slw 0.9.39 → 0.9.40
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,5 @@
|
|
|
1
1
|
import { pushScopeId as P, popScopeId as V, createElementVNode as h, resolveComponent as g, openBlock as o, createElementBlock as p, createBlock as f, normalizeClass as T, normalizeStyle as A, withModifiers as R, withCtx as r, renderSlot as q, createCommentVNode as _, Fragment as B, createVNode as s, mergeProps as k, renderList as j, toDisplayString as E, normalizeProps as K, guardReactiveProps as Q, resolveDynamicComponent as Z, defineAsyncComponent as $, computed as F, unref as D, withDirectives as ee, vShow as te } from "vue";
|
|
2
|
-
import { _ as x, d as S, a as L, u as N } from "./index-
|
|
2
|
+
import { _ as x, d as S, a as L, u as N } from "./index-ca785816.js";
|
|
3
3
|
const I = {
|
|
4
4
|
computed: {},
|
|
5
5
|
methods: {
|
|
@@ -8524,7 +8524,7 @@ PictureUpload.name = "slw-picture-upload";
|
|
|
8524
8524
|
PictureUpload.install = (Q) => {
|
|
8525
8525
|
Q.component(PictureUpload.name, PictureUpload);
|
|
8526
8526
|
};
|
|
8527
|
-
const
|
|
8527
|
+
const windowGrid_vue_vue_type_style_index_0_scoped_84f8fc32_lang = "", _withScopeId$8 = (Q) => (pushScopeId("data-v-84f8fc32"), Q = Q(), popScopeId(), Q), _hoisted_1$l1 = {
|
|
8528
8528
|
class: "slw-window-grid-container",
|
|
8529
8529
|
style: { height: "100%" }
|
|
8530
8530
|
}, _hoisted_2$kY = /* @__PURE__ */ _withScopeId$8(() => /* @__PURE__ */ createElementVNode("span", { class: "vxe-table--cell-main-area" }, null, -1)), _hoisted_3$hY = /* @__PURE__ */ _withScopeId$8(() => /* @__PURE__ */ createElementVNode("span", { class: "vxe-table--cell-active-area" }, null, -1)), _hoisted_4$ay = /* @__PURE__ */ _withScopeId$8(() => /* @__PURE__ */ createElementVNode("span", { class: "vxe-table--cell-copy-area" }, null, -1)), _hoisted_5$4Y = [
|
|
@@ -8564,8 +8564,10 @@ const windowGrid_vue_vue_type_style_index_0_scoped_deefae39_lang = "", _withScop
|
|
|
8564
8564
|
const preTag = computed(() => gridData.value.params.preTag || ""), computeExcelUrl = computed(() => {
|
|
8565
8565
|
let Q = getCurRegion();
|
|
8566
8566
|
return Q.params.newImportUrl ? Q.params.newImportUrl : importUrl.value;
|
|
8567
|
-
}), showButtons = (Q) => gridData.value.toolbarConfig.buttons.filter(
|
|
8568
|
-
(
|
|
8567
|
+
}), showButtons = (Q, H) => gridData.value.type === "TREE" || gridData.value.type === "TREE_STRUCTURE" ? gridData.value.toolbarConfig.buttons.filter(
|
|
8568
|
+
(G) => G.showInGrid && G.btnShowInGrid[H._INDEX]
|
|
8569
|
+
) : gridData.value.toolbarConfig.buttons.filter(
|
|
8570
|
+
(G) => G.showInGrid && G.btnShowInGrid[Q]
|
|
8569
8571
|
), $modal = $Modal, $Message = ref({
|
|
8570
8572
|
success(Q) {
|
|
8571
8573
|
success(Q);
|
|
@@ -8607,6 +8609,7 @@ const windowGrid_vue_vue_type_style_index_0_scoped_deefae39_lang = "", _withScop
|
|
|
8607
8609
|
const data = Object.assign({}, datax);
|
|
8608
8610
|
let result = !1;
|
|
8609
8611
|
try {
|
|
8612
|
+
(gridData.value.type === "TREE" || gridData.value.type === "TREE_STRUCTURE") && typeof data._CHILDS > "u" && (data._CHILDS = "undefined");
|
|
8610
8613
|
for (const Q in data)
|
|
8611
8614
|
displayStr = displayStr.replace(
|
|
8612
8615
|
new RegExp("@" + Q + "@", "gi"),
|
|
@@ -8724,43 +8727,45 @@ const windowGrid_vue_vue_type_style_index_0_scoped_deefae39_lang = "", _withScop
|
|
|
8724
8727
|
return oe.then((le) => {
|
|
8725
8728
|
let se = {};
|
|
8726
8729
|
if (le && le.data && le.data.result && le.data.data && le.data.data.length > 0) {
|
|
8727
|
-
let
|
|
8728
|
-
|
|
8729
|
-
|
|
8730
|
-
|
|
8731
|
-
|
|
8732
|
-
|
|
8733
|
-
|
|
8734
|
-
|
|
8735
|
-
|
|
8736
|
-
|
|
8737
|
-
|
|
8738
|
-
|
|
8739
|
-
|
|
8740
|
-
|
|
8741
|
-
|
|
8742
|
-
|
|
8743
|
-
|
|
8744
|
-
|
|
8745
|
-
|
|
8746
|
-
|
|
8747
|
-
|
|
8730
|
+
let ue = function(me) {
|
|
8731
|
+
me.forEach((ve, ge) => {
|
|
8732
|
+
let we = 0;
|
|
8733
|
+
gridData.value.toolbarConfig.buttons.forEach((_e) => {
|
|
8734
|
+
if (typeof _e.type < "u") {
|
|
8735
|
+
_e.btnLoad[he] = !1;
|
|
8736
|
+
const xe = _e.displayLogic ? displayLogic(_e.displayLogic, {
|
|
8737
|
+
...ve,
|
|
8738
|
+
...assembleParentData(gridData.value.params.parentData)
|
|
8739
|
+
}) : !0, $e = _e.showInGrid && xe, ke = !_e.showInGrid && xe;
|
|
8740
|
+
if (_e.btnShowInGrid[he] = $e, _e.btnShow[he] = ke, ce = ce || $e, $e)
|
|
8741
|
+
if (_e.iconComponent)
|
|
8742
|
+
we = we + 0.7;
|
|
8743
|
+
else {
|
|
8744
|
+
let Ce = _e.name.match(/[\u4e00-\u9fa5]/g);
|
|
8745
|
+
if (Ce) {
|
|
8746
|
+
let be = Math.ceil(Ce.length / 2);
|
|
8747
|
+
we += be;
|
|
8748
|
+
} else {
|
|
8749
|
+
let be = Math.ceil(_e.name.length / 6);
|
|
8750
|
+
we += be;
|
|
8751
|
+
}
|
|
8748
8752
|
}
|
|
8749
|
-
|
|
8750
|
-
}
|
|
8751
|
-
})
|
|
8752
|
-
}
|
|
8753
|
-
|
|
8754
|
-
|
|
8755
|
-
|
|
8756
|
-
|
|
8753
|
+
}
|
|
8754
|
+
}), we > de && (de = we), ve._INDEX = he, he++, ve._CHILDS && ve._CHILDS.length > 0 && ue(ve._CHILDS);
|
|
8755
|
+
});
|
|
8756
|
+
}, ce = !1, de = 0, he = 0;
|
|
8757
|
+
ue(le.data.data);
|
|
8758
|
+
let fe = !1;
|
|
8759
|
+
gridData.value.columns.forEach((me) => {
|
|
8760
|
+
if (me.colId == "_operation_" && me.title == "操作") {
|
|
8761
|
+
me.width != de * 60 && de * 60 >= 60 && (fe = !0, me.width = de.toFixed(1) * 60);
|
|
8757
8762
|
return;
|
|
8758
8763
|
}
|
|
8759
|
-
}),
|
|
8760
|
-
const
|
|
8761
|
-
if (
|
|
8762
|
-
const
|
|
8763
|
-
|
|
8764
|
+
}), fe && getCurRegion().loadColumn(gridData.value.columns), gridData.value.params.rowIndex != null && (he = gridData.value.params.rowIndex), le.data.data.length > he ? se = le.data.data[he] : se = le.data.data[0];
|
|
8765
|
+
const pe = getCurRegion();
|
|
8766
|
+
if (pe) {
|
|
8767
|
+
const me = pe.getColumnById("_operation_");
|
|
8768
|
+
me && ce && pe.showColumn(me);
|
|
8764
8769
|
}
|
|
8765
8770
|
!isEditGridInitData.value && gridData.value.type === "EDIT_GRID" && editGridInitData(se);
|
|
8766
8771
|
}
|
|
@@ -9912,6 +9917,18 @@ const windowGrid_vue_vue_type_style_index_0_scoped_deefae39_lang = "", _withScop
|
|
|
9912
9917
|
Q && Q.formConfig.items.forEach((H) => {
|
|
9913
9918
|
H.field ? H.folding = !1 : H.align == "right" && (H.collapseNode = !1);
|
|
9914
9919
|
});
|
|
9920
|
+
}, headerCustomClick = ({ type: Q, $event: H }) => {
|
|
9921
|
+
if (Q == "confirm" || Q == "reset") {
|
|
9922
|
+
let G = getCurRegion().getColumns(), X = G.filter((K) => K.field).map((K) => K.field), Z = {
|
|
9923
|
+
_region_id: gridData.value.params._region_id,
|
|
9924
|
+
cols: G
|
|
9925
|
+
};
|
|
9926
|
+
axios.post("", Z).then((K) => {
|
|
9927
|
+
K.data.result || console.error(err);
|
|
9928
|
+
}).catch((K) => {
|
|
9929
|
+
console.error(K);
|
|
9930
|
+
});
|
|
9931
|
+
}
|
|
9915
9932
|
};
|
|
9916
9933
|
return onMounted(async () => {
|
|
9917
9934
|
gridData.value.addListener && getCurRegion() && addListener(), gridData.value.type === "TREE_STRUCTURE" && (gridData.value.menuConfig = {
|
|
@@ -10009,7 +10026,8 @@ const windowGrid_vue_vue_type_style_index_0_scoped_deefae39_lang = "", _withScop
|
|
|
10009
10026
|
onMenuClick: contextMenuClickEvent,
|
|
10010
10027
|
onCheckboxChange: headerCheckboxChange,
|
|
10011
10028
|
onCheckboxAll: headerCheckboxChange,
|
|
10012
|
-
onProxyQuery: headerProxyQuery
|
|
10029
|
+
onProxyQuery: headerProxyQuery,
|
|
10030
|
+
onCustom: headerCustomClick
|
|
10013
10031
|
}), {
|
|
10014
10032
|
scan_item: withCtx(({ data: ae, property: le }) => [
|
|
10015
10033
|
createVNode(G, {
|
|
@@ -10027,7 +10045,7 @@ const windowGrid_vue_vue_type_style_index_0_scoped_deefae39_lang = "", _withScop
|
|
|
10027
10045
|
}, 1032, ["modelValue", "onUpdate:modelValue"])
|
|
10028
10046
|
]),
|
|
10029
10047
|
operation: withCtx(({ row: ae, rowIndex: le }) => [
|
|
10030
|
-
(openBlock(!0), createElementBlock(Fragment, null, renderList(showButtons(le), (se) => (openBlock(), createBlock(K, {
|
|
10048
|
+
(openBlock(!0), createElementBlock(Fragment, null, renderList(showButtons(le, ae), (se) => (openBlock(), createBlock(K, {
|
|
10031
10049
|
key: se._button_id,
|
|
10032
10050
|
iconComponent: se.iconComponent,
|
|
10033
10051
|
"auto-insert-space": "",
|
|
@@ -10155,7 +10173,7 @@ const windowGrid_vue_vue_type_style_index_0_scoped_deefae39_lang = "", _withScop
|
|
|
10155
10173
|
]);
|
|
10156
10174
|
};
|
|
10157
10175
|
}
|
|
10158
|
-
}, WindowGrid = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["__scopeId", "data-v-
|
|
10176
|
+
}, WindowGrid = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["__scopeId", "data-v-84f8fc32"]]);
|
|
10159
10177
|
WindowGrid.name = "slw-window-grid";
|
|
10160
10178
|
WindowGrid.install = (Q) => {
|
|
10161
10179
|
Q.component(WindowGrid.name, WindowGrid);
|
|
@@ -59235,7 +59253,7 @@ const windowDesigner_vue_vue_type_style_index_0_scoped_a3ebe962_lang = "", _with
|
|
|
59235
59253
|
emits: ["update:type", "update:rootLayout", "update:viewData", "update:rowData"],
|
|
59236
59254
|
setup(Q, { emit: H }) {
|
|
59237
59255
|
const G = Q, X = defineAsyncComponent(
|
|
59238
|
-
() => import("./index-
|
|
59256
|
+
() => import("./index-b9b23ad7.js")
|
|
59239
59257
|
);
|
|
59240
59258
|
let Z = useVModel(G, "type", H), K = useVModel(G, "rootLayout", H), ee = useVModel(G, "viewData", H), te = useVModel(G, "rowData", H), ne = ref(0), re = ref(null);
|
|
59241
59259
|
re.value = createDesigner();
|
|
@@ -144233,7 +144251,7 @@ function reConsole() {
|
|
|
144233
144251
|
}
|
|
144234
144252
|
}
|
|
144235
144253
|
console.info(
|
|
144236
|
-
`%cSLW %cVer 0.9.
|
|
144254
|
+
`%cSLW %cVer 0.9.40%c
|
|
144237
144255
|
%c指引文档:%chttp://slwdoc.js.sforcecon.com:5900/%c
|
|
144238
144256
|
%c启光文档:%chttp://docs.js.sforcecon.com:5900/notepad/view/592`,
|
|
144239
144257
|
"color:#409EFF;font-size: 22px;font-weight:bolder;text-shadow: 2px 2px 4px #84c1ff;",
|
package/lib/index.js
CHANGED