cnhis-design-vue 3.0.9 → 3.1.2
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.
- package/CHANGELOG.md +42 -0
- package/es/big-table/index.js +49 -22
- package/es/button-print/index.css +46 -42
- package/es/button-print/index.js +135 -74
- package/es/drag-layout/index.css +45 -41
- package/es/field-set/index.css +45 -41
- package/es/grid/index.css +61 -57
- package/es/index.css +15 -11
- package/es/index.js +183 -95
- package/es/select-person/index.css +61 -57
- package/package.json +1 -1
- package/packages/big-table/src/BigTable.vue +11 -7
- package/packages/big-table/src/components/edit-form/edit-date.vue +1 -1
- package/packages/big-table/src/components/edit-form/edit-select.vue +37 -9
- package/packages/big-table/src/hooks/useEdit.ts +2 -3
- package/packages/button-print/src/ButtonPrint.vue +58 -52
- package/packages/button-print/src/components/IdentityVerification.vue +16 -15
package/es/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { watch, h as h$1, resolveComponent, defineComponent, inject, computed, nextTick, reactive, createApp, ref, Teleport, createCommentVNode, provide, onMounted, onUnmounted, getCurrentInstance, onBeforeUnmount, onActivated, onDeactivated, createVNode, mergeProps, isVNode, openBlock, createElementBlock, unref, createElementVNode, toDisplayString, withCtx, normalizeClass, renderSlot, createTextVNode, useAttrs, normalizeStyle, withDirectives, vShow, Fragment, createBlock, vModelSelect, vModelText, pushScopeId, popScopeId, vModelCheckbox, withModifiers, renderList } from 'vue';
|
|
2
2
|
import { NInput, NInputNumber, NSelect, NDatePicker, NTooltip, useMessage, NIcon, NPopconfirm, NButton, NInputGroup, NCheckbox, NCheckboxGroup, NSpace, NProgress, NDropdown, NSwitch, NPopover, NSpin, NRadio, NModal, NForm, NGrid, NFormItemGi, NFormItem, NTree } from 'naive-ui';
|
|
3
|
-
import { SettingsSharp, CaretDown, CaretForward, CopyOutline, SyncOutline, EllipsisVerticalSharp,
|
|
3
|
+
import { SettingsSharp, CaretDown, CaretForward, CopyOutline, SyncOutline, EllipsisVerticalSharp, ChevronDown, Search, CloseCircleSharp } from '@vicons/ionicons5';
|
|
4
4
|
import draggable from 'vuedraggable';
|
|
5
5
|
|
|
6
6
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
@@ -38481,21 +38481,34 @@ var script$d = defineComponent({
|
|
|
38481
38481
|
emits: ["setOptions", "formChange"],
|
|
38482
38482
|
setup(props, { attrs, slots, emit }) {
|
|
38483
38483
|
const state = reactive({
|
|
38484
|
-
options: []
|
|
38484
|
+
options: [],
|
|
38485
|
+
loading: false,
|
|
38486
|
+
keyword: "",
|
|
38487
|
+
config: {}
|
|
38485
38488
|
});
|
|
38486
38489
|
const setOptions = async () => {
|
|
38487
38490
|
if (props.col.options) {
|
|
38488
38491
|
state.options = JSON.parse(JSON.stringify(props.col.options));
|
|
38489
38492
|
}
|
|
38490
38493
|
else {
|
|
38491
|
-
|
|
38492
|
-
|
|
38493
|
-
|
|
38494
|
-
|
|
38495
|
-
|
|
38494
|
+
`${props.col.columnName}_options`;
|
|
38495
|
+
const obj = {
|
|
38496
|
+
keyword: state.keyword,
|
|
38497
|
+
row: props.row,
|
|
38498
|
+
column: props.col,
|
|
38499
|
+
index: props.index
|
|
38500
|
+
};
|
|
38501
|
+
state.options = await props.col.queryOptions(obj);
|
|
38502
|
+
state.loading = false;
|
|
38503
|
+
emit("setOptions", state.options);
|
|
38496
38504
|
}
|
|
38497
38505
|
};
|
|
38498
|
-
|
|
38506
|
+
let selectSearch = (value) => {
|
|
38507
|
+
state.keyword = value;
|
|
38508
|
+
state.loading = true;
|
|
38509
|
+
setOptions();
|
|
38510
|
+
};
|
|
38511
|
+
selectSearch = xeUtils.debounce(selectSearch, 800);
|
|
38499
38512
|
const onUpdateValue = (value) => {
|
|
38500
38513
|
emit("formChange", {
|
|
38501
38514
|
value,
|
|
@@ -38504,14 +38517,24 @@ var script$d = defineComponent({
|
|
|
38504
38517
|
index: props.index
|
|
38505
38518
|
});
|
|
38506
38519
|
};
|
|
38507
|
-
|
|
38508
|
-
|
|
38520
|
+
const init = () => {
|
|
38521
|
+
if (props.col.options) {
|
|
38522
|
+
setOptions();
|
|
38523
|
+
}
|
|
38524
|
+
else {
|
|
38525
|
+
state.config.remote = true;
|
|
38526
|
+
state.config.onSearch = selectSearch;
|
|
38527
|
+
selectSearch("");
|
|
38528
|
+
}
|
|
38529
|
+
};
|
|
38530
|
+
init();
|
|
38531
|
+
return () => [createVNode(NSelect, mergeProps(attrs, state.config, {
|
|
38509
38532
|
"options": state.options,
|
|
38510
38533
|
"consistentMenuWidth": false,
|
|
38511
38534
|
"clearable": true,
|
|
38512
38535
|
"filterable": true,
|
|
38513
|
-
"to": false,
|
|
38514
38536
|
"placeholder": "\u8BF7\u9009\u62E9",
|
|
38537
|
+
"loading": state.loading,
|
|
38515
38538
|
"onUpdateValue": onUpdateValue
|
|
38516
38539
|
}), null)];
|
|
38517
38540
|
}
|
|
@@ -38584,7 +38607,6 @@ var script$c = defineComponent({
|
|
|
38584
38607
|
clearable: props.col.clearable || true,
|
|
38585
38608
|
disabled: props.col.disabled || false,
|
|
38586
38609
|
valueFormat: props.col.valueFormat || "yyyy-MM-dd HH:mm:ss",
|
|
38587
|
-
to: false,
|
|
38588
38610
|
isDateDisabled: props.col.isDateDisabled || isDateDisabled
|
|
38589
38611
|
};
|
|
38590
38612
|
if (config.type.includes("time")) {
|
|
@@ -38687,12 +38709,11 @@ const useEdit = (props, state, emit, xGrid) => {
|
|
|
38687
38709
|
return params.row[item.formatMap.label];
|
|
38688
38710
|
}
|
|
38689
38711
|
if (item.options) {
|
|
38690
|
-
return item.options.find((v) => v.value == value)?.label || "";
|
|
38712
|
+
return item.options.find((v) => v.value == value)?.label || value || "";
|
|
38691
38713
|
}
|
|
38692
38714
|
if (item.queryOptions) {
|
|
38693
|
-
return params.row[`${item.columnName}_options`]?.find((v) => v.value === value)?.label || "";
|
|
38715
|
+
return params.row[`${item.columnName}_options`]?.find((v) => v.value === value)?.label || value || "";
|
|
38694
38716
|
}
|
|
38695
|
-
return value;
|
|
38696
38717
|
}
|
|
38697
38718
|
return value;
|
|
38698
38719
|
};
|
|
@@ -39566,7 +39587,8 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
39566
39587
|
const GROUP_TITLE_KEY = "group-show-title";
|
|
39567
39588
|
window.$message = useMessage();
|
|
39568
39589
|
const xGrid = ref(null);
|
|
39569
|
-
const
|
|
39590
|
+
const copyState = xeUtils.clone(bigTableState, true);
|
|
39591
|
+
const state = reactive(copyState);
|
|
39570
39592
|
const { formatData, htmlToText, getBtnStyle } = useFormat(state);
|
|
39571
39593
|
const { imgs2imgArr, parseDurationValue, parseCombinationValue, formatFieldText } = useTableParse(formatData);
|
|
39572
39594
|
const { allSelectedLength, checkOperateCurrentTable, setRowStatus, resetBatchOperationRowStatus, checkListFormUnionSettingParamsList, handleClickCancelBtnByInline, setAllRowInlineStatus, hideSelectCloumns, handleEditFormLength, resetOperationRowStatus, recordClickBtnInfo, getInlineOpreateRow } = useBatchEditing(props, state, emit, xGrid);
|
|
@@ -39742,7 +39764,7 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
39742
39764
|
return;
|
|
39743
39765
|
let currentPageTableData = table.getTableData()?.tableData;
|
|
39744
39766
|
let currentPageSelectedRows = currentPageTableData.filter((row) => {
|
|
39745
|
-
return currentCheckedKeys.value.includes(row[props.primaryKey]);
|
|
39767
|
+
return row[props.primaryKey] ? currentCheckedKeys.value.includes(row[props.primaryKey]) : false;
|
|
39746
39768
|
});
|
|
39747
39769
|
setCurrentCheckedLength();
|
|
39748
39770
|
if (!currentPageSelectedRows || !currentPageSelectedRows.length) {
|
|
@@ -39863,6 +39885,9 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
39863
39885
|
if (!isEdit || item.columnName === "operatorColumn" || !item.isEdit) {
|
|
39864
39886
|
return formatter(params, item);
|
|
39865
39887
|
}
|
|
39888
|
+
else if (isEdit && item.isEdit && item.checkEditStatus && item.checkEditStatus(params)) {
|
|
39889
|
+
return formatterEdit(params, item);
|
|
39890
|
+
}
|
|
39866
39891
|
else {
|
|
39867
39892
|
return createVNode("span", null, [getDefaultValue(params, item)]);
|
|
39868
39893
|
}
|
|
@@ -39921,13 +39946,13 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
39921
39946
|
onFormChange
|
|
39922
39947
|
};
|
|
39923
39948
|
if (formType === "date") {
|
|
39924
|
-
propsData.
|
|
39949
|
+
propsData.formattedValue = row[col.columnName];
|
|
39925
39950
|
}
|
|
39926
39951
|
else if (formatMap) {
|
|
39927
|
-
propsData.
|
|
39952
|
+
propsData.value = row[formatMap.value];
|
|
39928
39953
|
}
|
|
39929
39954
|
else {
|
|
39930
|
-
propsData.
|
|
39955
|
+
propsData.value = row[col.columnName];
|
|
39931
39956
|
}
|
|
39932
39957
|
if (formType === "select") {
|
|
39933
39958
|
propsData.onSetOptions = (options) => row[`${col.columnName}_options`] = options;
|
|
@@ -41414,7 +41439,8 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
41414
41439
|
loadData(value);
|
|
41415
41440
|
});
|
|
41416
41441
|
}, {
|
|
41417
|
-
immediate: true
|
|
41442
|
+
immediate: true,
|
|
41443
|
+
deep: true
|
|
41418
41444
|
});
|
|
41419
41445
|
watch(() => currentCheckedKeys, (val) => {
|
|
41420
41446
|
setVisibleCheckAllWrap(state, props, currentCheckedKeys.value);
|
|
@@ -41564,7 +41590,7 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
41564
41590
|
"highlight-current-row": "",
|
|
41565
41591
|
"show-footer-overflow": "title",
|
|
41566
41592
|
"keep-source": "",
|
|
41567
|
-
height: "auto",
|
|
41593
|
+
height: props.height ? "auto" : "unset",
|
|
41568
41594
|
resizable: "",
|
|
41569
41595
|
"auto-resize": "",
|
|
41570
41596
|
"seq-config": unref(handleSeqConfig),
|
|
@@ -41613,6 +41639,7 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
41613
41639
|
iconClose: "iconfont icon-a-xitongtubiaotianjia"
|
|
41614
41640
|
},
|
|
41615
41641
|
"keyboard-config": _ctx.columnConfig.keyboardConfig || {},
|
|
41642
|
+
"edit-rules": _ctx.columnConfig.editRules || {},
|
|
41616
41643
|
onCellDblclick: rowdblclick,
|
|
41617
41644
|
onCellClick: handlerClickRow,
|
|
41618
41645
|
onCheckboxChange: selectionChange,
|
|
@@ -41663,7 +41690,7 @@ var script$8 = /* @__PURE__ */ defineComponent({
|
|
|
41663
41690
|
}
|
|
41664
41691
|
})]),
|
|
41665
41692
|
_: 3
|
|
41666
|
-
}, 8, ["seq-config", "tree-config", "row-id", "show-footer", "checkbox-config", "row-style", "edit-config", "expand-config", "keyboard-config"]), createCommentVNode(" `${refreshRow}\u6761\u66F4\u65B0` "), withDirectives(createElementVNode("div", {
|
|
41693
|
+
}, 8, ["height", "seq-config", "tree-config", "row-id", "show-footer", "checkbox-config", "row-style", "edit-config", "expand-config", "keyboard-config", "edit-rules"]), createCommentVNode(" `${refreshRow}\u6761\u66F4\u65B0` "), withDirectives(createElementVNode("div", {
|
|
41667
41694
|
class: "refresh",
|
|
41668
41695
|
onClick: hanldeClickRefresh
|
|
41669
41696
|
}, [createVNode(unref(NIcon), {
|
|
@@ -45180,8 +45207,7 @@ var script$3 = /* @__PURE__ */ defineComponent({
|
|
|
45180
45207
|
password: { required: true, message: "\u8BF7\u8F93\u5165\u5BC6\u7801" }
|
|
45181
45208
|
};
|
|
45182
45209
|
const style = {
|
|
45183
|
-
width: "416px"
|
|
45184
|
-
height: "328px"
|
|
45210
|
+
width: "416px"
|
|
45185
45211
|
};
|
|
45186
45212
|
const formRef = ref(null);
|
|
45187
45213
|
const handleClickClose = () => {
|
|
@@ -45221,13 +45247,13 @@ var script$3 = /* @__PURE__ */ defineComponent({
|
|
|
45221
45247
|
show: __props.modelValue,
|
|
45222
45248
|
"close-on-esc": false,
|
|
45223
45249
|
"show-icon": false,
|
|
45224
|
-
style: normalizeStyle({ width: style.width,
|
|
45225
|
-
|
|
45250
|
+
style: normalizeStyle({ width: style.width, overflowY: "auto" }),
|
|
45251
|
+
onClose: handleClickClose
|
|
45226
45252
|
}, {
|
|
45227
45253
|
default: withCtx(() => [
|
|
45228
45254
|
createElementVNode("div", _hoisted_1$2, [
|
|
45229
45255
|
createVNode(unref(NForm), {
|
|
45230
|
-
class: "login-form",
|
|
45256
|
+
class: "login-form-button-print",
|
|
45231
45257
|
ref_key: "formRef",
|
|
45232
45258
|
ref: formRef,
|
|
45233
45259
|
model: unref(form),
|
|
@@ -45290,20 +45316,77 @@ const __default__$1 = create({
|
|
|
45290
45316
|
var script$2 = /* @__PURE__ */ defineComponent({
|
|
45291
45317
|
...__default__$1,
|
|
45292
45318
|
props: {
|
|
45293
|
-
btnText: {
|
|
45294
|
-
|
|
45295
|
-
|
|
45296
|
-
|
|
45297
|
-
|
|
45298
|
-
|
|
45299
|
-
|
|
45300
|
-
|
|
45301
|
-
|
|
45302
|
-
|
|
45303
|
-
|
|
45304
|
-
|
|
45319
|
+
btnText: {
|
|
45320
|
+
type: String,
|
|
45321
|
+
required: false,
|
|
45322
|
+
default: "\u6253\u5370"
|
|
45323
|
+
},
|
|
45324
|
+
printText: {
|
|
45325
|
+
type: String,
|
|
45326
|
+
required: false,
|
|
45327
|
+
default: "\u76F4\u63A5\u6253\u5370"
|
|
45328
|
+
},
|
|
45329
|
+
previewText: {
|
|
45330
|
+
type: String,
|
|
45331
|
+
required: false,
|
|
45332
|
+
default: "\u6253\u5370\u9884\u89C8"
|
|
45333
|
+
},
|
|
45334
|
+
formatEditText: {
|
|
45335
|
+
type: String,
|
|
45336
|
+
required: false,
|
|
45337
|
+
default: "\u683C\u5F0F\u7F16\u8F91"
|
|
45338
|
+
},
|
|
45339
|
+
identityVerificationTitle: {
|
|
45340
|
+
type: String,
|
|
45341
|
+
required: false,
|
|
45342
|
+
default: "\u6253\u5370\u670D\u52A1\u8EAB\u4EFD\u6821\u9A8C"
|
|
45343
|
+
},
|
|
45344
|
+
params: {
|
|
45345
|
+
type: Array,
|
|
45346
|
+
required: false,
|
|
45347
|
+
default: () => []
|
|
45348
|
+
},
|
|
45349
|
+
prevFn: {
|
|
45350
|
+
type: Function,
|
|
45351
|
+
required: false,
|
|
45352
|
+
default: () => Promise.resolve()
|
|
45353
|
+
},
|
|
45354
|
+
verifyUser: {
|
|
45355
|
+
type: Function,
|
|
45356
|
+
required: false,
|
|
45357
|
+
default: () => Promise.resolve()
|
|
45358
|
+
},
|
|
45359
|
+
queryPrintFormatByNumber: {
|
|
45360
|
+
type: Function,
|
|
45361
|
+
required: true,
|
|
45362
|
+
default: () => Promise.resolve({})
|
|
45363
|
+
},
|
|
45364
|
+
queryTemplateParams: {
|
|
45365
|
+
type: Function,
|
|
45366
|
+
required: false,
|
|
45367
|
+
default: () => Promise.resolve({})
|
|
45368
|
+
},
|
|
45369
|
+
strategy: {
|
|
45370
|
+
type: String,
|
|
45371
|
+
required: false,
|
|
45372
|
+
default: "MULTI"
|
|
45373
|
+
},
|
|
45374
|
+
printParams: {
|
|
45375
|
+
type: Array,
|
|
45376
|
+
required: false
|
|
45377
|
+
},
|
|
45378
|
+
clickPrevFn: {
|
|
45379
|
+
type: Function,
|
|
45380
|
+
required: false,
|
|
45381
|
+
default: () => Promise.resolve(true)
|
|
45382
|
+
},
|
|
45383
|
+
noDataMsg: {
|
|
45384
|
+
type: String,
|
|
45385
|
+
required: false,
|
|
45386
|
+
default: "\u8BF7\u9009\u4E2D\u9700\u8981\u6253\u5370\u7684\u6570\u636E"
|
|
45387
|
+
}
|
|
45305
45388
|
},
|
|
45306
|
-
emits: ["success", "error"],
|
|
45389
|
+
emits: ["success", "error", "clickoutside"],
|
|
45307
45390
|
setup(__props, { emit }) {
|
|
45308
45391
|
const props = __props;
|
|
45309
45392
|
window.$message = useMessage();
|
|
@@ -45322,27 +45405,30 @@ var script$2 = /* @__PURE__ */ defineComponent({
|
|
|
45322
45405
|
watchPrintParamsReformatFn: null,
|
|
45323
45406
|
spinTimer: null
|
|
45324
45407
|
});
|
|
45325
|
-
const options = reactive([
|
|
45326
|
-
{
|
|
45408
|
+
const options = reactive([{
|
|
45327
45409
|
label: props.printText,
|
|
45328
45410
|
key: "printText"
|
|
45329
|
-
},
|
|
45330
|
-
{
|
|
45411
|
+
}, {
|
|
45331
45412
|
label: props.previewText,
|
|
45332
45413
|
key: "previewText"
|
|
45333
|
-
},
|
|
45334
|
-
{
|
|
45414
|
+
}, {
|
|
45335
45415
|
label: props.formatEditText,
|
|
45336
45416
|
key: "formatEditText"
|
|
45337
|
-
}
|
|
45338
|
-
]);
|
|
45417
|
+
}]);
|
|
45339
45418
|
const currentFormatItem = computed(() => {
|
|
45340
45419
|
if (!state.currentFormatId)
|
|
45341
45420
|
return {};
|
|
45342
45421
|
let id = state.currentFormatId;
|
|
45343
45422
|
return state.formatList.find((item) => item.id === id);
|
|
45344
45423
|
});
|
|
45345
|
-
computed(() => currentFormatItem.value.name || "\u683C\u5F0F\u9009\u62E9");
|
|
45424
|
+
const formatTitle = computed(() => currentFormatItem.value.name || "\u683C\u5F0F\u9009\u62E9");
|
|
45425
|
+
const renderLabel = (option) => {
|
|
45426
|
+
return createVNode("span", {
|
|
45427
|
+
"class": {
|
|
45428
|
+
"active": option.key === state.currentFormatId
|
|
45429
|
+
}
|
|
45430
|
+
}, [option.label]);
|
|
45431
|
+
};
|
|
45346
45432
|
const getTemplateIdByFormatId = (id) => {
|
|
45347
45433
|
let find = state.formatList.find((item) => item.id === id);
|
|
45348
45434
|
return find.templateId;
|
|
@@ -45472,21 +45558,13 @@ var script$2 = /* @__PURE__ */ defineComponent({
|
|
|
45472
45558
|
break;
|
|
45473
45559
|
default:
|
|
45474
45560
|
state.currentFormatId = key;
|
|
45561
|
+
state.visible = false;
|
|
45475
45562
|
break;
|
|
45476
45563
|
}
|
|
45477
45564
|
};
|
|
45478
45565
|
const handleClickOutside = () => {
|
|
45479
45566
|
state.visible = false;
|
|
45480
|
-
|
|
45481
|
-
const handleClickWrap = () => {
|
|
45482
|
-
setTimeout(() => {
|
|
45483
|
-
state.visible = true;
|
|
45484
|
-
}, 0);
|
|
45485
|
-
};
|
|
45486
|
-
const setTimeoutSpin = () => {
|
|
45487
|
-
state.spinTimer = setTimeout(() => {
|
|
45488
|
-
state.spinning = true;
|
|
45489
|
-
}, 1500);
|
|
45567
|
+
emit("clickoutside");
|
|
45490
45568
|
};
|
|
45491
45569
|
const instantiatePrintSDK = () => {
|
|
45492
45570
|
if (printInstance)
|
|
@@ -45499,6 +45577,19 @@ var script$2 = /* @__PURE__ */ defineComponent({
|
|
|
45499
45577
|
let findDefault = list.find((item) => item[key] == 1);
|
|
45500
45578
|
return findDefault?.id || list[0].id;
|
|
45501
45579
|
};
|
|
45580
|
+
const setOptions = () => {
|
|
45581
|
+
const children = state.formatList.map((v) => {
|
|
45582
|
+
return {
|
|
45583
|
+
label: v.name,
|
|
45584
|
+
key: v.id
|
|
45585
|
+
};
|
|
45586
|
+
});
|
|
45587
|
+
options.unshift({
|
|
45588
|
+
label: formatTitle.value,
|
|
45589
|
+
key: "format",
|
|
45590
|
+
children
|
|
45591
|
+
});
|
|
45592
|
+
};
|
|
45502
45593
|
const formatFormatList = (list) => {
|
|
45503
45594
|
let formatList = [];
|
|
45504
45595
|
list.forEach((item) => {
|
|
@@ -45508,16 +45599,9 @@ var script$2 = /* @__PURE__ */ defineComponent({
|
|
|
45508
45599
|
});
|
|
45509
45600
|
return formatList;
|
|
45510
45601
|
};
|
|
45511
|
-
const setLoaded = () => {
|
|
45512
|
-
state.spinning = false;
|
|
45513
|
-
if (!state.spinTimer)
|
|
45514
|
-
return false;
|
|
45515
|
-
clearTimeout(state.spinTimer);
|
|
45516
|
-
state.spinTimer = null;
|
|
45517
|
-
};
|
|
45518
45602
|
const requestError = () => {
|
|
45519
45603
|
state.isInited = false;
|
|
45520
|
-
|
|
45604
|
+
state.spinning = false;
|
|
45521
45605
|
setTimeout(() => {
|
|
45522
45606
|
state.visible = false;
|
|
45523
45607
|
}, 0);
|
|
@@ -45564,6 +45648,7 @@ var script$2 = /* @__PURE__ */ defineComponent({
|
|
|
45564
45648
|
state.formatList = formatListResult ? formatFormatList(formatListResult.obj) : [];
|
|
45565
45649
|
console.log("formatListResult", formatListResult);
|
|
45566
45650
|
state.currentFormatId = getDefaultFormatId(state.formatList, "defaultFlag");
|
|
45651
|
+
setOptions();
|
|
45567
45652
|
if (!state.currentFormatId) {
|
|
45568
45653
|
window.$message.error("\u83B7\u53D6\u6253\u5370\u683C\u5F0F\u5931\u8D25\uFF0C\u8BF7\u8054\u7CFB\u7BA1\u7406\u5458\uFF01");
|
|
45569
45654
|
return requestError();
|
|
@@ -45585,14 +45670,21 @@ var script$2 = /* @__PURE__ */ defineComponent({
|
|
|
45585
45670
|
if (state.isInited)
|
|
45586
45671
|
return true;
|
|
45587
45672
|
state.isInited = true;
|
|
45588
|
-
|
|
45673
|
+
state.spinning = true;
|
|
45589
45674
|
instantiatePrintSDK();
|
|
45590
45675
|
const formatListResult = await props.queryPrintFormatByNumber();
|
|
45591
45676
|
await initCRM(formatListResult);
|
|
45592
|
-
|
|
45677
|
+
state.spinning = false;
|
|
45593
45678
|
return true;
|
|
45594
45679
|
};
|
|
45595
45680
|
const handleClickBtn = async () => {
|
|
45681
|
+
const status = await props.clickPrevFn();
|
|
45682
|
+
if (!status)
|
|
45683
|
+
return;
|
|
45684
|
+
if (!props.params?.length) {
|
|
45685
|
+
window.$message.warning(props.noDataMsg);
|
|
45686
|
+
return;
|
|
45687
|
+
}
|
|
45596
45688
|
if (!state.visible) {
|
|
45597
45689
|
let result = await init();
|
|
45598
45690
|
if (!result)
|
|
@@ -45631,48 +45723,44 @@ var script$2 = /* @__PURE__ */ defineComponent({
|
|
|
45631
45723
|
if (!val?.length)
|
|
45632
45724
|
return false;
|
|
45633
45725
|
reformatPrintParams();
|
|
45634
|
-
}, {
|
|
45726
|
+
}, {
|
|
45727
|
+
deep: true
|
|
45728
|
+
});
|
|
45635
45729
|
return (_ctx, _cache) => {
|
|
45636
|
-
return openBlock(), createElementBlock(
|
|
45637
|
-
|
|
45730
|
+
return openBlock(), createElementBlock(Fragment, null, [createVNode(unref(NDropdown), {
|
|
45731
|
+
class: "rowFoldHideBtnList-dropdown",
|
|
45638
45732
|
placement: "bottom-start",
|
|
45733
|
+
trigger: "click",
|
|
45639
45734
|
show: unref(state).visible,
|
|
45640
45735
|
onClickoutside: handleClickOutside,
|
|
45641
45736
|
options: unref(options),
|
|
45642
|
-
onSelect: handleSelect
|
|
45737
|
+
onSelect: handleSelect,
|
|
45738
|
+
"render-label": renderLabel
|
|
45643
45739
|
}, {
|
|
45644
|
-
default: withCtx(() => [
|
|
45645
|
-
renderSlot(_ctx.$slots, "button", {
|
|
45740
|
+
default: withCtx(() => [renderSlot(_ctx.$slots, "button", {
|
|
45646
45741
|
handleClickPrintBtn: handleClickBtn,
|
|
45647
45742
|
printSpinning: unref(state).spinning,
|
|
45648
45743
|
printbtnText: __props.btnText,
|
|
45649
45744
|
printVisible: unref(state).visible
|
|
45650
|
-
}, () => [
|
|
45651
|
-
createVNode(unref(NButton), {
|
|
45745
|
+
}, () => [createVNode(unref(NButton), {
|
|
45652
45746
|
class: "dropdown-button",
|
|
45653
|
-
style: {
|
|
45747
|
+
style: {
|
|
45748
|
+
"margin": "0 8px 8px 0"
|
|
45749
|
+
},
|
|
45654
45750
|
onClick: withModifiers(handleClickBtn, ["stop"])
|
|
45655
45751
|
}, {
|
|
45656
|
-
default: withCtx(() => [
|
|
45657
|
-
|
|
45658
|
-
|
|
45659
|
-
component: unref(Reload),
|
|
45660
|
-
style: { "line-height": "10px" }
|
|
45661
|
-
}, null, 8, ["component"])) : createCommentVNode("v-if", true),
|
|
45662
|
-
createTextVNode(" " + toDisplayString(__props.btnText) + " ", 1),
|
|
45663
|
-
createVNode(unref(NIcon), { component: unref(ChevronDown) }, null, 8, ["component"])
|
|
45664
|
-
]),
|
|
45752
|
+
default: withCtx(() => [createCommentVNode(' <n-spin v-show="state.spinning" size="small"></n-spin> '), createTextVNode(toDisplayString(__props.btnText) + " ", 1), createVNode(unref(NIcon), {
|
|
45753
|
+
component: unref(ChevronDown)
|
|
45754
|
+
}, null, 8, ["component"])]),
|
|
45665
45755
|
_: 1
|
|
45666
|
-
}, 8, ["onClick"])
|
|
45667
|
-
])
|
|
45668
|
-
]),
|
|
45756
|
+
}, 8, ["onClick"])])]),
|
|
45669
45757
|
_: 3
|
|
45670
|
-
}, 8, ["show", "options"]),
|
|
45671
|
-
createVNode(script$3, mergeProps({
|
|
45758
|
+
}, 8, ["show", "options"]), createVNode(script$3, mergeProps({
|
|
45672
45759
|
modelValue: unref(state).identityVerification.visible,
|
|
45673
45760
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => unref(state).identityVerification.visible = $event)
|
|
45674
|
-
}, _ctx.$attrs, {
|
|
45675
|
-
|
|
45761
|
+
}, _ctx.$attrs, {
|
|
45762
|
+
onSuccess: verifiySuccess
|
|
45763
|
+
}), null, 16, ["modelValue"])], 64);
|
|
45676
45764
|
};
|
|
45677
45765
|
}
|
|
45678
45766
|
});
|