sooyie-task 0.0.5 → 0.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,7 @@ import { defineComponent as te, mergeModels as ae, ref as c, reactive as M, watc
2
2
  import { ElMessage as q } from "element-plus";
3
3
  import { useI18n as se } from "vue-i18n";
4
4
  import { u as re } from "./index-DaJ5KrbS.mjs";
5
- import { t as E } from "./index-CEvxhWYT.mjs";
5
+ import { t as E } from "./index-BRMLJ2ar.mjs";
6
6
  import { D as w, C as de, Y as ue } from "./index-DvawPwK3.mjs";
7
7
  import "jmash-core";
8
8
  import { _ as ie } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
@@ -3,7 +3,7 @@ import "element-plus";
3
3
  import { useRoute as ne, useRouter as se } from "vue-router";
4
4
  import { useI18n as re } from "vue-i18n";
5
5
  import { routerUtil as de } from "jmash-core";
6
- import { t as D } from "./index-CEvxhWYT.mjs";
6
+ import { t as D } from "./index-BRMLJ2ar.mjs";
7
7
  import { D as _, C as ie } from "./index-DvawPwK3.mjs";
8
8
  import { u as ue } from "./index-DaJ5KrbS.mjs";
9
9
  import { _ as fe } from "./index.vue_vue_type_script_setup_true_lang-DRYjMxBU.mjs";
@@ -8,7 +8,7 @@ class i {
8
8
  // 查询翻页信息任务定义
9
9
  findPage(t) {
10
10
  const s = e().user.tenant;
11
- return a(t), n({
11
+ return t && (t.hasTaskSort = t.taskSort != null), a(t), n({
12
12
  url: "/v1/front/task/sooyie/task_define/page/" + s,
13
13
  method: "get",
14
14
  params: t
@@ -58,14 +58,14 @@ class i {
58
58
  }
59
59
  // 批量删除任务定义
60
60
  batchDelete(t) {
61
- const s = t.map((o) => o.taskDefineId), r = {
61
+ const s = t.map((r) => r.taskDefineId), o = {
62
62
  tenant: e().user.tenant,
63
63
  taskDefineId: s
64
64
  };
65
- return a(r), n({
65
+ return a(o), n({
66
66
  url: "/v1/front/task/sooyie/task_define/batch",
67
67
  method: "put",
68
- data: r
68
+ data: o
69
69
  });
70
70
  }
71
71
  // 下载导入模板任务定义
@@ -98,7 +98,7 @@ class i {
98
98
  });
99
99
  }
100
100
  }
101
- const u = new i();
101
+ const k = new i();
102
102
  export {
103
- u as t
103
+ k as t
104
104
  };
@@ -2,9 +2,9 @@ import { defineComponent as X, getCurrentInstance as Z, ref as C, reactive as N,
2
2
  import { useTableHooks as ne } from "jmash-core";
3
3
  import { useI18n as se } from "vue-i18n";
4
4
  import { b as re } from "./index-B_hFZVhb-C3Oi__-I.mjs";
5
- import { t as B } from "./index-CEvxhWYT.mjs";
5
+ import { t as B } from "./index-BRMLJ2ar.mjs";
6
6
  import { D as ie, C as ue } from "./index-DvawPwK3.mjs";
7
- import me from "./add-C2devcsq.mjs";
7
+ import me from "./add-BjZ9XOOq.mjs";
8
8
  import { useRouter as de } from "vue-router";
9
9
  const pe = { class: "app-container" }, ce = { class: "search-container" }, fe = ["onClick"], ke = ["onClick"], Se = /* @__PURE__ */ X({
10
10
  __name: "index",
@@ -0,0 +1,412 @@
1
+ import { defineComponent as Z, getCurrentInstance as tt, ref as C, onActivated as et, resolveComponent as r, resolveDirective as at, createElementBlock as I, openBlock as p, createElementVNode as c, createVNode as o, withCtx as a, withKeys as h, unref as s, Fragment as st, renderList as lt, createBlock as V, createTextVNode as _, toDisplayString as d, withDirectives as N, createCommentVNode as ot, isRef as E } from "vue";
2
+ import { useUserStore as U, clearEmpty as z, request as R, useTableHooks as nt } from "jmash-core";
3
+ import { useI18n as rt } from "vue-i18n";
4
+ import { D as m, C as L } from "./index-DvawPwK3.mjs";
5
+ import { t as ut } from "./index-BRMLJ2ar.mjs";
6
+ import { useRouter as dt } from "vue-router";
7
+ class it {
8
+ getKey() {
9
+ return {};
10
+ }
11
+ // 查询翻页信息任务实例
12
+ findPage(u) {
13
+ const k = U().user.tenant;
14
+ return z(u), u && (u.hasStatus = u.status !== void 0, u.hasSort = u.sort !== void 0), R({
15
+ url: "/v1/front/task/sooyie/task/page/" + k,
16
+ method: "get",
17
+ params: u
18
+ });
19
+ }
20
+ // 查询列表信息任务实例
21
+ findList(u) {
22
+ const k = U().user.tenant;
23
+ return z(u), R({
24
+ url: "/v1/front/task/sooyie/task/list/" + k,
25
+ method: "get",
26
+ params: u
27
+ });
28
+ }
29
+ }
30
+ const mt = new it(), pt = { class: "app-container" }, ct = { class: "search-container" }, kt = { key: 0 }, ft = { key: 1 }, vt = ["onClick"], St = /* @__PURE__ */ Z({
31
+ __name: "index",
32
+ setup(B) {
33
+ const { proxy: u } = tt(), { t: k } = rt();
34
+ m.OrgBizDict.useValues(), m.UserExtBizDict.useValues(), m.itemBizLayDict.useValues();
35
+ const n = C({}), P = dt(), {
36
+ tableHooks: i,
37
+ multipleTableRef: j,
38
+ queryFormRef: K,
39
+ listLoading: Q,
40
+ tableData: A,
41
+ total: w
42
+ } = nt(k, mt, n), f = C([]);
43
+ function Y(l) {
44
+ f.value.length === 0 && ut.getEnum({ className: L.TASKSORT_TYPE, type: 1 }).then((b) => {
45
+ f.value = b.data.values;
46
+ });
47
+ const e = f.value.find((b) => b.key === l);
48
+ return e ? e.value : "";
49
+ }
50
+ let v = C([
51
+ // 任务主题
52
+ {
53
+ label: "taskInst.taskName",
54
+ prop: "taskName",
55
+ minWidth: "150",
56
+ sortable: "custom",
57
+ isColumn: !0
58
+ },
59
+ // 任务类型
60
+ {
61
+ label: "taskInst.sort",
62
+ prop: "sort",
63
+ slotName: "sort",
64
+ columnType: "slot",
65
+ minWidth: "150",
66
+ sortable: "custom",
67
+ isColumn: !0
68
+ },
69
+ // 服务对象
70
+ {
71
+ label: "taskInst.customerTagId",
72
+ prop: "customerTagId",
73
+ slotName: "customerTagId",
74
+ columnType: "slot",
75
+ minWidth: "150",
76
+ sortable: "custom",
77
+ isColumn: !0
78
+ },
79
+ // 开始日期
80
+ {
81
+ label: "taskInst.startDate",
82
+ prop: "startDate",
83
+ width: "105",
84
+ sortable: "custom",
85
+ isColumn: !0
86
+ },
87
+ // 截止日期
88
+ {
89
+ label: "taskInst.endDate",
90
+ prop: "endDate",
91
+ width: "105",
92
+ sortable: "custom",
93
+ isColumn: !0
94
+ },
95
+ // 执行人员
96
+ {
97
+ label: "taskInst.userId",
98
+ prop: "userId",
99
+ slotName: "userId",
100
+ columnType: "slot",
101
+ width: "105",
102
+ sortable: "custom",
103
+ isColumn: !0
104
+ },
105
+ // 已读状态
106
+ {
107
+ label: "taskInst.readStatus",
108
+ prop: "readStatus",
109
+ slotName: "readStatus",
110
+ columnType: "slot",
111
+ width: "105",
112
+ sortable: "custom",
113
+ isColumn: !0
114
+ },
115
+ // 完成状态
116
+ {
117
+ label: "taskInst.status",
118
+ prop: "status",
119
+ slotName: "status",
120
+ columnType: "slot",
121
+ width: "105",
122
+ sortable: "custom",
123
+ isColumn: !0
124
+ },
125
+ // 完成进度
126
+ {
127
+ label: "taskInst.percent",
128
+ prop: "percent",
129
+ slotName: "percent",
130
+ columnType: "slot",
131
+ width: "105",
132
+ sortable: "custom",
133
+ isColumn: !0
134
+ },
135
+ // 完成时间
136
+ {
137
+ label: "taskInst.finishDate",
138
+ prop: "finishDate",
139
+ slotName: "finishDate",
140
+ columnType: "slot",
141
+ width: "160",
142
+ sortable: "custom",
143
+ isColumn: !0
144
+ },
145
+ {
146
+ label: "common.operate",
147
+ width: "60",
148
+ slotName: "operation",
149
+ columnType: "slot",
150
+ fixed: "right",
151
+ isColumn: !0
152
+ }
153
+ ]);
154
+ function x(l) {
155
+ P.push({
156
+ path: "/task/task-inst/info",
157
+ query: {
158
+ taskInstId: l.taskInstId,
159
+ taskSort: l.sort,
160
+ taskDefineId: l.taskDefineId
161
+ }
162
+ });
163
+ }
164
+ function H(l) {
165
+ i.selectionRows.value = l;
166
+ }
167
+ function O(l) {
168
+ i.handleSort(l.prop, l.order);
169
+ }
170
+ return et(() => {
171
+ i.getList();
172
+ }), (l, e) => {
173
+ const b = r("el-input"), y = r("el-form-item"), g = r("el-col"), F = r("el-option"), M = r("el-select"), T = r("jmash-select"), S = r("el-row"), D = r("el-button"), W = r("el-form"), q = r("jmash-column-select"), G = r("jmash-table"), J = r("jmash-pagination"), X = r("el-card"), $ = at("hasPerm");
174
+ return p(), I("div", pt, [
175
+ c("div", ct, [
176
+ o(W, {
177
+ ref_key: "queryFormRef",
178
+ ref: K,
179
+ model: n.value,
180
+ inline: !0
181
+ }, {
182
+ default: a(() => [
183
+ o(S, null, {
184
+ default: a(() => [
185
+ o(g, { span: 6 }, {
186
+ default: a(() => [
187
+ o(y, {
188
+ label: l.$t("taskInst.keyword"),
189
+ prop: "keyword"
190
+ }, {
191
+ default: a(() => [
192
+ o(b, {
193
+ modelValue: n.value.keyword,
194
+ "onUpdate:modelValue": e[0] || (e[0] = (t) => n.value.keyword = t),
195
+ placeholder: l.$t("taskInst.keywordRequired"),
196
+ onKeyup: e[1] || (e[1] = h((t) => s(i).handleQuery(), ["enter"])),
197
+ class: "!w-[203px]"
198
+ }, null, 8, ["modelValue", "placeholder"])
199
+ ]),
200
+ _: 1
201
+ }, 8, ["label"])
202
+ ]),
203
+ _: 1
204
+ }),
205
+ o(g, { span: 6 }, {
206
+ default: a(() => [
207
+ o(y, {
208
+ label: l.$t("taskDefine.taskSort"),
209
+ prop: "sort"
210
+ }, {
211
+ default: a(() => [
212
+ o(M, {
213
+ modelValue: n.value.sort,
214
+ "onUpdate:modelValue": e[2] || (e[2] = (t) => n.value.sort = t),
215
+ data: f.value,
216
+ placeholder: l.$t("taskDefine.taskSort"),
217
+ onKeyup: e[3] || (e[3] = h((t) => s(i).handleQuery(), ["enter"])),
218
+ class: "!w-[203px]"
219
+ }, {
220
+ default: a(() => [
221
+ (p(!0), I(st, null, lt(f.value, (t) => (p(), V(F, {
222
+ key: t.key,
223
+ label: t.value,
224
+ value: t.key
225
+ }, null, 8, ["label", "value"]))), 128))
226
+ ]),
227
+ _: 1
228
+ }, 8, ["modelValue", "data", "placeholder"])
229
+ ]),
230
+ _: 1
231
+ }, 8, ["label"])
232
+ ]),
233
+ _: 1
234
+ }),
235
+ o(g, { span: 6 }, {
236
+ default: a(() => [
237
+ o(y, {
238
+ label: l.$t("taskInst.readStatus"),
239
+ prop: "readStatus"
240
+ }, {
241
+ default: a(() => [
242
+ o(T, {
243
+ modelValue: n.value.readStatus,
244
+ "onUpdate:modelValue": e[4] || (e[4] = (t) => n.value.readStatus = t),
245
+ data: s(m).readStatusDict.values,
246
+ placeholder: l.$t("taskInst.readStatus"),
247
+ onKeyup: e[5] || (e[5] = h((t) => s(i).handleQuery(), ["enter"])),
248
+ class: "!w-[203px]"
249
+ }, null, 8, ["modelValue", "data", "placeholder"])
250
+ ]),
251
+ _: 1
252
+ }, 8, ["label"])
253
+ ]),
254
+ _: 1
255
+ }),
256
+ o(g, { span: 6 }, {
257
+ default: a(() => [
258
+ o(y, {
259
+ label: l.$t("taskInst.status"),
260
+ prop: "status"
261
+ }, {
262
+ default: a(() => [
263
+ o(T, {
264
+ modelValue: n.value.status,
265
+ "onUpdate:modelValue": e[6] || (e[6] = (t) => n.value.status = t),
266
+ data: s(m).taskStatusEnum.values,
267
+ placeholder: l.$t("taskInst.statusRequired"),
268
+ onKeyup: e[7] || (e[7] = h((t) => s(i).handleQuery(), ["enter"])),
269
+ class: "!w-[203px]"
270
+ }, null, 8, ["modelValue", "data", "placeholder"])
271
+ ]),
272
+ _: 1
273
+ }, 8, ["label"])
274
+ ]),
275
+ _: 1
276
+ })
277
+ ]),
278
+ _: 1
279
+ }),
280
+ o(S),
281
+ o(y, { class: "search-btn" }, {
282
+ default: a(() => [
283
+ o(D, {
284
+ type: "primary",
285
+ onClick: e[8] || (e[8] = (t) => s(i).handleQuery())
286
+ }, {
287
+ default: a(() => [
288
+ _(d(l.$t("common.search")), 1)
289
+ ]),
290
+ _: 1
291
+ }),
292
+ o(D, {
293
+ onClick: e[9] || (e[9] = (t) => s(i).resetQuery())
294
+ }, {
295
+ default: a(() => [
296
+ _(d(l.$t("common.reset")), 1)
297
+ ]),
298
+ _: 1
299
+ })
300
+ ]),
301
+ _: 1
302
+ })
303
+ ]),
304
+ _: 1
305
+ }, 8, ["model"]),
306
+ e[16] || (e[16] = c("div", { class: "clear" }, null, -1))
307
+ ]),
308
+ o(X, {
309
+ shadow: "never",
310
+ class: "table-container"
311
+ }, {
312
+ header: a(() => [
313
+ o(S, null, {
314
+ default: a(() => [
315
+ o(g, {
316
+ span: 24,
317
+ class: "container-float"
318
+ }, {
319
+ default: a(() => [
320
+ N((p(), V(D, {
321
+ plain: "",
322
+ type: "primary",
323
+ onClick: e[10] || (e[10] = (t) => s(i).handleExport(s(k)("task.taskInst.name")))
324
+ }, {
325
+ default: a(() => [
326
+ _(d(l.$t("common.export")), 1)
327
+ ]),
328
+ _: 1
329
+ })), [
330
+ [$, ["task:task:export"]]
331
+ ]),
332
+ o(q, {
333
+ modelValue: s(v),
334
+ "onUpdate:modelValue": e[11] || (e[11] = (t) => E(v) ? v.value = t : v = t),
335
+ "label-name": "task/task"
336
+ }, null, 8, ["modelValue"])
337
+ ]),
338
+ _: 1
339
+ })
340
+ ]),
341
+ _: 1
342
+ })
343
+ ]),
344
+ footer: a(() => [
345
+ s(w) > 0 ? (p(), V(J, {
346
+ key: 0,
347
+ total: s(w),
348
+ "onUpdate:total": e[12] || (e[12] = (t) => E(w) ? w.value = t : null),
349
+ "current-page": n.value.curPage,
350
+ "onUpdate:currentPage": e[13] || (e[13] = (t) => n.value.curPage = t),
351
+ "page-size": n.value.pageSize,
352
+ "onUpdate:pageSize": e[14] || (e[14] = (t) => n.value.pageSize = t),
353
+ onPagination: e[15] || (e[15] = (t) => s(i).getList())
354
+ }, null, 8, ["total", "current-page", "page-size"])) : ot("", !0)
355
+ ]),
356
+ default: a(() => [
357
+ o(G, {
358
+ ref_key: "multipleTableRef",
359
+ ref: j,
360
+ "row-key": "taskInstId",
361
+ "list-loading": s(Q),
362
+ data: s(A),
363
+ "table-label": s(v),
364
+ onSelectionChange: H,
365
+ onSortChange: O
366
+ }, {
367
+ sort: a((t) => [
368
+ c("span", null, d(Y(t.data.row.sort)), 1)
369
+ ]),
370
+ customerTagId: a((t) => [
371
+ t.data.row.sort === s(L).CUSTOMER ? (p(), I("span", kt, d(s(m).OrgBizDict.getValue(t.data.row.annivCustomerId)), 1)) : (p(), I("span", ft, d(s(m).itemBizLayDict.getValue(t.data.row.annivCustomerId)), 1))
372
+ ]),
373
+ readStatus: a((t) => [
374
+ c("span", null, d(s(m).readStatusDict.getValue(t.data.row.readStatus)), 1)
375
+ ]),
376
+ status: a((t) => [
377
+ c("span", null, d(s(m).taskStatusEnum.getEnumValue(t.data.row.status)), 1)
378
+ ]),
379
+ percent: a((t) => [
380
+ c("span", null, d(t.data.row.percent) + "% ", 1)
381
+ ]),
382
+ finishDate: a((t) => [
383
+ _(d(s(u).$moment.formatDate(
384
+ t.data.row.finishDate,
385
+ "YYYY-MM-DD HH:mm:ss"
386
+ )), 1)
387
+ ]),
388
+ userId: a((t) => [
389
+ c("span", null, d(s(m).UserExtBizDict.getValue(t.data.row.userId)), 1)
390
+ ]),
391
+ operation: a((t) => [
392
+ N((p(), I("span", {
393
+ class: "el-button-color",
394
+ onClick: (bt) => x(t.data.row)
395
+ }, [
396
+ _(d(l.$t("common.view")), 1)
397
+ ], 8, vt)), [
398
+ [$, ["task:task:delete"]]
399
+ ])
400
+ ]),
401
+ _: 1
402
+ }, 8, ["list-loading", "data", "table-label"])
403
+ ]),
404
+ _: 1
405
+ })
406
+ ]);
407
+ };
408
+ }
409
+ });
410
+ export {
411
+ St as default
412
+ };
package/dist/index.mjs CHANGED
@@ -213,7 +213,7 @@ function bs(e) {
213
213
  let s = e.global.getLocaleMessage("en");
214
214
  s = pt(s, Os), e.global.setLocaleMessage("zh-cn", t), e.global.setLocaleMessage("en", s);
215
215
  }
216
- const Is = () => import("./edit-CRQkMd15.mjs"), xs = () => import("./info-BTSBObrr.mjs"), Ns = [
216
+ const Is = () => import("./edit-CQXHFXME.mjs"), xs = () => import("./info-CMW8tHes.mjs"), Ns = [
217
217
  {
218
218
  path: "/task",
219
219
  component: Ms,
@@ -2827,7 +2827,7 @@ const Pi = {
2827
2827
  }
2828
2828
  };
2829
2829
  }
2830
- }, Wi = /* @__PURE__ */ Object.assign({ "./views/task/task-define-rel/add.vue": () => import("./add-7_dK5ok_.mjs").then((e) => e.b), "./views/task/task-define-rel/index.vue": () => import("./index-DIHsBjkh.mjs"), "./views/task/task-define/add.vue": () => import("./add-C2devcsq.mjs"), "./views/task/task-define/edit.vue": () => import("./edit-CRQkMd15.mjs"), "./views/task/task-define/index.vue": () => import("./index-_jDuSfL7.mjs"), "./views/task/task-inst/edit.vue": () => import("./edit-Ci8Uch5Z.mjs"), "./views/task/task-inst/index.vue": () => import("./index-DtM5EnwJ.mjs"), "./views/task/task-inst/info.vue": () => import("./info-BTSBObrr.mjs"), "./views/task/task-inst/report-info.vue": () => import("./report-info-B0NXFFzR.mjs").then((e) => e.r), "./views/task/task-inst/report.vue": () => import("./report-Uf6UKzUn.mjs").then((e) => e.r), "./views/task/task-task/index.vue": () => import("./index-aDDSbb4h.mjs") }), Ci = {
2830
+ }, Wi = /* @__PURE__ */ Object.assign({ "./views/task/task-define-rel/add.vue": () => import("./add-7_dK5ok_.mjs").then((e) => e.b), "./views/task/task-define-rel/index.vue": () => import("./index-DIHsBjkh.mjs"), "./views/task/task-define/add.vue": () => import("./add-BjZ9XOOq.mjs"), "./views/task/task-define/edit.vue": () => import("./edit-CQXHFXME.mjs"), "./views/task/task-define/index.vue": () => import("./index-CQu6Hpdd.mjs"), "./views/task/task-inst/edit.vue": () => import("./edit-Ci8Uch5Z.mjs"), "./views/task/task-inst/index.vue": () => import("./index-DtM5EnwJ.mjs"), "./views/task/task-inst/info.vue": () => import("./info-CMW8tHes.mjs"), "./views/task/task-inst/report-info.vue": () => import("./report-info-B0NXFFzR.mjs").then((e) => e.r), "./views/task/task-inst/report.vue": () => import("./report-Uf6UKzUn.mjs").then((e) => e.r), "./views/task/task-task/index.vue": () => import("./index-Cb72ljTZ.mjs") }), Ci = {
2831
2831
  install(e) {
2832
2832
  vs(Wi, 7), bs(Ys), ps(Ns), e.use(Pi);
2833
2833
  }
@@ -3,7 +3,7 @@ import { b as Pr } from "./index-B_hFZVhb-C3Oi__-I.mjs";
3
3
  import { useUserStore as F, clearEmpty as z, request as B, fileApi as kr } from "jmash-core";
4
4
  import { useRoute as Rr } from "vue-router";
5
5
  import { D as L, J as Dr, $ as Nr, C as Re } from "./index-DvawPwK3.mjs";
6
- import { t as Tr } from "./index-CEvxhWYT.mjs";
6
+ import { t as Tr } from "./index-BRMLJ2ar.mjs";
7
7
  import { t as Et, a as Fr } from "./report-info-B0NXFFzR.mjs";
8
8
  import { t as At, a as Cr } from "./report-Uf6UKzUn.mjs";
9
9
  import { useI18n as Mr } from "vue-i18n";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sooyie-task",
3
- "version": "0.0.5",
3
+ "version": "0.0.6",
4
4
  "private": false,
5
5
  "module": "dist/index.mjs",
6
6
  "types": "dts/src/index.d.ts",
@@ -1,481 +0,0 @@
1
- import { defineComponent as Z, getCurrentInstance as ee, ref as C, onActivated as te, resolveComponent as r, resolveDirective as ae, createElementBlock as y, openBlock as p, createElementVNode as c, createVNode as l, withCtx as a, withKeys as _, unref as o, Fragment as oe, renderList as se, createBlock as V, createTextVNode as I, toDisplayString as d, withDirectives as N, createCommentVNode as le, isRef as E } from "vue";
2
- import { RedirectPage as ne, Layout as T, LoginPage as re, ProfilePage as ue, DashboardPage as de, Error401Page as ie, Error404Page as me, useUserStore as R, clearEmpty as L, request as U, useTableHooks as pe } from "jmash-core";
3
- import { useI18n as ce } from "vue-i18n";
4
- import { D as m, C as z } from "./index-DvawPwK3.mjs";
5
- import { createRouter as fe, createWebHistory as ke } from "vue-router";
6
- import { t as he } from "./index-CEvxhWYT.mjs";
7
- const be = [
8
- {
9
- path: "/redirect",
10
- component: T,
11
- meta: { hidden: !0 },
12
- children: [
13
- {
14
- path: "/redirect/:path(.*)",
15
- component: ne
16
- }
17
- ]
18
- },
19
- {
20
- path: "/login",
21
- component: re,
22
- meta: { hidden: !0 }
23
- },
24
- {
25
- path: "/my",
26
- component: T,
27
- meta: { hidden: !0 },
28
- redirect: "noredirect",
29
- children: [
30
- {
31
- path: "profile",
32
- component: ue,
33
- name: "Profile",
34
- meta: { title: "个人中心", icon: "user" }
35
- }
36
- ]
37
- },
38
- {
39
- path: "/",
40
- name: "/",
41
- component: T,
42
- redirect: "/dashboard",
43
- children: [
44
- {
45
- path: "/dashboard",
46
- component: de,
47
- name: "Dashboard",
48
- // 用于 keep-alive, 必须与SFC自动推导或者显示声明的组件name一致
49
- // https://cn.vuejs.org/guide/built-ins/keep-alive.html#include-exclude
50
- meta: {
51
- title: "Dashboard",
52
- icon: "homepage",
53
- affix: !0,
54
- keepAlive: !0,
55
- alwaysShow: !1
56
- }
57
- },
58
- {
59
- path: "401",
60
- component: ie,
61
- meta: { hidden: !0 }
62
- },
63
- {
64
- path: "404",
65
- component: me,
66
- meta: { hidden: !0 }
67
- }
68
- ]
69
- }
70
- ], ve = fe({
71
- history: ke(void 0),
72
- routes: be,
73
- // 刷新时,滚动条位置还原
74
- scrollBehavior: () => ({ left: 0, top: 0 })
75
- });
76
- class ge {
77
- getKey() {
78
- return {};
79
- }
80
- // 查询翻页信息任务实例
81
- findPage(u) {
82
- const f = R().user.tenant;
83
- return L(u), u && (u.hasStatus = u.status !== void 0, u.hasSort = u.sort !== void 0), U({
84
- url: "/v1/front/task/sooyie/task/page/" + f,
85
- method: "get",
86
- params: u
87
- });
88
- }
89
- // 查询列表信息任务实例
90
- findList(u) {
91
- const f = R().user.tenant;
92
- return L(u), U({
93
- url: "/v1/front/task/sooyie/task/list/" + f,
94
- method: "get",
95
- params: u
96
- });
97
- }
98
- }
99
- const ye = new ge(), Ie = { class: "app-container" }, we = { class: "search-container" }, _e = { key: 0 }, Se = { key: 1 }, De = ["onClick"], Re = /* @__PURE__ */ Z({
100
- __name: "index",
101
- setup(B) {
102
- const { proxy: u } = ee(), { t: f } = ce();
103
- m.OrgBizDict.useValues(), m.UserExtBizDict.useValues(), m.itemBizLayDict.useValues();
104
- const n = C({}), {
105
- tableHooks: i,
106
- multipleTableRef: j,
107
- queryFormRef: K,
108
- listLoading: A,
109
- tableData: Q,
110
- total: w
111
- } = pe(f, ye, n), k = C([]);
112
- function x(s) {
113
- k.value.length === 0 && he.getEnum({ className: z.TASKSORT_TYPE, type: 1 }).then((b) => {
114
- k.value = b.data.values;
115
- });
116
- const t = k.value.find((b) => b.key === s);
117
- return t ? t.value : "";
118
- }
119
- let h = C([
120
- // 任务主题
121
- {
122
- label: "taskInst.taskName",
123
- prop: "taskName",
124
- minWidth: "150",
125
- sortable: "custom",
126
- isColumn: !0
127
- },
128
- // 任务类型
129
- {
130
- label: "taskInst.sort",
131
- prop: "sort",
132
- slotName: "sort",
133
- columnType: "slot",
134
- minWidth: "150",
135
- sortable: "custom",
136
- isColumn: !0
137
- },
138
- // 服务对象
139
- {
140
- label: "taskInst.customerTagId",
141
- prop: "customerTagId",
142
- slotName: "customerTagId",
143
- columnType: "slot",
144
- minWidth: "150",
145
- sortable: "custom",
146
- isColumn: !0
147
- },
148
- // 开始日期
149
- {
150
- label: "taskInst.startDate",
151
- prop: "startDate",
152
- width: "105",
153
- sortable: "custom",
154
- isColumn: !0
155
- },
156
- // 截止日期
157
- {
158
- label: "taskInst.endDate",
159
- prop: "endDate",
160
- width: "105",
161
- sortable: "custom",
162
- isColumn: !0
163
- },
164
- // 执行人员
165
- {
166
- label: "taskInst.userId",
167
- prop: "userId",
168
- slotName: "userId",
169
- columnType: "slot",
170
- width: "105",
171
- sortable: "custom",
172
- isColumn: !0
173
- },
174
- // 已读状态
175
- {
176
- label: "taskInst.readStatus",
177
- prop: "readStatus",
178
- slotName: "readStatus",
179
- columnType: "slot",
180
- width: "105",
181
- sortable: "custom",
182
- isColumn: !0
183
- },
184
- // 完成状态
185
- {
186
- label: "taskInst.status",
187
- prop: "status",
188
- slotName: "status",
189
- columnType: "slot",
190
- width: "105",
191
- sortable: "custom",
192
- isColumn: !0
193
- },
194
- // 完成进度
195
- {
196
- label: "taskInst.percent",
197
- prop: "percent",
198
- slotName: "percent",
199
- columnType: "slot",
200
- width: "105",
201
- sortable: "custom",
202
- isColumn: !0
203
- },
204
- // 完成时间
205
- {
206
- label: "taskInst.finishDate",
207
- prop: "finishDate",
208
- slotName: "finishDate",
209
- columnType: "slot",
210
- width: "160",
211
- sortable: "custom",
212
- isColumn: !0
213
- },
214
- {
215
- label: "common.operate",
216
- width: "60",
217
- slotName: "operation",
218
- columnType: "slot",
219
- fixed: "right",
220
- isColumn: !0
221
- }
222
- ]);
223
- function H(s) {
224
- ve.push({
225
- path: "/task/task-inst/info",
226
- query: {
227
- taskInstId: s.taskInstId,
228
- taskSort: s.sort,
229
- taskDefineId: s.taskDefineId
230
- }
231
- });
232
- }
233
- function Y(s) {
234
- i.selectionRows.value = s;
235
- }
236
- function O(s) {
237
- i.handleSort(s.prop, s.order);
238
- }
239
- return te(() => {
240
- i.getList();
241
- }), (s, t) => {
242
- const b = r("el-input"), v = r("el-form-item"), g = r("el-col"), W = r("el-option"), F = r("el-select"), $ = r("jmash-select"), S = r("el-row"), D = r("el-button"), M = r("el-form"), q = r("jmash-column-select"), G = r("jmash-table"), J = r("jmash-pagination"), X = r("el-card"), P = ae("hasPerm");
243
- return p(), y("div", Ie, [
244
- c("div", we, [
245
- l(M, {
246
- ref_key: "queryFormRef",
247
- ref: K,
248
- model: n.value,
249
- inline: !0
250
- }, {
251
- default: a(() => [
252
- l(S, null, {
253
- default: a(() => [
254
- l(g, { span: 6 }, {
255
- default: a(() => [
256
- l(v, {
257
- label: s.$t("taskInst.keyword"),
258
- prop: "keyword"
259
- }, {
260
- default: a(() => [
261
- l(b, {
262
- modelValue: n.value.keyword,
263
- "onUpdate:modelValue": t[0] || (t[0] = (e) => n.value.keyword = e),
264
- placeholder: s.$t("taskInst.keywordRequired"),
265
- onKeyup: t[1] || (t[1] = _((e) => o(i).handleQuery(), ["enter"])),
266
- class: "!w-[203px]"
267
- }, null, 8, ["modelValue", "placeholder"])
268
- ]),
269
- _: 1
270
- }, 8, ["label"])
271
- ]),
272
- _: 1
273
- }),
274
- l(g, { span: 6 }, {
275
- default: a(() => [
276
- l(v, {
277
- label: s.$t("taskDefine.taskSort"),
278
- prop: "sort"
279
- }, {
280
- default: a(() => [
281
- l(F, {
282
- modelValue: n.value.sort,
283
- "onUpdate:modelValue": t[2] || (t[2] = (e) => n.value.sort = e),
284
- data: k.value,
285
- placeholder: s.$t("taskDefine.taskSort"),
286
- onKeyup: t[3] || (t[3] = _((e) => o(i).handleQuery(), ["enter"])),
287
- class: "!w-[203px]"
288
- }, {
289
- default: a(() => [
290
- (p(!0), y(oe, null, se(k.value, (e) => (p(), V(W, {
291
- key: e.key,
292
- label: e.value,
293
- value: e.key
294
- }, null, 8, ["label", "value"]))), 128))
295
- ]),
296
- _: 1
297
- }, 8, ["modelValue", "data", "placeholder"])
298
- ]),
299
- _: 1
300
- }, 8, ["label"])
301
- ]),
302
- _: 1
303
- }),
304
- l(g, { span: 6 }, {
305
- default: a(() => [
306
- l(v, {
307
- label: s.$t("taskInst.readStatus"),
308
- prop: "readStatus"
309
- }, {
310
- default: a(() => [
311
- l($, {
312
- modelValue: n.value.readStatus,
313
- "onUpdate:modelValue": t[4] || (t[4] = (e) => n.value.readStatus = e),
314
- data: o(m).readStatusDict.values,
315
- placeholder: s.$t("taskInst.readStatus"),
316
- onKeyup: t[5] || (t[5] = _((e) => o(i).handleQuery(), ["enter"])),
317
- class: "!w-[203px]"
318
- }, null, 8, ["modelValue", "data", "placeholder"])
319
- ]),
320
- _: 1
321
- }, 8, ["label"])
322
- ]),
323
- _: 1
324
- }),
325
- l(g, { span: 6 }, {
326
- default: a(() => [
327
- l(v, {
328
- label: s.$t("taskInst.status"),
329
- prop: "status"
330
- }, {
331
- default: a(() => [
332
- l($, {
333
- modelValue: n.value.status,
334
- "onUpdate:modelValue": t[6] || (t[6] = (e) => n.value.status = e),
335
- data: o(m).taskStatusEnum.values,
336
- placeholder: s.$t("taskInst.statusRequired"),
337
- onKeyup: t[7] || (t[7] = _((e) => o(i).handleQuery(), ["enter"])),
338
- class: "!w-[203px]"
339
- }, null, 8, ["modelValue", "data", "placeholder"])
340
- ]),
341
- _: 1
342
- }, 8, ["label"])
343
- ]),
344
- _: 1
345
- })
346
- ]),
347
- _: 1
348
- }),
349
- l(S),
350
- l(v, { class: "search-btn" }, {
351
- default: a(() => [
352
- l(D, {
353
- type: "primary",
354
- onClick: t[8] || (t[8] = (e) => o(i).handleQuery())
355
- }, {
356
- default: a(() => [
357
- I(d(s.$t("common.search")), 1)
358
- ]),
359
- _: 1
360
- }),
361
- l(D, {
362
- onClick: t[9] || (t[9] = (e) => o(i).resetQuery())
363
- }, {
364
- default: a(() => [
365
- I(d(s.$t("common.reset")), 1)
366
- ]),
367
- _: 1
368
- })
369
- ]),
370
- _: 1
371
- })
372
- ]),
373
- _: 1
374
- }, 8, ["model"]),
375
- t[16] || (t[16] = c("div", { class: "clear" }, null, -1))
376
- ]),
377
- l(X, {
378
- shadow: "never",
379
- class: "table-container"
380
- }, {
381
- header: a(() => [
382
- l(S, null, {
383
- default: a(() => [
384
- l(g, {
385
- span: 24,
386
- class: "container-float"
387
- }, {
388
- default: a(() => [
389
- N((p(), V(D, {
390
- plain: "",
391
- type: "primary",
392
- onClick: t[10] || (t[10] = (e) => o(i).handleExport(o(f)("task.taskInst.name")))
393
- }, {
394
- default: a(() => [
395
- I(d(s.$t("common.export")), 1)
396
- ]),
397
- _: 1
398
- })), [
399
- [P, ["task:task:export"]]
400
- ]),
401
- l(q, {
402
- modelValue: o(h),
403
- "onUpdate:modelValue": t[11] || (t[11] = (e) => E(h) ? h.value = e : h = e),
404
- "label-name": "task/task"
405
- }, null, 8, ["modelValue"])
406
- ]),
407
- _: 1
408
- })
409
- ]),
410
- _: 1
411
- })
412
- ]),
413
- footer: a(() => [
414
- o(w) > 0 ? (p(), V(J, {
415
- key: 0,
416
- total: o(w),
417
- "onUpdate:total": t[12] || (t[12] = (e) => E(w) ? w.value = e : null),
418
- "current-page": n.value.curPage,
419
- "onUpdate:currentPage": t[13] || (t[13] = (e) => n.value.curPage = e),
420
- "page-size": n.value.pageSize,
421
- "onUpdate:pageSize": t[14] || (t[14] = (e) => n.value.pageSize = e),
422
- onPagination: t[15] || (t[15] = (e) => o(i).getList())
423
- }, null, 8, ["total", "current-page", "page-size"])) : le("", !0)
424
- ]),
425
- default: a(() => [
426
- l(G, {
427
- ref_key: "multipleTableRef",
428
- ref: j,
429
- "row-key": "taskInstId",
430
- "list-loading": o(A),
431
- data: o(Q),
432
- "table-label": o(h),
433
- onSelectionChange: Y,
434
- onSortChange: O
435
- }, {
436
- sort: a((e) => [
437
- c("span", null, d(x(e.data.row.sort)), 1)
438
- ]),
439
- customerTagId: a((e) => [
440
- e.data.row.sort === o(z).CUSTOMER ? (p(), y("span", _e, d(o(m).OrgBizDict.getValue(e.data.row.annivCustomerId)), 1)) : (p(), y("span", Se, d(o(m).itemBizLayDict.getValue(e.data.row.annivCustomerId)), 1))
441
- ]),
442
- readStatus: a((e) => [
443
- c("span", null, d(o(m).readStatusDict.getValue(e.data.row.readStatus)), 1)
444
- ]),
445
- status: a((e) => [
446
- c("span", null, d(o(m).taskStatusEnum.getEnumValue(e.data.row.status)), 1)
447
- ]),
448
- percent: a((e) => [
449
- c("span", null, d(e.data.row.percent) + "% ", 1)
450
- ]),
451
- finishDate: a((e) => [
452
- I(d(o(u).$moment.formatDate(
453
- e.data.row.finishDate,
454
- "YYYY-MM-DD HH:mm:ss"
455
- )), 1)
456
- ]),
457
- userId: a((e) => [
458
- c("span", null, d(o(m).UserExtBizDict.getValue(e.data.row.userId)), 1)
459
- ]),
460
- operation: a((e) => [
461
- N((p(), y("span", {
462
- class: "el-button-color",
463
- onClick: (Ce) => H(e.data.row)
464
- }, [
465
- I(d(s.$t("common.view")), 1)
466
- ], 8, De)), [
467
- [P, ["task:task:delete"]]
468
- ])
469
- ]),
470
- _: 1
471
- }, 8, ["list-loading", "data", "table-label"])
472
- ]),
473
- _: 1
474
- })
475
- ]);
476
- };
477
- }
478
- });
479
- export {
480
- Re as default
481
- };