This commit is contained in:
hayu 2025-09-16 21:09:39 +08:00
parent 53dc31425d
commit afe021d167
1 changed files with 6 additions and 4 deletions

View File

@ -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 '未知'
}
}