@tmagic/form 1.5.20 → 1.5.22
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/dist/tmagic-form.js +1049 -1493
- package/dist/tmagic-form.umd.cjs +1049 -1493
- package/package.json +4 -4
- package/src/containers/GroupListItem.vue +3 -1
- package/src/fields/Select.vue +20 -10
- package/types/index.d.ts +404 -375
package/dist/tmagic-form.js
CHANGED
|
@@ -411,277 +411,238 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
|
|
|
411
411
|
"label-width": itemLabelWidth.value,
|
|
412
412
|
onChange: onChangeHandler,
|
|
413
413
|
onAddDiffCount
|
|
414
|
-
}, null, 40, ["size", "model", "last-values", "is-compare", "config", "disabled", "name", "prop", "step-active", "expand-more", "label-width"])) : type.value && display$1.value && !showDiff.value ? (openBlock(), createElementBlock(
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
414
|
+
}, null, 40, ["size", "model", "last-values", "is-compare", "config", "disabled", "name", "prop", "step-active", "expand-more", "label-width"])) : type.value && display$1.value && !showDiff.value ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
415
|
+
createVNode(unref(TMagicFormItem), {
|
|
416
|
+
style: normalizeStyle(_ctx.config.tip ? "flex: 1" : ""),
|
|
417
|
+
class: normalizeClass({ "tmagic-form-hidden": `${itemLabelWidth.value}` === "0" || !text.value }),
|
|
418
|
+
prop: itemProp.value,
|
|
419
|
+
"label-width": itemLabelWidth.value,
|
|
420
|
+
"label-position": _ctx.config.labelPosition,
|
|
421
|
+
rules: rule.value
|
|
422
|
+
}, {
|
|
423
|
+
label: withCtx(() => [
|
|
424
|
+
createElementVNode("span", {
|
|
425
|
+
innerHTML: type.value === "checkbox" ? "" : text.value,
|
|
426
|
+
title: _ctx.config.labelTitle
|
|
427
|
+
}, null, 8, _hoisted_2$7)
|
|
428
|
+
]),
|
|
429
|
+
default: withCtx(() => [
|
|
430
|
+
tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
|
|
431
|
+
content: withCtx(() => [
|
|
432
|
+
createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_3$5)
|
|
433
|
+
]),
|
|
434
|
+
default: withCtx(() => [
|
|
435
|
+
(openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
436
|
+
key: key(_ctx.config),
|
|
437
|
+
size: _ctx.size,
|
|
438
|
+
model: _ctx.model,
|
|
439
|
+
"last-values": _ctx.lastValues,
|
|
440
|
+
config: _ctx.config,
|
|
441
|
+
name: name.value,
|
|
442
|
+
disabled: disabled.value,
|
|
443
|
+
prop: itemProp.value,
|
|
444
|
+
onChange: onChangeHandler,
|
|
445
|
+
onAddDiffCount
|
|
446
|
+
}, null, 40, ["size", "model", "last-values", "config", "name", "disabled", "prop"]))
|
|
447
|
+
]),
|
|
448
|
+
_: 1
|
|
449
|
+
})) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
450
|
+
key: key(_ctx.config),
|
|
451
|
+
size: _ctx.size,
|
|
452
|
+
model: _ctx.model,
|
|
453
|
+
"last-values": _ctx.lastValues,
|
|
454
|
+
config: _ctx.config,
|
|
455
|
+
name: name.value,
|
|
456
|
+
disabled: disabled.value,
|
|
457
|
+
prop: itemProp.value,
|
|
458
|
+
onChange: onChangeHandler,
|
|
459
|
+
onAddDiffCount
|
|
460
|
+
}, null, 40, ["size", "model", "last-values", "config", "name", "disabled", "prop"])),
|
|
461
|
+
extra.value && type.value !== "table" ? (openBlock(), createElementBlock("div", {
|
|
462
|
+
key: 2,
|
|
463
|
+
innerHTML: extra.value,
|
|
464
|
+
class: "m-form-tip"
|
|
465
|
+
}, null, 8, _hoisted_4$3)) : createCommentVNode("", true)
|
|
466
|
+
]),
|
|
467
|
+
_: 1
|
|
468
|
+
}, 8, ["style", "class", "prop", "label-width", "label-position", "rules"]),
|
|
469
|
+
_ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
470
|
+
key: 0,
|
|
471
|
+
placement: "left"
|
|
472
|
+
}, {
|
|
473
|
+
content: withCtx(() => [
|
|
474
|
+
createElementVNode("div", {
|
|
475
|
+
innerHTML: _ctx.config.tip
|
|
476
|
+
}, null, 8, _hoisted_5$3)
|
|
477
|
+
]),
|
|
478
|
+
default: withCtx(() => [
|
|
479
|
+
createVNode(unref(TMagicIcon), { style: { "line-height": "40px", "margin-left": "5px" } }, {
|
|
480
|
+
default: withCtx(() => [
|
|
481
|
+
createVNode(unref(WarningFilled))
|
|
482
|
+
]),
|
|
483
|
+
_: 1
|
|
484
|
+
})
|
|
485
|
+
]),
|
|
486
|
+
_: 1
|
|
487
|
+
})) : createCommentVNode("", true)
|
|
488
|
+
], 64)) : type.value && display$1.value && showDiff.value ? (openBlock(), createElementBlock(Fragment, { key: 3 }, [
|
|
489
|
+
createVNode(unref(TMagicFormItem), {
|
|
490
|
+
style: normalizeStyle([_ctx.config.tip ? "flex: 1" : "", { "background": "#f7dadd" }]),
|
|
491
|
+
class: normalizeClass({ "tmagic-form-hidden": `${itemLabelWidth.value}` === "0" || !text.value }),
|
|
492
|
+
prop: itemProp.value,
|
|
493
|
+
"label-width": itemLabelWidth.value,
|
|
494
|
+
"label-position": _ctx.config.labelPosition,
|
|
495
|
+
rules: rule.value
|
|
496
|
+
}, {
|
|
497
|
+
label: withCtx(() => [
|
|
498
|
+
createElementVNode("span", {
|
|
499
|
+
innerHTML: type.value === "checkbox" ? "" : text.value,
|
|
500
|
+
title: _ctx.config.labelTitle
|
|
501
|
+
}, null, 8, _hoisted_6$2)
|
|
502
|
+
]),
|
|
503
|
+
default: withCtx(() => [
|
|
504
|
+
tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
|
|
505
|
+
content: withCtx(() => [
|
|
506
|
+
createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_7$1)
|
|
507
|
+
]),
|
|
508
|
+
default: withCtx(() => [
|
|
509
|
+
(openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
510
|
+
key: key(_ctx.config),
|
|
511
|
+
size: _ctx.size,
|
|
512
|
+
model: _ctx.lastValues,
|
|
513
|
+
config: _ctx.config,
|
|
514
|
+
name: name.value,
|
|
515
|
+
disabled: disabled.value,
|
|
516
|
+
prop: itemProp.value,
|
|
517
|
+
onChange: onChangeHandler
|
|
518
|
+
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"]))
|
|
519
|
+
]),
|
|
520
|
+
_: 1
|
|
521
|
+
})) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
522
|
+
key: key(_ctx.config),
|
|
523
|
+
size: _ctx.size,
|
|
524
|
+
model: _ctx.lastValues,
|
|
525
|
+
config: _ctx.config,
|
|
526
|
+
name: name.value,
|
|
527
|
+
disabled: disabled.value,
|
|
528
|
+
prop: itemProp.value,
|
|
529
|
+
onChange: onChangeHandler
|
|
530
|
+
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"])),
|
|
531
|
+
extra.value ? (openBlock(), createElementBlock("div", {
|
|
532
|
+
key: 2,
|
|
533
|
+
innerHTML: extra.value,
|
|
534
|
+
class: "m-form-tip"
|
|
535
|
+
}, null, 8, _hoisted_8$1)) : createCommentVNode("", true)
|
|
536
|
+
]),
|
|
537
|
+
_: 1
|
|
538
|
+
}, 8, ["style", "class", "prop", "label-width", "label-position", "rules"]),
|
|
539
|
+
_ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
540
|
+
key: 0,
|
|
541
|
+
placement: "left"
|
|
542
|
+
}, {
|
|
543
|
+
content: withCtx(() => [
|
|
544
|
+
createElementVNode("div", {
|
|
545
|
+
innerHTML: _ctx.config.tip
|
|
546
|
+
}, null, 8, _hoisted_9)
|
|
547
|
+
]),
|
|
548
|
+
default: withCtx(() => [
|
|
549
|
+
createVNode(unref(TMagicIcon), { style: { "line-height": "40px", "margin-left": "5px" } }, {
|
|
550
|
+
default: withCtx(() => [
|
|
551
|
+
createVNode(unref(WarningFilled))
|
|
552
|
+
]),
|
|
553
|
+
_: 1
|
|
554
|
+
})
|
|
555
|
+
]),
|
|
556
|
+
_: 1
|
|
557
|
+
})) : createCommentVNode("", true),
|
|
558
|
+
createVNode(unref(TMagicFormItem), {
|
|
559
|
+
style: normalizeStyle([_ctx.config.tip ? "flex: 1" : "", { "background": "#def7da" }]),
|
|
560
|
+
class: normalizeClass({ "tmagic-form-hidden": `${itemLabelWidth.value}` === "0" || !text.value }),
|
|
561
|
+
prop: itemProp.value,
|
|
562
|
+
"label-width": itemLabelWidth.value,
|
|
563
|
+
"label-position": _ctx.config.labelPosition,
|
|
564
|
+
rules: rule.value
|
|
565
|
+
}, {
|
|
566
|
+
label: withCtx(() => [
|
|
567
|
+
createElementVNode("span", {
|
|
568
|
+
innerHTML: type.value === "checkbox" ? "" : text.value,
|
|
569
|
+
title: _ctx.config.labelTitle
|
|
570
|
+
}, null, 8, _hoisted_10)
|
|
571
|
+
]),
|
|
572
|
+
default: withCtx(() => [
|
|
573
|
+
tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
|
|
574
|
+
content: withCtx(() => [
|
|
575
|
+
createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_11)
|
|
576
|
+
]),
|
|
577
|
+
default: withCtx(() => [
|
|
578
|
+
(openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
579
|
+
key: key(_ctx.config),
|
|
580
|
+
size: _ctx.size,
|
|
581
|
+
model: _ctx.model,
|
|
582
|
+
config: _ctx.config,
|
|
583
|
+
name: name.value,
|
|
584
|
+
disabled: disabled.value,
|
|
585
|
+
prop: itemProp.value,
|
|
586
|
+
onChange: onChangeHandler
|
|
587
|
+
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"]))
|
|
588
|
+
]),
|
|
589
|
+
_: 1
|
|
590
|
+
})) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
591
|
+
key: key(_ctx.config),
|
|
592
|
+
size: _ctx.size,
|
|
593
|
+
model: _ctx.model,
|
|
594
|
+
config: _ctx.config,
|
|
595
|
+
name: name.value,
|
|
596
|
+
disabled: disabled.value,
|
|
597
|
+
prop: itemProp.value,
|
|
598
|
+
onChange: onChangeHandler
|
|
599
|
+
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"])),
|
|
600
|
+
extra.value ? (openBlock(), createElementBlock("div", {
|
|
601
|
+
key: 2,
|
|
602
|
+
innerHTML: extra.value,
|
|
603
|
+
class: "m-form-tip"
|
|
604
|
+
}, null, 8, _hoisted_12)) : createCommentVNode("", true)
|
|
605
|
+
]),
|
|
606
|
+
_: 1
|
|
607
|
+
}, 8, ["style", "class", "prop", "label-width", "label-position", "rules"]),
|
|
608
|
+
_ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
609
|
+
key: 1,
|
|
610
|
+
placement: "left"
|
|
611
|
+
}, {
|
|
612
|
+
content: withCtx(() => [
|
|
613
|
+
createElementVNode("div", {
|
|
614
|
+
innerHTML: _ctx.config.tip
|
|
615
|
+
}, null, 8, _hoisted_13)
|
|
616
|
+
]),
|
|
617
|
+
default: withCtx(() => [
|
|
618
|
+
createVNode(unref(TMagicIcon), { style: { "line-height": "40px", "margin-left": "5px" } }, {
|
|
619
|
+
default: withCtx(() => [
|
|
620
|
+
createVNode(unref(WarningFilled))
|
|
621
|
+
]),
|
|
622
|
+
_: 1
|
|
623
|
+
})
|
|
624
|
+
]),
|
|
625
|
+
_: 1
|
|
626
|
+
})) : createCommentVNode("", true)
|
|
627
|
+
], 64)) : items.value && display$1.value ? (openBlock(), createElementBlock(Fragment, { key: 4 }, [
|
|
628
|
+
(isValidName() ? _ctx.model[name.value] : _ctx.model) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(items.value, (item) => {
|
|
629
|
+
return openBlock(), createBlock(_component_Container, {
|
|
630
|
+
key: key(item),
|
|
631
|
+
model: isValidName() ? _ctx.model[name.value] : _ctx.model,
|
|
632
|
+
"last-values": isValidName() ? _ctx.lastValues[name.value] || {} : _ctx.lastValues,
|
|
633
|
+
"is-compare": _ctx.isCompare,
|
|
634
|
+
config: item,
|
|
635
|
+
size: _ctx.size,
|
|
636
|
+
disabled: disabled.value,
|
|
637
|
+
"step-active": _ctx.stepActive,
|
|
638
|
+
"expand-more": expand.value,
|
|
508
639
|
"label-width": itemLabelWidth.value,
|
|
509
|
-
"label-position": _ctx.config.labelPosition,
|
|
510
|
-
rules: rule.value
|
|
511
|
-
}, {
|
|
512
|
-
label: withCtx(() => [
|
|
513
|
-
createElementVNode("span", {
|
|
514
|
-
innerHTML: type.value === "checkbox" ? "" : text.value,
|
|
515
|
-
title: _ctx.config.labelTitle
|
|
516
|
-
}, null, 8, _hoisted_6$2)
|
|
517
|
-
]),
|
|
518
|
-
default: withCtx(() => [
|
|
519
|
-
tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
|
|
520
|
-
content: withCtx(() => [
|
|
521
|
-
createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_7$1)
|
|
522
|
-
]),
|
|
523
|
-
default: withCtx(() => [
|
|
524
|
-
(openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
525
|
-
key: key(_ctx.config),
|
|
526
|
-
size: _ctx.size,
|
|
527
|
-
model: _ctx.lastValues,
|
|
528
|
-
config: _ctx.config,
|
|
529
|
-
name: name.value,
|
|
530
|
-
disabled: disabled.value,
|
|
531
|
-
prop: itemProp.value,
|
|
532
|
-
onChange: onChangeHandler
|
|
533
|
-
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"]))
|
|
534
|
-
]),
|
|
535
|
-
_: 1
|
|
536
|
-
/* STABLE */
|
|
537
|
-
})) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
538
|
-
key: key(_ctx.config),
|
|
539
|
-
size: _ctx.size,
|
|
540
|
-
model: _ctx.lastValues,
|
|
541
|
-
config: _ctx.config,
|
|
542
|
-
name: name.value,
|
|
543
|
-
disabled: disabled.value,
|
|
544
|
-
prop: itemProp.value,
|
|
545
|
-
onChange: onChangeHandler
|
|
546
|
-
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"])),
|
|
547
|
-
extra.value ? (openBlock(), createElementBlock("div", {
|
|
548
|
-
key: 2,
|
|
549
|
-
innerHTML: extra.value,
|
|
550
|
-
class: "m-form-tip"
|
|
551
|
-
}, null, 8, _hoisted_8$1)) : createCommentVNode("v-if", true)
|
|
552
|
-
]),
|
|
553
|
-
_: 1
|
|
554
|
-
/* STABLE */
|
|
555
|
-
}, 8, ["style", "class", "prop", "label-width", "label-position", "rules"]),
|
|
556
|
-
_ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
557
|
-
key: 0,
|
|
558
|
-
placement: "left"
|
|
559
|
-
}, {
|
|
560
|
-
content: withCtx(() => [
|
|
561
|
-
createElementVNode("div", {
|
|
562
|
-
innerHTML: _ctx.config.tip
|
|
563
|
-
}, null, 8, _hoisted_9)
|
|
564
|
-
]),
|
|
565
|
-
default: withCtx(() => [
|
|
566
|
-
createVNode(unref(TMagicIcon), { style: { "line-height": "40px", "margin-left": "5px" } }, {
|
|
567
|
-
default: withCtx(() => [
|
|
568
|
-
createVNode(unref(WarningFilled))
|
|
569
|
-
]),
|
|
570
|
-
_: 1
|
|
571
|
-
/* STABLE */
|
|
572
|
-
})
|
|
573
|
-
]),
|
|
574
|
-
_: 1
|
|
575
|
-
/* STABLE */
|
|
576
|
-
})) : createCommentVNode("v-if", true),
|
|
577
|
-
createCommentVNode(" 当前内容 "),
|
|
578
|
-
createVNode(unref(TMagicFormItem), {
|
|
579
|
-
style: normalizeStyle([_ctx.config.tip ? "flex: 1" : "", { "background": "#def7da" }]),
|
|
580
|
-
class: normalizeClass({ "tmagic-form-hidden": `${itemLabelWidth.value}` === "0" || !text.value }),
|
|
581
640
|
prop: itemProp.value,
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
createElementVNode("span", {
|
|
588
|
-
innerHTML: type.value === "checkbox" ? "" : text.value,
|
|
589
|
-
title: _ctx.config.labelTitle
|
|
590
|
-
}, null, 8, _hoisted_10)
|
|
591
|
-
]),
|
|
592
|
-
default: withCtx(() => [
|
|
593
|
-
tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
|
|
594
|
-
content: withCtx(() => [
|
|
595
|
-
createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_11)
|
|
596
|
-
]),
|
|
597
|
-
default: withCtx(() => [
|
|
598
|
-
(openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
599
|
-
key: key(_ctx.config),
|
|
600
|
-
size: _ctx.size,
|
|
601
|
-
model: _ctx.model,
|
|
602
|
-
config: _ctx.config,
|
|
603
|
-
name: name.value,
|
|
604
|
-
disabled: disabled.value,
|
|
605
|
-
prop: itemProp.value,
|
|
606
|
-
onChange: onChangeHandler
|
|
607
|
-
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"]))
|
|
608
|
-
]),
|
|
609
|
-
_: 1
|
|
610
|
-
/* STABLE */
|
|
611
|
-
})) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
|
|
612
|
-
key: key(_ctx.config),
|
|
613
|
-
size: _ctx.size,
|
|
614
|
-
model: _ctx.model,
|
|
615
|
-
config: _ctx.config,
|
|
616
|
-
name: name.value,
|
|
617
|
-
disabled: disabled.value,
|
|
618
|
-
prop: itemProp.value,
|
|
619
|
-
onChange: onChangeHandler
|
|
620
|
-
}, null, 40, ["size", "model", "config", "name", "disabled", "prop"])),
|
|
621
|
-
extra.value ? (openBlock(), createElementBlock("div", {
|
|
622
|
-
key: 2,
|
|
623
|
-
innerHTML: extra.value,
|
|
624
|
-
class: "m-form-tip"
|
|
625
|
-
}, null, 8, _hoisted_12)) : createCommentVNode("v-if", true)
|
|
626
|
-
]),
|
|
627
|
-
_: 1
|
|
628
|
-
/* STABLE */
|
|
629
|
-
}, 8, ["style", "class", "prop", "label-width", "label-position", "rules"]),
|
|
630
|
-
_ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
631
|
-
key: 1,
|
|
632
|
-
placement: "left"
|
|
633
|
-
}, {
|
|
634
|
-
content: withCtx(() => [
|
|
635
|
-
createElementVNode("div", {
|
|
636
|
-
innerHTML: _ctx.config.tip
|
|
637
|
-
}, null, 8, _hoisted_13)
|
|
638
|
-
]),
|
|
639
|
-
default: withCtx(() => [
|
|
640
|
-
createVNode(unref(TMagicIcon), { style: { "line-height": "40px", "margin-left": "5px" } }, {
|
|
641
|
-
default: withCtx(() => [
|
|
642
|
-
createVNode(unref(WarningFilled))
|
|
643
|
-
]),
|
|
644
|
-
_: 1
|
|
645
|
-
/* STABLE */
|
|
646
|
-
})
|
|
647
|
-
]),
|
|
648
|
-
_: 1
|
|
649
|
-
/* STABLE */
|
|
650
|
-
})) : createCommentVNode("v-if", true)
|
|
651
|
-
],
|
|
652
|
-
64
|
|
653
|
-
/* STABLE_FRAGMENT */
|
|
654
|
-
)) : items.value && display$1.value ? (openBlock(), createElementBlock(
|
|
655
|
-
Fragment,
|
|
656
|
-
{ key: 4 },
|
|
657
|
-
[
|
|
658
|
-
(isValidName() ? _ctx.model[name.value] : _ctx.model) ? (openBlock(true), createElementBlock(
|
|
659
|
-
Fragment,
|
|
660
|
-
{ key: 0 },
|
|
661
|
-
renderList(items.value, (item) => {
|
|
662
|
-
return openBlock(), createBlock(_component_Container, {
|
|
663
|
-
key: key(item),
|
|
664
|
-
model: isValidName() ? _ctx.model[name.value] : _ctx.model,
|
|
665
|
-
"last-values": isValidName() ? _ctx.lastValues[name.value] || {} : _ctx.lastValues,
|
|
666
|
-
"is-compare": _ctx.isCompare,
|
|
667
|
-
config: item,
|
|
668
|
-
size: _ctx.size,
|
|
669
|
-
disabled: disabled.value,
|
|
670
|
-
"step-active": _ctx.stepActive,
|
|
671
|
-
"expand-more": expand.value,
|
|
672
|
-
"label-width": itemLabelWidth.value,
|
|
673
|
-
prop: itemProp.value,
|
|
674
|
-
onChange: onChangeHandler,
|
|
675
|
-
onAddDiffCount
|
|
676
|
-
}, null, 8, ["model", "last-values", "is-compare", "config", "size", "disabled", "step-active", "expand-more", "label-width", "prop"]);
|
|
677
|
-
}),
|
|
678
|
-
128
|
|
679
|
-
/* KEYED_FRAGMENT */
|
|
680
|
-
)) : createCommentVNode("v-if", true)
|
|
681
|
-
],
|
|
682
|
-
64
|
|
683
|
-
/* STABLE_FRAGMENT */
|
|
684
|
-
)) : createCommentVNode("v-if", true),
|
|
641
|
+
onChange: onChangeHandler,
|
|
642
|
+
onAddDiffCount
|
|
643
|
+
}, null, 8, ["model", "last-values", "is-compare", "config", "size", "disabled", "step-active", "expand-more", "label-width", "prop"]);
|
|
644
|
+
}), 128)) : createCommentVNode("", true)
|
|
645
|
+
], 64)) : createCommentVNode("", true),
|
|
685
646
|
_ctx.config.expand && type.value !== "fieldset" ? (openBlock(), createElementBlock("div", _hoisted_14, [
|
|
686
647
|
createVNode(unref(TMagicButton), {
|
|
687
648
|
type: "primary",
|
|
@@ -691,17 +652,12 @@ const _sfc_main$x = /* @__PURE__ */ defineComponent({
|
|
|
691
652
|
onClick: expandHandler
|
|
692
653
|
}, {
|
|
693
654
|
default: withCtx(() => [
|
|
694
|
-
createTextVNode(
|
|
695
|
-
toDisplayString(expand.value ? "收起配置" : "展开更多配置"),
|
|
696
|
-
1
|
|
697
|
-
/* TEXT */
|
|
698
|
-
)
|
|
655
|
+
createTextVNode(toDisplayString(expand.value ? "收起配置" : "展开更多配置"), 1)
|
|
699
656
|
]),
|
|
700
657
|
_: 1
|
|
701
|
-
/* STABLE */
|
|
702
658
|
})
|
|
703
|
-
])) : createCommentVNode("
|
|
704
|
-
], 14, _hoisted_1$e)) : createCommentVNode("
|
|
659
|
+
])) : createCommentVNode("", true)
|
|
660
|
+
], 14, _hoisted_1$e)) : createCommentVNode("", true);
|
|
705
661
|
};
|
|
706
662
|
}
|
|
707
663
|
});
|
|
@@ -758,85 +714,50 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
|
758
714
|
const key = (item, index) => item[mForm?.keyProp || "__key"] ?? index;
|
|
759
715
|
const onAddDiffCount = () => emit("addDiffCount");
|
|
760
716
|
return (_ctx, _cache) => {
|
|
761
|
-
return (name.value ? _ctx.model[name.value] : _ctx.model) ? (openBlock(), createElementBlock(
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
"
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
}, null, 8, _hoisted_5$2)) : createCommentVNode("v-if", true)
|
|
806
|
-
])),
|
|
807
|
-
_ctx.config.schematic && show.value ? (openBlock(), createElementBlock("div", _hoisted_6$1, [
|
|
808
|
-
createElementVNode("div", _hoisted_7, [
|
|
809
|
-
(openBlock(true), createElementBlock(
|
|
810
|
-
Fragment,
|
|
811
|
-
null,
|
|
812
|
-
renderList(_ctx.config.items, (item, index) => {
|
|
813
|
-
return openBlock(), createBlock(_sfc_main$x, {
|
|
814
|
-
key: key(item, index),
|
|
815
|
-
model: name.value ? _ctx.model[name.value] : _ctx.model,
|
|
816
|
-
lastValues: name.value ? _ctx.lastValues[name.value] : _ctx.lastValues,
|
|
817
|
-
"is-compare": _ctx.isCompare,
|
|
818
|
-
rules: name.value ? _ctx.rules[name.value] : [],
|
|
819
|
-
config: item,
|
|
820
|
-
prop: _ctx.prop,
|
|
821
|
-
disabled: _ctx.disabled,
|
|
822
|
-
labelWidth: lWidth.value,
|
|
823
|
-
size: _ctx.size,
|
|
824
|
-
onChange: changeHandler,
|
|
825
|
-
onAddDiffCount: _cache[1] || (_cache[1] = ($event) => onAddDiffCount())
|
|
826
|
-
}, null, 8, ["model", "lastValues", "is-compare", "rules", "config", "prop", "disabled", "labelWidth", "size"]);
|
|
827
|
-
}),
|
|
828
|
-
128
|
|
829
|
-
/* KEYED_FRAGMENT */
|
|
830
|
-
))
|
|
831
|
-
]),
|
|
832
|
-
createElementVNode("img", {
|
|
833
|
-
class: "m-form-schematic",
|
|
834
|
-
src: _ctx.config.schematic
|
|
835
|
-
}, null, 8, _hoisted_8)
|
|
836
|
-
])) : show.value ? (openBlock(true), createElementBlock(
|
|
837
|
-
Fragment,
|
|
838
|
-
{ key: 3 },
|
|
839
|
-
renderList(_ctx.config.items, (item, index) => {
|
|
717
|
+
return (name.value ? _ctx.model[name.value] : _ctx.model) ? (openBlock(), createElementBlock("fieldset", {
|
|
718
|
+
key: 0,
|
|
719
|
+
class: "m-fieldset",
|
|
720
|
+
style: normalizeStyle(show.value ? "padding: 15px" : "border: 0")
|
|
721
|
+
}, [
|
|
722
|
+
name.value && _ctx.config.checkbox ? (openBlock(), createBlock(resolveDynamicComponent(!show.value ? "div" : "legend"), { key: 0 }, {
|
|
723
|
+
default: withCtx(() => [
|
|
724
|
+
createVNode(unref(TMagicCheckbox), {
|
|
725
|
+
modelValue: _ctx.model[name.value].value,
|
|
726
|
+
"onUpdate:modelValue": [
|
|
727
|
+
_cache[0] || (_cache[0] = ($event) => _ctx.model[name.value].value = $event),
|
|
728
|
+
valueChangeHandler
|
|
729
|
+
],
|
|
730
|
+
prop: `${_ctx.prop}${_ctx.prop ? "." : ""}${_ctx.config.name}.value`,
|
|
731
|
+
"true-value": 1,
|
|
732
|
+
"false-value": 0
|
|
733
|
+
}, {
|
|
734
|
+
default: withCtx(() => [
|
|
735
|
+
createElementVNode("span", {
|
|
736
|
+
innerHTML: _ctx.config.legend
|
|
737
|
+
}, null, 8, _hoisted_1$d),
|
|
738
|
+
_ctx.config.extra ? (openBlock(), createElementBlock("span", {
|
|
739
|
+
key: 0,
|
|
740
|
+
innerHTML: _ctx.config.extra,
|
|
741
|
+
class: "m-form-tip"
|
|
742
|
+
}, null, 8, _hoisted_2$6)) : createCommentVNode("", true)
|
|
743
|
+
]),
|
|
744
|
+
_: 1
|
|
745
|
+
}, 8, ["modelValue", "prop"])
|
|
746
|
+
]),
|
|
747
|
+
_: 1
|
|
748
|
+
})) : (openBlock(), createElementBlock("legend", _hoisted_3$4, [
|
|
749
|
+
createElementVNode("span", {
|
|
750
|
+
innerHTML: _ctx.config.legend
|
|
751
|
+
}, null, 8, _hoisted_4$2),
|
|
752
|
+
_ctx.config.extra ? (openBlock(), createElementBlock("span", {
|
|
753
|
+
key: 0,
|
|
754
|
+
innerHTML: _ctx.config.extra,
|
|
755
|
+
class: "m-form-tip"
|
|
756
|
+
}, null, 8, _hoisted_5$2)) : createCommentVNode("", true)
|
|
757
|
+
])),
|
|
758
|
+
_ctx.config.schematic && show.value ? (openBlock(), createElementBlock("div", _hoisted_6$1, [
|
|
759
|
+
createElementVNode("div", _hoisted_7, [
|
|
760
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (item, index) => {
|
|
840
761
|
return openBlock(), createBlock(_sfc_main$x, {
|
|
841
762
|
key: key(item, index),
|
|
842
763
|
model: name.value ? _ctx.model[name.value] : _ctx.model,
|
|
@@ -845,20 +766,35 @@ const _sfc_main$w = /* @__PURE__ */ defineComponent({
|
|
|
845
766
|
rules: name.value ? _ctx.rules[name.value] : [],
|
|
846
767
|
config: item,
|
|
847
768
|
prop: _ctx.prop,
|
|
769
|
+
disabled: _ctx.disabled,
|
|
848
770
|
labelWidth: lWidth.value,
|
|
849
771
|
size: _ctx.size,
|
|
850
|
-
disabled: _ctx.disabled,
|
|
851
772
|
onChange: changeHandler,
|
|
852
|
-
onAddDiffCount: _cache[
|
|
853
|
-
}, null, 8, ["model", "lastValues", "is-compare", "rules", "config", "prop", "
|
|
854
|
-
}),
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
773
|
+
onAddDiffCount: _cache[1] || (_cache[1] = ($event) => onAddDiffCount())
|
|
774
|
+
}, null, 8, ["model", "lastValues", "is-compare", "rules", "config", "prop", "disabled", "labelWidth", "size"]);
|
|
775
|
+
}), 128))
|
|
776
|
+
]),
|
|
777
|
+
createElementVNode("img", {
|
|
778
|
+
class: "m-form-schematic",
|
|
779
|
+
src: _ctx.config.schematic
|
|
780
|
+
}, null, 8, _hoisted_8)
|
|
781
|
+
])) : show.value ? (openBlock(true), createElementBlock(Fragment, { key: 3 }, renderList(_ctx.config.items, (item, index) => {
|
|
782
|
+
return openBlock(), createBlock(_sfc_main$x, {
|
|
783
|
+
key: key(item, index),
|
|
784
|
+
model: name.value ? _ctx.model[name.value] : _ctx.model,
|
|
785
|
+
lastValues: name.value ? _ctx.lastValues[name.value] : _ctx.lastValues,
|
|
786
|
+
"is-compare": _ctx.isCompare,
|
|
787
|
+
rules: name.value ? _ctx.rules[name.value] : [],
|
|
788
|
+
config: item,
|
|
789
|
+
prop: _ctx.prop,
|
|
790
|
+
labelWidth: lWidth.value,
|
|
791
|
+
size: _ctx.size,
|
|
792
|
+
disabled: _ctx.disabled,
|
|
793
|
+
onChange: changeHandler,
|
|
794
|
+
onAddDiffCount: _cache[2] || (_cache[2] = ($event) => onAddDiffCount())
|
|
795
|
+
}, null, 8, ["model", "lastValues", "is-compare", "rules", "config", "prop", "labelWidth", "size", "disabled"]);
|
|
796
|
+
}), 128)) : createCommentVNode("", true)
|
|
797
|
+
], 4)) : createCommentVNode("", true);
|
|
862
798
|
};
|
|
863
799
|
}
|
|
864
800
|
});
|
|
@@ -888,7 +824,8 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
888
824
|
const props = __props;
|
|
889
825
|
const emit = __emit;
|
|
890
826
|
const mForm = inject("mForm");
|
|
891
|
-
const
|
|
827
|
+
const defaultExpandQuantity = props.config.defaultExpandQuantity ?? 7;
|
|
828
|
+
const expand = ref(props.config.expandAll || defaultExpandQuantity > props.index);
|
|
892
829
|
const rowConfig = computed(() => ({
|
|
893
830
|
type: "row",
|
|
894
831
|
span: props.config.span || 24,
|
|
@@ -956,16 +893,10 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
956
893
|
expand.value ? (openBlock(), createBlock(unref(CaretBottom), { key: 0 })) : (openBlock(), createBlock(unref(CaretRight), { key: 1 }))
|
|
957
894
|
]),
|
|
958
895
|
_: 1
|
|
959
|
-
/* STABLE */
|
|
960
896
|
}),
|
|
961
|
-
createTextVNode(
|
|
962
|
-
toDisplayString(title.value),
|
|
963
|
-
1
|
|
964
|
-
/* TEXT */
|
|
965
|
-
)
|
|
897
|
+
createTextVNode(toDisplayString(title.value), 1)
|
|
966
898
|
]),
|
|
967
899
|
_: 1
|
|
968
|
-
/* STABLE */
|
|
969
900
|
}, 8, ["disabled"]),
|
|
970
901
|
withDirectives(createVNode(unref(TMagicButton), {
|
|
971
902
|
type: "danger",
|
|
@@ -990,46 +921,37 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
990
921
|
createTextVNode("复制")
|
|
991
922
|
])),
|
|
992
923
|
_: 1
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
_: 1
|
|
1025
|
-
/* STABLE */
|
|
1026
|
-
}, 8, ["disabled", "icon"]), [
|
|
1027
|
-
[vShow, _ctx.index !== length.value - 1]
|
|
1028
|
-
])
|
|
1029
|
-
],
|
|
1030
|
-
64
|
|
1031
|
-
/* STABLE_FRAGMENT */
|
|
1032
|
-
)) : createCommentVNode("v-if", true),
|
|
924
|
+
}, 8, ["icon", "disabled"])) : createCommentVNode("", true),
|
|
925
|
+
movable.value ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
926
|
+
withDirectives(createVNode(unref(TMagicButton), {
|
|
927
|
+
link: "",
|
|
928
|
+
size: "small",
|
|
929
|
+
disabled: _ctx.disabled,
|
|
930
|
+
icon: unref(CaretTop),
|
|
931
|
+
onClick: _cache[0] || (_cache[0] = ($event) => changeOrder(-1))
|
|
932
|
+
}, {
|
|
933
|
+
default: withCtx(() => _cache[7] || (_cache[7] = [
|
|
934
|
+
createTextVNode("上移")
|
|
935
|
+
])),
|
|
936
|
+
_: 1
|
|
937
|
+
}, 8, ["disabled", "icon"]), [
|
|
938
|
+
[vShow, _ctx.index !== 0]
|
|
939
|
+
]),
|
|
940
|
+
withDirectives(createVNode(unref(TMagicButton), {
|
|
941
|
+
link: "",
|
|
942
|
+
size: "small",
|
|
943
|
+
disabled: _ctx.disabled,
|
|
944
|
+
icon: unref(CaretBottom),
|
|
945
|
+
onClick: _cache[1] || (_cache[1] = ($event) => changeOrder(1))
|
|
946
|
+
}, {
|
|
947
|
+
default: withCtx(() => _cache[8] || (_cache[8] = [
|
|
948
|
+
createTextVNode("下移")
|
|
949
|
+
])),
|
|
950
|
+
_: 1
|
|
951
|
+
}, 8, ["disabled", "icon"]), [
|
|
952
|
+
[vShow, _ctx.index !== length.value - 1]
|
|
953
|
+
])
|
|
954
|
+
], 64)) : createCommentVNode("", true),
|
|
1033
955
|
_ctx.config.moveSpecifyLocation ? (openBlock(), createBlock(unref(TMagicPopover), {
|
|
1034
956
|
key: 2,
|
|
1035
957
|
trigger: "click",
|
|
@@ -1050,7 +972,6 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
1050
972
|
createTextVNode("移动至")
|
|
1051
973
|
])),
|
|
1052
974
|
_: 1
|
|
1053
|
-
/* STABLE */
|
|
1054
975
|
}, 8, ["icon", "disabled"])
|
|
1055
976
|
]),
|
|
1056
977
|
default: withCtx(() => [
|
|
@@ -1077,7 +998,6 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
1077
998
|
createTextVNode("取消")
|
|
1078
999
|
])),
|
|
1079
1000
|
_: 1
|
|
1080
|
-
/* STABLE */
|
|
1081
1001
|
}),
|
|
1082
1002
|
createVNode(unref(TMagicButton), {
|
|
1083
1003
|
size: "small",
|
|
@@ -1088,19 +1008,17 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
1088
1008
|
createTextVNode("确认")
|
|
1089
1009
|
])),
|
|
1090
1010
|
_: 1
|
|
1091
|
-
/* STABLE */
|
|
1092
1011
|
})
|
|
1093
1012
|
])
|
|
1094
1013
|
])
|
|
1095
1014
|
]),
|
|
1096
1015
|
_: 1
|
|
1097
|
-
|
|
1098
|
-
}, 8, ["visible"])) : createCommentVNode("v-if", true),
|
|
1016
|
+
}, 8, ["visible"])) : createCommentVNode("", true),
|
|
1099
1017
|
itemExtra.value ? (openBlock(), createElementBlock("span", {
|
|
1100
1018
|
key: 3,
|
|
1101
1019
|
innerHTML: itemExtra.value,
|
|
1102
1020
|
class: "m-form-tip"
|
|
1103
|
-
}, null, 8, _hoisted_3$3)) : createCommentVNode("
|
|
1021
|
+
}, null, 8, _hoisted_3$3)) : createCommentVNode("", true)
|
|
1104
1022
|
]),
|
|
1105
1023
|
expand.value ? (openBlock(), createBlock(_sfc_main$x, {
|
|
1106
1024
|
key: 0,
|
|
@@ -1114,7 +1032,7 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
|
|
|
1114
1032
|
disabled: _ctx.disabled,
|
|
1115
1033
|
onChange: changeHandler,
|
|
1116
1034
|
onAddDiffCount: _cache[5] || (_cache[5] = ($event) => onAddDiffCount())
|
|
1117
|
-
}, null, 8, ["config", "model", "lastValues", "is-compare", "labelWidth", "prop", "size", "disabled"])) : createCommentVNode("
|
|
1035
|
+
}, null, 8, ["config", "model", "lastValues", "is-compare", "labelWidth", "prop", "size", "disabled"])) : createCommentVNode("", true)
|
|
1118
1036
|
]);
|
|
1119
1037
|
};
|
|
1120
1038
|
}
|
|
@@ -1221,41 +1139,29 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
1221
1139
|
key: 0,
|
|
1222
1140
|
innerHTML: _ctx.config.extra,
|
|
1223
1141
|
style: { "color": "rgba(0, 0, 0, 0.45)" }
|
|
1224
|
-
}, null, 8, _hoisted_2$4)) : createCommentVNode("
|
|
1142
|
+
}, null, 8, _hoisted_2$4)) : createCommentVNode("", true),
|
|
1225
1143
|
!_ctx.model[_ctx.name] || !_ctx.model[_ctx.name].length ? (openBlock(), createElementBlock("div", _hoisted_3$2, _cache[1] || (_cache[1] = [
|
|
1226
|
-
createElementVNode(
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
disabled: _ctx.disabled,
|
|
1248
|
-
"group-model": _ctx.model[_ctx.name],
|
|
1249
|
-
onRemoveItem: removeHandler,
|
|
1250
|
-
onCopyItem: copyHandler,
|
|
1251
|
-
onSwapItem: swapHandler,
|
|
1252
|
-
onChange: changeHandler,
|
|
1253
|
-
onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
|
|
1254
|
-
}, null, 8, ["model", "lastValues", "is-compare", "config", "prop", "index", "label-width", "size", "disabled", "group-model"]);
|
|
1255
|
-
}),
|
|
1256
|
-
128
|
|
1257
|
-
/* KEYED_FRAGMENT */
|
|
1258
|
-
)),
|
|
1144
|
+
createElementVNode("span", { class: "el-table__empty-text" }, "暂无数据", -1)
|
|
1145
|
+
]))) : (openBlock(true), createElementBlock(Fragment, { key: 2 }, renderList(_ctx.model[_ctx.name], (item, index) => {
|
|
1146
|
+
return openBlock(), createBlock(_sfc_main$v, {
|
|
1147
|
+
key: index,
|
|
1148
|
+
model: item,
|
|
1149
|
+
lastValues: getLastValues(_ctx.lastValues[_ctx.name], index),
|
|
1150
|
+
"is-compare": _ctx.isCompare,
|
|
1151
|
+
config: _ctx.config,
|
|
1152
|
+
prop: _ctx.prop,
|
|
1153
|
+
index,
|
|
1154
|
+
"label-width": _ctx.labelWidth,
|
|
1155
|
+
size: _ctx.size,
|
|
1156
|
+
disabled: _ctx.disabled,
|
|
1157
|
+
"group-model": _ctx.model[_ctx.name],
|
|
1158
|
+
onRemoveItem: removeHandler,
|
|
1159
|
+
onCopyItem: copyHandler,
|
|
1160
|
+
onSwapItem: swapHandler,
|
|
1161
|
+
onChange: changeHandler,
|
|
1162
|
+
onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
|
|
1163
|
+
}, null, 8, ["model", "lastValues", "is-compare", "config", "prop", "index", "label-width", "size", "disabled", "group-model"]);
|
|
1164
|
+
}), 128)),
|
|
1259
1165
|
addable.value ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
1260
1166
|
key: 3,
|
|
1261
1167
|
type: "primary",
|
|
@@ -1267,8 +1173,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
1267
1173
|
createTextVNode("新增")
|
|
1268
1174
|
])),
|
|
1269
1175
|
_: 1
|
|
1270
|
-
|
|
1271
|
-
}, 8, ["size", "disabled"])) : createCommentVNode("v-if", true),
|
|
1176
|
+
}, 8, ["size", "disabled"])) : createCommentVNode("", true),
|
|
1272
1177
|
_ctx.config.enableToggleMode ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
1273
1178
|
key: 4,
|
|
1274
1179
|
icon: unref(Grid),
|
|
@@ -1279,8 +1184,7 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
|
|
|
1279
1184
|
createTextVNode("切换为表格")
|
|
1280
1185
|
])),
|
|
1281
1186
|
_: 1
|
|
1282
|
-
|
|
1283
|
-
}, 8, ["icon"])) : createCommentVNode("v-if", true)
|
|
1187
|
+
}, 8, ["icon"])) : createCommentVNode("", true)
|
|
1284
1188
|
]);
|
|
1285
1189
|
};
|
|
1286
1190
|
}
|
|
@@ -1340,13 +1244,9 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
1340
1244
|
key: 0,
|
|
1341
1245
|
innerHTML: _ctx.config.extra,
|
|
1342
1246
|
class: "m-form-tip"
|
|
1343
|
-
}, null, 8, _hoisted_2$3)) : createCommentVNode("
|
|
1247
|
+
}, null, 8, _hoisted_2$3)) : createCommentVNode("", true),
|
|
1344
1248
|
renderSlot(_ctx.$slots, "header", {}, () => [
|
|
1345
|
-
createTextVNode(
|
|
1346
|
-
toDisplayString(filter(_ctx.config.title)),
|
|
1347
|
-
1
|
|
1348
|
-
/* TEXT */
|
|
1349
|
-
)
|
|
1249
|
+
createTextVNode(toDisplayString(filter(_ctx.config.title)), 1)
|
|
1350
1250
|
])
|
|
1351
1251
|
])
|
|
1352
1252
|
]),
|
|
@@ -1355,58 +1255,45 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
|
|
|
1355
1255
|
renderSlot(_ctx.$slots, "default"),
|
|
1356
1256
|
_ctx.config.schematic ? (openBlock(), createElementBlock("div", _hoisted_3$1, [
|
|
1357
1257
|
createElementVNode("div", _hoisted_4$1, [
|
|
1358
|
-
(openBlock(true), createElementBlock(
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
onAddDiffCount: _cache[1] || (_cache[1] = ($event) => onAddDiffCount())
|
|
1374
|
-
}, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"]);
|
|
1375
|
-
}),
|
|
1376
|
-
128
|
|
1377
|
-
/* KEYED_FRAGMENT */
|
|
1378
|
-
))
|
|
1258
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(items.value, (item, index) => {
|
|
1259
|
+
return openBlock(), createBlock(_sfc_main$x, {
|
|
1260
|
+
key: item[unref(mForm)?.keyProp || "__key"] ?? index,
|
|
1261
|
+
config: item,
|
|
1262
|
+
model: _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
|
|
1263
|
+
lastValues: _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
|
|
1264
|
+
"is-compare": _ctx.isCompare,
|
|
1265
|
+
prop: _ctx.prop,
|
|
1266
|
+
size: _ctx.size,
|
|
1267
|
+
disabled: _ctx.disabled,
|
|
1268
|
+
"label-width": _ctx.config.labelWidth || _ctx.labelWidth,
|
|
1269
|
+
onChange: changeHandler,
|
|
1270
|
+
onAddDiffCount: _cache[1] || (_cache[1] = ($event) => onAddDiffCount())
|
|
1271
|
+
}, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"]);
|
|
1272
|
+
}), 128))
|
|
1379
1273
|
]),
|
|
1380
1274
|
createElementVNode("img", {
|
|
1381
1275
|
class: "m-form-schematic",
|
|
1382
1276
|
src: _ctx.config.schematic
|
|
1383
1277
|
}, null, 8, _hoisted_5$1)
|
|
1384
|
-
])) : (openBlock(true), createElementBlock(
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
onAddDiffCount: _cache[2] || (_cache[2] = ($event) => onAddDiffCount())
|
|
1400
|
-
}, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"]);
|
|
1401
|
-
}),
|
|
1402
|
-
128
|
|
1403
|
-
/* KEYED_FRAGMENT */
|
|
1404
|
-
))
|
|
1278
|
+
])) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(items.value, (item, index) => {
|
|
1279
|
+
return openBlock(), createBlock(_sfc_main$x, {
|
|
1280
|
+
key: item[unref(mForm)?.keyProp || "__key"] ?? index,
|
|
1281
|
+
config: item,
|
|
1282
|
+
model: _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
|
|
1283
|
+
lastValues: _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
|
|
1284
|
+
"is-compare": _ctx.isCompare,
|
|
1285
|
+
prop: _ctx.prop,
|
|
1286
|
+
size: _ctx.size,
|
|
1287
|
+
disabled: _ctx.disabled,
|
|
1288
|
+
"label-width": _ctx.config.labelWidth || _ctx.labelWidth,
|
|
1289
|
+
onChange: changeHandler,
|
|
1290
|
+
onAddDiffCount: _cache[2] || (_cache[2] = ($event) => onAddDiffCount())
|
|
1291
|
+
}, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"]);
|
|
1292
|
+
}), 128))
|
|
1405
1293
|
])
|
|
1406
1294
|
]),
|
|
1407
1295
|
_: 3
|
|
1408
|
-
|
|
1409
|
-
}, 8, ["body-style"])) : createCommentVNode("v-if", true);
|
|
1296
|
+
}, 8, ["body-style"])) : createCommentVNode("", true);
|
|
1410
1297
|
};
|
|
1411
1298
|
}
|
|
1412
1299
|
});
|
|
@@ -1454,7 +1341,6 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
1454
1341
|
}, null, 8, ["model", "lastValues", "is-compare", "config", "prop", "label-width", "expand-more", "size", "disabled"])
|
|
1455
1342
|
]),
|
|
1456
1343
|
_: 1
|
|
1457
|
-
/* STABLE */
|
|
1458
1344
|
}, 8, ["span"])), [
|
|
1459
1345
|
[vShow, display$1.value && _ctx.config.type !== "hidden"]
|
|
1460
1346
|
]);
|
|
@@ -1491,32 +1377,25 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
|
|
|
1491
1377
|
return (_ctx, _cache) => {
|
|
1492
1378
|
return openBlock(), createBlock(unref(TMagicRow), { gutter: 10 }, {
|
|
1493
1379
|
default: withCtx(() => [
|
|
1494
|
-
(openBlock(true), createElementBlock(
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
onAddDiffCount
|
|
1512
|
-
}, null, 8, ["span", "config", "labelWidth", "expandMore", "model", "lastValues", "is-compare", "prop", "size", "disabled"]);
|
|
1513
|
-
}),
|
|
1514
|
-
128
|
|
1515
|
-
/* KEYED_FRAGMENT */
|
|
1516
|
-
))
|
|
1380
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (col, index) => {
|
|
1381
|
+
return openBlock(), createBlock(_sfc_main$s, {
|
|
1382
|
+
key: col[unref(mForm)?.keyProp || "__key"] ?? index,
|
|
1383
|
+
span: col.span || _ctx.config.span || 24 / _ctx.config.items.length,
|
|
1384
|
+
config: col,
|
|
1385
|
+
labelWidth: _ctx.config.labelWidth || _ctx.labelWidth,
|
|
1386
|
+
expandMore: _ctx.expandMore,
|
|
1387
|
+
model: _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
|
|
1388
|
+
lastValues: _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
|
|
1389
|
+
"is-compare": _ctx.isCompare,
|
|
1390
|
+
prop: _ctx.prop,
|
|
1391
|
+
size: _ctx.size,
|
|
1392
|
+
disabled: _ctx.disabled,
|
|
1393
|
+
onChange: changeHandler,
|
|
1394
|
+
onAddDiffCount
|
|
1395
|
+
}, null, 8, ["span", "config", "labelWidth", "expandMore", "model", "lastValues", "is-compare", "prop", "size", "disabled"]);
|
|
1396
|
+
}), 128))
|
|
1517
1397
|
]),
|
|
1518
1398
|
_: 1
|
|
1519
|
-
/* STABLE */
|
|
1520
1399
|
});
|
|
1521
1400
|
};
|
|
1522
1401
|
}
|
|
@@ -1563,71 +1442,40 @@ const _sfc_main$q = /* @__PURE__ */ defineComponent({
|
|
|
1563
1442
|
space: _ctx.config.space
|
|
1564
1443
|
}, {
|
|
1565
1444
|
default: withCtx(() => [
|
|
1566
|
-
(openBlock(true), createElementBlock(
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
onClick: ($event) => stepClick(index)
|
|
1575
|
-
}, null, 8, ["title", "active", "onClick"]);
|
|
1576
|
-
}),
|
|
1577
|
-
128
|
|
1578
|
-
/* KEYED_FRAGMENT */
|
|
1579
|
-
))
|
|
1445
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (item, index) => {
|
|
1446
|
+
return openBlock(), createBlock(unref(TMagicStep), {
|
|
1447
|
+
key: item.__key,
|
|
1448
|
+
title: item.title,
|
|
1449
|
+
active: active.value,
|
|
1450
|
+
onClick: ($event) => stepClick(index)
|
|
1451
|
+
}, null, 8, ["title", "active", "onClick"]);
|
|
1452
|
+
}), 128))
|
|
1580
1453
|
]),
|
|
1581
1454
|
_: 1
|
|
1582
|
-
/* STABLE */
|
|
1583
1455
|
}, 8, ["active", "space"]),
|
|
1584
|
-
(openBlock(true), createElementBlock(
|
|
1585
|
-
Fragment,
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
size: _ctx.size,
|
|
1608
|
-
disabled: _ctx.disabled,
|
|
1609
|
-
"label-width": _ctx.config.labelWidth || _ctx.labelWidth,
|
|
1610
|
-
onChange: changeHandler,
|
|
1611
|
-
onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
|
|
1612
|
-
}, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"])), [
|
|
1613
|
-
[vShow, active.value - 1 === index]
|
|
1614
|
-
]) : createCommentVNode("v-if", true)
|
|
1615
|
-
],
|
|
1616
|
-
64
|
|
1617
|
-
/* STABLE_FRAGMENT */
|
|
1618
|
-
);
|
|
1619
|
-
}),
|
|
1620
|
-
256
|
|
1621
|
-
/* UNKEYED_FRAGMENT */
|
|
1622
|
-
))
|
|
1623
|
-
],
|
|
1624
|
-
64
|
|
1625
|
-
/* STABLE_FRAGMENT */
|
|
1626
|
-
);
|
|
1627
|
-
}),
|
|
1628
|
-
256
|
|
1629
|
-
/* UNKEYED_FRAGMENT */
|
|
1630
|
-
))
|
|
1456
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (step, index) => {
|
|
1457
|
+
return openBlock(), createElementBlock(Fragment, null, [
|
|
1458
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(step.items, (item) => {
|
|
1459
|
+
return openBlock(), createElementBlock(Fragment, null, [
|
|
1460
|
+
item ? withDirectives((openBlock(), createBlock(_sfc_main$x, {
|
|
1461
|
+
key: item[unref(mForm)?.keyProp || "__key"],
|
|
1462
|
+
config: item,
|
|
1463
|
+
model: step.name ? _ctx.model[step.name] : _ctx.model,
|
|
1464
|
+
lastValues: step.name ? _ctx.lastValues[step.name] : _ctx.lastValues,
|
|
1465
|
+
"is-compare": _ctx.isCompare,
|
|
1466
|
+
prop: `${step.name}`,
|
|
1467
|
+
size: _ctx.size,
|
|
1468
|
+
disabled: _ctx.disabled,
|
|
1469
|
+
"label-width": _ctx.config.labelWidth || _ctx.labelWidth,
|
|
1470
|
+
onChange: changeHandler,
|
|
1471
|
+
onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
|
|
1472
|
+
}, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"])), [
|
|
1473
|
+
[vShow, active.value - 1 === index]
|
|
1474
|
+
]) : createCommentVNode("", true)
|
|
1475
|
+
], 64);
|
|
1476
|
+
}), 256))
|
|
1477
|
+
], 64);
|
|
1478
|
+
}), 256))
|
|
1631
1479
|
]);
|
|
1632
1480
|
};
|
|
1633
1481
|
}
|
|
@@ -2024,329 +1872,276 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
|
|
|
2024
1872
|
to: "body",
|
|
2025
1873
|
disabled: !isFullscreen.value
|
|
2026
1874
|
}, [
|
|
2027
|
-
createElementVNode(
|
|
2028
|
-
"
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
_ctx.config.extra
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
|
|
2061
|
-
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
1875
|
+
createElementVNode("div", {
|
|
1876
|
+
ref_key: "mTable",
|
|
1877
|
+
ref: mTable,
|
|
1878
|
+
class: normalizeClass(["m-fields-table", { "m-fields-table-item-extra": _ctx.config.itemExtra }])
|
|
1879
|
+
}, [
|
|
1880
|
+
_ctx.config.extra ? (openBlock(), createElementBlock("span", {
|
|
1881
|
+
key: 0,
|
|
1882
|
+
style: { "color": "rgba(0, 0, 0, 0.45)" },
|
|
1883
|
+
innerHTML: _ctx.config.extra
|
|
1884
|
+
}, null, 8, _hoisted_2$2)) : createCommentVNode("", true),
|
|
1885
|
+
createVNode(unref(TMagicTooltip), {
|
|
1886
|
+
content: "拖拽可排序",
|
|
1887
|
+
placement: "left-start",
|
|
1888
|
+
disabled: _ctx.config.dropSort !== true
|
|
1889
|
+
}, {
|
|
1890
|
+
default: withCtx(() => [
|
|
1891
|
+
_ctx.model[modelName.value] ? (openBlock(), createBlock(unref(TMagicTable), {
|
|
1892
|
+
ref_key: "tMagicTable",
|
|
1893
|
+
ref: tMagicTable,
|
|
1894
|
+
style: { "width": "100%" },
|
|
1895
|
+
"row-key": _ctx.config.rowKey || "id",
|
|
1896
|
+
data: data.value,
|
|
1897
|
+
lastData: lastData.value,
|
|
1898
|
+
border: _ctx.config.border,
|
|
1899
|
+
"max-height": _ctx.config.maxHeight,
|
|
1900
|
+
"default-expand-all": true,
|
|
1901
|
+
key: updateKey.value,
|
|
1902
|
+
onSelect: selectHandle,
|
|
1903
|
+
onSortChange: sortChange
|
|
1904
|
+
}, {
|
|
1905
|
+
default: withCtx(() => [
|
|
1906
|
+
_ctx.config.itemExtra && !_ctx.config.dropSort ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
1907
|
+
key: 0,
|
|
1908
|
+
fixed: "left",
|
|
1909
|
+
width: "30",
|
|
1910
|
+
type: "expand"
|
|
1911
|
+
}, {
|
|
1912
|
+
default: withCtx((scope) => [
|
|
1913
|
+
createElementVNode("span", {
|
|
1914
|
+
innerHTML: itemExtra(_ctx.config.itemExtra, scope.$index),
|
|
1915
|
+
class: "m-form-tip"
|
|
1916
|
+
}, null, 8, _hoisted_3)
|
|
1917
|
+
]),
|
|
1918
|
+
_: 1
|
|
1919
|
+
})) : createCommentVNode("", true),
|
|
1920
|
+
createVNode(unref(TMagicTableColumn), {
|
|
1921
|
+
label: "操作",
|
|
1922
|
+
width: _ctx.config.operateColWidth || 100,
|
|
1923
|
+
align: "center",
|
|
1924
|
+
fixed: _ctx.config.fixed === false ? void 0 : "left"
|
|
1925
|
+
}, {
|
|
1926
|
+
default: withCtx((scope) => [
|
|
1927
|
+
renderSlot(_ctx.$slots, "operateCol", { scope }),
|
|
1928
|
+
withDirectives(createVNode(unref(TMagicButton), {
|
|
1929
|
+
size: "small",
|
|
1930
|
+
type: "danger",
|
|
1931
|
+
link: "",
|
|
1932
|
+
title: "删除",
|
|
1933
|
+
icon: unref(Delete),
|
|
1934
|
+
onClick: ($event) => removeHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1)
|
|
1935
|
+
}, null, 8, ["icon", "onClick"]), [
|
|
1936
|
+
[vShow, showDelete(scope.$index + 1 + pagecontext.value * pagesize.value - 1)]
|
|
2072
1937
|
]),
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
1938
|
+
copyable(scope.$index + 1 + pagecontext.value * pagesize.value - 1) ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
1939
|
+
key: 0,
|
|
1940
|
+
link: "",
|
|
1941
|
+
size: "small",
|
|
1942
|
+
type: "primary",
|
|
1943
|
+
title: "复制",
|
|
1944
|
+
icon: unref(DocumentCopy),
|
|
1945
|
+
disabled: _ctx.disabled,
|
|
1946
|
+
onClick: ($event) => copyHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1)
|
|
1947
|
+
}, null, 8, ["icon", "disabled", "onClick"])) : createCommentVNode("", true)
|
|
1948
|
+
]),
|
|
1949
|
+
_: 3
|
|
1950
|
+
}, 8, ["width", "fixed"]),
|
|
1951
|
+
_ctx.sort && _ctx.model[modelName.value] && _ctx.model[modelName.value].length > 1 ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
1952
|
+
key: 1,
|
|
1953
|
+
label: "排序",
|
|
1954
|
+
width: "60"
|
|
1955
|
+
}, {
|
|
1956
|
+
default: withCtx((scope) => [
|
|
1957
|
+
scope.$index + 1 + pagecontext.value * pagesize.value - 1 !== 0 ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
1958
|
+
key: 0,
|
|
1959
|
+
content: "点击上移,双击置顶",
|
|
1960
|
+
placement: "top"
|
|
1961
|
+
}, {
|
|
1962
|
+
default: withCtx(() => [
|
|
1963
|
+
createVNode(unref(TMagicButton), {
|
|
1964
|
+
plain: "",
|
|
1965
|
+
size: "small",
|
|
1966
|
+
type: "primary",
|
|
1967
|
+
icon: unref(ArrowUp),
|
|
1968
|
+
disabled: _ctx.disabled,
|
|
1969
|
+
link: "",
|
|
1970
|
+
onClick: ($event) => upHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1),
|
|
1971
|
+
onDblclick: ($event) => topHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1)
|
|
1972
|
+
}, null, 8, ["icon", "disabled", "onClick", "onDblclick"])
|
|
2093
1973
|
]),
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
1974
|
+
_: 2
|
|
1975
|
+
}, 1024)) : createCommentVNode("", true),
|
|
1976
|
+
scope.$index + 1 + pagecontext.value * pagesize.value - 1 !== _ctx.model[modelName.value].length - 1 ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
1977
|
+
key: 1,
|
|
1978
|
+
content: "点击下移,双击置底",
|
|
1979
|
+
placement: "top"
|
|
1980
|
+
}, {
|
|
1981
|
+
default: withCtx(() => [
|
|
1982
|
+
createVNode(unref(TMagicButton), {
|
|
1983
|
+
plain: "",
|
|
1984
|
+
size: "small",
|
|
1985
|
+
type: "primary",
|
|
1986
|
+
icon: unref(ArrowDown),
|
|
1987
|
+
disabled: _ctx.disabled,
|
|
1988
|
+
link: "",
|
|
1989
|
+
onClick: ($event) => downHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1),
|
|
1990
|
+
onDblclick: ($event) => bottomHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1)
|
|
1991
|
+
}, null, 8, ["icon", "disabled", "onClick", "onDblclick"])
|
|
1992
|
+
]),
|
|
1993
|
+
_: 2
|
|
1994
|
+
}, 1024)) : createCommentVNode("", true)
|
|
1995
|
+
]),
|
|
1996
|
+
_: 1
|
|
1997
|
+
})) : createCommentVNode("", true),
|
|
1998
|
+
selection.value ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
1999
|
+
key: 2,
|
|
2000
|
+
align: "center",
|
|
2001
|
+
"header-align": "center",
|
|
2002
|
+
type: "selection",
|
|
2003
|
+
width: "45"
|
|
2004
|
+
})) : createCommentVNode("", true),
|
|
2005
|
+
_ctx.showIndex && _ctx.config.showIndex ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
2006
|
+
key: 3,
|
|
2007
|
+
width: "60",
|
|
2008
|
+
label: "序号"
|
|
2009
|
+
}, {
|
|
2010
|
+
default: withCtx((scope) => [
|
|
2011
|
+
createTextVNode(toDisplayString(scope.$index + 1 + pagecontext.value * pagesize.value), 1)
|
|
2012
|
+
]),
|
|
2013
|
+
_: 1
|
|
2014
|
+
})) : createCommentVNode("", true),
|
|
2015
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (column, index) => {
|
|
2016
|
+
return openBlock(), createElementBlock(Fragment, null, [
|
|
2017
|
+
column.type !== "hidden" && display$1(column.display) ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
2018
|
+
prop: column.name,
|
|
2019
|
+
width: column.width,
|
|
2020
|
+
label: column.label,
|
|
2021
|
+
sortable: column.sortable,
|
|
2022
|
+
"sort-orders": ["ascending", "descending"],
|
|
2023
|
+
key: column[unref(mForm)?.keyProp || "__key"] ?? index,
|
|
2024
|
+
"class-name": _ctx.config.dropSort === true ? "el-table__column--dropable" : ""
|
|
2025
|
+
}, {
|
|
2026
|
+
default: withCtx((scope) => [
|
|
2027
|
+
scope.$index > -1 ? (openBlock(), createBlock(_sfc_main$x, {
|
|
2117
2028
|
key: 0,
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
}, null, 8, ["icon", "disabled", "onClick", "onDblclick"])
|
|
2159
|
-
]),
|
|
2160
|
-
_: 2
|
|
2161
|
-
/* DYNAMIC */
|
|
2162
|
-
},
|
|
2163
|
-
1024
|
|
2164
|
-
/* DYNAMIC_SLOTS */
|
|
2165
|
-
)) : createCommentVNode("v-if", true)
|
|
2166
|
-
]),
|
|
2167
|
-
_: 1
|
|
2168
|
-
/* STABLE */
|
|
2169
|
-
})) : createCommentVNode("v-if", true),
|
|
2170
|
-
selection.value ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
2171
|
-
key: 2,
|
|
2172
|
-
align: "center",
|
|
2173
|
-
"header-align": "center",
|
|
2174
|
-
type: "selection",
|
|
2175
|
-
width: "45"
|
|
2176
|
-
})) : createCommentVNode("v-if", true),
|
|
2177
|
-
_ctx.showIndex && _ctx.config.showIndex ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
2178
|
-
key: 3,
|
|
2179
|
-
width: "60",
|
|
2180
|
-
label: "序号"
|
|
2181
|
-
}, {
|
|
2182
|
-
default: withCtx((scope) => [
|
|
2183
|
-
createTextVNode(
|
|
2184
|
-
toDisplayString(scope.$index + 1 + pagecontext.value * pagesize.value),
|
|
2185
|
-
1
|
|
2186
|
-
/* TEXT */
|
|
2187
|
-
)
|
|
2188
|
-
]),
|
|
2189
|
-
_: 1
|
|
2190
|
-
/* STABLE */
|
|
2191
|
-
})) : createCommentVNode("v-if", true),
|
|
2192
|
-
(openBlock(true), createElementBlock(
|
|
2193
|
-
Fragment,
|
|
2194
|
-
null,
|
|
2195
|
-
renderList(_ctx.config.items, (column, index) => {
|
|
2196
|
-
return openBlock(), createElementBlock(
|
|
2197
|
-
Fragment,
|
|
2198
|
-
null,
|
|
2199
|
-
[
|
|
2200
|
-
column.type !== "hidden" && display$1(column.display) ? (openBlock(), createBlock(unref(TMagicTableColumn), {
|
|
2201
|
-
prop: column.name,
|
|
2202
|
-
width: column.width,
|
|
2203
|
-
label: column.label,
|
|
2204
|
-
sortable: column.sortable,
|
|
2205
|
-
"sort-orders": ["ascending", "descending"],
|
|
2206
|
-
key: column[unref(mForm)?.keyProp || "__key"] ?? index,
|
|
2207
|
-
"class-name": _ctx.config.dropSort === true ? "el-table__column--dropable" : ""
|
|
2208
|
-
}, {
|
|
2209
|
-
default: withCtx((scope) => [
|
|
2210
|
-
scope.$index > -1 ? (openBlock(), createBlock(_sfc_main$x, {
|
|
2211
|
-
key: 0,
|
|
2212
|
-
labelWidth: "0",
|
|
2213
|
-
disabled: _ctx.disabled,
|
|
2214
|
-
prop: getProp(scope.$index),
|
|
2215
|
-
rules: column.rules,
|
|
2216
|
-
config: makeConfig(column, scope.row),
|
|
2217
|
-
model: scope.row,
|
|
2218
|
-
lastValues: lastData.value[scope.$index],
|
|
2219
|
-
"is-compare": _ctx.isCompare,
|
|
2220
|
-
size: _ctx.size,
|
|
2221
|
-
onChange: changeHandler,
|
|
2222
|
-
onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
|
|
2223
|
-
}, null, 8, ["disabled", "prop", "rules", "config", "model", "lastValues", "is-compare", "size"])) : createCommentVNode("v-if", true)
|
|
2224
|
-
]),
|
|
2225
|
-
_: 2
|
|
2226
|
-
/* DYNAMIC */
|
|
2227
|
-
}, 1032, ["prop", "width", "label", "sortable", "class-name"])) : createCommentVNode("v-if", true)
|
|
2228
|
-
],
|
|
2229
|
-
64
|
|
2230
|
-
/* STABLE_FRAGMENT */
|
|
2231
|
-
);
|
|
2232
|
-
}),
|
|
2233
|
-
256
|
|
2234
|
-
/* UNKEYED_FRAGMENT */
|
|
2235
|
-
))
|
|
2236
|
-
]),
|
|
2237
|
-
_: 3
|
|
2238
|
-
/* FORWARDED */
|
|
2239
|
-
}, 8, ["row-key", "data", "lastData", "border", "max-height"])) : createCommentVNode("v-if", true)
|
|
2240
|
-
]),
|
|
2241
|
-
_: 3
|
|
2242
|
-
/* FORWARDED */
|
|
2243
|
-
}, 8, ["disabled"]),
|
|
2244
|
-
renderSlot(_ctx.$slots, "default"),
|
|
2245
|
-
createElementVNode("div", _hoisted_4, [
|
|
2246
|
-
addable.value ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
2029
|
+
labelWidth: "0",
|
|
2030
|
+
disabled: _ctx.disabled,
|
|
2031
|
+
prop: getProp(scope.$index),
|
|
2032
|
+
rules: column.rules,
|
|
2033
|
+
config: makeConfig(column, scope.row),
|
|
2034
|
+
model: scope.row,
|
|
2035
|
+
lastValues: lastData.value[scope.$index],
|
|
2036
|
+
"is-compare": _ctx.isCompare,
|
|
2037
|
+
size: _ctx.size,
|
|
2038
|
+
onChange: changeHandler,
|
|
2039
|
+
onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
|
|
2040
|
+
}, null, 8, ["disabled", "prop", "rules", "config", "model", "lastValues", "is-compare", "size"])) : createCommentVNode("", true)
|
|
2041
|
+
]),
|
|
2042
|
+
_: 2
|
|
2043
|
+
}, 1032, ["prop", "width", "label", "sortable", "class-name"])) : createCommentVNode("", true)
|
|
2044
|
+
], 64);
|
|
2045
|
+
}), 256))
|
|
2046
|
+
]),
|
|
2047
|
+
_: 3
|
|
2048
|
+
}, 8, ["row-key", "data", "lastData", "border", "max-height"])) : createCommentVNode("", true)
|
|
2049
|
+
]),
|
|
2050
|
+
_: 3
|
|
2051
|
+
}, 8, ["disabled"]),
|
|
2052
|
+
renderSlot(_ctx.$slots, "default"),
|
|
2053
|
+
createElementVNode("div", _hoisted_4, [
|
|
2054
|
+
addable.value ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
2055
|
+
key: 0,
|
|
2056
|
+
size: "small",
|
|
2057
|
+
type: "primary",
|
|
2058
|
+
disabled: _ctx.disabled,
|
|
2059
|
+
plain: "",
|
|
2060
|
+
onClick: _cache[1] || (_cache[1] = ($event) => newHandler())
|
|
2061
|
+
}, {
|
|
2062
|
+
default: withCtx(() => _cache[3] || (_cache[3] = [
|
|
2063
|
+
createTextVNode("新增一行")
|
|
2064
|
+
])),
|
|
2065
|
+
_: 1
|
|
2066
|
+
}, 8, ["disabled"])) : createCommentVNode("", true),
|
|
2067
|
+
createElementVNode("div", _hoisted_5, [
|
|
2068
|
+
_ctx.enableToggleMode && _ctx.config.enableToggleMode !== false && !isFullscreen.value ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
2247
2069
|
key: 0,
|
|
2070
|
+
icon: unref(Grid),
|
|
2071
|
+
size: "small",
|
|
2072
|
+
type: "primary",
|
|
2073
|
+
onClick: toggleMode
|
|
2074
|
+
}, {
|
|
2075
|
+
default: withCtx(() => _cache[4] || (_cache[4] = [
|
|
2076
|
+
createTextVNode("展开配置")
|
|
2077
|
+
])),
|
|
2078
|
+
_: 1
|
|
2079
|
+
}, 8, ["icon"])) : createCommentVNode("", true),
|
|
2080
|
+
_ctx.config.enableFullscreen !== false ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
2081
|
+
key: 1,
|
|
2082
|
+
icon: unref(FullScreen),
|
|
2083
|
+
size: "small",
|
|
2084
|
+
type: "primary",
|
|
2085
|
+
onClick: toggleFullscreen
|
|
2086
|
+
}, {
|
|
2087
|
+
default: withCtx(() => [
|
|
2088
|
+
createTextVNode(toDisplayString(isFullscreen.value ? "退出全屏" : "全屏编辑"), 1)
|
|
2089
|
+
]),
|
|
2090
|
+
_: 1
|
|
2091
|
+
}, 8, ["icon"])) : createCommentVNode("", true),
|
|
2092
|
+
importable.value ? (openBlock(), createBlock(unref(TMagicUpload), {
|
|
2093
|
+
key: 2,
|
|
2094
|
+
style: { "display": "inline-block" },
|
|
2095
|
+
ref_key: "excelBtn",
|
|
2096
|
+
ref: excelBtn,
|
|
2097
|
+
action: "/noop",
|
|
2098
|
+
disabled: _ctx.disabled,
|
|
2099
|
+
"on-change": excelHandler,
|
|
2100
|
+
"auto-upload": false
|
|
2101
|
+
}, {
|
|
2102
|
+
default: withCtx(() => [
|
|
2103
|
+
createVNode(unref(TMagicButton), {
|
|
2104
|
+
size: "small",
|
|
2105
|
+
type: "success",
|
|
2106
|
+
disabled: _ctx.disabled,
|
|
2107
|
+
plain: ""
|
|
2108
|
+
}, {
|
|
2109
|
+
default: withCtx(() => _cache[5] || (_cache[5] = [
|
|
2110
|
+
createTextVNode("导入EXCEL")
|
|
2111
|
+
])),
|
|
2112
|
+
_: 1
|
|
2113
|
+
}, 8, ["disabled"])
|
|
2114
|
+
]),
|
|
2115
|
+
_: 1
|
|
2116
|
+
}, 8, ["disabled"])) : createCommentVNode("", true),
|
|
2117
|
+
importable.value ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
2118
|
+
key: 3,
|
|
2248
2119
|
size: "small",
|
|
2249
|
-
type: "
|
|
2120
|
+
type: "warning",
|
|
2250
2121
|
disabled: _ctx.disabled,
|
|
2251
2122
|
plain: "",
|
|
2252
|
-
onClick: _cache[
|
|
2123
|
+
onClick: _cache[2] || (_cache[2] = ($event) => clearHandler())
|
|
2253
2124
|
}, {
|
|
2254
|
-
default: withCtx(() => _cache[
|
|
2255
|
-
createTextVNode("
|
|
2125
|
+
default: withCtx(() => _cache[6] || (_cache[6] = [
|
|
2126
|
+
createTextVNode("清空")
|
|
2256
2127
|
])),
|
|
2257
2128
|
_: 1
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
_ctx.config.enableFullscreen !== false ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
2275
|
-
key: 1,
|
|
2276
|
-
icon: unref(FullScreen),
|
|
2277
|
-
size: "small",
|
|
2278
|
-
type: "primary",
|
|
2279
|
-
onClick: toggleFullscreen
|
|
2280
|
-
}, {
|
|
2281
|
-
default: withCtx(() => [
|
|
2282
|
-
createTextVNode(
|
|
2283
|
-
toDisplayString(isFullscreen.value ? "退出全屏" : "全屏编辑"),
|
|
2284
|
-
1
|
|
2285
|
-
/* TEXT */
|
|
2286
|
-
)
|
|
2287
|
-
]),
|
|
2288
|
-
_: 1
|
|
2289
|
-
/* STABLE */
|
|
2290
|
-
}, 8, ["icon"])) : createCommentVNode("v-if", true),
|
|
2291
|
-
importable.value ? (openBlock(), createBlock(unref(TMagicUpload), {
|
|
2292
|
-
key: 2,
|
|
2293
|
-
style: { "display": "inline-block" },
|
|
2294
|
-
ref_key: "excelBtn",
|
|
2295
|
-
ref: excelBtn,
|
|
2296
|
-
action: "/noop",
|
|
2297
|
-
disabled: _ctx.disabled,
|
|
2298
|
-
"on-change": excelHandler,
|
|
2299
|
-
"auto-upload": false
|
|
2300
|
-
}, {
|
|
2301
|
-
default: withCtx(() => [
|
|
2302
|
-
createVNode(unref(TMagicButton), {
|
|
2303
|
-
size: "small",
|
|
2304
|
-
type: "success",
|
|
2305
|
-
disabled: _ctx.disabled,
|
|
2306
|
-
plain: ""
|
|
2307
|
-
}, {
|
|
2308
|
-
default: withCtx(() => _cache[5] || (_cache[5] = [
|
|
2309
|
-
createTextVNode("导入EXCEL")
|
|
2310
|
-
])),
|
|
2311
|
-
_: 1
|
|
2312
|
-
/* STABLE */
|
|
2313
|
-
}, 8, ["disabled"])
|
|
2314
|
-
]),
|
|
2315
|
-
_: 1
|
|
2316
|
-
/* STABLE */
|
|
2317
|
-
}, 8, ["disabled"])) : createCommentVNode("v-if", true),
|
|
2318
|
-
importable.value ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
2319
|
-
key: 3,
|
|
2320
|
-
size: "small",
|
|
2321
|
-
type: "warning",
|
|
2322
|
-
disabled: _ctx.disabled,
|
|
2323
|
-
plain: "",
|
|
2324
|
-
onClick: _cache[2] || (_cache[2] = ($event) => clearHandler())
|
|
2325
|
-
}, {
|
|
2326
|
-
default: withCtx(() => _cache[6] || (_cache[6] = [
|
|
2327
|
-
createTextVNode("清空")
|
|
2328
|
-
])),
|
|
2329
|
-
_: 1
|
|
2330
|
-
/* STABLE */
|
|
2331
|
-
}, 8, ["disabled"])) : createCommentVNode("v-if", true)
|
|
2332
|
-
])
|
|
2333
|
-
]),
|
|
2334
|
-
_ctx.config.pagination ? (openBlock(), createElementBlock("div", _hoisted_6, [
|
|
2335
|
-
createVNode(unref(TMagicPagination), {
|
|
2336
|
-
layout: "total, sizes, prev, pager, next, jumper",
|
|
2337
|
-
"hide-on-single-page": _ctx.model[modelName.value].length < pagesize.value,
|
|
2338
|
-
"current-page": pagecontext.value + 1,
|
|
2339
|
-
"page-sizes": [pagesize.value, 60, 120, 300],
|
|
2340
|
-
"page-size": pagesize.value,
|
|
2341
|
-
total: _ctx.model[modelName.value].length,
|
|
2342
|
-
onSizeChange: handleSizeChange,
|
|
2343
|
-
onCurrentChange: handleCurrentChange
|
|
2344
|
-
}, null, 8, ["hide-on-single-page", "current-page", "page-sizes", "page-size", "total"])
|
|
2345
|
-
])) : createCommentVNode("v-if", true)
|
|
2346
|
-
],
|
|
2347
|
-
2
|
|
2348
|
-
/* CLASS */
|
|
2349
|
-
)
|
|
2129
|
+
}, 8, ["disabled"])) : createCommentVNode("", true)
|
|
2130
|
+
])
|
|
2131
|
+
]),
|
|
2132
|
+
_ctx.config.pagination ? (openBlock(), createElementBlock("div", _hoisted_6, [
|
|
2133
|
+
createVNode(unref(TMagicPagination), {
|
|
2134
|
+
layout: "total, sizes, prev, pager, next, jumper",
|
|
2135
|
+
"hide-on-single-page": _ctx.model[modelName.value].length < pagesize.value,
|
|
2136
|
+
"current-page": pagecontext.value + 1,
|
|
2137
|
+
"page-sizes": [pagesize.value, 60, 120, 300],
|
|
2138
|
+
"page-size": pagesize.value,
|
|
2139
|
+
total: _ctx.model[modelName.value].length,
|
|
2140
|
+
onSizeChange: handleSizeChange,
|
|
2141
|
+
onCurrentChange: handleCurrentChange
|
|
2142
|
+
}, null, 8, ["hide-on-single-page", "current-page", "page-sizes", "page-size", "total"])
|
|
2143
|
+
])) : createCommentVNode("", true)
|
|
2144
|
+
], 2)
|
|
2350
2145
|
], 8, ["disabled"]))
|
|
2351
2146
|
]);
|
|
2352
2147
|
};
|
|
@@ -2491,71 +2286,47 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
|
|
|
2491
2286
|
}
|
|
2492
2287
|
), {
|
|
2493
2288
|
default: withCtx(() => [
|
|
2494
|
-
(openBlock(true), createElementBlock(
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
unref(
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
"is-compare": _ctx.isCompare,
|
|
2534
|
-
prop: _ctx.config.dynamic ? `${_ctx.prop}${_ctx.prop ? "." : ""}${String(tabIndex)}` : _ctx.prop,
|
|
2535
|
-
size: _ctx.size,
|
|
2536
|
-
"label-width": tab.labelWidth || _ctx.labelWidth,
|
|
2537
|
-
"expand-more": _ctx.expandMore,
|
|
2538
|
-
onChange: changeHandler,
|
|
2539
|
-
onAddDiffCount: ($event) => onAddDiffCount(tabIndex)
|
|
2540
|
-
}, null, 8, ["config", "disabled", "model", "last-values", "is-compare", "prop", "size", "label-width", "expand-more", "onAddDiffCount"]);
|
|
2541
|
-
}),
|
|
2542
|
-
128
|
|
2543
|
-
/* KEYED_FRAGMENT */
|
|
2544
|
-
))
|
|
2545
|
-
]),
|
|
2546
|
-
_: 2
|
|
2547
|
-
/* DYNAMIC */
|
|
2548
|
-
},
|
|
2549
|
-
1040
|
|
2550
|
-
/* FULL_PROPS, DYNAMIC_SLOTS */
|
|
2551
|
-
);
|
|
2552
|
-
}),
|
|
2553
|
-
128
|
|
2554
|
-
/* KEYED_FRAGMENT */
|
|
2555
|
-
))
|
|
2289
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(tabs.value, (tab, tabIndex) => {
|
|
2290
|
+
return openBlock(), createBlock(resolveDynamicComponent(unref(tabPaneComponent)?.component || "el-tab-pane"), mergeProps(
|
|
2291
|
+
{
|
|
2292
|
+
key: tab[unref(mForm)?.keyProp || "__key"] ?? tabIndex,
|
|
2293
|
+
ref_for: true
|
|
2294
|
+
},
|
|
2295
|
+
unref(tabPaneComponent)?.props({ name: filter(tab.status) || tabIndex.toString(), lazy: tab.lazy || false }) || {}
|
|
2296
|
+
), {
|
|
2297
|
+
label: withCtx(() => [
|
|
2298
|
+
createElementVNode("span", null, [
|
|
2299
|
+
createTextVNode(toDisplayString(filter(tab.title)), 1),
|
|
2300
|
+
createVNode(unref(TMagicBadge), {
|
|
2301
|
+
hidden: !diffCount.value[tabIndex],
|
|
2302
|
+
value: diffCount.value[tabIndex],
|
|
2303
|
+
class: "diff-count-badge"
|
|
2304
|
+
}, null, 8, ["hidden", "value"])
|
|
2305
|
+
])
|
|
2306
|
+
]),
|
|
2307
|
+
default: withCtx(() => [
|
|
2308
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(tabItems(tab), (item) => {
|
|
2309
|
+
return openBlock(), createBlock(_sfc_main$x, {
|
|
2310
|
+
key: item[unref(mForm)?.keyProp || "__key"],
|
|
2311
|
+
config: item,
|
|
2312
|
+
disabled: _ctx.disabled,
|
|
2313
|
+
model: _ctx.config.dynamic ? (_ctx.name ? _ctx.model[_ctx.name] : _ctx.model)[tabIndex] : tab.name ? (_ctx.name ? _ctx.model[_ctx.name] : _ctx.model)[tab.name] : _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
|
|
2314
|
+
"last-values": unref(isEmpty)(_ctx.lastValues) ? {} : _ctx.config.dynamic ? (_ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues)[tabIndex] : tab.name ? (_ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues)[tab.name] : _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
|
|
2315
|
+
"is-compare": _ctx.isCompare,
|
|
2316
|
+
prop: _ctx.config.dynamic ? `${_ctx.prop}${_ctx.prop ? "." : ""}${String(tabIndex)}` : _ctx.prop,
|
|
2317
|
+
size: _ctx.size,
|
|
2318
|
+
"label-width": tab.labelWidth || _ctx.labelWidth,
|
|
2319
|
+
"expand-more": _ctx.expandMore,
|
|
2320
|
+
onChange: changeHandler,
|
|
2321
|
+
onAddDiffCount: ($event) => onAddDiffCount(tabIndex)
|
|
2322
|
+
}, null, 8, ["config", "disabled", "model", "last-values", "is-compare", "prop", "size", "label-width", "expand-more", "onAddDiffCount"]);
|
|
2323
|
+
}), 128))
|
|
2324
|
+
]),
|
|
2325
|
+
_: 2
|
|
2326
|
+
}, 1040);
|
|
2327
|
+
}), 128))
|
|
2556
2328
|
]),
|
|
2557
2329
|
_: 1
|
|
2558
|
-
/* STABLE */
|
|
2559
2330
|
}, 16, ["modelValue", "class"]);
|
|
2560
2331
|
};
|
|
2561
2332
|
}
|
|
@@ -2762,14 +2533,9 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
|
|
|
2762
2533
|
onChange: changeHandler
|
|
2763
2534
|
}, {
|
|
2764
2535
|
default: withCtx(() => [
|
|
2765
|
-
createTextVNode(
|
|
2766
|
-
toDisplayString(_ctx.config.text),
|
|
2767
|
-
1
|
|
2768
|
-
/* TEXT */
|
|
2769
|
-
)
|
|
2536
|
+
createTextVNode(toDisplayString(_ctx.config.text), 1)
|
|
2770
2537
|
]),
|
|
2771
2538
|
_: 1
|
|
2772
|
-
/* STABLE */
|
|
2773
2539
|
}, 8, ["modelValue", "size", "trueValue", "falseValue", "disabled"]);
|
|
2774
2540
|
};
|
|
2775
2541
|
}
|
|
@@ -2818,32 +2584,20 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
|
|
|
2818
2584
|
onChange: changeHandler
|
|
2819
2585
|
}, {
|
|
2820
2586
|
default: withCtx(() => [
|
|
2821
|
-
(openBlock(true), createElementBlock(
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2825
|
-
|
|
2826
|
-
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
|
|
2833
|
-
1
|
|
2834
|
-
/* TEXT */
|
|
2835
|
-
)
|
|
2836
|
-
]),
|
|
2837
|
-
_: 2
|
|
2838
|
-
/* DYNAMIC */
|
|
2839
|
-
}, 1032, ["value", "disabled"]);
|
|
2840
|
-
}),
|
|
2841
|
-
128
|
|
2842
|
-
/* KEYED_FRAGMENT */
|
|
2843
|
-
))
|
|
2587
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(options.value, (option) => {
|
|
2588
|
+
return openBlock(), createBlock(unref(TMagicCheckbox), {
|
|
2589
|
+
value: option.value,
|
|
2590
|
+
key: option.value,
|
|
2591
|
+
disabled: option.disabled
|
|
2592
|
+
}, {
|
|
2593
|
+
default: withCtx(() => [
|
|
2594
|
+
createTextVNode(toDisplayString(option.text), 1)
|
|
2595
|
+
]),
|
|
2596
|
+
_: 2
|
|
2597
|
+
}, 1032, ["value", "disabled"]);
|
|
2598
|
+
}), 128))
|
|
2844
2599
|
]),
|
|
2845
2600
|
_: 1
|
|
2846
|
-
/* STABLE */
|
|
2847
2601
|
}, 8, ["modelValue", "size", "disabled"]);
|
|
2848
2602
|
};
|
|
2849
2603
|
}
|
|
@@ -3103,13 +2857,7 @@ const _sfc_main$g = /* @__PURE__ */ defineComponent({
|
|
|
3103
2857
|
}
|
|
3104
2858
|
useAddField(props.prop);
|
|
3105
2859
|
return (_ctx, _cache) => {
|
|
3106
|
-
return _ctx.model ? (openBlock(), createElementBlock(
|
|
3107
|
-
"span",
|
|
3108
|
-
_hoisted_1$8,
|
|
3109
|
-
toDisplayString(_ctx.model[_ctx.name]),
|
|
3110
|
-
1
|
|
3111
|
-
/* TEXT */
|
|
3112
|
-
)) : createCommentVNode("v-if", true);
|
|
2860
|
+
return _ctx.model ? (openBlock(), createElementBlock("span", _hoisted_1$8, toDisplayString(_ctx.model[_ctx.name]), 1)) : createCommentVNode("", true);
|
|
3113
2861
|
};
|
|
3114
2862
|
}
|
|
3115
2863
|
});
|
|
@@ -3184,32 +2932,24 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
|
3184
2932
|
return openBlock(), createElementBlock("div", _hoisted_1$7, [
|
|
3185
2933
|
createVNode(unref(TMagicForm), { size: "small" }, {
|
|
3186
2934
|
default: withCtx(() => [
|
|
3187
|
-
(openBlock(true), createElementBlock(
|
|
3188
|
-
|
|
3189
|
-
|
|
3190
|
-
|
|
3191
|
-
|
|
3192
|
-
|
|
3193
|
-
|
|
3194
|
-
|
|
3195
|
-
|
|
3196
|
-
|
|
3197
|
-
|
|
3198
|
-
|
|
3199
|
-
|
|
3200
|
-
|
|
3201
|
-
|
|
3202
|
-
|
|
3203
|
-
_: 2
|
|
3204
|
-
/* DYNAMIC */
|
|
3205
|
-
}, 1032, ["label"]);
|
|
3206
|
-
}),
|
|
3207
|
-
128
|
|
3208
|
-
/* KEYED_FRAGMENT */
|
|
3209
|
-
))
|
|
2935
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(Object.keys(fieldMap.value), (key) => {
|
|
2936
|
+
return openBlock(), createBlock(unref(TMagicFormItem), {
|
|
2937
|
+
key,
|
|
2938
|
+
label: fieldLabelMap.value[key]
|
|
2939
|
+
}, {
|
|
2940
|
+
default: withCtx(() => [
|
|
2941
|
+
createVNode(unref(TMagicInput), {
|
|
2942
|
+
modelValue: fieldMap.value[key],
|
|
2943
|
+
"onUpdate:modelValue": ($event) => fieldMap.value[key] = $event,
|
|
2944
|
+
placeholder: fieldLabelMap.value[key],
|
|
2945
|
+
onChange: ($event) => inputChangeHandler(key)
|
|
2946
|
+
}, null, 8, ["modelValue", "onUpdate:modelValue", "placeholder", "onChange"])
|
|
2947
|
+
]),
|
|
2948
|
+
_: 2
|
|
2949
|
+
}, 1032, ["label"]);
|
|
2950
|
+
}), 128))
|
|
3210
2951
|
]),
|
|
3211
2952
|
_: 1
|
|
3212
|
-
/* STABLE */
|
|
3213
2953
|
})
|
|
3214
2954
|
]);
|
|
3215
2955
|
};
|
|
@@ -3236,19 +2976,13 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
|
3236
2976
|
const props = __props;
|
|
3237
2977
|
useAddField(props.prop);
|
|
3238
2978
|
return (_ctx, _cache) => {
|
|
3239
|
-
return _ctx.model ? withDirectives((openBlock(), createElementBlock(
|
|
3240
|
-
|
|
3241
|
-
|
|
3242
|
-
|
|
3243
|
-
|
|
3244
|
-
type: "hidden"
|
|
3245
|
-
},
|
|
3246
|
-
null,
|
|
3247
|
-
512
|
|
3248
|
-
/* NEED_PATCH */
|
|
3249
|
-
)), [
|
|
2979
|
+
return _ctx.model ? withDirectives((openBlock(), createElementBlock("input", {
|
|
2980
|
+
key: 0,
|
|
2981
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
|
|
2982
|
+
type: "hidden"
|
|
2983
|
+
}, null, 512)), [
|
|
3250
2984
|
[vModelText, _ctx.model[_ctx.name]]
|
|
3251
|
-
]) : createCommentVNode("
|
|
2985
|
+
]) : createCommentVNode("", true);
|
|
3252
2986
|
};
|
|
3253
2987
|
}
|
|
3254
2988
|
});
|
|
@@ -3408,29 +3142,22 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
3408
3142
|
onSubmit: submitHandler
|
|
3409
3143
|
}, {
|
|
3410
3144
|
default: withCtx(() => [
|
|
3411
|
-
initialized.value && Array.isArray(_ctx.config) ? (openBlock(true), createElementBlock(
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3417
|
-
|
|
3418
|
-
|
|
3419
|
-
|
|
3420
|
-
|
|
3421
|
-
|
|
3422
|
-
|
|
3423
|
-
|
|
3424
|
-
|
|
3425
|
-
onChange: changeHandler
|
|
3426
|
-
}, null, 8, ["disabled", "config", "model", "last-values", "is-compare", "label-width", "step-active", "size"]);
|
|
3427
|
-
}),
|
|
3428
|
-
128
|
|
3429
|
-
/* KEYED_FRAGMENT */
|
|
3430
|
-
)) : createCommentVNode("v-if", true)
|
|
3145
|
+
initialized.value && Array.isArray(_ctx.config) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.config, (item, index) => {
|
|
3146
|
+
return openBlock(), createBlock(_sfc_main$x, {
|
|
3147
|
+
disabled: _ctx.disabled,
|
|
3148
|
+
key: item[_ctx.keyProp] ?? index,
|
|
3149
|
+
config: item,
|
|
3150
|
+
model: values.value,
|
|
3151
|
+
"last-values": lastValuesProcessed.value,
|
|
3152
|
+
"is-compare": _ctx.isCompare,
|
|
3153
|
+
"label-width": item.labelWidth || _ctx.labelWidth,
|
|
3154
|
+
"step-active": _ctx.stepActive,
|
|
3155
|
+
size: _ctx.size,
|
|
3156
|
+
onChange: changeHandler
|
|
3157
|
+
}, null, 8, ["disabled", "config", "model", "last-values", "is-compare", "label-width", "step-active", "size"]);
|
|
3158
|
+
}), 128)) : createCommentVNode("", true)
|
|
3431
3159
|
]),
|
|
3432
3160
|
_: 1
|
|
3433
|
-
/* STABLE */
|
|
3434
3161
|
}, 8, ["model", "label-width", "style", "inline", "label-position"]);
|
|
3435
3162
|
};
|
|
3436
3163
|
}
|
|
@@ -3551,7 +3278,6 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3551
3278
|
])
|
|
3552
3279
|
]),
|
|
3553
3280
|
_: 3
|
|
3554
|
-
/* FORWARDED */
|
|
3555
3281
|
}),
|
|
3556
3282
|
createVNode(unref(TMagicCol), { span: 12 }, {
|
|
3557
3283
|
default: withCtx(() => [
|
|
@@ -3564,7 +3290,6 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3564
3290
|
createTextVNode("取 消")
|
|
3565
3291
|
])),
|
|
3566
3292
|
_: 1
|
|
3567
|
-
/* STABLE */
|
|
3568
3293
|
}),
|
|
3569
3294
|
hasStep.value && stepActive.value > 1 ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
3570
3295
|
key: 0,
|
|
@@ -3576,8 +3301,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3576
3301
|
createTextVNode("上一步")
|
|
3577
3302
|
])),
|
|
3578
3303
|
_: 1
|
|
3579
|
-
|
|
3580
|
-
})) : createCommentVNode("v-if", true),
|
|
3304
|
+
})) : createCommentVNode("", true),
|
|
3581
3305
|
hasStep.value && stepCount.value > stepActive.value ? (openBlock(), createBlock(unref(TMagicButton), {
|
|
3582
3306
|
key: 1,
|
|
3583
3307
|
type: "info",
|
|
@@ -3588,7 +3312,6 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3588
3312
|
createTextVNode("下一步")
|
|
3589
3313
|
])),
|
|
3590
3314
|
_: 1
|
|
3591
|
-
/* STABLE */
|
|
3592
3315
|
})) : (openBlock(), createBlock(unref(TMagicButton), {
|
|
3593
3316
|
key: 2,
|
|
3594
3317
|
type: "primary",
|
|
@@ -3598,58 +3321,44 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
|
3598
3321
|
onClick: save
|
|
3599
3322
|
}, {
|
|
3600
3323
|
default: withCtx(() => [
|
|
3601
|
-
createTextVNode(
|
|
3602
|
-
toDisplayString(_ctx.confirmText),
|
|
3603
|
-
1
|
|
3604
|
-
/* TEXT */
|
|
3605
|
-
)
|
|
3324
|
+
createTextVNode(toDisplayString(_ctx.confirmText), 1)
|
|
3606
3325
|
]),
|
|
3607
3326
|
_: 1
|
|
3608
|
-
/* STABLE */
|
|
3609
3327
|
}, 8, ["disabled", "loading"]))
|
|
3610
3328
|
])
|
|
3611
3329
|
]),
|
|
3612
3330
|
_: 3
|
|
3613
|
-
/* FORWARDED */
|
|
3614
3331
|
})
|
|
3615
3332
|
]),
|
|
3616
3333
|
_: 3
|
|
3617
|
-
/* FORWARDED */
|
|
3618
3334
|
})
|
|
3619
3335
|
]),
|
|
3620
3336
|
default: withCtx(() => [
|
|
3621
|
-
dialogVisible.value ? (openBlock(), createElementBlock(
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3625
|
-
|
|
3626
|
-
|
|
3627
|
-
|
|
3628
|
-
|
|
3629
|
-
|
|
3630
|
-
|
|
3631
|
-
|
|
3632
|
-
|
|
3633
|
-
|
|
3634
|
-
|
|
3635
|
-
|
|
3636
|
-
|
|
3637
|
-
|
|
3638
|
-
|
|
3639
|
-
|
|
3640
|
-
|
|
3641
|
-
|
|
3642
|
-
|
|
3643
|
-
|
|
3644
|
-
}, null, 8, ["modelValue", "size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
3645
|
-
renderSlot(_ctx.$slots, "default")
|
|
3646
|
-
],
|
|
3647
|
-
4
|
|
3648
|
-
/* STYLE */
|
|
3649
|
-
)) : createCommentVNode("v-if", true)
|
|
3337
|
+
dialogVisible.value ? (openBlock(), createElementBlock("div", {
|
|
3338
|
+
key: 0,
|
|
3339
|
+
class: "m-dialog-body",
|
|
3340
|
+
style: normalizeStyle(`max-height: ${bodyHeight.value}; overflow-y: auto; overflow-x: hidden;`)
|
|
3341
|
+
}, [
|
|
3342
|
+
createVNode(_sfc_main$d, {
|
|
3343
|
+
modelValue: stepActive.value,
|
|
3344
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => stepActive.value = $event),
|
|
3345
|
+
ref_key: "form",
|
|
3346
|
+
ref: form,
|
|
3347
|
+
size: _ctx.size,
|
|
3348
|
+
disabled: _ctx.disabled,
|
|
3349
|
+
config: _ctx.config,
|
|
3350
|
+
"init-values": _ctx.values,
|
|
3351
|
+
"parent-values": _ctx.parentValues,
|
|
3352
|
+
"label-width": _ctx.labelWidth,
|
|
3353
|
+
"label-position": _ctx.labelPosition,
|
|
3354
|
+
inline: _ctx.inline,
|
|
3355
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
3356
|
+
onChange: changeHandler
|
|
3357
|
+
}, null, 8, ["modelValue", "size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
3358
|
+
renderSlot(_ctx.$slots, "default")
|
|
3359
|
+
], 4)) : createCommentVNode("", true)
|
|
3650
3360
|
]),
|
|
3651
3361
|
_: 3
|
|
3652
|
-
/* FORWARDED */
|
|
3653
3362
|
}, 8, ["modelValue", "title", "width", "zIndex", "fullscreen"]);
|
|
3654
3363
|
};
|
|
3655
3364
|
}
|
|
@@ -3729,16 +3438,10 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
|
|
|
3729
3438
|
target: "_blank",
|
|
3730
3439
|
href: href.value,
|
|
3731
3440
|
style: normalizeStyle(_ctx.config.css || {})
|
|
3732
|
-
}, toDisplayString(displayText.value), 13, _hoisted_1$5)) : _ctx.config.href && _ctx.disabled ? (openBlock(), createElementBlock(
|
|
3733
|
-
|
|
3734
|
-
{
|
|
3735
|
-
|
|
3736
|
-
style: normalizeStyle(_ctx.config.disabledCss || {})
|
|
3737
|
-
},
|
|
3738
|
-
toDisplayString(displayText.value),
|
|
3739
|
-
5
|
|
3740
|
-
/* TEXT, STYLE */
|
|
3741
|
-
)) : (openBlock(), createElementBlock("div", _hoisted_2$1, [
|
|
3441
|
+
}, toDisplayString(displayText.value), 13, _hoisted_1$5)) : _ctx.config.href && _ctx.disabled ? (openBlock(), createElementBlock("span", {
|
|
3442
|
+
key: 1,
|
|
3443
|
+
style: normalizeStyle(_ctx.config.disabledCss || {})
|
|
3444
|
+
}, toDisplayString(displayText.value), 5)) : (openBlock(), createElementBlock("div", _hoisted_2$1, [
|
|
3742
3445
|
createVNode(unref(TMagicButton), {
|
|
3743
3446
|
link: "",
|
|
3744
3447
|
type: "primary",
|
|
@@ -3748,7 +3451,6 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
|
|
|
3748
3451
|
createTextVNode("点击编辑")
|
|
3749
3452
|
])),
|
|
3750
3453
|
_: 1
|
|
3751
|
-
/* STABLE */
|
|
3752
3454
|
}),
|
|
3753
3455
|
createVNode(_sfc_main$c, {
|
|
3754
3456
|
ref_key: "editor",
|
|
@@ -3810,7 +3512,7 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
|
3810
3512
|
disabled: _ctx.disabled,
|
|
3811
3513
|
onChange: changeHandler,
|
|
3812
3514
|
onInput: inputHandler
|
|
3813
|
-
}, null, 8, ["modelValue", "size", "max", "min", "step", "placeholder", "disabled"])) : createCommentVNode("
|
|
3515
|
+
}, null, 8, ["modelValue", "size", "max", "min", "step", "placeholder", "disabled"])) : createCommentVNode("", true);
|
|
3814
3516
|
};
|
|
3815
3517
|
}
|
|
3816
3518
|
});
|
|
@@ -3856,13 +3558,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
|
3856
3558
|
disabled: _ctx.disabled,
|
|
3857
3559
|
onChange: minChangeHandler
|
|
3858
3560
|
}, null, 8, ["modelValue", "size", "disabled"]),
|
|
3859
|
-
_cache[2] || (_cache[2] = createElementVNode(
|
|
3860
|
-
"span",
|
|
3861
|
-
{ class: "split-tag" },
|
|
3862
|
-
"-",
|
|
3863
|
-
-1
|
|
3864
|
-
/* HOISTED */
|
|
3865
|
-
)),
|
|
3561
|
+
_cache[2] || (_cache[2] = createElementVNode("span", { class: "split-tag" }, "-", -1)),
|
|
3866
3562
|
createVNode(unref(TMagicInput), {
|
|
3867
3563
|
modelValue: _ctx.model[_ctx.name][1],
|
|
3868
3564
|
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.model[_ctx.name][1] = $event),
|
|
@@ -3915,87 +3611,52 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
|
3915
3611
|
disabled: _ctx.disabled
|
|
3916
3612
|
}, {
|
|
3917
3613
|
default: withCtx(() => [
|
|
3918
|
-
(openBlock(true), createElementBlock(
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
|
|
3922
|
-
|
|
3923
|
-
|
|
3924
|
-
|
|
3925
|
-
|
|
3926
|
-
|
|
3927
|
-
|
|
3928
|
-
option.tooltip
|
|
3929
|
-
|
|
3930
|
-
|
|
3931
|
-
|
|
3932
|
-
|
|
3933
|
-
default: withCtx(() => [
|
|
3934
|
-
createElementVNode("div", null, [
|
|
3935
|
-
option.icon ? (openBlock(), createBlock(
|
|
3936
|
-
unref(TMagicIcon),
|
|
3937
|
-
{
|
|
3938
|
-
key: 0,
|
|
3939
|
-
size: "16"
|
|
3940
|
-
},
|
|
3941
|
-
{
|
|
3942
|
-
default: withCtx(() => [
|
|
3943
|
-
(openBlock(), createBlock(resolveDynamicComponent(option.icon)))
|
|
3944
|
-
]),
|
|
3945
|
-
_: 2
|
|
3946
|
-
/* DYNAMIC */
|
|
3947
|
-
},
|
|
3948
|
-
1024
|
|
3949
|
-
/* DYNAMIC_SLOTS */
|
|
3950
|
-
)) : createCommentVNode("v-if", true),
|
|
3951
|
-
createElementVNode(
|
|
3952
|
-
"span",
|
|
3953
|
-
null,
|
|
3954
|
-
toDisplayString(option.text),
|
|
3955
|
-
1
|
|
3956
|
-
/* TEXT */
|
|
3957
|
-
)
|
|
3958
|
-
])
|
|
3959
|
-
]),
|
|
3960
|
-
_: 2
|
|
3961
|
-
/* DYNAMIC */
|
|
3962
|
-
}, 1032, ["content"])) : (openBlock(), createElementBlock("div", _hoisted_1$3, [
|
|
3963
|
-
option.icon ? (openBlock(), createBlock(
|
|
3964
|
-
unref(TMagicIcon),
|
|
3965
|
-
{
|
|
3614
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.options, (option) => {
|
|
3615
|
+
return openBlock(), createBlock(resolveDynamicComponent(itemComponent.value), {
|
|
3616
|
+
value: option.value,
|
|
3617
|
+
key: `${option.value}`,
|
|
3618
|
+
onClick: withModifiers(($event) => clickHandler(option.value), ["prevent"])
|
|
3619
|
+
}, {
|
|
3620
|
+
default: withCtx(() => [
|
|
3621
|
+
option.tooltip ? (openBlock(), createBlock(unref(TMagicTooltip), {
|
|
3622
|
+
key: 0,
|
|
3623
|
+
placement: "top-start",
|
|
3624
|
+
content: option.tooltip
|
|
3625
|
+
}, {
|
|
3626
|
+
default: withCtx(() => [
|
|
3627
|
+
createElementVNode("div", null, [
|
|
3628
|
+
option.icon ? (openBlock(), createBlock(unref(TMagicIcon), {
|
|
3966
3629
|
key: 0,
|
|
3967
3630
|
size: "16"
|
|
3968
|
-
},
|
|
3969
|
-
{
|
|
3631
|
+
}, {
|
|
3970
3632
|
default: withCtx(() => [
|
|
3971
3633
|
(openBlock(), createBlock(resolveDynamicComponent(option.icon)))
|
|
3972
3634
|
]),
|
|
3973
3635
|
_: 2
|
|
3974
|
-
|
|
3975
|
-
|
|
3976
|
-
|
|
3977
|
-
|
|
3978
|
-
|
|
3979
|
-
|
|
3980
|
-
|
|
3981
|
-
|
|
3982
|
-
|
|
3983
|
-
|
|
3984
|
-
|
|
3985
|
-
|
|
3986
|
-
|
|
3987
|
-
|
|
3988
|
-
|
|
3989
|
-
|
|
3990
|
-
|
|
3991
|
-
|
|
3992
|
-
|
|
3993
|
-
|
|
3994
|
-
))
|
|
3636
|
+
}, 1024)) : createCommentVNode("", true),
|
|
3637
|
+
createElementVNode("span", null, toDisplayString(option.text), 1)
|
|
3638
|
+
])
|
|
3639
|
+
]),
|
|
3640
|
+
_: 2
|
|
3641
|
+
}, 1032, ["content"])) : (openBlock(), createElementBlock("div", _hoisted_1$3, [
|
|
3642
|
+
option.icon ? (openBlock(), createBlock(unref(TMagicIcon), {
|
|
3643
|
+
key: 0,
|
|
3644
|
+
size: "16"
|
|
3645
|
+
}, {
|
|
3646
|
+
default: withCtx(() => [
|
|
3647
|
+
(openBlock(), createBlock(resolveDynamicComponent(option.icon)))
|
|
3648
|
+
]),
|
|
3649
|
+
_: 2
|
|
3650
|
+
}, 1024)) : createCommentVNode("", true),
|
|
3651
|
+
createElementVNode("span", null, toDisplayString(option.text), 1)
|
|
3652
|
+
]))
|
|
3653
|
+
]),
|
|
3654
|
+
_: 2
|
|
3655
|
+
}, 1032, ["value", "onClick"]);
|
|
3656
|
+
}), 128))
|
|
3995
3657
|
]),
|
|
3996
3658
|
_: 1
|
|
3997
|
-
|
|
3998
|
-
}, 8, ["modelValue", "size", "disabled"])) : createCommentVNode("v-if", true);
|
|
3659
|
+
}, 8, ["modelValue", "size", "disabled"])) : createCommentVNode("", true);
|
|
3999
3660
|
};
|
|
4000
3661
|
}
|
|
4001
3662
|
});
|
|
@@ -4018,7 +3679,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4018
3679
|
lastValues: {}
|
|
4019
3680
|
},
|
|
4020
3681
|
emits: ["change"],
|
|
4021
|
-
setup(__props, { emit: __emit }) {
|
|
3682
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
4022
3683
|
const props = __props;
|
|
4023
3684
|
const emit = __emit;
|
|
4024
3685
|
const optionComponent = getDesignConfig("components")?.option;
|
|
@@ -4094,7 +3755,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4094
3755
|
postOptions.data = body;
|
|
4095
3756
|
const requestFuc = getConfig("request");
|
|
4096
3757
|
if (typeof option.beforeRequest === "function") {
|
|
4097
|
-
postOptions = option.beforeRequest(mForm, postOptions, {
|
|
3758
|
+
postOptions = await option.beforeRequest(mForm, postOptions, {
|
|
4098
3759
|
model: props.model,
|
|
4099
3760
|
formValue: mForm?.values,
|
|
4100
3761
|
formValues: mForm?.values,
|
|
@@ -4107,7 +3768,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4107
3768
|
}
|
|
4108
3769
|
let res = await requestFuc(postOptions);
|
|
4109
3770
|
if (typeof option.afterRequest === "function") {
|
|
4110
|
-
res = option.afterRequest(mForm, res, {
|
|
3771
|
+
res = await option.afterRequest(mForm, res, {
|
|
4111
3772
|
model: props.model,
|
|
4112
3773
|
formValue: mForm?.values,
|
|
4113
3774
|
formValues: mForm?.values,
|
|
@@ -4196,7 +3857,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4196
3857
|
json: option.json || false
|
|
4197
3858
|
};
|
|
4198
3859
|
if (typeof option.beforeInitRequest === "function") {
|
|
4199
|
-
postOptions = option.beforeInitRequest(mForm, postOptions, {
|
|
3860
|
+
postOptions = await option.beforeInitRequest(mForm, postOptions, {
|
|
4200
3861
|
model: props.model,
|
|
4201
3862
|
formValue: mForm?.values,
|
|
4202
3863
|
formValues: mForm?.values,
|
|
@@ -4210,7 +3871,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4210
3871
|
const requestFuc = getConfig("request");
|
|
4211
3872
|
let res = await requestFuc(postOptions);
|
|
4212
3873
|
if (typeof option.afterRequest === "function") {
|
|
4213
|
-
res = option.afterRequest(mForm, res, {
|
|
3874
|
+
res = await option.afterRequest(mForm, res, {
|
|
4214
3875
|
model: props.model,
|
|
4215
3876
|
formValue: mForm?.values,
|
|
4216
3877
|
formValues: mForm?.values,
|
|
@@ -4232,6 +3893,9 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4232
3893
|
}
|
|
4233
3894
|
return options2;
|
|
4234
3895
|
};
|
|
3896
|
+
const setOptions = (data) => {
|
|
3897
|
+
options.value = data;
|
|
3898
|
+
};
|
|
4235
3899
|
if (typeof props.config.options === "function") {
|
|
4236
3900
|
watchEffect(() => {
|
|
4237
3901
|
typeof props.config.options === "function" && Promise.resolve(
|
|
@@ -4243,12 +3907,12 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4243
3907
|
config: props.config
|
|
4244
3908
|
})
|
|
4245
3909
|
).then((data) => {
|
|
4246
|
-
|
|
3910
|
+
setOptions(data);
|
|
4247
3911
|
});
|
|
4248
3912
|
});
|
|
4249
3913
|
} else if (Array.isArray(props.config.options)) {
|
|
4250
3914
|
watchEffect(() => {
|
|
4251
|
-
|
|
3915
|
+
setOptions(props.config.options);
|
|
4252
3916
|
});
|
|
4253
3917
|
} else if (props.config.option) {
|
|
4254
3918
|
onBeforeMount(() => {
|
|
@@ -4256,7 +3920,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4256
3920
|
const v = props.model[props.name];
|
|
4257
3921
|
if (Array.isArray(v) ? v.length : typeof v !== "undefined") {
|
|
4258
3922
|
getInitOption().then((data) => {
|
|
4259
|
-
|
|
3923
|
+
setOptions(data);
|
|
4260
3924
|
});
|
|
4261
3925
|
}
|
|
4262
3926
|
});
|
|
@@ -4282,7 +3946,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4282
3946
|
}
|
|
4283
3947
|
moreLoadingVisible.value = true;
|
|
4284
3948
|
pgIndex.value += 1;
|
|
4285
|
-
|
|
3949
|
+
setOptions(await getOptions());
|
|
4286
3950
|
moreLoadingVisible.value = false;
|
|
4287
3951
|
});
|
|
4288
3952
|
},
|
|
@@ -4303,20 +3967,24 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4303
3967
|
tMagicSelect.value.setPreviousQuery(query.value);
|
|
4304
3968
|
tMagicSelect.value.setSelectedLabel(query.value);
|
|
4305
3969
|
} else if (options.value.length <= (props.config.multiple ? props.model?.[props.name].length : 1)) {
|
|
4306
|
-
|
|
3970
|
+
setOptions(await getOptions());
|
|
4307
3971
|
}
|
|
4308
3972
|
};
|
|
4309
3973
|
const remoteMethod = async (q) => {
|
|
4310
3974
|
if (!localOptions.value.length) {
|
|
4311
3975
|
query.value = q;
|
|
4312
3976
|
pgIndex.value = 0;
|
|
4313
|
-
|
|
3977
|
+
setOptions(await getOptions());
|
|
4314
3978
|
if (props.config.multiple)
|
|
4315
3979
|
setTimeout(() => {
|
|
4316
3980
|
tMagicSelect.value?.setSelected();
|
|
4317
3981
|
}, 0);
|
|
4318
3982
|
}
|
|
4319
3983
|
};
|
|
3984
|
+
__expose({
|
|
3985
|
+
options,
|
|
3986
|
+
setOptions
|
|
3987
|
+
});
|
|
4320
3988
|
return (_ctx, _cache) => {
|
|
4321
3989
|
const _directive_loading = resolveDirective("loading");
|
|
4322
3990
|
return _ctx.model ? withDirectives((openBlock(), createBlock(unref(TMagicSelect), {
|
|
@@ -4341,111 +4009,67 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
4341
4009
|
onVisibleChange: visibleHandler
|
|
4342
4010
|
}, {
|
|
4343
4011
|
default: withCtx(() => [
|
|
4344
|
-
_ctx.config.group ? (openBlock(true), createElementBlock(
|
|
4345
|
-
|
|
4346
|
-
|
|
4347
|
-
|
|
4348
|
-
|
|
4349
|
-
|
|
4350
|
-
|
|
4351
|
-
|
|
4352
|
-
|
|
4353
|
-
|
|
4354
|
-
|
|
4355
|
-
|
|
4356
|
-
|
|
4357
|
-
|
|
4358
|
-
|
|
4359
|
-
|
|
4360
|
-
|
|
4361
|
-
|
|
4362
|
-
|
|
4363
|
-
|
|
4364
|
-
|
|
4365
|
-
(
|
|
4366
|
-
|
|
4367
|
-
|
|
4368
|
-
|
|
4369
|
-
|
|
4370
|
-
|
|
4371
|
-
|
|
4372
|
-
|
|
4373
|
-
|
|
4374
|
-
|
|
4375
|
-
|
|
4376
|
-
|
|
4377
|
-
|
|
4378
|
-
|
|
4379
|
-
|
|
4380
|
-
|
|
4381
|
-
|
|
4382
|
-
|
|
4383
|
-
|
|
4384
|
-
|
|
4385
|
-
|
|
4386
|
-
|
|
4387
|
-
|
|
4388
|
-
|
|
4389
|
-
|
|
4390
|
-
|
|
4391
|
-
|
|
4392
|
-
|
|
4393
|
-
|
|
4394
|
-
|
|
4395
|
-
|
|
4396
|
-
|
|
4397
|
-
|
|
4398
|
-
1040
|
|
4399
|
-
/* FULL_PROPS, DYNAMIC_SLOTS */
|
|
4400
|
-
);
|
|
4401
|
-
}),
|
|
4402
|
-
128
|
|
4403
|
-
/* KEYED_FRAGMENT */
|
|
4404
|
-
)) : (openBlock(true), createElementBlock(
|
|
4405
|
-
Fragment,
|
|
4406
|
-
{ key: 1 },
|
|
4407
|
-
renderList(options.value, (option) => {
|
|
4408
|
-
return openBlock(), createBlock(
|
|
4409
|
-
resolveDynamicComponent(unref(optionComponent)?.component || "el-option"),
|
|
4410
|
-
mergeProps(
|
|
4411
|
-
{
|
|
4412
|
-
class: "tmagic-design-option",
|
|
4413
|
-
key: _ctx.config.valueKey ? option.value[_ctx.config.valueKey] : option.value,
|
|
4414
|
-
ref_for: true
|
|
4415
|
-
},
|
|
4416
|
-
unref(optionComponent)?.props({
|
|
4417
|
-
label: option.text,
|
|
4418
|
-
value: option.value,
|
|
4419
|
-
disabled: option.disabled
|
|
4420
|
-
}) || {
|
|
4421
|
-
label: option.text,
|
|
4422
|
-
value: option.value,
|
|
4423
|
-
disabled: option.disabled
|
|
4424
|
-
}
|
|
4425
|
-
),
|
|
4426
|
-
null,
|
|
4427
|
-
16
|
|
4428
|
-
/* FULL_PROPS */
|
|
4429
|
-
);
|
|
4430
|
-
}),
|
|
4431
|
-
128
|
|
4432
|
-
/* KEYED_FRAGMENT */
|
|
4433
|
-
)),
|
|
4434
|
-
moreLoadingVisible.value ? withDirectives((openBlock(), createElementBlock(
|
|
4435
|
-
"div",
|
|
4436
|
-
_hoisted_1$2,
|
|
4437
|
-
null,
|
|
4438
|
-
512
|
|
4439
|
-
/* NEED_PATCH */
|
|
4440
|
-
)), [
|
|
4012
|
+
_ctx.config.group ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(options.value, (group, index) => {
|
|
4013
|
+
return openBlock(), createBlock(resolveDynamicComponent(unref(optionGroupComponent)?.component || "el-option-group"), mergeProps(
|
|
4014
|
+
{
|
|
4015
|
+
key: index,
|
|
4016
|
+
ref_for: true
|
|
4017
|
+
},
|
|
4018
|
+
unref(optionGroupComponent)?.props({
|
|
4019
|
+
label: group.label,
|
|
4020
|
+
disabled: group.disabled
|
|
4021
|
+
}) || {
|
|
4022
|
+
label: group.label,
|
|
4023
|
+
disabled: group.disabled
|
|
4024
|
+
}
|
|
4025
|
+
), {
|
|
4026
|
+
default: withCtx(() => [
|
|
4027
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(group.options, (item, index2) => {
|
|
4028
|
+
return openBlock(), createBlock(resolveDynamicComponent(unref(optionComponent)?.component || "el-option"), mergeProps(
|
|
4029
|
+
{
|
|
4030
|
+
key: index2,
|
|
4031
|
+
ref_for: true
|
|
4032
|
+
},
|
|
4033
|
+
unref(optionComponent)?.props({
|
|
4034
|
+
label: item.label || item.text,
|
|
4035
|
+
value: item.value,
|
|
4036
|
+
disabled: item.disabled
|
|
4037
|
+
}) || {
|
|
4038
|
+
label: item.label || item.text,
|
|
4039
|
+
value: item.value,
|
|
4040
|
+
disabled: item.disabled
|
|
4041
|
+
}
|
|
4042
|
+
), null, 16);
|
|
4043
|
+
}), 128))
|
|
4044
|
+
]),
|
|
4045
|
+
_: 2
|
|
4046
|
+
}, 1040);
|
|
4047
|
+
}), 128)) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(options.value, (option) => {
|
|
4048
|
+
return openBlock(), createBlock(resolveDynamicComponent(unref(optionComponent)?.component || "el-option"), mergeProps(
|
|
4049
|
+
{
|
|
4050
|
+
class: "tmagic-design-option",
|
|
4051
|
+
key: _ctx.config.valueKey ? option.value[_ctx.config.valueKey] : option.value,
|
|
4052
|
+
ref_for: true
|
|
4053
|
+
},
|
|
4054
|
+
unref(optionComponent)?.props({
|
|
4055
|
+
label: option.text,
|
|
4056
|
+
value: option.value,
|
|
4057
|
+
disabled: option.disabled
|
|
4058
|
+
}) || {
|
|
4059
|
+
label: option.text,
|
|
4060
|
+
value: option.value,
|
|
4061
|
+
disabled: option.disabled
|
|
4062
|
+
}
|
|
4063
|
+
), null, 16);
|
|
4064
|
+
}), 128)),
|
|
4065
|
+
moreLoadingVisible.value ? withDirectives((openBlock(), createElementBlock("div", _hoisted_1$2, null, 512)), [
|
|
4441
4066
|
[_directive_loading, true]
|
|
4442
|
-
]) : createCommentVNode("
|
|
4067
|
+
]) : createCommentVNode("", true)
|
|
4443
4068
|
]),
|
|
4444
4069
|
_: 1
|
|
4445
|
-
/* STABLE */
|
|
4446
4070
|
}, 8, ["modelValue", "clearable", "filterable", "popper-class", "size", "remote", "placeholder", "multiple", "value-key", "allow-create", "disabled", "remote-method"])), [
|
|
4447
4071
|
[_directive_loading, loading.value]
|
|
4448
|
-
]) : createCommentVNode("
|
|
4072
|
+
]) : createCommentVNode("", true);
|
|
4449
4073
|
};
|
|
4450
4074
|
}
|
|
4451
4075
|
});
|
|
@@ -4662,10 +4286,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
4662
4286
|
onChange: changeHandler,
|
|
4663
4287
|
onInput: inputHandler,
|
|
4664
4288
|
onKeyup: _cache[1] || (_cache[1] = ($event) => keyUpHandler($event))
|
|
4665
|
-
}, createSlots({
|
|
4666
|
-
_: 2
|
|
4667
|
-
/* DYNAMIC */
|
|
4668
|
-
}, [
|
|
4289
|
+
}, createSlots({ _: 2 }, [
|
|
4669
4290
|
appendConfig.value ? {
|
|
4670
4291
|
name: "append",
|
|
4671
4292
|
fn: withCtx(() => [
|
|
@@ -4676,74 +4297,49 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
4676
4297
|
onClick: withModifiers(buttonClickHandler, ["prevent"])
|
|
4677
4298
|
}, {
|
|
4678
4299
|
default: withCtx(() => [
|
|
4679
|
-
createTextVNode(
|
|
4680
|
-
toDisplayString(appendConfig.value.text),
|
|
4681
|
-
1
|
|
4682
|
-
/* TEXT */
|
|
4683
|
-
)
|
|
4300
|
+
createTextVNode(toDisplayString(appendConfig.value.text), 1)
|
|
4684
4301
|
]),
|
|
4685
4302
|
_: 1
|
|
4686
|
-
|
|
4687
|
-
}, 8, ["size"])) : createCommentVNode("v-if", true)
|
|
4303
|
+
}, 8, ["size"])) : createCommentVNode("", true)
|
|
4688
4304
|
]),
|
|
4689
4305
|
key: "0"
|
|
4690
4306
|
} : void 0
|
|
4691
4307
|
]), 1032, ["modelValue", "size", "placeholder", "disabled"]),
|
|
4692
4308
|
(openBlock(), createBlock(Teleport, { to: "body" }, [
|
|
4693
|
-
popoverVisible.value ? (openBlock(), createElementBlock(
|
|
4694
|
-
|
|
4695
|
-
|
|
4696
|
-
|
|
4697
|
-
|
|
4698
|
-
|
|
4699
|
-
|
|
4700
|
-
|
|
4701
|
-
|
|
4702
|
-
|
|
4703
|
-
"
|
|
4704
|
-
|
|
4705
|
-
|
|
4706
|
-
|
|
4707
|
-
|
|
4708
|
-
|
|
4709
|
-
|
|
4710
|
-
|
|
4711
|
-
|
|
4712
|
-
|
|
4713
|
-
|
|
4714
|
-
|
|
4715
|
-
|
|
4716
|
-
|
|
4717
|
-
|
|
4718
|
-
|
|
4719
|
-
|
|
4720
|
-
|
|
4721
|
-
|
|
4722
|
-
|
|
4723
|
-
|
|
4724
|
-
|
|
4725
|
-
|
|
4726
|
-
|
|
4727
|
-
createTextVNode("移除空格")
|
|
4728
|
-
])),
|
|
4729
|
-
_: 1
|
|
4730
|
-
/* STABLE */
|
|
4731
|
-
})
|
|
4732
|
-
]),
|
|
4733
|
-
_cache[6] || (_cache[6] = createElementVNode(
|
|
4734
|
-
"span",
|
|
4735
|
-
{
|
|
4736
|
-
class: "tmagic-form-text-popper-arrow",
|
|
4737
|
-
"data-popper-arrow": ""
|
|
4738
|
-
},
|
|
4739
|
-
null,
|
|
4740
|
-
-1
|
|
4741
|
-
/* HOISTED */
|
|
4742
|
-
))
|
|
4743
|
-
],
|
|
4744
|
-
512
|
|
4745
|
-
/* NEED_PATCH */
|
|
4746
|
-
)) : createCommentVNode("v-if", true)
|
|
4309
|
+
popoverVisible.value ? (openBlock(), createElementBlock("div", {
|
|
4310
|
+
key: 0,
|
|
4311
|
+
class: "tmagic-form-text-popper m-form-item__content",
|
|
4312
|
+
ref_key: "popoverEl",
|
|
4313
|
+
ref: popoverEl
|
|
4314
|
+
}, [
|
|
4315
|
+
_cache[5] || (_cache[5] = createElementVNode("div", { class: "m-form-validate__warning" }, "输入内容前后有空格,是否移除空格?", -1)),
|
|
4316
|
+
createElementVNode("div", _hoisted_2, [
|
|
4317
|
+
createVNode(unref(TMagicButton), {
|
|
4318
|
+
link: "",
|
|
4319
|
+
size: "small",
|
|
4320
|
+
onClick: _cache[2] || (_cache[2] = ($event) => popoverVisible.value = false)
|
|
4321
|
+
}, {
|
|
4322
|
+
default: withCtx(() => _cache[3] || (_cache[3] = [
|
|
4323
|
+
createTextVNode("保持原样")
|
|
4324
|
+
])),
|
|
4325
|
+
_: 1
|
|
4326
|
+
}),
|
|
4327
|
+
createVNode(unref(TMagicButton), {
|
|
4328
|
+
type: "primary",
|
|
4329
|
+
size: "small",
|
|
4330
|
+
onClick: confirmTrimHandler
|
|
4331
|
+
}, {
|
|
4332
|
+
default: withCtx(() => _cache[4] || (_cache[4] = [
|
|
4333
|
+
createTextVNode("移除空格")
|
|
4334
|
+
])),
|
|
4335
|
+
_: 1
|
|
4336
|
+
})
|
|
4337
|
+
]),
|
|
4338
|
+
_cache[6] || (_cache[6] = createElementVNode("span", {
|
|
4339
|
+
class: "tmagic-form-text-popper-arrow",
|
|
4340
|
+
"data-popper-arrow": ""
|
|
4341
|
+
}, null, -1))
|
|
4342
|
+
], 512)) : createCommentVNode("", true)
|
|
4747
4343
|
]))
|
|
4748
4344
|
]);
|
|
4749
4345
|
};
|
|
@@ -5020,7 +4616,6 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
5020
4616
|
])
|
|
5021
4617
|
]),
|
|
5022
4618
|
_: 3
|
|
5023
|
-
/* FORWARDED */
|
|
5024
4619
|
}),
|
|
5025
4620
|
createVNode(unref(TMagicCol), { span: 12 }, {
|
|
5026
4621
|
default: withCtx(() => [
|
|
@@ -5030,7 +4625,6 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
5030
4625
|
createTextVNode("关闭")
|
|
5031
4626
|
])),
|
|
5032
4627
|
_: 1
|
|
5033
|
-
/* STABLE */
|
|
5034
4628
|
}),
|
|
5035
4629
|
createVNode(unref(TMagicButton), {
|
|
5036
4630
|
type: "primary",
|
|
@@ -5039,57 +4633,43 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
5039
4633
|
onClick: submitHandler
|
|
5040
4634
|
}, {
|
|
5041
4635
|
default: withCtx(() => [
|
|
5042
|
-
createTextVNode(
|
|
5043
|
-
toDisplayString(_ctx.confirmText),
|
|
5044
|
-
1
|
|
5045
|
-
/* TEXT */
|
|
5046
|
-
)
|
|
4636
|
+
createTextVNode(toDisplayString(_ctx.confirmText), 1)
|
|
5047
4637
|
]),
|
|
5048
4638
|
_: 1
|
|
5049
|
-
/* STABLE */
|
|
5050
4639
|
}, 8, ["disabled", "loading"])
|
|
5051
4640
|
])
|
|
5052
4641
|
]),
|
|
5053
4642
|
_: 3
|
|
5054
|
-
/* FORWARDED */
|
|
5055
4643
|
})
|
|
5056
4644
|
]),
|
|
5057
4645
|
_: 3
|
|
5058
|
-
/* FORWARDED */
|
|
5059
4646
|
})
|
|
5060
4647
|
]),
|
|
5061
4648
|
default: withCtx(() => [
|
|
5062
|
-
visible.value ? (openBlock(), createElementBlock(
|
|
5063
|
-
|
|
5064
|
-
|
|
5065
|
-
|
|
5066
|
-
|
|
5067
|
-
|
|
5068
|
-
|
|
5069
|
-
|
|
5070
|
-
|
|
5071
|
-
|
|
5072
|
-
|
|
5073
|
-
|
|
5074
|
-
|
|
5075
|
-
|
|
5076
|
-
|
|
5077
|
-
|
|
5078
|
-
|
|
5079
|
-
|
|
5080
|
-
|
|
5081
|
-
|
|
5082
|
-
|
|
5083
|
-
|
|
5084
|
-
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
5085
|
-
renderSlot(_ctx.$slots, "default")
|
|
5086
|
-
],
|
|
5087
|
-
512
|
|
5088
|
-
/* NEED_PATCH */
|
|
5089
|
-
)) : createCommentVNode("v-if", true)
|
|
4649
|
+
visible.value ? (openBlock(), createElementBlock("div", {
|
|
4650
|
+
key: 0,
|
|
4651
|
+
ref_key: "drawerBody",
|
|
4652
|
+
ref: drawerBody,
|
|
4653
|
+
class: "m-drawer-body"
|
|
4654
|
+
}, [
|
|
4655
|
+
createVNode(_sfc_main$d, {
|
|
4656
|
+
ref_key: "form",
|
|
4657
|
+
ref: form,
|
|
4658
|
+
size: _ctx.size,
|
|
4659
|
+
disabled: _ctx.disabled,
|
|
4660
|
+
config: _ctx.config,
|
|
4661
|
+
"init-values": _ctx.values,
|
|
4662
|
+
"parent-values": _ctx.parentValues,
|
|
4663
|
+
"label-width": _ctx.labelWidth,
|
|
4664
|
+
"label-position": _ctx.labelPosition,
|
|
4665
|
+
inline: _ctx.inline,
|
|
4666
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
4667
|
+
onChange: changeHandler
|
|
4668
|
+
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
4669
|
+
renderSlot(_ctx.$slots, "default")
|
|
4670
|
+
], 512)) : createCommentVNode("", true)
|
|
5090
4671
|
]),
|
|
5091
4672
|
_: 3
|
|
5092
|
-
/* FORWARDED */
|
|
5093
4673
|
}, 8, ["modelValue", "title", "close-on-press-escape", "size", "zIndex", "before-close"]);
|
|
5094
4674
|
};
|
|
5095
4675
|
}
|
|
@@ -5160,84 +4740,60 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
5160
4740
|
hide
|
|
5161
4741
|
});
|
|
5162
4742
|
return (_ctx, _cache) => {
|
|
5163
|
-
return openBlock(), createElementBlock(
|
|
5164
|
-
"
|
|
5165
|
-
|
|
5166
|
-
|
|
5167
|
-
|
|
5168
|
-
|
|
5169
|
-
|
|
5170
|
-
|
|
5171
|
-
|
|
5172
|
-
|
|
5173
|
-
|
|
5174
|
-
|
|
5175
|
-
|
|
5176
|
-
|
|
5177
|
-
|
|
4743
|
+
return openBlock(), createElementBlock("div", {
|
|
4744
|
+
class: "m-form-box",
|
|
4745
|
+
style: normalizeStyle(style.value)
|
|
4746
|
+
}, [
|
|
4747
|
+
createElementVNode("div", {
|
|
4748
|
+
class: "m-box-body",
|
|
4749
|
+
style: normalizeStyle(bodyHeight.value ? { height: `${bodyHeight.value}px` } : {})
|
|
4750
|
+
}, [
|
|
4751
|
+
createVNode(unref(TMagicScrollbar), null, {
|
|
4752
|
+
default: withCtx(() => [
|
|
4753
|
+
createVNode(_sfc_main$d, {
|
|
4754
|
+
ref_key: "form",
|
|
4755
|
+
ref: form,
|
|
4756
|
+
size: _ctx.size,
|
|
4757
|
+
disabled: _ctx.disabled,
|
|
4758
|
+
config: _ctx.config,
|
|
4759
|
+
"init-values": _ctx.values,
|
|
4760
|
+
"parent-values": _ctx.parentValues,
|
|
4761
|
+
"label-width": _ctx.labelWidth,
|
|
4762
|
+
"label-position": _ctx.labelPosition,
|
|
4763
|
+
inline: _ctx.inline,
|
|
4764
|
+
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
4765
|
+
onChange: changeHandler
|
|
4766
|
+
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
4767
|
+
renderSlot(_ctx.$slots, "default")
|
|
4768
|
+
]),
|
|
4769
|
+
_: 3
|
|
4770
|
+
})
|
|
4771
|
+
], 4),
|
|
4772
|
+
createElementVNode("div", {
|
|
4773
|
+
class: "dialog-footer",
|
|
4774
|
+
style: normalizeStyle(`height: ${footerHeight}px`)
|
|
4775
|
+
}, [
|
|
4776
|
+
createElementVNode("div", null, [
|
|
4777
|
+
renderSlot(_ctx.$slots, "left")
|
|
4778
|
+
]),
|
|
4779
|
+
createElementVNode("div", null, [
|
|
4780
|
+
renderSlot(_ctx.$slots, "footer", {}, () => [
|
|
4781
|
+
createVNode(unref(TMagicButton), {
|
|
4782
|
+
type: "primary",
|
|
4783
|
+
size: _ctx.size,
|
|
4784
|
+
disabled: _ctx.disabled,
|
|
4785
|
+
loading: saveFetch.value,
|
|
4786
|
+
onClick: submitHandler
|
|
4787
|
+
}, {
|
|
5178
4788
|
default: withCtx(() => [
|
|
5179
|
-
|
|
5180
|
-
ref_key: "form",
|
|
5181
|
-
ref: form,
|
|
5182
|
-
size: _ctx.size,
|
|
5183
|
-
disabled: _ctx.disabled,
|
|
5184
|
-
config: _ctx.config,
|
|
5185
|
-
"init-values": _ctx.values,
|
|
5186
|
-
"parent-values": _ctx.parentValues,
|
|
5187
|
-
"label-width": _ctx.labelWidth,
|
|
5188
|
-
"label-position": _ctx.labelPosition,
|
|
5189
|
-
inline: _ctx.inline,
|
|
5190
|
-
"prevent-submit-default": _ctx.preventSubmitDefault,
|
|
5191
|
-
onChange: changeHandler
|
|
5192
|
-
}, null, 8, ["size", "disabled", "config", "init-values", "parent-values", "label-width", "label-position", "inline", "prevent-submit-default"]),
|
|
5193
|
-
renderSlot(_ctx.$slots, "default")
|
|
4789
|
+
createTextVNode(toDisplayString(_ctx.confirmText), 1)
|
|
5194
4790
|
]),
|
|
5195
|
-
_:
|
|
5196
|
-
|
|
5197
|
-
|
|
5198
|
-
|
|
5199
|
-
|
|
5200
|
-
|
|
5201
|
-
),
|
|
5202
|
-
createElementVNode(
|
|
5203
|
-
"div",
|
|
5204
|
-
{
|
|
5205
|
-
class: "dialog-footer",
|
|
5206
|
-
style: normalizeStyle(`height: ${footerHeight}px`)
|
|
5207
|
-
},
|
|
5208
|
-
[
|
|
5209
|
-
createElementVNode("div", null, [
|
|
5210
|
-
renderSlot(_ctx.$slots, "left")
|
|
5211
|
-
]),
|
|
5212
|
-
createElementVNode("div", null, [
|
|
5213
|
-
renderSlot(_ctx.$slots, "footer", {}, () => [
|
|
5214
|
-
createVNode(unref(TMagicButton), {
|
|
5215
|
-
type: "primary",
|
|
5216
|
-
size: _ctx.size,
|
|
5217
|
-
disabled: _ctx.disabled,
|
|
5218
|
-
loading: saveFetch.value,
|
|
5219
|
-
onClick: submitHandler
|
|
5220
|
-
}, {
|
|
5221
|
-
default: withCtx(() => [
|
|
5222
|
-
createTextVNode(
|
|
5223
|
-
toDisplayString(_ctx.confirmText),
|
|
5224
|
-
1
|
|
5225
|
-
/* TEXT */
|
|
5226
|
-
)
|
|
5227
|
-
]),
|
|
5228
|
-
_: 1
|
|
5229
|
-
/* STABLE */
|
|
5230
|
-
}, 8, ["size", "disabled", "loading"])
|
|
5231
|
-
])
|
|
5232
|
-
])
|
|
5233
|
-
],
|
|
5234
|
-
4
|
|
5235
|
-
/* STYLE */
|
|
5236
|
-
)
|
|
5237
|
-
],
|
|
5238
|
-
4
|
|
5239
|
-
/* STYLE */
|
|
5240
|
-
);
|
|
4791
|
+
_: 1
|
|
4792
|
+
}, 8, ["size", "disabled", "loading"])
|
|
4793
|
+
])
|
|
4794
|
+
])
|
|
4795
|
+
], 4)
|
|
4796
|
+
], 4);
|
|
5241
4797
|
};
|
|
5242
4798
|
}
|
|
5243
4799
|
});
|