提交 4641b2f7 编写于 作者: jlj05024111@163.com's avatar jlj05024111@163.com

feat: 更新dsf插件包

上级 85d128f4
var de = Object.defineProperty; var de = Object.defineProperty;
var ue = (s, e, t) => e in s ? de(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t; var ue = (s, a, e) => a in s ? de(s, a, { enumerable: !0, configurable: !0, writable: !0, value: e }) : s[a] = e;
var C = (s, e, t) => (ue(s, typeof e != "symbol" ? e + "" : e, t), t); var P = (s, a, e) => (ue(s, typeof a != "symbol" ? a + "" : a, e), e);
import { EditFormModel as me, FormMDCtrlModel as pe, DefectModelError as he, AppEntityModel as H } from "@ibiz-template/model"; import { EditFormModel as me, FormMDCtrlModel as pe, DefectModelError as he, AppEntityModel as H } from "@ibiz-template/model";
import { useNamespace as B, useControlController as fe, usePropsWatch as ve, getDatePickerProps as ye, getEditorEmits as G, useController as ge, getDataPickerProps as se, useViewController as we } from "@ibiz-template/vue-util"; import { useNamespace as B, useControlController as fe, usePropsWatch as ve, getDatePickerProps as ye, getEditorEmits as G, useController as ge, getDataPickerProps as se, useViewController as we } from "@ibiz-template/vue-util";
import { defineComponent as M, getCurrentInstance as W, ref as b, watch as V, h as r, onMounted as De, computed as j } from "vue"; import { defineComponent as M, getCurrentInstance as W, ref as A, watch as V, h as r, onMounted as De, computed as j } from "vue";
import { createUUID as te } from "qx-util"; import { createUUID as te } from "qx-util";
import { ViewMode as ae, PluginStaticResource as Ee, OpenAppViewCommand as q, UIActionHandler as Ce, FrontUIActionHandler as re } from "@ibiz-template/runtime"; import { ViewMode as ae, PluginStaticResource as Ce, OpenAppViewCommand as q, UIActionHandler as Ee, FrontUIActionHandler as re } from "@ibiz-template/runtime";
import { EditFormController as be, FormMDCtrlController as Pe, FormDRUIPartController as Ae, EditViewController as Fe, DatePickerEditorController as Ie, UploadEditorController as Se, PickerEditorController as oe } from "@ibiz-template/controller"; import { EditFormController as be, FormMDCtrlController as Pe, FormDRUIPartController as Ae, EditViewController as Fe, DatePickerEditorController as Ie, UploadEditorController as Se, PickerEditorController as oe } from "@ibiz-template/controller";
import { ControlVO as xe, calcResPath as K } from "@ibiz-template/service"; import { ControlVO as ke, calcResPath as K } from "@ibiz-template/service";
import $ from "dayjs"; import $ from "dayjs";
import { RuntimeError as ke, StringUtil as ne } from "@ibiz-template/core"; import { RuntimeError as xe, StringUtil as ne } from "@ibiz-template/core";
class Ne extends be { class Ne extends be {
constructor() { constructor() {
super(...arguments); super(...arguments);
...@@ -20,7 +20,7 @@ class Ne extends be { ...@@ -20,7 +20,7 @@ class Ne extends be {
* @date 2024-04-26 17:04:49 * @date 2024-04-26 17:04:49
* @type {IData} * @type {IData}
*/ */
C(this, "baseResData", []); P(this, "baseResData", []);
/** /**
* 对比数据 * 对比数据
* *
...@@ -28,7 +28,7 @@ class Ne extends be { ...@@ -28,7 +28,7 @@ class Ne extends be {
* @date 2024-04-26 17:04:49 * @date 2024-04-26 17:04:49
* @type {IData} * @type {IData}
*/ */
C(this, "compareResData", []); P(this, "compareResData", []);
/** /**
* 表单旧数据 * 表单旧数据
* *
...@@ -38,7 +38,7 @@ class Ne extends be { ...@@ -38,7 +38,7 @@ class Ne extends be {
* @type {IData} * @type {IData}
* @memberof FormController * @memberof FormController
*/ */
C(this, "oldData", new xe()); P(this, "oldData", new ke());
/** /**
* version数据 * version数据
* *
...@@ -46,7 +46,7 @@ class Ne extends be { ...@@ -46,7 +46,7 @@ class Ne extends be {
* @date 2024-04-26 16:04:37 * @date 2024-04-26 16:04:37
* @type {IData[]} * @type {IData[]}
*/ */
C(this, "versionData", []); P(this, "versionData", []);
/** /**
* 对比数据 * 对比数据
* *
...@@ -54,7 +54,7 @@ class Ne extends be { ...@@ -54,7 +54,7 @@ class Ne extends be {
* @date 2024-04-26 16:04:37 * @date 2024-04-26 16:04:37
* @type {IData[]} * @type {IData[]}
*/ */
C(this, "comparisonArr", {}); P(this, "comparisonArr", {});
/** /**
* 基础表格数据 * 基础表格数据
* *
...@@ -62,7 +62,7 @@ class Ne extends be { ...@@ -62,7 +62,7 @@ class Ne extends be {
* @date 2024-05-06 11:05:57 * @date 2024-05-06 11:05:57
* @type {IData[]} * @type {IData[]}
*/ */
C(this, "gridData", []); P(this, "gridData", []);
/** /**
* 展示完全数据 * 展示完全数据
* *
...@@ -70,7 +70,7 @@ class Ne extends be { ...@@ -70,7 +70,7 @@ class Ne extends be {
* @date 2024-05-06 11:05:04 * @date 2024-05-06 11:05:04
* @type {IData[]} * @type {IData[]}
*/ */
C(this, "AllGridData", []); P(this, "AllGridData", []);
/** /**
* 去除相同数据 * 去除相同数据
* *
...@@ -78,7 +78,7 @@ class Ne extends be { ...@@ -78,7 +78,7 @@ class Ne extends be {
* @date 2024-05-06 11:05:15 * @date 2024-05-06 11:05:15
* @type {IData[]} * @type {IData[]}
*/ */
C(this, "removeSameGridData", []); P(this, "removeSameGridData", []);
/** /**
* 关系界面数据 * 关系界面数据
* *
...@@ -86,7 +86,7 @@ class Ne extends be { ...@@ -86,7 +86,7 @@ class Ne extends be {
* @date 2024-04-30 10:04:33 * @date 2024-04-30 10:04:33
* @type {IData} * @type {IData}
*/ */
C(this, "AlldruipartData", /* @__PURE__ */ new Map()); P(this, "AlldruipartData", /* @__PURE__ */ new Map());
/** /**
* 关系界面数据长度 * 关系界面数据长度
* *
...@@ -94,7 +94,7 @@ class Ne extends be { ...@@ -94,7 +94,7 @@ class Ne extends be {
* @date 2024-05-06 11:05:56 * @date 2024-05-06 11:05:56
* @type {number} * @type {number}
*/ */
C(this, "druipartDataSize", 0); P(this, "druipartDataSize", 0);
/** /**
* 关系界面实际数据 * 关系界面实际数据
* *
...@@ -102,7 +102,7 @@ class Ne extends be { ...@@ -102,7 +102,7 @@ class Ne extends be {
* @date 2024-05-06 11:05:13 * @date 2024-05-06 11:05:13
* @type {IData} * @type {IData}
*/ */
C(this, "newDruipartData", {}); P(this, "newDruipartData", {});
} }
/** /**
* 加载数据 * 加载数据
...@@ -112,18 +112,18 @@ class Ne extends be { ...@@ -112,18 +112,18 @@ class Ne extends be {
*/ */
async loadGridData() { async loadGridData() {
await this.startLoading(); await this.startLoading();
const t = this.model.source.M.getPSControlParam.ctrlParams, { BASEENTITY: a, COMPAREENTITY: c } = t, n = await ibiz.entityService.getService(a), d = await ibiz.entityService.getService(c), v = Object.assign({}, this.context.clone(), { const e = this.model.source.M.getPSControlParam.ctrlParams, { BASEENTITY: t, COMPAREENTITY: i } = e, n = await ibiz.entityService.getService(t), c = await ibiz.entityService.getService(i), g = Object.assign({}, this.context.clone(), {
[a.toLowerCase()]: this.params.base_version [t.toLowerCase()]: this.params.base_version
}), p = Object.assign({}, this.context.clone(), { }), u = Object.assign({}, this.context.clone(), {
[c.toLowerCase()]: this.params.compare_version [i.toLowerCase()]: this.params.compare_version
}), h = await n.exec("Get", v, this.params), g = await d.exec( }), m = await n.exec("Get", g, this.params), w = await c.exec(
"Get", "Get",
p, u,
this.params this.params
); );
return this.isLoaded = !0, { return this.isLoaded = !0, {
baseData: h.data.data, baseData: m.data.data,
compareData: g.data.data compareData: w.data.data
}; };
} }
/** /**
...@@ -133,8 +133,8 @@ class Ne extends be { ...@@ -133,8 +133,8 @@ class Ne extends be {
* @return {*} * @return {*}
* @memberof FormDataComparisonController * @memberof FormDataComparisonController
*/ */
isFalseyButNotEmpty(t) { isFalseyButNotEmpty(e) {
return t == null || typeof t == "string" && t === "" || Array.isArray(t) && t.length === 0 || typeof t == "object" && Object.keys(t).length === 0; return e == null || typeof e == "string" && e === "" || Array.isArray(e) && e.length === 0 || typeof e == "object" && Object.keys(e).length === 0;
} }
/** /**
* 比较两个值 * 比较两个值
...@@ -144,8 +144,8 @@ class Ne extends be { ...@@ -144,8 +144,8 @@ class Ne extends be {
* @return {*} * @return {*}
* @memberof FormDataComparisonController * @memberof FormDataComparisonController
*/ */
compareObjectValues(t, a) { compareObjectValues(e, t) {
return JSON.stringify(t) !== JSON.stringify(a); return JSON.stringify(e) !== JSON.stringify(t);
} }
} }
const Oe = M({ const Oe = M({
...@@ -169,73 +169,73 @@ const Oe = M({ ...@@ -169,73 +169,73 @@ const Oe = M({
} }
}, },
setup(s) { setup(s) {
const e = B("form-data-comparison"), { const a = B("form-data-comparison"), {
proxy: t proxy: e
} = W(), a = fe(t, () => { } = W(), t = fe(e, () => {
const o = new Ne(s.modelData, s.context, s.params); const o = new Ne(s.modelData, s.context, s.params);
return ve(t, "enableAutoSave", o.setEnableAutoSave.bind(o)), o; return ve(e, "enableAutoSave", o.setEnableAutoSave.bind(o)), o;
}), c = b(!0), n = b(!1), d = b({}), v = b({}), p = b([]), h = [], g = b([]), i = b([]), y = b([]), f = /* @__PURE__ */ new Map(), u = b(0), l = (o) => { }), i = A(!0), n = A(!1), c = A({}), g = A({}), u = A([]), m = [], w = A([]), l = A([]), v = A([]), f = /* @__PURE__ */ new Map(), C = A(0), h = (o) => {
const m = []; const d = [];
if (m.push(o), o && o.children) { if (d.push(o), o && o.children) {
const A = []; const b = [];
o.children.forEach((F) => { o.children.forEach((S) => {
const O = l(F); const x = h(S);
A.push(...O); b.push(...x);
}), m.push(...A); }), d.push(...b);
} }
return m; return d;
}, w = l(s.modelData); }, p = h(s.modelData);
h.push(...w); m.push(...p);
const E = (o) => { const y = (o) => {
const m = a.details[o.source.name], A = r("not-supported-editor", { const d = t.details[o.source.name], b = r("not-supported-editor", {
attrs: { attrs: {
modelData: o.editor modelData: o.editor
} }
}); });
return r("div", { return r("div", {
class: [e.e("form-grid-item"), e.is("add", g.value.includes(o.source.name)), e.is("update", y.value.includes(o.source.name)), e.is("delete", i.value.includes(o.source.name))] class: [a.e("form-grid-item"), a.is("add", w.value.includes(o.source.name)), a.is("update", v.value.includes(o.source.name)), a.is("delete", l.value.includes(o.source.name))]
}, [r("div", { }, [r("div", {
class: e.em("form-grid-item", "name") class: a.em("form-grid-item", "name")
}, [o.source.caption]), r("div", { }, [o.source.caption]), r("div", {
class: e.em("form-grid-item", "left") class: a.em("form-grid-item", "left")
}, [m.editorProvider ? r(m.editorProvider.formEditor, { }, [d.editorProvider ? r(d.editorProvider.formEditor, {
props: { props: {
value: v.value[o.source.name], value: g.value[o.source.name],
data: m.data, data: d.data,
controller: m.editor, controller: d.editor,
disabled: m.disabled, disabled: d.disabled,
readonly: !0 readonly: !0
} }
}) : A]), r("div", { }) : b]), r("div", {
class: e.em("form-grid-item", "right") class: a.em("form-grid-item", "right")
}, [m.editorProvider ? r(m.editorProvider.formEditor, { }, [d.editorProvider ? r(d.editorProvider.formEditor, {
props: { props: {
value: d.value[o.source.name], value: c.value[o.source.name],
data: m.data, data: d.data,
controller: m.editor, controller: d.editor,
disabled: m.disabled, disabled: d.disabled,
readonly: !0 readonly: !0
} }
}) : A])]); }) : b])]);
}, I = (o, m) => { }, F = (o, d) => {
f.set(o.source.id, m), m.evt.on("mounted", () => { f.set(o.source.id, d), d.evt.on("mounted", () => {
c.value && a.startLoading(), u.value += 1, m.call.refresh(); i.value && t.startLoading(), C.value += 1, d.call.refresh();
}), m.evt.on("refreshed", () => { }), d.evt.on("refreshed", () => {
u.value -= 1, setTimeout(() => { C.value -= 1, setTimeout(() => {
c.value && a.endLoading(); i.value && t.endLoading();
}, 500); }, 500);
}); });
}, D = (o) => { }, I = (o) => {
const m = h.find((L) => L.id === `${o.source.id}_srfcopy`), A = o.embedView.source.modelPath, F = m == null ? void 0 : m.embedView.source.modelPath, O = a.context.clone(), N = { const d = m.find((L) => L.id === `${o.source.id}_srfcopy`), b = o.embedView.source.modelPath, S = d == null ? void 0 : d.embedView.source.modelPath, x = t.context.clone(), N = {
base_version: s.params.base_version base_version: s.params.base_version
}, T = a.context.clone(); }, T = t.context.clone();
Object.assign(T, { Object.assign(T, {
gysrlzy_info: s.params.compare_version, gysrlzy_info: s.params.compare_version,
compare_version: s.params.compare_version compare_version: s.params.compare_version
}); });
const _ = { const _ = {
compare_version: s.params.compare_version compare_version: s.params.compare_version
}, R = d.value[o.source.userTag], U = v.value[m == null ? void 0 : m.source.userTag]; }, R = c.value[o.source.userTag], U = g.value[d == null ? void 0 : d.source.userTag];
let J = !1, z = !1, X = !1; let J = !1, z = !1, X = !1;
if (o.source.userTag2) { if (o.source.userTag2) {
const L = JSON.parse(o.source.userTag2), { const L = JSON.parse(o.source.userTag2), {
...@@ -248,149 +248,149 @@ const Oe = M({ ...@@ -248,149 +248,149 @@ const Oe = M({
}))); })));
} }
return r("div", { return r("div", {
class: [e.e("druipart"), e.is("add", J), e.is("update", z), e.is("delete", X)] class: [a.e("druipart"), a.is("add", J), a.is("update", z), a.is("delete", X)]
}, [r("div", { }, [r("div", {
class: e.em("druipart", "caption") class: a.em("druipart", "caption")
}, [o.source.caption]), r("div", { }, [o.source.caption]), r("div", {
class: e.em("druipart", "left") class: a.em("druipart", "left")
}, [F && r("ViewShell", { }, [S && r("ViewShell", {
attrs: { attrs: {
context: T, context: T,
params: _, params: _,
modal: { modal: {
mode: ae.EMBED mode: ae.EMBED
}, },
modelPath: F, modelPath: S,
noLoadDefault: !0, noLoadDefault: !0,
name: m == null ? void 0 : m.source.id name: d == null ? void 0 : d.source.id
}, },
key: te(), key: te(),
on: { on: {
neuronInit: (L) => I(m, L) neuronInit: (L) => F(d, L)
} }
})]), r("div", { })]), r("div", {
class: e.em("druipart", "right") class: a.em("druipart", "right")
}, [A && r("ViewShell", { }, [b && r("ViewShell", {
attrs: { attrs: {
context: O, context: x,
params: N, params: N,
modal: { modal: {
mode: ae.EMBED mode: ae.EMBED
}, },
modelPath: A, modelPath: b,
noLoadDefault: !0, noLoadDefault: !0,
name: o.source.id name: o.source.id
}, },
key: te(), key: te(),
on: { on: {
neuronInit: (L) => I(o, L) neuronInit: (L) => F(o, L)
} }
})])]); })])]);
}, P = (o) => { }, D = (o) => {
const m = { const d = {
modelData: o, modelData: o,
controller: a.details[o.source.name] controller: t.details[o.source.name]
}, A = a.providers[o.source.name], F = r(A.component, { }, b = t.providers[o.source.name], S = r(b.component, {
props: { props: {
...m ...d
}, },
key: o.id key: o.id
}), O = r(A.component, { }), x = r(b.component, {
props: { props: {
...m ...d
}, },
key: `compare_${o.id}` key: `compare_${o.id}`
}); });
return r("div", { return r("div", {
class: e.e("mdctrl") class: a.e("mdctrl")
}, [r("div", { }, [r("div", {
class: e.em("mdctrl", "caption") class: a.em("mdctrl", "caption")
}, [o.source.caption]), r("div", { }, [o.source.caption]), r("div", {
class: e.em("mdctrl", "left") class: a.em("mdctrl", "left")
}, [F]), r("div", { }, [S]), r("div", {
class: e.em("mdctrl", "right") class: a.em("mdctrl", "right")
}, [O])]); }, [x])]);
}, S = (o) => { }, E = (o) => {
c.value = !1; i.value = !1;
const m = p.value.findIndex((A) => A === o.source.name); const d = u.value.findIndex((b) => b === o.source.name);
m > -1 ? p.value.splice(m, 1) : p.value.push(o.source.name); d > -1 ? u.value.splice(d, 1) : u.value.push(o.source.name);
}, k = (o) => { }, k = (o) => {
if (!o.source.hidden) { if (!o.source.hidden) {
if (o.source.detailType === "FORMPAGE") if (o.source.detailType === "FORMPAGE")
return r("div", { return r("div", {
class: e.e("form-page") class: a.e("form-page")
}, [o.children.map((m) => k(m))]); }, [o.children.map((d) => k(d))]);
if (o.source.detailType === "FORMITEM") { if (o.source.detailType === "FORMITEM") {
const m = g.value.includes(o.source.name), A = i.value.includes(o.source.name), F = y.value.includes(o.source.name); const d = w.value.includes(o.source.name), b = l.value.includes(o.source.name), S = v.value.includes(o.source.name);
return n.value && !m && !A && !F ? null : E(o); return n.value && !d && !b && !S ? null : y(o);
} }
if (o.source.detailType === "GROUPPANEL") { if (o.source.detailType === "GROUPPANEL") {
const m = p.value.includes(o.source.name); const d = u.value.includes(o.source.name);
return r("div", { return r("div", {
class: e.b("group") class: a.b("group")
}, [r("div", { }, [r("div", {
class: [e.be("group", "header"), e.is("hide-caption", !o.source.showCaption)] class: [a.be("group", "header"), a.is("hide-caption", !o.source.showCaption)]
}, [r("div", { }, [r("div", {
class: e.bem("group", "header", "name") class: a.bem("group", "header", "name")
}, [m ? r("i-icon", { }, [d ? r("i-icon", {
class: e.bem("group", "header", "icon"), class: a.bem("group", "header", "icon"),
attrs: { attrs: {
type: "ios-arrow-forward", type: "ios-arrow-forward",
title: "展开" title: "展开"
}, },
on: { on: {
click: () => S(o) click: () => E(o)
} }
}) : r("i-icon", { }) : r("i-icon", {
class: e.bem("group", "header", "icon"), class: a.bem("group", "header", "icon"),
attrs: { attrs: {
type: "ios-arrow-down", type: "ios-arrow-down",
title: "收缩" title: "收缩"
}, },
on: { on: {
click: () => S(o) click: () => E(o)
} }
}), r("span", { }), r("span", {
class: e.bem("group", "header", "name-text") class: a.bem("group", "header", "name-text")
}, [o.source.caption || o.source.title])]), r("div", ["---"]), r("div", ["---"])]), r("div", { }, [o.source.caption || o.source.title])]), r("div", ["---"]), r("div", ["---"])]), r("div", {
class: [e.be("group", "content"), e.is("collapse", m)] class: [a.be("group", "content"), a.is("collapse", d)]
}, [o.children.map((A) => k(A))])]); }, [o.children.map((b) => k(b))])]);
} }
return o.source.detailType === "DRUIPART" && !o.source.name.endsWith("_srfcopy") ? D(o) : o.source.detailType === "MDCTRL" ? P(o) : null; return o.source.detailType === "DRUIPART" && !o.source.name.endsWith("_srfcopy") ? I(o) : o.source.detailType === "MDCTRL" ? D(o) : null;
} }
}, x = (o, m) => { }, O = (o, d) => {
const A = [], F = [], O = []; const b = [], S = [], x = [];
return Object.keys(m).forEach((N) => { return Object.keys(d).forEach((N) => {
const T = o[N], _ = m[N]; const T = o[N], _ = d[N];
a.isFalseyButNotEmpty(T) && !a.isFalseyButNotEmpty(_) && A.push(N), !a.isFalseyButNotEmpty(T) && !a.isFalseyButNotEmpty(_) && a.compareObjectValues(T, _) && F.push(N); t.isFalseyButNotEmpty(T) && !t.isFalseyButNotEmpty(_) && b.push(N), !t.isFalseyButNotEmpty(T) && !t.isFalseyButNotEmpty(_) && t.compareObjectValues(T, _) && S.push(N);
}), Object.keys(o).forEach((N) => { }), Object.keys(o).forEach((N) => {
if (!Object.prototype.hasOwnProperty.call(m, N) || a.isFalseyButNotEmpty(m[N])) { if (!Object.prototype.hasOwnProperty.call(d, N) || t.isFalseyButNotEmpty(d[N])) {
const T = o[N]; const T = o[N];
a.isFalseyButNotEmpty(T) || O.push(N); t.isFalseyButNotEmpty(T) || x.push(N);
} }
}), { }), {
added: A, added: b,
modified: F, modified: S,
deleted: O deleted: x
}; };
}; };
return V(() => s.params, async () => { return V(() => s.params, async () => {
const o = await a.loadGridData(); const o = await t.loadGridData();
d.value = o.baseData, v.value = o.compareData; c.value = o.baseData, g.value = o.compareData;
const { const {
added: m, added: d,
modified: A, modified: b,
deleted: F deleted: S
} = x(v.value, d.value); } = O(g.value, c.value);
g.value = m, y.value = A, i.value = F; w.value = d, v.value = b, l.value = S;
}, { }, {
immediate: !0 immediate: !0
}), { }), {
ns: e, ns: a,
c: a, c: t,
switchValue: n, switchValue: n,
druipartNum: u, druipartNum: C,
renderEditor: E, renderEditor: y,
renderByDetailType: k renderByDetailType: k
}; };
}, },
...@@ -457,65 +457,65 @@ const Te = M({ ...@@ -457,65 +457,65 @@ const Te = M({
} }
}, },
setup(s, { setup(s, {
emit: e emit: a
}) { }) {
const t = B("data-import"), a = b(), c = b({ const e = B("data-import"), t = A(), i = A({
state: "ready", state: "ready",
message: "", message: "",
rowError: [] rowError: []
}), n = b(""), d = async (i) => { }), n = A(""), c = async (l) => {
const y = new FormData(), f = $(n.value).format("YYYY-MM"); const v = new FormData(), f = $(n.value).format("YYYY-MM");
y.append("file", i), y.append("ny", f); v.append("file", l), v.append("ny", f);
try { try {
const u = await ibiz.net.request(s.importUrl, { const C = await ibiz.net.request(s.importUrl, {
method: "post", method: "post",
data: y, data: v,
headers: { headers: {
"Content-Type": "multipart/form-data" "Content-Type": "multipart/form-data"
} }
}); });
c.value.state = "success", c.value.message = "导入成功"; i.value.state = "success", i.value.message = "导入成功";
const { const {
errorinfo: l, errorinfo: h,
success: w, success: p,
total: E total: y
} = u.data, I = E ? Number(E) : 0, D = w ? Number(w) : 0, P = E - w; } = C.data, F = y ? Number(y) : 0, I = p ? Number(p) : 0, D = y - p;
c.value.message = `共计导入数据 ${I} 条,错误[${P}],成功[${D}]`, l && Object.keys(l).length > 0 && (c.value.rowError = [], Object.keys(l).forEach((S) => { i.value.message = `共计导入数据 ${F} 条,错误[${D}],成功[${I}]`, h && Object.keys(h).length > 0 && (i.value.rowError = [], Object.keys(h).forEach((E) => {
c.value.rowError.push({ i.value.rowError.push({
index: Number(S) + 1, index: Number(E) + 1,
info: l[S].errorInfo info: h[E].errorInfo
}); });
})); }));
} catch (u) { } catch (C) {
c.value.state = "fail", c.value.message = `导入失败!${u.message}`; i.value.state = "fail", i.value.message = `导入失败!${C.message}`;
} }
}, v = (i) => { }, g = (l) => {
const y = i.target; const v = l.target;
if (!y.files) if (!v.files)
return; return;
const f = y.files[0]; const f = v.files[0];
y.value = null, d(f); v.value = null, c(f);
}, p = async () => { }, u = async () => {
var y; var v;
const i = await ibiz.net.request(s.templateUrl, { const l = await ibiz.net.request(s.templateUrl, {
responseType: "blob" responseType: "blob"
}); });
if (i.status === 200) { if (l.status === 200) {
let f = ((y = i.headers["content-disposition"].split(";").find((w) => w.indexOf("filename=") !== -1)) == null ? void 0 : y.slice(9)) || ""; let f = ((v = l.headers["content-disposition"].split(";").find((p) => p.indexOf("filename=") !== -1)) == null ? void 0 : v.slice(9)) || "";
f = decodeURIComponent(f); f = decodeURIComponent(f);
const u = new Blob([i.data], { const C = new Blob([l.data], {
type: "application/vnd.ms-excel" type: "application/vnd.ms-excel"
}), l = document.createElement("a"); }), h = document.createElement("a");
l.download = f, l.style.display = "none", l.href = URL.createObjectURL(u), document.body.appendChild(l), l.click(), URL.revokeObjectURL(l.href), document.body.removeChild(l); h.download = f, h.style.display = "none", h.href = URL.createObjectURL(C), document.body.appendChild(h), h.click(), URL.revokeObjectURL(h.href), document.body.removeChild(h);
} }
}, h = () => { }, m = () => {
a.value.click(); t.value.click();
}, g = () => { }, w = () => {
var i; var l;
e("close", { a("close", {
ok: !1, ok: !1,
data: {} data: {}
}), (i = s.dismiss) == null || i.call(s, { }), (l = s.dismiss) == null || l.call(s, {
ok: !1, ok: !1,
data: {} data: {}
}); });
...@@ -523,14 +523,14 @@ const Te = M({ ...@@ -523,14 +523,14 @@ const Te = M({
return De(() => { return De(() => {
n.value = $().format("YYYY年MM月"); n.value = $().format("YYYY年MM月");
}), { }), {
ns: t, ns: e,
curDate: n, curDate: n,
onLinkClick: p, onLinkClick: u,
selectFile: h, selectFile: m,
onCancelButtonClick: g, onCancelButtonClick: w,
onFileChange: v, onFileChange: g,
inputUpLoad: a, inputUpLoad: t,
message: c message: i
}; };
}, },
render() { render() {
...@@ -611,17 +611,17 @@ const Me = M({ ...@@ -611,17 +611,17 @@ const Me = M({
props: ye(), props: ye(),
emits: G(), emits: G(),
setup(s, { setup(s, {
emit: e emit: a
}) { }) {
const t = B("date-picker"), a = s.controller, c = a.model, n = b("date"), d = b("yyyy-MM-dd"), v = b(!1); const e = B("date-picker"), t = s.controller, i = t.model, n = A("date"), c = A("yyyy-MM-dd"), g = A(!1);
switch (c.editorType) { switch (i.editorType) {
case "DATEPICKEREX": case "DATEPICKEREX":
case "DATEPICKEREX_NOTIME": case "DATEPICKEREX_NOTIME":
n.value = "date"; n.value = "date";
break; break;
case "DATEPICKEREX_NODAY": case "DATEPICKEREX_NODAY":
case "DATEPICKEREX_NODAY_NOSECOND": case "DATEPICKEREX_NODAY_NOSECOND":
v.value = !0, n.value = "time"; g.value = !0, n.value = "time";
break; break;
case "DATEPICKEREX_HOUR": case "DATEPICKEREX_HOUR":
case "DATEPICKEREX_MINUTE": case "DATEPICKEREX_MINUTE":
...@@ -631,41 +631,41 @@ const Me = M({ ...@@ -631,41 +631,41 @@ const Me = M({
default: default:
n.value = "datetime"; n.value = "datetime";
} }
const p = a.valueFormat; const u = t.valueFormat;
if (p) { if (u) {
p === "YYYY-MM" ? n.value = "month" : p === "YYYY" && (n.value = "year"); u === "YYYY-MM" ? n.value = "month" : u === "YYYY" && (n.value = "year");
const f = p.replace("YYYY", "yyyy").replace("DD", "dd"); const f = u.replace("YYYY", "yyyy").replace("DD", "dd");
d.value = f; c.value = f;
} }
c.editorParams.formatText && (d.value = c.editorParams.formatText.replace("YYYY", "yyyy").replace("DD", "dd")); i.editorParams.formatText && (c.value = i.editorParams.formatText.replace("YYYY", "yyyy").replace("DD", "dd"));
const h = b(); const m = A();
V(() => s.value, (f, u) => { V(() => s.value, (f, C) => {
f && f !== u && (h.value = $(f).format(p)); f && f !== C && (m.value = $(f).format(u));
}, { }, {
immediate: !0 immediate: !0
}); });
const g = (f, u) => { const w = (f, C) => {
if (f) { if (f) {
const l = $(f.replace(/[年月]/g, "-")).format(p); const h = $(f.replace(/[年月]/g, "-")).format(u);
e("change", l); a("change", h);
} else } else
e("change", f); a("change", f);
}, i = (f) => { }, l = (f) => {
e("operate", f); a("operate", f);
}, y = b(); }, v = A();
return s.autoFocus && V(y, (f) => { return s.autoFocus && V(v, (f) => {
f && f.$el.getElementsByTagName("input")[0].click(); f && f.$el.getElementsByTagName("input")[0].click();
}), { }), {
ns: t, ns: e,
c: a, c: t,
editorModel: c, editorModel: i,
type: n, type: n,
format: d, format: c,
formatValue: h, formatValue: m,
handleChange: g, handleChange: w,
onOpenChange: i, onOpenChange: l,
inputRef: y, inputRef: v,
isTimePicker: v isTimePicker: g
}; };
}, },
render(s) { render(s) {
...@@ -704,14 +704,14 @@ const Me = M({ ...@@ -704,14 +704,14 @@ const Me = M({
})]]); })]]);
} }
}); });
const ie = new Ee(import.meta.url), Re = M({ const ie = new Ce(import.meta.url), Re = M({
name: "DownLoadSafeFile", name: "DownLoadSafeFile",
props: {}, props: {},
setup() { setup() {
const s = B("download-safe-file"), e = ie.dir("/assets/doc/safe-file.doc"); const s = B("download-safe-file"), a = ie.dir("/assets/doc/safe-file.doc");
return { return {
ns: s, ns: s,
url: e url: a
}; };
}, },
render() { render() {
...@@ -734,17 +734,49 @@ class le extends Pe { ...@@ -734,17 +734,49 @@ class le extends Pe {
* @type {number} * @type {number}
* @memberof FormMDCtrlFormStyle2Controller * @memberof FormMDCtrlFormStyle2Controller
*/ */
C(this, "active", 0); P(this, "active", 0);
}
/**
* 计算表单更新项信息
*
* @param {IPSDEFormItemUpdate} formItemUpdate
* @return {*}
* @memberof FormMDCtrlFormStyle2Controller
*/
calcFormUpdateItem(e) {
var t, i;
return {
methodName: ((t = e.getPSAppDEMethod()) == null ? void 0 : t.codeName) || "",
itemNames: (i = e.getPSDEFIUpdateDetails()) == null ? void 0 : i.map((n) => n.name),
model: {
customCode: e.customCode,
scriptCode: e.scriptCode
}
};
} }
connect(t, a) { connect(e, t) {
this.formNeurons.get(t) || (this.formNeurons.set(t, a), a.evt.on("mounted", () => { this.formNeurons.get(e) || (this.formNeurons.set(e, t), t.evt.on("mounted", () => {
a.call.load(); t.call.load();
}), a.evt.on("destroyed", () => { }), t.evt.on("destroyed", () => {
this.formNeurons.delete(t); this.formNeurons.delete(e);
}), a.evt.on("valueChange", (c) => { }), t.evt.on("valueChange", (i) => {
if (c) { if (i) {
const n = this.contentCtrlData.find((d) => d.srfkey === c.srfkey); const n = this.contentCtrlData.find((c) => c.srfkey === i.srfkey);
n && Object.assign(n, c), this.force(); n && Object.assign(n, i), this.force();
}
}), t.evt.on("afterSave", async () => {
const i = this.model.source.M.getPSAppDEField;
i && await this.form.setDataValue(i.codeName.toLowerCase(), [
...this.contentCtrlData
]);
const n = this.model.source.getPSDEFormItemUpdate();
if (n) {
const { methodName: c, itemNames: g, model: u } = this.calcFormUpdateItem(n);
await this.form.updateFormItem(
c,
g,
u
);
} }
})); }));
} }
...@@ -755,23 +787,23 @@ class le extends Pe { ...@@ -755,23 +787,23 @@ class le extends Pe {
* @memberof FormMDCtrlFormStyle2Controller * @memberof FormMDCtrlFormStyle2Controller
*/ */
async validate() { async validate() {
const t = []; const e = [];
this.formNeurons.forEach((n, d) => { this.formNeurons.forEach((n, c) => {
const v = n.call.getFormController(); const g = n.call.getFormController();
t.push({ key: d, controller: v }); e.push({ key: c, controller: g });
}); });
let a = ""; let t = "";
const c = await Promise.all( const i = await Promise.all(
t.map(async (n) => { e.map(async (n) => {
const d = await n.controller.validate(); const c = await n.controller.validate();
return !a && !d && (a = n.key), d; return !t && !c && (t = n.key), c;
}) })
); );
if (a) { if (t) {
const n = this.contentCtrlData.findIndex((d) => d.srfkey === a); const n = this.contentCtrlData.findIndex((c) => c.srfkey === t);
n > -1 && (this.active = n); n > -1 && (this.active = n);
} }
return c.findIndex((n) => !n) === -1; return i.findIndex((n) => !n) === -1;
} }
/** /**
* 静默校验 * 静默校验
...@@ -780,23 +812,23 @@ class le extends Pe { ...@@ -780,23 +812,23 @@ class le extends Pe {
* @memberof FormMDCtrlFormStyle2Controller * @memberof FormMDCtrlFormStyle2Controller
*/ */
async silentValidate() { async silentValidate() {
const t = []; const e = [];
this.formNeurons.forEach((n, d) => { this.formNeurons.forEach((n, c) => {
const v = n.call.getFormController(); const g = n.call.getFormController();
t.push({ key: d, controller: v }); e.push({ key: c, controller: g });
}); });
let a = ""; let t = "";
const c = await Promise.all( const i = await Promise.all(
t.map(async (n) => { e.map(async (n) => {
const d = await n.controller.silentValidate(); const c = await n.controller.silentValidate();
return !a && !d && (a = n.key), d; return !t && !c && (t = n.key), c;
}) })
); );
if (a) { if (t) {
const n = this.contentCtrlData.findIndex((d) => d.srfkey === a); const n = this.contentCtrlData.findIndex((c) => c.srfkey === t);
n > -1 && (this.active = n); n > -1 && (this.active = n);
} }
return c.findIndex((n) => !n) === -1; return i.findIndex((n) => !n) === -1;
} }
} }
const Ue = M({ const Ue = M({
...@@ -812,108 +844,108 @@ const Ue = M({ ...@@ -812,108 +844,108 @@ const Ue = M({
} }
}, },
setup(s) { setup(s) {
const e = B("form-mdctrl-form-style2"), t = s.controller, { const a = B("form-mdctrl-form-style2"), e = s.controller, {
proxy: a proxy: t
} = W(); } = W();
ge(a, s.controller); ge(t, s.controller);
const c = async (h, g, i) => { const i = async (m, w, l) => {
i.stopPropagation(), i.preventDefault(); l.stopPropagation(), l.preventDefault();
const y = t.contentCtrlData.length; const v = e.contentCtrlData.length;
await t.handleRemove(h, g), y !== t.contentCtrlData.length && g <= t.active && t.active !== 0 && (t.active -= 1); await e.handleRemove(m, w), v !== e.contentCtrlData.length && w <= e.active && e.active !== 0 && (e.active -= 1);
}, n = (h) => { }, n = (m) => {
t.active = h, t.force(); e.active = m, e.force();
}, d = async () => { }, c = async () => {
const h = JSON.parse(JSON.stringify(t.contentCtrlData)).length; const m = JSON.parse(JSON.stringify(e.contentCtrlData)).length;
await t.handleAdd(), h < t.contentCtrlData.length && (t.active = t.contentCtrlData.length - 1); await e.handleAdd(), m < e.contentCtrlData.length && (e.active = e.contentCtrlData.length - 1);
}, v = () => { }, g = () => {
const h = s.modelData.source.userTag; const m = s.modelData.source.userTag;
let g = {}; let w = {};
h && (g = JSON.parse(h)); m && (w = JSON.parse(m));
const { const {
tabtitle: i, tabtitle: l,
addtitle: y, addtitle: v,
usermode: f usermode: f
} = g; } = w;
return f === "user1" && t.contentCtrlData.some((l) => l.rcrylx === "system") ? r("div", { return f === "user1" && e.contentCtrlData.some((h) => h.rcrylx === "system") ? r("div", {
class: e.e("header") class: a.e("header")
}, [t.contentCtrlData.map((l, w) => { }, [e.contentCtrlData.map((h, p) => {
let E = ""; let y = "";
l.srfmajortext ? E = l.srfmajortext : i && l[i] && (E = l[i]); h.srfmajortext ? y = h.srfmajortext : l && h[l] && (y = h[l]);
let I = "待确认"; let F = "待确认";
return l.is_rc === 1 ? I = "确认入场" : l.is_rc === 0 && (I = "放弃入场"), r("div", { return h.is_rc === 1 ? F = "确认入场" : h.is_rc === 0 && (F = "放弃入场"), r("div", {
class: [e.e("header-item"), e.is("actived", w === t.active)], class: [a.e("header-item"), a.is("actived", p === e.active)],
on: { on: {
click: () => n(w) click: () => n(p)
} }
}, [r("div", { }, [r("div", {
class: e.em("header-item", "title") class: a.em("header-item", "title")
}, [E, "(", I, ")"])]); }, [y, "(", F, ")"])]);
})]) : r("div", { })]) : r("div", {
class: e.e("header") class: a.e("header")
}, [t.contentCtrlData.map((u, l) => { }, [e.contentCtrlData.map((C, h) => {
let w = `新建${l + 1}`; let p = `新建${h + 1}`;
return u.srfmajortext ? w = u.srfmajortext : i && u[i] ? w = u[i] : y && (w = `${y}${l + 1}`), r("div", { return C.srfmajortext ? p = C.srfmajortext : l && C[l] ? p = C[l] : v && (p = `${v}${h + 1}`), r("div", {
class: [e.e("header-item"), e.is("actived", l === t.active)], class: [a.e("header-item"), a.is("actived", h === e.active)],
on: { on: {
click: () => n(l) click: () => n(h)
} }
}, [r("div", { }, [r("div", {
class: e.em("header-item", "title") class: a.em("header-item", "title")
}, [w]), t.enableDelete && r("div", { }, [p]), e.enableDelete && r("div", {
class: e.em("header-item", "delete"), class: a.em("header-item", "delete"),
attrs: { attrs: {
title: "移除" title: "移除"
}, },
on: { on: {
click: (E) => c(u, l, E) click: (y) => i(C, h, y)
} }
}, [r("i", { }, [r("i", {
class: "fa fa-close" class: "fa fa-close"
})])]); })])]);
}), t.enableCreate && r("div", { }), e.enableCreate && r("div", {
class: [e.e("header-item"), e.e("add")], class: [a.e("header-item"), a.e("add")],
attrs: { attrs: {
title: "添加" title: "添加"
}, },
on: { on: {
click: () => d() click: () => c()
} }
}, [r("span", ["添加"]), r("i", { }, [r("span", ["添加"]), r("i", {
class: "fa fa-plus" class: "fa fa-plus"
})])]); })])]);
}; };
return V(() => t.form.isLoaded, (h, g) => { return V(() => e.form.isLoaded, (m, w) => {
h !== g && h === !0 && t.loadData(); m !== w && m === !0 && e.loadData();
}), { }), {
ns: e, ns: a,
rendertanHeader: v, rendertanHeader: g,
renderTabs: () => t.contentCtrlData.map((h, g) => { renderTabs: () => e.contentCtrlData.map((m, w) => {
var f; var f;
let i = null; let l = null;
const { const {
form: y form: v
} = t.model; } = e.model;
if (y && t.providers[y.name] && t.model.appEntity) { if (v && e.providers[v.name] && e.model.appEntity) {
const u = Object.assign(t.form.context.clone(), { const C = Object.assign(e.form.context.clone(), {
[(f = t.model.appEntity.codeName) == null ? void 0 : f.toLowerCase()]: h[t.model.appEntity.keyName] [(f = e.model.appEntity.codeName) == null ? void 0 : f.toLowerCase()]: m[e.model.appEntity.keyName]
}); });
i = r(t.providers[y.name].component, { l = r(e.providers[v.name].component, {
props: { props: {
modelData: y, modelData: v,
context: u, context: C,
params: t.form.params, params: e.form.params,
enableAutoSave: !0, enableAutoSave: !0,
silentVerify: !0 silentVerify: !0
}, },
on: { on: {
neuronInit: t.onNeuronInit(h.srfkey) neuronInit: e.onNeuronInit(m.srfkey)
} }
}); });
} }
return r("div", { return r("div", {
class: [e.e("content"), e.is("actived", g === t.active)], class: [a.e("content"), a.is("actived", w === e.active)],
key: h.srfkey key: m.srfkey
}, [i]); }, [l]);
}) })
}; };
}, },
...@@ -927,92 +959,94 @@ const Ue = M({ ...@@ -927,92 +959,94 @@ const Ue = M({
props: se(), props: se(),
emits: G(), emits: G(),
setup(s, { setup(s, {
emit: e emit: a
}) { }) {
const t = B("mpicker"), a = s.controller, c = b([]), n = b([]), d = b([]), v = b(!1), p = b(!1), h = b(null), g = b([]), i = j(() => { const e = B("mpicker"), t = s.controller, i = A([]), n = A([]), c = A([]), g = A(!1), u = A(!1), m = A(null), w = A([]), l = A(!0), v = j(() => {
const D = a.editorParams.followitem; const D = t.editorParams.followitem;
return D ? s.data[D] : ""; return D ? s.data[D] : "";
}); });
V(() => s.value, (D) => { V(() => s.value, (D) => {
c.value = [], d.value = [], D && (d.value = JSON.parse(D), d.value.length > 0 && d.value.forEach((P) => { i.value = [], c.value = [], D && (c.value = JSON.parse(D), c.value.length > 0 && c.value.forEach((E) => {
n.value.findIndex((k) => Object.is(k.srfkey, P.srfkey)) < 0 && (n.value.push(P), g.value.push(P.srfmajortext)), c.value.push(P.srfkey); n.value.findIndex((O) => Object.is(O.srfkey, E.srfkey)) < 0 && (n.value.push(E), w.value.push(E.srfmajortext)), i.value.push(E.srfkey);
})); }));
}, { }, {
immediate: !0, immediate: !0,
deep: !0 deep: !0
}); });
const y = async (D) => { const f = async (D) => {
const P = []; const E = [];
if (D && Array.isArray(D)) if (D && Array.isArray(D))
for (let k = 0; k < D.length; k++) { for (let O = 0; O < D.length; O++) {
const x = D[k], o = { const o = D[O], d = {
srfkey: x[a.keyName] || x.srfkey, srfkey: o[t.keyName] || o.srfkey,
srfmajortext: x[a.textName] || x.srfmajortext srfmajortext: o[t.textName] || o.srfmajortext
}, m = await a.calcFillDataItems(x); }, b = await t.calcFillDataItems(o);
m.length > 0 && m.forEach((F) => { b.length > 0 && b.forEach((x) => {
Object.assign(o, { Object.assign(d, {
[F.name]: F.value [x.name]: x.value
}); });
}), P.push(o), n.value.findIndex((F) => Object.is(F[a.keyName], x[a.keyName])) < 0 && n.value.push(o); }), E.push(d), n.value.findIndex((x) => Object.is(x[t.keyName], o[t.keyName])) < 0 && n.value.push(d);
} }
const S = P.length > 0 ? JSON.stringify(P) : ""; const k = E.length > 0 ? JSON.stringify(E) : "";
e("change", S); a("change", k);
}, f = async () => { }, C = async () => {
let D; let D;
d.value.length && (D = JSON.stringify(d.value)); c.value.length && (D = JSON.stringify(c.value));
const P = await a.openPickUpView(s.data, D); const E = await t.openPickUpView(s.data, D);
P && y(P); E && f(E);
}, u = (D) => { }, h = (D) => {
const P = []; const E = [];
if (D.length > 0) { if (D.length > 0) {
D.forEach((k) => { D.forEach((O) => {
let x = n.value.findIndex((m) => Object.is(m.srfkey, k)), o = null; let o = n.value.findIndex((b) => Object.is(b.srfkey, O)), d = null;
x >= 0 ? o = n.value[x] : (x = d.value.findIndex((m) => Object.is(m.srfkey, k)), x >= 0 && (o = d.value[x])), o && P.push(o); o >= 0 ? d = n.value[o] : (o = c.value.findIndex((b) => Object.is(b.srfkey, O)), o >= 0 && (d = c.value[o])), d && E.push(d);
}); });
const S = P.length > 0 ? JSON.stringify(P) : ""; const k = E.length > 0 ? JSON.stringify(E) : "";
e("change", S); a("change", k);
} else } else
e("change", ""); a("change", "");
}, l = async (D) => { }, p = async (D) => {
if (a.model.appDataEntity) { if (t.model.appDataEntity) {
p.value = !0; u.value = !0;
try { try {
const P = await a.getServiceData(D, s.data); const E = await t.getServiceData(D, s.data);
p.value = !1, n.value = [], P.data.length > 0 && (n.value = P.data.map((S) => ({ u.value = !1, n.value = [], E.data.length > 0 && (n.value = E.data.map((k) => ({
srfkey: S[a.keyName], srfkey: k[t.keyName],
srfmajortext: S[a.textName] srfmajortext: k[t.textName]
}))); })));
} catch (P) { } catch (E) {
p.value = !1; u.value = !1;
} }
} }
}, w = (D) => { }, y = (D) => {
v.value = D, e("operate", D), v.value && l(""); g.value = D, a("operate", D), g.value && p("");
}, E = j(() => d.value.map((D) => D.srfmajortext).join("、")), I = (D) => { }, F = j(() => c.value.map((D) => D.srfmajortext).join("、")), I = (D) => {
n.value = D; n.value = D;
}; };
return V(() => i.value, async (D) => { return V(() => v.value, async (D) => {
if (D) { if (D) {
await l(""); await p("");
const P = n.value.map((S) => S.srfkey); const E = n.value.map((k) => k.srfkey);
u(P); if (l.value && (l.value = !1, s.value))
return;
h(E);
} else } else
n.value = [], e("change", ""); n.value = [], a("change", "");
}, { }, {
immediate: !0 immediate: !0
}), { }), {
ns: t, ns: e,
c: a, c: t,
selectRef: h, selectRef: m,
curValue: c, curValue: i,
loading: p, loading: u,
items: n, items: n,
defaultLabel: g, defaultLabel: w,
valueText: E, valueText: F,
onSearch: l, onSearch: p,
onOpenChange: w, onOpenChange: y,
onSelect: u, onSelect: h,
openPickUpView: f, openPickUpView: C,
setDefaultOptions: I setDefaultOptions: I
}; };
}, },
...@@ -1037,13 +1071,13 @@ const Ue = M({ ...@@ -1037,13 +1071,13 @@ const Ue = M({
"on-change": this.onSelect, "on-change": this.onSelect,
"on-open-change": this.onOpenChange "on-open-change": this.onOpenChange
} }
}, [this.items.map((e) => s("i-option", { }, [this.items.map((a) => s("i-option", {
key: e.srfkey, key: a.srfkey,
attrs: { attrs: {
value: e.srfkey, value: a.srfkey,
label: e.srfmajortext label: a.srfmajortext
} }
}, [e.srfmajortext]))]), !this.readonly && s("div", { }, [a.srfmajortext]))]), !this.readonly && s("div", {
class: this.ns.e("buns-position") class: this.ns.e("buns-position")
}, [s("div", { }, [s("div", {
class: this.ns.e("btns") class: this.ns.e("btns")
...@@ -1063,71 +1097,75 @@ const Ve = M({ ...@@ -1063,71 +1097,75 @@ const Ve = M({
props: se(), props: se(),
emits: G(), emits: G(),
setup(s, { setup(s, {
emit: e emit: a
}) { }) {
const t = B("checkbox"), a = s.controller, c = b([]), n = b([]), d = ",", v = j({ const e = B("checkbox"), t = s.controller, i = A([]), n = A([]), c = A(!0), g = ",", u = t.editorParams.emptyClearItems, m = j({
get() { get() {
var u; var p;
return ((u = s.value) == null ? void 0 : u.split(",")) || []; return ((p = s.value) == null ? void 0 : p.split(",")) || [];
}, },
set(u) { set(p) {
let l = null; let y = null;
const w = []; const F = [];
c.value.length > 0 && (c.value.forEach((E) => { if (i.value.length > 0 && (i.value.forEach((I) => {
u.findIndex((D) => Object.is(E.value, D)) !== -1 && w.push(E.value); p.findIndex((E) => Object.is(I.value, E)) !== -1 && F.push(I.value);
}), l = w.join(d)), e("change", l); }), y = F.join(g)), a("change", y), !y && u) {
const I = JSON.parse(u);
for (let D = 0; D < I.length; D++)
a("change", I[D].value, I[D].key);
}
} }
}), p = async (u) => { }), w = async (p) => {
const { const {
context: l, context: y,
params: w params: F
} = a.handlePublicParams(u, a.context, a.params); } = t.handlePublicParams(p, t.context, t.params);
if (a.editorParams.codeTag) { if (t.editorParams.codeTag) {
let E = []; let I = [];
const I = a.editorParams.codeTag; const D = t.editorParams.codeTag;
return E = await ibiz.codeListService.get(I, l, w), E; return I = await ibiz.codeListService.get(D, y, F), I;
} }
throw new he(a.model.source, "请配置代码表"); throw new he(t.model.source, "请配置代码表");
}, h = (u) => { }, l = (p) => {
v.value = u; m.value = p;
}, g = j(() => { }, v = j(() => {
const u = Array.isArray(v.value) ? v.value : [v.value]; const p = Array.isArray(m.value) ? m.value : [m.value];
return c.value.filter((l) => u.includes(l.srfkey)).map((l) => l.srfmajortext).join("、"); return i.value.filter((y) => p.includes(y.srfkey)).map((y) => y.srfmajortext).join("、");
}), i = async (u) => { }), f = async (p) => {
if (a.model.appDataEntity) if (t.model.appDataEntity)
try { try {
const l = await a.getServiceData(u, s.data); const y = await t.getServiceData(p, s.data);
n.value = [], l.data.length > 0 && (n.value = l.data.map((w) => ({ n.value = [], y.data.length > 0 && (n.value = y.data.map((F) => ({
srfkey: w[a.keyName], srfkey: F[t.keyName],
srfmajortext: w[a.textName] srfmajortext: F[t.textName]
}))); })));
} catch (l) { } catch (y) {
console.error(l); console.error(y);
} }
}, y = j(() => { }, C = j(() => {
const u = a.editorParams.followitem; const p = t.editorParams.followitem;
return u ? s.data[u] : ""; return p ? s.data[p] : "";
}), f = () => { }), h = () => {
const u = []; const p = [];
c.value.forEach((l) => { i.value.forEach((y) => {
n.value.findIndex((E) => E.srfkey === l.value) > -1 && u.push(l.value); n.value.findIndex((I) => I.srfkey === y.value) > -1 && p.push(y.value);
}), h(u); }), l(p);
}; };
return V(() => y, async (u) => { return V(() => C, async (p) => {
await p(u).then((l) => { await w(p).then((y) => {
c.value = l; i.value = y;
}), await i(""), f(); }), await f(""), !(c.value && (c.value = !1, s.value)) && h();
}, { }, {
immediate: !0, immediate: !0,
deep: !0 deep: !0
}), { }), {
ns: t, ns: e,
c: a, c: t,
valueText: g, valueText: v,
selectArray: v, selectArray: m,
items: c, items: i,
onSearch: i, onSearch: f,
onSelectArrayChange: h onSelectArrayChange: l
}; };
}, },
render(s) { render(s) {
...@@ -1141,15 +1179,15 @@ const Ve = M({ ...@@ -1141,15 +1179,15 @@ const Ve = M({
on: { on: {
"on-change": this.onSelectArrayChange "on-change": this.onSelectArrayChange
} }
}, [this.items.map((e, t) => s("i-checkbox", { }, [this.items.map((a, e) => s("i-checkbox", {
key: t, key: e,
attrs: { attrs: {
label: e.value, label: a.value,
disabled: this.disabled disabled: this.disabled
} }
}, [s("span", { }, [s("span", {
class: this.ns.e("text") class: this.ns.e("text")
}, [e.text])]))])]); }, [a.text])]))])]);
} }
}); });
class Be extends Ae { class Be extends Ae {
...@@ -1160,25 +1198,25 @@ class Be extends Ae { ...@@ -1160,25 +1198,25 @@ class Be extends Ae {
* @date 2022-09-15 10:09:22 * @date 2022-09-15 10:09:22
* @param {ViewNeuron} neuron * @param {ViewNeuron} neuron
*/ */
setViewNeuron(e) { setViewNeuron(a) {
this.neuron = e, this.neuron.evt.on("refreshed", (t) => { this.neuron = a, this.neuron.evt.on("refreshed", (e) => {
if (ibiz.log.debug("接收到关系界面的刷新变更事件", t), this.model.formItemUpdate) { if (ibiz.log.debug("接收到关系界面的刷新变更事件", e), this.model.formItemUpdate) {
const { methodName: a, itemNames: c, model: n } = this.model.formItemUpdate; const { methodName: t, itemNames: i, model: n } = this.model.formItemUpdate;
this.form.updateFormItem( this.form.updateFormItem(
a, t,
c, i,
n n
); );
} }
}), this.neuron.evt.on("mounted", () => { }), this.neuron.evt.on("mounted", () => {
this.neuron.call.refresh(); this.neuron.call.refresh();
}), this.neuron.evt.on("viewDataChange", async (t) => { }), this.neuron.evt.on("viewDataChange", async (e) => {
if (!["LOAD", "LOADDRAFT"].includes(t.type) && (ibiz.log.debug("接收到关系界面的数据变更事件", t.data), this.model.formItemUpdate)) { if (!["LOAD", "LOADDRAFT"].includes(e.type) && (ibiz.log.debug("接收到关系界面的数据变更事件", e.data), this.model.formItemUpdate)) {
const { methodName: a, itemNames: c, model: n } = this.model.formItemUpdate; const { methodName: t, itemNames: i, model: n } = this.model.formItemUpdate;
try { try {
this.processState.formItemUpdate = !0, await this.form.updateFormItem( this.processState.formItemUpdate = !0, await this.form.updateFormItem(
a, t,
c, i,
n n
); );
} finally { } finally {
...@@ -1186,8 +1224,8 @@ class Be extends Ae { ...@@ -1186,8 +1224,8 @@ class Be extends Ae {
} }
} }
}), this.neuron.evt.on("destroyed", () => { }), this.neuron.evt.on("destroyed", () => {
Object.keys(this.processState).forEach((t) => { Object.keys(this.processState).forEach((e) => {
this.processState[t] = !1; this.processState[e] = !1;
}); });
}), this.neuron.evt.on("viewSaveStart", () => { }), this.neuron.evt.on("viewSaveStart", () => {
this.processState.viewSave = !0; this.processState.viewSave = !0;
...@@ -1205,7 +1243,7 @@ class _e extends Fe { ...@@ -1205,7 +1243,7 @@ class _e extends Fe {
* @type {string} * @type {string}
* @memberof WfEditViewController * @memberof WfEditViewController
*/ */
C(this, "userAction"); P(this, "userAction");
} }
async onInit() { async onInit() {
await super.onInit(), this.getUserAction(); await super.onInit(), this.getUserAction();
...@@ -1218,25 +1256,25 @@ class _e extends Fe { ...@@ -1218,25 +1256,25 @@ class _e extends Fe {
* @returns {*} {Promise<void>} * @returns {*} {Promise<void>}
*/ */
async wfStart() { async wfStart() {
var h; var m;
await this.save(), await this.execUserAction(); await this.save(), await this.execUserAction();
const t = await this.entityService.wf.getWFVersion(); const e = await this.entityService.wf.getWFVersion();
if (t.data.length === 0) if (e.data.length === 0)
throw new ke("当前工作流版本不存在"); throw new xe("当前工作流版本不存在");
const a = t.data[0], c = `WFSTART@${a.wfversion}`, n = Object.assign(this.context.clone(), { const t = e.data[0], i = `WFSTART@${t.wfversion}`, n = Object.assign(this.context.clone(), {
activeForm: a["process-form"] activeForm: t["process-form"]
}), d = { }), c = {
processDefinitionKey: a.definitionkey processDefinitionKey: t.definitionkey
}, v = (h = this.model.source.findPSAppViewRef(c)) == null ? void 0 : h.getRefPSAppView(); }, g = (m = this.model.source.findPSAppViewRef(i)) == null ? void 0 : m.getRefPSAppView();
if (!v) { if (!g) {
await this.nerve.form.call.wfStart(d), await this.closeView(); await this.nerve.form.call.wfStart(c), await this.closeView();
return; return;
} }
(await ibiz.commands.execute( (await ibiz.commands.execute(
q.TAG, q.TAG,
v, g,
n, n,
d c
)).ok && await this.closeView(); )).ok && await this.closeView();
} }
/** /**
...@@ -1245,10 +1283,10 @@ class _e extends Fe { ...@@ -1245,10 +1283,10 @@ class _e extends Fe {
* @memberof EditViewController * @memberof EditViewController
*/ */
getUserAction() { getUserAction() {
const { form: t } = this.model, a = t.source.getPSControlHandler(); const { form: e } = this.model, t = e.source.getPSControlHandler();
if (a) { if (t) {
const c = a.findPSControlHandlerAction("user"); const i = t.findPSControlHandlerAction("user");
c && c.getPSAppDEMethod() && (this.userAction = c.getPSAppDEMethod().codeName); i && i.getPSAppDEMethod() && (this.userAction = i.getPSAppDEMethod().codeName);
} }
} }
/** /**
...@@ -1258,15 +1296,15 @@ class _e extends Fe { ...@@ -1258,15 +1296,15 @@ class _e extends Fe {
*/ */
async execUserAction() { async execUserAction() {
if (this.userAction) { if (this.userAction) {
const t = this.getData(); const e = this.getData();
await this.entityService.exec(this.userAction, this.context, t[0]); await this.entityService.exec(this.userAction, this.context, e[0]);
} }
} }
} }
function je(s, e) { function je(s, a) {
return we( return we(
s, s,
(t, a) => new _e(e, t, a) (e, t) => new _e(a, e, t)
); );
} }
const ze = M({ const ze = M({
...@@ -1289,26 +1327,26 @@ const ze = M({ ...@@ -1289,26 +1327,26 @@ const ze = M({
}, },
setup(s) { setup(s) {
const { const {
proxy: e proxy: a
} = W(); } = W();
return { return {
c: je(e, s.modelPath) c: je(a, s.modelPath)
}; };
}, },
render(s) { render(s) {
let e = null; let a = null;
if (this.c.complete) { if (this.c.complete) {
const { const {
form: t form: e
} = this.c.model; } = this.c.model;
this.c.providers[t.name] && (e = s(this.c.providers[t.name].component, { this.c.providers[e.name] && (a = s(this.c.providers[e.name].component, {
props: { props: {
modelData: t, modelData: e,
context: this.c.context, context: this.c.context,
params: this.c.params params: this.c.params
}, },
on: { on: {
neuronInit: this.c.nerve.onNeuronInit(t.name) neuronInit: this.c.nerve.onNeuronInit(e.name)
} }
})); }));
} }
...@@ -1316,40 +1354,40 @@ const ze = M({ ...@@ -1316,40 +1354,40 @@ const ze = M({
attrs: { attrs: {
controller: this.c controller: this.c
} }
}, [e]); }, [a]);
} }
}); });
class Ye { class Ye {
constructor() { constructor() {
C(this, "component", "IBizFormDataComparison"); P(this, "component", "IBizFormDataComparison");
} }
} }
class $e extends Ce { class $e extends Ee {
async execAction(e, t, a, c) { async execAction(a, e, t, i) {
const n = {}, d = e.getPSAppDataEntity(); const n = {}, c = a.getPSAppDataEntity();
if (d) { if (c) {
d.isFill === !1 && await d.fill(!0); c.isFill === !1 && await c.fill(!0);
const v = new H(d); const g = new H(c);
await v.init(); await g.init();
const { resultContext: p } = await this.handleParams( const { resultContext: u } = await this.handleParams(
a,
e, e,
t, t,
a, i
c ), m = ibiz.resourcePathUtil.calcPaths(
), h = ibiz.resourcePathUtil.calcPaths( u,
p, g.codeName
v.codeName ), w = K(u, m);
), g = K(p, h); let l = `${w}/${g.deNamePlural}/importtemplate`, v = `${w}/${g.deNamePlural}/importdata2`;
let i = `${g}/${v.deNamePlural}/importtemplate`, y = `${g}/${v.deNamePlural}/importdata2`; const f = a.getPSAppDEDataImport();
const f = e.getPSAppDEDataImport(); f && (l += `?srfimporttag=${f.codeName}`, v += `?srfimporttag=${f.codeName}`);
f && (i += `?srfimporttag=${f.codeName}`, y += `?srfimporttag=${f.codeName}`); const C = ibiz.overlay.createModal(
const u = ibiz.overlay.createModal(
"CustomDataImport", "CustomDataImport",
{ {
templateUrl: i, templateUrl: l,
importUrl: y, importUrl: v,
dismiss: (l) => { dismiss: (h) => {
u.dismiss(l); C.dismiss(h);
} }
}, },
{ {
...@@ -1357,7 +1395,7 @@ class $e extends Ce { ...@@ -1357,7 +1395,7 @@ class $e extends Ce {
placement: "center" placement: "center"
} }
); );
return u.present(), await u.onWillDismiss(), { return C.present(), await C.onWillDismiss(), {
refresh: !0 refresh: !0
}; };
} }
...@@ -1366,7 +1404,7 @@ class $e extends Ce { ...@@ -1366,7 +1404,7 @@ class $e extends Ce {
} }
class He { class He {
constructor() { constructor() {
C(this, "handler"); P(this, "handler");
} }
async getHandler() { async getHandler() {
return this.handler || (this.handler = new $e()), this.handler; return this.handler || (this.handler = new $e()), this.handler;
...@@ -1374,56 +1412,56 @@ class He { ...@@ -1374,56 +1412,56 @@ class He {
} }
class Ge { class Ge {
constructor() { constructor() {
C(this, "gridEditor", "YearMonthPicker"); P(this, "gridEditor", "YearMonthPicker");
C(this, "formEditor", "YearMonthPicker"); P(this, "formEditor", "YearMonthPicker");
} }
async createController(e, t) { async createController(a, e) {
const a = new Ie(e, t); const t = new Ie(a, e);
return await a.init(), a; return await t.init(), t;
} }
} }
class We { class We {
constructor() { constructor() {
C(this, "formEditor", "DownLoadSafeFile"); P(this, "formEditor", "DownLoadSafeFile");
C(this, "gridEditor", "DownLoadSafeFile"); P(this, "gridEditor", "DownLoadSafeFile");
} }
async createController(e, t) { async createController(a, e) {
const a = new Se(e, t); const t = new Se(a, e);
return await a.init(), a; return await t.init(), t;
} }
} }
class qe extends re { class qe extends re {
async execAction(e, t, a, c, n) { async execAction(a, e, t, i, n) {
const d = {}, { frontProcessType: v } = e; const c = {}, { frontProcessType: g } = a;
if (v === "OPENHTMLPAGE") { if (g === "OPENHTMLPAGE") {
const p = ne.fill(e.htmlPageUrl, t, a == null ? void 0 : a[0]); const u = ne.fill(a.htmlPageUrl, e, t == null ? void 0 : t[0]);
window.open(p, "_blank"); window.open(u, "_blank");
} }
if (v === "DATAIMP") { if (g === "DATAIMP") {
const p = e.getPSAppDataEntity(); const u = a.getPSAppDataEntity();
if (p) { if (u) {
p.isFill === !1 && await p.fill(!0); u.isFill === !1 && await u.fill(!0);
const h = new H(p); const m = new H(u);
await h.init(); await m.init();
const { resultContext: g } = await this.handleParams( const { resultContext: w } = await this.handleParams(
a,
e, e,
t, t,
a, i
c ), l = ibiz.resourcePathUtil.calcPaths(
), i = ibiz.resourcePathUtil.calcPaths( w,
g, m.codeName
h.codeName ), v = K(w, l);
), y = K(g, i); let f = `${v}/${m.deNamePlural}/importtemplate`, C = `${v}/${m.deNamePlural}/importdata2`;
let f = `${y}/${h.deNamePlural}/importtemplate`, u = `${y}/${h.deNamePlural}/importdata2`; const h = a.getPSAppDEDataImport();
const l = e.getPSAppDEDataImport(); h && (f += `?srfimporttag=${h.codeName}`, C += `?srfimporttag=${h.codeName}`);
l && (f += `?srfimporttag=${l.codeName}`, u += `?srfimporttag=${l.codeName}`); const p = ibiz.overlay.createModal(
const w = ibiz.overlay.createModal(
"DataImport", "DataImport",
{ {
templateUrl: f, templateUrl: f,
importUrl: u, importUrl: C,
dismiss: (E) => { dismiss: (y) => {
w.dismiss(E); p.dismiss(y);
} }
}, },
{ {
...@@ -1431,60 +1469,60 @@ class qe extends re { ...@@ -1431,60 +1469,60 @@ class qe extends re {
placement: "center" placement: "center"
} }
); );
return w.present(), await w.onWillDismiss(), { return p.present(), await p.onWillDismiss(), {
refresh: !0 refresh: !0
}; };
} }
} }
if (["TOP", "WIZARD"].includes(v)) { if (["TOP", "WIZARD"].includes(g)) {
const p = e.getFrontPSAppView(); const u = a.getFrontPSAppView();
if (!p) if (!u)
throw new Error("未配置打开视图"); throw new Error("未配置打开视图");
await p.fill(!0); await u.fill(!0);
const { resultContext: h, resultParams: g } = await this.handleParams( const { resultContext: m, resultParams: w } = await this.handleParams(
a,
e, e,
t, t,
a, i
c ), l = await ibiz.commands.execute(
), i = await ibiz.commands.execute(
q.TAG, q.TAG,
p, u,
h, m,
g, w,
n n
); );
(i == null ? void 0 : i.ok) === !1 && (d.closeView = !1, d.refresh = !1, d.cancel = !0), i != null && i.ok && i.data && (d.data = i.data); (l == null ? void 0 : l.ok) === !1 && (c.closeView = !1, c.refresh = !1, c.cancel = !0), l != null && l.ok && l.data && (c.data = l.data);
} else if (n) { } else if (n) {
const { neuron: p } = n, g = p.call.getFormController().call.getFormController(), { druipart1: i, druipart2: y, druipart3: f } = g.details; const { neuron: u } = n, w = u.call.getFormController().call.getFormController(), { druipart1: l, druipart2: v, druipart3: f } = w.details;
[ [
{ {
message: "服务履历为空", message: "服务履历为空",
neuron: i neuron: l
}, },
{ {
message: "教育经验为空", message: "教育经验为空",
neuron: y neuron: v
}, },
{ {
message: "项目经验为空", message: "项目经验为空",
neuron: f neuron: f
} }
].some((w) => { ].some((p) => {
const E = w.neuron.neuron.call.getGridController(); const y = p.neuron.neuron.call.getGridController();
if (E) { if (y) {
const I = E.call.getGridController(); const F = y.call.getGridController();
if (I && I.items && I.items.length > 0) if (F && F.items && F.items.length > 0)
return !1; return !1;
} }
return ibiz.message.error(`${w.message}`, 1.5, !0), !0; return ibiz.message.error(`${p.message}`, 1.5, !0), !0;
}) || await p.call.wfStart(); }) || await u.call.wfStart();
} }
return d; return c;
} }
} }
class Ke { class Ke {
constructor() { constructor() {
C(this, "handler"); P(this, "handler");
} }
async getHandler() { async getHandler() {
return this.handler || (this.handler = new qe()), this.handler; return this.handler || (this.handler = new qe()), this.handler;
...@@ -1492,65 +1530,65 @@ class Ke { ...@@ -1492,65 +1530,65 @@ class Ke {
} }
class Je { class Je {
constructor() { constructor() {
C(this, "component", "FormMDCtrlFormStyle2"); P(this, "component", "FormMDCtrlFormStyle2");
} }
async createController(e, t, a) { async createController(a, e, t) {
const c = new le(e, t, a); const i = new le(a, e, t);
return await c.init(), c; return await i.init(), i;
} }
} }
class Xe { class Xe {
constructor() { constructor() {
C(this, "formEditor", "AutoSelectAll"); P(this, "formEditor", "AutoSelectAll");
C(this, "gridEditor", "AutoSelectAll"); P(this, "gridEditor", "AutoSelectAll");
} }
async createController(e, t) { async createController(a, e) {
const a = new oe(e, t); const t = new oe(a, e);
return await a.init(), a; return await t.init(), t;
} }
} }
class Ze { class Ze {
constructor() { constructor() {
C(this, "formEditor", "MPickerCheckbox"); P(this, "formEditor", "MPickerCheckbox");
C(this, "gridEditor", "IBizGridPicker"); P(this, "gridEditor", "IBizGridPicker");
} }
async createController(e, t) { async createController(a, e) {
const a = new oe(e, t); const t = new oe(a, e);
return await a.init(), a; return await t.init(), t;
} }
} }
class Qe extends re { class Qe extends re {
async execAction(e, t, a, c, n) { async execAction(a, e, t, i, n) {
const d = {}, { frontProcessType: v } = e; const c = {}, { frontProcessType: g } = a;
if (v === "OPENHTMLPAGE") { if (g === "OPENHTMLPAGE") {
const p = ne.fill(e.htmlPageUrl, t, a == null ? void 0 : a[0]); const u = ne.fill(a.htmlPageUrl, e, t == null ? void 0 : t[0]);
window.open(p, "_blank"); window.open(u, "_blank");
} }
if (v === "DATAIMP") { if (g === "DATAIMP") {
const p = e.getPSAppDataEntity(); const u = a.getPSAppDataEntity();
if (p) { if (u) {
p.isFill === !1 && await p.fill(!0); u.isFill === !1 && await u.fill(!0);
const h = new H(p); const m = new H(u);
await h.init(); await m.init();
const { resultContext: g } = await this.handleParams( const { resultContext: w } = await this.handleParams(
a,
e, e,
t, t,
a, i
c ), l = ibiz.resourcePathUtil.calcPaths(
), i = ibiz.resourcePathUtil.calcPaths( w,
g, m.codeName
h.codeName ), v = K(w, l);
), y = K(g, i); let f = `${v}/${m.deNamePlural}/importtemplate`, C = `${v}/${m.deNamePlural}/importdata2`;
let f = `${y}/${h.deNamePlural}/importtemplate`, u = `${y}/${h.deNamePlural}/importdata2`; const h = a.getPSAppDEDataImport();
const l = e.getPSAppDEDataImport(); h && (f += `?srfimporttag=${h.codeName}`, C += `?srfimporttag=${h.codeName}`);
l && (f += `?srfimporttag=${l.codeName}`, u += `?srfimporttag=${l.codeName}`); const p = ibiz.overlay.createModal(
const w = ibiz.overlay.createModal(
"DataImport", "DataImport",
{ {
templateUrl: f, templateUrl: f,
importUrl: u, importUrl: C,
dismiss: (E) => { dismiss: (y) => {
w.dismiss(E); p.dismiss(y);
} }
}, },
{ {
...@@ -1558,39 +1596,39 @@ class Qe extends re { ...@@ -1558,39 +1596,39 @@ class Qe extends re {
placement: "center" placement: "center"
} }
); );
return w.present(), await w.onWillDismiss(), { return p.present(), await p.onWillDismiss(), {
refresh: !0 refresh: !0
}; };
} }
} }
if (["TOP", "WIZARD"].includes(v)) { if (["TOP", "WIZARD"].includes(g)) {
const p = e.getFrontPSAppView(); const u = a.getFrontPSAppView();
if (!p) if (!u)
throw new Error("未配置打开视图"); throw new Error("未配置打开视图");
await p.fill(!0); await u.fill(!0);
const { resultContext: h, resultParams: g } = await this.handleParams( const { resultContext: m, resultParams: w } = await this.handleParams(
a,
e, e,
t, t,
a, i
c ), l = await ibiz.commands.execute(
), i = await ibiz.commands.execute(
q.TAG, q.TAG,
p, u,
h, m,
g, w,
n n
); );
(i == null ? void 0 : i.ok) === !1 && (d.closeView = !1, d.refresh = !1, d.cancel = !0), i != null && i.ok && i.data && (d.data = i.data); (l == null ? void 0 : l.ok) === !1 && (c.closeView = !1, c.refresh = !1, c.cancel = !0), l != null && l.ok && l.data && (c.data = l.data);
} else if (a && a.length > 0 && n) { } else if (t && t.length > 0 && n) {
const { neuron: p } = n, i = await p.call.getFormController().call.getFormController().autoSave(); const { neuron: u } = n, l = await u.call.getFormController().call.getFormController().autoSave();
i && i.rcryqd && Array.isArray(i.rcryqd) && i.rcryqd.length > 0 ? await p.call.wfStart() : ibiz.message.error("入场信息为空"); l && l.rcryqd && Array.isArray(l.rcryqd) && l.rcryqd.length > 0 ? await u.call.wfStart() : ibiz.message.error("入场信息为空");
} }
return d; return c;
} }
} }
class et { class et {
constructor() { constructor() {
C(this, "handler"); P(this, "handler");
} }
async getHandler() { async getHandler() {
return this.handler || (this.handler = new Qe()), this.handler; return this.handler || (this.handler = new Qe()), this.handler;
...@@ -1598,16 +1636,16 @@ class et { ...@@ -1598,16 +1636,16 @@ class et {
} }
class tt { class tt {
constructor() { constructor() {
C(this, "component", "FormDruipart"); P(this, "component", "FormDruipart");
} }
async createController(e, t, a) { async createController(a, e, t) {
const c = new Be(e, t, a); const i = new Be(a, e, t);
return await c.init(), c; return await i.init(), i;
} }
} }
class at { class at {
constructor() { constructor() {
C(this, "component", "WfEditView"); P(this, "component", "WfEditView");
} }
} }
const pt = { const pt = {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册