|
|
@ -1,7 +1,7 @@ |
|
|
|
<template> |
|
|
|
<ContentWrap> |
|
|
|
<!-- 搜索工作栏 --> |
|
|
|
<Search :schema="[...SupplierinvoiceRecordMain.allSchemas.searchSchema,...SupplierinvoiceRecordDetail.allSchemas.searchSchema]" @search="searchList" @reset="searchList" /> |
|
|
|
<Search :schema="SupplierinvoiceRecordMain.allSchemas.searchSchema" @search="searchList" @reset="searchList" /> |
|
|
|
</ContentWrap> |
|
|
|
|
|
|
|
<!-- 列表头部 --> |
|
|
@ -12,7 +12,6 @@ |
|
|
|
@updataTableColumns="updataTableColumns" |
|
|
|
@searchFormClick="searchFormClick" |
|
|
|
:allSchemas="SupplierinvoiceRecordMain.allSchemas" |
|
|
|
:detailAllSchemas="SupplierinvoiceRecordDetail.allSchemas" |
|
|
|
/> |
|
|
|
|
|
|
|
<!-- 列表 --> |
|
|
@ -125,14 +124,14 @@ const { t } = useI18n() // 国际化 |
|
|
|
const route = useRoute() // 路由信息 |
|
|
|
const routeName = ref() |
|
|
|
routeName.value = route.name |
|
|
|
const tableColumns = ref([...SupplierinvoiceRecordMain.allSchemas.tableColumns,...SupplierinvoiceRecordDetail.allSchemas.tableMainColumns]) |
|
|
|
const tableColumns = ref(SupplierinvoiceRecordMain.allSchemas.tableColumns) |
|
|
|
// 字段设置 更新主列表字段 |
|
|
|
const updataTableColumns = (val) => { |
|
|
|
tableColumns.value = val |
|
|
|
} |
|
|
|
|
|
|
|
const { tableObject, tableMethods } = useTable({ |
|
|
|
getListApi: SupplierinvoiceRecordDetailApi.getSupplierinvoiceRecordDeatilPage // 分页接口 |
|
|
|
getListApi: SupplierinvoiceRecordMainApi.getSupplierinvoiceRecordMainPage // 分页接口 |
|
|
|
}) |
|
|
|
|
|
|
|
// 获得表格的各种操作 |
|
|
@ -174,10 +173,6 @@ const buttonBaseClick = (val, item) => { |
|
|
|
|
|
|
|
// 列表-操作按钮 |
|
|
|
const butttondata = (row,$index) => { |
|
|
|
const findIndex = row['masterId']?tableObject.tableList.findIndex(item=>item['masterId'] == row['masterId']):-1 |
|
|
|
if(findIndex>-1&&findIndex<$index){ |
|
|
|
return [] |
|
|
|
} |
|
|
|
return [] |
|
|
|
} |
|
|
|
|
|
|
@ -199,9 +194,12 @@ const openDetail = async (row: any, titleName: any, titleValue: any) => { |
|
|
|
requestTableObject.params.number = row.requestNumber |
|
|
|
await requestGetList() |
|
|
|
if(requestTableObject.tableList.length>0){ |
|
|
|
row.annexMasterId = requestTableObject.tableList[0].masterId |
|
|
|
// row.annexMasterId = requestTableObject.tableList[0].masterId |
|
|
|
row.annexMasterId = row.id |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (departmentCode) row.departmentCode = JSON.parse(JSON.stringify(departmentCode)) |
|
|
|
detailRef.value.openDetail(row, titleName, titleValue) |
|
|
|
} |
|
|
|