小程序端不提示错误问题和设计时间问题
This commit is contained in:
parent
6aed54f04e
commit
8ecf0e1cfe
@ -808,6 +808,7 @@ const onAddItem = async() => {
|
||||
//条件修改:没有时间就不填
|
||||
var date = new Date();
|
||||
date.setHours(0,0,0,0)
|
||||
var date2 = new Date();
|
||||
if(processDesignType.value == 'BLUEPRINT_WORKBLANK'){
|
||||
if(formData.value.blankDate != null ){
|
||||
var date1 = new Date(formData.value.blankDate);
|
||||
@ -899,8 +900,8 @@ const onAddItem = async() => {
|
||||
progress: undefined,
|
||||
blueprintLink: undefined,
|
||||
remark: '',
|
||||
createTime: date.getTime(),
|
||||
beginTime:date.getTime(),
|
||||
createTime: date2.getTime(),
|
||||
beginTime:date2.getTime(),
|
||||
endTime:undefined,
|
||||
isOver:0,
|
||||
workTime:undefined,
|
||||
|
@ -102,9 +102,9 @@ const getData = async () => {
|
||||
}else{
|
||||
amount.value = 0
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
isLoading.value = false
|
||||
}
|
||||
@ -159,17 +159,29 @@ const handleComplate = async () => {
|
||||
try {
|
||||
const data = await postOperateAPI(params);
|
||||
} catch (error) {
|
||||
console.log(error)
|
||||
uni.showToast({
|
||||
icon: 'none',
|
||||
duration: 3000,
|
||||
title: error.data.msg,
|
||||
})
|
||||
} finally {
|
||||
isLoading.value = false;
|
||||
await getDetailData(detailInfo.value.id)
|
||||
await getData()
|
||||
const obj = historyList.value[0]
|
||||
// 最新的报工是否完成
|
||||
if (obj && obj?.workTime == null && obj.endTime) {
|
||||
popupShow.value = true
|
||||
}
|
||||
const url = `/pages/productionReport/productionReport-detail?id=${detailInfo.value.id}`
|
||||
uni.redirectTo({
|
||||
url,
|
||||
})
|
||||
}
|
||||
isLoading.value = false;
|
||||
// const url = `/pages/productionReport/productionReport-detail?id=${detailInfo.value.id}`
|
||||
// uni.redirectTo({
|
||||
// url,
|
||||
// })
|
||||
}
|
||||
// 提交报工
|
||||
const handleOk = async (active) => {
|
||||
console.log(amount.value)
|
||||
const params = {
|
||||
id: detailInfo.value?.id,
|
||||
active: 'SUBMIT',
|
||||
@ -318,7 +330,7 @@ const handleStop = async () => {
|
||||
<p>上一道工序尚未完工,请等待上一道工序完工后进行报工!</p>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
</template>
|
||||
<style lang="scss">
|
||||
// 订单列表
|
||||
|
Loading…
Reference in New Issue
Block a user