@web-utils/component 3.8.4 → 3.8.5

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,5 +1,6 @@
1
- import { n as g } from "./_plugin-vue2_normalizer.CeySl7Fu.mjs";
2
- const b = {
1
+ import { getBusinessObject as b, is as g } from "bpmn-js/lib/util/ModelUtil";
2
+ import { n as h } from "./_plugin-vue2_normalizer.CeySl7Fu.mjs";
3
+ const y = {
3
4
  name: "ServiceTaskConfig",
4
5
  props: {
5
6
  id: String,
@@ -26,14 +27,14 @@ const b = {
26
27
  id: {
27
28
  immediate: !0,
28
29
  handler() {
29
- var n, e, t, s, i, l, a, r, c, o, f, m, p, d;
30
+ var n, e, t, s, l, a, i, o, c, r, m, d, f, p;
30
31
  if (!((e = (n = this.element) == null ? void 0 : n.businessObject) != null && e.delegateExpression) && !((s = (t = this.element) == null ? void 0 : t.businessObject) != null && s.class) && (this.config.async = !0, this.config.exclusive = !0, this.bpmnInstances.modeling.updateProperties(this.element, {
31
32
  async: !0,
32
33
  exclusive: !0,
33
34
  class: void 0,
34
35
  delegateExpression: void 0,
35
36
  failedJobRetryTimeCycle: "R3/PT60S"
36
- })), this.config.async = (l = (i = this.element) == null ? void 0 : i.businessObject) == null ? void 0 : l.async, this.config.exclusive = (r = (a = this.element) == null ? void 0 : a.businessObject) == null ? void 0 : r.exclusive, this.config.class = (o = (c = this.element) == null ? void 0 : c.businessObject) == null ? void 0 : o.class, this.config.delegateExpression = (m = (f = this.element) == null ? void 0 : f.businessObject) == null ? void 0 : m.delegateExpression, this.config.failedJobRetryTimeCycle = (d = (p = this.element) == null ? void 0 : p.businessObject) == null ? void 0 : d.failedJobRetryTimeCycle, this.config.failedJobRetryTimeCycle) {
37
+ })), this.config.async = (a = (l = this.element) == null ? void 0 : l.businessObject) == null ? void 0 : a.async, this.config.exclusive = (o = (i = this.element) == null ? void 0 : i.businessObject) == null ? void 0 : o.exclusive, this.config.class = (r = (c = this.element) == null ? void 0 : c.businessObject) == null ? void 0 : r.class, this.config.delegateExpression = (d = (m = this.element) == null ? void 0 : m.businessObject) == null ? void 0 : d.delegateExpression, this.config.failedJobRetryTimeCycle = (p = (f = this.element) == null ? void 0 : f.businessObject) == null ? void 0 : p.failedJobRetryTimeCycle, this.config.failedJobRetryTimeCycle) {
37
38
  const u = this.config.failedJobRetryTimeCycle.split("/");
38
39
  this.form.retry = Number(u[0].replace("R", "")) || 3, this.form.interval = u[1].replace("PT", "") || "60S";
39
40
  }
@@ -43,17 +44,23 @@ const b = {
43
44
  },
44
45
  methods: {
45
46
  retryInput(n) {
46
- const e = n != null ? n : 3, t = this.form.interval || "60S";
47
- this.bpmnInstances.modeling.updateProperties(this.element, {
48
- failedJobRetryTimeCycle: `R${e}/PT${t}`
49
- });
47
+ const e = n != null ? n : 3, t = this.form.interval || "60S", l = b(this.element).get("extensionElements") || this.bpmnInstances.moddle.create("bpmn:ExtensionElements");
48
+ l.set(
49
+ "values",
50
+ l.get("values").filter((i) => !g(i, "flowable:FailedJobRetryTimeCycle"))
51
+ );
52
+ const a = this.bpmnInstances.moddle.create("flowable:FailedJobRetryTimeCycle", { body: `R${e}/PT${t}` });
53
+ l.get("values").push(a), this.bpmnInstances.modeling.updateProperties(this.element, { extensionElements: l });
50
54
  },
51
55
  intervalInput(n) {
52
- var s;
53
- const e = (s = this.form.retry) != null ? s : 3, t = n || "60S";
54
- this.bpmnInstances.modeling.updateProperties(this.element, {
55
- failedJobRetryTimeCycle: `R${e}/PT${t}`
56
- });
56
+ var i;
57
+ const e = (i = this.form.retry) != null ? i : 3, t = n || "60S", l = b(this.element).get("extensionElements") || this.bpmnInstances.moddle.create("bpmn:ExtensionElements");
58
+ l.set(
59
+ "values",
60
+ l.get("values").filter((o) => !g(o, "flowable:FailedJobRetryTimeCycle"))
61
+ );
62
+ const a = this.bpmnInstances.moddle.create("flowable:FailedJobRetryTimeCycle", { body: `R${e}/PT${t}` });
63
+ l.get("values").push(a), this.bpmnInstances.modeling.updateProperties(this.element, { extensionElements: l });
57
64
  },
58
65
  clear() {
59
66
  this.config.class = void 0, this.config.delegateExpression = void 0, this.bpmnInstances.modeling.updateProperties(this.element, {
@@ -79,7 +86,7 @@ const b = {
79
86
  }
80
87
  }
81
88
  };
82
- var h = function() {
89
+ var x = function() {
83
90
  var e = this, t = e._self._c;
84
91
  return t("div", { staticClass: "panel-tab__content" }, [t("ElForm", { attrs: { size: "mini", "label-width": "90px" }, nativeOn: { submit: function(s) {
85
92
  s.preventDefault();
@@ -98,15 +105,15 @@ var h = function() {
98
105
  }, expression: "form.retry" } })], 1), t("ElFormItem", { staticStyle: { flex: "1", width: "0", "margin-top": "0", "margin-left": "10px" }, attrs: { "label-width": "40px", label: "间隔" } }, [t("ElInput", { attrs: { clearable: "" }, on: { input: e.intervalInput }, model: { value: e.form.interval, callback: function(s) {
99
106
  e.$set(e.form, "interval", s);
100
107
  }, expression: "form.interval" } })], 1)], 1)]) : e._e()], 1)], 1);
101
- }, y = [], x = /* @__PURE__ */ g(
102
- b,
103
- h,
108
+ }, v = [], E = /* @__PURE__ */ h(
104
109
  y,
110
+ x,
111
+ v,
105
112
  !1,
106
113
  null,
107
114
  null
108
115
  );
109
- const E = x.exports;
116
+ const _ = E.exports;
110
117
  export {
111
- E as default
118
+ _ as default
112
119
  };
@@ -495,7 +495,7 @@ const je = {
495
495
  ElementTaskConfig: () => import("../chunks/ElementTaskConfig.MBbkLrth.mjs"),
496
496
  ElementOtherConfig: () => import("../chunks/ElementOtherConfig.B1NfMTYh.mjs"),
497
497
  ElementBaseInfo: () => import("../chunks/ElementBaseInfo.ZADwixb5.mjs"),
498
- ServiceTaskConfig: () => import("../chunks/ServiceTaskConfig.BYzwAxGU.mjs")
498
+ ServiceTaskConfig: () => import("../chunks/ServiceTaskConfig.DNbFd8j0.mjs")
499
499
  },
500
500
  provide() {
501
501
  return {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@web-utils/component",
3
3
  "description": "Web Components",
4
- "version": "3.8.4",
4
+ "version": "3.8.5",
5
5
  "author": "Simple",
6
6
  "license": "MIT",
7
7
  "type": "module",
package/web-types.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://json.schemastore.org/web-types",
3
3
  "framework": "vue",
4
4
  "name": "@web-utils/component",
5
- "version": "3.8.4",
5
+ "version": "3.8.5",
6
6
  "contributions": {
7
7
  "html": {
8
8
  "description-markup": "markdown",