This commit is contained in:
parent
53dc31425d
commit
afe021d167
|
|
@ -74,7 +74,7 @@
|
|||
color="#409eff"
|
||||
:value="item.code"
|
||||
:checked="selectedItems.includes(item.code)"
|
||||
:disabled="item.status !== '0'"
|
||||
:disabled="item.status !== '0' && item.status!=='3'"
|
||||
@click.stop="handleItemCheck(item.code)"
|
||||
style="transform: scale(0.7)"
|
||||
/>
|
||||
|
|
@ -109,7 +109,7 @@ const repairDeviceList = ref([])
|
|||
const selectedItems = ref([])
|
||||
|
||||
const selectableItems = computed(() => {
|
||||
return repairDeviceList.value.filter(item => item.status === '0').map(item => item.code)
|
||||
return repairDeviceList.value.filter(item => item.status === '0' || item.status==='3').map(item => item.code)
|
||||
})
|
||||
|
||||
onLoad((options) => {
|
||||
|
|
@ -132,7 +132,7 @@ const handleSelectAll = (e) => {
|
|||
const handleItemCheck = (code) => {
|
||||
// Only allow selection if item is status '0'
|
||||
const item = repairDeviceList.value.find(i => i.code === code)
|
||||
if (item && item.status !== '0') return
|
||||
if (item && item.status !== '0' && item.status!=='3') return
|
||||
|
||||
const index = selectedItems.value.indexOf(code)
|
||||
if (index === -1) {
|
||||
|
|
@ -145,7 +145,7 @@ const handleItemCheck = (code) => {
|
|||
|
||||
// 点击跳转维修页面
|
||||
const goOperate = (item,index) => {
|
||||
if(item.status==0){
|
||||
if(item.status==0 || item.status==3){
|
||||
const codingUrl = '/pages/repair/equipAssessment/batch-repair' // 编码维修
|
||||
const selectedCodes = [item.code];
|
||||
// 构造传递的参数
|
||||
|
|
@ -222,6 +222,7 @@ const getStatusClass = (status) => {
|
|||
case '1': return 'status-completed'
|
||||
case '0': return 'status-pending'
|
||||
case '2': return 'status-scrap'
|
||||
case '3': return 'status-pending'
|
||||
default: return ''
|
||||
}
|
||||
}
|
||||
|
|
@ -232,6 +233,7 @@ const getStatusText = (status) => {
|
|||
case '1': return '已完成'
|
||||
case '0': return '未完成'
|
||||
case '2': return '待报废'
|
||||
case '3': return '未完成'
|
||||
default: return '未知'
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue