feat: support ins pause and enable tips

This commit is contained in:
engigu
2024-01-14 19:48:45 +08:00
parent 766e4c8855
commit c6cd067451
2 changed files with 11 additions and 3 deletions
+8 -1
View File
@@ -208,5 +208,12 @@ func UpdateMsgTaskInsEnable(c *gin.Context) {
return
}
appG.CResponse(http.StatusOK, "更新实例成功!", nil)
msg := ""
if req.Enable == 1 {
msg = fmt.Sprintf("设置实例发送为开启成功!")
} else {
msg = fmt.Sprintf("设置实例发送为暂停成功!")
}
appG.CResponse(http.StatusOK, msg, nil)
}
@@ -67,7 +67,7 @@
{{ scope.row.way_type }}+{{ scope.row.content_type }}
</template>
</el-table-column>
<el-table-column prop="way_type" label="额外信息" >
<el-table-column prop="way_type" label="额外信息">
<template #default="scope">
{{ formatExtraInfo(scope) }}
</template>
@@ -229,6 +229,7 @@ export default defineComponent({
const rsp = await request.post('/sendtasks/ins/update_enable', postData);
if (await rsp.data.code == 200) {
row.enable = status;
ElMessage({ message: await rsp.data.msg, type: 'success' });
}
}
@@ -236,7 +237,7 @@ export default defineComponent({
let postData = { id: state.currTaskInput.taskId, name: state.currTaskInput.taskName };
const rsp = await request.post('/sendtasks/edit', postData);
if (await rsp.data.code == 200) {
ElMessage({ message: await rsp.data.msg, type: 'success' })
ElMessage({ message: await rsp.data.msg, type: 'success' });
}
}