feat: support dingtalk push
This commit is contained in:
@@ -8,9 +8,9 @@
|
||||
<br />
|
||||
实例的内容类型大体上可以可以分为text、html、markdown
|
||||
<br />
|
||||
发送的消息会优先现在相应的类型消息进行发送,如果没有,将使用传的text消息进行发送
|
||||
发送的消息会优先现在相应的类型消息进行发送,如果没有,将使用传的text消息进行发送
|
||||
<br />
|
||||
** text节点必传,指定mode=async将异步发送,否则同步发送
|
||||
** text节点必传,指定mode=sync将同步发送,默认异步发送
|
||||
</template>
|
||||
<el-icon>
|
||||
<QuestionFilled />
|
||||
@@ -40,6 +40,7 @@ import { usePageState } from '@/store/page_sate.js';
|
||||
import Prism from "prismjs";
|
||||
import { ApiStrGenerate } from "@/util/viewApi.js";
|
||||
import { QuestionFilled } from '@element-plus/icons-vue'
|
||||
import { request } from '@/api/api'
|
||||
|
||||
export default defineComponent({
|
||||
components: {
|
||||
@@ -70,10 +71,24 @@ export default defineComponent({
|
||||
}
|
||||
}
|
||||
|
||||
const renderApiString = () => {
|
||||
// 获取接口查看格式
|
||||
const getViewOptions = async (taskId) => {
|
||||
let params = { id: taskId };
|
||||
const rsp = await request.get('/sendtasks/ins/gettask', { params: params });
|
||||
let insTableData = await rsp.data.data.ins_data;
|
||||
|
||||
let viewOptions = {}
|
||||
insTableData.forEach(element => {
|
||||
viewOptions[element.content_type] = 1;
|
||||
});
|
||||
return viewOptions
|
||||
}
|
||||
|
||||
const renderApiString = async () => {
|
||||
let task_id = pageState.ShowDialogData[props.componentName].rowData.id;
|
||||
let options = await getViewOptions(task_id)
|
||||
if (state.activeName == 'curl') {
|
||||
state.currCode = ApiStrGenerate.getCurlString(task_id, {});
|
||||
state.currCode = ApiStrGenerate.getCurlString(task_id, options);
|
||||
}
|
||||
setTimeout(() => {
|
||||
Prism.highlightAll()
|
||||
|
||||
Reference in New Issue
Block a user