1921 lines
79 KiB
JavaScript
1921 lines
79 KiB
JavaScript
import { E as ElMessage, x as ElFormItem, aq as ElSelect, ar as ElOption, h as ElButton, w as ElForm, am as ElTableColumn, y as ElInput, t as ElLink, i as ElIcon, U as ElRow, V as ElCol, l as ElTooltip, al as ElTable, q as ElTag, m as ElDropdown, n as ElDropdownMenu, o as ElDropdownItem, u as ElEmpty, ao as vLoading, T as ElCard, a3 as ElDescriptions, a4 as ElDescriptionsItem, P as ElRadioGroup, Q as ElRadio, av as ElInputNumber, aw as ElDatePicker, ax as ElPopover, v as ElDialog, D as ElMessageBox } from "./element-plus.CkEW9frc.js";
|
|
import { _ as __unplugin_components_19 } from "./index.fgd49PES.js";
|
|
import { _ as _sfc_main$3 } from "./UserTableSelect.vue_vue_type_script_setup_true_lang.7Fjc3bJT.js";
|
|
import { D as DatePicker } from "./index.Cu5O_6Z1.js";
|
|
import { J as defineComponent, r as ref, t as onMounted, S as openBlock, T as createBlock, a0 as withCtx, $ as createVNode, o as unref, a9 as createTextVNode, _ as createElementBlock, H as Fragment, ay as renderList, aa as toDisplayString, a1 as createBaseVNode, a6 as withDirectives, R as renderSlot, aS as normalizeProps, aT as guardReactiveProps, j as computed, aO as resolveComponent, aP as resolveDirective, z as isRef, a8 as createCommentVNode, aw as withModifiers, em as index_umd_minExports, ak as reactive } from "./.pnpm.BW3P1y8f.js";
|
|
import { _ as _sfc_main$4, J as JobAPI } from "./JobLogDrawer.vue_vue_type_script_setup_true_lang.ClGD6wLS.js";
|
|
import { _ as _export_sfc } from "./_plugin-vue_export-helper.1tPrXgE0.js";
|
|
import { j as useDictStore } from "./index.CMd5bD1r.js";
|
|
import { _ as _sfc_main$5 } from "./ExportModal.vue_vue_type_script_setup_true_lang.Bok1HJuH.js";
|
|
import { f as formatToDateTime } from "./dateUtil.SHphbRyf.js";
|
|
import "./codemirror.CvJAcn2d.js";
|
|
import "./exceljs.CkFT-P7Q.js";
|
|
const _hoisted_1$2 = { class: "form-actions" };
|
|
const MAX_SECONDS = 60;
|
|
const MAX_MINUTES = 60;
|
|
const MAX_HOURS = 24;
|
|
const MAX_DAYS = 31;
|
|
const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
__name: "index",
|
|
props: {
|
|
cronValue: {}
|
|
},
|
|
emits: ["confirm", "cancel"],
|
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
const props = __props;
|
|
const emit = __emit;
|
|
const formRef = ref();
|
|
const crontabValueObj = ref({
|
|
second: "*",
|
|
min: "*",
|
|
hour: "*",
|
|
day: "*",
|
|
week: "*"
|
|
});
|
|
const seconds = ref(Array.from({ length: MAX_SECONDS }, (_, i) => i));
|
|
const minutes = ref(Array.from({ length: MAX_MINUTES }, (_, i) => i));
|
|
const hours = ref(Array.from({ length: MAX_HOURS }, (_, i) => i));
|
|
const days = ref(Array.from({ length: MAX_DAYS }, (_, i) => i + 1));
|
|
const weekOptions = [
|
|
{ value: "1", label: "周一" },
|
|
{ value: "2", label: "周二" },
|
|
{ value: "3", label: "周三" },
|
|
{ value: "4", label: "周四" },
|
|
{ value: "5", label: "周五" },
|
|
{ value: "6", label: "周六" },
|
|
{ value: "7", label: "周日" }
|
|
];
|
|
onMounted(() => {
|
|
if (props.cronValue) {
|
|
setCron(props.cronValue);
|
|
}
|
|
});
|
|
const handleConfirm = () => {
|
|
const obj = crontabValueObj.value;
|
|
if (!obj.second || !obj.min || !obj.hour || !obj.day || !obj.week) {
|
|
ElMessage.warning("请完善所有时间选项");
|
|
return;
|
|
}
|
|
const cronStr = `${obj.second} ${obj.min} ${obj.hour} ${obj.day} ${obj.week}`;
|
|
emit("confirm", cronStr);
|
|
};
|
|
const setCron = (cronStr) => {
|
|
if (!cronStr) return;
|
|
const parts = cronStr.split(" ");
|
|
if (parts.length !== 5) {
|
|
ElMessage.warning("无效的cron表达式格式");
|
|
return;
|
|
}
|
|
const [second, min, hour, day, week] = parts;
|
|
crontabValueObj.value = {
|
|
second: second || "*",
|
|
min: min || "*",
|
|
hour: hour || "*",
|
|
day: day || "*",
|
|
week: week || "*"
|
|
};
|
|
};
|
|
__expose({ setCron });
|
|
return (_ctx, _cache) => {
|
|
const _component_el_option = ElOption;
|
|
const _component_el_select = ElSelect;
|
|
const _component_el_form_item = ElFormItem;
|
|
const _component_el_button = ElButton;
|
|
const _component_el_form = ElForm;
|
|
return openBlock(), createBlock(_component_el_form, {
|
|
ref_key: "formRef",
|
|
ref: formRef,
|
|
model: unref(crontabValueObj),
|
|
"label-width": "auto",
|
|
"label-suffix": ":",
|
|
inline: true,
|
|
class: "interval-tab-form"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_form_item, {
|
|
label: "秒",
|
|
prop: "second",
|
|
class: "form-item"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(crontabValueObj).second,
|
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => unref(crontabValueObj).second = $event),
|
|
placeholder: "秒",
|
|
clearable: ""
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_option, {
|
|
label: "每秒",
|
|
value: "*"
|
|
}, {
|
|
default: withCtx(() => [..._cache[6] || (_cache[6] = [
|
|
createTextVNode("*", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(seconds), (second) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: second,
|
|
label: second,
|
|
value: second.toString()
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(second), 1)
|
|
]),
|
|
_: 2
|
|
}, 1032, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "分",
|
|
prop: "min",
|
|
class: "form-item"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(crontabValueObj).min,
|
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => unref(crontabValueObj).min = $event),
|
|
placeholder: "分",
|
|
clearable: ""
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_option, {
|
|
label: "每分",
|
|
value: "*"
|
|
}, {
|
|
default: withCtx(() => [..._cache[7] || (_cache[7] = [
|
|
createTextVNode("*", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(minutes), (min) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: min,
|
|
label: min,
|
|
value: min.toString()
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(min), 1)
|
|
]),
|
|
_: 2
|
|
}, 1032, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "时",
|
|
prop: "hour",
|
|
class: "form-item"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(crontabValueObj).hour,
|
|
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => unref(crontabValueObj).hour = $event),
|
|
placeholder: "时",
|
|
clearable: ""
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_option, {
|
|
label: "每时",
|
|
value: "*"
|
|
}, {
|
|
default: withCtx(() => [..._cache[8] || (_cache[8] = [
|
|
createTextVNode("*", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(hours), (hour) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: hour,
|
|
label: hour,
|
|
value: hour.toString()
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(hour), 1)
|
|
]),
|
|
_: 2
|
|
}, 1032, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "天",
|
|
prop: "day",
|
|
class: "form-item"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(crontabValueObj).day,
|
|
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => unref(crontabValueObj).day = $event),
|
|
placeholder: "天",
|
|
clearable: ""
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_option, {
|
|
label: "每天",
|
|
value: "*"
|
|
}, {
|
|
default: withCtx(() => [..._cache[9] || (_cache[9] = [
|
|
createTextVNode("*", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(days), (day) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: day,
|
|
label: day,
|
|
value: day
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(day), 1)
|
|
]),
|
|
_: 2
|
|
}, 1032, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "周",
|
|
prop: "week",
|
|
class: "form-item"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(crontabValueObj).week,
|
|
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => unref(crontabValueObj).week = $event),
|
|
placeholder: "周",
|
|
clearable: ""
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_option, {
|
|
label: "每周",
|
|
value: "*"
|
|
}, {
|
|
default: withCtx(() => [..._cache[10] || (_cache[10] = [
|
|
createTextVNode("*", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
(openBlock(), createElementBlock(Fragment, null, renderList(weekOptions, (week) => {
|
|
return createVNode(_component_el_option, {
|
|
key: week.value,
|
|
label: week.label,
|
|
value: week.value
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(week.label), 1)
|
|
]),
|
|
_: 2
|
|
}, 1032, ["label", "value"]);
|
|
}), 64))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createBaseVNode("div", _hoisted_1$2, [
|
|
createVNode(_component_el_button, {
|
|
onClick: _cache[5] || (_cache[5] = ($event) => emit("cancel"))
|
|
}, {
|
|
default: withCtx(() => [..._cache[11] || (_cache[11] = [
|
|
createTextVNode("取消", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_button, {
|
|
type: "primary",
|
|
onClick: handleConfirm
|
|
}, {
|
|
default: withCtx(() => [..._cache[12] || (_cache[12] = [
|
|
createTextVNode("确认", -1)
|
|
])]),
|
|
_: 1
|
|
})
|
|
])
|
|
]),
|
|
_: 1
|
|
}, 8, ["model"]);
|
|
};
|
|
}
|
|
});
|
|
const IntervalTab = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-f82eb42d"]]);
|
|
const _hoisted_1$1 = { class: "operation-buttons" };
|
|
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
__name: "index",
|
|
props: {
|
|
listDataLength: {},
|
|
prop: {},
|
|
label: { default: "操作" },
|
|
fixed: { type: [String, Boolean], default: "right" },
|
|
align: { default: "center" },
|
|
width: {},
|
|
showOverflowTooltip: { type: Boolean },
|
|
minWidth: { default: 80 }
|
|
},
|
|
setup(__props) {
|
|
const props = __props;
|
|
const count = ref(0);
|
|
const operationWidth = ref(Number(props.minWidth) || 80);
|
|
const calculateWidth = () => {
|
|
count.value++;
|
|
if (count.value !== props.listDataLength) return;
|
|
const maxWidth = getOperationMaxWidth();
|
|
operationWidth.value = Math.max(maxWidth, Number(props.minWidth));
|
|
count.value = 0;
|
|
};
|
|
const finalWidth = computed(() => {
|
|
const widthNum = typeof props.width === "number" ? props.width : Number(props.width);
|
|
const minWidthNum = typeof props.minWidth === "number" ? props.minWidth : Number(props.minWidth);
|
|
return widthNum || operationWidth.value || minWidthNum;
|
|
});
|
|
const vAutoWidth = {
|
|
mounted() {
|
|
calculateWidth();
|
|
},
|
|
updated() {
|
|
calculateWidth();
|
|
}
|
|
};
|
|
const getOperationMaxWidth = () => {
|
|
const el = document.getElementsByClassName("operation-buttons");
|
|
let maxWidth = 0;
|
|
let totalWidth = 0;
|
|
Array.prototype.forEach.call(el, (item) => {
|
|
const buttons = item.querySelectorAll(".el-button");
|
|
totalWidth = Array.from(buttons).reduce((acc, button) => {
|
|
return acc + button.scrollWidth + 14;
|
|
}, 0);
|
|
if (totalWidth > maxWidth) maxWidth = totalWidth;
|
|
});
|
|
return maxWidth;
|
|
};
|
|
return (_ctx, _cache) => {
|
|
const _component_el_table_column = ElTableColumn;
|
|
return openBlock(), createBlock(_component_el_table_column, {
|
|
label: __props.label,
|
|
fixed: __props.fixed,
|
|
align: __props.align,
|
|
"show-overflow-tooltip": __props.showOverflowTooltip,
|
|
width: unref(finalWidth)
|
|
}, {
|
|
default: withCtx(({ row, column, $index }) => [
|
|
withDirectives((openBlock(), createElementBlock("div", _hoisted_1$1, [
|
|
renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ row, column, $index })))
|
|
])), [
|
|
[vAutoWidth]
|
|
])
|
|
]),
|
|
_: 3
|
|
}, 8, ["label", "fixed", "align", "show-overflow-tooltip", "width"]);
|
|
};
|
|
}
|
|
});
|
|
const _hoisted_1 = { class: "app-container" };
|
|
const _hoisted_2 = { class: "search-container" };
|
|
const _hoisted_3 = { class: "card-header" };
|
|
const _hoisted_4 = { class: "data-table__toolbar" };
|
|
const _hoisted_5 = { class: "data-table__toolbar--left" };
|
|
const _hoisted_6 = { class: "data-table__toolbar--right" };
|
|
const _hoisted_7 = { class: "flex" };
|
|
const _hoisted_8 = { class: "dialog-footer" };
|
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
...{
|
|
name: "Job",
|
|
inheritAttrs: false
|
|
},
|
|
__name: "index",
|
|
setup(__props) {
|
|
const dictStore = useDictStore();
|
|
const queryFormRef = ref();
|
|
const dataFormRef = ref();
|
|
const total = ref(0);
|
|
const selectIds = ref([]);
|
|
const loading = ref(false);
|
|
const isExpand = ref(false);
|
|
const isExpandable = ref(true);
|
|
const openCron = ref(false);
|
|
const openIntervalTab = ref(false);
|
|
const intervalTabRef = ref();
|
|
const pageTableData = ref([]);
|
|
const exportsDialogVisible = ref(false);
|
|
const selectionRows = ref([]);
|
|
const detailFormData = ref({});
|
|
const queryFormData = reactive({
|
|
page_no: 1,
|
|
page_size: 10,
|
|
name: void 0,
|
|
status: void 0,
|
|
created_time: void 0,
|
|
created_id: void 0
|
|
});
|
|
const formData = reactive({
|
|
id: void 0,
|
|
name: void 0,
|
|
func: void 0,
|
|
trigger: void 0,
|
|
args: void 0,
|
|
kwargs: void 0,
|
|
coalesce: false,
|
|
max_instances: 1,
|
|
jobstore: void 0,
|
|
executor: void 0,
|
|
trigger_args: void 0,
|
|
start_date: void 0,
|
|
end_date: void 0,
|
|
status: void 0,
|
|
description: void 0
|
|
});
|
|
const dialogVisible = reactive({
|
|
title: "",
|
|
visible: false,
|
|
type: "create"
|
|
});
|
|
const drawerVisible = ref(false);
|
|
const rules = reactive({
|
|
name: [{ required: true, message: "请输入任务名称", trigger: "blur" }],
|
|
func: [{ required: true, message: "请输入执行函数", trigger: "blur" }],
|
|
trigger: [{ required: true, message: "请选择触发器", trigger: "blur" }],
|
|
coalesce: [{ required: true, message: "请选择并发执行", trigger: "blur" }],
|
|
jobstore: [{ required: true, message: "请选择存储器", trigger: "blur" }],
|
|
executor: [{ required: true, message: "请选择执行器", trigger: "blur" }]
|
|
});
|
|
const createdDateRange = ref([]);
|
|
const updatedDateRange = ref([]);
|
|
function handleCreatedDateRangeChange(range) {
|
|
createdDateRange.value = range;
|
|
if (range && range.length === 2) {
|
|
queryFormData.created_time = [formatToDateTime(range[0]), formatToDateTime(range[1])];
|
|
} else {
|
|
queryFormData.created_time = void 0;
|
|
}
|
|
}
|
|
function handleUpdatedDateRangeChange(range) {
|
|
updatedDateRange.value = range;
|
|
if (range && range.length === 2) {
|
|
queryFormData.updated_time = [formatToDateTime(range[0]), formatToDateTime(range[1])];
|
|
} else {
|
|
queryFormData.updated_time = void 0;
|
|
}
|
|
}
|
|
async function handleRefresh() {
|
|
await loadingData();
|
|
}
|
|
async function loadingData() {
|
|
loading.value = true;
|
|
try {
|
|
const response = await JobAPI.listJob(queryFormData);
|
|
pageTableData.value = response.data.data.items;
|
|
total.value = response.data.data.total;
|
|
} catch (error) {
|
|
console.error(error);
|
|
} finally {
|
|
loading.value = false;
|
|
}
|
|
}
|
|
async function handleQuery() {
|
|
queryFormData.page_no = 1;
|
|
loadingData();
|
|
}
|
|
function handleConfirm() {
|
|
handleQuery();
|
|
}
|
|
async function handleResetQuery() {
|
|
queryFormRef.value.resetFields();
|
|
queryFormData.page_no = 1;
|
|
createdDateRange.value = [];
|
|
queryFormData.created_time = void 0;
|
|
updatedDateRange.value = [];
|
|
queryFormData.updated_time = void 0;
|
|
loadingData();
|
|
}
|
|
const initialFormData = {
|
|
id: void 0,
|
|
name: void 0,
|
|
func: void 0,
|
|
trigger: void 0,
|
|
args: void 0,
|
|
kwargs: void 0,
|
|
coalesce: false,
|
|
max_instances: 1,
|
|
jobstore: void 0,
|
|
executor: void 0,
|
|
trigger_args: void 0,
|
|
start_date: void 0,
|
|
end_date: void 0,
|
|
status: void 0,
|
|
description: void 0
|
|
};
|
|
async function resetForm() {
|
|
if (dataFormRef.value) {
|
|
dataFormRef.value.resetFields();
|
|
dataFormRef.value.clearValidate();
|
|
}
|
|
Object.assign(formData, initialFormData);
|
|
}
|
|
async function handleSelectionChange(selection) {
|
|
selectIds.value = selection.map((item) => item.id);
|
|
selectionRows.value = selection;
|
|
}
|
|
async function handleCloseDialog() {
|
|
dialogVisible.visible = false;
|
|
resetForm();
|
|
}
|
|
async function handleOpenDialog(type, id) {
|
|
dialogVisible.type = type;
|
|
if (id) {
|
|
const response = await JobAPI.detailJob(id);
|
|
if (type === "detail") {
|
|
dialogVisible.title = "任务详情";
|
|
Object.assign(detailFormData.value, response.data.data);
|
|
} else if (type === "update") {
|
|
dialogVisible.title = "修改任务";
|
|
Object.assign(formData, response.data.data);
|
|
}
|
|
} else {
|
|
dialogVisible.title = "新增任务";
|
|
formData.id = void 0;
|
|
}
|
|
dialogVisible.visible = true;
|
|
}
|
|
async function handleSubmit() {
|
|
dataFormRef.value.validate(async (valid) => {
|
|
if (valid) {
|
|
loading.value = true;
|
|
const id = formData.id;
|
|
if (id) {
|
|
try {
|
|
await JobAPI.updateJob(id, formData);
|
|
dialogVisible.visible = false;
|
|
resetForm();
|
|
handleCloseDialog();
|
|
handleResetQuery();
|
|
} catch (error) {
|
|
console.log(error);
|
|
} finally {
|
|
loading.value = false;
|
|
}
|
|
} else {
|
|
try {
|
|
await JobAPI.createJob(formData);
|
|
dialogVisible.visible = false;
|
|
resetForm();
|
|
handleCloseDialog();
|
|
handleResetQuery();
|
|
} catch (error) {
|
|
console.log(error);
|
|
} finally {
|
|
loading.value = false;
|
|
}
|
|
}
|
|
}
|
|
});
|
|
}
|
|
async function handleDelete(ids) {
|
|
ElMessageBox.confirm("确认删除该项数据?", "警告", {
|
|
confirmButtonText: "确定",
|
|
cancelButtonText: "取消",
|
|
type: "warning"
|
|
}).then(async () => {
|
|
try {
|
|
loading.value = true;
|
|
await JobAPI.deleteJob(ids);
|
|
handleResetQuery();
|
|
} catch (error) {
|
|
console.error(error);
|
|
} finally {
|
|
loading.value = false;
|
|
}
|
|
}).catch(() => {
|
|
ElMessageBox.close();
|
|
});
|
|
}
|
|
async function handleOpenExportsModal() {
|
|
exportsDialogVisible.value = true;
|
|
}
|
|
function handleIntervalConfirm(interval) {
|
|
formData.trigger_args = interval;
|
|
openIntervalTab.value = false;
|
|
}
|
|
const handlechangeCron = (cronStr) => {
|
|
if (typeof cronStr == "string") {
|
|
formData.trigger_args = cronStr;
|
|
}
|
|
};
|
|
const handleClear = () => {
|
|
ElMessageBox.confirm("是否确认清空所有定时任务数据?", "警告", {
|
|
confirmButtonText: "确定",
|
|
cancelButtonText: "取消",
|
|
type: "warning"
|
|
}).then(async () => {
|
|
try {
|
|
loading.value = true;
|
|
await JobAPI.clearJob();
|
|
handleResetQuery();
|
|
} catch (error) {
|
|
console.error(error);
|
|
} finally {
|
|
loading.value = false;
|
|
}
|
|
}).catch(() => {
|
|
ElMessageBox.close();
|
|
});
|
|
};
|
|
const handleOption = (id, option) => {
|
|
JobAPI.OptionJob({ id, option }).then(() => {
|
|
loadingData();
|
|
});
|
|
};
|
|
const currentJobId = ref(0);
|
|
const currentJobName = ref("");
|
|
function handleOpenLogDrawer(jobId, jobName) {
|
|
currentJobId.value = jobId;
|
|
currentJobName.value = jobName;
|
|
drawerVisible.value = true;
|
|
}
|
|
const handleRunJob = (id) => {
|
|
JobAPI.runJob(id).then(() => {
|
|
loadingData();
|
|
});
|
|
};
|
|
const exportColumns = [
|
|
{ prop: "name", label: "任务名称" },
|
|
{ prop: "func", label: "执行函数" },
|
|
{ prop: "trigger", label: "触发器" },
|
|
{ prop: "jobstore", label: "存储器" },
|
|
{ prop: "executor", label: "执行器" },
|
|
{ prop: "coalesce", label: "并发执行" },
|
|
{ prop: "status", label: "状态" },
|
|
{ prop: "description", label: "描述" },
|
|
{ prop: "created_time", label: "创建时间" },
|
|
{ prop: "updated_time", label: "更新时间" }
|
|
];
|
|
const curdContentConfig = {
|
|
permPrefix: "module_application:job",
|
|
cols: exportColumns,
|
|
exportsAction: async (params) => {
|
|
var _a, _b, _c, _d;
|
|
const query = { ...params };
|
|
if (typeof query.status === "string") query.status = query.status === "true";
|
|
query.page_no = 1;
|
|
query.page_size = 1e3;
|
|
const all = [];
|
|
while (true) {
|
|
const res = await JobAPI.listJob(query);
|
|
const items = ((_b = (_a = res.data) == null ? void 0 : _a.data) == null ? void 0 : _b.items) || [];
|
|
const total2 = ((_d = (_c = res.data) == null ? void 0 : _c.data) == null ? void 0 : _d.total) || 0;
|
|
all.push(...items);
|
|
if (all.length >= total2 || items.length === 0) break;
|
|
query.page_no += 1;
|
|
}
|
|
return all;
|
|
}
|
|
};
|
|
onMounted(async () => {
|
|
await dictStore.getDict([
|
|
"sys_job_function",
|
|
"sys_job_executor",
|
|
"sys_job_store",
|
|
"sys_job_trigger"
|
|
]);
|
|
loadingData();
|
|
});
|
|
return (_ctx, _cache) => {
|
|
const _component_el_input = ElInput;
|
|
const _component_el_form_item = ElFormItem;
|
|
const _component_el_option = ElOption;
|
|
const _component_el_select = ElSelect;
|
|
const _component_DatePicker = DatePicker;
|
|
const _component_UserTableSelect = _sfc_main$3;
|
|
const _component_el_button = ElButton;
|
|
const _component_ArrowUp = resolveComponent("ArrowUp");
|
|
const _component_ArrowDown = resolveComponent("ArrowDown");
|
|
const _component_el_icon = ElIcon;
|
|
const _component_el_link = ElLink;
|
|
const _component_el_form = ElForm;
|
|
const _component_QuestionFilled = resolveComponent("QuestionFilled");
|
|
const _component_el_tooltip = ElTooltip;
|
|
const _component_el_col = ElCol;
|
|
const _component_el_row = ElRow;
|
|
const _component_el_empty = ElEmpty;
|
|
const _component_el_table_column = ElTableColumn;
|
|
const _component_el_tag = ElTag;
|
|
const _component_el_dropdown_item = ElDropdownItem;
|
|
const _component_el_dropdown_menu = ElDropdownMenu;
|
|
const _component_el_dropdown = ElDropdown;
|
|
const _component_el_table = ElTable;
|
|
const _component_pagination = __unplugin_components_19;
|
|
const _component_el_card = ElCard;
|
|
const _component_el_descriptions_item = ElDescriptionsItem;
|
|
const _component_el_descriptions = ElDescriptions;
|
|
const _component_el_radio = ElRadio;
|
|
const _component_el_radio_group = ElRadioGroup;
|
|
const _component_el_input_number = ElInputNumber;
|
|
const _component_el_date_picker = ElDatePicker;
|
|
const _component_el_popover = ElPopover;
|
|
const _component_el_dialog = ElDialog;
|
|
const _directive_hasPerm = resolveDirective("hasPerm");
|
|
const _directive_loading = vLoading;
|
|
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
createBaseVNode("div", _hoisted_2, [
|
|
createVNode(_component_el_form, {
|
|
ref_key: "queryFormRef",
|
|
ref: queryFormRef,
|
|
model: unref(queryFormData),
|
|
inline: true,
|
|
"label-suffix": ":",
|
|
onSubmit: withModifiers(handleQuery, ["prevent"])
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_form_item, {
|
|
prop: "name",
|
|
label: "任务名称"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_input, {
|
|
modelValue: unref(queryFormData).name,
|
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => unref(queryFormData).name = $event),
|
|
placeholder: "请输入任务名称",
|
|
clearable: ""
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
prop: "status",
|
|
label: "状态"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(queryFormData).status,
|
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => unref(queryFormData).status = $event),
|
|
placeholder: "请选择状态",
|
|
clearable: "",
|
|
style: { "width": "167.5px" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_option, {
|
|
value: "0",
|
|
label: "运行中"
|
|
}),
|
|
createVNode(_component_el_option, {
|
|
value: "1",
|
|
label: "暂停"
|
|
})
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
unref(isExpand) ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 0,
|
|
prop: "created_time",
|
|
label: "创建时间"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_DatePicker, {
|
|
modelValue: unref(createdDateRange),
|
|
"onUpdate:modelValue": [
|
|
_cache[2] || (_cache[2] = ($event) => isRef(createdDateRange) ? createdDateRange.value = $event : null),
|
|
handleCreatedDateRangeChange
|
|
]
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true),
|
|
unref(isExpand) ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 1,
|
|
prop: "updated_time",
|
|
label: "更新时间"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_DatePicker, {
|
|
modelValue: unref(updatedDateRange),
|
|
"onUpdate:modelValue": [
|
|
_cache[3] || (_cache[3] = ($event) => isRef(updatedDateRange) ? updatedDateRange.value = $event : null),
|
|
handleUpdatedDateRangeChange
|
|
]
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true),
|
|
unref(isExpand) ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 2,
|
|
prop: "created_id",
|
|
label: "创建人"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_UserTableSelect, {
|
|
modelValue: unref(queryFormData).created_id,
|
|
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => unref(queryFormData).created_id = $event),
|
|
onConfirmClick: handleConfirm,
|
|
onClearClick: handleQuery
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true),
|
|
unref(isExpand) ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 3,
|
|
prop: "updated_id",
|
|
label: "更新人"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_UserTableSelect, {
|
|
modelValue: unref(queryFormData).updated_id,
|
|
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => unref(queryFormData).updated_id = $event),
|
|
onConfirmClick: handleConfirm,
|
|
onClearClick: handleQuery
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true),
|
|
createVNode(_component_el_form_item, { class: "search-buttons" }, {
|
|
default: withCtx(() => [
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
type: "primary",
|
|
icon: "search",
|
|
"native-type": "submit"
|
|
}, {
|
|
default: withCtx(() => [..._cache[34] || (_cache[34] = [
|
|
createTextVNode(" 查询 ", -1)
|
|
])]),
|
|
_: 1
|
|
})), [
|
|
[_directive_hasPerm, ["module_application:job:query"]]
|
|
]),
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
icon: "refresh",
|
|
onClick: handleResetQuery
|
|
}, {
|
|
default: withCtx(() => [..._cache[35] || (_cache[35] = [
|
|
createTextVNode(" 重置 ", -1)
|
|
])]),
|
|
_: 1
|
|
})), [
|
|
[_directive_hasPerm, ["module_application:job:query"]]
|
|
]),
|
|
unref(isExpandable) ? (openBlock(), createBlock(_component_el_link, {
|
|
key: 0,
|
|
class: "ml-3",
|
|
type: "primary",
|
|
underline: "never",
|
|
onClick: _cache[6] || (_cache[6] = ($event) => isExpand.value = !unref(isExpand))
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(isExpand) ? "收起" : "展开") + " ", 1),
|
|
createVNode(_component_el_icon, null, {
|
|
default: withCtx(() => [
|
|
unref(isExpand) ? (openBlock(), createBlock(_component_ArrowUp, { key: 0 })) : (openBlock(), createBlock(_component_ArrowDown, { key: 1 }))
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true)
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
}, 8, ["model"])
|
|
]),
|
|
createVNode(_component_el_card, { class: "data-table" }, {
|
|
header: withCtx(() => [
|
|
createBaseVNode("div", _hoisted_3, [
|
|
createBaseVNode("span", null, [
|
|
createVNode(_component_el_tooltip, { content: "定时任务列表" }, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_QuestionFilled, { class: "w-4 h-4 mx-1" })
|
|
]),
|
|
_: 1
|
|
}),
|
|
_cache[36] || (_cache[36] = createTextVNode(" 定时任务列表 ", -1))
|
|
])
|
|
])
|
|
]),
|
|
footer: withCtx(() => [
|
|
createVNode(_component_pagination, {
|
|
total: unref(total),
|
|
"onUpdate:total": _cache[9] || (_cache[9] = ($event) => isRef(total) ? total.value = $event : null),
|
|
page: unref(queryFormData).page_no,
|
|
"onUpdate:page": _cache[10] || (_cache[10] = ($event) => unref(queryFormData).page_no = $event),
|
|
limit: unref(queryFormData).page_size,
|
|
"onUpdate:limit": _cache[11] || (_cache[11] = ($event) => unref(queryFormData).page_size = $event),
|
|
onPagination: loadingData
|
|
}, null, 8, ["total", "page", "limit"])
|
|
]),
|
|
default: withCtx(() => [
|
|
createBaseVNode("div", _hoisted_4, [
|
|
createBaseVNode("div", _hoisted_5, [
|
|
createVNode(_component_el_row, { gutter: 10 }, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_col, { span: 1.5 }, {
|
|
default: withCtx(() => [
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
type: "success",
|
|
icon: "plus",
|
|
onClick: _cache[7] || (_cache[7] = ($event) => handleOpenDialog("create"))
|
|
}, {
|
|
default: withCtx(() => [..._cache[37] || (_cache[37] = [
|
|
createTextVNode(" 新增 ", -1)
|
|
])]),
|
|
_: 1
|
|
})), [
|
|
[_directive_hasPerm, ["module_application:job:create"]]
|
|
])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_col, { span: 1.5 }, {
|
|
default: withCtx(() => [
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
type: "danger",
|
|
icon: "delete",
|
|
disabled: unref(selectIds).length === 0,
|
|
onClick: _cache[8] || (_cache[8] = ($event) => handleDelete(unref(selectIds)))
|
|
}, {
|
|
default: withCtx(() => [..._cache[38] || (_cache[38] = [
|
|
createTextVNode(" 批量删除 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["disabled"])), [
|
|
[_directive_hasPerm, ["module_application:job:delete"]]
|
|
])
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
createBaseVNode("div", _hoisted_6, [
|
|
createVNode(_component_el_row, { gutter: 10 }, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_col, { span: 1.5 }, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_tooltip, { content: "导出" }, {
|
|
default: withCtx(() => [
|
|
withDirectives(createVNode(_component_el_button, {
|
|
type: "warning",
|
|
icon: "download",
|
|
circle: "",
|
|
onClick: handleOpenExportsModal
|
|
}, null, 512), [
|
|
[_directive_hasPerm, ["module_application:job:export"]]
|
|
])
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_col, { span: 1.5 }, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_tooltip, { content: "清除" }, {
|
|
default: withCtx(() => [
|
|
withDirectives(createVNode(_component_el_button, {
|
|
type: "danger",
|
|
icon: "delete",
|
|
circle: "",
|
|
onClick: handleClear
|
|
}, null, 512), [
|
|
[_directive_hasPerm, ["module_application:job:delete"]]
|
|
])
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_col, { span: 1.5 }, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_tooltip, { content: "刷新" }, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_button, {
|
|
type: "primary",
|
|
icon: "refresh",
|
|
circle: "",
|
|
onClick: handleRefresh
|
|
})
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
})
|
|
])
|
|
]),
|
|
withDirectives((openBlock(), createBlock(_component_el_table, {
|
|
ref: "dataTableRef",
|
|
data: unref(pageTableData),
|
|
class: "data-table__content",
|
|
"highlight-current-row": "",
|
|
height: "500",
|
|
"max-height": "500",
|
|
border: "",
|
|
stripe: "",
|
|
onSelectionChange: handleSelectionChange
|
|
}, {
|
|
empty: withCtx(() => [
|
|
createVNode(_component_el_empty, {
|
|
"image-size": 80,
|
|
description: "暂无数据"
|
|
})
|
|
]),
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_table_column, {
|
|
type: "selection",
|
|
align: "center",
|
|
"min-width": "55"
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
type: "index",
|
|
fixed: "",
|
|
label: "序号",
|
|
"min-width": "60"
|
|
}, {
|
|
default: withCtx((scope) => [
|
|
createTextVNode(toDisplayString((unref(queryFormData).page_no - 1) * unref(queryFormData).page_size + scope.$index + 1), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "任务名称",
|
|
prop: "name",
|
|
"min-width": "140"
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "执行函数",
|
|
prop: "func",
|
|
"min-width": "140"
|
|
}, {
|
|
default: withCtx((scope) => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString(((_a = unref(dictStore).getDictLabel("sys_job_function", scope.row.func)) == null ? void 0 : _a.dict_label) || scope.row.func), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "触发器",
|
|
prop: "trigger",
|
|
"min-width": "100",
|
|
"show-overflow-tooltip": ""
|
|
}, {
|
|
default: withCtx((scope) => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString((_a = unref(dictStore).getDictLabel("sys_job_trigger", scope.row.trigger)) == null ? void 0 : _a.dict_label), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "存储器",
|
|
prop: "jobstore",
|
|
"min-width": "120",
|
|
"show-overflow-tooltip": ""
|
|
}, {
|
|
default: withCtx((scope) => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString((_a = unref(dictStore).getDictLabel("sys_job_store", scope.row.jobstore)) == null ? void 0 : _a.dict_label), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "执行器",
|
|
prop: "executor",
|
|
"min-width": "100"
|
|
}, {
|
|
default: withCtx((scope) => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString((_a = unref(dictStore).getDictLabel("sys_job_executor", scope.row.executor)) == null ? void 0 : _a.dict_label), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "并发执行",
|
|
prop: "coalesce",
|
|
"min-width": "100"
|
|
}, {
|
|
default: withCtx((scope) => [
|
|
createVNode(_component_el_tag, {
|
|
type: scope.row.coalesce === true ? "success" : "danger"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(scope.row.coalesce === true ? "是" : "否"), 1)
|
|
]),
|
|
_: 2
|
|
}, 1032, ["type"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "状态",
|
|
prop: "status",
|
|
"min-width": "100"
|
|
}, {
|
|
default: withCtx((scope) => [
|
|
createVNode(_component_el_tag, {
|
|
type: scope.row.status === "0" ? "success" : "danger"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(scope.row.status === "0" ? "运行中" : "暂停"), 1)
|
|
]),
|
|
_: 2
|
|
}, 1032, ["type"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "描述",
|
|
prop: "description",
|
|
"min-width": "100"
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "创建时间",
|
|
prop: "created_time",
|
|
"min-width": "200",
|
|
sortable: ""
|
|
}),
|
|
createVNode(_component_el_table_column, {
|
|
label: "更新时间",
|
|
prop: "updated_time",
|
|
"min-width": "200",
|
|
sortable: ""
|
|
}),
|
|
createVNode(_sfc_main$1, {
|
|
"list-data-length": unref(pageTableData).length
|
|
}, {
|
|
default: withCtx((scope) => [
|
|
createBaseVNode("div", _hoisted_7, [
|
|
createVNode(_component_el_button, {
|
|
type: "warning",
|
|
size: "small",
|
|
link: "",
|
|
icon: "document",
|
|
onClick: ($event) => handleOpenLogDrawer(scope.row.id, scope.row.name)
|
|
}, {
|
|
default: withCtx(() => [..._cache[39] || (_cache[39] = [
|
|
createTextVNode(" 日志 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["onClick"]),
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
type: "primary",
|
|
size: "small",
|
|
link: "",
|
|
icon: "smoking",
|
|
onClick: ($event) => handleRunJob(scope.row.id)
|
|
}, {
|
|
default: withCtx(() => [..._cache[40] || (_cache[40] = [
|
|
createTextVNode(" 立即执行 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["onClick"])), [
|
|
[_directive_hasPerm, ["module_application:job:update"]]
|
|
]),
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
type: "info",
|
|
size: "small",
|
|
link: "",
|
|
icon: "document",
|
|
onClick: ($event) => handleOpenDialog("detail", scope.row.id)
|
|
}, {
|
|
default: withCtx(() => [..._cache[41] || (_cache[41] = [
|
|
createTextVNode(" 详情 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["onClick"])), [
|
|
[_directive_hasPerm, ["module_application:job:detail"]]
|
|
]),
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
type: "primary",
|
|
size: "small",
|
|
link: "",
|
|
icon: "edit",
|
|
onClick: ($event) => handleOpenDialog("update", scope.row.id)
|
|
}, {
|
|
default: withCtx(() => [..._cache[42] || (_cache[42] = [
|
|
createTextVNode(" 编辑 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["onClick"])), [
|
|
[_directive_hasPerm, ["module_application:job:update"]]
|
|
]),
|
|
withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
type: "danger",
|
|
size: "small",
|
|
link: "",
|
|
icon: "delete",
|
|
onClick: ($event) => handleDelete([scope.row.id])
|
|
}, {
|
|
default: withCtx(() => [..._cache[43] || (_cache[43] = [
|
|
createTextVNode(" 删除 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["onClick"])), [
|
|
[_directive_hasPerm, ["module_application:job:delete"]]
|
|
]),
|
|
withDirectives((openBlock(), createBlock(_component_el_dropdown, { trigger: "click" }, {
|
|
dropdown: withCtx(() => [
|
|
createVNode(_component_el_dropdown_menu, null, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_dropdown_item, {
|
|
disabled: scope.row.status === "1",
|
|
icon: "Check",
|
|
onClick: ($event) => handleOption(scope.row.id, 1)
|
|
}, {
|
|
default: withCtx(() => [..._cache[45] || (_cache[45] = [
|
|
createTextVNode(" 暂停 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["disabled", "onClick"]),
|
|
createVNode(_component_el_dropdown_item, {
|
|
disabled: scope.row.status === "0",
|
|
icon: "CircleClose",
|
|
onClick: ($event) => handleOption(scope.row.id, 2)
|
|
}, {
|
|
default: withCtx(() => [..._cache[46] || (_cache[46] = [
|
|
createTextVNode(" 恢复 ", -1)
|
|
])]),
|
|
_: 1
|
|
}, 8, ["disabled", "onClick"])
|
|
]),
|
|
_: 2
|
|
}, 1024)
|
|
]),
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_button, {
|
|
type: "warning",
|
|
size: "small",
|
|
link: "",
|
|
icon: "ArrowDown"
|
|
}, {
|
|
default: withCtx(() => [..._cache[44] || (_cache[44] = [
|
|
createTextVNode("更多", -1)
|
|
])]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 2
|
|
}, 1024)), [
|
|
[_directive_hasPerm, ["module_application:job:update"]]
|
|
])
|
|
])
|
|
]),
|
|
_: 1
|
|
}, 8, ["list-data-length"])
|
|
]),
|
|
_: 1
|
|
}, 8, ["data"])), [
|
|
[_directive_loading, unref(loading)]
|
|
])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_dialog, {
|
|
modelValue: unref(dialogVisible).visible,
|
|
"onUpdate:modelValue": _cache[31] || (_cache[31] = ($event) => unref(dialogVisible).visible = $event),
|
|
title: unref(dialogVisible).title,
|
|
onClose: handleCloseDialog
|
|
}, {
|
|
footer: withCtx(() => [
|
|
createBaseVNode("div", _hoisted_8, [
|
|
createVNode(_component_el_button, { onClick: handleCloseDialog }, {
|
|
default: withCtx(() => [..._cache[49] || (_cache[49] = [
|
|
createTextVNode("取消", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
unref(dialogVisible).type !== "detail" ? (openBlock(), createBlock(_component_el_button, {
|
|
key: 0,
|
|
type: "primary",
|
|
onClick: handleSubmit
|
|
}, {
|
|
default: withCtx(() => [..._cache[50] || (_cache[50] = [
|
|
createTextVNode(" 确定 ", -1)
|
|
])]),
|
|
_: 1
|
|
})) : withDirectives((openBlock(), createBlock(_component_el_button, {
|
|
key: 1,
|
|
type: "primary",
|
|
onClick: handleCloseDialog
|
|
}, {
|
|
default: withCtx(() => [..._cache[51] || (_cache[51] = [
|
|
createTextVNode(" 确定 ", -1)
|
|
])]),
|
|
_: 1
|
|
})), [
|
|
[_directive_hasPerm, ["module_application:job:query"]]
|
|
])
|
|
])
|
|
]),
|
|
default: withCtx(() => [
|
|
unref(dialogVisible).type === "detail" ? (openBlock(), createBlock(_component_el_descriptions, {
|
|
key: 0,
|
|
column: 4,
|
|
border: ""
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "序号",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).id), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "任务名称",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).name), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "任务函数",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString(((_a = unref(detailFormData).func ? unref(dictStore).getDictLabel("sys_job_function", unref(detailFormData).func) : void 0) == null ? void 0 : _a.dict_label) || unref(detailFormData).func), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "存储器",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString(((_a = unref(detailFormData).jobstore ? unref(dictStore).getDictLabel("sys_job_store", unref(detailFormData).jobstore) : void 0) == null ? void 0 : _a.dict_label) || unref(detailFormData).jobstore), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "执行器",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString(((_a = unref(detailFormData).executor ? unref(dictStore).getDictLabel("sys_job_executor", unref(detailFormData).executor) : void 0) == null ? void 0 : _a.dict_label) || unref(detailFormData).executor), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "触发器",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString(((_a = unref(detailFormData).trigger ? unref(dictStore).getDictLabel("sys_job_trigger", unref(detailFormData).trigger) : void 0) == null ? void 0 : _a.dict_label) || unref(detailFormData).trigger), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "位置参数",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).args), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "关键字参数",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).kwargs), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "并发执行",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_tag, {
|
|
type: unref(detailFormData).coalesce ? "success" : "danger"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).coalesce ? "是" : "否"), 1)
|
|
]),
|
|
_: 1
|
|
}, 8, ["type"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "状态",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_tag, {
|
|
type: unref(detailFormData).status === "0" ? "success" : "danger"
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).status === "0" ? "运行中" : "暂停"), 1)
|
|
]),
|
|
_: 1
|
|
}, 8, ["type"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "最大实例数",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).max_instances), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "触发器参数",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).trigger_args), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "开始时间",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).start_date), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "结束时间",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).end_date), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "创建人",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => {
|
|
var _a;
|
|
return [
|
|
createTextVNode(toDisplayString((_a = unref(detailFormData).created_by) == null ? void 0 : _a.name), 1)
|
|
];
|
|
}),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "创建时间",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).created_time), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "更新时间",
|
|
span: 2
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).updated_time), 1)
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_descriptions_item, {
|
|
label: "描述",
|
|
span: 4
|
|
}, {
|
|
default: withCtx(() => [
|
|
createTextVNode(toDisplayString(unref(detailFormData).description), 1)
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
})) : (openBlock(), createBlock(_component_el_form, {
|
|
key: 1,
|
|
ref_key: "dataFormRef",
|
|
ref: dataFormRef,
|
|
model: unref(formData),
|
|
rules: unref(rules),
|
|
"label-suffix": ":",
|
|
"label-width": "auto",
|
|
inline: ""
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_form_item, {
|
|
label: "任务名称",
|
|
prop: "name",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_input, {
|
|
modelValue: unref(formData).name,
|
|
"onUpdate:modelValue": _cache[12] || (_cache[12] = ($event) => unref(formData).name = $event),
|
|
placeholder: "请输入任务名称",
|
|
maxlength: 50
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "任务函数",
|
|
prop: "func",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(formData).func,
|
|
"onUpdate:modelValue": _cache[13] || (_cache[13] = ($event) => unref(formData).func = $event),
|
|
placeholder: "请选择任务函数"
|
|
}, {
|
|
default: withCtx(() => [
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(dictStore).getDictArray("sys_job_function"), (item) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: item.dict_value,
|
|
label: item.dict_label,
|
|
value: item.dict_value
|
|
}, null, 8, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "存储器",
|
|
prop: "jobstore",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(formData).jobstore,
|
|
"onUpdate:modelValue": _cache[14] || (_cache[14] = ($event) => unref(formData).jobstore = $event),
|
|
placeholder: "请选择存储器"
|
|
}, {
|
|
default: withCtx(() => [
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(dictStore).getDictArray("sys_job_store"), (item) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: item.dict_value,
|
|
label: item.dict_label,
|
|
value: item.dict_value
|
|
}, null, 8, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "执行器",
|
|
prop: "executor",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(formData).executor,
|
|
"onUpdate:modelValue": _cache[15] || (_cache[15] = ($event) => unref(formData).executor = $event),
|
|
placeholder: "请选择执行器"
|
|
}, {
|
|
default: withCtx(() => [
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(dictStore).getDictArray("sys_job_executor"), (item) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: item.dict_value,
|
|
label: item.dict_label,
|
|
value: item.dict_value
|
|
}, null, 8, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "位置参数",
|
|
prop: "args",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_input, {
|
|
modelValue: unref(formData).args,
|
|
"onUpdate:modelValue": _cache[16] || (_cache[16] = ($event) => unref(formData).args = $event),
|
|
placeholder: "请输入位置参数",
|
|
maxlength: 50
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "关键字参数",
|
|
prop: "kwargs",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_input, {
|
|
modelValue: unref(formData).kwargs,
|
|
"onUpdate:modelValue": _cache[17] || (_cache[17] = ($event) => unref(formData).kwargs = $event),
|
|
placeholder: "请输入关键字参数",
|
|
maxlength: 50
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "并发执行",
|
|
prop: "coalesce",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_radio_group, {
|
|
modelValue: unref(formData).coalesce,
|
|
"onUpdate:modelValue": _cache[18] || (_cache[18] = ($event) => unref(formData).coalesce = $event)
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_radio, { value: true }, {
|
|
default: withCtx(() => [..._cache[47] || (_cache[47] = [
|
|
createTextVNode("是", -1)
|
|
])]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_radio, { value: false }, {
|
|
default: withCtx(() => [..._cache[48] || (_cache[48] = [
|
|
createTextVNode("否", -1)
|
|
])]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "最大实例数",
|
|
prop: "max_instances",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_input_number, {
|
|
modelValue: unref(formData).max_instances,
|
|
"onUpdate:modelValue": _cache[19] || (_cache[19] = ($event) => unref(formData).max_instances = $event),
|
|
"controls-position": "right",
|
|
min: 1,
|
|
max: 10
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
createVNode(_component_el_form_item, {
|
|
label: "触发器",
|
|
prop: "trigger",
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_select, {
|
|
modelValue: unref(formData).trigger,
|
|
"onUpdate:modelValue": _cache[20] || (_cache[20] = ($event) => unref(formData).trigger = $event),
|
|
placeholder: "请选择触发器"
|
|
}, {
|
|
default: withCtx(() => [
|
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(dictStore).getDictArray("sys_job_trigger"), (item) => {
|
|
return openBlock(), createBlock(_component_el_option, {
|
|
key: item.dict_value,
|
|
label: item.dict_label,
|
|
value: item.dict_value
|
|
}, null, 8, ["label", "value"]);
|
|
}), 128))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
}),
|
|
unref(formData).trigger === "date" ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 0,
|
|
label: "运行日期",
|
|
prop: "trigger_args",
|
|
rules: [{ required: true, message: "请选择运行日期" }],
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_date_picker, {
|
|
modelValue: unref(formData).trigger_args,
|
|
"onUpdate:modelValue": _cache[21] || (_cache[21] = ($event) => unref(formData).trigger_args = $event),
|
|
type: "datetime",
|
|
format: "YYYY-MM-DD HH:mm:ss",
|
|
"value-format": "YYYY-MM-DD HH:mm:ss",
|
|
placeholder: "请选择运行日期"
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})) : unref(formData).trigger === "interval" ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 1,
|
|
label: "间隔时间",
|
|
prop: "trigger_args",
|
|
rules: [{ required: true, message: "请输入间隔时间", trigger: "change" }],
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_popover, {
|
|
visible: unref(openIntervalTab),
|
|
width: "600px",
|
|
trigger: "click",
|
|
persistent: false
|
|
}, {
|
|
reference: withCtx(() => [
|
|
createVNode(_component_el_input, {
|
|
modelValue: unref(formData).trigger_args,
|
|
"onUpdate:modelValue": _cache[22] || (_cache[22] = ($event) => unref(formData).trigger_args = $event),
|
|
placeholder: "请输入 秒-分-时-天-周",
|
|
readonly: "",
|
|
onClick: _cache[23] || (_cache[23] = ($event) => openIntervalTab.value = true)
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
default: withCtx(() => [
|
|
createVNode(IntervalTab, {
|
|
ref_key: "intervalTabRef",
|
|
ref: intervalTabRef,
|
|
"cron-value": unref(formData).trigger_args,
|
|
onConfirm: handleIntervalConfirm,
|
|
onCancel: _cache[24] || (_cache[24] = ($event) => openIntervalTab.value = false)
|
|
}, null, 8, ["cron-value"])
|
|
]),
|
|
_: 1
|
|
}, 8, ["visible"])
|
|
]),
|
|
_: 1
|
|
})) : unref(formData).trigger === "cron" ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 2,
|
|
label: "Cron表达式",
|
|
prop: "trigger_args",
|
|
rules: [
|
|
{
|
|
required: true,
|
|
message: "请输入Cron表达式",
|
|
trigger: "change"
|
|
}
|
|
],
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_popover, {
|
|
visible: unref(openCron),
|
|
width: "600px",
|
|
trigger: "click",
|
|
persistent: false,
|
|
placement: "left"
|
|
}, {
|
|
reference: withCtx(() => [
|
|
createVNode(_component_el_input, {
|
|
modelValue: unref(formData).trigger_args,
|
|
"onUpdate:modelValue": _cache[25] || (_cache[25] = ($event) => unref(formData).trigger_args = $event),
|
|
placeholder: "请输入 * * * * * ? *",
|
|
onClick: _cache[26] || (_cache[26] = ($event) => openCron.value = true)
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
default: withCtx(() => [
|
|
createVNode(unref(index_umd_minExports.vue3CronPlus), {
|
|
i18n: "cn",
|
|
onChange: handlechangeCron,
|
|
onClose: _cache[27] || (_cache[27] = ($event) => openCron.value = false)
|
|
})
|
|
]),
|
|
_: 1
|
|
}, 8, ["visible"])
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true),
|
|
unref(formData).trigger && unref(formData).trigger != "date" ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 3,
|
|
label: "开始日期",
|
|
prop: "start_date",
|
|
rules: [{ required: false, message: "请选择开始日期", trigger: "blur" }],
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_date_picker, {
|
|
modelValue: unref(formData).start_date,
|
|
"onUpdate:modelValue": _cache[28] || (_cache[28] = ($event) => unref(formData).start_date = $event),
|
|
type: "datetime",
|
|
format: "YYYY-MM-DD HH:mm:ss",
|
|
"value-format": "YYYY-MM-DD HH:mm:ss",
|
|
placeholder: "请选择开始日期"
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true),
|
|
unref(formData).trigger && unref(formData).trigger != "date" ? (openBlock(), createBlock(_component_el_form_item, {
|
|
key: 4,
|
|
label: "结束日期",
|
|
prop: "end_date",
|
|
rules: [{ required: false, message: "请选择结束日期", trigger: "blur" }],
|
|
style: { "width": "40%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_date_picker, {
|
|
modelValue: unref(formData).end_date,
|
|
"onUpdate:modelValue": _cache[29] || (_cache[29] = ($event) => unref(formData).end_date = $event),
|
|
type: "datetime",
|
|
format: "YYYY-MM-DD HH:mm:ss",
|
|
"value-format": "YYYY-MM-DD HH:mm:ss",
|
|
placeholder: "请选择结束日期"
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})) : createCommentVNode("", true),
|
|
createVNode(_component_el_form_item, {
|
|
label: "描述",
|
|
prop: "description",
|
|
style: { "width": "85%" }
|
|
}, {
|
|
default: withCtx(() => [
|
|
createVNode(_component_el_input, {
|
|
modelValue: unref(formData).description,
|
|
"onUpdate:modelValue": _cache[30] || (_cache[30] = ($event) => unref(formData).description = $event),
|
|
rows: 4,
|
|
maxlength: 100,
|
|
"show-word-limit": "",
|
|
type: "textarea",
|
|
placeholder: "请输入描述"
|
|
}, null, 8, ["modelValue"])
|
|
]),
|
|
_: 1
|
|
})
|
|
]),
|
|
_: 1
|
|
}, 8, ["model", "rules"]))
|
|
]),
|
|
_: 1
|
|
}, 8, ["modelValue", "title"]),
|
|
unref(drawerVisible) ? (openBlock(), createBlock(_sfc_main$4, {
|
|
key: 0,
|
|
modelValue: unref(drawerVisible),
|
|
"onUpdate:modelValue": _cache[32] || (_cache[32] = ($event) => isRef(drawerVisible) ? drawerVisible.value = $event : null),
|
|
"job-id": unref(currentJobId),
|
|
"job-name": unref(currentJobName)
|
|
}, null, 8, ["modelValue", "job-id", "job-name"])) : createCommentVNode("", true),
|
|
createVNode(_sfc_main$5, {
|
|
modelValue: unref(exportsDialogVisible),
|
|
"onUpdate:modelValue": _cache[33] || (_cache[33] = ($event) => isRef(exportsDialogVisible) ? exportsDialogVisible.value = $event : null),
|
|
"content-config": curdContentConfig,
|
|
"query-params": unref(queryFormData),
|
|
"page-data": unref(pageTableData),
|
|
"selection-data": unref(selectionRows)
|
|
}, null, 8, ["modelValue", "query-params", "page-data", "selection-data"])
|
|
]);
|
|
};
|
|
}
|
|
});
|
|
export {
|
|
_sfc_main as default
|
|
};
|