|
|
@ -45,14 +45,16 @@ |
|
|
|
:apiDelete="InspectionRecordDetailApi.deleteInspectionRecordDetail" @searchTableSuccessDetail="searchTableSuccessDetail" |
|
|
|
:isShowAddBtn="false" :detailButtonIsShow="true" |
|
|
|
/> |
|
|
|
<!-- 包装信息 --> |
|
|
|
<ListTable ref="listTableRef" titleName="包装信息"/> |
|
|
|
<!-- 包装信息 --> <ListTable ref="listTableRef" titleName="包装信息" :allSchemas="InspectionRecordMain.allSchemas" |
|
|
|
:detailAllSchemas="InspectionRecordPackage.allSchemas" :detailAllSchemasRules="InspectionRecordPackageRules" |
|
|
|
:list="list"/> |
|
|
|
</template> |
|
|
|
|
|
|
|
<script setup lang="ts"> |
|
|
|
import download from '@/utils/download' |
|
|
|
import { InspectionRecordMain, InspectionRecordMainRules, InspectionRecordDetail, InspectionRecordDetailRules,InspectionRecordPackage, InspectionRecordPackageRules} from './inspectionRecordMain.data' |
|
|
|
// import { InspectionJobPackage,InspectionJobPackageRules} from '../inspectionJob/inspectionJobMain.data' |
|
|
|
import * as InspectionRecordPackageApi from '@/api/qms/inspectionRecord/InspectionRecordPackage/InspectionRecordPackage' |
|
|
|
import * as InspectionRecordMainApi from '@/api/qms/inspectionRecord/inspectionRecordMain' |
|
|
|
import * as InspectionRecordDetailApi from '@/api/qms/inspectionRecord/inspectionRecordDetail' |
|
|
|
import * as defaultButtons from '@/utils/disposition/defaultButtons' |
|
|
@ -132,6 +134,7 @@ import { DICT_TYPE, getStrDictOptions } from '@/utils/dict' |
|
|
|
} |
|
|
|
|
|
|
|
const listTableRef = ref() |
|
|
|
const list = ref([]) |
|
|
|
const useDecisionList = getStrDictOptions(DICT_TYPE.USAGE_DECISION) |
|
|
|
// const useDecisionList = InspectionRecordMain.allSchemas.formSchema.filter(item=>item.field == "useDecision") |
|
|
|
// 列表-操作按钮事件 |
|
|
@ -153,14 +156,15 @@ import { DICT_TYPE, getStrDictOptions } from '@/utils/dict' |
|
|
|
} |
|
|
|
openForm('update', row) |
|
|
|
}else if (val == 'mainPackage') { // 包装 |
|
|
|
const list = await InspectionRecordMainApi.getInspectionRecordPackageList(row.id) |
|
|
|
list.forEach(item=>{ |
|
|
|
list.value = await InspectionRecordPackageApi.getInspectionRecordPackageList(row.id) |
|
|
|
list.value.forEach(item=>{ |
|
|
|
item.qualifiedAmount = item.qualifiedAmount ?item.qualifiedAmount :0 |
|
|
|
item.noQualifiedAmount = item.noQualifiedAmount ?item.noQualifiedAmount :0 |
|
|
|
item.destroyAmount = item.destroyAmount ?item.destroyAmount :0 |
|
|
|
item.frozenAmount = item.frozenAmount ?item.frozenAmount :0 |
|
|
|
}) |
|
|
|
listTableRef.value.openPackage(row,'包装信息',InspectionRecordPackage.allSchemas.tableColumns,list) |
|
|
|
// row.status = '1' |
|
|
|
listTableRef.value.openPackage(row,'包装信息',InspectionRecordPackage.allSchemas.tableColumns) |
|
|
|
}else if (val == 'delete') { // 删除 |
|
|
|
handleDelete(row.id) |
|
|
|
}else if (val == 'mainOrderPub') { //发布 |
|
|
|