应用中心 脚本管理、数据源管理修改与开发

This commit is contained in:
hyt 2024-06-20 16:11:38 +08:00
parent aa1b38e226
commit fbad8e0d0a
2 changed files with 79 additions and 15 deletions

View File

@ -185,6 +185,45 @@ export default {
} }
] ]
}, },
{
elCol: [
{
type: 'select',
title: '新增脚本',
id: 'addScript',
row: 24,
disabled: false,
fontSize: 16,
options: []
}
]
},
{
elCol: [
{
type: 'select',
title: '修改脚本',
id: 'updateScript',
row: 24,
disabled: false,
fontSize: 16,
options: []
}
]
},
{
elCol: [
{
type: 'select',
title: '删除脚本',
id: 'deleteScript',
row: 24,
disabled: false,
fontSize: 16,
options: []
}
]
},
{ {
elCol: [ elCol: [
{ {
@ -341,9 +380,15 @@ export default {
this.formRow[2].elCol[0].options = [] this.formRow[2].elCol[0].options = []
this.formRow[3].elCol[0].options = [] this.formRow[3].elCol[0].options = []
this.formRow[4].elCol[0].options = [] this.formRow[4].elCol[0].options = []
this.formRow[5].elCol[0].options = []
this.formRow[6].elCol[0].options = []
this.formRow[7].elCol[0].options = []
this.$set(this.ruleForm, 'addApi', '') this.$set(this.ruleForm, 'addApi', '')
this.$set(this.ruleForm, 'updateApi', '') this.$set(this.ruleForm, 'updateApi', '')
this.$set(this.ruleForm, 'deleteApi', '') this.$set(this.ruleForm, 'deleteApi', '')
this.$set(this.ruleForm, 'addScript', '')
this.$set(this.ruleForm, 'updateScript', '')
this.$set(this.ruleForm, 'deleteScript', '')
} }
//appidapp //appidapp
if (row.id === 'appId' && val) { if (row.id === 'appId' && val) {
@ -364,6 +409,25 @@ export default {
label: item.apiName label: item.apiName
}) })
}) })
//
this.openLoading('detail')
const res2 = await authApi('sysApplicationService', '', 'queryAppScript', '', {
appId: val
})
res2.attribute.forEach((item) => {
this.formRow[5].elCol[0].options.push({
id: item.id,
label: item.scriptName
})
this.formRow[6].elCol[0].options.push({
id: item.id,
label: item.scriptName
})
this.formRow[7].elCol[0].options.push({
id: item.id,
label: item.scriptName
})
})
} }
}, },

View File

@ -14,7 +14,7 @@
</template> </template>
<!-- 操作类型--> <!-- 操作类型-->
<template #optionType="{row}"> <template #optionType="{row}">
{{ optionTypeDist[row.optionType]}} {{row.optionType}}
</template> </template>
</baseTable> </baseTable>
</div> </div>
@ -109,9 +109,9 @@ export default {
limit: 10 limit: 10
}, },
optionTypeDist:{ optionTypeDist:{
1:"新增", '1':"新增",
2:"修改", '2':"修改",
3:"删除", '3':"删除",
} }
} }
}, },