|
|
@ -10,7 +10,7 @@ |
|
|
|
@change="tabsChange" :is-scroll="false"> |
|
|
|
</u-subsection> --> |
|
|
|
</view> |
|
|
|
<view class="item" v-for="(item, index) in list" :key="index" @click="openDetail(item)"> |
|
|
|
<view class="item" v-for="(item, index) in list" :key="index"> |
|
|
|
<view class="title"> |
|
|
|
<view class="title-txt"> |
|
|
|
{{item.schedulingCode}} |
|
|
@ -56,6 +56,16 @@ |
|
|
|
border-color='#fe8463' type="primary" shape='circle'/> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view> |
|
|
|
<u-collapse ref="collapse" open="false"> |
|
|
|
<u-collapse-item title="当前工序" > |
|
|
|
<view class="content"> |
|
|
|
<text class="text">{{ item.workingNode }}</text> |
|
|
|
<u-button type="success" size="mini" v-if="item.status==1" @click="nodeCodeFinish(item)" class="btn1" style="background-color:#3366FF">完成</u-button> |
|
|
|
</view> |
|
|
|
</u-collapse-item> |
|
|
|
</u-collapse> |
|
|
|
</view> |
|
|
|
<view v-if="item.status==-1" > |
|
|
|
<u-button type="primary" @click="openInspectItem(item)">齐套检查</u-button> |
|
|
|
</view> |
|
|
@ -71,6 +81,7 @@ |
|
|
|
</view> |
|
|
|
<view> |
|
|
|
<u-button type="success" size="mini" @click="SOP(item)" class="btn" style="background-color:#888888">SOP</u-button> |
|
|
|
<u-button type="success" size="mini" @click="openDetail(item)" class="btn" style="background-color:#888888">明细</u-button> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view style="height: 94rpx;padding-top: 30rpx;"> |
|
|
@ -115,6 +126,9 @@ const list1 = ref([ |
|
|
|
{ |
|
|
|
name: '待质检', |
|
|
|
}, |
|
|
|
{ |
|
|
|
name: '已完工', |
|
|
|
}, |
|
|
|
{ |
|
|
|
name: '已完成', |
|
|
|
}, |
|
|
@ -132,7 +146,7 @@ const status = ref('loadmore') //是否显示没有更多了 |
|
|
|
const falg = ref('') |
|
|
|
const list = ref([]) |
|
|
|
const searchValue = ref('') |
|
|
|
const ss = ref() |
|
|
|
const nodeCodes = ref([]) |
|
|
|
|
|
|
|
|
|
|
|
const params = ref({ |
|
|
@ -146,7 +160,7 @@ async function getViewList() { |
|
|
|
if (status.value == 'nomore') return |
|
|
|
status.value = 'loading' |
|
|
|
proxy.$modal.loading('加载中') |
|
|
|
await workSchedulingListApi.getWorkSchedulingPage(params.value).then((res) => { |
|
|
|
await workSchedulingListApi.getWorkSchedulingPDAPage(params.value).then((res) => { |
|
|
|
proxy.$modal.closeLoading() |
|
|
|
if (res.data.list.length > 0) { |
|
|
|
list.value = list.value.concat(res.data.list) |
|
|
@ -172,7 +186,7 @@ async function getTabsList() { |
|
|
|
if (status.value == 'nomore') return |
|
|
|
status.value = 'loading' |
|
|
|
proxy.$modal.loading('加载中') |
|
|
|
await workSchedulingListApi.getWorkSchedulingPage(tabParams.value).then((res) => { |
|
|
|
await workSchedulingListApi.getWorkSchedulingPDAPage(tabParams.value).then((res) => { |
|
|
|
proxy.$modal.closeLoading() |
|
|
|
if (res.data.list.length > 0) { |
|
|
|
list.value = list.value.concat(res.data.list) |
|
|
@ -209,6 +223,34 @@ onReachBottom(() => { |
|
|
|
} |
|
|
|
}) |
|
|
|
|
|
|
|
//折叠框 |
|
|
|
// function getNodeCodes(item){ |
|
|
|
// console.log(item.schedulingCode) |
|
|
|
// workSchedulingListApi.getWorkSchedulingDetail(item.schedulingCode).then((res) => { |
|
|
|
// console.log(res.data); |
|
|
|
// nodeCodes.value = [] |
|
|
|
// nodeCodes.value = res.data |
|
|
|
// console.log(nodeCodes.value); |
|
|
|
// }).catch(() => { |
|
|
|
|
|
|
|
// }) |
|
|
|
// } |
|
|
|
|
|
|
|
//工序完成 |
|
|
|
function nodeCodeFinish(item){ |
|
|
|
console.log(item.remark) |
|
|
|
proxy.$modal.loading('加载中') |
|
|
|
workSchedulingListApi.getWorkSchedulingProcessFinished(item.remark).then((res) => { |
|
|
|
proxy.$modal.showToast('成功') |
|
|
|
console.log(res.data) |
|
|
|
tabsChange(3); |
|
|
|
proxy.$modal.closeLoading() |
|
|
|
}).catch(() => { |
|
|
|
proxy.$modal.showToast('失败') |
|
|
|
proxy.$modal.closeLoading() |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
//打开明细 |
|
|
|
function openDetail(item, index) { |
|
|
|
proxy.$tab.navigateTo(`/pages/mes/workScheduling/workSchedulingDetail?obj=${JSON.stringify(item)}`) |
|
|
@ -261,14 +303,16 @@ function tabsChange(index) { |
|
|
|
}else if(index == '5'){ |
|
|
|
tabParams.value.status = '3' |
|
|
|
}else if(index == '6'){ |
|
|
|
tabParams.value.status = '4' |
|
|
|
tabParams.value.status = '6' |
|
|
|
}else if(index == '7'){ |
|
|
|
tabParams.value.status = '9' |
|
|
|
tabParams.value.status = '6' |
|
|
|
}else if(index == '8'){ |
|
|
|
tabParams.value.status = '5' |
|
|
|
tabParams.value.status = '6' |
|
|
|
}else if(index == '9'){ |
|
|
|
tabParams.value.status = '-3' |
|
|
|
tabParams.value.status = '9' |
|
|
|
}else if(index == '10'){ |
|
|
|
tabParams.value.status = '-3' |
|
|
|
}else if(index == '11'){ |
|
|
|
tabParams.value.status = '-2' |
|
|
|
} else { |
|
|
|
tabParams.value.status = index |
|
|
@ -286,7 +330,7 @@ const searchTableParams = ref({ |
|
|
|
async function searchTable() { |
|
|
|
list.value = [] |
|
|
|
searchTableParams.value.planNoDay = this.searchValue |
|
|
|
await workSchedulingListApi.getWorkSchedulingPage(searchTableParams.value).then((res) => { |
|
|
|
await workSchedulingListApi.getWorkSchedulingPDAPage(searchTableParams.value).then((res) => { |
|
|
|
if (res.data.list.length > 0) { |
|
|
|
list.value = list.value.concat(res.data.list) |
|
|
|
} |
|
|
@ -447,4 +491,11 @@ function SOP(item){ |
|
|
|
font-size: 17px |
|
|
|
|
|
|
|
} |
|
|
|
.btn1{ |
|
|
|
margin-left: 8px; |
|
|
|
width: 35px; |
|
|
|
height:20px; |
|
|
|
font-size: 10px |
|
|
|
|
|
|
|
} |
|
|
|
</style> |