Browse Source

feat: update 增加叫料、领料、补料、完工、按钮

master
TengXF 6 months ago
parent
commit
cbb49d9088
  1. 21
      src/api/mes/workScheduling/index.ts
  2. 1
      src/pages/mes/reworkBatch/create.vue
  3. 33
      src/pages/mes/workScheduling/workScheduling.vue

21
src/api/mes/workScheduling/index.ts

@ -77,3 +77,24 @@ export const getConfigProcessWorker = async (params: any) => {
export const reportWorkByProcess = async (params: any) => {
return http.post('/mes/work-scheduling-detail/reportWorkByProcess', params)
}
//完工处理
export function completeHandle(data) {
return http.post('/mes/workScheduling/completeHandle', data)
}
//叫料
export function callBasicItem(data) {
return http.post('/mes/', data)
}
//领料
export function receiveBasicItem(data) {
return http.post('/mes/', data)
}
//补料
export function addBasicItem(data) {
return http.post('/mes/', data)
}

1
src/pages/mes/reworkBatch/create.vue

@ -198,6 +198,7 @@
}
//
function selectReworkTime(index){
console.log(index)
const dateStr = `${index.year}-${index.month}-${index.day}`
form.value.reworkStr = dateStr
form.value.reworkTime = index.timestamp

33
src/pages/mes/workScheduling/workScheduling.vue

@ -62,6 +62,12 @@
<view v-if="item.status==0" >
<u-button type="primary" @click="开工(item)">开工</u-button>
</view>
<view v-if="item.status==1" >
<u-button type="success" size="medium" @click="callBasicItem(item)" style="width: 20px;">叫料</u-button>
<u-button type="primary" size="medium" @click="receiveBasicItem(item)" style="margin-left: 5px;width: 20px;">领料</u-button>
<u-button type="warning" size="medium" @click="addBasicItem(item)" style="margin-left: 5px;width: 20px;">补料</u-button>
<u-button type="success" size="medium" @click="completeHandle(item)" style="margin-left: 5px;width: 20px;">完工</u-button>
</view>
</view>
<view style="height: 94rpx;padding-top: 30rpx;">
<u-loadmore :status="status" v-if="status != 'loadmore'" />
@ -267,6 +273,33 @@ async function searchTable() {
}
})
}
//
function completeHandle(item) {
console.log(item)
// proxy.$modal.loading('')
// workSchedulingListApi.completeHandle(completedParams.value).then((res) => {
// proxy.$modal.closeLoading()
// if (res.data) {
// } else {
// }
// }).catch(() => {
// proxy.$modal.closeLoading()
// })
}
//
function callBasicItem(item){
console.log(item)
}
//
function receiveBasicItem(item){
console.log(item)
}
//
function addBasicItem(item){
console.log(item)
}
</script>

Loading…
Cancel
Save