xyvcard-itsm-flow 0.0.12 → 0.0.13

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.
@@ -1,13 +1,13 @@
1
- import { defineComponent as X, mergeModels as Y, ref as m, useModel as Z, resolveComponent as d, createElementBlock as g, openBlock as b, Fragment as M, createVNode as e, withCtx as l, createElementVNode as n, createTextVNode as u, toDisplayString as r, unref as F, createBlock as S, createCommentVNode as B, renderList as ee } from "vue";
1
+ import { defineComponent as Y, mergeModels as Z, ref as m, useModel as ee, resolveComponent as d, createElementBlock as A, openBlock as b, Fragment as O, createVNode as e, withCtx as l, createElementVNode as n, createTextVNode as u, toDisplayString as r, unref as f, createBlock as $, createCommentVNode as h, renderList as le } from "vue";
2
2
  import "element-plus";
3
- import { D as k, i as A, C as le, u as ae, a as te } from "./index-B80qPhYo.mjs";
3
+ import { D as k, i as V, C as w, u as ae, a as te } from "./index-CMpeLVvR.mjs";
4
4
  import { handlePreview as oe } from "jmash-core";
5
5
  import { useI18n as ne } from "vue-i18n";
6
6
  import { F as se } from "./FileSaver.min-5d27MsC6.mjs";
7
- import { E as L } from "./el-message-CDs_oXSE.mjs";
8
- const _e = /* @__PURE__ */ X({
7
+ import { E as S } from "./el-message-DweX1k3E.mjs";
8
+ const _e = /* @__PURE__ */ Y({
9
9
  __name: "index",
10
- props: /* @__PURE__ */ Y({
10
+ props: /* @__PURE__ */ Z({
11
11
  task: {
12
12
  type: Object,
13
13
  default: () => {
@@ -18,74 +18,74 @@ const _e = /* @__PURE__ */ X({
18
18
  modelModifiers: {}
19
19
  }),
20
20
  emits: ["update:modelValue"],
21
- setup($, { expose: O }) {
22
- const { t: w } = ne(), U = () => {
23
- A.exportFilePdf({ acceptanceId: h.value.acceptanceId }).then((a) => {
21
+ setup(I, { expose: j }) {
22
+ const { t: y } = ne(), K = () => {
23
+ V.exportFilePdf({ acceptanceId: D.value.acceptanceId }).then((a) => {
24
24
  const o = new Blob([a.data], {
25
25
  type: "application/octet-stream"
26
26
  });
27
- se.saveAs(o, w("itsmFlowAcceptance.name") + ".pdf");
27
+ se.saveAs(o, y("itsmFlowAcceptance.name") + ".pdf");
28
28
  });
29
29
  };
30
30
  k.orgIdBizDict.useValues();
31
- const _ = $, h = m({
31
+ const _ = I, D = m({
32
32
  acceptanceId: _.task.businessKey
33
- }), c = m({}), f = Z($, "modelValue"), V = m(), j = m({}), y = m(!1), I = m(), p = m([]), E = m();
34
- function P() {
35
- y.value = !0, I.value.clearFileList();
33
+ }), c = m({}), v = ee(I, "modelValue"), E = m(), P = m({}), N = m(!1), M = m(), p = m([]), B = m();
34
+ function q() {
35
+ N.value = !0, M.value.clearFileList();
36
36
  }
37
- function q(a) {
37
+ function U(a) {
38
38
  p == null || p.value.splice(a, 1);
39
39
  }
40
- function K(a) {
40
+ function z(a) {
41
41
  const o = {
42
42
  fileName: a.name,
43
43
  fileId: a.response.fileId
44
44
  };
45
- p == null || p.value.push(o), p.value = [...new Set(p.value)], E.value = {
45
+ p == null || p.value.push(o), p.value = [...new Set(p.value)], B.value = {
46
46
  requestId: Math.random() * 10 + "",
47
47
  taskId: _.task.id,
48
48
  name: a.name,
49
49
  type: a.response.contentType,
50
50
  url: a.response.fileSrc
51
- }, z();
51
+ }, R();
52
52
  }
53
- function z() {
54
- te.uploadFile(E.value).then(() => {
55
- L.success(w("common.uploadSuccess"));
53
+ function R() {
54
+ te.uploadFile(B.value).then(() => {
55
+ S.success(y("common.uploadSuccess"));
56
56
  }).catch(() => {
57
- L.error(w("common.uploadError"));
57
+ S.error(y("common.uploadError"));
58
58
  });
59
59
  }
60
- function R() {
61
- A.findFilesList({ actionId: _.task.businessKey }).then(({ data: a }) => {
60
+ function T() {
61
+ V.findFilesList({ actionId: _.task.businessKey }).then(({ data: a }) => {
62
62
  a.results.forEach((o) => {
63
63
  o.filePath = o.fileSrc;
64
64
  }), c.value.files = a.results;
65
65
  });
66
66
  }
67
- _.task.businessKey && T(), O({
68
- changeModel: () => W()
67
+ _.task.businessKey && W(), j({
68
+ changeModel: () => x()
69
69
  });
70
- function T() {
71
- A.findById({ acceptanceId: h.value.acceptanceId }).then(({ data: a }) => {
70
+ function W() {
71
+ V.findById({ acceptanceId: D.value.acceptanceId }).then(({ data: a }) => {
72
72
  c.value = Object.assign(c.value, a);
73
- }), R();
73
+ }), T();
74
74
  }
75
- function W() {
76
- return f.value && (f.value.selectActions = [
75
+ function x() {
76
+ return v.value && (v.value.selectActions = [
77
77
  { key: "true", value: "同意" },
78
78
  { key: "false", value: "不同意" }
79
- ], f.value.varName = "approved", f.value.module = "", f.value.module = le.MODULE_ITSMFLOW), new Promise((a, o) => {
79
+ ], v.value.varName = "approved", v.value.module = "", v.value.module = w.MODULE_ITSMFLOW), new Promise((a, o) => {
80
80
  var t;
81
- (t = V.value) == null || t.validate((s) => {
82
- s ? (f.value && (f.value.comment = ""), a(!0)) : o(!1);
81
+ (t = E.value) == null || t.validate((s) => {
82
+ s ? (v.value && (v.value.comment = ""), a(!0)) : o(!1);
83
83
  });
84
84
  });
85
85
  }
86
86
  return (a, o) => {
87
- const t = d("el-col"), s = d("el-form-item"), i = d("el-row"), D = d("el-table-column"), N = d("el-button"), x = d("el-table"), G = d("CircleClose"), H = d("el-icon"), J = d("el-form"), Q = d("jmash-multi-upload");
88
- return b(), g(M, null, [
87
+ const t = d("el-col"), s = d("el-form-item"), i = d("el-row"), L = d("el-table-column"), g = d("el-button"), G = d("el-table"), H = d("CircleClose"), J = d("el-icon"), Q = d("el-form"), X = d("jmash-multi-upload");
88
+ return b(), A(O, null, [
89
89
  e(t, { span: 24 }, {
90
90
  default: l(() => o[1] || (o[1] = [
91
91
  n("div", { class: "title" }, "山西云时代技术有限公司大数据中心分公司项目验收书", -1)
@@ -93,10 +93,10 @@ const _e = /* @__PURE__ */ X({
93
93
  _: 1,
94
94
  __: [1]
95
95
  }),
96
- e(J, {
96
+ e(Q, {
97
97
  ref_key: "taskFormRef",
98
- ref: V,
99
- model: j.value,
98
+ ref: E,
99
+ model: P.value,
100
100
  "label-width": "150px",
101
101
  class: "custom-table-form"
102
102
  }, {
@@ -167,7 +167,7 @@ const _e = /* @__PURE__ */ X({
167
167
  prop: "entrustName"
168
168
  }, {
169
169
  default: l(() => [
170
- u(r(F(k).projectNameDict.getDictValue(c.value.entrustName)), 1)
170
+ u(r(f(k).projectNameDict.getDictValue(c.value.entrustName)), 1)
171
171
  ]),
172
172
  _: 1
173
173
  }, 8, ["label"])
@@ -186,7 +186,7 @@ const _e = /* @__PURE__ */ X({
186
186
  prop: "serviceOrg"
187
187
  }, {
188
188
  default: l(() => [
189
- u(r(F(k).orgIdBizDict.getValue(c.value.serviceOrg)), 1)
189
+ u(r(f(k).orgIdBizDict.getValue(c.value.serviceOrg)), 1)
190
190
  ]),
191
191
  _: 1
192
192
  }, 8, ["label"])
@@ -247,26 +247,26 @@ const _e = /* @__PURE__ */ X({
247
247
  prop: "files"
248
248
  }, {
249
249
  default: l(() => [
250
- e(x, {
250
+ e(G, {
251
251
  data: c.value.files,
252
252
  border: ""
253
253
  }, {
254
254
  default: l(() => [
255
- e(D, {
255
+ e(L, {
256
256
  prop: "fileName",
257
257
  label: "附件名称"
258
258
  }),
259
- e(D, {
259
+ e(L, {
260
260
  prop: "",
261
261
  label: "操作",
262
262
  width: "100"
263
263
  }, {
264
- default: l((v) => [
265
- e(N, {
264
+ default: l((F) => [
265
+ e(g, {
266
266
  type: "primary",
267
267
  link: "",
268
268
  size: "small",
269
- onClick: (C) => F(oe)(v.row)
269
+ onClick: (C) => f(oe)(F.row)
270
270
  }, {
271
271
  default: l(() => o[2] || (o[2] = [
272
272
  u(" 查看 ")
@@ -310,14 +310,36 @@ const _e = /* @__PURE__ */ X({
310
310
  }),
311
311
  e(i, null, {
312
312
  default: l(() => [
313
- e(t, { span: 24 }, {
313
+ _.task.taskDefinitionKey !== f(w).node.sign ? (b(), $(t, {
314
+ key: 0,
315
+ span: 24
316
+ }, {
314
317
  default: l(() => [
315
318
  e(s, {
316
319
  label: a.$t("itsmFlowAcceptance.result"),
317
320
  prop: "result"
318
321
  }, {
319
322
  default: l(() => [
320
- u(r(F(k).isValuesDict.getValue(c.value.result)), 1)
323
+ u(r(f(k).isValuesDict.getValue(c.value.result)), 1)
324
+ ]),
325
+ _: 1
326
+ }, 8, ["label"])
327
+ ]),
328
+ _: 1
329
+ })) : h("", !0)
330
+ ]),
331
+ _: 1
332
+ }),
333
+ e(i, null, {
334
+ default: l(() => [
335
+ e(t, { span: 24 }, {
336
+ default: l(() => [
337
+ e(s, {
338
+ label: a.$t("itsmFlowAcceptance.acceptanceNo"),
339
+ prop: "acceptanceNo"
340
+ }, {
341
+ default: l(() => [
342
+ u(r(c.value.acceptanceNo), 1)
321
343
  ]),
322
344
  _: 1
323
345
  }, 8, ["label"])
@@ -394,7 +416,7 @@ const _e = /* @__PURE__ */ X({
394
416
  }),
395
417
  e(i, null, {
396
418
  default: l(() => [
397
- _.task.taskDefinitionKey === "UploadScanFile" ? (b(), S(t, {
419
+ _.task.taskDefinitionKey === f(w).node.upload ? (b(), $(t, {
398
420
  key: 0,
399
421
  span: 12
400
422
  }, {
@@ -403,10 +425,10 @@ const _e = /* @__PURE__ */ X({
403
425
  label: a.$t("itsmFlowEntrust.scannedCopy")
404
426
  }, {
405
427
  default: l(() => [
406
- e(N, {
428
+ e(g, {
407
429
  type: "primary",
408
- icon: F(ae),
409
- onClick: P
430
+ icon: f(ae),
431
+ onClick: q
410
432
  }, {
411
433
  default: l(() => [
412
434
  u(r(a.$t("common.uploadFiles")), 1)
@@ -418,18 +440,18 @@ const _e = /* @__PURE__ */ X({
418
440
  }, 8, ["label"]),
419
441
  e(s, null, {
420
442
  default: l(() => [
421
- (b(!0), g(M, null, ee(p.value, (v, C) => (b(), g("div", {
443
+ (b(!0), A(O, null, le(p.value, (F, C) => (b(), A("div", {
422
444
  key: C,
423
445
  class: "files-list"
424
446
  }, [
425
- u(r(v.fileName) + " ", 1),
426
- e(H, {
447
+ u(r(F.fileName) + " ", 1),
448
+ e(J, {
427
449
  size: "16",
428
450
  class: "icon-right",
429
- onClick: (ue) => q(C)
451
+ onClick: (ue) => U(C)
430
452
  }, {
431
453
  default: l(() => [
432
- e(G)
454
+ e(H)
433
455
  ]),
434
456
  _: 2
435
457
  }, 1032, ["onClick"])
@@ -439,8 +461,8 @@ const _e = /* @__PURE__ */ X({
439
461
  })
440
462
  ]),
441
463
  _: 1
442
- })) : B("", !0),
443
- _.task.taskDefinitionKey === "UploadScanFile" ? (b(), S(t, {
464
+ })) : h("", !0),
465
+ _.task.taskDefinitionKey === f(w).node.upload ? (b(), $(t, {
444
466
  key: 1,
445
467
  span: 12
446
468
  }, {
@@ -449,10 +471,10 @@ const _e = /* @__PURE__ */ X({
449
471
  label: a.$t("itsmFlowEntrust.export")
450
472
  }, {
451
473
  default: l(() => [
452
- e(N, {
474
+ e(g, {
453
475
  plain: "",
454
476
  type: "primary",
455
- onClick: U
477
+ onClick: K
456
478
  }, {
457
479
  default: l(() => [
458
480
  u(r(a.$t("itsmFlowEntrust.export")), 1)
@@ -464,19 +486,19 @@ const _e = /* @__PURE__ */ X({
464
486
  }, 8, ["label"])
465
487
  ]),
466
488
  _: 1
467
- })) : B("", !0)
489
+ })) : h("", !0)
468
490
  ]),
469
491
  _: 1
470
492
  })
471
493
  ]),
472
494
  _: 1
473
495
  }, 8, ["model"]),
474
- e(Q, {
496
+ e(X, {
475
497
  ref_key: "uploadRef",
476
- ref: I,
477
- modelValue: y.value,
478
- "onUpdate:modelValue": o[0] || (o[0] = (v) => y.value = v),
479
- onUploadFileList: K
498
+ ref: M,
499
+ modelValue: N.value,
500
+ "onUpdate:modelValue": o[0] || (o[0] = (F) => N.value = F),
501
+ onUploadFileList: z
480
502
  }, null, 8, ["modelValue"])
481
503
  ], 64);
482
504
  };