diff --git a/src/components/Detail/src/Detail.vue b/src/components/Detail/src/Detail.vue
index 22f0dd4a6..d34a31098 100644
--- a/src/components/Detail/src/Detail.vue
+++ b/src/components/Detail/src/Detail.vue
@@ -12,7 +12,7 @@
{{ titleValueRef }} {{ t(`ts.${titleNameRef}`).replace('ts.','') }}
-
+
-
-
-
-
+
+
+
+
-
+
+
{
return props.annexTable.filter(item=>{
@@ -678,6 +679,7 @@ const change = (item, index) => {
// 附件/备注/变更记录 -- 点击回到顶部
scrollbar.value?.scrollTo({ top: 0});
}
+
}
const changeTabCurrent = ({label,index})=>{
@@ -704,6 +706,7 @@ const masterParmas = ref({
// 列表头部按钮
const HeadButttondata = ref()
+const HeadButttondataBackups = ref()// 列表头部按钮备份
// 列表-操作按钮
const buttondata = ref()
@@ -787,7 +790,8 @@ const openDetail = async (row: any, titleName: any, titleValue: any, tableName:
})
]
}
- HeadButttondata.value = [...detailButtonFilter,...detailButtonAdd]
+ HeadButttondata.value = [...detailButtonFilter, ...detailButtonAdd]
+ HeadButttondataBackups.value = [...detailButtonFilter, ...detailButtonAdd]
// 针对特殊处理 当业务是任务的 只显示筛选 正常情况下应在业务页面设置 后期再作优化
if (routeName.value.indexOf('Job') > -1) {
@@ -796,6 +800,7 @@ const openDetail = async (row: any, titleName: any, titleValue: any, tableName:
]
}
HeadButttondata.value = [...HeadButttondata.value,...props.otherHeadButttonData]
+ HeadButttondataBackups.value = [...HeadButttondata.value,...props.otherHeadButttonData]
let detailButtonEdit: any = []
let detailButtonDelete: any = []
if (props.detailButtonIsShowEdit) {
@@ -907,12 +912,6 @@ const buttonBaseClick = (val, item) => {
}else{
openForm('create')
}
- } else if (val == 'import') {
- // 导入
- handleImport()
- } else if (val == 'export') {
- // 导出
- handleExport()
} else if (val == 'refresh') {
// 刷新
getList()
@@ -1147,7 +1146,7 @@ const formFormDateChange = (field, val,row, index) => {
//监视属性
watch(
() => props.apiPage,
- () => {
+ async () => {
const { tableObject, tableMethods } = useTable({
getListApi: props.apiPage // 分页接口
})
@@ -1161,10 +1160,16 @@ watch(
tableObjectRef.value = tableObject
tableMethodsRef.value = tableMethods
const { getList } = tableMethods
- getList()
+ await getList()
}
)
-defineExpose({ openDetail, formRef ,updateList,submitUpdateList,changeTabCurrent}) // 提供 open 方法,用于打开弹窗
+ watch(
+ () => props.otherHeadButttonData,
+ (val) => {
+ HeadButttondata.value = [...HeadButttondataBackups.value, ...props.otherHeadButttonData]
+ }
+ )
+defineExpose({ openDetail, formRef ,updateList,submitUpdateList,changeTabCurrent,openForm}) // 提供 open 方法,用于打开弹窗