|
@@ -194,7 +194,7 @@ const getSelectOptions = async (id: number) => {
|
|
|
try {
|
|
|
const {
|
|
|
code,
|
|
|
- returnData: { listValues },
|
|
|
+ returnData,
|
|
|
message,
|
|
|
}: SelectOptionQueryResult = await Query({
|
|
|
id,
|
|
@@ -203,6 +203,7 @@ const getSelectOptions = async (id: number) => {
|
|
|
if (Number(code) !== 0) {
|
|
|
throw new Error(message ?? "失败");
|
|
|
}
|
|
|
+ const listValues = returnData.listValues || returnData
|
|
|
const options = listValues.map(({ k, v, setlabel, setvalue }) => ({
|
|
|
k,
|
|
|
v,
|
|
@@ -336,6 +337,7 @@ const changeServiceState = async (serviceID: number, runState: string) => {
|
|
|
} = await Query({
|
|
|
id: DATACONTENT_ID.sysServiceNodeList,
|
|
|
dataContent: [serviceID],
|
|
|
+ btnAuth: 'service_stop_button'
|
|
|
});
|
|
|
if (Number(code) !== 0) {
|
|
|
throw new Error(message ?? "失败");
|
|
@@ -405,6 +407,7 @@ const deleteService = async () => {
|
|
|
const { code, message } = await GeneralDataReception({
|
|
|
serviceId: SERVICE_ID.sysServiceEdit,
|
|
|
dataContent: JSON.stringify(dataContent),
|
|
|
+ btnAuth: 'service_deletion_button'
|
|
|
});
|
|
|
if (Number(code) === 0) {
|
|
|
ElMessage.success(message ?? "成功");
|
|
@@ -419,7 +422,7 @@ const addServiceDialogShow = () => {
|
|
|
serviceDialogType.value = "add";
|
|
|
msgTitle.value = "新增服务管理";
|
|
|
serviceDialogVisible.value = true;
|
|
|
- console.log(queryTemplateIDMap, selectOptionMap);
|
|
|
+ // console.log(queryTemplateIDMap, selectOptionMap);
|
|
|
};
|
|
|
const addServiceDialogHide = () => {
|
|
|
serviceFormRef.value?.resetFields();
|
|
@@ -491,6 +494,7 @@ const createService = async () => {
|
|
|
const { code, message } = await GeneralDataReception({
|
|
|
serviceId: SERVICE_ID.sysServiceEdit,
|
|
|
dataContent: JSON.stringify(dataContent),
|
|
|
+ btnAuth: 'service_addition_button',
|
|
|
});
|
|
|
if (Number(code) === 0) {
|
|
|
ElMessage.success(message ?? "成功");
|