@ibiz-template/vue3-components 0.5.7-alpha.6 → 0.5.7-alpha.9

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.
Files changed (40) hide show
  1. package/dist/index-vJ69ZIJV.js +1 -0
  2. package/dist/index.min.css +1 -1
  3. package/dist/index.system.min.js +1 -1
  4. package/dist/{xlsx-util-TVsJdNUI.js → xlsx-util-gM6xqNsx.js} +1 -1
  5. package/es/control/form/form-detail/form-mdctrl/form-mdctrl-md/form-mdctrl-md.css +1 -1
  6. package/es/control/grid/grid/grid.css +1 -1
  7. package/es/control/grid/grid/grid.mjs +1 -4
  8. package/es/control/search-bar/filter-mode-select/filter-mode-select.d.ts +5 -1
  9. package/es/control/search-bar/filter-mode-select/filter-mode-select.mjs +3 -1
  10. package/es/control/search-bar/filter-tree/filter-tree.mjs +13 -1
  11. package/es/control/search-bar/search-bar.mjs +1 -1
  12. package/es/panel-component/panel-app-login-view/index.d.ts +1 -0
  13. package/es/panel-component/panel-app-login-view/panel-app-login-view.css +1 -1
  14. package/es/panel-component/panel-app-login-view/panel-app-login-view.d.ts +1 -0
  15. package/es/panel-component/panel-app-login-view/panel-app-login-view.mjs +18 -1
  16. package/es/panel-component/panel-button/index.d.ts +2 -0
  17. package/es/panel-component/panel-button/panel-button.d.ts +2 -0
  18. package/es/panel-component/panel-button/panel-button.mjs +12 -4
  19. package/es/panel-component/user-message/user-message.mjs +1 -0
  20. package/es/util/app-drawer/app-drawer-component.mjs +14 -16
  21. package/es/util/app-modal/app-modal-component.mjs +12 -15
  22. package/es/util/open-view-util/open-view-util.mjs +6 -3
  23. package/es/view-engine/edit-view.engine.d.ts +14 -0
  24. package/es/view-engine/edit-view.engine.mjs +90 -0
  25. package/lib/control/form/form-detail/form-mdctrl/form-mdctrl-md/form-mdctrl-md.css +1 -1
  26. package/lib/control/grid/grid/grid.cjs +1 -4
  27. package/lib/control/grid/grid/grid.css +1 -1
  28. package/lib/control/search-bar/filter-mode-select/filter-mode-select.cjs +3 -1
  29. package/lib/control/search-bar/filter-tree/filter-tree.cjs +13 -1
  30. package/lib/control/search-bar/search-bar.cjs +1 -1
  31. package/lib/panel-component/panel-app-login-view/panel-app-login-view.cjs +18 -1
  32. package/lib/panel-component/panel-app-login-view/panel-app-login-view.css +1 -1
  33. package/lib/panel-component/panel-button/panel-button.cjs +11 -3
  34. package/lib/panel-component/user-message/user-message.cjs +1 -0
  35. package/lib/util/app-drawer/app-drawer-component.cjs +13 -15
  36. package/lib/util/app-modal/app-modal-component.cjs +11 -14
  37. package/lib/util/open-view-util/open-view-util.cjs +6 -3
  38. package/lib/view-engine/edit-view.engine.cjs +90 -0
  39. package/package.json +5 -5
  40. package/dist/index-CzVC8rhd.js +0 -1
@@ -9,6 +9,7 @@ require('./filter-tree.css');
9
9
  function _isSlot(s) {
10
10
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !vue.isVNode(s);
11
11
  }
12
+ const ScriptValueRegex = /\$\{[^}]*\}/;
12
13
  const FilterModes = [{
13
14
  valueOP: runtime.ValueOP.EQ,
14
15
  label: "\u7B49\u4E8E(=)"
@@ -121,10 +122,12 @@ const FilterTreeControl = /* @__PURE__ */ vue.defineComponent({
121
122
  }
122
123
  });
123
124
  const onFieldSelect = (node, field) => {
125
+ node.value = null;
124
126
  node.field = field;
125
127
  };
126
128
  const onValueOPSelect = (node, valueOP) => {
127
129
  node.valueOP = valueOP;
130
+ node.value = null;
128
131
  };
129
132
  const onGroupLogicTypeChange = (node, logicType) => {
130
133
  node.logicType = logicType;
@@ -154,11 +157,18 @@ const FilterTreeControl = /* @__PURE__ */ vue.defineComponent({
154
157
  return null;
155
158
  }
156
159
  let editor = null;
160
+ let editorValue = node.value;
161
+ if (node.disabled && ScriptValueRegex.test(editorValue)) {
162
+ editorValue = editorValue.replace("${context.srfpersonid}", "\u5F53\u524D\u7528\u6237");
163
+ editorValue = editorValue.replace("${context.srforgid}", "\u5F53\u524D\u7EC4\u7EC7");
164
+ }
157
165
  if (filterC.editorProvider) {
158
166
  const component = vue.resolveComponent(filterC.editorProvider.formEditor);
159
167
  editor = vue.h(component, {
160
- value: node.value,
168
+ key: filterC.editor.model.id,
169
+ value: editorValue,
161
170
  controller: filterC.editor,
171
+ disabled: node.disabled,
162
172
  data: {},
163
173
  onChange: (val) => {
164
174
  node.value = val;
@@ -180,6 +190,7 @@ const FilterTreeControl = /* @__PURE__ */ vue.defineComponent({
180
190
  return vue.createVNode("div", {
181
191
  "class": ns.b("item")
182
192
  }, [vue.createVNode(vue.resolveComponent("el-select"), {
193
+ "disabled": node.disabled,
183
194
  "model-value": node.field,
184
195
  "teleported": false,
185
196
  "class": ns.e("field-select"),
@@ -195,6 +206,7 @@ const FilterTreeControl = /* @__PURE__ */ vue.defineComponent({
195
206
  })) ? _slot : {
196
207
  default: () => [_slot]
197
208
  }), availableModes && availableModes.length > 0 && vue.createVNode(vue.resolveComponent("iBizFilterModeSelect"), {
209
+ "disabled": node.disabled,
198
210
  "class": ns.e("mode-select"),
199
211
  "value": node.valueOP,
200
212
  "modes": availableModes,
@@ -120,7 +120,7 @@ const SearchBarControl = /* @__PURE__ */ vue.defineComponent({
120
120
  }, [groupItem.caption]);
121
121
  })])), this.c.model.enableGroup && this.c.isBackendSearchGroup && vue.createVNode(vue.resolveComponent("el-button"), {
122
122
  "class": this.ns.b("save"),
123
- "title": "\u4FDD\u5B58",
123
+ "title": "\u4FDD\u5B58\u5206\u7EC4",
124
124
  "onClick": this.handleSave
125
125
  }, {
126
126
  default: () => [vue.createVNode("ion-icon", {
@@ -31,9 +31,25 @@ const PanelAppLoginView = /* @__PURE__ */ vue.defineComponent({
31
31
  result = [...result, ...props.controller.containerClass, ns.is("hidden", !props.controller.state.visible)];
32
32
  return result;
33
33
  });
34
+ const cssVars = vue.computed(() => {
35
+ let styles = {};
36
+ const pathName = window.location.pathname;
37
+ if (pathName) {
38
+ const lastIndex = pathName.lastIndexOf("/");
39
+ if (lastIndex !== -1) {
40
+ const path = pathName.substring(0, lastIndex + 1);
41
+ styles = {
42
+ "header-url": "url('".concat(path, "assets/images/login-header.png')"),
43
+ "avatar-url": "url('".concat(path, "assets/images/login-avatar.png')")
44
+ };
45
+ }
46
+ }
47
+ return ns.cssVarBlock(styles);
48
+ });
34
49
  return {
35
50
  ns,
36
- classArr
51
+ classArr,
52
+ cssVars
37
53
  };
38
54
  },
39
55
  render() {
@@ -59,6 +75,7 @@ const PanelAppLoginView = /* @__PURE__ */ vue.defineComponent({
59
75
  });
60
76
  return vue.createVNode("div", {
61
77
  "class": this.classArr,
78
+ "style": this.cssVars,
62
79
  "onClick": () => {
63
80
  this.controller.onClick();
64
81
  }
@@ -1 +1 @@
1
- .ibiz-panel-app-login-view{display:flex;align-items:center;justify-content:center;width:100vw;height:100vh;background:linear-gradient(120deg,#a1c4fd 0,#c2e9fb 100%);--el-color-primary:#409eff}.ibiz-panel-app-login-view .el-input{--el-input-text-color:#606266;--el-input-border-color:#dcdfe6;--el-input-hover-border-color:#c0c4cc;--el-input-icon-color:#a8abb2}.ibiz-panel-app-login-view .el-button{--el-button-text-color:var(--el-color-white);--el-button-bg-color:var(--el-color-primary);--el-button-border-color:var(--el-color-primary);--el-button-outline-color:var(--el-color-primary-light-5);--el-button-active-color:var(--el-color-primary-dark-2);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-link-text-color:var(--el-color-primary-light-5);--el-button-hover-bg-color:var(--el-color-primary-light-3);--el-button-hover-border-color:var(--el-color-primary-light-3);--el-button-active-bg-color:var(--el-color-primary-dark-2);--el-button-active-border-color:var(--el-color-primary-dark-2);--el-button-disabled-text-color:var(--el-color-white);--el-button-disabled-bg-color:var(--el-color-primary-light-5);--el-button-disabled-border-color:var(--el-color-primary-light-5)}.ibiz-panel-app-login-view .ibiz-panel-container--container1{width:430px;margin-bottom:80px}.ibiz-panel-app-login-view .ibiz-panel-container--container4{position:relative;height:150px;background:url(assets/images/login-header.png);background-size:100% 100%}.ibiz-panel-app-login-view .ibiz-panel-container--container4 .ibiz-rawitem{position:absolute;top:28%;left:50%;height:auto;font-size:var(--ibiz-font-size-header-2);font-weight:var(--ibiz-font-weight-bold);color:rgb(var(--ibiz-white));text-align:center;text-shadow:0 2px 6px rgba(0,0,0,.54);transform:translateX(-50%)}.ibiz-panel-app-login-view .ibiz-panel-container--container5{position:relative;height:380px;padding:100px 40px 40px;background:#fff}.ibiz-panel-app-login-view .ibiz-panel-container--container5 .el-input__inner:-webkit-autofill{box-shadow:0 0 0 1000px #fff inset;-webkit-text-fill-color:#606266}.ibiz-panel-app-login-view .ibiz-panel-container--container5 .el-input__prefix{width:20px;margin-left:-1px}.ibiz-panel-app-login-view .ibiz-panel-container--container5 ion-icon{font-size:16px}.ibiz-panel-app-login-view .ibiz-panel-container--container6{position:absolute;top:-50px;right:calc(50% - 50px);z-index:2;display:block;width:100px;height:100px;-webkit-user-select:none;-moz-user-select:none;user-select:none;background:url(assets/images/login-avatar.png);background-size:100% 100%;border:4px solid #fff;border-radius:50%}.ibiz-panel-app-login-view .ibiz-panel-container--container3>.ibiz-row>*+*{margin-left:10px}.ibiz-panel-app-login-view .ibiz-panel-container--container3>.ibiz-row>.ibiz-col{flex:1}.ibiz-panel-app-login-view .ibiz-panel-container--container3 .ibiz-panel-button{width:100%;padding:0}.ibiz-panel-app-login-view .ibiz-panel-container--container3 .ibiz-panel-button .el-button{font-weight:300;letter-spacing:2px}
1
+ .ibiz-panel-app-login-view{--ibiz-panel-app-login-view-header-url:url("/assets/images/login-header.png");--ibiz-panel-app-login-view-avatar-url:url("/assets/images/login-avatar.png");display:flex;align-items:center;justify-content:center;width:100vw;height:100vh;background:linear-gradient(120deg,#a1c4fd 0,#c2e9fb 100%);--el-color-primary:#409eff}.ibiz-panel-app-login-view .el-input{--el-input-text-color:#606266;--el-input-border-color:#dcdfe6;--el-input-hover-border-color:#c0c4cc;--el-input-icon-color:#a8abb2}.ibiz-panel-app-login-view .el-button{--el-button-text-color:var(--el-color-white);--el-button-bg-color:var(--el-color-primary);--el-button-border-color:var(--el-color-primary);--el-button-outline-color:var(--el-color-primary-light-5);--el-button-active-color:var(--el-color-primary-dark-2);--el-button-hover-text-color:var(--el-color-white);--el-button-hover-link-text-color:var(--el-color-primary-light-5);--el-button-hover-bg-color:var(--el-color-primary-light-3);--el-button-hover-border-color:var(--el-color-primary-light-3);--el-button-active-bg-color:var(--el-color-primary-dark-2);--el-button-active-border-color:var(--el-color-primary-dark-2);--el-button-disabled-text-color:var(--el-color-white);--el-button-disabled-bg-color:var(--el-color-primary-light-5);--el-button-disabled-border-color:var(--el-color-primary-light-5)}.ibiz-panel-app-login-view .ibiz-panel-container--container1{width:430px;margin-bottom:80px}.ibiz-panel-app-login-view .ibiz-panel-container--container4{position:relative;height:150px;background:var(--ibiz-panel-app-login-view-header-url);background-size:100% 100%}.ibiz-panel-app-login-view .ibiz-panel-container--container4 .ibiz-rawitem{position:absolute;top:28%;left:50%;height:auto;font-size:var(--ibiz-font-size-header-2);font-weight:var(--ibiz-font-weight-bold);color:rgb(var(--ibiz-white));text-align:center;text-shadow:0 2px 6px rgba(0,0,0,.54);transform:translateX(-50%)}.ibiz-panel-app-login-view .ibiz-panel-container--container5{position:relative;height:380px;padding:100px 40px 40px;background:#fff}.ibiz-panel-app-login-view .ibiz-panel-container--container5 .el-input__inner:-webkit-autofill{box-shadow:0 0 0 1000px #fff inset;-webkit-text-fill-color:#606266}.ibiz-panel-app-login-view .ibiz-panel-container--container5 .el-input__prefix{width:20px;margin-left:-1px}.ibiz-panel-app-login-view .ibiz-panel-container--container5 ion-icon{font-size:16px}.ibiz-panel-app-login-view .ibiz-panel-container--container6{position:absolute;top:-50px;right:calc(50% - 50px);z-index:2;display:block;width:100px;height:100px;-webkit-user-select:none;-moz-user-select:none;user-select:none;background:var(--ibiz-panel-app-login-view-avatar-url);background-size:100% 100%;border:4px solid #fff;border-radius:50%}.ibiz-panel-app-login-view .ibiz-panel-container--container3>.ibiz-row>*+*{margin-left:10px}.ibiz-panel-app-login-view .ibiz-panel-container--container3>.ibiz-row>.ibiz-col{flex:1}.ibiz-panel-app-login-view .ibiz-panel-container--container3 .ibiz-panel-button{width:100%;padding:0}.ibiz-panel-app-login-view .ibiz-panel-container--container3 .ibiz-panel-button .el-button{font-weight:300;letter-spacing:2px}
@@ -30,12 +30,17 @@ const PanelButton = /* @__PURE__ */ vue.defineComponent({
30
30
  sysImage,
31
31
  codeName,
32
32
  itemStyle,
33
- tooltip
33
+ tooltip,
34
+ buttonCssStyle
34
35
  } = props.modelData;
35
36
  const {
36
37
  panel,
37
38
  state
38
39
  } = props.controller;
40
+ const tempStyle = vue.ref("");
41
+ if (buttonCssStyle) {
42
+ tempStyle.value = buttonCssStyle;
43
+ }
39
44
  const captionText = vue.computed(() => {
40
45
  if (captionItemName && panel.data) {
41
46
  return panel.data[captionItemName.toLowerCase()];
@@ -86,13 +91,16 @@ const PanelButton = /* @__PURE__ */ vue.defineComponent({
86
91
  codeName,
87
92
  state,
88
93
  tooltip,
89
- handleButtonClick
94
+ handleButtonClick,
95
+ buttonCssStyle,
96
+ tempStyle
90
97
  };
91
98
  },
92
99
  render() {
93
100
  if (this.state.visible) {
94
101
  return vue.createVNode("div", {
95
- "class": [this.ns.b(), this.ns.m(this.codeName), this.ns.is("loading", this.state.loading), ...this.controller.containerClass]
102
+ "class": [this.ns.b(), this.ns.m(this.codeName), this.ns.is("loading", this.state.loading), ...this.controller.containerClass],
103
+ "style": this.tempStyle
96
104
  }, [vue.createVNode(vue.resolveComponent("el-button"), {
97
105
  "type": this.buttonType,
98
106
  "text": this.isText,
@@ -49,6 +49,7 @@ const UserMessage = /* @__PURE__ */ vue.defineComponent({
49
49
  },
50
50
  render() {
51
51
  return vue.createVNode("div", {
52
+ "title": "\u901A\u77E5",
52
53
  "class": [this.ns.b(), this.ns.m(this.modelData.id), ...this.controller.containerClass]
53
54
  }, [vue.createVNode(vue.resolveComponent("el-popover"), {
54
55
  "ref": "popoverRef",
@@ -95,21 +95,19 @@ const AppDrawerComponent = /* @__PURE__ */ vue.defineComponent({
95
95
  };
96
96
  },
97
97
  render() {
98
- return vue.createVNode(vue.resolveComponent("el-drawer"), {
99
- "model-value": this.isShow,
100
- "lock-scroll": true,
101
- "size": this.size,
102
- "class": this.ns.b(),
103
- "z-index": this.drawerZIndex,
104
- "direction": this.direction,
105
- "before-close": this.onBeforeClose,
106
- "onClosed": this.onClosed
107
- }, {
108
- default: () => {
109
- var _a, _b;
110
- return [(_b = (_a = this.$slots).default) == null ? void 0 : _b.call(_a, this.modal)];
111
- }
112
- });
98
+ var _a, _b;
99
+ const option = this.opts || {};
100
+ return vue.h(vue.resolveComponent("el-drawer"), {
101
+ modelValue: this.isShow,
102
+ lockScroll: true,
103
+ size: this.size,
104
+ class: this.ns.b(),
105
+ zIndex: this.drawerZIndex,
106
+ direction: this.direction,
107
+ beforeClose: this.onBeforeClose,
108
+ onClosed: this.onClosed,
109
+ ...option
110
+ }, (_b = (_a = this.$slots).default) == null ? void 0 : _b.call(_a, this.modal));
113
111
  }
114
112
  });
115
113
  function createDrawer(render, opts) {
@@ -87,20 +87,17 @@ const AppModalComponent = /* @__PURE__ */ vue.defineComponent({
87
87
  };
88
88
  },
89
89
  render() {
90
- return vue.createVNode(vue.resolveComponent("el-dialog"), {
91
- "model-value": this.isShow,
92
- "align-center": true,
93
- "class": [this.ns.b(), this.options.placement && this.ns.m(this.options.placement), this.options.modalClass],
94
- "style": this.customStyle,
95
- "z-index": this.modalZIndex,
96
- "onClosed": this.onClosed,
97
- "before-close": this.onBeforeClose
98
- }, {
99
- default: () => {
100
- var _a, _b;
101
- return [(_b = (_a = this.$slots).default) == null ? void 0 : _b.call(_a, this.modal)];
102
- }
103
- });
90
+ var _a, _b;
91
+ return vue.h(vue.resolveComponent("el-dialog"), {
92
+ modelValue: this.isShow,
93
+ alignCenter: true,
94
+ class: [this.ns.b(), this.options.placement && this.ns.m(this.options.placement), this.options.modalClass],
95
+ style: this.customStyle,
96
+ zIndex: this.modalZIndex,
97
+ onClosed: this.onClosed,
98
+ onBeforeClose: this.onBeforeClose,
99
+ ...this.options
100
+ }, (_b = (_a = this.$slots).default) == null ? void 0 : _b.call(_a, this.modal));
104
101
  }
105
102
  });
106
103
  function createModal(render, opts) {
@@ -46,7 +46,8 @@ class OpenViewUtil {
46
46
  const opts = {
47
47
  width: appView.width || "80%",
48
48
  height: appView.height || "80%",
49
- footerHide: true
49
+ footerHide: true,
50
+ ...appView.modalOption
50
51
  };
51
52
  return vue3Util.openViewModal(
52
53
  {
@@ -64,7 +65,8 @@ class OpenViewUtil {
64
65
  height: appView.height,
65
66
  autoClose: true,
66
67
  placement: "bottom",
67
- ...options
68
+ ...options,
69
+ ...appView.modalOption
68
70
  };
69
71
  return vue3Util.openViewPopover(
70
72
  event,
@@ -92,7 +94,8 @@ class OpenViewUtil {
92
94
  const opts = {
93
95
  width: appView.width,
94
96
  height: appView.height,
95
- placement
97
+ placement,
98
+ ...appView.modalOption
96
99
  };
97
100
  return vue3Util.openViewDrawer(
98
101
  {
@@ -2,9 +2,26 @@
2
2
 
3
3
  var core = require('@ibiz-template/core');
4
4
  var runtime = require('@ibiz-template/runtime');
5
+ var ramda = require('ramda');
5
6
 
6
7
  "use strict";
8
+ var __defProp = Object.defineProperty;
9
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
10
+ var __publicField = (obj, key, value) => {
11
+ __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
12
+ return value;
13
+ };
7
14
  class EditViewEngine extends runtime.ViewEngineBase {
15
+ constructor() {
16
+ super(...arguments);
17
+ /**
18
+ * 实体名称
19
+ * @author lxm
20
+ * @date 2024-01-31 11:05:49
21
+ * @type {string}
22
+ */
23
+ __publicField(this, "deName");
24
+ }
8
25
  get form() {
9
26
  return this.view.getController("form");
10
27
  }
@@ -12,6 +29,7 @@ class EditViewEngine extends runtime.ViewEngineBase {
12
29
  await super.onCreated();
13
30
  const { childNames, modal } = this.view;
14
31
  childNames.push("form");
32
+ this.deName = runtime.calcDeCodeNameById(this.view.model.appDataEntityId);
15
33
  if (!this.view.slotProps.form) {
16
34
  this.view.slotProps.form = {};
17
35
  }
@@ -30,6 +48,7 @@ class EditViewEngine extends runtime.ViewEngineBase {
30
48
  }
31
49
  async onMounted() {
32
50
  await super.onMounted();
51
+ this.initMarkOpenData();
33
52
  const { model, evt } = this.view;
34
53
  const formDeId = this.form.model.appDataEntityId;
35
54
  const formDataStateChange = (event) => {
@@ -218,6 +237,77 @@ class EditViewEngine extends runtime.ViewEngineBase {
218
237
  );
219
238
  ibiz.mc.command.send({ srfdecodename: "SysTodo" }, "OBJECTUPDATED");
220
239
  }
240
+ /**
241
+ * 初始化标记打开数据相关逻辑
242
+ * @author lxm
243
+ * @date 2024-01-31 11:52:13
244
+ * @return {*} {void}
245
+ */
246
+ initMarkOpenData() {
247
+ if (ramda.isNil(this.view.modal.routeDepth)) {
248
+ return;
249
+ }
250
+ let srfkey;
251
+ const callback = (data) => {
252
+ if (!this.view.state.activated) {
253
+ return;
254
+ }
255
+ const dataInfo = this.form.getData()[0].srfmajortext;
256
+ let actionMsg = "";
257
+ switch (data.action) {
258
+ case "VIEW":
259
+ actionMsg = "\u6D4F\u89C8\u4E86";
260
+ break;
261
+ case "EDIT":
262
+ actionMsg = "\u7F16\u8F91\u4E86";
263
+ break;
264
+ case "UPDATE":
265
+ actionMsg = "\u66F4\u65B0\u4E86";
266
+ break;
267
+ default:
268
+ break;
269
+ }
270
+ ibiz.notification.info({
271
+ position: "bottom-right",
272
+ title: data.username,
273
+ desc: "".concat(actionMsg, " ").concat(this.view.state.caption, "-").concat(dataInfo)
274
+ });
275
+ };
276
+ this.form.evt.on("onLoadSuccess", (event) => {
277
+ const formData = event.data[0];
278
+ srfkey = formData.srfkey;
279
+ ibiz.markOpenData.action(this.deName, srfkey, "VIEW");
280
+ ibiz.markOpenData.subscribe(this.deName, srfkey, callback);
281
+ this.view.evt.on("onDestroyed", () => {
282
+ ibiz.markOpenData.unsubscribe(this.deName, srfkey, callback);
283
+ });
284
+ });
285
+ let isWait = false;
286
+ const actionEdit = () => {
287
+ if (!srfkey || isWait) {
288
+ return;
289
+ }
290
+ isWait = true;
291
+ ibiz.markOpenData.action(this.deName, srfkey, "EDIT");
292
+ setTimeout(
293
+ () => {
294
+ isWait = false;
295
+ },
296
+ 1e3 * 60 * 5
297
+ );
298
+ };
299
+ this.form.evt.on("onFormDataChange", actionEdit);
300
+ this.form.evt.on("onSaveSuccess", () => {
301
+ if (srfkey) {
302
+ ibiz.markOpenData.action(this.deName, srfkey, "UPDATE");
303
+ }
304
+ });
305
+ this.view.evt.on("onCloseView", () => {
306
+ if (srfkey) {
307
+ ibiz.markOpenData.action(this.deName, srfkey, "CLOSE");
308
+ }
309
+ });
310
+ }
221
311
  }
222
312
 
223
313
  exports.EditViewEngine = EditViewEngine;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ibiz-template/vue3-components",
3
- "version": "0.5.7-alpha.6",
3
+ "version": "0.5.7-alpha.9",
4
4
  "description": "使用 rollup 编译 vue 组件或者 jsx",
5
5
  "main": "lib/index.cjs",
6
6
  "module": "es/index.mjs",
@@ -27,11 +27,11 @@
27
27
  "@floating-ui/dom": "^1.5.3",
28
28
  "@ibiz-template-plugin/ai-chat": "^0.0.1",
29
29
  "@ibiz-template-plugin/gantt": "0.1.1",
30
- "@ibiz-template/core": "^0.5.7-alpha.6",
31
- "@ibiz-template/model-helper": "^0.5.7-alpha.6",
32
- "@ibiz-template/runtime": "^0.5.7-alpha.6",
30
+ "@ibiz-template/core": "^0.5.7-alpha.9",
31
+ "@ibiz-template/model-helper": "^0.5.7-alpha.9",
32
+ "@ibiz-template/runtime": "^0.5.7-alpha.9",
33
33
  "@ibiz-template/theme": "^0.5.0",
34
- "@ibiz-template/vue3-util": "^0.5.7-alpha.6",
34
+ "@ibiz-template/vue3-util": "^0.5.7-alpha.9",
35
35
  "@ibiz/model-core": "^0.1.9",
36
36
  "@imengyu/vue3-context-menu": "^1.3.5",
37
37
  "@monaco-editor/loader": "^1.4.0",