@idooel/components 0.0.1-beta.61 → 0.0.1-beta.62
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/@idooel/components.esm.js +764 -597
- package/dist/@idooel/components.umd.js +797 -629
- package/package.json +1 -1
- package/packages/composite-components/modal-table/index.js +5 -0
- package/packages/composite-components/modal-table/src/index.vue +93 -0
- package/packages/index.js +5 -2
- package/packages/models/tree-table-model/src/index.vue +8 -1
- package/packages/table/src/index.vue +1 -1
- package/packages/utils/index.js +1 -0
|
@@ -20,7 +20,7 @@ import FileUpload from 'vue-upload-component';
|
|
|
20
20
|
//
|
|
21
21
|
//
|
|
22
22
|
|
|
23
|
-
var script$
|
|
23
|
+
var script$C = {
|
|
24
24
|
name: 'ele-button',
|
|
25
25
|
props: {
|
|
26
26
|
record: {
|
|
@@ -141,10 +141,10 @@ function normalizeComponent(template, style, script, scopeId, isFunctionalTempla
|
|
|
141
141
|
}
|
|
142
142
|
|
|
143
143
|
/* script */
|
|
144
|
-
const __vue_script__$
|
|
144
|
+
const __vue_script__$C = script$C;
|
|
145
145
|
|
|
146
146
|
/* template */
|
|
147
|
-
var __vue_render__$
|
|
147
|
+
var __vue_render__$C = function () {
|
|
148
148
|
var _vm = this;
|
|
149
149
|
var _h = _vm.$createElement;
|
|
150
150
|
var _c = _vm._self._c || _h;
|
|
@@ -190,17 +190,17 @@ var __vue_render__$B = function () {
|
|
|
190
190
|
2
|
|
191
191
|
)
|
|
192
192
|
};
|
|
193
|
-
var __vue_staticRenderFns__$
|
|
194
|
-
__vue_render__$
|
|
193
|
+
var __vue_staticRenderFns__$C = [];
|
|
194
|
+
__vue_render__$C._withStripped = true;
|
|
195
195
|
|
|
196
196
|
/* style */
|
|
197
|
-
const __vue_inject_styles__$
|
|
197
|
+
const __vue_inject_styles__$C = undefined;
|
|
198
198
|
/* scoped */
|
|
199
|
-
const __vue_scope_id__$
|
|
199
|
+
const __vue_scope_id__$C = undefined;
|
|
200
200
|
/* module identifier */
|
|
201
|
-
const __vue_module_identifier__$
|
|
201
|
+
const __vue_module_identifier__$C = undefined;
|
|
202
202
|
/* functional template */
|
|
203
|
-
const __vue_is_functional_template__$
|
|
203
|
+
const __vue_is_functional_template__$C = false;
|
|
204
204
|
/* style inject */
|
|
205
205
|
|
|
206
206
|
/* style inject SSR */
|
|
@@ -209,23 +209,23 @@ __vue_render__$B._withStripped = true;
|
|
|
209
209
|
|
|
210
210
|
|
|
211
211
|
|
|
212
|
-
const __vue_component__$
|
|
213
|
-
{ render: __vue_render__$
|
|
214
|
-
__vue_inject_styles__$
|
|
215
|
-
__vue_script__$
|
|
216
|
-
__vue_scope_id__$
|
|
217
|
-
__vue_is_functional_template__$
|
|
218
|
-
__vue_module_identifier__$
|
|
212
|
+
const __vue_component__$C = /*#__PURE__*/normalizeComponent(
|
|
213
|
+
{ render: __vue_render__$C, staticRenderFns: __vue_staticRenderFns__$C },
|
|
214
|
+
__vue_inject_styles__$C,
|
|
215
|
+
__vue_script__$C,
|
|
216
|
+
__vue_scope_id__$C,
|
|
217
|
+
__vue_is_functional_template__$C,
|
|
218
|
+
__vue_module_identifier__$C,
|
|
219
219
|
false,
|
|
220
220
|
undefined,
|
|
221
221
|
undefined,
|
|
222
222
|
undefined
|
|
223
223
|
);
|
|
224
224
|
|
|
225
|
-
__vue_component__$
|
|
225
|
+
__vue_component__$C.install = Vue => Vue.component(__vue_component__$C.name, __vue_component__$C);
|
|
226
226
|
|
|
227
227
|
//
|
|
228
|
-
var script$
|
|
228
|
+
var script$B = {
|
|
229
229
|
name: 'ele-date',
|
|
230
230
|
model: {
|
|
231
231
|
prop: 'value',
|
|
@@ -345,10 +345,10 @@ function addStyle(id, css) {
|
|
|
345
345
|
}
|
|
346
346
|
|
|
347
347
|
/* script */
|
|
348
|
-
const __vue_script__$
|
|
348
|
+
const __vue_script__$B = script$B;
|
|
349
349
|
|
|
350
350
|
/* template */
|
|
351
|
-
var __vue_render__$
|
|
351
|
+
var __vue_render__$B = function () {
|
|
352
352
|
var _vm = this;
|
|
353
353
|
var _h = _vm.$createElement;
|
|
354
354
|
var _c = _vm._self._c || _h;
|
|
@@ -396,48 +396,48 @@ var __vue_render__$A = function () {
|
|
|
396
396
|
1
|
|
397
397
|
)
|
|
398
398
|
};
|
|
399
|
-
var __vue_staticRenderFns__$
|
|
400
|
-
__vue_render__$
|
|
399
|
+
var __vue_staticRenderFns__$B = [];
|
|
400
|
+
__vue_render__$B._withStripped = true;
|
|
401
401
|
|
|
402
402
|
/* style */
|
|
403
|
-
const __vue_inject_styles__$
|
|
403
|
+
const __vue_inject_styles__$B = function (inject) {
|
|
404
404
|
if (!inject) return
|
|
405
405
|
inject("data-v-0b54504c_0", { source: ".ele-date__wrapper[data-v-0b54504c] {\n width: 100%;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/date/src/index.vue","index.vue"],"names":[],"mappings":"AAuGA;EACA,WAAA;ACtGA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"ele-date__wrapper\">\n <a-date-picker \n style=\"width: 100%;\" \n :mode=\"modeValue\"\n v-if=\"modeValue == 'year'\"\n :open=\"open\"\n :disabled=\"disabled\"\n :value=\"value\"\n :show-time=\"showTime\"\n :show-today=\"showToday\"\n :valueFormat=\"innerValueFormat\"\n @panelChange=\"onPanelChange\"\n @openChange=\"openChange\"\n @change=\"onChange\"\n :format=\"format\">\n </a-date-picker>\n <a-date-picker \n v-else\n style=\"width: 100%;\" \n :open=\"open\"\n :disabled=\"disabled\"\n :value=\"value\"\n :show-time=\"showTime\"\n :show-today=\"showToday\"\n :valueFormat=\"innerValueFormat\"\n @panelChange=\"onPanelChange\"\n @openChange=\"openChange\"\n @change=\"onChange\"\n :format=\"format\">\n </a-date-picker>\n </div>\n</template>\n\n<script>\nimport moment from 'moment'\nexport default {\n name: 'ele-date',\n model: {\n prop: 'value',\n event: 'change'\n },\n props: {\n value: {\n type: [String, Object]\n },\n disabled: {\n type: Boolean,\n default: false\n },\n format: {\n type: String,\n default: 'YYYY/MM/DD'\n },\n mode: {\n type: String\n },\n valueFormat: {\n type: String\n },\n showTime: {\n type: [Boolean, Object],\n default: true\n },\n showToday: {\n type: Boolean,\n default: true\n },\n },\n data () {\n return {\n open: false\n }\n },\n computed: {\n innerValueFormat () {\n if (this.valueFormat) return this.valueFormat\n return this.format\n },\n modeValue () {\n if (this.mode) return this.mode\n if (this.format === 'YYYY') return 'year'\n return 'date'\n }\n },\n methods: {\n onChange (_, dataString) {\n this.$emit('input', dataString)\n this.$emit('change', dataString)\n },\n onPanelChange (value, mode) {\n if (this.modeValue !== 'year') return\n this.$emit('input', moment(value).format(this.format))\n this.$emit('change', moment(value).format(this.format))\n this.open = false\n },\n openChange (open) {\n this.open = open\n }\n }\n}\n</script>\n<style lang=\"scss\" scoped>\n.ele-date__wrapper {\n width: 100%;\n}\n</style>",".ele-date__wrapper {\n width: 100%;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
406
406
|
|
|
407
407
|
};
|
|
408
408
|
/* scoped */
|
|
409
|
-
const __vue_scope_id__$
|
|
409
|
+
const __vue_scope_id__$B = "data-v-0b54504c";
|
|
410
410
|
/* module identifier */
|
|
411
|
-
const __vue_module_identifier__$
|
|
411
|
+
const __vue_module_identifier__$B = undefined;
|
|
412
412
|
/* functional template */
|
|
413
|
-
const __vue_is_functional_template__$
|
|
413
|
+
const __vue_is_functional_template__$B = false;
|
|
414
414
|
/* style inject SSR */
|
|
415
415
|
|
|
416
416
|
/* style inject shadow dom */
|
|
417
417
|
|
|
418
418
|
|
|
419
419
|
|
|
420
|
-
const __vue_component__$
|
|
421
|
-
{ render: __vue_render__$
|
|
422
|
-
__vue_inject_styles__$
|
|
423
|
-
__vue_script__$
|
|
424
|
-
__vue_scope_id__$
|
|
425
|
-
__vue_is_functional_template__$
|
|
426
|
-
__vue_module_identifier__$
|
|
420
|
+
const __vue_component__$B = /*#__PURE__*/normalizeComponent(
|
|
421
|
+
{ render: __vue_render__$B, staticRenderFns: __vue_staticRenderFns__$B },
|
|
422
|
+
__vue_inject_styles__$B,
|
|
423
|
+
__vue_script__$B,
|
|
424
|
+
__vue_scope_id__$B,
|
|
425
|
+
__vue_is_functional_template__$B,
|
|
426
|
+
__vue_module_identifier__$B,
|
|
427
427
|
false,
|
|
428
428
|
createInjector,
|
|
429
429
|
undefined,
|
|
430
430
|
undefined
|
|
431
431
|
);
|
|
432
432
|
|
|
433
|
-
__vue_component__$
|
|
433
|
+
__vue_component__$B.install = Vue => Vue.component(__vue_component__$B.name, __vue_component__$B);
|
|
434
434
|
|
|
435
435
|
//
|
|
436
436
|
//
|
|
437
437
|
//
|
|
438
438
|
//
|
|
439
439
|
|
|
440
|
-
var script$
|
|
440
|
+
var script$A = {
|
|
441
441
|
name: 'ele-input',
|
|
442
442
|
model: {
|
|
443
443
|
prop: 'value',
|
|
@@ -465,10 +465,10 @@ var script$z = {
|
|
|
465
465
|
};
|
|
466
466
|
|
|
467
467
|
/* script */
|
|
468
|
-
const __vue_script__$
|
|
468
|
+
const __vue_script__$A = script$A;
|
|
469
469
|
|
|
470
470
|
/* template */
|
|
471
|
-
var __vue_render__$
|
|
471
|
+
var __vue_render__$A = function () {
|
|
472
472
|
var _vm = this;
|
|
473
473
|
var _h = _vm.$createElement;
|
|
474
474
|
var _c = _vm._self._c || _h;
|
|
@@ -481,44 +481,44 @@ var __vue_render__$z = function () {
|
|
|
481
481
|
on: { change: _vm.onChange },
|
|
482
482
|
})
|
|
483
483
|
};
|
|
484
|
-
var __vue_staticRenderFns__$
|
|
485
|
-
__vue_render__$
|
|
484
|
+
var __vue_staticRenderFns__$A = [];
|
|
485
|
+
__vue_render__$A._withStripped = true;
|
|
486
486
|
|
|
487
487
|
/* style */
|
|
488
|
-
const __vue_inject_styles__$
|
|
488
|
+
const __vue_inject_styles__$A = function (inject) {
|
|
489
489
|
if (!inject) return
|
|
490
490
|
inject("data-v-c04139c8_0", { source: "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n", map: {"version":3,"sources":[],"names":[],"mappings":"","file":"index.vue"}, media: undefined });
|
|
491
491
|
|
|
492
492
|
};
|
|
493
493
|
/* scoped */
|
|
494
|
-
const __vue_scope_id__$
|
|
494
|
+
const __vue_scope_id__$A = "data-v-c04139c8";
|
|
495
495
|
/* module identifier */
|
|
496
|
-
const __vue_module_identifier__$
|
|
496
|
+
const __vue_module_identifier__$A = undefined;
|
|
497
497
|
/* functional template */
|
|
498
|
-
const __vue_is_functional_template__$
|
|
498
|
+
const __vue_is_functional_template__$A = false;
|
|
499
499
|
/* style inject SSR */
|
|
500
500
|
|
|
501
501
|
/* style inject shadow dom */
|
|
502
502
|
|
|
503
503
|
|
|
504
504
|
|
|
505
|
-
const __vue_component__$
|
|
506
|
-
{ render: __vue_render__$
|
|
507
|
-
__vue_inject_styles__$
|
|
508
|
-
__vue_script__$
|
|
509
|
-
__vue_scope_id__$
|
|
510
|
-
__vue_is_functional_template__$
|
|
511
|
-
__vue_module_identifier__$
|
|
505
|
+
const __vue_component__$A = /*#__PURE__*/normalizeComponent(
|
|
506
|
+
{ render: __vue_render__$A, staticRenderFns: __vue_staticRenderFns__$A },
|
|
507
|
+
__vue_inject_styles__$A,
|
|
508
|
+
__vue_script__$A,
|
|
509
|
+
__vue_scope_id__$A,
|
|
510
|
+
__vue_is_functional_template__$A,
|
|
511
|
+
__vue_module_identifier__$A,
|
|
512
512
|
false,
|
|
513
513
|
createInjector,
|
|
514
514
|
undefined,
|
|
515
515
|
undefined
|
|
516
516
|
);
|
|
517
517
|
|
|
518
|
-
__vue_component__$
|
|
518
|
+
__vue_component__$A.install = Vue => Vue.component(__vue_component__$A.name, __vue_component__$A);
|
|
519
519
|
|
|
520
520
|
//
|
|
521
|
-
var script$
|
|
521
|
+
var script$z = {
|
|
522
522
|
name: 'ele-select',
|
|
523
523
|
props: {
|
|
524
524
|
disabled: {
|
|
@@ -603,10 +603,10 @@ var script$y = {
|
|
|
603
603
|
};
|
|
604
604
|
|
|
605
605
|
/* script */
|
|
606
|
-
const __vue_script__$
|
|
606
|
+
const __vue_script__$z = script$z;
|
|
607
607
|
|
|
608
608
|
/* template */
|
|
609
|
-
var __vue_render__$
|
|
609
|
+
var __vue_render__$z = function () {
|
|
610
610
|
var _vm = this;
|
|
611
611
|
var _h = _vm.$createElement;
|
|
612
612
|
var _c = _vm._self._c || _h;
|
|
@@ -627,41 +627,41 @@ var __vue_render__$y = function () {
|
|
|
627
627
|
1
|
|
628
628
|
)
|
|
629
629
|
};
|
|
630
|
-
var __vue_staticRenderFns__$
|
|
631
|
-
__vue_render__$
|
|
630
|
+
var __vue_staticRenderFns__$z = [];
|
|
631
|
+
__vue_render__$z._withStripped = true;
|
|
632
632
|
|
|
633
633
|
/* style */
|
|
634
|
-
const __vue_inject_styles__$
|
|
634
|
+
const __vue_inject_styles__$z = function (inject) {
|
|
635
635
|
if (!inject) return
|
|
636
636
|
inject("data-v-1fbed5ac_0", { source: "\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":";;AAEA,oCAAoC","file":"index.vue"}, media: undefined });
|
|
637
637
|
|
|
638
638
|
};
|
|
639
639
|
/* scoped */
|
|
640
|
-
const __vue_scope_id__$
|
|
640
|
+
const __vue_scope_id__$z = "data-v-1fbed5ac";
|
|
641
641
|
/* module identifier */
|
|
642
|
-
const __vue_module_identifier__$
|
|
642
|
+
const __vue_module_identifier__$z = undefined;
|
|
643
643
|
/* functional template */
|
|
644
|
-
const __vue_is_functional_template__$
|
|
644
|
+
const __vue_is_functional_template__$z = false;
|
|
645
645
|
/* style inject SSR */
|
|
646
646
|
|
|
647
647
|
/* style inject shadow dom */
|
|
648
648
|
|
|
649
649
|
|
|
650
650
|
|
|
651
|
-
const __vue_component__$
|
|
652
|
-
{ render: __vue_render__$
|
|
653
|
-
__vue_inject_styles__$
|
|
654
|
-
__vue_script__$
|
|
655
|
-
__vue_scope_id__$
|
|
656
|
-
__vue_is_functional_template__$
|
|
657
|
-
__vue_module_identifier__$
|
|
651
|
+
const __vue_component__$z = /*#__PURE__*/normalizeComponent(
|
|
652
|
+
{ render: __vue_render__$z, staticRenderFns: __vue_staticRenderFns__$z },
|
|
653
|
+
__vue_inject_styles__$z,
|
|
654
|
+
__vue_script__$z,
|
|
655
|
+
__vue_scope_id__$z,
|
|
656
|
+
__vue_is_functional_template__$z,
|
|
657
|
+
__vue_module_identifier__$z,
|
|
658
658
|
false,
|
|
659
659
|
createInjector,
|
|
660
660
|
undefined,
|
|
661
661
|
undefined
|
|
662
662
|
);
|
|
663
663
|
|
|
664
|
-
__vue_component__$
|
|
664
|
+
__vue_component__$z.install = Vue => Vue.component(__vue_component__$z.name, __vue_component__$z);
|
|
665
665
|
|
|
666
666
|
// Unique ID creation requires a high quality random # generator. In the browser we therefore
|
|
667
667
|
// require the crypto API and do not support built-in fallback to lower quality random number
|
|
@@ -1365,6 +1365,7 @@ const PAGE_STATUS = {
|
|
|
1365
1365
|
const RESERVE_EVENT_NAMES = {
|
|
1366
1366
|
//global event
|
|
1367
1367
|
INIT: 'init',
|
|
1368
|
+
WATCH: 'watch',
|
|
1368
1369
|
//form event
|
|
1369
1370
|
WATCH_FORM_STATUS: 'watch-form-status',
|
|
1370
1371
|
INIT_FORM: 'init-form'
|
|
@@ -1379,7 +1380,7 @@ const parseFieldMap = (fieldMap = {}, dataSource = {}) => {
|
|
|
1379
1380
|
|
|
1380
1381
|
//
|
|
1381
1382
|
const MENU_KEY_NAMESPACE = 'f7b3b8b0-1b7b-11ec-9621-0242ac130002';
|
|
1382
|
-
var script$
|
|
1383
|
+
var script$y = {
|
|
1383
1384
|
props: {
|
|
1384
1385
|
record: {
|
|
1385
1386
|
type: Object
|
|
@@ -1506,10 +1507,10 @@ var script$x = {
|
|
|
1506
1507
|
};
|
|
1507
1508
|
|
|
1508
1509
|
/* script */
|
|
1509
|
-
const __vue_script__$
|
|
1510
|
+
const __vue_script__$y = script$y;
|
|
1510
1511
|
|
|
1511
1512
|
/* template */
|
|
1512
|
-
var __vue_render__$
|
|
1513
|
+
var __vue_render__$y = function () {
|
|
1513
1514
|
var _vm = this;
|
|
1514
1515
|
var _h = _vm.$createElement;
|
|
1515
1516
|
var _c = _vm._self._c || _h;
|
|
@@ -1674,34 +1675,34 @@ var __vue_render__$x = function () {
|
|
|
1674
1675
|
0
|
|
1675
1676
|
)
|
|
1676
1677
|
};
|
|
1677
|
-
var __vue_staticRenderFns__$
|
|
1678
|
-
__vue_render__$
|
|
1678
|
+
var __vue_staticRenderFns__$y = [];
|
|
1679
|
+
__vue_render__$y._withStripped = true;
|
|
1679
1680
|
|
|
1680
1681
|
/* style */
|
|
1681
|
-
const __vue_inject_styles__$
|
|
1682
|
+
const __vue_inject_styles__$y = function (inject) {
|
|
1682
1683
|
if (!inject) return
|
|
1683
1684
|
inject("data-v-3fafa38c_0", { source: ".g-table__action[data-v-3fafa38c] {\n display: flex;\n flex-direction: row;\n}\n.g-table__action .table-action__item[data-v-3fafa38c] {\n font-size: 14px;\n color: #409EFF;\n margin-left: 16px;\n cursor: pointer;\n}\n.g-table__action .table-action__item[data-v-3fafa38c]:first-child {\n margin-left: 0;\n}\n\n/*# sourceMappingURL=action.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/table/src/action.vue","action.vue"],"names":[],"mappings":"AA8JA;EACA,aAAA;EACA,mBAAA;AC7JA;AD8JA;EACA,eAAA;EACA,cAAA;EACA,iBAAA;EACA,eAAA;AC5JA;AD6JA;EACA,cAAA;AC3JA;;AAEA,qCAAqC","file":"action.vue","sourcesContent":["<template>\n <div class=\"g-table__action\">\n <div class=\"table-action__item\" v-for=\"(item, idx) in execOperationExpression(dataSource)\" :key=\"idx\">\n <template v-if=\"item.type == 'text'\">\n <span @click=\"handleClickText(item)\">{{ item.label }}</span>\n </template>\n <template v-else-if=\"item.type == 'confirm'\">\n <div>\n <a-popconfirm :title=\"item.message\" @confirm=\"handleClickConfirm(item)\">\n {{ item.label }}\n </a-popconfirm>\n </div>\n </template>\n <template v-else-if=\"item.type == 'dropdown'\">\n <a-dropdown>\n <a-menu slot=\"overlay\" @click=\"handleDropdownClick\">\n <a-menu-item :key=\"`${item.key || ''}${menuKeyDelimiter}${opt.value || ''}`\" v-for=\"opt in execOperationExpression(item.optionList)\">\n <template v-if=\"opt.type == 'confirm'\">\n <a-popconfirm :title=\"opt.message\" @confirm=\"handleClickConfirm(opt)\">\n {{ opt.label }}\n </a-popconfirm>\n </template>\n <template v-if=\"opt.type == 'modal-confirm'\">\n <div style=\"width: 100%\" @click=\"handleClickModalConfirm(opt)\">{{ opt.label }}</div>\n <ele-modal-confirm v-bind=\"opt.modalConfirm\" v-on=\"$listeners\" v-model=\"showModalConfirm\"></ele-modal-confirm>\n </template>\n <template v-else>\n {{ opt.label }}\n </template>\n </a-menu-item>\n </a-menu>\n <span>{{ item.label }}</span>\n </a-dropdown>\n </template>\n </div>\n </div>\n</template>\n\n<script>\nimport { v5 as uuidv5 } from 'uuid'\nimport { type, route } from '@idooel/shared'\nimport { parse } from '@idooel/expression'\nimport { CONTEXT } from '../../utils'\nconst MENU_KEY_NAMESPACE = 'f7b3b8b0-1b7b-11ec-9621-0242ac130002'\nexport default {\n props: {\n record: {\n type: Object\n },\n dataSource: {\n type: Array,\n default: () => []\n }\n },\n inject: {\n requestTreeData: {\n default: void 0\n },\n requestTableData: {\n default: void 0\n }\n },\n data() {\n return {\n showModalConfirm: false\n }\n },\n provide () {\n return {\n [CONTEXT]: () => {\n return {\n _route: this.$route.query,\n _routeMeta: this.$route.meta,\n exposed: this.builtInMethods,\n ...this.record\n }\n }\n }\n },\n computed: {\n menuKeyDelimiter () {\n return uuidv5('_', MENU_KEY_NAMESPACE)\n },\n builtInMethods () {\n return { \n requestTreeData: this.requestTreeData, \n requestTableData: this.requestTableData,\n closeModalConfirm: this.closeModalConfirm,\n showModalConfirm: this.handleClickModalConfirm\n }\n }\n },\n methods: {\n closeModalConfirm () {\n this.showModalConfirm = false\n },\n handleClickModalConfirm () {\n this.showModalConfirm = true\n },\n execOperationExpression (dataSource = []) {\n const ret = dataSource.map(item => {\n const { show } = item\n if (type.isUndefined(show)) {\n return item\n } else if (type.isBool(show)) {\n if (show) return item\n } else if (type.isStr(show)) {\n const parseRet = parse(show, { \n ...this.record, \n _route: route.searchToQueryParams(window.location.search) \n })\n if (parseRet) return item\n }\n }).filter(item => item)\n return ret\n },\n handleClickConfirm (props) {\n //TODO generate event by special rule\n const { eventName, value, key } = props\n this.$emit(eventName, { \n key: value || key, \n record: this.record,\n builtInMethods: this.builtInMethods,\n exposed: this.builtInMethods\n })\n },\n handleDropdownClick (props) {\n const { key } = props\n const [parent, child] = key.split(this.menuKeyDelimiter)\n if (!parent || !child) {\n throw new Error('key is required')\n }\n const currentDropdown = this.dataSource.find(item => item.key === parent)\n const currentClickTarget = currentDropdown.optionList.find(item => item.value === child)\n const { eventName, type } = currentClickTarget\n //TODO generate event by special rule\n if (type === 'confirm' || type === 'modal-confirm') return\n this.$emit(eventName, { \n key: child, \n record: this.record, \n builtInMethods: this.builtInMethods,\n exposed: this.builtInMethods\n })\n },\n handleClickText (props) {\n const { eventName, key } = props\n this.$emit(eventName, { \n key, \n record: this.record, \n builtInMethods: this.builtInMethods,\n exposed: this.builtInMethods\n })\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.g-table__action {\n display: flex;\n flex-direction: row;\n .table-action__item {\n font-size: 14px;\n color: #409EFF;\n margin-left: 16px;\n cursor: pointer;\n &:first-child {\n margin-left: 0;\n }\n }\n}\n</style>",".g-table__action {\n display: flex;\n flex-direction: row;\n}\n.g-table__action .table-action__item {\n font-size: 14px;\n color: #409EFF;\n margin-left: 16px;\n cursor: pointer;\n}\n.g-table__action .table-action__item:first-child {\n margin-left: 0;\n}\n\n/*# sourceMappingURL=action.vue.map */"]}, media: undefined });
|
|
1684
1685
|
|
|
1685
1686
|
};
|
|
1686
1687
|
/* scoped */
|
|
1687
|
-
const __vue_scope_id__$
|
|
1688
|
+
const __vue_scope_id__$y = "data-v-3fafa38c";
|
|
1688
1689
|
/* module identifier */
|
|
1689
|
-
const __vue_module_identifier__$
|
|
1690
|
+
const __vue_module_identifier__$y = undefined;
|
|
1690
1691
|
/* functional template */
|
|
1691
|
-
const __vue_is_functional_template__$
|
|
1692
|
+
const __vue_is_functional_template__$y = false;
|
|
1692
1693
|
/* style inject SSR */
|
|
1693
1694
|
|
|
1694
1695
|
/* style inject shadow dom */
|
|
1695
1696
|
|
|
1696
1697
|
|
|
1697
1698
|
|
|
1698
|
-
const __vue_component__$
|
|
1699
|
-
{ render: __vue_render__$
|
|
1700
|
-
__vue_inject_styles__$
|
|
1701
|
-
__vue_script__$
|
|
1702
|
-
__vue_scope_id__$
|
|
1703
|
-
__vue_is_functional_template__$
|
|
1704
|
-
__vue_module_identifier__$
|
|
1699
|
+
const __vue_component__$y = /*#__PURE__*/normalizeComponent(
|
|
1700
|
+
{ render: __vue_render__$y, staticRenderFns: __vue_staticRenderFns__$y },
|
|
1701
|
+
__vue_inject_styles__$y,
|
|
1702
|
+
__vue_script__$y,
|
|
1703
|
+
__vue_scope_id__$y,
|
|
1704
|
+
__vue_is_functional_template__$y,
|
|
1705
|
+
__vue_module_identifier__$y,
|
|
1705
1706
|
false,
|
|
1706
1707
|
createInjector,
|
|
1707
1708
|
undefined,
|
|
@@ -1709,10 +1710,10 @@ __vue_render__$x._withStripped = true;
|
|
|
1709
1710
|
);
|
|
1710
1711
|
|
|
1711
1712
|
//
|
|
1712
|
-
var script$
|
|
1713
|
+
var script$x = {
|
|
1713
1714
|
name: 'ele-table',
|
|
1714
1715
|
components: {
|
|
1715
|
-
Actions: __vue_component__$
|
|
1716
|
+
Actions: __vue_component__$y
|
|
1716
1717
|
},
|
|
1717
1718
|
props: {
|
|
1718
1719
|
// ant table wrapper
|
|
@@ -1895,10 +1896,10 @@ var script$w = {
|
|
|
1895
1896
|
};
|
|
1896
1897
|
|
|
1897
1898
|
/* script */
|
|
1898
|
-
const __vue_script__$
|
|
1899
|
+
const __vue_script__$x = script$x;
|
|
1899
1900
|
|
|
1900
1901
|
/* template */
|
|
1901
|
-
var __vue_render__$
|
|
1902
|
+
var __vue_render__$x = function () {
|
|
1902
1903
|
var _vm = this;
|
|
1903
1904
|
var _h = _vm.$createElement;
|
|
1904
1905
|
var _c = _vm._self._c || _h;
|
|
@@ -1964,41 +1965,41 @@ var __vue_render__$w = function () {
|
|
|
1964
1965
|
1
|
|
1965
1966
|
)
|
|
1966
1967
|
};
|
|
1967
|
-
var __vue_staticRenderFns__$
|
|
1968
|
-
__vue_render__$
|
|
1968
|
+
var __vue_staticRenderFns__$x = [];
|
|
1969
|
+
__vue_render__$x._withStripped = true;
|
|
1969
1970
|
|
|
1970
1971
|
/* style */
|
|
1971
|
-
const __vue_inject_styles__$
|
|
1972
|
+
const __vue_inject_styles__$x = function (inject) {
|
|
1972
1973
|
if (!inject) return
|
|
1973
|
-
inject("data-v-5d64823a_0", { source: ".g-table__wrapper[data-v-5d64823a] {\n padding: 16px;\n padding-top: unset;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-spin-nested-loading {\n height: inherit;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-spin-nested-loading .ant-table-fixed-header .ant-table-body-inner {\n overflow: hidden;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-spin-nested-loading .ant-spin-container {\n height: inherit;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-spin-nested-loading .ant-spin-container .ant-table {\n height: inherit;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table {\n border-width: calc(var(--idooel-border-width) * 1px);\n border-style: solid;\n border-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-header .ant-table-fixed {\n /* border-bottom: 2px solid #53a8ff !important; */\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-tbody tr td {\n border-color: var(--idooel-column-border-color);\n border-width: calc(var(--idooel-column-border-width) * 1px);\n border-style: solid;\n border-top: unset;\n border-left: unset;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-fixed-left {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-fixed-left .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-fixed-left .ant-table-body-inner {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-style: solid;\n border-right-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-fixed-left .ant-table-fixed {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-color: var(--idooel-border-color);\n border-right-style: solid;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-fixed-right .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-color: var(--idooel-border-color);\n border-bottom-style: solid;\n}\n.g-table__wrapper[data-v-5d64823a] .ant-table-wrapper .ant-table-fixed-right .ant-table-fixed {\n border-left-width: calc(var(--idooel-border-width) * 1px);\n border-left-style: solid;\n border-left-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-5d64823a] .g-table__row--even {\n background: var(--idooel-row-even-color);\n}\n.g-table__wrapper .g-table__row--odd[data-v-5d64823a] {\n background: var(--idooel-row-odd-color);\n}\n.g-table__wrapper .g-table__pagination[data-v-5d64823a] {\n display: flex;\n flex-direction: row;\n justify-content: end;\n border-width: calc(var(--idooel-border-width) * 1px);\n border-color: var(--idooel-border-color);\n border-style: solid;\n border-top: unset;\n padding-top: 8px;\n padding-bottom: 8px;\n position: relative;\n z-index: 9999;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/table/src/index.vue","index.vue"],"names":[],"mappings":"AAiNA;EAuFA,aAAA;EACA,kBAAA;ACtSA;AD+MA;EACA,eAAA;AC7MA;AD+MA;EACA,gBAAA;AC7MA;ADgNA;EACA,eAAA;AC9MA;AD+MA;EACA,eAAA;AC7MA;AD2NA;EACA,oDAAA;EACA,mBAAA;EACA,wCAAA;ACzNA;AD4NA;EACA,iDAAA;AC1NA;AD+NA;EACA,+CAAA;EACA,2DAAA;EACA,mBAAA;EACA,iBAAA;EACA,kBAAA;AC7NA;ADsOA;EACA,2DAAA;EACA,0BAAA;EACA,+CAAA;ACpOA;ADqOA;EACA,2DAAA;EACA,0BAAA;EACA,+CAAA;ACnOA;ADqOA;EACA,0DAAA;EACA,yBAAA;EACA,8CAAA;ACnOA;ADqOA;EACA,0DAAA;EACA,8CAAA;EACA,yBAAA;ACnOA;ADuOA;EACA,2DAAA;EACA,+CAAA;EACA,0BAAA;ACrOA;AD0OA;EACA,yDAAA;EACA,wBAAA;EACA,6CAAA;ACxOA;AD8OA;EACA,wCAAA;AC5OA;AD8OA;EACA,uCAAA;AC5OA;AD8OA;EACA,aAAA;EACA,mBAAA;EACA,oBAAA;EACA,oDAAA;EACA,wCAAA;EACA,mBAAA;EACA,iBAAA;EACA,gBAAA;EACA,mBAAA;EACA,kBAAA;EACA,aAAA;AC5OA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"g-table__wrapper\" :style=\"{ height: `${height}px` }\">\n <a-table\n :class=\"[isNoData && 'g-table__no-data']\"\n :style=\"{ height: noDataAntTableHeight }\"\n :pagination=\"false\"\n :loading=\"loading\"\n :columns=\"innerColumns\"\n :row-selection=\"rowSelection\"\n :row-class-name=\"setRowClassName\"\n :data-source=\"dataSource\"\n :scroll=\"getScroll\">\n <template slot=\"action\" slot-scope=\"record\">\n <Actions v-on=\"$listeners\" :data-source=\"actions\" :record=\"record\"></Actions>\n </template>\n </a-table>\n <div class=\"g-table__pagination\">\n <a-pagination\n :show-total=\"all => `共 ${all} 条数据`\"\n show-size-changer \n show-quick-jumper\n :pageSize=\"innerPageSize\"\n :current=\"innerCurrentPage\"\n :pageSizeOptions=\"pageSizeOptions\"\n @change=\"onChangePagination\"\n @showSizeChange=\"onShowSizeChange\"\n :total=\"total\">\n </a-pagination>\n </div>\n </div>\n</template>\n\n<script>\nimport Actions from './action.vue'\nexport default {\n name: 'ele-table',\n components: {\n Actions\n },\n props: {\n // ant table wrapper\n height: {\n type: Number\n },\n width: {\n type: Number\n },\n x: {\n type: Number,\n default: 1200\n },\n y: {\n type: Number,\n default: 200\n },\n scroll: {\n type: Object\n },\n rowSelection: {\n type: Object\n },\n actions: {\n type: Array,\n default: () => []\n },\n total: {\n type: Number,\n default: 0\n },\n loading: {\n type: Boolean,\n default: false\n },\n columns: {\n type: Array,\n default: () => []\n },\n dataSource: {\n type: Array,\n default: () => []\n },\n pageSize: {\n type: Number,\n default: 10\n },\n pageSizeOptions: {\n type: Array,\n default: () => ['10', '20', '30', '40']\n }\n },\n data() {\n return {\n tableHeaderHeight: 0,\n paginationHeight: 0,\n innerPageSize: 10,\n innerCurrentPage: 1,\n tableContentHeight: 0,\n obs: [],\n tableTbodyHeight: 0\n }\n },\n computed: {\n innerColumns () {\n return this.columns.filter(col => !Object.keys(col).includes('multiple'))\n },\n isNoData () {\n return !this.dataSource.length\n },\n noDataAntTableHeight () {\n //TODO\n if (this.dataSource.length) {\n // return 'auto'\n return `${this.height - this.paginationHeight - 16}px` \n }\n return `${this.height - this.paginationHeight - 16}px` \n },\n getScrollHeightByHeight () {\n const height = this.height - this.tableHeaderHeight - this.paginationHeight\n if (height > this.tableTbodyHeight) {\n document.querySelector('.ant-table-content') && (document.querySelector('.ant-table-content').style.height = 'inherit')\n document.querySelector('.ant-table-scroll') && (document.querySelector('.ant-table-scroll').style.height = 'inherit')\n document.querySelector('.ant-table-body') && (document.querySelector('.ant-table-body').style.height = 'inherit')\n if (this.tableTbodyHeight > height) {\n document.querySelector('.ant-table-content').style.height = 'auto'\n document.querySelector('.ant-table-scroll').style.height = 'auto'\n document.querySelector('.ant-table-body').style.height = 'auto'\n }\n // 0的时候没有y滚动条\n return 0\n }\n return this.height - this.tableHeaderHeight - this.paginationHeight\n },\n isFlexColumn () {\n return this.columns.every(col => !col.width)\n },\n getScroll () {\n if (this.scroll) {\n return this.scroll\n } else {\n if (this.height) {\n return { x: this.isFlexColumn ? 0 : this.width > this.x ? 0 : this.x, y: this.getScrollHeightByHeight }\n }\n return { x: this.isFlexColumn ? 0 : this.width > this.x ? 0 : this.x, y: this.y }\n }\n }\n },\n watch: {\n pageSize: {\n handler (pageSize) {\n this.innerPageSize = pageSize\n },\n immediate: true\n }\n },\n methods: {\n onShowSizeChange (current, pageSize) {\n this.innerCurrentPage = current\n this.innerPageSize = pageSize\n this.$emit('change-page', current, pageSize)\n },\n setPaginationHeight () {\n this.$nextTick(() => {\n const { height } = document.querySelector('.g-table__pagination').getBoundingClientRect()\n this.paginationHeight = height\n })\n },\n setTableHeaderHeight () {\n this.$nextTick(() => {\n const el = document.querySelector('.ant-table-header')\n if (!el) return\n const { height } = el.getBoundingClientRect()\n this.tableHeaderHeight = height\n })\n },\n setTableTbodyHeight () {\n const el = document.querySelector('.ant-table-tbody')\n const ob = new ResizeObserver((entries => {\n if (this.tableHeaderHeight) return\n for (const _ of entries) {\n requestAnimationFrame(() => {\n const { height } = el.getBoundingClientRect()\n this.tableTbodyHeight = height\n this.setTableHeaderHeight()\n })\n }\n }))\n ob.observe(el)\n this.obs.push(ob)\n },\n setRowClassName (record, idx) {\n return idx % 2 === 0 ? 'g-table__row--even' : 'g-table__row--odd'\n },\n onChangePagination (page, pageSize) {\n this.innerCurrentPage = page\n this.innerPageSize = pageSize\n this.$emit('change-page', page, pageSize)\n }\n },\n mounted() {\n this.setTableTbodyHeight()\n this.setPaginationHeight()\n },\n destroyed () {\n this.obs.forEach(ob => ob.disconnect())\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.g-table__wrapper {\n ::v-deep .ant-spin-nested-loading {\n height: inherit;\n .ant-table-fixed-header {\n .ant-table-body-inner {\n overflow: hidden;\n }\n }\n .ant-spin-container {\n height: inherit;\n .ant-table {\n height: inherit;\n .ant-table-content {\n // height: inherit;\n // .ant-table-scroll {\n // height: inherit;\n // .ant-table-body {\n // height: inherit;\n // }\n // }\n }\n }\n }\n }\n ::v-deep .ant-table-wrapper {\n .ant-table {\n border-width: calc(var(--idooel-border-width) * 1px);\n border-style: solid;\n border-color: var(--idooel-border-color);\n }\n .ant-table-header {\n .ant-table-fixed {\n /* border-bottom: 2px solid #53a8ff !important; */\n }\n }\n .ant-table-tbody {\n tr {\n td {\n border-color: var(--idooel-column-border-color);\n border-width: calc(var(--idooel-column-border-width) * 1px);;\n border-style: solid;\n border-top: unset;\n border-left: unset;\n }\n }\n }\n .ant-table-body {\n // border-top-width: calc(var(--idooel-border-width) * 1px);\n // border-top-style: solid;\n // border-top-color: var(--idooel-border-color);\n }\n .ant-table-fixed-left {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n }\n .ant-table-body-inner {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-style: solid;\n border-right-color: var(--idooel-border-color);\n }\n .ant-table-fixed {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-color: var(--idooel-border-color);\n border-right-style: solid;\n }\n }\n .ant-table-fixed-right {\n .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-color: var(--idooel-border-color);\n border-bottom-style: solid;\n }\n // border-bottom-width: calc(var(--idooel-border-width) * 1px);\n // border-bottom-style: solid;\n // border-bottom-color: var(--idooel-border-color);\n .ant-table-fixed {\n border-left-width: calc(var(--idooel-border-width) * 1px);\n border-left-style: solid;\n border-left-color: var(--idooel-border-color);\n }\n }\n }\n padding: 16px;\n padding-top: unset;\n ::v-deep .g-table__row--even {\n background: var(--idooel-row-even-color);\n }\n .g-table__row--odd {\n background: var(--idooel-row-odd-color);\n }\n .g-table__pagination {\n display: flex;\n flex-direction: row;\n justify-content: end;\n border-width: calc(var(--idooel-border-width) * 1px);\n border-color: var(--idooel-border-color);\n border-style: solid;\n border-top: unset;\n padding-top: 8px;\n padding-bottom: 8px;\n position: relative;\n z-index: 9999;\n }\n}\n</style>",".g-table__wrapper {\n padding: 16px;\n padding-top: unset;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading {\n height: inherit;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading .ant-table-fixed-header .ant-table-body-inner {\n overflow: hidden;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading .ant-spin-container {\n height: inherit;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading .ant-spin-container .ant-table {\n height: inherit;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table {\n border-width: calc(var(--idooel-border-width) * 1px);\n border-style: solid;\n border-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-header .ant-table-fixed {\n /* border-bottom: 2px solid #53a8ff !important; */\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-tbody tr td {\n border-color: var(--idooel-column-border-color);\n border-width: calc(var(--idooel-column-border-width) * 1px);\n border-style: solid;\n border-top: unset;\n border-left: unset;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left .ant-table-body-inner {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-style: solid;\n border-right-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left .ant-table-fixed {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-color: var(--idooel-border-color);\n border-right-style: solid;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-right .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-color: var(--idooel-border-color);\n border-bottom-style: solid;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-right .ant-table-fixed {\n border-left-width: calc(var(--idooel-border-width) * 1px);\n border-left-style: solid;\n border-left-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .g-table__row--even {\n background: var(--idooel-row-even-color);\n}\n.g-table__wrapper .g-table__row--odd {\n background: var(--idooel-row-odd-color);\n}\n.g-table__wrapper .g-table__pagination {\n display: flex;\n flex-direction: row;\n justify-content: end;\n border-width: calc(var(--idooel-border-width) * 1px);\n border-color: var(--idooel-border-color);\n border-style: solid;\n border-top: unset;\n padding-top: 8px;\n padding-bottom: 8px;\n position: relative;\n z-index: 9999;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
1974
|
+
inject("data-v-1de938d1_0", { source: ".g-table__wrapper[data-v-1de938d1] {\n padding: 16px;\n padding-top: unset;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-spin-nested-loading {\n height: inherit;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-spin-nested-loading .ant-table-fixed-header .ant-table-body-inner {\n overflow: hidden;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-spin-nested-loading .ant-spin-container {\n height: inherit;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-spin-nested-loading .ant-spin-container .ant-table {\n height: inherit;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table {\n border-width: calc(var(--idooel-border-width) * 1px);\n border-style: solid;\n border-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-header .ant-table-fixed {\n /* border-bottom: 2px solid #53a8ff !important; */\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-tbody tr td {\n border-color: var(--idooel-column-border-color);\n border-width: calc(var(--idooel-column-border-width) * 1px);\n border-style: solid;\n border-top: unset;\n border-left: unset;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-fixed-left {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-fixed-left .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-fixed-left .ant-table-body-inner {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-style: solid;\n border-right-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-fixed-left .ant-table-fixed {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-color: var(--idooel-border-color);\n border-right-style: solid;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-fixed-right .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-color: var(--idooel-border-color);\n border-bottom-style: solid;\n}\n.g-table__wrapper[data-v-1de938d1] .ant-table-wrapper .ant-table-fixed-right .ant-table-fixed {\n border-left-width: calc(var(--idooel-border-width) * 1px);\n border-left-style: solid;\n border-left-color: var(--idooel-border-color);\n}\n.g-table__wrapper[data-v-1de938d1] .g-table__row--even {\n background: var(--idooel-row-even-color);\n}\n.g-table__wrapper .g-table__row--odd[data-v-1de938d1] {\n background: var(--idooel-row-odd-color);\n}\n.g-table__wrapper .g-table__pagination[data-v-1de938d1] {\n display: flex;\n flex-direction: row;\n justify-content: end;\n border-width: calc(var(--idooel-border-width) * 1px);\n border-color: var(--idooel-border-color);\n border-style: solid;\n border-top: unset;\n padding-top: 8px;\n padding-bottom: 8px;\n position: relative;\n z-index: 999;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/table/src/index.vue","index.vue"],"names":[],"mappings":"AAiNA;EAuFA,aAAA;EACA,kBAAA;ACtSA;AD+MA;EACA,eAAA;AC7MA;AD+MA;EACA,gBAAA;AC7MA;ADgNA;EACA,eAAA;AC9MA;AD+MA;EACA,eAAA;AC7MA;AD2NA;EACA,oDAAA;EACA,mBAAA;EACA,wCAAA;ACzNA;AD4NA;EACA,iDAAA;AC1NA;AD+NA;EACA,+CAAA;EACA,2DAAA;EACA,mBAAA;EACA,iBAAA;EACA,kBAAA;AC7NA;ADsOA;EACA,2DAAA;EACA,0BAAA;EACA,+CAAA;ACpOA;ADqOA;EACA,2DAAA;EACA,0BAAA;EACA,+CAAA;ACnOA;ADqOA;EACA,0DAAA;EACA,yBAAA;EACA,8CAAA;ACnOA;ADqOA;EACA,0DAAA;EACA,8CAAA;EACA,yBAAA;ACnOA;ADuOA;EACA,2DAAA;EACA,+CAAA;EACA,0BAAA;ACrOA;AD0OA;EACA,yDAAA;EACA,wBAAA;EACA,6CAAA;ACxOA;AD8OA;EACA,wCAAA;AC5OA;AD8OA;EACA,uCAAA;AC5OA;AD8OA;EACA,aAAA;EACA,mBAAA;EACA,oBAAA;EACA,oDAAA;EACA,wCAAA;EACA,mBAAA;EACA,iBAAA;EACA,gBAAA;EACA,mBAAA;EACA,kBAAA;EACA,YAAA;AC5OA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"g-table__wrapper\" :style=\"{ height: `${height}px` }\">\n <a-table\n :class=\"[isNoData && 'g-table__no-data']\"\n :style=\"{ height: noDataAntTableHeight }\"\n :pagination=\"false\"\n :loading=\"loading\"\n :columns=\"innerColumns\"\n :row-selection=\"rowSelection\"\n :row-class-name=\"setRowClassName\"\n :data-source=\"dataSource\"\n :scroll=\"getScroll\">\n <template slot=\"action\" slot-scope=\"record\">\n <Actions v-on=\"$listeners\" :data-source=\"actions\" :record=\"record\"></Actions>\n </template>\n </a-table>\n <div class=\"g-table__pagination\">\n <a-pagination\n :show-total=\"all => `共 ${all} 条数据`\"\n show-size-changer \n show-quick-jumper\n :pageSize=\"innerPageSize\"\n :current=\"innerCurrentPage\"\n :pageSizeOptions=\"pageSizeOptions\"\n @change=\"onChangePagination\"\n @showSizeChange=\"onShowSizeChange\"\n :total=\"total\">\n </a-pagination>\n </div>\n </div>\n</template>\n\n<script>\nimport Actions from './action.vue'\nexport default {\n name: 'ele-table',\n components: {\n Actions\n },\n props: {\n // ant table wrapper\n height: {\n type: Number\n },\n width: {\n type: Number\n },\n x: {\n type: Number,\n default: 1200\n },\n y: {\n type: Number,\n default: 200\n },\n scroll: {\n type: Object\n },\n rowSelection: {\n type: Object\n },\n actions: {\n type: Array,\n default: () => []\n },\n total: {\n type: Number,\n default: 0\n },\n loading: {\n type: Boolean,\n default: false\n },\n columns: {\n type: Array,\n default: () => []\n },\n dataSource: {\n type: Array,\n default: () => []\n },\n pageSize: {\n type: Number,\n default: 10\n },\n pageSizeOptions: {\n type: Array,\n default: () => ['10', '20', '30', '40']\n }\n },\n data() {\n return {\n tableHeaderHeight: 0,\n paginationHeight: 0,\n innerPageSize: 10,\n innerCurrentPage: 1,\n tableContentHeight: 0,\n obs: [],\n tableTbodyHeight: 0\n }\n },\n computed: {\n innerColumns () {\n return this.columns.filter(col => !Object.keys(col).includes('multiple'))\n },\n isNoData () {\n return !this.dataSource.length\n },\n noDataAntTableHeight () {\n //TODO\n if (this.dataSource.length) {\n // return 'auto'\n return `${this.height - this.paginationHeight - 16}px` \n }\n return `${this.height - this.paginationHeight - 16}px` \n },\n getScrollHeightByHeight () {\n const height = this.height - this.tableHeaderHeight - this.paginationHeight\n if (height > this.tableTbodyHeight) {\n document.querySelector('.ant-table-content') && (document.querySelector('.ant-table-content').style.height = 'inherit')\n document.querySelector('.ant-table-scroll') && (document.querySelector('.ant-table-scroll').style.height = 'inherit')\n document.querySelector('.ant-table-body') && (document.querySelector('.ant-table-body').style.height = 'inherit')\n if (this.tableTbodyHeight > height) {\n document.querySelector('.ant-table-content').style.height = 'auto'\n document.querySelector('.ant-table-scroll').style.height = 'auto'\n document.querySelector('.ant-table-body').style.height = 'auto'\n }\n // 0的时候没有y滚动条\n return 0\n }\n return this.height - this.tableHeaderHeight - this.paginationHeight\n },\n isFlexColumn () {\n return this.columns.every(col => !col.width)\n },\n getScroll () {\n if (this.scroll) {\n return this.scroll\n } else {\n if (this.height) {\n return { x: this.isFlexColumn ? 0 : this.width > this.x ? 0 : this.x, y: this.getScrollHeightByHeight }\n }\n return { x: this.isFlexColumn ? 0 : this.width > this.x ? 0 : this.x, y: this.y }\n }\n }\n },\n watch: {\n pageSize: {\n handler (pageSize) {\n this.innerPageSize = pageSize\n },\n immediate: true\n }\n },\n methods: {\n onShowSizeChange (current, pageSize) {\n this.innerCurrentPage = current\n this.innerPageSize = pageSize\n this.$emit('change-page', current, pageSize)\n },\n setPaginationHeight () {\n this.$nextTick(() => {\n const { height } = document.querySelector('.g-table__pagination').getBoundingClientRect()\n this.paginationHeight = height\n })\n },\n setTableHeaderHeight () {\n this.$nextTick(() => {\n const el = document.querySelector('.ant-table-header')\n if (!el) return\n const { height } = el.getBoundingClientRect()\n this.tableHeaderHeight = height\n })\n },\n setTableTbodyHeight () {\n const el = document.querySelector('.ant-table-tbody')\n const ob = new ResizeObserver((entries => {\n if (this.tableHeaderHeight) return\n for (const _ of entries) {\n requestAnimationFrame(() => {\n const { height } = el.getBoundingClientRect()\n this.tableTbodyHeight = height\n this.setTableHeaderHeight()\n })\n }\n }))\n ob.observe(el)\n this.obs.push(ob)\n },\n setRowClassName (record, idx) {\n return idx % 2 === 0 ? 'g-table__row--even' : 'g-table__row--odd'\n },\n onChangePagination (page, pageSize) {\n this.innerCurrentPage = page\n this.innerPageSize = pageSize\n this.$emit('change-page', page, pageSize)\n }\n },\n mounted() {\n this.setTableTbodyHeight()\n this.setPaginationHeight()\n },\n destroyed () {\n this.obs.forEach(ob => ob.disconnect())\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.g-table__wrapper {\n ::v-deep .ant-spin-nested-loading {\n height: inherit;\n .ant-table-fixed-header {\n .ant-table-body-inner {\n overflow: hidden;\n }\n }\n .ant-spin-container {\n height: inherit;\n .ant-table {\n height: inherit;\n .ant-table-content {\n // height: inherit;\n // .ant-table-scroll {\n // height: inherit;\n // .ant-table-body {\n // height: inherit;\n // }\n // }\n }\n }\n }\n }\n ::v-deep .ant-table-wrapper {\n .ant-table {\n border-width: calc(var(--idooel-border-width) * 1px);\n border-style: solid;\n border-color: var(--idooel-border-color);\n }\n .ant-table-header {\n .ant-table-fixed {\n /* border-bottom: 2px solid #53a8ff !important; */\n }\n }\n .ant-table-tbody {\n tr {\n td {\n border-color: var(--idooel-column-border-color);\n border-width: calc(var(--idooel-column-border-width) * 1px);;\n border-style: solid;\n border-top: unset;\n border-left: unset;\n }\n }\n }\n .ant-table-body {\n // border-top-width: calc(var(--idooel-border-width) * 1px);\n // border-top-style: solid;\n // border-top-color: var(--idooel-border-color);\n }\n .ant-table-fixed-left {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n }\n .ant-table-body-inner {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-style: solid;\n border-right-color: var(--idooel-border-color);\n }\n .ant-table-fixed {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-color: var(--idooel-border-color);\n border-right-style: solid;\n }\n }\n .ant-table-fixed-right {\n .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-color: var(--idooel-border-color);\n border-bottom-style: solid;\n }\n // border-bottom-width: calc(var(--idooel-border-width) * 1px);\n // border-bottom-style: solid;\n // border-bottom-color: var(--idooel-border-color);\n .ant-table-fixed {\n border-left-width: calc(var(--idooel-border-width) * 1px);\n border-left-style: solid;\n border-left-color: var(--idooel-border-color);\n }\n }\n }\n padding: 16px;\n padding-top: unset;\n ::v-deep .g-table__row--even {\n background: var(--idooel-row-even-color);\n }\n .g-table__row--odd {\n background: var(--idooel-row-odd-color);\n }\n .g-table__pagination {\n display: flex;\n flex-direction: row;\n justify-content: end;\n border-width: calc(var(--idooel-border-width) * 1px);\n border-color: var(--idooel-border-color);\n border-style: solid;\n border-top: unset;\n padding-top: 8px;\n padding-bottom: 8px;\n position: relative;\n z-index: 999;\n }\n}\n</style>",".g-table__wrapper {\n padding: 16px;\n padding-top: unset;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading {\n height: inherit;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading .ant-table-fixed-header .ant-table-body-inner {\n overflow: hidden;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading .ant-spin-container {\n height: inherit;\n}\n.g-table__wrapper ::v-deep .ant-spin-nested-loading .ant-spin-container .ant-table {\n height: inherit;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table {\n border-width: calc(var(--idooel-border-width) * 1px);\n border-style: solid;\n border-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-header .ant-table-fixed {\n /* border-bottom: 2px solid #53a8ff !important; */\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-tbody tr td {\n border-color: var(--idooel-column-border-color);\n border-width: calc(var(--idooel-column-border-width) * 1px);\n border-style: solid;\n border-top: unset;\n border-left: unset;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-style: solid;\n border-bottom-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left .ant-table-body-inner {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-style: solid;\n border-right-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-left .ant-table-fixed {\n border-right-width: calc(var(--idooel-border-width) * 1px);\n border-right-color: var(--idooel-border-color);\n border-right-style: solid;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-right .ant-table-header {\n border-bottom-width: calc(var(--idooel-border-width) * 1px);\n border-bottom-color: var(--idooel-border-color);\n border-bottom-style: solid;\n}\n.g-table__wrapper ::v-deep .ant-table-wrapper .ant-table-fixed-right .ant-table-fixed {\n border-left-width: calc(var(--idooel-border-width) * 1px);\n border-left-style: solid;\n border-left-color: var(--idooel-border-color);\n}\n.g-table__wrapper ::v-deep .g-table__row--even {\n background: var(--idooel-row-even-color);\n}\n.g-table__wrapper .g-table__row--odd {\n background: var(--idooel-row-odd-color);\n}\n.g-table__wrapper .g-table__pagination {\n display: flex;\n flex-direction: row;\n justify-content: end;\n border-width: calc(var(--idooel-border-width) * 1px);\n border-color: var(--idooel-border-color);\n border-style: solid;\n border-top: unset;\n padding-top: 8px;\n padding-bottom: 8px;\n position: relative;\n z-index: 999;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
1974
1975
|
|
|
1975
1976
|
};
|
|
1976
1977
|
/* scoped */
|
|
1977
|
-
const __vue_scope_id__$
|
|
1978
|
+
const __vue_scope_id__$x = "data-v-1de938d1";
|
|
1978
1979
|
/* module identifier */
|
|
1979
|
-
const __vue_module_identifier__$
|
|
1980
|
+
const __vue_module_identifier__$x = undefined;
|
|
1980
1981
|
/* functional template */
|
|
1981
|
-
const __vue_is_functional_template__$
|
|
1982
|
+
const __vue_is_functional_template__$x = false;
|
|
1982
1983
|
/* style inject SSR */
|
|
1983
1984
|
|
|
1984
1985
|
/* style inject shadow dom */
|
|
1985
1986
|
|
|
1986
1987
|
|
|
1987
1988
|
|
|
1988
|
-
const __vue_component__$
|
|
1989
|
-
{ render: __vue_render__$
|
|
1990
|
-
__vue_inject_styles__$
|
|
1991
|
-
__vue_script__$
|
|
1992
|
-
__vue_scope_id__$
|
|
1993
|
-
__vue_is_functional_template__$
|
|
1994
|
-
__vue_module_identifier__$
|
|
1989
|
+
const __vue_component__$x = /*#__PURE__*/normalizeComponent(
|
|
1990
|
+
{ render: __vue_render__$x, staticRenderFns: __vue_staticRenderFns__$x },
|
|
1991
|
+
__vue_inject_styles__$x,
|
|
1992
|
+
__vue_script__$x,
|
|
1993
|
+
__vue_scope_id__$x,
|
|
1994
|
+
__vue_is_functional_template__$x,
|
|
1995
|
+
__vue_module_identifier__$x,
|
|
1995
1996
|
false,
|
|
1996
1997
|
createInjector,
|
|
1997
1998
|
undefined,
|
|
1998
1999
|
undefined
|
|
1999
2000
|
);
|
|
2000
2001
|
|
|
2001
|
-
__vue_component__$
|
|
2002
|
+
__vue_component__$x.install = Vue => Vue.component(__vue_component__$x.name, __vue_component__$x);
|
|
2002
2003
|
|
|
2003
2004
|
//
|
|
2004
2005
|
//
|
|
@@ -2028,7 +2029,7 @@ __vue_component__$w.install = Vue => Vue.component(__vue_component__$w.name, __v
|
|
|
2028
2029
|
//
|
|
2029
2030
|
//
|
|
2030
2031
|
|
|
2031
|
-
var script$
|
|
2032
|
+
var script$w = {
|
|
2032
2033
|
name: 'ele-tree',
|
|
2033
2034
|
props: {
|
|
2034
2035
|
treeData: {
|
|
@@ -2089,10 +2090,10 @@ var script$v = {
|
|
|
2089
2090
|
};
|
|
2090
2091
|
|
|
2091
2092
|
/* script */
|
|
2092
|
-
const __vue_script__$
|
|
2093
|
+
const __vue_script__$w = script$w;
|
|
2093
2094
|
|
|
2094
2095
|
/* template */
|
|
2095
|
-
var __vue_render__$
|
|
2096
|
+
var __vue_render__$w = function () {
|
|
2096
2097
|
var _vm = this;
|
|
2097
2098
|
var _h = _vm.$createElement;
|
|
2098
2099
|
var _c = _vm._self._c || _h;
|
|
@@ -2163,49 +2164,53 @@ var __vue_render__$v = function () {
|
|
|
2163
2164
|
1
|
|
2164
2165
|
)
|
|
2165
2166
|
};
|
|
2166
|
-
var __vue_staticRenderFns__$
|
|
2167
|
-
__vue_render__$
|
|
2167
|
+
var __vue_staticRenderFns__$w = [];
|
|
2168
|
+
__vue_render__$w._withStripped = true;
|
|
2168
2169
|
|
|
2169
2170
|
/* style */
|
|
2170
|
-
const __vue_inject_styles__$
|
|
2171
|
+
const __vue_inject_styles__$w = function (inject) {
|
|
2171
2172
|
if (!inject) return
|
|
2172
2173
|
inject("data-v-a7a27de8_0", { source: ".g-tree__wrapper[data-v-a7a27de8] {\n overflow: hidden;\n}\n.g-tree__wrapper[data-v-a7a27de8] .ant-tree .ant-tree-node-content-wrapper {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n}\n.g-tree__wrapper[data-v-a7a27de8] .ant-tree .ant-tree-node-selected {\n color: #fff;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/tree/src/index.vue","index.vue"],"names":[],"mappings":"AAwFA;EACA,gBAAA;ACvFA;ADyFA;EACA,uBAAA;EACA,gBAAA;EACA,mBAAA;ACvFA;ADyFA;EACA,WAAA;ACvFA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"g-tree__wrapper\">\n <a-tree\n v-if=\"innerTreeData.length\"\n :tree-data=\"innerTreeData\"\n :checkable=\"checkable\"\n @select=\"selectTreeNode\"\n @check=\"checkTreeNode\"\n :replaceFields=\"replaceFields\"\n :default-expanded-keys=\"defaultExpandedKeys\"\n :default-selected-keys=\"defaultSelectedKeys\"\n :show-line=\"showLine\"\n blockNode \n :show-icon=\"showIcon\">\n <a-icon v-if=\"switcherIcon\" slot=\"switcherIcon\" :type=\"switcherIcon\" />\n <template #title=\"{ title }\">\n <span :title=\"title\" class=\"tree-node__title\">\n {{ title }}\n </span>\n </template>\n <template slot=\"custom\" slot-scope=\"{ scopedSlots }\">\n <a-icon :type=\"scopedSlots.iconName\"></a-icon>\n </template>\n </a-tree>\n </div>\n</template>\n\n<script>\nexport default {\n name: 'ele-tree',\n props: {\n treeData: {\n type: Array,\n default: () => []\n },\n showLine: {\n type: Boolean,\n default: false\n },\n switcherIcon: {\n type: String\n },\n checkable: {\n type: Boolean,\n default: false\n },\n replaceFields: {\n type: Object,\n default: () => ({\n title: 'title',\n key: 'id',\n children: 'children'\n })\n },\n defaultExpandedKeys: {\n type: Array\n },\n defaultSelectedKeys: {\n type: Array\n },\n showIcon: {\n type: Boolean,\n default: true\n }\n },\n data () {\n return {}\n },\n computed: {\n innerTreeData () {\n return this.treeData\n }\n },\n methods: {\n checkTreeNode (checkedKeys, e) {\n const { checkedNodes } = e\n const nodeDatas = checkedNodes.map(item => item.data.props.dataRef)\n this.$emit('check', checkedKeys, nodeDatas)\n },\n refreshTreeStatus (props = {}) {},\n selectTreeNode (selectedKeys, e) {\n this.$emit('select', selectedKeys, e)\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.g-tree__wrapper {\n overflow: hidden;\n ::v-deep .ant-tree {\n .ant-tree-node-content-wrapper {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n .ant-tree-node-selected {\n color: #fff;\n }\n }\n}\n</style>",".g-tree__wrapper {\n overflow: hidden;\n}\n.g-tree__wrapper ::v-deep .ant-tree .ant-tree-node-content-wrapper {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n}\n.g-tree__wrapper ::v-deep .ant-tree .ant-tree-node-selected {\n color: #fff;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
2173
2174
|
|
|
2174
2175
|
};
|
|
2175
2176
|
/* scoped */
|
|
2176
|
-
const __vue_scope_id__$
|
|
2177
|
+
const __vue_scope_id__$w = "data-v-a7a27de8";
|
|
2177
2178
|
/* module identifier */
|
|
2178
|
-
const __vue_module_identifier__$
|
|
2179
|
+
const __vue_module_identifier__$w = undefined;
|
|
2179
2180
|
/* functional template */
|
|
2180
|
-
const __vue_is_functional_template__$
|
|
2181
|
+
const __vue_is_functional_template__$w = false;
|
|
2181
2182
|
/* style inject SSR */
|
|
2182
2183
|
|
|
2183
2184
|
/* style inject shadow dom */
|
|
2184
2185
|
|
|
2185
2186
|
|
|
2186
2187
|
|
|
2187
|
-
const __vue_component__$
|
|
2188
|
-
{ render: __vue_render__$
|
|
2189
|
-
__vue_inject_styles__$
|
|
2190
|
-
__vue_script__$
|
|
2191
|
-
__vue_scope_id__$
|
|
2192
|
-
__vue_is_functional_template__$
|
|
2193
|
-
__vue_module_identifier__$
|
|
2188
|
+
const __vue_component__$w = /*#__PURE__*/normalizeComponent(
|
|
2189
|
+
{ render: __vue_render__$w, staticRenderFns: __vue_staticRenderFns__$w },
|
|
2190
|
+
__vue_inject_styles__$w,
|
|
2191
|
+
__vue_script__$w,
|
|
2192
|
+
__vue_scope_id__$w,
|
|
2193
|
+
__vue_is_functional_template__$w,
|
|
2194
|
+
__vue_module_identifier__$w,
|
|
2194
2195
|
false,
|
|
2195
2196
|
createInjector,
|
|
2196
2197
|
undefined,
|
|
2197
2198
|
undefined
|
|
2198
2199
|
);
|
|
2199
2200
|
|
|
2200
|
-
__vue_component__$
|
|
2201
|
+
__vue_component__$w.install = Vue => Vue.component(__vue_component__$w.name, __vue_component__$w);
|
|
2201
2202
|
|
|
2202
2203
|
//
|
|
2203
|
-
var script$
|
|
2204
|
+
var script$v = {
|
|
2204
2205
|
name: 'ele-tree-table-model',
|
|
2205
2206
|
props: {
|
|
2206
2207
|
title: {
|
|
2207
2208
|
type: [Object, String]
|
|
2208
2209
|
},
|
|
2210
|
+
overHeight: {
|
|
2211
|
+
type: Number,
|
|
2212
|
+
default: 0
|
|
2213
|
+
},
|
|
2209
2214
|
treeMeta: {
|
|
2210
2215
|
type: Object,
|
|
2211
2216
|
default: () => ({})
|
|
@@ -2544,8 +2549,10 @@ var script$u = {
|
|
|
2544
2549
|
onChangeTableSelection(_, selectedRows) {
|
|
2545
2550
|
if (this.currentTableMode === 'radio') {
|
|
2546
2551
|
this.currentTableSelection = selectedRows[0];
|
|
2552
|
+
this.$emit('on-change-table-selection', this.currentTableSelection);
|
|
2547
2553
|
} else {
|
|
2548
2554
|
this.currentTableSelection = selectedRows;
|
|
2555
|
+
this.$emit('on-change-table-selection', this.currentTableSelection);
|
|
2549
2556
|
}
|
|
2550
2557
|
},
|
|
2551
2558
|
[BUILT_IN_EVENT_NAMES.EDIT]() {
|
|
@@ -2634,6 +2641,9 @@ var script$u = {
|
|
|
2634
2641
|
currentPage: 1,
|
|
2635
2642
|
pageSize
|
|
2636
2643
|
}, props);
|
|
2644
|
+
this.$emit(RESERVE_EVENT_NAMES.WATCH, {
|
|
2645
|
+
...this.exposed
|
|
2646
|
+
});
|
|
2637
2647
|
this.loading = true;
|
|
2638
2648
|
const ret = await net[requestType.toLowerCase()](url, this.tableQuerys).then(resp => {
|
|
2639
2649
|
const {
|
|
@@ -2663,7 +2673,7 @@ var script$u = {
|
|
|
2663
2673
|
width
|
|
2664
2674
|
} = tableRef.$el.getBoundingClientRect();
|
|
2665
2675
|
this.tableWidth = width;
|
|
2666
|
-
this.tableHeight = currentViewportHeight - tableToTop;
|
|
2676
|
+
this.tableHeight = currentViewportHeight - tableToTop - this.overHeight;
|
|
2667
2677
|
},
|
|
2668
2678
|
calculateTreeHeight() {
|
|
2669
2679
|
if (!this.showTree) return;
|
|
@@ -2694,10 +2704,10 @@ var script$u = {
|
|
|
2694
2704
|
};
|
|
2695
2705
|
|
|
2696
2706
|
/* script */
|
|
2697
|
-
const __vue_script__$
|
|
2707
|
+
const __vue_script__$v = script$v;
|
|
2698
2708
|
|
|
2699
2709
|
/* template */
|
|
2700
|
-
var __vue_render__$
|
|
2710
|
+
var __vue_render__$v = function () {
|
|
2701
2711
|
var _vm = this;
|
|
2702
2712
|
var _h = _vm.$createElement;
|
|
2703
2713
|
var _c = _vm._self._c || _h;
|
|
@@ -2852,34 +2862,34 @@ var __vue_render__$u = function () {
|
|
|
2852
2862
|
1
|
|
2853
2863
|
)
|
|
2854
2864
|
};
|
|
2855
|
-
var __vue_staticRenderFns__$
|
|
2856
|
-
__vue_render__$
|
|
2865
|
+
var __vue_staticRenderFns__$v = [];
|
|
2866
|
+
__vue_render__$v._withStripped = true;
|
|
2857
2867
|
|
|
2858
2868
|
/* style */
|
|
2859
|
-
const __vue_inject_styles__$
|
|
2869
|
+
const __vue_inject_styles__$v = function (inject) {
|
|
2860
2870
|
if (!inject) return
|
|
2861
|
-
inject("data-v-1d4ea815_0", { source: ".ele.model__tree-table[data-v-1d4ea815] {\n background: transparent;\n display: flex;\n flex-direction: row;\n width: 100%;\n}\n.ele.model__tree-table .model__tree-table--container .model__tree--wrapper[data-v-1d4ea815] {\n width: 240px;\n background: #fff;\n flex-shrink: 0;\n padding: 16px;\n box-sizing: border-box;\n margin-right: 16px;\n overflow-y: auto;\n}\n.ele.model__tree-table .model__table--container[data-v-1d4ea815] {\n width: 100%;\n min-width: 0;\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--bar[data-v-1d4ea815] {\n width: 100%;\n height: 8px;\n background: var(--idooel-primary-color);\n border-top-left-radius: 4px;\n border-top-right-radius: 4px;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--text[data-v-1d4ea815] {\n text-align: left;\n padding: 16px;\n font-size: 16px;\n font-weight: bold;\n background: #fff;\n border-bottom: 1px solid;\n border-color: var(--idoole-black-016);\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper[data-v-1d4ea815] {\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .button-row__area[data-v-1d4ea815] {\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n padding-top: 16px;\n padding-bottom: 8px;\n padding-right: 16px;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .g-table__wrapper .fsm[data-v-1d4ea815] {\n cursor: pointer;\n color: var(--idooel-primary-color);\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/models/tree-table-model/src/index.vue","index.vue"],"names":[],"mappings":"AA4cA;EACA,uBAAA;EACA,aAAA;EACA,mBAAA;EACA,WAAA;AC3cA;AD6cA;EACA,YAAA;EACA,gBAAA;EACA,cAAA;EACA,aAAA;EACA,sBAAA;EACA,kBAAA;EACA,gBAAA;AC3cA;AD8cA;EACA,WAAA;EACA,YAAA;EACA,gBAAA;AC5cA;AD8cA;EACA,WAAA;EACA,WAAA;EACA,uCAAA;EACA,2BAAA;EACA,4BAAA;AC5cA;AD8cA;EACA,gBAAA;EACA,aAAA;EACA,eAAA;EACA,iBAAA;EACA,gBAAA;EACA,wBAAA;EACA,qCAAA;AC5cA;AD+cA;EACA,gBAAA;AC7cA;AD8cA;EACA,WAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,8BAAA;EACA,iBAAA;EACA,mBAAA;EACA,mBAAA;AC5cA;AD+cA;EACA,eAAA;EACA,kCAAA;AC7cA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <section class=\"ele model__tree-table\">\n <section class=\"model__tree-table--container\" v-if=\"showTree\">\n <div class=\"model__tree--title\"></div>\n <section :ref=\"modelTreeWrapper\" class=\"model__tree--wrapper\" :style=\"{height: `${treeWrapperHeight}px`}\">\n <ele-tree\n :tree-data=\"treeData\"\n :defaultExpandedKeys=\"defaultExpandedKeys\"\n :defaultSelectedKeys=\"defaultSelectedKeys\"\n @select=\"selectTreeNode\"\n :replace-fields=\"treeMeta.replaceFields || replaceFields\">\n </ele-tree>\n </section>\n </section>\n <section class=\"model__table--container\" :ref=\"modelTableContainerRef\">\n <div class=\"model__table--title\" v-if=\"title\">\n <template v-if=\"titleMode\">\n <div :class=\"[`model__table-title--${titleMode}`]\"></div>\n </template>\n <template v-else>\n <div class=\"model__table-title--text\">{{ title }}</div>\n </template>\n </div>\n <section :ref=\"modelTableWrapper\" class=\"model__table--wrapper\">\n <ele-search-area :ref=\"searchArea\" @search=\"onSearch\" :data-source=\"searchMeta.elements\"></ele-search-area>\n <div class=\"button-row__area\">\n <ele-button-group class=\"model-table__button-group\" v-on=\"overrideButtonGroupEvent\" :ref=\"buttonGroup\" @click=\"handleClickButtonGroup\" :data-source=\"getButtonGroupElements\"></ele-button-group>\n <slot name=\"tags\"></slot>\n </div>\n <ele-table\n v-on=\"overrideTableEvent\"\n :ref=\"tableRef\"\n :row-selection=\"rowSelection\"\n :loading=\"loading\" \n :columns=\"columns\"\n :total=\"total\"\n :x=\"x\"\n :y=\"y\"\n :height=\"tableHeight\"\n :width=\"tableWidth\"\n :actions=\"actions\"\n :pageSize=\"pageSize\"\n :pageSizeOptions=\"pageSizeOptions\"\n :data-source=\"tableData\"\n @change-page=\"onChangePage\"\n ></ele-table>\n </section>\n </section>\n <ele-modal-form v-model=\"modalFormValue\" :meta=\"modalFormMeta\"></ele-modal-form>\n <ele-modal-fsm v-model=\"showFsmModal\" :contextProp=\"fsmContextProp\" :meta=\"fsmMeta\" @cancel=\"handleCloseFsmModal\"></ele-modal-fsm>\n </section>\n</template>\n\n<script>\nimport { type, net } from '@idooel/shared'\nimport { v4 as uuidv4 } from 'uuid'\nimport { BUILT_IN_EVENT_NAMES, RESERVE_EVENT_NAMES, parseFieldMap, BUILT_IN_TRIGGER } from '../../../utils'\nexport default {\n name: 'ele-tree-table-model',\n props: {\n title: {\n type: [Object, String]\n },\n treeMeta: {\n type: Object,\n default: () => ({})\n },\n searchMeta: {\n type: Object,\n default: () => ({})\n },\n buttonGroupMeta: {\n typeof: Object,\n default: () => ({})\n },\n tableMeta: {\n type: Object,\n default: () => ({})\n },\n createMeta: {\n type: Object\n },\n editMeta: {\n type: Object\n }\n },\n provide () {\n return {\n requestTreeData: this.requestTreeData,\n requestTableData: this.requestTableData\n }\n },\n data () {\n return {\n tableHeight: 0,\n tableWidth: 0,\n modalFormMeta: {},\n modalFormValue: false,\n treeData: [],\n tableData: [],\n defaultExpandedKeys: [],\n defaultSelectedKeys: [],\n replaceFields: {\n title: 'title',\n children: 'children',\n key: 'id'\n },\n loading: false,\n total: 0,\n tableQuerys: {},\n resizeObserverModelTableWrapper: null,\n modelTableWrapperHeight: 0,\n currentTreeNodeData: {},\n treeWrapperHeight: 0,\n currentTableSelection: {},\n showFsmModal: false,\n fsmMeta: {},\n fsmContextProp: {}\n }\n },\n computed: {\n rowSelection () {\n if (!this.currentTableMode) return void 0\n return {\n columnTitle: this.currentSelectionColumn.columnTitle,\n fixed: true,\n type: this.currentTableMode,\n onChange: this.onChangeTableSelection\n }\n },\n currentSelectionColumn () {\n const { multiple } = this.tableMeta\n const target = this.columns.find(item => Object.keys(item).includes('multiple'))\n const isGlobalExistMultiple = Object.keys(this.tableMeta).includes('multiple')\n if (target) {\n return target\n } else if (isGlobalExistMultiple) {\n return { multiple }\n }\n return void 0\n },\n x () {\n const { x } = this.tableMeta\n return x\n },\n y () {\n const { y } = this.tableMeta\n return y\n },\n currentTableMode () {\n if (!this.currentSelectionColumn) return void 0\n const { multiple } = this.currentSelectionColumn\n if (type.isBool(multiple)) {\n if (multiple) {\n return 'checkbox'\n } else {\n return 'radio'\n }\n } else {\n return void 0\n }\n },\n modelTableContainerRef () {\n return uuidv4()\n },\n titleMode () {\n if (type.isObject(this.title)) {\n const { mode = '' } = this.title\n return mode\n }\n return void 0\n },\n tableRef () {\n return uuidv4()\n },\n exposed () {\n return {\n currentTableSelection: this.currentTableSelection,\n currentTreeNode: this.currentTreeNodeData,\n requestTableData: this.requestTableData,\n querys: this.tableQuerys\n }\n },\n overrideTableEvent () {\n const events = this.actions.reduce((ret, action) => {\n ret[action.eventName] = (e) => {\n this.$emit(action.eventName || 'click', { ...e, currentTreeNode: this.currentTreeNodeData, exposed: this.exposed })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events,\n [BUILT_IN_EVENT_NAMES.EDIT]: this[BUILT_IN_EVENT_NAMES.EDIT]\n }\n },\n overrideButtonGroupEvent () {\n const events = this.getButtonGroupElements.reduce((ret, ele) => {\n ret[ele.eventName] = (e) => {\n this.$emit(ele.eventName || 'click', { ...e, currentTreeNode: this.currentTreeNodeData, exposed: this.exposed })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events,\n [BUILT_IN_EVENT_NAMES.CREATE]: this[BUILT_IN_EVENT_NAMES.CREATE]\n }\n },\n showTree () {\n return !!Object.keys(this.treeMeta).length\n },\n buttonGroup () {\n return uuidv4()\n },\n searchArea () {\n return uuidv4()\n },\n modelTreeWrapper () {\n return uuidv4()\n },\n modelTableWrapper () {\n return uuidv4()\n },\n actions () {\n const { operations } = this.tableMeta\n if (operations) {\n return operations.elements\n } else {\n return []\n }\n },\n pageSize () {\n const { page = {} } = this.tableMeta\n return page.pageSize || 10\n },\n pageSizeOptions () {\n const { page = {} } = this.tableMeta\n return page.pageSizeOptions || ['10', '20', '30', '40']\n },\n columns () {\n const { columns, operations } = this.tableMeta\n if (type.get(columns) === 'array') {\n const columnsOptions = columns.map(item => {\n const { mode = 'text' } = item\n if (item.render) {\n return {\n ...item,\n customRender: (text, record, index) => {\n const { $createElement } = this\n return item.render.call(this, \n { h: $createElement, ctx: this },\n text ? typeof text == 'object' ? text[item.dataIndex] : text : '', \n record, index)\n }\n }\n } else if (mode !== BUILT_IN_TRIGGER.TEXT) {\n const { [`${mode}Meta`]: modeMeta } = item\n return {\n ...item,\n customRender: (text, record, index) => {\n return <span onClick={() => this.dispatchTrigger({ mode, record, modeMeta, index })} class={ mode }>{ text }</span>\n }\n }\n }\n return {\n ...item\n }\n })\n if (operations) {\n return [\n ...columnsOptions,\n {\n title: '操作',\n width: operations.width,\n key: 'action',\n fixed: 'right',\n scopedSlots: { customRender: 'action' }\n }\n ]\n }\n return columnsOptions\n } else {\n console.error('Error: columns is invalid, please check it')\n return []\n }\n },\n getButtonGroupElements () {\n const { elements } = this.buttonGroupMeta\n if (type.get(elements) === 'function') {\n return elements.call(this)\n } else if (type.get(elements) === 'array') {\n return elements\n } else {\n return []\n }\n }\n },\n async created () {\n if (this.showTree) {\n this.treeData = await this.requestTreeData()\n const [defaultTreeNode = {}] = this.treeData\n this.defaultExpandedKeys = [defaultTreeNode[this.replaceFields.key]]\n this.defaultSelectedKeys = [defaultTreeNode[this.replaceFields.key]]\n this.currentTreeNodeData = defaultTreeNode\n }\n const { params = {}, fieldMap = {}, overrideInit = false } = this.tableMeta\n const ctx = { ...this.currentTreeNodeData, _route: this.$route.query }\n const initQuerys = Object.assign({}, params, parseFieldMap(fieldMap, ctx))\n if (overrideInit) {\n this.$emit(RESERVE_EVENT_NAMES.INIT, { ...this.exposed })\n } else {\n this.tableData = await this.requestTableData(initQuerys)\n }\n },\n methods: {\n dispatchTrigger ({ mode, record = {}, modeMeta = { } }) {\n switch (mode) {\n case BUILT_IN_TRIGGER.FSM:\n this[`${BUILT_IN_TRIGGER.FSM}Trigger`](record, modeMeta = { \n url: 'api-fsm/workbench/fsm/auditFlow',\n requestType: 'GET',\n fieldMap: {\n modelCode: 'modelCode',\n businessId: 'businessId'\n }\n })\n break\n default:\n break\n }\n },\n handleCloseFsmModal () {\n this.showFsmModal = false\n },\n [`${BUILT_IN_TRIGGER.FSM}Trigger`] (record, meta) {\n this.fsmMeta = meta\n this.fsmContextProp = record\n this.showFsmModal = true\n },\n onChangeTableSelection (_, selectedRows) {\n if (this.currentTableMode === 'radio') {\n this.currentTableSelection = selectedRows[0]\n } else {\n this.currentTableSelection = selectedRows\n }\n },\n [BUILT_IN_EVENT_NAMES.EDIT] () {\n this.modalFormMeta = this.editMeta\n this.modalFormValue = true\n },\n [BUILT_IN_EVENT_NAMES.CREATE] () {\n this.modalFormMeta = this.createMeta\n this.modalFormValue = true\n },\n handleClickButtonGroup (props) {\n const { eventName } = props\n this.$emit(eventName, { currentTreeNode: this.currentTreeNodeData })\n },\n watchViewPort () {\n const modelTableWrapper = this.$refs[this.modelTableWrapper]\n console.log(modelTableWrapper.getBoundingClientRect())\n const { top } = modelTableWrapper.getBoundingClientRect()\n this.$refs[this.modelTreeWrapper].style.height = `calc(100vh - ${top}px)`\n },\n async onSearch (props) {\n this.tableQuerys = Object.assign(this.tableQuerys, props)\n this.tableData = await this.requestTableData()\n },\n execTableFieldMap (fieldMap = {}, props) {\n let ret = {}\n const keys = Object.keys(fieldMap)\n keys.forEach(key => {\n const field = fieldMap[key]\n ret[field] = props[key]\n })\n return ret\n },\n async selectTreeNode (selectedKeys, e) {\n const { fieldMap } = this.tableMeta\n this.currentTreeNodeData = e.node.$vnode.data.props.dataRef\n const execFieldMapRet = this.execTableFieldMap(fieldMap, e.node.$vnode.data.props.dataRef)\n this.tableData = await this.requestTableData(execFieldMapRet)\n },\n async requestTreeData () {\n const { url, requestType = 'GET', params = {}, fieldMap = {} } = this.treeMeta\n const fieldMapRet = parseFieldMap(fieldMap, { ...this.currentTreeNodeData, _route: this.$route.query })\n const ret = await net[requestType.toLowerCase()](\n url,\n { ...params, ...fieldMapRet }\n ).then(resp => {\n const { data } = resp || {}\n return data\n })\n return ret\n },\n async onChangePage (page, pageSize) {\n this.tableData = await this.requestTableData({ currentPage: page, pageSize })\n },\n async requestTableData (props = {}) {\n const { url, requestType = 'GET', page = {} } = this.tableMeta\n const { pageSize = 10 } = page\n this.tableQuerys = Object.assign(this.tableQuerys, { currentPage: 1, pageSize }, props)\n this.loading = true\n const ret = await net[requestType.toLowerCase()](\n url,\n this.tableQuerys\n ).then(resp => {\n const { data = [], count } = resp || {}\n this.total = count\n this.loading = false\n return data.map(item => {\n delete item.children\n return {\n key: uuidv4(),\n ...item\n }\n })\n })\n this.tableData = ret\n return ret\n },\n refreshTreeStatus (props = {}) {},\n refreshTableStatus (props = {}) {},\n calculateTableHeight () {\n const currentViewportHeight = window.innerHeight\n const tableRef = this.$refs[this.tableRef]\n const { top: tableToTop, width } = tableRef.$el.getBoundingClientRect()\n this.tableWidth = width\n this.tableHeight = currentViewportHeight - tableToTop\n },\n calculateTreeHeight () {\n if (!this.showTree) return\n const modelTableContainerRef = this.$refs[this.modelTableContainerRef]\n const { height } = modelTableContainerRef.getBoundingClientRect()\n this.treeWrapperHeight = height\n }\n },\n mounted () {\n this.calculateTableHeight()\n this.$nextTick(() => {\n this.calculateTreeHeight()\n })\n this.resizeObserverModelTableWrapper = new ResizeObserver(entries => {\n for (const _ of entries) {\n requestAnimationFrame(() => {\n this.calculateTableHeight()\n })\n }\n })\n this.resizeObserverModelTableWrapper.observe(this.$refs[this.modelTableWrapper])\n },\n destroyed () {\n this.resizeObserverModelTableWrapper.disconnect()\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.ele {\n &.model__tree-table {\n background: transparent; \n display: flex;\n flex-direction: row;\n width: 100%;\n .model__tree-table--container {\n .model__tree--wrapper {\n width: 240px;\n background: #fff;\n flex-shrink: 0;\n padding: 16px;\n box-sizing: border-box;\n margin-right: 16px;\n overflow-y: auto;\n }\n }\n .model__table--container {\n width: 100%;\n min-width: 0;\n background: #fff;\n .model__table--title {\n .model__table-title--bar {\n width: 100%;\n height: 8px;\n background: var(--idooel-primary-color);\n border-top-left-radius: 4px;\n border-top-right-radius: 4px;\n }\n .model__table-title--text {\n text-align: left;\n padding: 16px;\n font-size: 16px;\n font-weight: bold;\n background: #fff;\n border-bottom: 1px solid;\n border-color: var(--idoole-black-016);\n }\n }\n .model__table--wrapper {\n background: #fff;\n .button-row__area {\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n padding-top: 16px;\n padding-bottom: 8px;\n padding-right: 16px;\n }\n .g-table__wrapper {\n .fsm {\n cursor: pointer;\n color: var(--idooel-primary-color);\n }\n }\n }\n }\n }\n}\n</style>\n",".ele.model__tree-table {\n background: transparent;\n display: flex;\n flex-direction: row;\n width: 100%;\n}\n.ele.model__tree-table .model__tree-table--container .model__tree--wrapper {\n width: 240px;\n background: #fff;\n flex-shrink: 0;\n padding: 16px;\n box-sizing: border-box;\n margin-right: 16px;\n overflow-y: auto;\n}\n.ele.model__tree-table .model__table--container {\n width: 100%;\n min-width: 0;\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--bar {\n width: 100%;\n height: 8px;\n background: var(--idooel-primary-color);\n border-top-left-radius: 4px;\n border-top-right-radius: 4px;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--text {\n text-align: left;\n padding: 16px;\n font-size: 16px;\n font-weight: bold;\n background: #fff;\n border-bottom: 1px solid;\n border-color: var(--idoole-black-016);\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper {\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .button-row__area {\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n padding-top: 16px;\n padding-bottom: 8px;\n padding-right: 16px;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .g-table__wrapper .fsm {\n cursor: pointer;\n color: var(--idooel-primary-color);\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
2871
|
+
inject("data-v-59aa9f0b_0", { source: ".ele.model__tree-table[data-v-59aa9f0b] {\n background: transparent;\n display: flex;\n flex-direction: row;\n width: 100%;\n}\n.ele.model__tree-table .model__tree-table--container .model__tree--wrapper[data-v-59aa9f0b] {\n width: 240px;\n background: #fff;\n flex-shrink: 0;\n padding: 16px;\n box-sizing: border-box;\n margin-right: 16px;\n overflow-y: auto;\n}\n.ele.model__tree-table .model__table--container[data-v-59aa9f0b] {\n width: 100%;\n min-width: 0;\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--bar[data-v-59aa9f0b] {\n width: 100%;\n height: 8px;\n background: var(--idooel-primary-color);\n border-top-left-radius: 4px;\n border-top-right-radius: 4px;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--text[data-v-59aa9f0b] {\n text-align: left;\n padding: 16px;\n font-size: 16px;\n font-weight: bold;\n background: #fff;\n border-bottom: 1px solid;\n border-color: var(--idoole-black-016);\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper[data-v-59aa9f0b] {\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .button-row__area[data-v-59aa9f0b] {\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n padding-top: 16px;\n padding-bottom: 8px;\n padding-right: 16px;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .g-table__wrapper .fsm[data-v-59aa9f0b] {\n cursor: pointer;\n color: var(--idooel-primary-color);\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/models/tree-table-model/src/index.vue","index.vue"],"names":[],"mappings":"AAmdA;EACA,uBAAA;EACA,aAAA;EACA,mBAAA;EACA,WAAA;ACldA;ADodA;EACA,YAAA;EACA,gBAAA;EACA,cAAA;EACA,aAAA;EACA,sBAAA;EACA,kBAAA;EACA,gBAAA;ACldA;ADqdA;EACA,WAAA;EACA,YAAA;EACA,gBAAA;ACndA;ADqdA;EACA,WAAA;EACA,WAAA;EACA,uCAAA;EACA,2BAAA;EACA,4BAAA;ACndA;ADqdA;EACA,gBAAA;EACA,aAAA;EACA,eAAA;EACA,iBAAA;EACA,gBAAA;EACA,wBAAA;EACA,qCAAA;ACndA;ADsdA;EACA,gBAAA;ACpdA;ADqdA;EACA,WAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,8BAAA;EACA,iBAAA;EACA,mBAAA;EACA,mBAAA;ACndA;ADsdA;EACA,eAAA;EACA,kCAAA;ACpdA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <section class=\"ele model__tree-table\">\n <section class=\"model__tree-table--container\" v-if=\"showTree\">\n <div class=\"model__tree--title\"></div>\n <section :ref=\"modelTreeWrapper\" class=\"model__tree--wrapper\" :style=\"{height: `${treeWrapperHeight}px`}\">\n <ele-tree\n :tree-data=\"treeData\"\n :defaultExpandedKeys=\"defaultExpandedKeys\"\n :defaultSelectedKeys=\"defaultSelectedKeys\"\n @select=\"selectTreeNode\"\n :replace-fields=\"treeMeta.replaceFields || replaceFields\">\n </ele-tree>\n </section>\n </section>\n <section class=\"model__table--container\" :ref=\"modelTableContainerRef\">\n <div class=\"model__table--title\" v-if=\"title\">\n <template v-if=\"titleMode\">\n <div :class=\"[`model__table-title--${titleMode}`]\"></div>\n </template>\n <template v-else>\n <div class=\"model__table-title--text\">{{ title }}</div>\n </template>\n </div>\n <section :ref=\"modelTableWrapper\" class=\"model__table--wrapper\">\n <ele-search-area :ref=\"searchArea\" @search=\"onSearch\" :data-source=\"searchMeta.elements\"></ele-search-area>\n <div class=\"button-row__area\">\n <ele-button-group class=\"model-table__button-group\" v-on=\"overrideButtonGroupEvent\" :ref=\"buttonGroup\" @click=\"handleClickButtonGroup\" :data-source=\"getButtonGroupElements\"></ele-button-group>\n <slot name=\"tags\"></slot>\n </div>\n <ele-table\n v-on=\"overrideTableEvent\"\n :ref=\"tableRef\"\n :row-selection=\"rowSelection\"\n :loading=\"loading\" \n :columns=\"columns\"\n :total=\"total\"\n :x=\"x\"\n :y=\"y\"\n :height=\"tableHeight\"\n :width=\"tableWidth\"\n :actions=\"actions\"\n :pageSize=\"pageSize\"\n :pageSizeOptions=\"pageSizeOptions\"\n :data-source=\"tableData\"\n @change-page=\"onChangePage\"\n ></ele-table>\n </section>\n </section>\n <ele-modal-form v-model=\"modalFormValue\" :meta=\"modalFormMeta\"></ele-modal-form>\n <ele-modal-fsm v-model=\"showFsmModal\" :contextProp=\"fsmContextProp\" :meta=\"fsmMeta\" @cancel=\"handleCloseFsmModal\"></ele-modal-fsm>\n </section>\n</template>\n\n<script>\nimport { type, net } from '@idooel/shared'\nimport { v4 as uuidv4 } from 'uuid'\nimport { BUILT_IN_EVENT_NAMES, RESERVE_EVENT_NAMES, parseFieldMap, BUILT_IN_TRIGGER } from '../../../utils'\nexport default {\n name: 'ele-tree-table-model',\n props: {\n title: {\n type: [Object, String]\n },\n overHeight: {\n type: Number,\n default: 0\n },\n treeMeta: {\n type: Object,\n default: () => ({})\n },\n searchMeta: {\n type: Object,\n default: () => ({})\n },\n buttonGroupMeta: {\n typeof: Object,\n default: () => ({})\n },\n tableMeta: {\n type: Object,\n default: () => ({})\n },\n createMeta: {\n type: Object\n },\n editMeta: {\n type: Object\n }\n },\n provide () {\n return {\n requestTreeData: this.requestTreeData,\n requestTableData: this.requestTableData\n }\n },\n data () {\n return {\n tableHeight: 0,\n tableWidth: 0,\n modalFormMeta: {},\n modalFormValue: false,\n treeData: [],\n tableData: [],\n defaultExpandedKeys: [],\n defaultSelectedKeys: [],\n replaceFields: {\n title: 'title',\n children: 'children',\n key: 'id'\n },\n loading: false,\n total: 0,\n tableQuerys: {},\n resizeObserverModelTableWrapper: null,\n modelTableWrapperHeight: 0,\n currentTreeNodeData: {},\n treeWrapperHeight: 0,\n currentTableSelection: {},\n showFsmModal: false,\n fsmMeta: {},\n fsmContextProp: {}\n }\n },\n computed: {\n rowSelection () {\n if (!this.currentTableMode) return void 0\n return {\n columnTitle: this.currentSelectionColumn.columnTitle,\n fixed: true,\n type: this.currentTableMode,\n onChange: this.onChangeTableSelection\n }\n },\n currentSelectionColumn () {\n const { multiple } = this.tableMeta\n const target = this.columns.find(item => Object.keys(item).includes('multiple'))\n const isGlobalExistMultiple = Object.keys(this.tableMeta).includes('multiple')\n if (target) {\n return target\n } else if (isGlobalExistMultiple) {\n return { multiple }\n }\n return void 0\n },\n x () {\n const { x } = this.tableMeta\n return x\n },\n y () {\n const { y } = this.tableMeta\n return y\n },\n currentTableMode () {\n if (!this.currentSelectionColumn) return void 0\n const { multiple } = this.currentSelectionColumn\n if (type.isBool(multiple)) {\n if (multiple) {\n return 'checkbox'\n } else {\n return 'radio'\n }\n } else {\n return void 0\n }\n },\n modelTableContainerRef () {\n return uuidv4()\n },\n titleMode () {\n if (type.isObject(this.title)) {\n const { mode = '' } = this.title\n return mode\n }\n return void 0\n },\n tableRef () {\n return uuidv4()\n },\n exposed () {\n return {\n currentTableSelection: this.currentTableSelection,\n currentTreeNode: this.currentTreeNodeData,\n requestTableData: this.requestTableData,\n querys: this.tableQuerys\n }\n },\n overrideTableEvent () {\n const events = this.actions.reduce((ret, action) => {\n ret[action.eventName] = (e) => {\n this.$emit(action.eventName || 'click', { ...e, currentTreeNode: this.currentTreeNodeData, exposed: this.exposed })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events,\n [BUILT_IN_EVENT_NAMES.EDIT]: this[BUILT_IN_EVENT_NAMES.EDIT]\n }\n },\n overrideButtonGroupEvent () {\n const events = this.getButtonGroupElements.reduce((ret, ele) => {\n ret[ele.eventName] = (e) => {\n this.$emit(ele.eventName || 'click', { ...e, currentTreeNode: this.currentTreeNodeData, exposed: this.exposed })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events,\n [BUILT_IN_EVENT_NAMES.CREATE]: this[BUILT_IN_EVENT_NAMES.CREATE]\n }\n },\n showTree () {\n return !!Object.keys(this.treeMeta).length\n },\n buttonGroup () {\n return uuidv4()\n },\n searchArea () {\n return uuidv4()\n },\n modelTreeWrapper () {\n return uuidv4()\n },\n modelTableWrapper () {\n return uuidv4()\n },\n actions () {\n const { operations } = this.tableMeta\n if (operations) {\n return operations.elements\n } else {\n return []\n }\n },\n pageSize () {\n const { page = {} } = this.tableMeta\n return page.pageSize || 10\n },\n pageSizeOptions () {\n const { page = {} } = this.tableMeta\n return page.pageSizeOptions || ['10', '20', '30', '40']\n },\n columns () {\n const { columns, operations } = this.tableMeta\n if (type.get(columns) === 'array') {\n const columnsOptions = columns.map(item => {\n const { mode = 'text' } = item\n if (item.render) {\n return {\n ...item,\n customRender: (text, record, index) => {\n const { $createElement } = this\n return item.render.call(this, \n { h: $createElement, ctx: this },\n text ? typeof text == 'object' ? text[item.dataIndex] : text : '', \n record, index)\n }\n }\n } else if (mode !== BUILT_IN_TRIGGER.TEXT) {\n const { [`${mode}Meta`]: modeMeta } = item\n return {\n ...item,\n customRender: (text, record, index) => {\n return <span onClick={() => this.dispatchTrigger({ mode, record, modeMeta, index })} class={ mode }>{ text }</span>\n }\n }\n }\n return {\n ...item\n }\n })\n if (operations) {\n return [\n ...columnsOptions,\n {\n title: '操作',\n width: operations.width,\n key: 'action',\n fixed: 'right',\n scopedSlots: { customRender: 'action' }\n }\n ]\n }\n return columnsOptions\n } else {\n console.error('Error: columns is invalid, please check it')\n return []\n }\n },\n getButtonGroupElements () {\n const { elements } = this.buttonGroupMeta\n if (type.get(elements) === 'function') {\n return elements.call(this)\n } else if (type.get(elements) === 'array') {\n return elements\n } else {\n return []\n }\n }\n },\n async created () {\n if (this.showTree) {\n this.treeData = await this.requestTreeData()\n const [defaultTreeNode = {}] = this.treeData\n this.defaultExpandedKeys = [defaultTreeNode[this.replaceFields.key]]\n this.defaultSelectedKeys = [defaultTreeNode[this.replaceFields.key]]\n this.currentTreeNodeData = defaultTreeNode\n }\n const { params = {}, fieldMap = {}, overrideInit = false } = this.tableMeta\n const ctx = { ...this.currentTreeNodeData, _route: this.$route.query }\n const initQuerys = Object.assign({}, params, parseFieldMap(fieldMap, ctx))\n if (overrideInit) {\n this.$emit(RESERVE_EVENT_NAMES.INIT, { ...this.exposed })\n } else {\n this.tableData = await this.requestTableData(initQuerys)\n }\n },\n methods: {\n dispatchTrigger ({ mode, record = {}, modeMeta = { } }) {\n switch (mode) {\n case BUILT_IN_TRIGGER.FSM:\n this[`${BUILT_IN_TRIGGER.FSM}Trigger`](record, modeMeta = { \n url: 'api-fsm/workbench/fsm/auditFlow',\n requestType: 'GET',\n fieldMap: {\n modelCode: 'modelCode',\n businessId: 'businessId'\n }\n })\n break\n default:\n break\n }\n },\n handleCloseFsmModal () {\n this.showFsmModal = false\n },\n [`${BUILT_IN_TRIGGER.FSM}Trigger`] (record, meta) {\n this.fsmMeta = meta\n this.fsmContextProp = record\n this.showFsmModal = true\n },\n onChangeTableSelection (_, selectedRows) {\n if (this.currentTableMode === 'radio') {\n this.currentTableSelection = selectedRows[0]\n this.$emit('on-change-table-selection', this.currentTableSelection)\n } else {\n this.currentTableSelection = selectedRows\n this.$emit('on-change-table-selection', this.currentTableSelection)\n }\n },\n [BUILT_IN_EVENT_NAMES.EDIT] () {\n this.modalFormMeta = this.editMeta\n this.modalFormValue = true\n },\n [BUILT_IN_EVENT_NAMES.CREATE] () {\n this.modalFormMeta = this.createMeta\n this.modalFormValue = true\n },\n handleClickButtonGroup (props) {\n const { eventName } = props\n this.$emit(eventName, { currentTreeNode: this.currentTreeNodeData })\n },\n watchViewPort () {\n const modelTableWrapper = this.$refs[this.modelTableWrapper]\n console.log(modelTableWrapper.getBoundingClientRect())\n const { top } = modelTableWrapper.getBoundingClientRect()\n this.$refs[this.modelTreeWrapper].style.height = `calc(100vh - ${top}px)`\n },\n async onSearch (props) {\n this.tableQuerys = Object.assign(this.tableQuerys, props)\n this.tableData = await this.requestTableData()\n },\n execTableFieldMap (fieldMap = {}, props) {\n let ret = {}\n const keys = Object.keys(fieldMap)\n keys.forEach(key => {\n const field = fieldMap[key]\n ret[field] = props[key]\n })\n return ret\n },\n async selectTreeNode (selectedKeys, e) {\n const { fieldMap } = this.tableMeta\n this.currentTreeNodeData = e.node.$vnode.data.props.dataRef\n const execFieldMapRet = this.execTableFieldMap(fieldMap, e.node.$vnode.data.props.dataRef)\n this.tableData = await this.requestTableData(execFieldMapRet)\n },\n async requestTreeData () {\n const { url, requestType = 'GET', params = {}, fieldMap = {} } = this.treeMeta\n const fieldMapRet = parseFieldMap(fieldMap, { ...this.currentTreeNodeData, _route: this.$route.query })\n const ret = await net[requestType.toLowerCase()](\n url,\n { ...params, ...fieldMapRet }\n ).then(resp => {\n const { data } = resp || {}\n return data\n })\n return ret\n },\n async onChangePage (page, pageSize) {\n this.tableData = await this.requestTableData({ currentPage: page, pageSize })\n },\n async requestTableData (props = {}) {\n const { url, requestType = 'GET', page = {} } = this.tableMeta\n const { pageSize = 10 } = page\n this.tableQuerys = Object.assign(this.tableQuerys, { currentPage: 1, pageSize }, props)\n this.$emit(RESERVE_EVENT_NAMES.WATCH, { ...this.exposed })\n this.loading = true\n const ret = await net[requestType.toLowerCase()](\n url,\n this.tableQuerys\n ).then(resp => {\n const { data = [], count } = resp || {}\n this.total = count\n this.loading = false\n return data.map(item => {\n delete item.children\n return {\n key: uuidv4(),\n ...item\n }\n })\n })\n this.tableData = ret\n return ret\n },\n refreshTreeStatus (props = {}) {},\n refreshTableStatus (props = {}) {},\n calculateTableHeight () {\n const currentViewportHeight = window.innerHeight\n const tableRef = this.$refs[this.tableRef]\n const { top: tableToTop, width } = tableRef.$el.getBoundingClientRect()\n this.tableWidth = width\n this.tableHeight = currentViewportHeight - tableToTop - this.overHeight\n },\n calculateTreeHeight () {\n if (!this.showTree) return\n const modelTableContainerRef = this.$refs[this.modelTableContainerRef]\n const { height } = modelTableContainerRef.getBoundingClientRect()\n this.treeWrapperHeight = height\n }\n },\n mounted () {\n this.calculateTableHeight()\n this.$nextTick(() => {\n this.calculateTreeHeight()\n })\n this.resizeObserverModelTableWrapper = new ResizeObserver(entries => {\n for (const _ of entries) {\n requestAnimationFrame(() => {\n this.calculateTableHeight()\n })\n }\n })\n this.resizeObserverModelTableWrapper.observe(this.$refs[this.modelTableWrapper])\n },\n destroyed () {\n this.resizeObserverModelTableWrapper.disconnect()\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.ele {\n &.model__tree-table {\n background: transparent; \n display: flex;\n flex-direction: row;\n width: 100%;\n .model__tree-table--container {\n .model__tree--wrapper {\n width: 240px;\n background: #fff;\n flex-shrink: 0;\n padding: 16px;\n box-sizing: border-box;\n margin-right: 16px;\n overflow-y: auto;\n }\n }\n .model__table--container {\n width: 100%;\n min-width: 0;\n background: #fff;\n .model__table--title {\n .model__table-title--bar {\n width: 100%;\n height: 8px;\n background: var(--idooel-primary-color);\n border-top-left-radius: 4px;\n border-top-right-radius: 4px;\n }\n .model__table-title--text {\n text-align: left;\n padding: 16px;\n font-size: 16px;\n font-weight: bold;\n background: #fff;\n border-bottom: 1px solid;\n border-color: var(--idoole-black-016);\n }\n }\n .model__table--wrapper {\n background: #fff;\n .button-row__area {\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n padding-top: 16px;\n padding-bottom: 8px;\n padding-right: 16px;\n }\n .g-table__wrapper {\n .fsm {\n cursor: pointer;\n color: var(--idooel-primary-color);\n }\n }\n }\n }\n }\n}\n</style>\n",".ele.model__tree-table {\n background: transparent;\n display: flex;\n flex-direction: row;\n width: 100%;\n}\n.ele.model__tree-table .model__tree-table--container .model__tree--wrapper {\n width: 240px;\n background: #fff;\n flex-shrink: 0;\n padding: 16px;\n box-sizing: border-box;\n margin-right: 16px;\n overflow-y: auto;\n}\n.ele.model__tree-table .model__table--container {\n width: 100%;\n min-width: 0;\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--bar {\n width: 100%;\n height: 8px;\n background: var(--idooel-primary-color);\n border-top-left-radius: 4px;\n border-top-right-radius: 4px;\n}\n.ele.model__tree-table .model__table--container .model__table--title .model__table-title--text {\n text-align: left;\n padding: 16px;\n font-size: 16px;\n font-weight: bold;\n background: #fff;\n border-bottom: 1px solid;\n border-color: var(--idoole-black-016);\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper {\n background: #fff;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .button-row__area {\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n padding-top: 16px;\n padding-bottom: 8px;\n padding-right: 16px;\n}\n.ele.model__tree-table .model__table--container .model__table--wrapper .g-table__wrapper .fsm {\n cursor: pointer;\n color: var(--idooel-primary-color);\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
2862
2872
|
|
|
2863
2873
|
};
|
|
2864
2874
|
/* scoped */
|
|
2865
|
-
const __vue_scope_id__$
|
|
2875
|
+
const __vue_scope_id__$v = "data-v-59aa9f0b";
|
|
2866
2876
|
/* module identifier */
|
|
2867
|
-
const __vue_module_identifier__$
|
|
2877
|
+
const __vue_module_identifier__$v = undefined;
|
|
2868
2878
|
/* functional template */
|
|
2869
|
-
const __vue_is_functional_template__$
|
|
2879
|
+
const __vue_is_functional_template__$v = false;
|
|
2870
2880
|
/* style inject SSR */
|
|
2871
2881
|
|
|
2872
2882
|
/* style inject shadow dom */
|
|
2873
2883
|
|
|
2874
2884
|
|
|
2875
2885
|
|
|
2876
|
-
const __vue_component__$
|
|
2877
|
-
{ render: __vue_render__$
|
|
2878
|
-
__vue_inject_styles__$
|
|
2879
|
-
__vue_script__$
|
|
2880
|
-
__vue_scope_id__$
|
|
2881
|
-
__vue_is_functional_template__$
|
|
2882
|
-
__vue_module_identifier__$
|
|
2886
|
+
const __vue_component__$v = /*#__PURE__*/normalizeComponent(
|
|
2887
|
+
{ render: __vue_render__$v, staticRenderFns: __vue_staticRenderFns__$v },
|
|
2888
|
+
__vue_inject_styles__$v,
|
|
2889
|
+
__vue_script__$v,
|
|
2890
|
+
__vue_scope_id__$v,
|
|
2891
|
+
__vue_is_functional_template__$v,
|
|
2892
|
+
__vue_module_identifier__$v,
|
|
2883
2893
|
false,
|
|
2884
2894
|
createInjector,
|
|
2885
2895
|
undefined,
|
|
@@ -2887,7 +2897,7 @@ __vue_render__$u._withStripped = true;
|
|
|
2887
2897
|
);
|
|
2888
2898
|
|
|
2889
2899
|
//
|
|
2890
|
-
var script$
|
|
2900
|
+
var script$u = {
|
|
2891
2901
|
name: 'ele-form-group-model',
|
|
2892
2902
|
props: {
|
|
2893
2903
|
mode: {
|
|
@@ -3167,10 +3177,10 @@ var script$t = {
|
|
|
3167
3177
|
};
|
|
3168
3178
|
|
|
3169
3179
|
/* script */
|
|
3170
|
-
const __vue_script__$
|
|
3180
|
+
const __vue_script__$u = script$u;
|
|
3171
3181
|
|
|
3172
3182
|
/* template */
|
|
3173
|
-
var __vue_render__$
|
|
3183
|
+
var __vue_render__$u = function () {
|
|
3174
3184
|
var _vm = this;
|
|
3175
3185
|
var _h = _vm.$createElement;
|
|
3176
3186
|
var _c = _vm._self._c || _h;
|
|
@@ -3272,34 +3282,34 @@ var __vue_render__$t = function () {
|
|
|
3272
3282
|
2
|
|
3273
3283
|
)
|
|
3274
3284
|
};
|
|
3275
|
-
var __vue_staticRenderFns__$
|
|
3276
|
-
__vue_render__$
|
|
3285
|
+
var __vue_staticRenderFns__$u = [];
|
|
3286
|
+
__vue_render__$u._withStripped = true;
|
|
3277
3287
|
|
|
3278
3288
|
/* style */
|
|
3279
|
-
const __vue_inject_styles__$
|
|
3289
|
+
const __vue_inject_styles__$u = function (inject) {
|
|
3280
3290
|
if (!inject) return
|
|
3281
3291
|
inject("data-v-770e5c93_0", { source: ".ele.form-group-model__wrapper[data-v-770e5c93] {\n background: unset;\n padding-bottom: 80px;\n}\n.ele.form-group-model__wrapper .form-group-model__from[data-v-770e5c93] {\n background: #fff;\n margin-top: 16px;\n}\n.ele.form-group-model__wrapper .form-group-model__from[data-v-770e5c93]:first-child {\n margin-top: unset;\n}\n.ele.form-group-model__wrapper .form-group-model__from .form-group-model__form--title[data-v-770e5c93] {\n width: 100%;\n height: 56px;\n padding: 0 16px;\n border-bottom: 1px solid;\n border-color: var(--idooel-form-title-border-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n}\n.ele.form-group-model__wrapper .form-group-model__from .form-group-model__form--content[data-v-770e5c93] {\n padding: 16px;\n}\n.ele.form-group-model__wrapper .form-group-model__form--footer[data-v-770e5c93] {\n width: 100%;\n height: 64px;\n background: #fff;\n position: fixed;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/models/form-group-model/src/index.vue","index.vue"],"names":[],"mappings":"AA4OA;EACA,iBAAA;EACA,oBAAA;AC3OA;AD4OA;EACA,gBAAA;EACA,gBAAA;AC1OA;AD2OA;EACA,iBAAA;ACzOA;AD2OA;EACA,WAAA;EACA,YAAA;EACA,eAAA;EACA,wBAAA;EACA,mDAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,8BAAA;ACzOA;AD2OA;EACA,aAAA;ACzOA;AD4OA;EACA,WAAA;EACA,YAAA;EACA,gBAAA;EACA,eAAA;EACA,SAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,oBAAA;AC1OA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"ele form-group-model__wrapper\">\n <template v-for=\"(group, idx) in innerGroupMeta\">\n <div \n class=\"form-group-model__from\"\n v-if=\"!group.isGenTpl\"\n :key=\"group.key || idx\">\n <div class=\"form-group-model__form--title\">\n <div>{{ group.title }}</div>\n <div class=\"form-group-model__form--buttons\">\n <ele-button-group v-if=\"group.buttonGroupMeta\" v-on=\"assignAttrForEvents\" @delete=\"handleClickDelete($event, group, idx)\" :data-source=\"group.buttonGroupMeta.elements.call(this)\"></ele-button-group>\n </div>\n </div>\n <div class=\"form-group-model__form--content\">\n <ele-form @change=\"onChangeFormStatus($event, group.key || idx)\" :form-name=\"group.key || idx\" :ref=\"group.key || `${formRefBase}__${idx}`\" :elements=\"group.elements\"></ele-form>\n </div>\n </div>\n </template>\n <div v-if=\"showFooterMeta\" class=\"form-group-model__form--footer\">\n <ele-button-group v-on=\"assignAttrForEvents\" :data-source=\"footerElements\"></ele-button-group>\n </div>\n </div>\n</template>\n\n<script>\nimport { BUILT_IN_EVENT_NAMES, RESERVE_EVENT_NAMES, parseFieldMap, PAGE_STATUS } from '../../../utils'\nimport { v4 as uuidv4 } from 'uuid'\nimport { type, net } from '@idooel/shared'\nexport default {\n name: 'ele-form-group-model',\n props: {\n mode: {\n type: String\n },\n fieldName: {\n type: String,\n default: 'formGroup'\n },\n groupMeta: {\n type: Function,\n default: () => []\n },\n footerMeta: {\n type: Object,\n default: () => {}\n },\n preRequest: {\n type: Object,\n default: () => {}\n },\n infoRequest: {\n type: Object,\n default: () => {}\n },\n submitRequest: {\n type: Object,\n default: () => {}\n }\n },\n data () {\n return {\n increaseCount: 1,\n innerGroupMeta: []\n }\n },\n watch: {\n readOnlyGroupMeta: {\n handler (meta) {\n this.innerGroupMeta = meta\n },\n immediate: true\n }\n },\n computed: {\n routeMetaMode () {\n return this.$route.meta.mode\n },\n readOnlyGroupMeta () {\n return this.groupMeta.call(this)\n },\n showFooterMeta () {\n return !type.isEmpty(this.footerMeta)\n },\n formRefBase () {\n return uuidv4()\n },\n footerElements () {\n const { elements } = this.footerMeta\n return elements.call(this)\n },\n assignAttrForEvents () {\n const events = this.footerElements.reduce((ret, ele) => {\n ret[ele.eventName] = (e) => {\n this.$emit(ele.eventName || 'click', { ...e })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events,\n [BUILT_IN_EVENT_NAMES.SUBMIT]: this[BUILT_IN_EVENT_NAMES.SUBMIT],\n [BUILT_IN_EVENT_NAMES.CANCEL]: this[BUILT_IN_EVENT_NAMES.CANCEL],\n [BUILT_IN_EVENT_NAMES.INCREASE]: this[BUILT_IN_EVENT_NAMES.INCREASE]\n }\n },\n getFormRefs () {\n return this.innerGroupMeta.map((group, idx) => {\n if (!group.isGenTpl) {\n return this.$refs[group.key || `${this.formRefBase}__${idx}`]\n }\n return void 0\n }).filter(item => !!item).flat()\n },\n formModels () {\n if (this.mode === 'increase') {\n //TODO increase mode to return formModels\n return this.getFormRefs.map(form => {\n return form.getFieldsValue()\n })\n } else {\n return this.getFormRefs.map(form => {\n const { $vnode: { data: { ref } } } = form\n return {\n key: ref,\n value: form.getFieldsValue()\n }\n }).reduce((ret, props) => {\n ret[props.key] = props.value\n return ret\n }, {})\n }\n }\n },\n methods: {\n execFieldMap (fieldMap = {}, dataSource = {}) {\n const ret = parseFieldMap(fieldMap, { _route: this.$route.query, ...dataSource})\n return ret\n },\n onChangeFormStatus (props, key) {\n this.$emit(RESERVE_EVENT_NAMES.WATCH_FORM_STATUS, { key, ...props })\n },\n async infoRequestTrigger () {\n if (!this.infoRequest || this.routeMetaMode == PAGE_STATUS.CREATE) return\n const { url, requestType, params = {}, fieldMap = {}, headers = {} } = this.infoRequest\n if (!url) return\n net[requestType.toLowerCase()](url, { ...params, ...this.execFieldMap(fieldMap) }, { ...headers }).then(resp => {\n const { data = {} } = resp\n if (this.mode === 'increase') {\n this.renderIncreaseForm(data)\n }\n this.$emit(RESERVE_EVENT_NAMES.INIT_FORM, { ...data })\n })\n },\n async preRequestTrigger () {\n if (!this.preRequest) return\n const { url, requestType = 'GET', params = {}, fieldMap = {}, headers = {} } = this.preRequest\n if (!url) return\n net[requestType.toLowerCase()](url, { ...params, ...fieldMap }, { ...headers }).then(resp => {\n const { data = {} } = resp\n if (this.mode === 'increase') {\n this.renderIncreaseForm(data)\n }\n this.$emit(RESERVE_EVENT_NAMES.INIT_FORM, { ...data })\n })\n },\n renderIncreaseForm (data = {}) {\n const formGroupValuesLength = data[this.fieldName].length\n const genTplTarget = this.readOnlyGroupMeta.find(item => item.isGenTpl)\n const notGenTplPoolLength = this.readOnlyGroupMeta.filter(item => !item.isGenTpl).length\n const genNum = formGroupValuesLength - notGenTplPoolLength\n new Array(genNum).fill().forEach(() => {\n const form = this.genForm(genTplTarget)\n this.innerGroupMeta.push(form)\n })\n const formGroupValues = data[this.fieldName]\n this.$nextTick(() => {\n this.setFieldsValue(formGroupValues)\n })\n },\n async submitRequestTrigger (props = {}) {\n const { url, requestType, headers = {}, params = {}, fieldMap = {} } = this.submitRequest\n if (!url) return\n const ret = await net[requestType.toLowerCase()](url, { ...params, ...this.execFieldMap(fieldMap, { ...this.formModels }), [this.fieldName]: this.formModels }, { headers }).then(resp => {\n this.$emit(BUILT_IN_EVENT_NAMES.SUBMIT, { ...props, formModel: { ...this.formModels, ...resp.data || {} } })\n return resp.data\n })\n return ret\n },\n setFieldsValue (data = []) {\n this.getFormRefs.forEach((form, idx) => {\n form.setFieldsValue(data[idx])\n form.evalDisabledExpression(data[idx])\n })\n },\n [BUILT_IN_EVENT_NAMES.SUBMIT] (props = {}) {\n const status = this.getFormRefs.map(form => {\n const status = form.validateFields()\n return status\n }).every(item => item)\n if (status) {\n return this.submitRequestTrigger(props)\n } else {\n return false\n }\n },\n [BUILT_IN_EVENT_NAMES.CANCEL] (props = {}) {\n this.$emit(BUILT_IN_EVENT_NAMES.CANCEL, { ...props })\n },\n genForm (base) {\n const { elements, title, buttonGroupMeta } = base\n return {\n elements: JSON.parse(JSON.stringify(elements)),\n buttonGroupMeta,\n title: `${title}${this.increaseCount++}`,\n _gen: true\n }\n },\n handleClickDelete (props = {}, attr = {}, idx) {\n this.innerGroupMeta.splice(idx, 1)\n this.$emit(BUILT_IN_EVENT_NAMES.DELETE, { ...props })\n },\n [BUILT_IN_EVENT_NAMES.INCREASE] (props) {\n const genTplTarget = this.readOnlyGroupMeta.find(item => item.isGenTpl)\n const form = this.genForm(genTplTarget)\n this.innerGroupMeta.push(form)\n }\n },\n async mounted() {\n await this.preRequestTrigger()\n await this.infoRequestTrigger()\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.ele {\n &.form-group-model__wrapper {\n background: unset;\n padding-bottom: 80px;\n .form-group-model__from {\n background: #fff;\n margin-top: 16px;\n &:first-child {\n margin-top: unset;\n }\n .form-group-model__form--title {\n width: 100%;\n height: 56px;\n padding: 0 16px;\n border-bottom: 1px solid;\n border-color: var(--idooel-form-title-border-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n }\n .form-group-model__form--content {\n padding: 16px;\n }\n }\n .form-group-model__form--footer {\n width: 100%;\n height: 64px;\n background: #fff;\n position: fixed;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n }\n }\n}\n</style>",".ele.form-group-model__wrapper {\n background: unset;\n padding-bottom: 80px;\n}\n.ele.form-group-model__wrapper .form-group-model__from {\n background: #fff;\n margin-top: 16px;\n}\n.ele.form-group-model__wrapper .form-group-model__from:first-child {\n margin-top: unset;\n}\n.ele.form-group-model__wrapper .form-group-model__from .form-group-model__form--title {\n width: 100%;\n height: 56px;\n padding: 0 16px;\n border-bottom: 1px solid;\n border-color: var(--idooel-form-title-border-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n}\n.ele.form-group-model__wrapper .form-group-model__from .form-group-model__form--content {\n padding: 16px;\n}\n.ele.form-group-model__wrapper .form-group-model__form--footer {\n width: 100%;\n height: 64px;\n background: #fff;\n position: fixed;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
3282
3292
|
|
|
3283
3293
|
};
|
|
3284
3294
|
/* scoped */
|
|
3285
|
-
const __vue_scope_id__$
|
|
3295
|
+
const __vue_scope_id__$u = "data-v-770e5c93";
|
|
3286
3296
|
/* module identifier */
|
|
3287
|
-
const __vue_module_identifier__$
|
|
3297
|
+
const __vue_module_identifier__$u = undefined;
|
|
3288
3298
|
/* functional template */
|
|
3289
|
-
const __vue_is_functional_template__$
|
|
3299
|
+
const __vue_is_functional_template__$u = false;
|
|
3290
3300
|
/* style inject SSR */
|
|
3291
3301
|
|
|
3292
3302
|
/* style inject shadow dom */
|
|
3293
3303
|
|
|
3294
3304
|
|
|
3295
3305
|
|
|
3296
|
-
const __vue_component__$
|
|
3297
|
-
{ render: __vue_render__$
|
|
3298
|
-
__vue_inject_styles__$
|
|
3299
|
-
__vue_script__$
|
|
3300
|
-
__vue_scope_id__$
|
|
3301
|
-
__vue_is_functional_template__$
|
|
3302
|
-
__vue_module_identifier__$
|
|
3306
|
+
const __vue_component__$u = /*#__PURE__*/normalizeComponent(
|
|
3307
|
+
{ render: __vue_render__$u, staticRenderFns: __vue_staticRenderFns__$u },
|
|
3308
|
+
__vue_inject_styles__$u,
|
|
3309
|
+
__vue_script__$u,
|
|
3310
|
+
__vue_scope_id__$u,
|
|
3311
|
+
__vue_is_functional_template__$u,
|
|
3312
|
+
__vue_module_identifier__$u,
|
|
3303
3313
|
false,
|
|
3304
3314
|
createInjector,
|
|
3305
3315
|
undefined,
|
|
@@ -3307,7 +3317,7 @@ __vue_render__$t._withStripped = true;
|
|
|
3307
3317
|
);
|
|
3308
3318
|
|
|
3309
3319
|
//
|
|
3310
|
-
var script$
|
|
3320
|
+
var script$t = {
|
|
3311
3321
|
name: 'ele-form-model',
|
|
3312
3322
|
props: {
|
|
3313
3323
|
disabled: {
|
|
@@ -3544,10 +3554,10 @@ var script$s = {
|
|
|
3544
3554
|
};
|
|
3545
3555
|
|
|
3546
3556
|
/* script */
|
|
3547
|
-
const __vue_script__$
|
|
3557
|
+
const __vue_script__$t = script$t;
|
|
3548
3558
|
|
|
3549
3559
|
/* template */
|
|
3550
|
-
var __vue_render__$
|
|
3560
|
+
var __vue_render__$t = function () {
|
|
3551
3561
|
var _vm = this;
|
|
3552
3562
|
var _h = _vm.$createElement;
|
|
3553
3563
|
var _c = _vm._self._c || _h;
|
|
@@ -3600,34 +3610,34 @@ var __vue_render__$s = function () {
|
|
|
3600
3610
|
: _vm._e(),
|
|
3601
3611
|
])
|
|
3602
3612
|
};
|
|
3603
|
-
var __vue_staticRenderFns__$
|
|
3604
|
-
__vue_render__$
|
|
3613
|
+
var __vue_staticRenderFns__$t = [];
|
|
3614
|
+
__vue_render__$t._withStripped = true;
|
|
3605
3615
|
|
|
3606
3616
|
/* style */
|
|
3607
|
-
const __vue_inject_styles__$
|
|
3617
|
+
const __vue_inject_styles__$t = function (inject) {
|
|
3608
3618
|
if (!inject) return
|
|
3609
3619
|
inject("data-v-02358f9a_0", { source: ".form__model--wrapper[data-v-02358f9a] {\n width: 100%;\n height: 100%;\n overflow: auto;\n background: #fff;\n}\n.form__model--wrapper .form-model__title[data-v-02358f9a] {\n height: 56px;\n padding: 0 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n border-bottom: 1px solid var(--idooel-form-title-border-color);\n}\n.form__model--wrapper .form-model__content[data-v-02358f9a] {\n padding: 16px;\n}\n.form__model--wrapper .form-model__footer[data-v-02358f9a] {\n /* width: 100%; */\n height: 64px;\n position: fixed;\n bottom: 0;\n display: flex;\n float: right;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/models/form-model/src/index.vue","index.vue"],"names":[],"mappings":"AAuLA;EACA,WAAA;EACA,YAAA;EACA,cAAA;EACA,gBAAA;ACtLA;ADuLA;EACA,YAAA;EACA,eAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,8DAAA;ACrLA;ADuLA;EACA,aAAA;ACrLA;ADuLA;EACA,iBAAA;EACA,YAAA;EACA,eAAA;EACA,SAAA;EACA,aAAA;EACA,YAAA;EACA,mBAAA;EACA,mBAAA;EACA,oBAAA;ACrLA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"form__model--wrapper\">\n <div class=\"form-model__title\" v-if=\"title\">\n {{ title }}\n </div>\n <div class=\"form-model__content\">\n <ele-alert style=\"margin-bottom: 16px;\" v-if=\"alertMeta\" v-bind=\"alertMeta\"></ele-alert>\n <ele-form :ref=\"formRef\" :elements=\"elements\" :disabled=\"globalDisabled\"></ele-form>\n </div>\n <div class=\"form-model__footer\" v-if=\"footerMeta\">\n <ele-button-group v-on=\"assignAttrForEvents\" :data-source=\"footerElements\"></ele-button-group>\n </div>\n </div>\n</template>\n\n<script>\nimport { BUILT_IN_EVENT_NAMES, parseFieldMap, RESERVE_EVENT_NAMES, PAGE_STATUS, CONTEXT } from '../../../utils'\nimport { v4 as uuidv4 } from 'uuid'\nimport { net, type } from '@idooel/shared'\nimport { parse } from '@idooel/expression'\nexport default {\n name: 'ele-form-model',\n props: {\n disabled: {\n type: [Boolean, String],\n default: '_routeMeta.disabled'\n },\n title: {\n type: String\n },\n formMeta: {\n type: Object\n },\n footerMeta: {\n type: Object\n }\n },\n data() {\n return {}\n },\n provide () {\n return {\n [CONTEXT]: () => {\n return {\n exposed: this.exposed\n }\n }\n }\n },\n computed: {\n globalDisabled () {\n return this.executeExpression(this.disabled)\n },\n formRef () {\n return uuidv4()\n },\n exposed () {\n return {\n setFieldsValue: this.setFieldsValue,\n validateFields: this.validateFields\n }\n },\n assignAttrForEvents () {\n const events = this.footerElements.reduce((ret, ele) => {\n ret[ele.eventName] = (e) => {\n this.$emit(ele.eventName || 'click', { ...e, formModel: this.formModels(), exposed: this.exposed })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events,\n [BUILT_IN_EVENT_NAMES.SUBMIT]: this[BUILT_IN_EVENT_NAMES.SUBMIT],\n [BUILT_IN_EVENT_NAMES.CANCEL]: this[BUILT_IN_EVENT_NAMES.CANCEL]\n }\n },\n elements () {\n const { elements } = this.formMeta\n return elements\n },\n preRequest () {\n const { preRequest = {} } = this.formMeta\n return preRequest\n },\n infoRequest () {\n const { infoRequest = {} } = this.formMeta\n return infoRequest\n },\n alertMeta () {\n const { alert = {} } = this.formMeta\n return type.isEmpty(alert) ? null : alert\n },\n submitRequest () {\n const { submitRequest = {} } = this.formMeta\n return submitRequest\n },\n footerElements () {\n const { elements } = this.footerMeta\n return elements.call(this)\n },\n expressionData () {\n return {\n _route: this.$route.query,\n _routeMeta: this.$route.meta\n }\n },\n routeMetaMode () {\n return this.$route.meta.mode\n }\n },\n methods: {\n formModels () {\n return this.$refs[this.formRef] ? this.$refs[this.formRef].getFieldsValue() : {}\n },\n executeExpression (expression, dataSource = {}) {\n if (type.isBool(expression)) return expression\n if (type.isEmpty(expression)) return false\n return parse(expression, { ...this.expressionData, ...this.formModels(), ...dataSource })\n },\n execFieldMap (fieldMap = {}, dataSource = {}) {\n const ret = parseFieldMap(fieldMap, { ...this.expressionData, ...dataSource})\n return ret\n },\n async submitRequestTrigger (props = {}) {\n const { url, requestType, headers = {}, params = {}, fieldMap = {} } = this.submitRequest\n const currentUrl = this.executeExpressionForUrl(url)\n if (!currentUrl) return\n const ret = await net[requestType.toLowerCase()](currentUrl, { ...params, ...this.execFieldMap(fieldMap, { ...this.formModels() }), ...this.formModels() }, { headers }).then(resp => {\n this.$emit(BUILT_IN_EVENT_NAMES.SUBMIT, { ...props, formModel: { ...this.formModels(), ...resp.data || {} } })\n return resp.data\n })\n return ret\n },\n async infoRequestTrigger () {\n if (PAGE_STATUS.CREATE == this.routeMetaMode) return\n const { url, requestType, params = {}, fieldMap = {}, headers = {} } = this.infoRequest\n const currentUrl = this.executeExpressionForUrl(url)\n if (!currentUrl) return\n net[requestType.toLowerCase()](currentUrl, { ...params, ...this.execFieldMap(fieldMap) }, { ...headers }).then(resp => {\n const { data = {} } = resp\n this.setFieldsValue(data)\n this.$emit(RESERVE_EVENT_NAMES.INIT_FORM, { ...data })\n })\n },\n async preRequestTrigger () {\n const { url, requestType = 'GET', params = {}, fieldMap = {}, headers = {} } = this.preRequest\n const currentUrl = this.executeExpressionForUrl(url)\n if (!currentUrl) return\n const { data } = await net[requestType.toLowerCase()](currentUrl, { ...params, ...this.execFieldMap(fieldMap) }, { ...headers })\n this.setFieldsValue(data)\n this.$emit(RESERVE_EVENT_NAMES.INIT_FORM, { ...data })\n },\n executeExpressionForUrl (url) {\n return type.isApi(url) ? url : this.executeExpression(url)\n },\n setFieldsValue (props) {\n this.$refs[this.formRef].setFieldsValue(props)\n },\n validateFields () {\n return this.$refs[this.formRef].validateFields()\n },\n [BUILT_IN_EVENT_NAMES.SUBMIT] (props = {}) {\n if (this.globalDisabled) return\n const status = this.$refs[this.formRef].validateFields()\n if (status) {\n //TODO fieldMap\n return this.submitRequestTrigger(props)\n } else {\n return false\n }\n },\n [BUILT_IN_EVENT_NAMES.CANCEL] (props = {}) {\n this.$emit(BUILT_IN_EVENT_NAMES.CANCEL, { ...props })\n }\n },\n async mounted() {\n await this.preRequestTrigger()\n await this.infoRequestTrigger()\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.form__model--wrapper {\n width: 100%;\n height: 100%;\n overflow: auto;\n background: #fff;\n .form-model__title {\n height: 56px;\n padding: 0 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n border-bottom: 1px solid var(--idooel-form-title-border-color);\n }\n .form-model__content {\n padding: 16px;\n }\n .form-model__footer {\n /* width: 100%; */\n height: 64px;\n position: fixed;\n bottom: 0;\n display: flex;\n float: right;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n }\n}\n</style>",".form__model--wrapper {\n width: 100%;\n height: 100%;\n overflow: auto;\n background: #fff;\n}\n.form__model--wrapper .form-model__title {\n height: 56px;\n padding: 0 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n border-bottom: 1px solid var(--idooel-form-title-border-color);\n}\n.form__model--wrapper .form-model__content {\n padding: 16px;\n}\n.form__model--wrapper .form-model__footer {\n /* width: 100%; */\n height: 64px;\n position: fixed;\n bottom: 0;\n display: flex;\n float: right;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
3610
3620
|
|
|
3611
3621
|
};
|
|
3612
3622
|
/* scoped */
|
|
3613
|
-
const __vue_scope_id__$
|
|
3623
|
+
const __vue_scope_id__$t = "data-v-02358f9a";
|
|
3614
3624
|
/* module identifier */
|
|
3615
|
-
const __vue_module_identifier__$
|
|
3625
|
+
const __vue_module_identifier__$t = undefined;
|
|
3616
3626
|
/* functional template */
|
|
3617
|
-
const __vue_is_functional_template__$
|
|
3627
|
+
const __vue_is_functional_template__$t = false;
|
|
3618
3628
|
/* style inject SSR */
|
|
3619
3629
|
|
|
3620
3630
|
/* style inject shadow dom */
|
|
3621
3631
|
|
|
3622
3632
|
|
|
3623
3633
|
|
|
3624
|
-
const __vue_component__$
|
|
3625
|
-
{ render: __vue_render__$
|
|
3626
|
-
__vue_inject_styles__$
|
|
3627
|
-
__vue_script__$
|
|
3628
|
-
__vue_scope_id__$
|
|
3629
|
-
__vue_is_functional_template__$
|
|
3630
|
-
__vue_module_identifier__$
|
|
3634
|
+
const __vue_component__$t = /*#__PURE__*/normalizeComponent(
|
|
3635
|
+
{ render: __vue_render__$t, staticRenderFns: __vue_staticRenderFns__$t },
|
|
3636
|
+
__vue_inject_styles__$t,
|
|
3637
|
+
__vue_script__$t,
|
|
3638
|
+
__vue_scope_id__$t,
|
|
3639
|
+
__vue_is_functional_template__$t,
|
|
3640
|
+
__vue_module_identifier__$t,
|
|
3631
3641
|
false,
|
|
3632
3642
|
createInjector,
|
|
3633
3643
|
undefined,
|
|
@@ -3635,7 +3645,7 @@ __vue_render__$s._withStripped = true;
|
|
|
3635
3645
|
);
|
|
3636
3646
|
|
|
3637
3647
|
//
|
|
3638
|
-
var script$
|
|
3648
|
+
var script$s = {
|
|
3639
3649
|
name: 'ele-step-model',
|
|
3640
3650
|
props: {
|
|
3641
3651
|
stepMeta: {
|
|
@@ -3826,10 +3836,10 @@ var script$r = {
|
|
|
3826
3836
|
};
|
|
3827
3837
|
|
|
3828
3838
|
/* script */
|
|
3829
|
-
const __vue_script__$
|
|
3839
|
+
const __vue_script__$s = script$s;
|
|
3830
3840
|
|
|
3831
3841
|
/* template */
|
|
3832
|
-
var __vue_render__$
|
|
3842
|
+
var __vue_render__$s = function () {
|
|
3833
3843
|
var _vm = this;
|
|
3834
3844
|
var _h = _vm.$createElement;
|
|
3835
3845
|
var _c = _vm._self._c || _h;
|
|
@@ -3895,34 +3905,34 @@ var __vue_render__$r = function () {
|
|
|
3895
3905
|
),
|
|
3896
3906
|
])
|
|
3897
3907
|
};
|
|
3898
|
-
var __vue_staticRenderFns__$
|
|
3899
|
-
__vue_render__$
|
|
3908
|
+
var __vue_staticRenderFns__$s = [];
|
|
3909
|
+
__vue_render__$s._withStripped = true;
|
|
3900
3910
|
|
|
3901
3911
|
/* style */
|
|
3902
|
-
const __vue_inject_styles__$
|
|
3912
|
+
const __vue_inject_styles__$s = function (inject) {
|
|
3903
3913
|
if (!inject) return
|
|
3904
3914
|
inject("data-v-1919f228_0", { source: ".ele-step-model__wrapper[data-v-1919f228] {\n width: 100%;\n height: 100vh;\n position: relative;\n}\n.ele-step-model__wrapper .ele-step-model__step--wrapper[data-v-1919f228] {\n width: 100%;\n height: 64px;\n padding: 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n background: #fff;\n}\n.ele-step-model__wrapper .ele-step-model__step--wrapper .ele-steps .ant-steps-item[data-v-1919f228] {\n text-align: left;\n}\n.ele-step-model__wrapper .ele-step-model__content--wrapper[data-v-1919f228] {\n width: 100%;\n width: 100%;\n margin-top: 16px;\n margin-bottom: 16px;\n height: calc(100vh - 64px - 64px - 16px - 16px);\n overflow: auto;\n}\n.ele-step-model__wrapper .ele-step-model__footer--wrapper[data-v-1919f228] {\n width: 100%;\n height: 64px;\n background: #fff;\n position: absolute;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/models/step-model/src/index.vue","index.vue"],"names":[],"mappings":"AAwLA;EACA,WAAA;EACA,aAAA;EACA,kBAAA;ACvLA;ADwLA;EACA,WAAA;EACA,YAAA;EACA,aAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,gBAAA;ACtLA;ADwLA;EACA,gBAAA;ACtLA;AD0LA;EACA,WAAA;EACA,WAAA;EACA,gBAAA;EACA,mBAAA;EACA,+CAAA;EACA,cAAA;ACxLA;AD0LA;EACA,WAAA;EACA,YAAA;EACA,gBAAA;EACA,kBAAA;EACA,SAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,oBAAA;ACxLA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"ele-step-model__wrapper\">\n <div class=\"ele-step-model__step--wrapper\">\n <a-steps class=\"ele-steps\" :current=\"current\" size=\"small\">\n <a-step v-for=\"step in elements\" :title=\"step.title\" :key=\"step.key\" />\n </a-steps>\n </div>\n <div class=\"ele-step-model__content--wrapper\">\n <template v-for=\"name in scopedSlotsNames\">\n <div :key=\"name\" v-if=\"currentSlotName == name\" :class=\"['ele-step-model__slot', `ele-step-model__slot--${name}`]\">\n <slot :name=\"name\"></slot>\n </div>\n </template>\n </div>\n <div class=\"ele-step-model__footer--wrapper\">\n <ele-button-group v-on=\"assignAttrForEvents\" :data-source=\"footerElements\"></ele-button-group>\n </div>\n </div>\n</template>\n\n<script>\nimport { BUILT_IN_EVENT_NAMES, CONTEXT } from '../../../utils'\nimport { parse } from '@idooel/expression'\nimport { type } from '@idooel/shared'\nexport default {\n name: 'ele-step-model',\n props: {\n stepMeta: {\n type: Object,\n default: () => ({})\n },\n footerMeta: {\n type: Object,\n default: () => ({})\n }\n },\n data() {\n return {\n current: 0,\n currentSlotComponentRef: null,\n innerFooterElements: []\n }\n },\n provide() {\n return {\n [CONTEXT]: () => {\n return {\n ...this.expressionData\n }\n }\n }\n },\n computed: {\n routeMetaDisabled () {\n return this.executeExpression(this.$route.meta.disabled)\n },\n expressionData () {\n return {\n current: this.current,\n _route: this.$route.query,\n _routeMeta: this.$route.meta\n }\n },\n currentSlotName () {\n return this.scopedSlotsNames[this.current]\n },\n footerElements () {\n return this.innerFooterElements\n },\n assignAttrForEvents () {\n const events = this.footerElements.reduce((ret, ele) => {\n ret[ele.eventName] = (e) => {\n this.evalShowExpressionForFooterElements()\n this.$emit(ele.eventName || 'click', { ...e, exposed: this.exposedMethods })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events,\n [BUILT_IN_EVENT_NAMES.NEXT]: this[BUILT_IN_EVENT_NAMES.NEXT],\n [BUILT_IN_EVENT_NAMES.PREVIOUS]: this[BUILT_IN_EVENT_NAMES.PREVIOUS],\n [BUILT_IN_EVENT_NAMES.SUBMIT]: this[BUILT_IN_EVENT_NAMES.SUBMIT]\n }\n },\n activeIndex () {\n const { activeIndex } = this.stepMeta\n return activeIndex\n },\n elements () {\n const { elements } = this.stepMeta\n return elements\n },\n scopedSlotsNames () {\n const slotNames = this.elements.map(item => item.key)\n return slotNames\n },\n exposedMethods () {\n return {\n slotRef: this.currentSlotComponentRef,\n setCurrentStep: this.setCurrentStep,\n next: this.nextStep,\n prev: this.prevStep,\n current: this.current\n }\n }\n },\n watch: {\n activeIndex: {\n handler (idx) {\n this.current = idx\n },\n immediate: true\n },\n current: {\n handler () {\n this.$nextTick(() => {\n this.currentSlotComponentRef = this.getCurrentSlotComponentRef()\n })\n },\n immediate: true\n }\n },\n created () {\n const { elements } = this.footerMeta\n this.innerFooterElements = elements.call(this)\n this.evalShowExpressionForFooterElements()\n },\n methods: {\n executeExpression (expression) {\n if (type.isBool(expression)) return expression\n if (type.isEmpty(expression)) return false\n return parse(expression, { ...this.expressionData })\n },\n evalShowExpressionForFooterElements () {\n this.innerFooterElements = this.innerFooterElements.map(element => {\n const { show = true, key, eventName } = element\n if(key == BUILT_IN_EVENT_NAMES.SUBMIT || eventName == BUILT_IN_EVENT_NAMES.SUBMIT) {\n // built in submit button should according to the route meta disabled\n this.$set(element, '_show', this.executeExpression(show, this.expressionData) && !this.routeMetaDisabled)\n return element\n }\n show && this.$set(element, '_show', this.executeExpression(show, this.expressionData))\n return element\n })\n },\n getCurrentSlotComponentRef () {\n const includeMetaCmp = this.$children.find(child => child.meta)\n if (!includeMetaCmp) return null\n const { $children: components } = includeMetaCmp\n const target = components.find(cmp => cmp.$options._componentTag === 'ele-tpl')\n return target.getModel ? target.getModel() : null\n },\n setCurrentStep (index) {\n this.current = index\n this.evalShowExpressionForFooterElements()\n },\n nextStep () {\n if (this.current >= this.elements.length - 1) return\n this.current ++\n this.evalShowExpressionForFooterElements()\n },\n prevStep () {\n if (this.current <= 0) return\n this.current --\n this.evalShowExpressionForFooterElements()\n },\n [BUILT_IN_EVENT_NAMES.NEXT] (props) {\n this.$emit(BUILT_IN_EVENT_NAMES.NEXT, { ...props, exposed: { ...this.exposedMethods } })\n },\n [BUILT_IN_EVENT_NAMES.PREVIOUS] (props) {\n this.$emit(BUILT_IN_EVENT_NAMES.PREVIOUS, { ...props, exposed: { ...this.exposedMethods } })\n },\n [BUILT_IN_EVENT_NAMES.SUBMIT] (props) {\n const currentComponent = this.getCurrentSlotComponentRef() || {}\n const hasSubmitMethod = currentComponent.hasOwnProperty(BUILT_IN_EVENT_NAMES.SUBMIT)\n hasSubmitMethod && currentComponent[BUILT_IN_EVENT_NAMES.SUBMIT]()\n this.$emit(BUILT_IN_EVENT_NAMES.SUBMIT, { ...props, exposed: { ...this.exposedMethods } })\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.ele-step-model__wrapper {\n width: 100%;\n height: 100vh;\n position: relative;\n .ele-step-model__step--wrapper {\n width: 100%;\n height: 64px;\n padding: 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n background: #fff;\n .ele-steps {\n .ant-steps-item {\n text-align: left;\n }\n }\n }\n .ele-step-model__content--wrapper {\n width: 100%;\n width: 100%;\n margin-top: 16px;\n margin-bottom: 16px;\n height: calc(100vh - 64px - 64px - 16px - 16px);\n overflow: auto;\n }\n .ele-step-model__footer--wrapper {\n width: 100%;\n height: 64px;\n background: #fff;\n position: absolute;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n }\n}\n</style>import meta from '@/views/tree-table-page/meta'import meta from '@/views/tree-table-page/meta'\n\n",".ele-step-model__wrapper {\n width: 100%;\n height: 100vh;\n position: relative;\n}\n.ele-step-model__wrapper .ele-step-model__step--wrapper {\n width: 100%;\n height: 64px;\n padding: 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n background: #fff;\n}\n.ele-step-model__wrapper .ele-step-model__step--wrapper .ele-steps .ant-steps-item {\n text-align: left;\n}\n.ele-step-model__wrapper .ele-step-model__content--wrapper {\n width: 100%;\n width: 100%;\n margin-top: 16px;\n margin-bottom: 16px;\n height: calc(100vh - 64px - 64px - 16px - 16px);\n overflow: auto;\n}\n.ele-step-model__wrapper .ele-step-model__footer--wrapper {\n width: 100%;\n height: 64px;\n background: #fff;\n position: absolute;\n bottom: 0;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: end;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
3905
3915
|
|
|
3906
3916
|
};
|
|
3907
3917
|
/* scoped */
|
|
3908
|
-
const __vue_scope_id__$
|
|
3918
|
+
const __vue_scope_id__$s = "data-v-1919f228";
|
|
3909
3919
|
/* module identifier */
|
|
3910
|
-
const __vue_module_identifier__$
|
|
3920
|
+
const __vue_module_identifier__$s = undefined;
|
|
3911
3921
|
/* functional template */
|
|
3912
|
-
const __vue_is_functional_template__$
|
|
3922
|
+
const __vue_is_functional_template__$s = false;
|
|
3913
3923
|
/* style inject SSR */
|
|
3914
3924
|
|
|
3915
3925
|
/* style inject shadow dom */
|
|
3916
3926
|
|
|
3917
3927
|
|
|
3918
3928
|
|
|
3919
|
-
const __vue_component__$
|
|
3920
|
-
{ render: __vue_render__$
|
|
3921
|
-
__vue_inject_styles__$
|
|
3922
|
-
__vue_script__$
|
|
3923
|
-
__vue_scope_id__$
|
|
3924
|
-
__vue_is_functional_template__$
|
|
3925
|
-
__vue_module_identifier__$
|
|
3929
|
+
const __vue_component__$s = /*#__PURE__*/normalizeComponent(
|
|
3930
|
+
{ render: __vue_render__$s, staticRenderFns: __vue_staticRenderFns__$s },
|
|
3931
|
+
__vue_inject_styles__$s,
|
|
3932
|
+
__vue_script__$s,
|
|
3933
|
+
__vue_scope_id__$s,
|
|
3934
|
+
__vue_is_functional_template__$s,
|
|
3935
|
+
__vue_module_identifier__$s,
|
|
3926
3936
|
false,
|
|
3927
3937
|
createInjector,
|
|
3928
3938
|
undefined,
|
|
@@ -3930,7 +3940,7 @@ __vue_render__$r._withStripped = true;
|
|
|
3930
3940
|
);
|
|
3931
3941
|
|
|
3932
3942
|
//
|
|
3933
|
-
var script$
|
|
3943
|
+
var script$r = {
|
|
3934
3944
|
name: 'ele-tpl',
|
|
3935
3945
|
props: {
|
|
3936
3946
|
modelName: {
|
|
@@ -3938,10 +3948,10 @@ var script$q = {
|
|
|
3938
3948
|
}
|
|
3939
3949
|
},
|
|
3940
3950
|
components: {
|
|
3951
|
+
[__vue_component__$v.name]: __vue_component__$v,
|
|
3941
3952
|
[__vue_component__$u.name]: __vue_component__$u,
|
|
3942
|
-
[__vue_component__$
|
|
3943
|
-
[__vue_component__$
|
|
3944
|
-
[__vue_component__$s.name]: __vue_component__$s
|
|
3953
|
+
[__vue_component__$s.name]: __vue_component__$s,
|
|
3954
|
+
[__vue_component__$t.name]: __vue_component__$t
|
|
3945
3955
|
},
|
|
3946
3956
|
computed: {
|
|
3947
3957
|
modelNameValidator() {
|
|
@@ -3963,10 +3973,10 @@ var script$q = {
|
|
|
3963
3973
|
};
|
|
3964
3974
|
|
|
3965
3975
|
/* script */
|
|
3966
|
-
const __vue_script__$
|
|
3976
|
+
const __vue_script__$r = script$r;
|
|
3967
3977
|
|
|
3968
3978
|
/* template */
|
|
3969
|
-
var __vue_render__$
|
|
3979
|
+
var __vue_render__$r = function () {
|
|
3970
3980
|
var _vm = this;
|
|
3971
3981
|
var _h = _vm.$createElement;
|
|
3972
3982
|
var _c = _vm._self._c || _h;
|
|
@@ -4004,44 +4014,44 @@ var __vue_render__$q = function () {
|
|
|
4004
4014
|
domProps: { innerHTML: _vm._s(_vm.modelNameValidator.message) },
|
|
4005
4015
|
})
|
|
4006
4016
|
};
|
|
4007
|
-
var __vue_staticRenderFns__$
|
|
4008
|
-
__vue_render__$
|
|
4017
|
+
var __vue_staticRenderFns__$r = [];
|
|
4018
|
+
__vue_render__$r._withStripped = true;
|
|
4009
4019
|
|
|
4010
4020
|
/* style */
|
|
4011
|
-
const __vue_inject_styles__$
|
|
4021
|
+
const __vue_inject_styles__$r = function (inject) {
|
|
4012
4022
|
if (!inject) return
|
|
4013
4023
|
inject("data-v-cb05e1de_0", { source: ".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n.margin-t-8 {\n margin-top: 8px;\n}\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":"AAAA;EACE,qBAAqB;AACvB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AAEA;EACE,eAAe;AACjB;AAEA;EACE,+BAA+B;EAC/B,sCAAsC;EACtC,sCAAsC;EACtC,sCAAsC;EACtC,uCAAuC;EACvC,uCAAuC;EACvC,uCAAuC;EACvC,mDAAmD;EACnD,4BAA4B;EAC5B,4BAA4B;EAC5B,0BAA0B;EAC1B,wBAAwB;EACxB,8BAA8B;EAC9B,+BAA+B;EAC/B,qCAAqC;EACrC,gCAAgC;EAChC,4BAA4B;EAC5B,qDAAqD;EACrD,kDAAkD;EAClD,gDAAgD;EAChD,gCAAgC;EAChC,uCAAuC;EACvC,yBAAyB;EACzB,yBAAyB;EACzB,oCAAoC;AACtC;AAEA;EACE,4DAA4D;AAC9D;AAEA;EACE,4DAA4D;AAC9D;;AAEA,oCAAoC","file":"index.vue","sourcesContent":[".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n\n.margin-t-8 {\n margin-top: 8px;\n}\n\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
4014
4024
|
|
|
4015
4025
|
};
|
|
4016
4026
|
/* scoped */
|
|
4017
|
-
const __vue_scope_id__$
|
|
4027
|
+
const __vue_scope_id__$r = undefined;
|
|
4018
4028
|
/* module identifier */
|
|
4019
|
-
const __vue_module_identifier__$
|
|
4029
|
+
const __vue_module_identifier__$r = undefined;
|
|
4020
4030
|
/* functional template */
|
|
4021
|
-
const __vue_is_functional_template__$
|
|
4031
|
+
const __vue_is_functional_template__$r = false;
|
|
4022
4032
|
/* style inject SSR */
|
|
4023
4033
|
|
|
4024
4034
|
/* style inject shadow dom */
|
|
4025
4035
|
|
|
4026
4036
|
|
|
4027
4037
|
|
|
4028
|
-
const __vue_component__$
|
|
4029
|
-
{ render: __vue_render__$
|
|
4030
|
-
__vue_inject_styles__$
|
|
4031
|
-
__vue_script__$
|
|
4032
|
-
__vue_scope_id__$
|
|
4033
|
-
__vue_is_functional_template__$
|
|
4034
|
-
__vue_module_identifier__$
|
|
4038
|
+
const __vue_component__$r = /*#__PURE__*/normalizeComponent(
|
|
4039
|
+
{ render: __vue_render__$r, staticRenderFns: __vue_staticRenderFns__$r },
|
|
4040
|
+
__vue_inject_styles__$r,
|
|
4041
|
+
__vue_script__$r,
|
|
4042
|
+
__vue_scope_id__$r,
|
|
4043
|
+
__vue_is_functional_template__$r,
|
|
4044
|
+
__vue_module_identifier__$r,
|
|
4035
4045
|
false,
|
|
4036
4046
|
createInjector,
|
|
4037
4047
|
undefined,
|
|
4038
4048
|
undefined
|
|
4039
4049
|
);
|
|
4040
4050
|
|
|
4041
|
-
__vue_component__$
|
|
4051
|
+
__vue_component__$r.install = Vue => Vue.component(__vue_component__$r.name, __vue_component__$r);
|
|
4042
4052
|
|
|
4043
4053
|
//
|
|
4044
|
-
var script$
|
|
4054
|
+
var script$q = {
|
|
4045
4055
|
name: 'ele-form',
|
|
4046
4056
|
props: {
|
|
4047
4057
|
disabled: {
|
|
@@ -4178,10 +4188,10 @@ var script$p = {
|
|
|
4178
4188
|
};
|
|
4179
4189
|
|
|
4180
4190
|
/* script */
|
|
4181
|
-
const __vue_script__$
|
|
4191
|
+
const __vue_script__$q = script$q;
|
|
4182
4192
|
|
|
4183
4193
|
/* template */
|
|
4184
|
-
var __vue_render__$
|
|
4194
|
+
var __vue_render__$q = function () {
|
|
4185
4195
|
var _vm = this;
|
|
4186
4196
|
var _h = _vm.$createElement;
|
|
4187
4197
|
var _c = _vm._self._c || _h;
|
|
@@ -4615,41 +4625,41 @@ var __vue_render__$p = function () {
|
|
|
4615
4625
|
1
|
|
4616
4626
|
)
|
|
4617
4627
|
};
|
|
4618
|
-
var __vue_staticRenderFns__$
|
|
4619
|
-
__vue_render__$
|
|
4628
|
+
var __vue_staticRenderFns__$q = [];
|
|
4629
|
+
__vue_render__$q._withStripped = true;
|
|
4620
4630
|
|
|
4621
4631
|
/* style */
|
|
4622
|
-
const __vue_inject_styles__$
|
|
4632
|
+
const __vue_inject_styles__$q = function (inject) {
|
|
4623
4633
|
if (!inject) return
|
|
4624
4634
|
inject("data-v-80dc2882_0", { source: ".ele__form--wrapper[data-v-80dc2882] {\n background: #fff;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/form/src/index.vue","index.vue"],"names":[],"mappings":"AAwPA;EACA,gBAAA;ACvPA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"ele__form--wrapper\">\n <a-form :form=\"form\" layout=\"vertical\" class=\"ant-advanced-search-form\">\n <a-row :gutter=\"24\">\n <template v-for=\"ele in elements\">\n <a-col v-if=\"executeExpression(ele._show)\" :span=\"ele.span\" :key=\"ele.name\">\n <template v-if=\"ele.type == 'Input'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-input \n @change=\"onChange($event, ele)\" \n :disabled=\"executeExpression(ele._disabled)\" \n :max-length=\"ele.maxLength\" \n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n style=\"width:100%;\">\n </ele-input>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'Textarea'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-textarea \n @change=\"onChange($event, ele)\"\n :max-length=\"ele.maxLength\"\n :autosize=\"ele.autosize\"\n :disabled=\"executeExpression(ele._disabled)\"\n :allow-clear=\"ele.allowClear\"\n :placeholder=\"ele.placeholder\"\n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\"\n style=\"width:100%;\">\n </ele-textarea>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'Select'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-select \n :data-source=\"ele.optionList\" \n :disabled=\"executeExpression(ele._disabled)\"\n :multiple=\"ele.multiple\"\n :mode=\"ele.mode\"\n :code=\"ele.code\" \n :params=\"ele.params\" \n @change=\"onChange($event, ele)\"\n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n style=\"width:100%;\">\n </ele-select>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'ele-upload'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-upload v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n :ext=\"ele.ext\"\n :multiple=\"ele.multiple\"\n :accept=\"ele.accept\"\n :extensions=\"ele.extensions\"\n :size=\"ele.size\"\n :icon=\"ele.icon\"\n :url=\"ele.url\"\n :message=\"ele.message\" \n style=\"width:100%;\">\n </ele-upload>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'ele-date-range'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-date-range \n :disabled=\"executeExpression(ele._disabled)\" \n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n style=\"width:100%;\">\n </ele-date-range>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'ele-date'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-date\n :format=\"ele.format\"\n :mode=\"ele.mode\"\n :show-time=\"ele.showTime\"\n :show-today=\"ele.showToday\"\n :value-format=\"ele.valueFormat\"\n :disabled=\"executeExpression(ele._disabled)\" \n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n style=\"width:100%;\">\n </ele-date>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'SelectEntity'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-select-entity \n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n style=\"width:100%;\">\n </ele-select-entity>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'InputNumber'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-input-number \n @change=\"onChange($event, ele)\" \n :precision=\"ele.precision\" \n :disabled=\"executeExpression(ele._disabled)\" \n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n v-bind=\"ele.props\" \n style=\"width:100%;\">\n </ele-input-number>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'Checkbox'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-checkbox \n :data-source=\"ele.optionList\" \n :disabled=\"executeExpression(ele._disabled)\" \n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n style=\"width:100%;\">\n </ele-checkbox>\n </a-form-item>\n </template>\n <template v-else-if=\"ele.type == 'Radio'\">\n <a-form-item :label=\"`${ele.label}:`\">\n <ele-radio \n @change=\"onChange($event, ele)\" \n :disabled=\"executeExpression(ele._disabled)\" \n :data-source=\"ele.optionList\" \n v-decorator=\"[ele.name, { rules: rebuildRules(ele.rules) }]\" \n style=\"width:100%;\">\n </ele-radio>\n </a-form-item>\n </template>\n </a-col>\n </template>\n </a-row>\n </a-form>\n </div>\n</template>\n\n<script>\nimport { parse } from '@idooel/expression'\nimport { type } from '@idooel/shared'\nexport default {\n name: 'ele-form',\n props: {\n disabled: {\n type: [Boolean, String],\n default: '_routeMeta.disabled'\n },\n formName: {\n type: [Number, String],\n default: 'coordinated'\n },\n elements: {\n type: Array,\n default: () => []\n }\n },\n data () {\n return {}\n },\n computed: {\n globalDisabled () {\n return this.executeExpression(this.disabled)\n },\n form () {\n return this.$form.createForm(this, { name: this.formName })\n },\n exposedMethods () {\n return {\n setFieldsValue: this.setFieldsValue,\n getFieldsValue: this.getFieldsValue\n }\n }\n },\n methods: {\n rebuildRules (rules = []) {\n //TODO\n rules.map(rule => {\n const { validator } = rule\n if (validator) {\n validator.formModel = this.getFieldsValue()\n validator.exposed = this.exposedMethods\n }\n })\n return rules\n },\n dispatchExpression () {\n this.evalDisabledExpression()\n this.evalShowExpression()\n },\n evalDisabledExpression () {\n this.elements.forEach(ele => {\n if (this.globalDisabled) return this.$set(ele, '_disabled', true)\n const { disabled } = ele\n const ret = this.executeExpression(disabled)\n this.$set(ele, '_disabled', ret)\n })\n },\n evalShowExpression () {\n this.elements.forEach(ele => {\n const { show = true } = ele\n const ret = this.executeExpression(show)\n this.$set(ele, '_show', ret)\n })\n },\n executeExpression (expression) {\n if (type.isBool(expression)) return expression\n if (type.isEmpty(expression)) return false\n return parse(expression, { ...this.getFieldsValue(), _route: this.$route.query, _routeMeta: this.$route.meta })\n },\n onChange (value, props) {\n const { name } = props\n this.setFieldsValue({ [name]: value })\n this.dispatchExpression()\n this.$emit('change', { value, props, exposed: { ...this.exposedMethods } })\n },\n collectDefaultValues () {\n const ret = this.elements.reduce((ret, props) => {\n const { name, defaultValue } = props\n if (defaultValue) {\n ret[name] = defaultValue\n }\n return ret\n }, {})\n return ret\n },\n setDefaultValues () {\n const defaultValues = this.collectDefaultValues()\n this.setFieldsValue(defaultValues)\n },\n validateFields () {\n let ret = false\n this.form.validateFields((error, values) => {\n ret = !error\n })\n return ret\n },\n setFieldsValue (props = {}) {\n this.form.setFieldsValue(props)\n },\n getFieldsValue () {\n return this.form.getFieldsValue()\n }\n },\n mounted() {\n this.dispatchExpression()\n this.$nextTick(() => {\n this.setDefaultValues()\n })\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.ele__form--wrapper {\n background: #fff;\n .ant-form-item {\n }\n}\n</style>",".ele__form--wrapper {\n background: #fff;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
4625
4635
|
|
|
4626
4636
|
};
|
|
4627
4637
|
/* scoped */
|
|
4628
|
-
const __vue_scope_id__$
|
|
4638
|
+
const __vue_scope_id__$q = "data-v-80dc2882";
|
|
4629
4639
|
/* module identifier */
|
|
4630
|
-
const __vue_module_identifier__$
|
|
4640
|
+
const __vue_module_identifier__$q = undefined;
|
|
4631
4641
|
/* functional template */
|
|
4632
|
-
const __vue_is_functional_template__$
|
|
4642
|
+
const __vue_is_functional_template__$q = false;
|
|
4633
4643
|
/* style inject SSR */
|
|
4634
4644
|
|
|
4635
4645
|
/* style inject shadow dom */
|
|
4636
4646
|
|
|
4637
4647
|
|
|
4638
4648
|
|
|
4639
|
-
const __vue_component__$
|
|
4640
|
-
{ render: __vue_render__$
|
|
4641
|
-
__vue_inject_styles__$
|
|
4642
|
-
__vue_script__$
|
|
4643
|
-
__vue_scope_id__$
|
|
4644
|
-
__vue_is_functional_template__$
|
|
4645
|
-
__vue_module_identifier__$
|
|
4649
|
+
const __vue_component__$q = /*#__PURE__*/normalizeComponent(
|
|
4650
|
+
{ render: __vue_render__$q, staticRenderFns: __vue_staticRenderFns__$q },
|
|
4651
|
+
__vue_inject_styles__$q,
|
|
4652
|
+
__vue_script__$q,
|
|
4653
|
+
__vue_scope_id__$q,
|
|
4654
|
+
__vue_is_functional_template__$q,
|
|
4655
|
+
__vue_module_identifier__$q,
|
|
4646
4656
|
false,
|
|
4647
4657
|
createInjector,
|
|
4648
4658
|
undefined,
|
|
4649
4659
|
undefined
|
|
4650
4660
|
);
|
|
4651
4661
|
|
|
4652
|
-
__vue_component__$
|
|
4662
|
+
__vue_component__$q.install = Vue => Vue.component(__vue_component__$q.name, __vue_component__$q);
|
|
4653
4663
|
|
|
4654
4664
|
//
|
|
4655
4665
|
//
|
|
@@ -4663,7 +4673,7 @@ __vue_component__$p.install = Vue => Vue.component(__vue_component__$p.name, __v
|
|
|
4663
4673
|
//
|
|
4664
4674
|
//
|
|
4665
4675
|
|
|
4666
|
-
var script$
|
|
4676
|
+
var script$p = {
|
|
4667
4677
|
name: 'ele-alert',
|
|
4668
4678
|
props: {
|
|
4669
4679
|
type: {
|
|
@@ -4692,10 +4702,10 @@ var script$o = {
|
|
|
4692
4702
|
};
|
|
4693
4703
|
|
|
4694
4704
|
/* script */
|
|
4695
|
-
const __vue_script__$
|
|
4705
|
+
const __vue_script__$p = script$p;
|
|
4696
4706
|
|
|
4697
4707
|
/* template */
|
|
4698
|
-
var __vue_render__$
|
|
4708
|
+
var __vue_render__$p = function () {
|
|
4699
4709
|
var _vm = this;
|
|
4700
4710
|
var _h = _vm.$createElement;
|
|
4701
4711
|
var _c = _vm._self._c || _h;
|
|
@@ -4711,44 +4721,44 @@ var __vue_render__$o = function () {
|
|
|
4711
4721
|
},
|
|
4712
4722
|
})
|
|
4713
4723
|
};
|
|
4714
|
-
var __vue_staticRenderFns__$
|
|
4715
|
-
__vue_render__$
|
|
4724
|
+
var __vue_staticRenderFns__$p = [];
|
|
4725
|
+
__vue_render__$p._withStripped = true;
|
|
4716
4726
|
|
|
4717
4727
|
/* style */
|
|
4718
|
-
const __vue_inject_styles__$
|
|
4728
|
+
const __vue_inject_styles__$p = function (inject) {
|
|
4719
4729
|
if (!inject) return
|
|
4720
4730
|
inject("data-v-ee7d6de4_0", { source: ".ele-alert[data-v-ee7d6de4] {\n text-align: left !important;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/alert/src/index.vue","index.vue"],"names":[],"mappings":"AA0CA;EACA,2BAAA;ACzCA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <a-alert\n class=\"ele-alert\"\n :message=\"message\" \n :description=\"description\" \n :type=\"type\"\n :closable=\"closable\"\n :closeText=\"closeText\"\n :show-icon=\"showIcon\" />\n</template>\n\n<script>\nexport default {\n name: 'ele-alert',\n props: {\n type: {\n type: String,\n default: 'success'\n },\n showIcon: {\n type: Boolean,\n default: true\n },\n message: {\n type: String,\n default: 'Success Tips'\n },\n description: {\n type: String\n },\n closable: {\n type: Boolean,\n default: true\n },\n closeText: {\n type: String\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.ele-alert {\n text-align: left !important;\n}\n</style>",".ele-alert {\n text-align: left !important;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
4721
4731
|
|
|
4722
4732
|
};
|
|
4723
4733
|
/* scoped */
|
|
4724
|
-
const __vue_scope_id__$
|
|
4734
|
+
const __vue_scope_id__$p = "data-v-ee7d6de4";
|
|
4725
4735
|
/* module identifier */
|
|
4726
|
-
const __vue_module_identifier__$
|
|
4736
|
+
const __vue_module_identifier__$p = undefined;
|
|
4727
4737
|
/* functional template */
|
|
4728
|
-
const __vue_is_functional_template__$
|
|
4738
|
+
const __vue_is_functional_template__$p = false;
|
|
4729
4739
|
/* style inject SSR */
|
|
4730
4740
|
|
|
4731
4741
|
/* style inject shadow dom */
|
|
4732
4742
|
|
|
4733
4743
|
|
|
4734
4744
|
|
|
4735
|
-
const __vue_component__$
|
|
4736
|
-
{ render: __vue_render__$
|
|
4737
|
-
__vue_inject_styles__$
|
|
4738
|
-
__vue_script__$
|
|
4739
|
-
__vue_scope_id__$
|
|
4740
|
-
__vue_is_functional_template__$
|
|
4741
|
-
__vue_module_identifier__$
|
|
4745
|
+
const __vue_component__$p = /*#__PURE__*/normalizeComponent(
|
|
4746
|
+
{ render: __vue_render__$p, staticRenderFns: __vue_staticRenderFns__$p },
|
|
4747
|
+
__vue_inject_styles__$p,
|
|
4748
|
+
__vue_script__$p,
|
|
4749
|
+
__vue_scope_id__$p,
|
|
4750
|
+
__vue_is_functional_template__$p,
|
|
4751
|
+
__vue_module_identifier__$p,
|
|
4742
4752
|
false,
|
|
4743
4753
|
createInjector,
|
|
4744
4754
|
undefined,
|
|
4745
4755
|
undefined
|
|
4746
4756
|
);
|
|
4747
4757
|
|
|
4748
|
-
__vue_component__$
|
|
4758
|
+
__vue_component__$p.install = Vue => Vue.component(__vue_component__$p.name, __vue_component__$p);
|
|
4749
4759
|
|
|
4750
4760
|
//
|
|
4751
|
-
var script$
|
|
4761
|
+
var script$o = {
|
|
4752
4762
|
name: 'ele-upload',
|
|
4753
4763
|
components: {
|
|
4754
4764
|
FileUpload
|
|
@@ -5089,10 +5099,10 @@ var script$n = {
|
|
|
5089
5099
|
};
|
|
5090
5100
|
|
|
5091
5101
|
/* script */
|
|
5092
|
-
const __vue_script__$
|
|
5102
|
+
const __vue_script__$o = script$o;
|
|
5093
5103
|
|
|
5094
5104
|
/* template */
|
|
5095
|
-
var __vue_render__$
|
|
5105
|
+
var __vue_render__$o = function () {
|
|
5096
5106
|
var _vm = this;
|
|
5097
5107
|
var _h = _vm.$createElement;
|
|
5098
5108
|
var _c = _vm._self._c || _h;
|
|
@@ -5254,41 +5264,41 @@ var __vue_render__$n = function () {
|
|
|
5254
5264
|
1
|
|
5255
5265
|
)
|
|
5256
5266
|
};
|
|
5257
|
-
var __vue_staticRenderFns__$
|
|
5258
|
-
__vue_render__$
|
|
5267
|
+
var __vue_staticRenderFns__$o = [];
|
|
5268
|
+
__vue_render__$o._withStripped = true;
|
|
5259
5269
|
|
|
5260
5270
|
/* style */
|
|
5261
|
-
const __vue_inject_styles__$
|
|
5271
|
+
const __vue_inject_styles__$o = function (inject) {
|
|
5262
5272
|
if (!inject) return
|
|
5263
5273
|
inject("data-v-d2929816_0", { source: "[data-v-d2929816] .ele-upload__inner {\n opacity: 1 !important;\n cursor: pointer;\n border: 1px dashed var(--idooel-form-title-border-color);\n background: var(--idooel-form-upload-bg-color) !important;\n border-radius: var(--idooel-form-border-radius);\n}\n[data-v-d2929816] .ele-upload__inner:hover {\n border-color: var(--idooel-form-upload-border-hover-color);\n}\n.ele-upload__wrapper[data-v-d2929816] {\n width: 100%;\n}\n.ele-upload__wrapper .ele-upload__area[data-v-d2929816] {\n padding: 16px;\n width: 100%;\n height: 80px;\n display: flex;\n flex-direction: row;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--icon[data-v-d2929816] {\n color: var(--idooel-primary-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n font-size: 16x;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload[data-v-d2929816] {\n font-size: 48px;\n color: var(--idooel-primary-color);\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--icon .anticon[data-v-d2929816] {\n font-size: 48px;\n color: var(--idooel-primary-color);\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--text[data-v-d2929816] {\n margin-left: 16px;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--text .ele-upload__message[data-v-d2929816] {\n font-size: 16px;\n color: var(--idoole-black-088);\n text-align: left;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--text .ele-upload__ext[data-v-d2929816] {\n text-align: left;\n font-size: 14px;\n color: var(--idoole-black-06);\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item[data-v-d2929816] {\n width: 100%;\n margin-top: 8px;\n padding: 8px 12px;\n border-radius: var(--idooel-form-border-radius);\n background: var(--idooel-form-upload-bg-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__name[data-v-d2929816] {\n flex: 1;\n text-align: left;\n white-space: nowrap;\n overflow: hidden;\n font-size: 14px;\n margin-left: 8px;\n cursor: pointer;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__name .ele-file__inner[data-v-d2929816] {\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__delete[data-v-d2929816] {\n margin-left: 8px;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__delete .ele-file__delete--icon[data-v-d2929816] {\n margin-left: 8px;\n cursor: pointer;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/upload/src/index.vue","index.vue"],"names":[],"mappings":"AA2WA;EACA,qBAAA;EACA,eAAA;EACA,wDAAA;EACA,yDAAA;EAIA,+CAAA;AC7WA;AD0WA;EACA,0DAAA;ACxWA;AD4WA;EACA,WAAA;ACzWA;AD0WA;EACA,aAAA;EACA,WAAA;EACA,YAAA;EACA,aAAA;EACA,mBAAA;ACxWA;ADyWA;EACA,kCAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,cAAA;ACvWA;ADwWA;EACA,eAAA;EACA,kCAAA;ACtWA;ADwWA;EACA,eAAA;EACA,kCAAA;ACtWA;ADyWA;EACA,iBAAA;ACvWA;ADwWA;EACA,eAAA;EACA,8BAAA;EACA,gBAAA;ACtWA;ADwWA;EACA,gBAAA;EACA,eAAA;EACA,6BAAA;ACtWA;AD2WA;EACA,WAAA;EACA,eAAA;EACA,iBAAA;EACA,+CAAA;EACA,8CAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;ACzWA;AD2WA;EACA,OAAA;EACA,gBAAA;EACA,mBAAA;EACA,gBAAA;EACA,eAAA;EACA,gBAAA;EACA,eAAA;ACzWA;AD0WA;EACA,gBAAA;EACA,uBAAA;ACxWA;AD2WA;EACA,gBAAA;ACzWA;AD0WA;EACA,gBAAA;EACA,eAAA;ACxWA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"ele-upload__wrapper\">\n <FileUpload\n class=\"ele-upload__inner\"\n v-show=\"isShowUploadContainer\"\n v-model=\"files\"\n :ref=\"uploadRef\"\n :drop=\"drop\"\n :chunk-enabled=\"chunkEnabled\"\n :chunk=\"chunkConfig\"\n :accept=\"accept\"\n :extensions=\"extensions\"\n :size=\"fileSizeLimit\"\n :post-action=\"postAction\"\n :multiple=\"multiple\"\n :headers=\"headers\"\n :maximum=\"getMaximum\"\n @input-file=\"onWatchInputFiles\"\n @input=\"onWatchFiles\"\n style=\"width: 100%;\">\n <section class=\"ele-upload__area\">\n <div class=\"ele-upload__area--icon\">\n <template v-if=\"iconIsZhWrod\">\n {{ icon }}\n </template>\n <template v-else>\n <ele-icon :type=\"icon\"></ele-icon>\n </template>\n </div>\n <div class=\"ele-upload__area--text\">\n <div class=\"ele-upload__message\" v-if=\"message\" v-html=\"message\"></div>\n <div class=\"ele-upload__message\" v-else>单击或拖动文件到该区域以上传</div>\n <div class=\"ele-upload__ext\" v-if=\"ext\" v-html=\"ext\"></div>\n <div class=\"ele-upload__ext\" v-else>文件小于{{ size }}M</div>\n </div>\n </section>\n </FileUpload>\n <section class=\"ele-files__wrapper\">\n <div class=\"ele-file__item\" v-for=\"(file, idx) in buildedFiles\" :key=\"idx\">\n <div class=\"ele-file__suffix--icon\">\n <ele-icon :type=\"fileSuffixIcon[file.suffix] ? fileSuffixIcon[file.suffix].name : 'icon-file'\"></ele-icon>\n </div>\n <div class=\"ele-file__name\">\n <div class=\"ele-file__inner\" @click=\"handleClickDownload(file)\">{{ file.name }}</div>\n <div v-if=\"(!file.success && file.progress)\" class=\"ele-uplpad__progress\">\n <a-progress :strokeWidth=\"2\" :percent=\"Number(file.progress)\" size=\"small\" />\n </div>\n </div>\n <div class=\"ele-file__delete\" v-if=\"file.success || file.error || !file.response\">\n <span class=\"ele-file__size\">{{ (file.size / byteConversion).toFixed(2) }}M</span>\n <span class=\"ele-file__delete--icon\" @click=\"handleClickDelete(file)\">\n <ele-icon type=\"delete\"></ele-icon>\n </span>\n </div>\n </div>\n </section>\n </div>\n</template>\n\n<script>\nimport FileUpload from 'vue-upload-component'\nimport { v4 as uuidv4 } from 'uuid'\nimport { route, net, type } from '@idooel/shared'\nexport default {\n name: 'ele-upload',\n components: {\n FileUpload\n },\n model: {\n prop: 'value',\n event: 'change'\n },\n props: {\n url: {\n type: String,\n //TODO\n default: `zuul/api-file/workbench/file`\n },\n icon: {\n type: String,\n default: '上传'\n },\n size: {\n type: Number,\n default: 100\n },\n message: {\n type: String,\n default: '单击或拖动文件到该区域以上传'\n },\n ext: {\n type: String\n },\n extensions: {\n type: String\n },\n accept: {\n type: String\n },\n maximum: {\n type: Number,\n default: 10\n },\n multiple: {\n type: Boolean,\n default: false\n },\n drop: {\n type: Boolean,\n default: true\n },\n value: {\n type: [String, Array]\n },\n querys: {\n type: Object,\n default: () => ({\n _csrf: localStorage.getItem('token'),\n _t: new Date().valueOf()\n })\n },\n headers: {\n type: Object,\n default: () => ({\n 'X-XSRF-TOKEN': localStorage.getItem('token')\n })\n },\n byteConversion: {\n type: Number,\n default: 1024 * 1024\n },\n chunkEnabled: {\n type: Boolean,\n default: true\n }\n },\n data() {\n return {\n files: [],\n buildedFiles: [],\n saveToServerAsyncPageTimer: null\n }\n },\n watch: {\n value: {\n async handler (value) {\n if (type.isArray(value)) {\n // multiple\n } else if (type.isEmpty(value)) {\n this.files = []\n this.buildedFiles = []\n } else {\n // single\n this.fetchFileWithFileId()\n }\n },\n immediate: true\n }\n },\n computed: {\n prefixPath () {\n return window.prefixPath\n },\n iconIsZhWrod () {\n return type.isZhWord(this.icon)\n },\n getPayloads () {\n return {\n override: false\n }\n },\n chunkConfig () {\n return {\n action: `${this.prefixPath}zuul/api-file/workbench/file/temp/chunk/vue`,\n headers: {\n ...this.headers\n },\n minSize: 3 * this.byteConversion,\n maxActive: 3,\n maxRetries: 5,\n startBody: {\n override: true,\n path: '/cw'\n },\n uploadBody: {\n override: true,\n path: '/cw'\n },\n finishBody: {\n override: true,\n path: '/cw'\n }\n }\n },\n isFileUploadSuccessed () {\n return this.files.every(file => file.success)\n },\n isShowUploadContainer () {\n if (this.multiple) {\n if (this.isFileUploadSuccessed && this.buildedFiles.length >= this.maximum) {\n return false\n } else {\n return true\n }\n } else {\n const [file = {}] = this.buildedFiles\n if (this.buildedFiles.length < 1) {\n return true\n }\n if ((this.isFileUploadSuccessed && this.buildedFiles.length >= 1) || !file.response) {\n return false\n } else {\n return true\n }\n }\n },\n getMaximum () {\n return this.multiple ? this.maximum : 1\n },\n fileSizeLimit () {\n return this.size * this.byteConversion\n },\n postAction () {\n const ret = route.toQueryString(this.querys)\n return `${this.prefixPath}${this.url}?${ret}`\n },\n uploadRef () {\n return uuidv4()\n },\n fileSuffixIcon () {\n return {\n 'doc': { name: 'icon-doc' },\n 'html': { name: 'icon-html' },\n 'mp4': { name: 'icon-mp' },\n 'pdf': { name: 'icon-pdf' },\n 'ppt': { name: 'icon-ppt' },\n 'psd': { name: 'icon-psd' },\n 'rtf': { name: 'icon-rtf' },\n 'txt': { name: 'icon-txt' },\n 'vis': { name: 'icon-vis' },\n 'xls': { name: 'icon-xls' },\n 'xml': { name: 'icon-xml' },\n 'zip': { name: 'icon-zip' },\n 'jpg': { name: 'icon-img' },\n 'mp3': { name: 'icon-mp1' },\n }\n },\n fileIds () {\n const fileIds = this.buildedFiles.map(file => {\n return file.fileID\n })\n return this.multiple ? fileIds : fileIds[0]\n },\n fileResponseData () {\n return this.multiple ? this.buildedFiles : this.buildedFiles[0]\n }\n },\n methods: {\n async fetchFileWithFileId () {\n if (!this.value) return\n await net.get(\n `/api-file/file/${this.value}`\n ).then(resp => {\n const { data } = resp\n this.buildedFiles = [data]\n this.files = [data]\n })\n },\n handleClickDownload (file) {\n const { fileID: fileId } = file\n window.open(`/api-file/workbench/file/stream/${fileId}?origin=true`)\n },\n handleClickDelete (file) {\n this.$refs[this.uploadRef].remove(file)\n const { fileID } = file\n this.files = this.files.filter(file => file.fileID !== fileID)\n this.buildedFiles = this.buildedFiles.filter(file => file.fileID !== fileID)\n this.$emit('change', this.fileIds)\n },\n onWatchFiles (files) {\n this.files = files\n this.buildedFiles = this.files.map(file => {\n return {\n ...file.response.data,\n ...file\n }\n })\n if (this.isFileUploadSuccessed) {\n this.$emit('change', this.fileIds)\n this.$emit('on-success', this.fileResponseData)\n }\n },\n async saveToServerAsyncPage (payloads = {}) {\n net.post('zuul/api-file/workbench/file/temp/saveToServerAsyncPage', payloads, { \n headers: {\n 'Content-Type': 'multipart/form-data'\n }\n }).then(resp =>{\n const { data } = resp\n if (data !== 'saveToServerAsyncPage') {\n clearInterval(this.saveToServerAsyncPageTimer)\n }\n })\n // const ret = await net.post({\n // url: 'zuul/api-file/workbench/file/temp/saveToServerAsyncPage',\n // method: 'POST',\n // data: { ...payloads }\n // }).then(resp => {\n // const { data: { data, code, message } } = resp\n // if (code !== '2000') {\n // this.$Message.error(message)\n // return\n // }\n // if (data !== 'saveToServerAsyncPage') {\n // clearInterval(timer)\n // const { fileID, size } = data\n // this.$emit('on-success', { ...data, fileId: fileID })\n // this.$Message.success('同步成功')\n // return { fileId: fileID, size }\n // }\n // })\n // return ret\n },\n onWatchInputFiles (newFile, oldFile) {\n if (newFile && !oldFile) {\n // add file\n console.log('add', newFile)\n }\n if (newFile && oldFile) {\n // update file\n console.log('update', newFile)\n const { success, active, chunk, response } = newFile\n if (chunk && success && !active) {\n console.log('chunk end')\n const { data: { file, type } } = response\n const payloads = {\n filePath: file.match(/\\/cw(.*)/)[0],\n asyncID: uuidv4(),\n isDeleteOrigin: false,\n toImage: type === 'pdf' ? true : false,\n unzip: type === 'zip' ? true : false,\n _csrf: localStorage.getItem('token')\n }\n this.saveToServerAsyncPageTimer = setInterval(() => {\n this.saveToServerAsyncPage(payloads)\n }, 2000)\n }\n }\n if (!newFile && oldFile) {\n // delete file\n console.log('delete')\n }\n if (Boolean(newFile) !== Boolean(oldFile) || oldFile.error !== newFile.error) {\n if (!this.$refs[this.uploadRef].active) {\n this.$refs[this.uploadRef].active = true\n }\n }\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n::v-deep .ele-upload__inner {\n opacity: 1 !important;\n cursor: pointer;\n border: 1px dashed var(--idooel-form-title-border-color);\n background: var(--idooel-form-upload-bg-color) !important;\n &:hover {\n border-color: var(--idooel-form-upload-border-hover-color);\n }\n border-radius: var(--idooel-form-border-radius);\n}\n.ele-upload__wrapper {\n width: 100%;\n .ele-upload__area {\n padding: 16px;\n width: 100%;\n height: 80px;\n display: flex;\n flex-direction: row;\n .ele-upload__area--icon {\n color: var(--idooel-primary-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n font-size: 16x;\n .anticon-cloud-upload {\n font-size: 48px;\n color: var(--idooel-primary-color);\n }\n .anticon {\n font-size: 48px;\n color: var(--idooel-primary-color);\n }\n }\n .ele-upload__area--text {\n margin-left: 16px;\n .ele-upload__message {\n font-size: 16px;\n color: var(--idoole-black-088);\n text-align: left;\n }\n .ele-upload__ext {\n text-align: left;\n font-size: 14px;\n color: var(--idoole-black-06);\n }\n }\n }\n .ele-files__wrapper {\n .ele-file__item {\n width: 100%;\n margin-top: 8px;\n padding: 8px 12px;\n border-radius: var(--idooel-form-border-radius);\n background: var(--idooel-form-upload-bg-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n .ele-file__suffix--icon {}\n .ele-file__name {\n flex: 1;\n text-align: left;\n white-space: nowrap;\n overflow: hidden;\n font-size: 14px;\n margin-left: 8px;\n cursor: pointer;\n .ele-file__inner {\n overflow: hidden;\n text-overflow: ellipsis;\n }\n }\n .ele-file__delete {\n margin-left: 8px;\n .ele-file__delete--icon {\n margin-left: 8px;\n cursor: pointer;\n }\n }\n }\n }\n}\n</style>","::v-deep .ele-upload__inner {\n opacity: 1 !important;\n cursor: pointer;\n border: 1px dashed var(--idooel-form-title-border-color);\n background: var(--idooel-form-upload-bg-color) !important;\n border-radius: var(--idooel-form-border-radius);\n}\n::v-deep .ele-upload__inner:hover {\n border-color: var(--idooel-form-upload-border-hover-color);\n}\n\n.ele-upload__wrapper {\n width: 100%;\n}\n.ele-upload__wrapper .ele-upload__area {\n padding: 16px;\n width: 100%;\n height: 80px;\n display: flex;\n flex-direction: row;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--icon {\n color: var(--idooel-primary-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n font-size: 16x;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n font-size: 48px;\n color: var(--idooel-primary-color);\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--icon .anticon {\n font-size: 48px;\n color: var(--idooel-primary-color);\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--text {\n margin-left: 16px;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--text .ele-upload__message {\n font-size: 16px;\n color: var(--idoole-black-088);\n text-align: left;\n}\n.ele-upload__wrapper .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n text-align: left;\n font-size: 14px;\n color: var(--idoole-black-06);\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item {\n width: 100%;\n margin-top: 8px;\n padding: 8px 12px;\n border-radius: var(--idooel-form-border-radius);\n background: var(--idooel-form-upload-bg-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__name {\n flex: 1;\n text-align: left;\n white-space: nowrap;\n overflow: hidden;\n font-size: 14px;\n margin-left: 8px;\n cursor: pointer;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__name .ele-file__inner {\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__delete {\n margin-left: 8px;\n}\n.ele-upload__wrapper .ele-files__wrapper .ele-file__item .ele-file__delete .ele-file__delete--icon {\n margin-left: 8px;\n cursor: pointer;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
5264
5274
|
|
|
5265
5275
|
};
|
|
5266
5276
|
/* scoped */
|
|
5267
|
-
const __vue_scope_id__$
|
|
5277
|
+
const __vue_scope_id__$o = "data-v-d2929816";
|
|
5268
5278
|
/* module identifier */
|
|
5269
|
-
const __vue_module_identifier__$
|
|
5279
|
+
const __vue_module_identifier__$o = undefined;
|
|
5270
5280
|
/* functional template */
|
|
5271
|
-
const __vue_is_functional_template__$
|
|
5281
|
+
const __vue_is_functional_template__$o = false;
|
|
5272
5282
|
/* style inject SSR */
|
|
5273
5283
|
|
|
5274
5284
|
/* style inject shadow dom */
|
|
5275
5285
|
|
|
5276
5286
|
|
|
5277
5287
|
|
|
5278
|
-
const __vue_component__$
|
|
5279
|
-
{ render: __vue_render__$
|
|
5280
|
-
__vue_inject_styles__$
|
|
5281
|
-
__vue_script__$
|
|
5282
|
-
__vue_scope_id__$
|
|
5283
|
-
__vue_is_functional_template__$
|
|
5284
|
-
__vue_module_identifier__$
|
|
5288
|
+
const __vue_component__$o = /*#__PURE__*/normalizeComponent(
|
|
5289
|
+
{ render: __vue_render__$o, staticRenderFns: __vue_staticRenderFns__$o },
|
|
5290
|
+
__vue_inject_styles__$o,
|
|
5291
|
+
__vue_script__$o,
|
|
5292
|
+
__vue_scope_id__$o,
|
|
5293
|
+
__vue_is_functional_template__$o,
|
|
5294
|
+
__vue_module_identifier__$o,
|
|
5285
5295
|
false,
|
|
5286
5296
|
createInjector,
|
|
5287
5297
|
undefined,
|
|
5288
5298
|
undefined
|
|
5289
5299
|
);
|
|
5290
5300
|
|
|
5291
|
-
__vue_component__$
|
|
5301
|
+
__vue_component__$o.install = Vue => Vue.component(__vue_component__$o.name, __vue_component__$o);
|
|
5292
5302
|
|
|
5293
5303
|
//
|
|
5294
5304
|
//
|
|
@@ -5309,7 +5319,7 @@ __vue_component__$n.install = Vue => Vue.component(__vue_component__$n.name, __v
|
|
|
5309
5319
|
//
|
|
5310
5320
|
//
|
|
5311
5321
|
|
|
5312
|
-
var script$
|
|
5322
|
+
var script$n = {
|
|
5313
5323
|
name: 'ele-select-entity',
|
|
5314
5324
|
props: {
|
|
5315
5325
|
value: {
|
|
@@ -5366,10 +5376,10 @@ var script$m = {
|
|
|
5366
5376
|
};
|
|
5367
5377
|
|
|
5368
5378
|
/* script */
|
|
5369
|
-
const __vue_script__$
|
|
5379
|
+
const __vue_script__$n = script$n;
|
|
5370
5380
|
|
|
5371
5381
|
/* template */
|
|
5372
|
-
var __vue_render__$
|
|
5382
|
+
var __vue_render__$n = function () {
|
|
5373
5383
|
var _vm = this;
|
|
5374
5384
|
var _h = _vm.$createElement;
|
|
5375
5385
|
var _c = _vm._self._c || _h;
|
|
@@ -5419,41 +5429,41 @@ var __vue_render__$m = function () {
|
|
|
5419
5429
|
2
|
|
5420
5430
|
)
|
|
5421
5431
|
};
|
|
5422
|
-
var __vue_staticRenderFns__$
|
|
5423
|
-
__vue_render__$
|
|
5432
|
+
var __vue_staticRenderFns__$n = [];
|
|
5433
|
+
__vue_render__$n._withStripped = true;
|
|
5424
5434
|
|
|
5425
5435
|
/* style */
|
|
5426
|
-
const __vue_inject_styles__$
|
|
5436
|
+
const __vue_inject_styles__$n = function (inject) {
|
|
5427
5437
|
if (!inject) return
|
|
5428
5438
|
inject("data-v-611a11f1_0", { source: ".g-select-entity__wrapper[data-v-611a11f1] {\n font-size: 14px;\n line-height: 30px;\n position: relative;\n width: 100%;\n display: flex;\n color: var(--idoole-black-07);\n border-radius: 4px;\n border: 1px solid var(--idooel-form-title-border-color);\n}\n.g-select-entity__wrapper[data-v-611a11f1]:hover {\n border-color: var(--idooel-primary-color);\n}\n.g-select-entity__wrapper .select-entity__input[data-v-611a11f1] {\n padding: 0 11px;\n background-color: #fff;\n border-radius: 4px;\n flex-grow: 1;\n min-height: 30px;\n text-align: left;\n}\n.g-select-entity__wrapper .select-entity__addon[data-v-611a11f1] {\n padding: 0 11px;\n color: var(--idoole-black-07);\n background-color: var(--idoole-black-02);\n border-left: 1px solid var(--idooel-form-title-border-color);\n cursor: pointer;\n min-height: 30px;\n white-space: nowrap;\n}\n.has-error .g-select-entity__wrapper[data-v-611a11f1] {\n border-color: var(--idooel-form-border-err-color);\n}\n.g-select-entity__disabled .select-entity__input[data-v-611a11f1] {\n background-color: var(--idoole-black-02);\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/select-entity/src/index.vue","index.vue"],"names":[],"mappings":"AA6EA;EACA,eAAA;EACA,iBAAA;EACA,kBAAA;EACA,WAAA;EACA,aAAA;EACA,6BAAA;EACA,kBAAA;EACA,uDAAA;AC5EA;AD6EA;EACA,yCAAA;AC3EA;AD6EA;EACA,eAAA;EACA,sBAAA;EACA,kBAAA;EACA,YAAA;EACA,gBAAA;EACA,gBAAA;AC3EA;AD6EA;EACA,eAAA;EACA,6BAAA;EACA,wCAAA;EACA,4DAAA;EACA,eAAA;EACA,gBAAA;EACA,mBAAA;AC3EA;AD8EA;EACA,iDAAA;AC3EA;AD6EA;EACA,wCAAA;AC1EA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"g-select-entity__wrapper\" :class=\"disabled ? 'g-select-entity__disabled' : ''\">\n <span class=\"select-entity__input\">\n <a-tag\n v-for=\"(item, inx) in getValueList()\"\n :key=\"item.value\"\n :closable=\"!disabled && !getIsMaxCount()\"\n @close=\"onClose(...arguments, inx)\"\n >\n {{ item.label }}\n </a-tag>\n <a-tag v-if=\"getIsMaxCount()\">......</a-tag>\n </span>\n <span class=\"select-entity__addon\" @click=\"onChange\">{{ addonAfter }}</span>\n <slot></slot>\n </div>\n</template>\n\n<script>\nexport default {\n name: 'ele-select-entity',\n props: {\n value: {\n type: [Array, Object]\n },\n multiple: {\n type: Boolean,\n default: true\n },\n maxCount: {\n type: Number,\n default: 7\n },\n disabled: {\n type: Boolean,\n default: false\n },\n addonAfter: {\n type: String,\n default: '选择'\n }\n },\n methods: {\n getValueList () {\n if (this.value) {\n if (this.multiple) {\n return this.getIsMaxCount() ? this.value.slice(0, this.maxCount) : this.value\n }\n return [this.value]\n }\n return []\n },\n getIsMaxCount () {\n if (this.value && this.multiple) {\n return this.value.length >= this.maxCount\n }\n return false\n },\n onChange () {\n if (this.disabled) return\n this.$emit('change', this.value)\n },\n onClose (e, inx) {\n e = window.event || e\n e.preventDefault()\n if (!this.multiple) {\n this.$emit('change', null)\n return\n }\n this.value.splice(inx, 1)\n this.$emit('change', this.value)\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.g-select-entity__wrapper {\n font-size: 14px;\n line-height: 30px;\n position: relative;\n width: 100%;\n display: flex;\n color: var(--idoole-black-07);\n border-radius: 4px;\n border: 1px solid var(--idooel-form-title-border-color);\n &:hover {\n border-color: var(--idooel-primary-color);\n }\n .select-entity__input {\n padding: 0 11px;\n background-color: #fff;\n border-radius: 4px;\n flex-grow: 1;\n min-height: 30px;\n text-align: left;\n }\n .select-entity__addon {\n padding: 0 11px;\n color: var(--idoole-black-07);\n background-color: var(--idoole-black-02);\n border-left: 1px solid var(--idooel-form-title-border-color);\n cursor: pointer;\n min-height: 30px;\n white-space: nowrap;\n }\n}\n.has-error .g-select-entity__wrapper {\n border-color: var(--idooel-form-border-err-color);\n}\n.g-select-entity__disabled .select-entity__input {\n background-color: var(--idoole-black-02);\n}\n</style>",".g-select-entity__wrapper {\n font-size: 14px;\n line-height: 30px;\n position: relative;\n width: 100%;\n display: flex;\n color: var(--idoole-black-07);\n border-radius: 4px;\n border: 1px solid var(--idooel-form-title-border-color);\n}\n.g-select-entity__wrapper:hover {\n border-color: var(--idooel-primary-color);\n}\n.g-select-entity__wrapper .select-entity__input {\n padding: 0 11px;\n background-color: #fff;\n border-radius: 4px;\n flex-grow: 1;\n min-height: 30px;\n text-align: left;\n}\n.g-select-entity__wrapper .select-entity__addon {\n padding: 0 11px;\n color: var(--idoole-black-07);\n background-color: var(--idoole-black-02);\n border-left: 1px solid var(--idooel-form-title-border-color);\n cursor: pointer;\n min-height: 30px;\n white-space: nowrap;\n}\n\n.has-error .g-select-entity__wrapper {\n border-color: var(--idooel-form-border-err-color);\n}\n\n.g-select-entity__disabled .select-entity__input {\n background-color: var(--idoole-black-02);\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
5429
5439
|
|
|
5430
5440
|
};
|
|
5431
5441
|
/* scoped */
|
|
5432
|
-
const __vue_scope_id__$
|
|
5442
|
+
const __vue_scope_id__$n = "data-v-611a11f1";
|
|
5433
5443
|
/* module identifier */
|
|
5434
|
-
const __vue_module_identifier__$
|
|
5444
|
+
const __vue_module_identifier__$n = undefined;
|
|
5435
5445
|
/* functional template */
|
|
5436
|
-
const __vue_is_functional_template__$
|
|
5446
|
+
const __vue_is_functional_template__$n = false;
|
|
5437
5447
|
/* style inject SSR */
|
|
5438
5448
|
|
|
5439
5449
|
/* style inject shadow dom */
|
|
5440
5450
|
|
|
5441
5451
|
|
|
5442
5452
|
|
|
5443
|
-
const __vue_component__$
|
|
5444
|
-
{ render: __vue_render__$
|
|
5445
|
-
__vue_inject_styles__$
|
|
5446
|
-
__vue_script__$
|
|
5447
|
-
__vue_scope_id__$
|
|
5448
|
-
__vue_is_functional_template__$
|
|
5449
|
-
__vue_module_identifier__$
|
|
5453
|
+
const __vue_component__$n = /*#__PURE__*/normalizeComponent(
|
|
5454
|
+
{ render: __vue_render__$n, staticRenderFns: __vue_staticRenderFns__$n },
|
|
5455
|
+
__vue_inject_styles__$n,
|
|
5456
|
+
__vue_script__$n,
|
|
5457
|
+
__vue_scope_id__$n,
|
|
5458
|
+
__vue_is_functional_template__$n,
|
|
5459
|
+
__vue_module_identifier__$n,
|
|
5450
5460
|
false,
|
|
5451
5461
|
createInjector,
|
|
5452
5462
|
undefined,
|
|
5453
5463
|
undefined
|
|
5454
5464
|
);
|
|
5455
5465
|
|
|
5456
|
-
__vue_component__$
|
|
5466
|
+
__vue_component__$n.install = Vue => Vue.component(__vue_component__$n.name, __vue_component__$n);
|
|
5457
5467
|
|
|
5458
5468
|
//
|
|
5459
5469
|
//
|
|
@@ -5465,7 +5475,7 @@ __vue_component__$m.install = Vue => Vue.component(__vue_component__$m.name, __v
|
|
|
5465
5475
|
//
|
|
5466
5476
|
//
|
|
5467
5477
|
|
|
5468
|
-
var script$
|
|
5478
|
+
var script$m = {
|
|
5469
5479
|
name: 'ele-icon',
|
|
5470
5480
|
props: {
|
|
5471
5481
|
type: {
|
|
@@ -5488,10 +5498,10 @@ var script$l = {
|
|
|
5488
5498
|
};
|
|
5489
5499
|
|
|
5490
5500
|
/* script */
|
|
5491
|
-
const __vue_script__$
|
|
5501
|
+
const __vue_script__$m = script$m;
|
|
5492
5502
|
|
|
5493
5503
|
/* template */
|
|
5494
|
-
var __vue_render__$
|
|
5504
|
+
var __vue_render__$m = function () {
|
|
5495
5505
|
var _vm = this;
|
|
5496
5506
|
var _h = _vm.$createElement;
|
|
5497
5507
|
var _c = _vm._self._c || _h;
|
|
@@ -5499,17 +5509,17 @@ var __vue_render__$l = function () {
|
|
|
5499
5509
|
? _c("a-icon", { attrs: { type: _vm.type, theme: _vm.theme } })
|
|
5500
5510
|
: _c("i", { class: ["iconfont", _vm.type] })
|
|
5501
5511
|
};
|
|
5502
|
-
var __vue_staticRenderFns__$
|
|
5503
|
-
__vue_render__$
|
|
5512
|
+
var __vue_staticRenderFns__$m = [];
|
|
5513
|
+
__vue_render__$m._withStripped = true;
|
|
5504
5514
|
|
|
5505
5515
|
/* style */
|
|
5506
|
-
const __vue_inject_styles__$
|
|
5516
|
+
const __vue_inject_styles__$m = undefined;
|
|
5507
5517
|
/* scoped */
|
|
5508
|
-
const __vue_scope_id__$
|
|
5518
|
+
const __vue_scope_id__$m = undefined;
|
|
5509
5519
|
/* module identifier */
|
|
5510
|
-
const __vue_module_identifier__$
|
|
5520
|
+
const __vue_module_identifier__$m = undefined;
|
|
5511
5521
|
/* functional template */
|
|
5512
|
-
const __vue_is_functional_template__$
|
|
5522
|
+
const __vue_is_functional_template__$m = false;
|
|
5513
5523
|
/* style inject */
|
|
5514
5524
|
|
|
5515
5525
|
/* style inject SSR */
|
|
@@ -5518,20 +5528,20 @@ __vue_render__$l._withStripped = true;
|
|
|
5518
5528
|
|
|
5519
5529
|
|
|
5520
5530
|
|
|
5521
|
-
const __vue_component__$
|
|
5522
|
-
{ render: __vue_render__$
|
|
5523
|
-
__vue_inject_styles__$
|
|
5524
|
-
__vue_script__$
|
|
5525
|
-
__vue_scope_id__$
|
|
5526
|
-
__vue_is_functional_template__$
|
|
5527
|
-
__vue_module_identifier__$
|
|
5528
|
-
false,
|
|
5529
|
-
undefined,
|
|
5530
|
-
undefined,
|
|
5531
|
+
const __vue_component__$m = /*#__PURE__*/normalizeComponent(
|
|
5532
|
+
{ render: __vue_render__$m, staticRenderFns: __vue_staticRenderFns__$m },
|
|
5533
|
+
__vue_inject_styles__$m,
|
|
5534
|
+
__vue_script__$m,
|
|
5535
|
+
__vue_scope_id__$m,
|
|
5536
|
+
__vue_is_functional_template__$m,
|
|
5537
|
+
__vue_module_identifier__$m,
|
|
5538
|
+
false,
|
|
5539
|
+
undefined,
|
|
5540
|
+
undefined,
|
|
5531
5541
|
undefined
|
|
5532
5542
|
);
|
|
5533
5543
|
|
|
5534
|
-
__vue_component__$
|
|
5544
|
+
__vue_component__$m.install = Vue => Vue.component(__vue_component__$m.name, __vue_component__$m);
|
|
5535
5545
|
|
|
5536
5546
|
//
|
|
5537
5547
|
//
|
|
@@ -5540,7 +5550,7 @@ __vue_component__$l.install = Vue => Vue.component(__vue_component__$l.name, __v
|
|
|
5540
5550
|
//
|
|
5541
5551
|
//
|
|
5542
5552
|
|
|
5543
|
-
var script$
|
|
5553
|
+
var script$l = {
|
|
5544
5554
|
name: 'ele-input-number',
|
|
5545
5555
|
props: {
|
|
5546
5556
|
precision: {
|
|
@@ -5558,10 +5568,10 @@ var script$k = {
|
|
|
5558
5568
|
};
|
|
5559
5569
|
|
|
5560
5570
|
/* script */
|
|
5561
|
-
const __vue_script__$
|
|
5571
|
+
const __vue_script__$l = script$l;
|
|
5562
5572
|
|
|
5563
5573
|
/* template */
|
|
5564
|
-
var __vue_render__$
|
|
5574
|
+
var __vue_render__$l = function () {
|
|
5565
5575
|
var _vm = this;
|
|
5566
5576
|
var _h = _vm.$createElement;
|
|
5567
5577
|
var _c = _vm._self._c || _h;
|
|
@@ -5585,17 +5595,17 @@ var __vue_render__$k = function () {
|
|
|
5585
5595
|
1
|
|
5586
5596
|
)
|
|
5587
5597
|
};
|
|
5588
|
-
var __vue_staticRenderFns__$
|
|
5589
|
-
__vue_render__$
|
|
5598
|
+
var __vue_staticRenderFns__$l = [];
|
|
5599
|
+
__vue_render__$l._withStripped = true;
|
|
5590
5600
|
|
|
5591
5601
|
/* style */
|
|
5592
|
-
const __vue_inject_styles__$
|
|
5602
|
+
const __vue_inject_styles__$l = undefined;
|
|
5593
5603
|
/* scoped */
|
|
5594
|
-
const __vue_scope_id__$
|
|
5604
|
+
const __vue_scope_id__$l = undefined;
|
|
5595
5605
|
/* module identifier */
|
|
5596
|
-
const __vue_module_identifier__$
|
|
5606
|
+
const __vue_module_identifier__$l = undefined;
|
|
5597
5607
|
/* functional template */
|
|
5598
|
-
const __vue_is_functional_template__$
|
|
5608
|
+
const __vue_is_functional_template__$l = false;
|
|
5599
5609
|
/* style inject */
|
|
5600
5610
|
|
|
5601
5611
|
/* style inject SSR */
|
|
@@ -5604,23 +5614,23 @@ __vue_render__$k._withStripped = true;
|
|
|
5604
5614
|
|
|
5605
5615
|
|
|
5606
5616
|
|
|
5607
|
-
const __vue_component__$
|
|
5608
|
-
{ render: __vue_render__$
|
|
5609
|
-
__vue_inject_styles__$
|
|
5610
|
-
__vue_script__$
|
|
5611
|
-
__vue_scope_id__$
|
|
5612
|
-
__vue_is_functional_template__$
|
|
5613
|
-
__vue_module_identifier__$
|
|
5617
|
+
const __vue_component__$l = /*#__PURE__*/normalizeComponent(
|
|
5618
|
+
{ render: __vue_render__$l, staticRenderFns: __vue_staticRenderFns__$l },
|
|
5619
|
+
__vue_inject_styles__$l,
|
|
5620
|
+
__vue_script__$l,
|
|
5621
|
+
__vue_scope_id__$l,
|
|
5622
|
+
__vue_is_functional_template__$l,
|
|
5623
|
+
__vue_module_identifier__$l,
|
|
5614
5624
|
false,
|
|
5615
5625
|
undefined,
|
|
5616
5626
|
undefined,
|
|
5617
5627
|
undefined
|
|
5618
5628
|
);
|
|
5619
5629
|
|
|
5620
|
-
__vue_component__$
|
|
5630
|
+
__vue_component__$l.install = Vue => Vue.component(__vue_component__$l.name, __vue_component__$l);
|
|
5621
5631
|
|
|
5622
5632
|
//
|
|
5623
|
-
var script$
|
|
5633
|
+
var script$k = {
|
|
5624
5634
|
name: 'ele-modal',
|
|
5625
5635
|
props: {
|
|
5626
5636
|
value: {
|
|
@@ -5764,10 +5774,10 @@ var script$j = {
|
|
|
5764
5774
|
};
|
|
5765
5775
|
|
|
5766
5776
|
/* script */
|
|
5767
|
-
const __vue_script__$
|
|
5777
|
+
const __vue_script__$k = script$k;
|
|
5768
5778
|
|
|
5769
5779
|
/* template */
|
|
5770
|
-
var __vue_render__$
|
|
5780
|
+
var __vue_render__$k = function () {
|
|
5771
5781
|
var _vm = this;
|
|
5772
5782
|
var _h = _vm.$createElement;
|
|
5773
5783
|
var _c = _vm._self._c || _h;
|
|
@@ -5840,41 +5850,41 @@ var __vue_render__$j = function () {
|
|
|
5840
5850
|
2
|
|
5841
5851
|
)
|
|
5842
5852
|
};
|
|
5843
|
-
var __vue_staticRenderFns__$
|
|
5844
|
-
__vue_render__$
|
|
5853
|
+
var __vue_staticRenderFns__$k = [];
|
|
5854
|
+
__vue_render__$k._withStripped = true;
|
|
5845
5855
|
|
|
5846
5856
|
/* style */
|
|
5847
|
-
const __vue_inject_styles__$
|
|
5857
|
+
const __vue_inject_styles__$k = function (inject) {
|
|
5848
5858
|
if (!inject) return
|
|
5849
5859
|
inject("data-v-e7c1987c_0", { source: ".ele-modal__footer[data-v-e7c1987c] {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n}\n.ele-modal__footer .footer-btn__wrapper[data-v-e7c1987c] {\n flex: 1;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/modal/src/index.vue","index.vue"],"names":[],"mappings":"AA+KA;EACA,aAAA;EACA,mBAAA;EACA,8BAAA;EACA,mBAAA;AC9KA;AD+KA;EACA,OAAA;AC7KA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <a-modal\n :title=\"title\"\n :cancelText=\"cancelText\"\n :okText=\"okText\"\n :closable=\"closable\"\n v-model:visible=\"showModal\"\n :width=\"width\"\n :keyboard=\"false\"\n :maskClosable=\"maskClosable\"\n :dialogStyle=\"{ top: `${upDownDistance[size]}px` }\"\n :bodyStyle=\"{ maxHeight: maxheight, overflowY: 'auto' }\"\n :footer=\"showFooter ? undefined : null\"\n @cancel=\"handleCancel\"\n @ok=\"handleOk\"\n >\n <slot v-if=\"showModal\"></slot>\n <template slot=\"footer\" v-if=\"!showDefaultFooter\">\n <div class=\"ele-modal__footer\">\n <slot name=\"footer-text\"></slot>\n <div class=\"footer-btn__wrapper\">\n <ele-button\n v-for=\"btn in buttonGroupMeta.elements\"\n :type=\"btn.type\"\n v-on=\"assignAttrEvents\"\n :event-name=\"btn.eventName\"\n :key=\"btn.key\">\n {{ btn.label }}\n </ele-button>\n </div>\n </div>\n </template>\n </a-modal>\n</template>\n<script>\nimport { CONTEXT } from '../../utils'\nexport default {\n name: 'ele-modal',\n props: {\n value: {\n type: Boolean,\n default: false\n },\n title: {\n type: String,\n default: '标题'\n },\n cancelText: {\n type: String,\n default: '关闭'\n },\n okText: {\n type: String,\n default: '确定'\n },\n size: {\n type: String,\n default: 'middle'\n },\n map: {\n type: Object,\n default () {\n return {}\n }\n },\n closable: {\n type: Boolean,\n default: true\n },\n maskClosable: {\n type: Boolean,\n default: false\n },\n showFooter: {\n type: Boolean,\n default: true\n },\n footer: {\n type: Function,\n default: null\n },\n onlyClose: {\n type: Boolean,\n default: false\n },\n buttonGroupMeta: {\n type: Object,\n default: () => ({})\n },\n // 是否展示组件默认底部按钮\n showDefaultFooter: {\n type: Boolean,\n default: false\n }\n },\n watch: {\n value: {\n handler (value) {\n this.$nextTick(() => {\n this.showModal = value\n })\n },\n immediate: true\n }\n },\n inject: {\n [CONTEXT]: {\n default: () => (() => ({}))\n }\n },\n computed: {\n assignAttrEvents () {\n const events = this.buttons.reduce((ret, btn) => {\n ret[btn.eventName] = (e) => {\n this.$emit(btn.eventName || 'click', { ...e, ...this[CONTEXT]() })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events\n }\n },\n buttons () {\n const { elements = [] } = this.buttonGroupMeta\n return elements\n },\n width () {\n return this.map[this.size]\n },\n maxheight () {\n return `calc(100vh - ${this.upDownDistance[this.size] * 2 + (this.title ? 55 : 0) + (this.showFooter ? 53 : 0) }px`\n }\n },\n data () {\n return {\n showModal: false\n }\n },\n created () {\n let defaultMap = {\n small: 480,\n middle: 768,\n big: 1200\n }\n this.upDownDistance = {\n small: 80,\n middle: 80,\n big: 40\n }\n this.map = Object.assign(this.map, defaultMap)\n },\n methods: {\n openModal () {\n this.showModal = true\n this.removeHidden()\n },\n handleCancel () {\n this.showModal = false\n this.$emit('input', this.showModal)\n this.$emit('change', this.showModal)\n this.removeHidden()\n this.$emit('cancel')\n },\n handleOk () {\n this.$emit('ok')\n },\n removeHidden () {\n let ishidden = document.body.style.overflow === 'hidden'\n ishidden && (document.body.style.overflow = 'initial')\n }\n }\n}\n</script>\n<style lang=\"scss\" scoped>\n.ele-modal__footer {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n .footer-btn__wrapper {\n flex: 1;\n }\n}\n</style>",".ele-modal__footer {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n}\n.ele-modal__footer .footer-btn__wrapper {\n flex: 1;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
5850
5860
|
|
|
5851
5861
|
};
|
|
5852
5862
|
/* scoped */
|
|
5853
|
-
const __vue_scope_id__$
|
|
5863
|
+
const __vue_scope_id__$k = "data-v-e7c1987c";
|
|
5854
5864
|
/* module identifier */
|
|
5855
|
-
const __vue_module_identifier__$
|
|
5865
|
+
const __vue_module_identifier__$k = undefined;
|
|
5856
5866
|
/* functional template */
|
|
5857
|
-
const __vue_is_functional_template__$
|
|
5867
|
+
const __vue_is_functional_template__$k = false;
|
|
5858
5868
|
/* style inject SSR */
|
|
5859
5869
|
|
|
5860
5870
|
/* style inject shadow dom */
|
|
5861
5871
|
|
|
5862
5872
|
|
|
5863
5873
|
|
|
5864
|
-
const __vue_component__$
|
|
5865
|
-
{ render: __vue_render__$
|
|
5866
|
-
__vue_inject_styles__$
|
|
5867
|
-
__vue_script__$
|
|
5868
|
-
__vue_scope_id__$
|
|
5869
|
-
__vue_is_functional_template__$
|
|
5870
|
-
__vue_module_identifier__$
|
|
5874
|
+
const __vue_component__$k = /*#__PURE__*/normalizeComponent(
|
|
5875
|
+
{ render: __vue_render__$k, staticRenderFns: __vue_staticRenderFns__$k },
|
|
5876
|
+
__vue_inject_styles__$k,
|
|
5877
|
+
__vue_script__$k,
|
|
5878
|
+
__vue_scope_id__$k,
|
|
5879
|
+
__vue_is_functional_template__$k,
|
|
5880
|
+
__vue_module_identifier__$k,
|
|
5871
5881
|
false,
|
|
5872
5882
|
createInjector,
|
|
5873
5883
|
undefined,
|
|
5874
5884
|
undefined
|
|
5875
5885
|
);
|
|
5876
5886
|
|
|
5877
|
-
__vue_component__$
|
|
5887
|
+
__vue_component__$k.install = Vue => Vue.component(__vue_component__$k.name, __vue_component__$k);
|
|
5878
5888
|
|
|
5879
5889
|
//
|
|
5880
5890
|
//
|
|
@@ -5886,7 +5896,7 @@ __vue_component__$j.install = Vue => Vue.component(__vue_component__$j.name, __v
|
|
|
5886
5896
|
//
|
|
5887
5897
|
//
|
|
5888
5898
|
|
|
5889
|
-
var script$
|
|
5899
|
+
var script$j = {
|
|
5890
5900
|
name: 'ele-checkbox',
|
|
5891
5901
|
model: {
|
|
5892
5902
|
prop: 'value',
|
|
@@ -5914,10 +5924,10 @@ var script$i = {
|
|
|
5914
5924
|
};
|
|
5915
5925
|
|
|
5916
5926
|
/* script */
|
|
5917
|
-
const __vue_script__$
|
|
5927
|
+
const __vue_script__$j = script$j;
|
|
5918
5928
|
|
|
5919
5929
|
/* template */
|
|
5920
|
-
var __vue_render__$
|
|
5930
|
+
var __vue_render__$j = function () {
|
|
5921
5931
|
var _vm = this;
|
|
5922
5932
|
var _h = _vm.$createElement;
|
|
5923
5933
|
var _c = _vm._self._c || _h;
|
|
@@ -5930,41 +5940,41 @@ var __vue_render__$i = function () {
|
|
|
5930
5940
|
on: { change: _vm.onChange },
|
|
5931
5941
|
})
|
|
5932
5942
|
};
|
|
5933
|
-
var __vue_staticRenderFns__$
|
|
5934
|
-
__vue_render__$
|
|
5943
|
+
var __vue_staticRenderFns__$j = [];
|
|
5944
|
+
__vue_render__$j._withStripped = true;
|
|
5935
5945
|
|
|
5936
5946
|
/* style */
|
|
5937
|
-
const __vue_inject_styles__$
|
|
5947
|
+
const __vue_inject_styles__$j = function (inject) {
|
|
5938
5948
|
if (!inject) return
|
|
5939
5949
|
inject("data-v-e6c4aea4_0", { source: ".ant-checkbox-group[data-v-e6c4aea4] {\n text-align: left;\n line-height: 32px;\n}\n.has-error .ant-checkbox-group[data-v-e6c4aea4] .ant-checkbox-wrapper {\n color: var(--idooel-form-border-err-color);\n}\n.has-error .ant-checkbox-group[data-v-e6c4aea4] .ant-checkbox-inner {\n border-color: var(--idooel-form-border-err-color);\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/checkbox/src/index.vue","index.vue"],"names":[],"mappings":"AAsCA;EACA,gBAAA;EACA,iBAAA;ACrCA;ADyCA;EACA,0CAAA;ACtCA;ADwCA;EACA,iDAAA;ACtCA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <a-checkbox-group\n :value=\"value\"\n :options=\"dataSource\" \n :disabled=\"disabled\" \n @change=\"onChange\">\n </a-checkbox-group>\n</template>\n\n<script>\nexport default {\n name: 'ele-checkbox',\n model: {\n prop: 'value',\n event: 'change'\n },\n props: {\n value: {\n type: Array\n },\n dataSource: {\n type: Array,\n default: () => []\n },\n disabled: {\n type: Boolean,\n default: false\n }\n },\n methods: {\n onChange (value) {\n this.$emit('change', value)\n this.$emit('input', value)\n }\n }\n}\n</script>\n<style lang=\"scss\" scoped>\n.ant-checkbox-group {\n text-align: left;\n line-height: 32px;\n}\n.has-error {\n .ant-checkbox-group {\n ::v-deep .ant-checkbox-wrapper {\n color: var(--idooel-form-border-err-color);\n }\n ::v-deep .ant-checkbox-inner {\n border-color: var(--idooel-form-border-err-color);\n }\n }\n}\n</style>",".ant-checkbox-group {\n text-align: left;\n line-height: 32px;\n}\n\n.has-error .ant-checkbox-group ::v-deep .ant-checkbox-wrapper {\n color: var(--idooel-form-border-err-color);\n}\n.has-error .ant-checkbox-group ::v-deep .ant-checkbox-inner {\n border-color: var(--idooel-form-border-err-color);\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
5940
5950
|
|
|
5941
5951
|
};
|
|
5942
5952
|
/* scoped */
|
|
5943
|
-
const __vue_scope_id__$
|
|
5953
|
+
const __vue_scope_id__$j = "data-v-e6c4aea4";
|
|
5944
5954
|
/* module identifier */
|
|
5945
|
-
const __vue_module_identifier__$
|
|
5955
|
+
const __vue_module_identifier__$j = undefined;
|
|
5946
5956
|
/* functional template */
|
|
5947
|
-
const __vue_is_functional_template__$
|
|
5957
|
+
const __vue_is_functional_template__$j = false;
|
|
5948
5958
|
/* style inject SSR */
|
|
5949
5959
|
|
|
5950
5960
|
/* style inject shadow dom */
|
|
5951
5961
|
|
|
5952
5962
|
|
|
5953
5963
|
|
|
5954
|
-
const __vue_component__$
|
|
5955
|
-
{ render: __vue_render__$
|
|
5956
|
-
__vue_inject_styles__$
|
|
5957
|
-
__vue_script__$
|
|
5958
|
-
__vue_scope_id__$
|
|
5959
|
-
__vue_is_functional_template__$
|
|
5960
|
-
__vue_module_identifier__$
|
|
5964
|
+
const __vue_component__$j = /*#__PURE__*/normalizeComponent(
|
|
5965
|
+
{ render: __vue_render__$j, staticRenderFns: __vue_staticRenderFns__$j },
|
|
5966
|
+
__vue_inject_styles__$j,
|
|
5967
|
+
__vue_script__$j,
|
|
5968
|
+
__vue_scope_id__$j,
|
|
5969
|
+
__vue_is_functional_template__$j,
|
|
5970
|
+
__vue_module_identifier__$j,
|
|
5961
5971
|
false,
|
|
5962
5972
|
createInjector,
|
|
5963
5973
|
undefined,
|
|
5964
5974
|
undefined
|
|
5965
5975
|
);
|
|
5966
5976
|
|
|
5967
|
-
__vue_component__$
|
|
5977
|
+
__vue_component__$j.install = Vue => Vue.component(__vue_component__$j.name, __vue_component__$j);
|
|
5968
5978
|
|
|
5969
5979
|
//
|
|
5970
5980
|
//
|
|
@@ -5975,7 +5985,7 @@ __vue_component__$i.install = Vue => Vue.component(__vue_component__$i.name, __v
|
|
|
5975
5985
|
//
|
|
5976
5986
|
//
|
|
5977
5987
|
|
|
5978
|
-
var script$
|
|
5988
|
+
var script$i = {
|
|
5979
5989
|
name: 'ele-radio',
|
|
5980
5990
|
model: {
|
|
5981
5991
|
prop: 'value',
|
|
@@ -6008,10 +6018,10 @@ var script$h = {
|
|
|
6008
6018
|
};
|
|
6009
6019
|
|
|
6010
6020
|
/* script */
|
|
6011
|
-
const __vue_script__$
|
|
6021
|
+
const __vue_script__$i = script$i;
|
|
6012
6022
|
|
|
6013
6023
|
/* template */
|
|
6014
|
-
var __vue_render__$
|
|
6024
|
+
var __vue_render__$i = function () {
|
|
6015
6025
|
var _vm = this;
|
|
6016
6026
|
var _h = _vm.$createElement;
|
|
6017
6027
|
var _c = _vm._self._c || _h;
|
|
@@ -6029,41 +6039,41 @@ var __vue_render__$h = function () {
|
|
|
6029
6039
|
1
|
|
6030
6040
|
)
|
|
6031
6041
|
};
|
|
6032
|
-
var __vue_staticRenderFns__$
|
|
6033
|
-
__vue_render__$
|
|
6042
|
+
var __vue_staticRenderFns__$i = [];
|
|
6043
|
+
__vue_render__$i._withStripped = true;
|
|
6034
6044
|
|
|
6035
6045
|
/* style */
|
|
6036
|
-
const __vue_inject_styles__$
|
|
6046
|
+
const __vue_inject_styles__$i = function (inject) {
|
|
6037
6047
|
if (!inject) return
|
|
6038
6048
|
inject("data-v-00d35412_0", { source: ".ant-radio-group[data-v-00d35412] {\n text-align: left;\n line-height: 32px;\n}\n.has-error .ant-radio-group[data-v-00d35412] .ant-radio-wrapper {\n color: var(--idooel-form-border-err-color);\n}\n.has-error .ant-radio-group[data-v-00d35412] .ant-radio-inner {\n border-color: var(--idooel-form-border-err-color);\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/radio/src/index.vue","index.vue"],"names":[],"mappings":"AA0CA;EACA,gBAAA;EACA,iBAAA;ACzCA;AD6CA;EACA,0CAAA;AC1CA;AD4CA;EACA,iDAAA;AC1CA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <a-radio-group :value=\"value\" @change=\"onChange\" :disabled=\"disabled\">\n <a-radio v-for=\"item in dataSource\" :key=\"item.value\" :value=\"item.value\">\n {{ item.label }}\n </a-radio>\n </a-radio-group>\n</template>\n\n<script>\nexport default {\n name: 'ele-radio',\n model: {\n prop: 'value',\n event: 'change'\n },\n props: {\n value: {\n type: [String, Array, Number]\n },\n dataSource: {\n type: Array,\n default: () => []\n },\n disabled: {\n type: Boolean,\n default: false\n }\n },\n watch: {\n value (val) {\n console.log('valvalval', val)\n }\n },\n methods: {\n onChange (e) {\n this.$emit('change', e.target.value)\n this.$emit('input', e.target.value)\n }\n }\n}\n</script>\n<style lang=\"scss\" scoped>\n.ant-radio-group {\n text-align: left;\n line-height: 32px;\n}\n.has-error {\n .ant-radio-group {\n ::v-deep .ant-radio-wrapper {\n color: var(--idooel-form-border-err-color);\n }\n ::v-deep .ant-radio-inner {\n border-color: var(--idooel-form-border-err-color);\n }\n }\n}\n</style>",".ant-radio-group {\n text-align: left;\n line-height: 32px;\n}\n\n.has-error .ant-radio-group ::v-deep .ant-radio-wrapper {\n color: var(--idooel-form-border-err-color);\n}\n.has-error .ant-radio-group ::v-deep .ant-radio-inner {\n border-color: var(--idooel-form-border-err-color);\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
6039
6049
|
|
|
6040
6050
|
};
|
|
6041
6051
|
/* scoped */
|
|
6042
|
-
const __vue_scope_id__$
|
|
6052
|
+
const __vue_scope_id__$i = "data-v-00d35412";
|
|
6043
6053
|
/* module identifier */
|
|
6044
|
-
const __vue_module_identifier__$
|
|
6054
|
+
const __vue_module_identifier__$i = undefined;
|
|
6045
6055
|
/* functional template */
|
|
6046
|
-
const __vue_is_functional_template__$
|
|
6056
|
+
const __vue_is_functional_template__$i = false;
|
|
6047
6057
|
/* style inject SSR */
|
|
6048
6058
|
|
|
6049
6059
|
/* style inject shadow dom */
|
|
6050
6060
|
|
|
6051
6061
|
|
|
6052
6062
|
|
|
6053
|
-
const __vue_component__$
|
|
6054
|
-
{ render: __vue_render__$
|
|
6055
|
-
__vue_inject_styles__$
|
|
6056
|
-
__vue_script__$
|
|
6057
|
-
__vue_scope_id__$
|
|
6058
|
-
__vue_is_functional_template__$
|
|
6059
|
-
__vue_module_identifier__$
|
|
6063
|
+
const __vue_component__$i = /*#__PURE__*/normalizeComponent(
|
|
6064
|
+
{ render: __vue_render__$i, staticRenderFns: __vue_staticRenderFns__$i },
|
|
6065
|
+
__vue_inject_styles__$i,
|
|
6066
|
+
__vue_script__$i,
|
|
6067
|
+
__vue_scope_id__$i,
|
|
6068
|
+
__vue_is_functional_template__$i,
|
|
6069
|
+
__vue_module_identifier__$i,
|
|
6060
6070
|
false,
|
|
6061
6071
|
createInjector,
|
|
6062
6072
|
undefined,
|
|
6063
6073
|
undefined
|
|
6064
6074
|
);
|
|
6065
6075
|
|
|
6066
|
-
__vue_component__$
|
|
6076
|
+
__vue_component__$i.install = Vue => Vue.component(__vue_component__$i.name, __vue_component__$i);
|
|
6067
6077
|
|
|
6068
6078
|
//
|
|
6069
6079
|
//
|
|
@@ -6087,7 +6097,7 @@ __vue_component__$h.install = Vue => Vue.component(__vue_component__$h.name, __v
|
|
|
6087
6097
|
//
|
|
6088
6098
|
//
|
|
6089
6099
|
|
|
6090
|
-
var script$
|
|
6100
|
+
var script$h = {
|
|
6091
6101
|
name: 'ele-batch-export',
|
|
6092
6102
|
props: {
|
|
6093
6103
|
value: {
|
|
@@ -6131,10 +6141,10 @@ var script$g = {
|
|
|
6131
6141
|
};
|
|
6132
6142
|
|
|
6133
6143
|
/* script */
|
|
6134
|
-
const __vue_script__$
|
|
6144
|
+
const __vue_script__$h = script$h;
|
|
6135
6145
|
|
|
6136
6146
|
/* template */
|
|
6137
|
-
var __vue_render__$
|
|
6147
|
+
var __vue_render__$h = function () {
|
|
6138
6148
|
var _vm = this;
|
|
6139
6149
|
var _h = _vm.$createElement;
|
|
6140
6150
|
var _c = _vm._self._c || _h;
|
|
@@ -6193,42 +6203,42 @@ var __vue_render__$g = function () {
|
|
|
6193
6203
|
]
|
|
6194
6204
|
)
|
|
6195
6205
|
};
|
|
6196
|
-
var __vue_staticRenderFns__$
|
|
6197
|
-
__vue_render__$
|
|
6206
|
+
var __vue_staticRenderFns__$h = [];
|
|
6207
|
+
__vue_render__$h._withStripped = true;
|
|
6198
6208
|
|
|
6199
6209
|
/* style */
|
|
6200
|
-
const __vue_inject_styles__$
|
|
6210
|
+
const __vue_inject_styles__$h = function (inject) {
|
|
6201
6211
|
if (!inject) return
|
|
6202
6212
|
inject("data-v-06685ad4_0", { source: ".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n.margin-t-8 {\n margin-top: 8px;\n}\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":"AAAA;EACE,qBAAqB;AACvB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AAEA;EACE,eAAe;AACjB;AAEA;EACE,+BAA+B;EAC/B,sCAAsC;EACtC,sCAAsC;EACtC,sCAAsC;EACtC,uCAAuC;EACvC,uCAAuC;EACvC,uCAAuC;EACvC,mDAAmD;EACnD,4BAA4B;EAC5B,4BAA4B;EAC5B,0BAA0B;EAC1B,wBAAwB;EACxB,8BAA8B;EAC9B,+BAA+B;EAC/B,qCAAqC;EACrC,gCAAgC;EAChC,4BAA4B;EAC5B,qDAAqD;EACrD,kDAAkD;EAClD,gDAAgD;EAChD,gCAAgC;EAChC,uCAAuC;EACvC,yBAAyB;EACzB,yBAAyB;EACzB,oCAAoC;AACtC;AAEA;EACE,4DAA4D;AAC9D;AAEA;EACE,4DAA4D;AAC9D;;AAEA,oCAAoC","file":"index.vue","sourcesContent":[".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n\n.margin-t-8 {\n margin-top: 8px;\n}\n\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined })
|
|
6203
6213
|
,inject("data-v-06685ad4_1", { source: ".ele-batch-export__content[data-v-06685ad4] {\n height: 106px;\n}\n.ele-batch-export__content .ele-batch-export__container[data-v-06685ad4] {\n border-width: 1px;\n border-style: dashed;\n height: 80px;\n border-color: var(--idooel-link-06);\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 0 16px;\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__icon[data-v-06685ad4] {\n font-size: 48px;\n color: var(--idooel-link-06);\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__handle[data-v-06685ad4] {\n margin-left: 16px;\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__handle .ele-batch-export__btn[data-v-06685ad4] {\n color: var(--idooel-link-06);\n font-size: 16px;\n cursor: pointer;\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__handle .ele-batch-export__btn--hint[data-v-06685ad4] {\n color: var(--idooel-link-03);\n font-size: 14px;\n}\n.ele-batch-export__content .ele-batch-export__message[data-v-06685ad4] {\n color: var(--idooel-link-06);\n font-size: 14px;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/batch-export/src/index.vue","index.vue"],"names":[],"mappings":"AAuEA;EACA,aAAA;ACtEA;ADuEA;EACA,iBAAA;EACA,oBAAA;EACA,YAAA;EACA,mCAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,eAAA;ACrEA;ADsEA;EACA,eAAA;EACA,4BAAA;ACpEA;ADsEA;EACA,iBAAA;ACpEA;ADqEA;EACA,4BAAA;EACA,eAAA;EACA,eAAA;ACnEA;ADqEA;EACA,4BAAA;EACA,eAAA;ACnEA;ADuEA;EACA,4BAAA;EACA,eAAA;ACrEA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <ele-modal \n v-model=\"innerValue\" \n v-on=\"$listeners\"\n :buttonGroupMeta=\"buttonGroupMeta\" \n title=\"批量导出\">\n <div class=\"ele-batch-export__content\">\n <div class=\"ele-batch-export__container\">\n <ele-icon class=\"ele-batch-export__icon\" type=\"download\"></ele-icon>\n <div class=\"ele-batch-export__handle\">\n <div class=\"ele-batch-export__btn\" @click=\"handleClick\">导出任务处理中..... 请点击此按钮跳转到“批处理管理”菜单查看任务进度</div>\n <div class=\"ele-batch-export__btn--hint\">批处理任务的准备工作会在后台运行</div>\n </div>\n </div>\n <div class=\"ele-batch-export__message\">\n 您可以请点击上方按钮查看任务进度或关闭弹框\n </div>\n </div>\n </ele-modal>\n</template>\n\n<script>\nexport default {\n name: 'ele-batch-export',\n props: {\n value: {\n type: Boolean,\n default: false\n },\n buttonGroupMeta: {\n type: Object,\n default: () => {\n return {\n elements: [\n {\n label: '关闭',\n key: 'close',\n type: 'primary',\n eventName: 'handleClose'\n }\n ]\n }\n }\n }\n },\n data() {\n return {\n innerValue: false\n }\n },\n watch: {\n value: {\n handler (value) {\n this.$nextTick(() => {\n this.innerValue = value\n })\n },\n immediate: true\n }\n },\n methods: {\n handleClick () {\n this.$emit('on-batch-export')\n }\n }\n}\n</script>\n<style lang=\"scss\">\n@import '../../theme/index';\n</style>\n<style lang=\"scss\" scoped>\n.ele-batch-export__content {\n height: 106px;\n .ele-batch-export__container {\n border-width: 1px;\n border-style: dashed;\n height: 80px;\n border-color: var(--idooel-link-06);\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 0 16px;\n .ele-batch-export__icon {\n font-size: 48px;\n color: var(--idooel-link-06);\n }\n .ele-batch-export__handle {\n margin-left: 16px;\n .ele-batch-export__btn {\n color: var(--idooel-link-06);\n font-size: 16px;\n cursor: pointer;\n }\n .ele-batch-export__btn--hint {\n color: var(--idooel-link-03);\n font-size: 14px;\n }\n }\n }\n .ele-batch-export__message {\n color: var(--idooel-link-06);\n font-size: 14px;\n }\n}\n</style>",".ele-batch-export__content {\n height: 106px;\n}\n.ele-batch-export__content .ele-batch-export__container {\n border-width: 1px;\n border-style: dashed;\n height: 80px;\n border-color: var(--idooel-link-06);\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 0 16px;\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__icon {\n font-size: 48px;\n color: var(--idooel-link-06);\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__handle {\n margin-left: 16px;\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__handle .ele-batch-export__btn {\n color: var(--idooel-link-06);\n font-size: 16px;\n cursor: pointer;\n}\n.ele-batch-export__content .ele-batch-export__container .ele-batch-export__handle .ele-batch-export__btn--hint {\n color: var(--idooel-link-03);\n font-size: 14px;\n}\n.ele-batch-export__content .ele-batch-export__message {\n color: var(--idooel-link-06);\n font-size: 14px;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
6204
6214
|
|
|
6205
6215
|
};
|
|
6206
6216
|
/* scoped */
|
|
6207
|
-
const __vue_scope_id__$
|
|
6217
|
+
const __vue_scope_id__$h = "data-v-06685ad4";
|
|
6208
6218
|
/* module identifier */
|
|
6209
|
-
const __vue_module_identifier__$
|
|
6219
|
+
const __vue_module_identifier__$h = undefined;
|
|
6210
6220
|
/* functional template */
|
|
6211
|
-
const __vue_is_functional_template__$
|
|
6221
|
+
const __vue_is_functional_template__$h = false;
|
|
6212
6222
|
/* style inject SSR */
|
|
6213
6223
|
|
|
6214
6224
|
/* style inject shadow dom */
|
|
6215
6225
|
|
|
6216
6226
|
|
|
6217
6227
|
|
|
6218
|
-
const __vue_component__$
|
|
6219
|
-
{ render: __vue_render__$
|
|
6220
|
-
__vue_inject_styles__$
|
|
6221
|
-
__vue_script__$
|
|
6222
|
-
__vue_scope_id__$
|
|
6223
|
-
__vue_is_functional_template__$
|
|
6224
|
-
__vue_module_identifier__$
|
|
6228
|
+
const __vue_component__$h = /*#__PURE__*/normalizeComponent(
|
|
6229
|
+
{ render: __vue_render__$h, staticRenderFns: __vue_staticRenderFns__$h },
|
|
6230
|
+
__vue_inject_styles__$h,
|
|
6231
|
+
__vue_script__$h,
|
|
6232
|
+
__vue_scope_id__$h,
|
|
6233
|
+
__vue_is_functional_template__$h,
|
|
6234
|
+
__vue_module_identifier__$h,
|
|
6225
6235
|
false,
|
|
6226
6236
|
createInjector,
|
|
6227
6237
|
undefined,
|
|
6228
6238
|
undefined
|
|
6229
6239
|
);
|
|
6230
6240
|
|
|
6231
|
-
__vue_component__$
|
|
6241
|
+
__vue_component__$h.install = Vue => Vue.component(__vue_component__$h.name, __vue_component__$h);
|
|
6232
6242
|
|
|
6233
6243
|
//
|
|
6234
6244
|
//
|
|
@@ -6242,7 +6252,7 @@ __vue_component__$g.install = Vue => Vue.component(__vue_component__$g.name, __v
|
|
|
6242
6252
|
//
|
|
6243
6253
|
//
|
|
6244
6254
|
|
|
6245
|
-
var script$
|
|
6255
|
+
var script$g = {
|
|
6246
6256
|
name: 'ele-date-range',
|
|
6247
6257
|
model: {
|
|
6248
6258
|
prop: 'value',
|
|
@@ -6273,10 +6283,10 @@ var script$f = {
|
|
|
6273
6283
|
};
|
|
6274
6284
|
|
|
6275
6285
|
/* script */
|
|
6276
|
-
const __vue_script__$
|
|
6286
|
+
const __vue_script__$g = script$g;
|
|
6277
6287
|
|
|
6278
6288
|
/* template */
|
|
6279
|
-
var __vue_render__$
|
|
6289
|
+
var __vue_render__$g = function () {
|
|
6280
6290
|
var _vm = this;
|
|
6281
6291
|
var _h = _vm.$createElement;
|
|
6282
6292
|
var _c = _vm._self._c || _h;
|
|
@@ -6291,44 +6301,44 @@ var __vue_render__$f = function () {
|
|
|
6291
6301
|
on: { change: _vm.onChange },
|
|
6292
6302
|
})
|
|
6293
6303
|
};
|
|
6294
|
-
var __vue_staticRenderFns__$
|
|
6295
|
-
__vue_render__$
|
|
6304
|
+
var __vue_staticRenderFns__$g = [];
|
|
6305
|
+
__vue_render__$g._withStripped = true;
|
|
6296
6306
|
|
|
6297
6307
|
/* style */
|
|
6298
|
-
const __vue_inject_styles__$
|
|
6308
|
+
const __vue_inject_styles__$g = function (inject) {
|
|
6299
6309
|
if (!inject) return
|
|
6300
6310
|
inject("data-v-eee16c3c_0", { source: "\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":";;AAEA,oCAAoC","file":"index.vue"}, media: undefined });
|
|
6301
6311
|
|
|
6302
6312
|
};
|
|
6303
6313
|
/* scoped */
|
|
6304
|
-
const __vue_scope_id__$
|
|
6314
|
+
const __vue_scope_id__$g = "data-v-eee16c3c";
|
|
6305
6315
|
/* module identifier */
|
|
6306
|
-
const __vue_module_identifier__$
|
|
6316
|
+
const __vue_module_identifier__$g = undefined;
|
|
6307
6317
|
/* functional template */
|
|
6308
|
-
const __vue_is_functional_template__$
|
|
6318
|
+
const __vue_is_functional_template__$g = false;
|
|
6309
6319
|
/* style inject SSR */
|
|
6310
6320
|
|
|
6311
6321
|
/* style inject shadow dom */
|
|
6312
6322
|
|
|
6313
6323
|
|
|
6314
6324
|
|
|
6315
|
-
const __vue_component__$
|
|
6316
|
-
{ render: __vue_render__$
|
|
6317
|
-
__vue_inject_styles__$
|
|
6318
|
-
__vue_script__$
|
|
6319
|
-
__vue_scope_id__$
|
|
6320
|
-
__vue_is_functional_template__$
|
|
6321
|
-
__vue_module_identifier__$
|
|
6325
|
+
const __vue_component__$g = /*#__PURE__*/normalizeComponent(
|
|
6326
|
+
{ render: __vue_render__$g, staticRenderFns: __vue_staticRenderFns__$g },
|
|
6327
|
+
__vue_inject_styles__$g,
|
|
6328
|
+
__vue_script__$g,
|
|
6329
|
+
__vue_scope_id__$g,
|
|
6330
|
+
__vue_is_functional_template__$g,
|
|
6331
|
+
__vue_module_identifier__$g,
|
|
6322
6332
|
false,
|
|
6323
6333
|
createInjector,
|
|
6324
6334
|
undefined,
|
|
6325
6335
|
undefined
|
|
6326
6336
|
);
|
|
6327
6337
|
|
|
6328
|
-
__vue_component__$
|
|
6338
|
+
__vue_component__$g.install = Vue => Vue.component(__vue_component__$g.name, __vue_component__$g);
|
|
6329
6339
|
|
|
6330
6340
|
//
|
|
6331
|
-
var script$
|
|
6341
|
+
var script$f = {
|
|
6332
6342
|
name: 'ele-timeline',
|
|
6333
6343
|
props: {
|
|
6334
6344
|
url: {
|
|
@@ -6416,10 +6426,10 @@ var script$e = {
|
|
|
6416
6426
|
};
|
|
6417
6427
|
|
|
6418
6428
|
/* script */
|
|
6419
|
-
const __vue_script__$
|
|
6429
|
+
const __vue_script__$f = script$f;
|
|
6420
6430
|
|
|
6421
6431
|
/* template */
|
|
6422
|
-
var __vue_render__$
|
|
6432
|
+
var __vue_render__$f = function () {
|
|
6423
6433
|
var _vm = this;
|
|
6424
6434
|
var _h = _vm.$createElement;
|
|
6425
6435
|
var _c = _vm._self._c || _h;
|
|
@@ -6497,7 +6507,7 @@ var __vue_render__$e = function () {
|
|
|
6497
6507
|
0
|
|
6498
6508
|
)
|
|
6499
6509
|
};
|
|
6500
|
-
var __vue_staticRenderFns__$
|
|
6510
|
+
var __vue_staticRenderFns__$f = [
|
|
6501
6511
|
function () {
|
|
6502
6512
|
var _vm = this;
|
|
6503
6513
|
var _h = _vm.$createElement;
|
|
@@ -6509,41 +6519,41 @@ var __vue_staticRenderFns__$e = [
|
|
|
6509
6519
|
])
|
|
6510
6520
|
},
|
|
6511
6521
|
];
|
|
6512
|
-
__vue_render__$
|
|
6522
|
+
__vue_render__$f._withStripped = true;
|
|
6513
6523
|
|
|
6514
6524
|
/* style */
|
|
6515
|
-
const __vue_inject_styles__$
|
|
6525
|
+
const __vue_inject_styles__$f = function (inject) {
|
|
6516
6526
|
if (!inject) return
|
|
6517
6527
|
inject("data-v-24d69f04_0", { source: ".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n.margin-t-8 {\n margin-top: 8px;\n}\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":"AAAA;EACE,qBAAqB;AACvB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AAEA;EACE,eAAe;AACjB;AAEA;EACE,+BAA+B;EAC/B,sCAAsC;EACtC,sCAAsC;EACtC,sCAAsC;EACtC,uCAAuC;EACvC,uCAAuC;EACvC,uCAAuC;EACvC,mDAAmD;EACnD,4BAA4B;EAC5B,4BAA4B;EAC5B,0BAA0B;EAC1B,wBAAwB;EACxB,8BAA8B;EAC9B,+BAA+B;EAC/B,qCAAqC;EACrC,gCAAgC;EAChC,4BAA4B;EAC5B,qDAAqD;EACrD,kDAAkD;EAClD,gDAAgD;EAChD,gCAAgC;EAChC,uCAAuC;EACvC,yBAAyB;EACzB,yBAAyB;EACzB,oCAAoC;AACtC;AAEA;EACE,4DAA4D;AAC9D;AAEA;EACE,4DAA4D;AAC9D;;AAEA,oCAAoC","file":"index.vue","sourcesContent":[".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n\n.margin-t-8 {\n margin-top: 8px;\n}\n\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined })
|
|
6518
6528
|
,inject("data-v-24d69f04_1", { source: ".ele-timeline__wrapper[data-v-24d69f04] {\n width: 100%;\n height: 100%;\n}\n.ele-timeline__wrapper .ele-timeline__item[data-v-24d69f04] {\n display: flex;\n flex-direction: row;\n}\n.ele-timeline__wrapper .ele-timeline__item:last-child .ele-timeline__middle .ele-timeline__traline[data-v-24d69f04] {\n display: none;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__left[data-v-24d69f04] {\n flex: 1;\n padding-right: 12px;\n padding-top: 16px;\n padding-bottom: 16px;\n text-align: right;\n display: flex;\n flex-direction: row;\n justify-content: end;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__left .titleline-left__date[data-v-24d69f04] {\n width: 100px;\n font-size: 14px;\n color: var(--idoole-black-064);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__middle[data-v-24d69f04] {\n width: 10px;\n display: flex;\n flex-direction: column;\n align-items: center;\n transform: translate(0, 20px);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__middle .ele-timeline__circle[data-v-24d69f04] {\n width: 100%;\n height: 10px;\n border-radius: 50%;\n border-width: 2px;\n border-style: solid;\n border-color: var(--idooel-primary-color);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__middle .ele-timeline__traline[data-v-24d69f04] {\n width: 1px;\n height: calc(100% - 10px);\n border-width: 1px;\n border-style: solid;\n border-color: var(--idoole-black-016);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right[data-v-24d69f04] {\n text-align: left;\n flex: 2;\n padding-left: 12px;\n padding-top: 16px;\n padding-bottom: 16px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title[data-v-24d69f04] {\n line-height: 22px;\n display: flex;\n flex-direction: row;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title[data-v-24d69f04] {\n color: var(--idoole-black-088);\n font-size: 14px;\n font-weight: bold;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info[data-v-24d69f04] {\n font-size: 14px;\n color: var(--idoole-black-064);\n margin-left: 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info[data-v-24d69f04]::before {\n content: \"\";\n display: inline-block;\n width: 6px;\n height: 6px;\n border-radius: 50%;\n margin-right: 8px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info.success[data-v-24d69f04]::before {\n background: var(--idoole-success-06);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info.warning[data-v-24d69f04]::before {\n background: var(--idoole-warning-06);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info.error[data-v-24d69f04]::before {\n background: var(--idoole-error-06);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__oper[data-v-24d69f04] {\n line-height: 22px;\n margin-top: 8px;\n margin-left: 12px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__oper .oper-name[data-v-24d69f04] {\n color: var(--idoole-black-088);\n font-size: 14px;\n font-weight: bold;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__subtitle[data-v-24d69f04] {\n margin-left: 12px;\n display: flex;\n flex-direction: row;\n line-height: 22px;\n margin-top: 4px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__subtitle .right-subtitle__field[data-v-24d69f04] {\n flex-shrink: 0;\n font-size: 14px;\n color: var(--idoole-black-064);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__subtitle .right-subtitle__content[data-v-24d69f04] {\n font-size: 14px;\n color: var(--idoole-black-088);\n font-weight: bold;\n margin-left: 4px;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/timeline/src/index.vue","index.vue"],"names":[],"mappings":"AA6HA;EACA,WAAA;EACA,YAAA;AC5HA;AD6HA;EACA,aAAA;EACA,mBAAA;AC3HA;AD8HA;EACA,aAAA;AC5HA;ADgIA;EACA,OAAA;EACA,mBAAA;EACA,iBAAA;EACA,oBAAA;EACA,iBAAA;EACA,aAAA;EACA,mBAAA;EACA,oBAAA;AC9HA;AD+HA;EACA,YAAA;EACA,eAAA;EACA,8BAAA;AC7HA;ADgIA;EACA,WAAA;EACA,aAAA;EACA,sBAAA;EACA,mBAAA;EACA,6BAAA;AC9HA;AD+HA;EACA,WAAA;EACA,YAAA;EACA,kBAAA;EACA,iBAAA;EACA,mBAAA;EACA,yCAAA;AC7HA;AD+HA;EACA,UAAA;EACA,yBAAA;EACA,iBAAA;EACA,mBAAA;EACA,qCAAA;AC7HA;ADgIA;EACA,gBAAA;EACA,OAAA;EACA,kBAAA;EACA,iBAAA;EACA,oBAAA;AC9HA;AD+HA;EACA,iBAAA;EACA,aAAA;EACA,mBAAA;AC7HA;AD8HA;EACA,8BAAA;EACA,eAAA;EACA,iBAAA;AC5HA;AD8HA;EACA,eAAA;EACA,8BAAA;EACA,iBAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;AC5HA;AD6HA;EACA,WAAA;EACA,qBAAA;EACA,UAAA;EACA,WAAA;EACA,kBAAA;EACA,iBAAA;AC3HA;AD8HA;EACA,oCAAA;AC5HA;ADgIA;EACA,oCAAA;AC9HA;ADkIA;EACA,kCAAA;AChIA;ADqIA;EACA,iBAAA;EACA,eAAA;EACA,iBAAA;ACnIA;ADoIA;EACA,8BAAA;EACA,eAAA;EACA,iBAAA;AClIA;ADqIA;EACA,iBAAA;EACA,aAAA;EACA,mBAAA;EACA,iBAAA;EACA,eAAA;ACnIA;ADoIA;EACA,cAAA;EACA,eAAA;EACA,8BAAA;AClIA;ADoIA;EACA,eAAA;EACA,8BAAA;EACA,iBAAA;EACA,gBAAA;AClIA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"ele-timeline__wrapper\">\n <div class=\"ele-timeline__item\" v-for=\"item in innerDataSource\" :key=\"item.key\">\n <div class=\"ele-timeline__left\">\n <div class=\"titleline-left__date\">{{ item.date }}</div>\n </div>\n <div class=\"ele-timeline__middle\">\n <div class=\"ele-timeline__circle\"></div>\n <div class=\"ele-timeline__traline\"></div>\n </div>\n <div class=\"ele-timeline__right\">\n <slot v-if=\"$scopedSlots.right\" name=\"right\" :data=\"item\"></slot>\n <template v-else>\n <div class=\"timeline-right__title\">\n <span class=\"title\">{{ item.title }}</span>\n <span :class=\"['title-info', item.state == 1 && 'success', item.state == 2 && 'warning', item.state == 3 && 'error']\">{{ item.stateName }}</span>\n </div>\n <div class=\"timeline-right__oper\">\n 由\n <span class=\"oper-name\">{{ item.userName }}</span>\n 操作\n </div>\n <div class=\"timeline-right__subtitle\" v-for=\"label in item.labelList\" :key=\"label.value\">\n <div class=\"right-subtitle__field\">{{ label.label }}:</div>\n <div class=\"right-subtitle__content\">{{ label.value }}</div>\n </div>\n </template>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { net, type } from '@idooel/shared'\nimport { v4 as uuidv4 } from 'uuid'\nimport { CONTEXT, parseFieldMap } from '../../utils'\nexport default {\n name: 'ele-timeline',\n props: {\n url: {\n type: String\n },\n params: {\n type: Object,\n default: () => ({})\n },\n requestType: {\n type: String,\n default: 'GET'\n },\n fieldMap: {\n type: Object,\n default: () => ({})\n },\n dataSource: {\n type: Array,\n default: () => ([\n // {\n // date: '2023/05/09 03:34:56',\n // title: 123,\n // state: 1,\n // stateName: '成功',\n // userName: 'Name',\n // labelList: [\n // {\n // label: 'label',\n // value: 'value'\n // }\n // ],\n // action: '结班',\n // opinion: '意见'\n // }\n ])\n }\n },\n data () {\n return {\n innerDataSource: []\n }\n },\n inject: {\n [CONTEXT]: {\n default: () => (() => ({}))\n }\n },\n computed: {\n expressionData () {\n return {\n _route: this.$route.query,\n ...this[CONTEXT]()\n }\n }\n },\n async created() {\n if (this.url) {\n this.innerDataSource = await this.requestData()\n } else if (!type.isEmpty(this.dataSource)) {\n this.innerDataSource = this.dataSource\n } else {\n console.warn('ele-timeline: 请传入数据源')\n }\n },\n methods: {\n async requestData () {\n const ret = await net[this.requestType.toLowerCase()](\n this.url,\n { ...this.params, ...parseFieldMap(this.fieldMap, this.expressionData) }\n ).then(resp => {\n const { data } = resp || {}\n return data.map(item => {\n return {\n key: uuidv4(),\n ...item\n }\n })\n })\n return ret\n }\n }\n}\n</script>\n<style lang=\"scss\">\n@import '../../theme/index';\n</style>\n<style lang=\"scss\" scoped>\n.ele-timeline__wrapper {\n width: 100%;\n height: 100%;\n .ele-timeline__item {\n display: flex;\n flex-direction: row;\n &:last-child {\n .ele-timeline__middle {\n .ele-timeline__traline {\n display: none;\n }\n }\n }\n .ele-timeline__left {\n flex: 1;\n padding-right: 12px;\n padding-top: 16px;\n padding-bottom: 16px;\n text-align: right;\n display: flex;\n flex-direction: row;\n justify-content: end;\n .titleline-left__date {\n width: 100px;\n font-size: 14px;\n color: var(--idoole-black-064);\n }\n }\n .ele-timeline__middle {\n width: 10px;\n display: flex;\n flex-direction: column;\n align-items: center;\n transform: translate(0, 20px);\n .ele-timeline__circle {\n width: 100%;\n height: 10px;\n border-radius: 50%;\n border-width: 2px;\n border-style: solid;\n border-color: var(--idooel-primary-color);\n }\n .ele-timeline__traline {\n width: 1px;\n height: calc(100% - 10px);\n border-width: 1px;\n border-style: solid;\n border-color: var(--idoole-black-016);\n }\n }\n .ele-timeline__right {\n text-align: left;\n flex: 2;\n padding-left: 12px;\n padding-top: 16px;\n padding-bottom: 16px;\n .timeline-right__title {\n line-height: 22px;\n display: flex;\n flex-direction: row;\n .title {\n color: var(--idoole-black-088);\n font-size: 14px;\n font-weight: bold;\n }\n .title-info {\n font-size: 14px;\n color: var(--idoole-black-064);\n margin-left: 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n &::before {\n content: '';\n display: inline-block;\n width: 6px;\n height: 6px;\n border-radius: 50%;\n margin-right: 8px;\n }\n &.success {\n &::before {\n background: var(--idoole-success-06);\n }\n }\n &.warning {\n &::before {\n background: var(--idoole-warning-06);\n }\n }\n &.error {\n &::before {\n background: var(--idoole-error-06);\n }\n }\n }\n }\n .timeline-right__oper {\n line-height: 22px;\n margin-top: 8px;\n margin-left: 12px;\n .oper-name {\n color: var(--idoole-black-088);\n font-size: 14px;\n font-weight: bold;\n }\n }\n .timeline-right__subtitle {\n margin-left: 12px;\n display: flex;\n flex-direction: row;\n line-height: 22px;\n margin-top: 4px;\n .right-subtitle__field {\n flex-shrink: 0;\n font-size: 14px;\n color: var(--idoole-black-064);\n }\n .right-subtitle__content {\n font-size: 14px;\n color: var(--idoole-black-088);\n font-weight: bold;\n margin-left: 4px;\n }\n }\n }\n }\n}\n</style>",".ele-timeline__wrapper {\n width: 100%;\n height: 100%;\n}\n.ele-timeline__wrapper .ele-timeline__item {\n display: flex;\n flex-direction: row;\n}\n.ele-timeline__wrapper .ele-timeline__item:last-child .ele-timeline__middle .ele-timeline__traline {\n display: none;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__left {\n flex: 1;\n padding-right: 12px;\n padding-top: 16px;\n padding-bottom: 16px;\n text-align: right;\n display: flex;\n flex-direction: row;\n justify-content: end;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__left .titleline-left__date {\n width: 100px;\n font-size: 14px;\n color: var(--idoole-black-064);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__middle {\n width: 10px;\n display: flex;\n flex-direction: column;\n align-items: center;\n transform: translate(0, 20px);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__middle .ele-timeline__circle {\n width: 100%;\n height: 10px;\n border-radius: 50%;\n border-width: 2px;\n border-style: solid;\n border-color: var(--idooel-primary-color);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__middle .ele-timeline__traline {\n width: 1px;\n height: calc(100% - 10px);\n border-width: 1px;\n border-style: solid;\n border-color: var(--idoole-black-016);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right {\n text-align: left;\n flex: 2;\n padding-left: 12px;\n padding-top: 16px;\n padding-bottom: 16px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title {\n line-height: 22px;\n display: flex;\n flex-direction: row;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title {\n color: var(--idoole-black-088);\n font-size: 14px;\n font-weight: bold;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info {\n font-size: 14px;\n color: var(--idoole-black-064);\n margin-left: 16px;\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info::before {\n content: \"\";\n display: inline-block;\n width: 6px;\n height: 6px;\n border-radius: 50%;\n margin-right: 8px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info.success::before {\n background: var(--idoole-success-06);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info.warning::before {\n background: var(--idoole-warning-06);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__title .title-info.error::before {\n background: var(--idoole-error-06);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__oper {\n line-height: 22px;\n margin-top: 8px;\n margin-left: 12px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__oper .oper-name {\n color: var(--idoole-black-088);\n font-size: 14px;\n font-weight: bold;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__subtitle {\n margin-left: 12px;\n display: flex;\n flex-direction: row;\n line-height: 22px;\n margin-top: 4px;\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__subtitle .right-subtitle__field {\n flex-shrink: 0;\n font-size: 14px;\n color: var(--idoole-black-064);\n}\n.ele-timeline__wrapper .ele-timeline__item .ele-timeline__right .timeline-right__subtitle .right-subtitle__content {\n font-size: 14px;\n color: var(--idoole-black-088);\n font-weight: bold;\n margin-left: 4px;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
6519
6529
|
|
|
6520
6530
|
};
|
|
6521
6531
|
/* scoped */
|
|
6522
|
-
const __vue_scope_id__$
|
|
6532
|
+
const __vue_scope_id__$f = "data-v-24d69f04";
|
|
6523
6533
|
/* module identifier */
|
|
6524
|
-
const __vue_module_identifier__$
|
|
6534
|
+
const __vue_module_identifier__$f = undefined;
|
|
6525
6535
|
/* functional template */
|
|
6526
|
-
const __vue_is_functional_template__$
|
|
6536
|
+
const __vue_is_functional_template__$f = false;
|
|
6527
6537
|
/* style inject SSR */
|
|
6528
6538
|
|
|
6529
6539
|
/* style inject shadow dom */
|
|
6530
6540
|
|
|
6531
6541
|
|
|
6532
6542
|
|
|
6533
|
-
const __vue_component__$
|
|
6534
|
-
{ render: __vue_render__$
|
|
6535
|
-
__vue_inject_styles__$
|
|
6536
|
-
__vue_script__$
|
|
6537
|
-
__vue_scope_id__$
|
|
6538
|
-
__vue_is_functional_template__$
|
|
6539
|
-
__vue_module_identifier__$
|
|
6543
|
+
const __vue_component__$f = /*#__PURE__*/normalizeComponent(
|
|
6544
|
+
{ render: __vue_render__$f, staticRenderFns: __vue_staticRenderFns__$f },
|
|
6545
|
+
__vue_inject_styles__$f,
|
|
6546
|
+
__vue_script__$f,
|
|
6547
|
+
__vue_scope_id__$f,
|
|
6548
|
+
__vue_is_functional_template__$f,
|
|
6549
|
+
__vue_module_identifier__$f,
|
|
6540
6550
|
false,
|
|
6541
6551
|
createInjector,
|
|
6542
6552
|
undefined,
|
|
6543
6553
|
undefined
|
|
6544
6554
|
);
|
|
6545
6555
|
|
|
6546
|
-
__vue_component__$
|
|
6556
|
+
__vue_component__$f.install = Vue => Vue.component(__vue_component__$f.name, __vue_component__$f);
|
|
6547
6557
|
|
|
6548
6558
|
//
|
|
6549
6559
|
//
|
|
@@ -6553,7 +6563,7 @@ __vue_component__$e.install = Vue => Vue.component(__vue_component__$e.name, __v
|
|
|
6553
6563
|
//
|
|
6554
6564
|
//
|
|
6555
6565
|
|
|
6556
|
-
var script$
|
|
6566
|
+
var script$e = {
|
|
6557
6567
|
name: 'ele-text',
|
|
6558
6568
|
props: {
|
|
6559
6569
|
type: {
|
|
@@ -6573,10 +6583,10 @@ var script$d = {
|
|
|
6573
6583
|
};
|
|
6574
6584
|
|
|
6575
6585
|
/* script */
|
|
6576
|
-
const __vue_script__$
|
|
6586
|
+
const __vue_script__$e = script$e;
|
|
6577
6587
|
|
|
6578
6588
|
/* template */
|
|
6579
|
-
var __vue_render__$
|
|
6589
|
+
var __vue_render__$e = function () {
|
|
6580
6590
|
var _vm = this;
|
|
6581
6591
|
var _h = _vm.$createElement;
|
|
6582
6592
|
var _c = _vm._self._c || _h;
|
|
@@ -6591,41 +6601,41 @@ var __vue_render__$d = function () {
|
|
|
6591
6601
|
1
|
|
6592
6602
|
)
|
|
6593
6603
|
};
|
|
6594
|
-
var __vue_staticRenderFns__$
|
|
6595
|
-
__vue_render__$
|
|
6604
|
+
var __vue_staticRenderFns__$e = [];
|
|
6605
|
+
__vue_render__$e._withStripped = true;
|
|
6596
6606
|
|
|
6597
6607
|
/* style */
|
|
6598
|
-
const __vue_inject_styles__$
|
|
6608
|
+
const __vue_inject_styles__$e = function (inject) {
|
|
6599
6609
|
if (!inject) return
|
|
6600
6610
|
inject("data-v-636e07f7_0", { source: ".ele-text__wrapper[data-v-636e07f7] {\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.ele-text__wrapper.default .anticon[data-v-636e07f7], .ele-text__wrapper.default .message[data-v-636e07f7] {\n color: var(--idoole-black-064);\n}\n.ele-text__wrapper .anticon[data-v-636e07f7] {\n font-size: 16px;\n}\n.ele-text__wrapper .message[data-v-636e07f7] {\n font-size: 14px;\n margin-left: 4px;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/text/src/index.vue","index.vue"],"names":[],"mappings":"AA8BA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;AC7BA;AD+BA;EACA,8BAAA;AC7BA;ADgCA;EACA,eAAA;AC9BA;ADgCA;EACA,eAAA;EACA,gBAAA;AC9BA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div :class=\"['ele-text__wrapper', type]\">\n <ele-icon theme=\"filled\" :type=\"icon\"></ele-icon>\n <span class=\"message\">{{ message }}</span>\n </div>\n</template>\n\n<script>\nexport default {\n name: 'ele-text',\n props: {\n type: {\n String,\n // default success error warning info\n default: 'default'\n },\n message: {\n type: String\n }\n },\n computed: {\n icon() {\n return 'info-circle'\n }\n },\n}\n</script>\n\n<style lang=\"scss\" scoped>\n//\n.ele-text__wrapper {\n display: flex;\n flex-direction: row;\n align-items: center;\n &.default {\n .anticon, .message {\n color: var(--idoole-black-064);\n }\n }\n .anticon {\n font-size: 16px;\n }\n .message {\n font-size: 14px;\n margin-left: 4px;\n }\n}\n</style>",".ele-text__wrapper {\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.ele-text__wrapper.default .anticon, .ele-text__wrapper.default .message {\n color: var(--idoole-black-064);\n}\n.ele-text__wrapper .anticon {\n font-size: 16px;\n}\n.ele-text__wrapper .message {\n font-size: 14px;\n margin-left: 4px;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
6601
6611
|
|
|
6602
6612
|
};
|
|
6603
6613
|
/* scoped */
|
|
6604
|
-
const __vue_scope_id__$
|
|
6614
|
+
const __vue_scope_id__$e = "data-v-636e07f7";
|
|
6605
6615
|
/* module identifier */
|
|
6606
|
-
const __vue_module_identifier__$
|
|
6616
|
+
const __vue_module_identifier__$e = undefined;
|
|
6607
6617
|
/* functional template */
|
|
6608
|
-
const __vue_is_functional_template__$
|
|
6618
|
+
const __vue_is_functional_template__$e = false;
|
|
6609
6619
|
/* style inject SSR */
|
|
6610
6620
|
|
|
6611
6621
|
/* style inject shadow dom */
|
|
6612
6622
|
|
|
6613
6623
|
|
|
6614
6624
|
|
|
6615
|
-
const __vue_component__$
|
|
6616
|
-
{ render: __vue_render__$
|
|
6617
|
-
__vue_inject_styles__$
|
|
6618
|
-
__vue_script__$
|
|
6619
|
-
__vue_scope_id__$
|
|
6620
|
-
__vue_is_functional_template__$
|
|
6621
|
-
__vue_module_identifier__$
|
|
6625
|
+
const __vue_component__$e = /*#__PURE__*/normalizeComponent(
|
|
6626
|
+
{ render: __vue_render__$e, staticRenderFns: __vue_staticRenderFns__$e },
|
|
6627
|
+
__vue_inject_styles__$e,
|
|
6628
|
+
__vue_script__$e,
|
|
6629
|
+
__vue_scope_id__$e,
|
|
6630
|
+
__vue_is_functional_template__$e,
|
|
6631
|
+
__vue_module_identifier__$e,
|
|
6622
6632
|
false,
|
|
6623
6633
|
createInjector,
|
|
6624
6634
|
undefined,
|
|
6625
6635
|
undefined
|
|
6626
6636
|
);
|
|
6627
6637
|
|
|
6628
|
-
__vue_component__$
|
|
6638
|
+
__vue_component__$e.install = Vue => Vue.component(__vue_component__$e.name, __vue_component__$e);
|
|
6629
6639
|
|
|
6630
6640
|
//
|
|
6631
6641
|
//
|
|
@@ -6642,7 +6652,7 @@ __vue_component__$d.install = Vue => Vue.component(__vue_component__$d.name, __v
|
|
|
6642
6652
|
//
|
|
6643
6653
|
//
|
|
6644
6654
|
|
|
6645
|
-
var script$
|
|
6655
|
+
var script$d = {
|
|
6646
6656
|
name: 'ele-tabs',
|
|
6647
6657
|
components: {},
|
|
6648
6658
|
model: {
|
|
@@ -6678,10 +6688,10 @@ var script$c = {
|
|
|
6678
6688
|
};
|
|
6679
6689
|
|
|
6680
6690
|
/* script */
|
|
6681
|
-
const __vue_script__$
|
|
6691
|
+
const __vue_script__$d = script$d;
|
|
6682
6692
|
|
|
6683
6693
|
/* template */
|
|
6684
|
-
var __vue_render__$
|
|
6694
|
+
var __vue_render__$d = function () {
|
|
6685
6695
|
var _vm = this;
|
|
6686
6696
|
var _h = _vm.$createElement;
|
|
6687
6697
|
var _c = _vm._self._c || _h;
|
|
@@ -6732,41 +6742,41 @@ var __vue_render__$c = function () {
|
|
|
6732
6742
|
1
|
|
6733
6743
|
)
|
|
6734
6744
|
};
|
|
6735
|
-
var __vue_staticRenderFns__$
|
|
6736
|
-
__vue_render__$
|
|
6745
|
+
var __vue_staticRenderFns__$d = [];
|
|
6746
|
+
__vue_render__$d._withStripped = true;
|
|
6737
6747
|
|
|
6738
6748
|
/* style */
|
|
6739
|
-
const __vue_inject_styles__$
|
|
6749
|
+
const __vue_inject_styles__$d = function (inject) {
|
|
6740
6750
|
if (!inject) return
|
|
6741
6751
|
inject("data-v-508efd50_0", { source: "[data-v-508efd50] .ant-tabs-nav-scroll {\n float: left !important;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/tabs/src/index.vue","index.vue"],"names":[],"mappings":"AAoDA;EACA,sBAAA;ACnDA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div>\n <a-tabs :default-active-key=\"activeKey\" :tabBarGutter=\"tabBarGutter\" :tabBarStyle=\"tabBarStyle\" @change=\"changeHandle\">\n <a-tab-pane v-for=\"(item, index) in tabsList\" :key=\"index\" :tab=\"item.tabName\" :disabled=\"item.disabled\">\n <template #tab>\n <component v-if=\"item.renderHeader\" :is=\"item.renderHeader\" ></component>\n <span v-else>{{ item.tabName }}</span>\n </template>\n <component :is=\"item.content\"></component>\n </a-tab-pane>\n </a-tabs>\n </div>\n</template>\n\n<script>\nexport default {\n name: 'ele-tabs',\n components: {},\n model: {\n prop: 'value',\n event: 'change'\n },\n props: {\n activeKey: {\n type: Number,\n default: 0\n },\n tabsList: {\n type: Array,\n default () {\n return []\n }\n },\n tabBarStyle: {\n type: Object,\n default () {\n return {}\n }\n },\n tabBarGutter: {\n type: Number\n }\n },\n methods: {\n changeHandle (key) {\n this.$emit('changeActiveKey', key)\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n::v-deep .ant-tabs-nav-scroll {\n float: left !important;\n}\n</style>","::v-deep .ant-tabs-nav-scroll {\n float: left !important;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
6742
6752
|
|
|
6743
6753
|
};
|
|
6744
6754
|
/* scoped */
|
|
6745
|
-
const __vue_scope_id__$
|
|
6755
|
+
const __vue_scope_id__$d = "data-v-508efd50";
|
|
6746
6756
|
/* module identifier */
|
|
6747
|
-
const __vue_module_identifier__$
|
|
6757
|
+
const __vue_module_identifier__$d = undefined;
|
|
6748
6758
|
/* functional template */
|
|
6749
|
-
const __vue_is_functional_template__$
|
|
6759
|
+
const __vue_is_functional_template__$d = false;
|
|
6750
6760
|
/* style inject SSR */
|
|
6751
6761
|
|
|
6752
6762
|
/* style inject shadow dom */
|
|
6753
6763
|
|
|
6754
6764
|
|
|
6755
6765
|
|
|
6756
|
-
const __vue_component__$
|
|
6757
|
-
{ render: __vue_render__$
|
|
6758
|
-
__vue_inject_styles__$
|
|
6759
|
-
__vue_script__$
|
|
6760
|
-
__vue_scope_id__$
|
|
6761
|
-
__vue_is_functional_template__$
|
|
6762
|
-
__vue_module_identifier__$
|
|
6766
|
+
const __vue_component__$d = /*#__PURE__*/normalizeComponent(
|
|
6767
|
+
{ render: __vue_render__$d, staticRenderFns: __vue_staticRenderFns__$d },
|
|
6768
|
+
__vue_inject_styles__$d,
|
|
6769
|
+
__vue_script__$d,
|
|
6770
|
+
__vue_scope_id__$d,
|
|
6771
|
+
__vue_is_functional_template__$d,
|
|
6772
|
+
__vue_module_identifier__$d,
|
|
6763
6773
|
false,
|
|
6764
6774
|
createInjector,
|
|
6765
6775
|
undefined,
|
|
6766
6776
|
undefined
|
|
6767
6777
|
);
|
|
6768
6778
|
|
|
6769
|
-
__vue_component__$
|
|
6779
|
+
__vue_component__$d.install = Vue => Vue.component(__vue_component__$d.name, __vue_component__$d);
|
|
6770
6780
|
|
|
6771
6781
|
/*!
|
|
6772
6782
|
* Cropper.js v1.4.1
|
|
@@ -10478,7 +10488,7 @@ var Cropper = function () {
|
|
|
10478
10488
|
assign(Cropper.prototype, render, preview, events, handlers, change, methods);
|
|
10479
10489
|
|
|
10480
10490
|
//
|
|
10481
|
-
var script$
|
|
10491
|
+
var script$c = {
|
|
10482
10492
|
name: 'ele-modal-img-crop',
|
|
10483
10493
|
model: {
|
|
10484
10494
|
event: 'input',
|
|
@@ -10619,10 +10629,10 @@ var script$b = {
|
|
|
10619
10629
|
};
|
|
10620
10630
|
|
|
10621
10631
|
/* script */
|
|
10622
|
-
const __vue_script__$
|
|
10632
|
+
const __vue_script__$c = script$c;
|
|
10623
10633
|
|
|
10624
10634
|
/* template */
|
|
10625
|
-
var __vue_render__$
|
|
10635
|
+
var __vue_render__$c = function () {
|
|
10626
10636
|
var _vm = this;
|
|
10627
10637
|
var _h = _vm.$createElement;
|
|
10628
10638
|
var _c = _vm._self._c || _h;
|
|
@@ -10740,44 +10750,44 @@ var __vue_render__$b = function () {
|
|
|
10740
10750
|
1
|
|
10741
10751
|
)
|
|
10742
10752
|
};
|
|
10743
|
-
var __vue_staticRenderFns__$
|
|
10744
|
-
__vue_render__$
|
|
10753
|
+
var __vue_staticRenderFns__$c = [];
|
|
10754
|
+
__vue_render__$c._withStripped = true;
|
|
10745
10755
|
|
|
10746
10756
|
/* style */
|
|
10747
|
-
const __vue_inject_styles__$
|
|
10757
|
+
const __vue_inject_styles__$c = function (inject) {
|
|
10748
10758
|
if (!inject) return
|
|
10749
10759
|
inject("data-v-1fd3602e_0", { source: "[data-v-1fd3602e] .ant-modal-body {\n padding: 16px;\n}\n[data-v-1fd3602e] .ant-modal-header {\n padding: 16px;\n}\n.ele-imgCrop__wrapper[data-v-1fd3602e] {\n display: flex;\n gap: 16px;\n justify-content: center;\n margin-bottom: 30px;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg[data-v-1fd3602e] {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n width: 100%;\n height: 100%;\n position: relative;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .img-crop-left__image[data-v-1fd3602e] {\n width: 100%;\n height: 100%;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload[data-v-1fd3602e] {\n width: 100%;\n height: 100%;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload[data-v-1fd3602e] .ele-upload__inner {\n height: 100%;\n border: unset;\n background: transparent !important;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload[data-v-1fd3602e] .ele-upload__inner .ele-upload__area {\n display: flex;\n flex-direction: column;\n height: 100%;\n align-items: center;\n justify-content: center;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload[data-v-1fd3602e] .ele-upload__inner .ele-upload__area .ele-upload__area--text {\n margin-top: 16px;\n display: flex;\n flex-direction: column;\n align-items: center;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-imgCrop__font1[data-v-1fd3602e] {\n color: var(--idoole-black-088);\n font-size: 16px;\n line-height: 24px !important;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-imgCrop__font2[data-v-1fd3602e] {\n color: var(--idoole-black-06);\n font-size: 14px;\n line-height: 22px;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__update[data-v-1fd3602e] {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n opacity: 0;\n cursor: pointer;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__right[data-v-1fd3602e] {\n position: relative;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__right span[data-v-1fd3602e] {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n}\n.ele-imgCrop__wrapper .ele-imgCrop__right .img-crop-right__image[data-v-1fd3602e] {\n width: 100%;\n height: 100%;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__item[data-v-1fd3602e] {\n width: 480px;\n height: 300px;\n border-radius: 2px;\n border: 1px dashed var(--idooel-form-title-border-color);\n background: var(--idooel-form-upload-bg-color);\n}\n.ele-imgCrop__tips[data-v-1fd3602e] {\n float: left;\n width: 80%;\n}\n.ele-imgCrop__error[data-v-1fd3602e] {\n color: var(--idooel-form-border-err-color) !important;\n}\n.ele-imgCrop__error2[data-v-1fd3602e] {\n color: var(--idooel-img-crop-err-color) !important;\n}\n.ele-imgCrop__icon[data-v-1fd3602e] {\n font-size: 48px;\n color: var(--idooel-link-06);\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/composite-components/modal-img-crop/src/index.vue","index.vue"],"names":[],"mappings":"AAsLA;EACA,aAAA;ACrLA;ADuLA;EACA,aAAA;ACpLA;ADsLA;EACA,aAAA;EACA,SAAA;EACA,uBAAA;EACA,mBAAA;ACnLA;ADqLA;EACA,aAAA;EACA,sBAAA;EACA,uBAAA;EACA,mBAAA;EACA,WAAA;EACA,YAAA;EACA,kBAAA;ACnLA;ADoLA;EACA,WAAA;EACA,YAAA;AClLA;ADoLA;EACA,WAAA;EACA,YAAA;AClLA;ADmLA;EACA,YAAA;EACA,aAAA;EACA,kCAAA;ACjLA;ADkLA;EACA,aAAA;EACA,sBAAA;EACA,YAAA;EACA,mBAAA;EACA,uBAAA;AChLA;ADiLA;EACA,gBAAA;EACA,aAAA;EACA,sBAAA;EACA,mBAAA;AC/KA;ADoLA;EACA,8BAAA;EACA,eAAA;EACA,4BAAA;AClLA;ADoLA;EACA,6BAAA;EACA,eAAA;EACA,iBAAA;AClLA;ADqLA;EACA,kBAAA;EACA,MAAA;EACA,OAAA;EACA,WAAA;EACA,YAAA;EACA,UAAA;EACA,eAAA;ACnLA;ADsLA;EACA,kBAAA;ACpLA;ADqLA;EACA,kBAAA;EACA,QAAA;EACA,SAAA;EACA,gCAAA;ACnLA;ADqLA;EACA,WAAA;EACA,YAAA;ACnLA;ADsLA;EACA,YAAA;EACA,aAAA;EACA,kBAAA;EACA,wDAAA;EACA,8CAAA;ACpLA;ADuLA;EACA,WAAA;EACA,UAAA;ACpLA;ADsLA;EACA,qDAAA;ACnLA;ADqLA;EACA,kDAAA;AClLA;ADoLA;EACA,eAAA;EACA,4BAAA;ACjLA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div>\n <ele-modal\n :ref=\"getEleModal\"\n :title=\"title\"\n :cancelText=\"cancelText\"\n :maskClosable=\"maskClosable\"\n v-on=\"$listeners\"\n :size=\"size\"\n :value=\"value\"\n @ok=\"handleOk\"\n :showDefaultFooter=\"true\"\n >\n <div class=\"ele-imgCrop__wrapper\">\n <div class=\"ele-imgCrop__left ele-imgCrop__item\">\n <div class=\"ele-imgCrop__noImg\">\n <ele-upload v-if=\"!fileId\" v-bind=\"uploadFileConfig\" class=\"ele-img-crop__upload\" @on-success=\"onUploadFileSuccess\" icon=\"inbox\" url=\"api/zuul/api-file/workbench/file\"></ele-upload>\n <template v-else>\n <img :ref=\"leftImage\" class=\"img-crop-left__image\" :src=\"imageUrl\" alt=\"\">\n </template>\n </div>\n <div class=\"margin-t-8\">\n <span v-if=\"imgtips\" class=\"ele-imgCrop__font1 ele-imgCrop__tips\" :class=\"isFail? 'ele-imgCrop__error' : ''\">{{ imgtips }}</span>\n <template v-else>\n <span class=\"ele-imgCrop__font1\">{{ fileName }}</span>\n <a-icon v-if=\"fileName\" @click=\"handleClickDeleteFile\" type=\"close\" style=\"cursor: pointer;float: right; line-height: 24px;\"/>\n </template>\n </div>\n </div>\n <div class=\"ele-imgCrop__right ele-imgCrop__item\">\n <span v-if=\"!fileId\" class=\"ele-imgCrop__font2\">左侧上传图片后可预览</span>\n <template v-else>\n <img class=\"img-crop-right__image\" :src=\"previewBase\" alt=\"\">\n </template>\n </div>\n </div>\n </ele-modal>\n </div>\n</template>\n\n<script>\nimport { v4 as uuidv4 } from 'uuid'\nimport Cropper from 'cropperjs'\nimport { util, net } from '@idooel/shared'\nexport default {\n name: 'ele-modal-img-crop',\n model: {\n event: 'input',\n prop: 'value'\n },\n props: {\n title: {\n type: String,\n default: '图像裁剪'\n },\n uploadFileConfig: {\n type: Object,\n default: () => {\n return {\n size: 10,\n accept: '*',\n byteConversion: 1024 * 1024\n }\n }\n },\n imageId: {\n type: String\n },\n maskClosable: {\n type: Boolean,\n default () {\n return false\n }\n },\n size: {\n type: String,\n default () {\n return 'big'\n }\n },\n value: {\n type: Boolean,\n default () {\n return false\n }\n },\n cropperConfig: {\n type: Object,\n default: () => {\n return {\n aspectRatio: 16 / 9\n }\n }\n }\n },\n data () {\n return {\n haveImg: false,\n imgtips: null,\n isFail: false,\n cancelText: '取消',\n fileName: null,\n fileId: null,\n previewBase: null,\n cropper: null\n }\n },\n computed: {\n leftImage () {\n return uuidv4()\n },\n imageUrl () {\n return `api-file/workbench/file/stream/${this.fileId}?origin=true`\n },\n getEleModal () {\n return uuidv4()\n }\n },\n watch: {\n value: {\n handler (value) {\n this.fileId = this.imageId\n if (value && this.fileId) {\n setTimeout(() => {\n this.initCropper()\n })\n }\n },\n immediate: true\n }\n },\n methods: {\n handleClickDeleteFile () {\n this.fileId = null\n this.fileName = null\n },\n handleOk () {\n this.cropper.getCroppedCanvas().toBlob(async (blob) => {\n await this.uploadFile(blob)\n this.$emit('input', false)\n this.$emit('change', this.fileId)\n })\n },\n async uploadFile (file) {\n const formData = new FormData()\n formData.append('serviceCode', 'cover-image')\n formData.append('_t', Math.random())\n formData.append('file', file)\n await net.post(\n 'zuul/api-file/workbench/file' + '?_csrf=' + localStorage.getItem('token'),\n formData\n ).then(() => {})\n },\n initCropper () {\n let previewReady = false\n console.log('this.$refs[this.leftImage', this.$refs[this.leftImage])\n this.cropper = new Cropper(this.$refs[this.leftImage], {\n aspectRatio: this.cropperConfig.aspectRatio,\n ready: () => {\n previewReady = true\n },\n crop: util.debounce(() => {\n if (!previewReady) {\n return\n }\n this.previewBase = this.cropper.getCroppedCanvas().toDataURL()\n }, 200)\n })\n },\n onUploadFileSuccess (props) {\n const { response: { data: { fileID } }, name } = props\n this.fileId = fileID\n this.fileName = name\n this.$nextTick(() => {\n this.initCropper()\n })\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n::v-deep .ant-modal-body {\n padding: 16px;\n}\n::v-deep .ant-modal-header {\n padding: 16px;\n}\n.ele-imgCrop__wrapper {\n display: flex;\n gap: 16px;\n justify-content: center;\n margin-bottom: 30px;\n .ele-imgCrop__left {\n .ele-imgCrop__noImg {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n width: 100%;\n height: 100%;\n position: relative;\n .img-crop-left__image {\n width: 100%;\n height: 100%;\n }\n .ele-img-crop__upload {\n width: 100%;\n height: 100%;\n ::v-deep .ele-upload__inner {\n height: 100%;\n border: unset;\n background: transparent !important;\n .ele-upload__area {\n display: flex;\n flex-direction: column;\n height: 100%;\n align-items: center;\n justify-content: center;\n .ele-upload__area--text {\n margin-top: 16px;\n display: flex;\n flex-direction: column;\n align-items: center;\n }\n }\n }\n }\n .ele-imgCrop__font1 {\n color: var(--idoole-black-088);\n font-size: 16px;\n line-height: 24px !important;\n }\n .ele-imgCrop__font2 {\n color: var(--idoole-black-06);\n font-size: 14px;\n line-height: 22px; \n }\n }\n .ele-imgCrop__update {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n opacity: 0;\n cursor: pointer;\n }\n }\n .ele-imgCrop__right {\n position: relative;\n span {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n }\n .img-crop-right__image {\n width: 100%;\n height: 100%;\n }\n }\n .ele-imgCrop__item {\n width: 480px;\n height: 300px;\n border-radius: 2px;\n border: 1px dashed var(--idooel-form-title-border-color);\n background: var(--idooel-form-upload-bg-color);\n }\n}\n.ele-imgCrop__tips {\n float: left;\n width: 80%;\n}\n.ele-imgCrop__error {\n color: var(--idooel-form-border-err-color) !important;\n}\n.ele-imgCrop__error2 {\n color: var(--idooel-img-crop-err-color) !important;\n}\n.ele-imgCrop__icon {\n font-size: 48px;\n color: var(--idooel-link-06);\n}\n</style>","::v-deep .ant-modal-body {\n padding: 16px;\n}\n\n::v-deep .ant-modal-header {\n padding: 16px;\n}\n\n.ele-imgCrop__wrapper {\n display: flex;\n gap: 16px;\n justify-content: center;\n margin-bottom: 30px;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n width: 100%;\n height: 100%;\n position: relative;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .img-crop-left__image {\n width: 100%;\n height: 100%;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload {\n width: 100%;\n height: 100%;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload ::v-deep .ele-upload__inner {\n height: 100%;\n border: unset;\n background: transparent !important;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload ::v-deep .ele-upload__inner .ele-upload__area {\n display: flex;\n flex-direction: column;\n height: 100%;\n align-items: center;\n justify-content: center;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-img-crop__upload ::v-deep .ele-upload__inner .ele-upload__area .ele-upload__area--text {\n margin-top: 16px;\n display: flex;\n flex-direction: column;\n align-items: center;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-imgCrop__font1 {\n color: var(--idoole-black-088);\n font-size: 16px;\n line-height: 24px !important;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__noImg .ele-imgCrop__font2 {\n color: var(--idoole-black-06);\n font-size: 14px;\n line-height: 22px;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__left .ele-imgCrop__update {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n opacity: 0;\n cursor: pointer;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__right {\n position: relative;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__right span {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n}\n.ele-imgCrop__wrapper .ele-imgCrop__right .img-crop-right__image {\n width: 100%;\n height: 100%;\n}\n.ele-imgCrop__wrapper .ele-imgCrop__item {\n width: 480px;\n height: 300px;\n border-radius: 2px;\n border: 1px dashed var(--idooel-form-title-border-color);\n background: var(--idooel-form-upload-bg-color);\n}\n\n.ele-imgCrop__tips {\n float: left;\n width: 80%;\n}\n\n.ele-imgCrop__error {\n color: var(--idooel-form-border-err-color) !important;\n}\n\n.ele-imgCrop__error2 {\n color: var(--idooel-img-crop-err-color) !important;\n}\n\n.ele-imgCrop__icon {\n font-size: 48px;\n color: var(--idooel-link-06);\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
10750
10760
|
|
|
10751
10761
|
};
|
|
10752
10762
|
/* scoped */
|
|
10753
|
-
const __vue_scope_id__$
|
|
10763
|
+
const __vue_scope_id__$c = "data-v-1fd3602e";
|
|
10754
10764
|
/* module identifier */
|
|
10755
|
-
const __vue_module_identifier__$
|
|
10765
|
+
const __vue_module_identifier__$c = undefined;
|
|
10756
10766
|
/* functional template */
|
|
10757
|
-
const __vue_is_functional_template__$
|
|
10767
|
+
const __vue_is_functional_template__$c = false;
|
|
10758
10768
|
/* style inject SSR */
|
|
10759
10769
|
|
|
10760
10770
|
/* style inject shadow dom */
|
|
10761
10771
|
|
|
10762
10772
|
|
|
10763
10773
|
|
|
10764
|
-
const __vue_component__$
|
|
10765
|
-
{ render: __vue_render__$
|
|
10766
|
-
__vue_inject_styles__$
|
|
10767
|
-
__vue_script__$
|
|
10768
|
-
__vue_scope_id__$
|
|
10769
|
-
__vue_is_functional_template__$
|
|
10770
|
-
__vue_module_identifier__$
|
|
10774
|
+
const __vue_component__$c = /*#__PURE__*/normalizeComponent(
|
|
10775
|
+
{ render: __vue_render__$c, staticRenderFns: __vue_staticRenderFns__$c },
|
|
10776
|
+
__vue_inject_styles__$c,
|
|
10777
|
+
__vue_script__$c,
|
|
10778
|
+
__vue_scope_id__$c,
|
|
10779
|
+
__vue_is_functional_template__$c,
|
|
10780
|
+
__vue_module_identifier__$c,
|
|
10771
10781
|
false,
|
|
10772
10782
|
createInjector,
|
|
10773
10783
|
undefined,
|
|
10774
10784
|
undefined
|
|
10775
10785
|
);
|
|
10776
10786
|
|
|
10777
|
-
__vue_component__$
|
|
10787
|
+
__vue_component__$c.install = Vue => Vue.component(__vue_component__$c.name, __vue_component__$c);
|
|
10778
10788
|
|
|
10779
10789
|
//
|
|
10780
|
-
var script$
|
|
10790
|
+
var script$b = {
|
|
10781
10791
|
name: 'ele-text-editor',
|
|
10782
10792
|
props: {
|
|
10783
10793
|
editorWidth: {
|
|
@@ -10823,10 +10833,10 @@ var script$a = {
|
|
|
10823
10833
|
};
|
|
10824
10834
|
|
|
10825
10835
|
/* script */
|
|
10826
|
-
const __vue_script__$
|
|
10836
|
+
const __vue_script__$b = script$b;
|
|
10827
10837
|
|
|
10828
10838
|
/* template */
|
|
10829
|
-
var __vue_render__$
|
|
10839
|
+
var __vue_render__$b = function () {
|
|
10830
10840
|
var _vm = this;
|
|
10831
10841
|
var _h = _vm.$createElement;
|
|
10832
10842
|
var _c = _vm._self._c || _h;
|
|
@@ -10849,41 +10859,41 @@ var __vue_render__$a = function () {
|
|
|
10849
10859
|
1
|
|
10850
10860
|
)
|
|
10851
10861
|
};
|
|
10852
|
-
var __vue_staticRenderFns__$
|
|
10853
|
-
__vue_render__$
|
|
10862
|
+
var __vue_staticRenderFns__$b = [];
|
|
10863
|
+
__vue_render__$b._withStripped = true;
|
|
10854
10864
|
|
|
10855
10865
|
/* style */
|
|
10856
|
-
const __vue_inject_styles__$
|
|
10866
|
+
const __vue_inject_styles__$b = function (inject) {
|
|
10857
10867
|
if (!inject) return
|
|
10858
10868
|
inject("data-v-baee03c0_0", { source: ".ele-editor__bottom[data-v-baee03c0] {\n height: 40px;\n padding: 8px 20px 8px 8px;\n border: 1px solid var(--idooel-form-title-border-color);\n border-top: 0px;\n}\n.ele-editor__bottom span[data-v-baee03c0] {\n color: var(--idoole-black-088);\n text-align: right;\n font-size: 12px;\n line-height: 20px;\n width: 100%;\n display: inline-block;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/text-editor/src/index.vue","index.vue"],"names":[],"mappings":"AA0DA;EACA,YAAA;EACA,yBAAA;EACA,uDAAA;EACA,eAAA;ACzDA;AD0DA;EACA,8BAAA;EACA,iBAAA;EACA,eAAA;EACA,iBAAA;EACA,WAAA;EACA,qBAAA;ACxDA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"ele-editor__wrapper\" :style=\"{width: editorWidth, height: editorHeight}\">\n <Vueditor :ref=\"getVueditor\" :style=\"{width: editorWidth, height: editorHeight}\"></Vueditor>\n <div class=\"ele-editor__bottom\">\n <span>{{ innerContent.length }}字</span>\n </div>\n </div>\n</template>\n\n<script>\nimport { v4 as uuidv4 } from 'uuid'\nexport default {\n name: 'ele-text-editor',\n props: {\n editorWidth: {\n type: String\n },\n editorHeight: {\n type: String\n },\n maxLength: {\n type: Number,\n default () {\n return 10\n }\n }\n },\n data() {\n return {\n editorConfig: {},\n textEditorRef: null\n }\n },\n computed: {\n innerContent () {\n let content = this.textEditorRef ? this.textEditorRef.getContent() : ''\n if (this.textEditorRef && content.length > this.maxLength) {\n content = content.substring(0, this.maxLength)\n this.$nextTick(() => {\n this.textEditorRef.setContent(content)\n })\n }\n this.$emit('input', content)\n return content\n },\n getVueditor () {\n return uuidv4()\n }\n },\n watch: {},\n methods: {},\n mounted () {\n this.textEditorRef = this.$refs[this.getVueditor]\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.ele-editor__bottom {\n height: 40px;\n padding: 8px 20px 8px 8px;\n border: 1px solid var(--idooel-form-title-border-color);\n border-top: 0px;\n span {\n color: var(--idoole-black-088);\n text-align: right;\n font-size: 12px;\n line-height: 20px;\n width: 100%;\n display: inline-block;\n }\n}\n</style>",".ele-editor__bottom {\n height: 40px;\n padding: 8px 20px 8px 8px;\n border: 1px solid var(--idooel-form-title-border-color);\n border-top: 0px;\n}\n.ele-editor__bottom span {\n color: var(--idoole-black-088);\n text-align: right;\n font-size: 12px;\n line-height: 20px;\n width: 100%;\n display: inline-block;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
10859
10869
|
|
|
10860
10870
|
};
|
|
10861
10871
|
/* scoped */
|
|
10862
|
-
const __vue_scope_id__$
|
|
10872
|
+
const __vue_scope_id__$b = "data-v-baee03c0";
|
|
10863
10873
|
/* module identifier */
|
|
10864
|
-
const __vue_module_identifier__$
|
|
10874
|
+
const __vue_module_identifier__$b = undefined;
|
|
10865
10875
|
/* functional template */
|
|
10866
|
-
const __vue_is_functional_template__$
|
|
10876
|
+
const __vue_is_functional_template__$b = false;
|
|
10867
10877
|
/* style inject SSR */
|
|
10868
10878
|
|
|
10869
10879
|
/* style inject shadow dom */
|
|
10870
10880
|
|
|
10871
10881
|
|
|
10872
10882
|
|
|
10873
|
-
const __vue_component__$
|
|
10874
|
-
{ render: __vue_render__$
|
|
10875
|
-
__vue_inject_styles__$
|
|
10876
|
-
__vue_script__$
|
|
10877
|
-
__vue_scope_id__$
|
|
10878
|
-
__vue_is_functional_template__$
|
|
10879
|
-
__vue_module_identifier__$
|
|
10883
|
+
const __vue_component__$b = /*#__PURE__*/normalizeComponent(
|
|
10884
|
+
{ render: __vue_render__$b, staticRenderFns: __vue_staticRenderFns__$b },
|
|
10885
|
+
__vue_inject_styles__$b,
|
|
10886
|
+
__vue_script__$b,
|
|
10887
|
+
__vue_scope_id__$b,
|
|
10888
|
+
__vue_is_functional_template__$b,
|
|
10889
|
+
__vue_module_identifier__$b,
|
|
10880
10890
|
false,
|
|
10881
10891
|
createInjector,
|
|
10882
10892
|
undefined,
|
|
10883
10893
|
undefined
|
|
10884
10894
|
);
|
|
10885
10895
|
|
|
10886
|
-
__vue_component__$
|
|
10896
|
+
__vue_component__$b.install = Vue => Vue.component(__vue_component__$b.name, __vue_component__$b);
|
|
10887
10897
|
|
|
10888
10898
|
//
|
|
10889
10899
|
//
|
|
@@ -10898,7 +10908,7 @@ __vue_component__$a.install = Vue => Vue.component(__vue_component__$a.name, __v
|
|
|
10898
10908
|
//
|
|
10899
10909
|
//
|
|
10900
10910
|
|
|
10901
|
-
var script$
|
|
10911
|
+
var script$a = {
|
|
10902
10912
|
name: 'ele-textarea',
|
|
10903
10913
|
model: {
|
|
10904
10914
|
prop: 'value',
|
|
@@ -10940,10 +10950,10 @@ var script$9 = {
|
|
|
10940
10950
|
};
|
|
10941
10951
|
|
|
10942
10952
|
/* script */
|
|
10943
|
-
const __vue_script__$
|
|
10953
|
+
const __vue_script__$a = script$a;
|
|
10944
10954
|
|
|
10945
10955
|
/* template */
|
|
10946
|
-
var __vue_render__$
|
|
10956
|
+
var __vue_render__$a = function () {
|
|
10947
10957
|
var _vm = this;
|
|
10948
10958
|
var _h = _vm.$createElement;
|
|
10949
10959
|
var _c = _vm._self._c || _h;
|
|
@@ -10959,41 +10969,41 @@ var __vue_render__$9 = function () {
|
|
|
10959
10969
|
on: { change: _vm.onChange },
|
|
10960
10970
|
})
|
|
10961
10971
|
};
|
|
10962
|
-
var __vue_staticRenderFns__$
|
|
10963
|
-
__vue_render__$
|
|
10972
|
+
var __vue_staticRenderFns__$a = [];
|
|
10973
|
+
__vue_render__$a._withStripped = true;
|
|
10964
10974
|
|
|
10965
10975
|
/* style */
|
|
10966
|
-
const __vue_inject_styles__$
|
|
10976
|
+
const __vue_inject_styles__$a = function (inject) {
|
|
10967
10977
|
if (!inject) return
|
|
10968
10978
|
inject("data-v-27d78bca_0", { source: "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n", map: {"version":3,"sources":[],"names":[],"mappings":"","file":"index.vue"}, media: undefined });
|
|
10969
10979
|
|
|
10970
10980
|
};
|
|
10971
10981
|
/* scoped */
|
|
10972
|
-
const __vue_scope_id__$
|
|
10982
|
+
const __vue_scope_id__$a = "data-v-27d78bca";
|
|
10973
10983
|
/* module identifier */
|
|
10974
|
-
const __vue_module_identifier__$
|
|
10984
|
+
const __vue_module_identifier__$a = undefined;
|
|
10975
10985
|
/* functional template */
|
|
10976
|
-
const __vue_is_functional_template__$
|
|
10986
|
+
const __vue_is_functional_template__$a = false;
|
|
10977
10987
|
/* style inject SSR */
|
|
10978
10988
|
|
|
10979
10989
|
/* style inject shadow dom */
|
|
10980
10990
|
|
|
10981
10991
|
|
|
10982
10992
|
|
|
10983
|
-
const __vue_component__$
|
|
10984
|
-
{ render: __vue_render__$
|
|
10985
|
-
__vue_inject_styles__$
|
|
10986
|
-
__vue_script__$
|
|
10987
|
-
__vue_scope_id__$
|
|
10988
|
-
__vue_is_functional_template__$
|
|
10989
|
-
__vue_module_identifier__$
|
|
10993
|
+
const __vue_component__$a = /*#__PURE__*/normalizeComponent(
|
|
10994
|
+
{ render: __vue_render__$a, staticRenderFns: __vue_staticRenderFns__$a },
|
|
10995
|
+
__vue_inject_styles__$a,
|
|
10996
|
+
__vue_script__$a,
|
|
10997
|
+
__vue_scope_id__$a,
|
|
10998
|
+
__vue_is_functional_template__$a,
|
|
10999
|
+
__vue_module_identifier__$a,
|
|
10990
11000
|
false,
|
|
10991
11001
|
createInjector,
|
|
10992
11002
|
undefined,
|
|
10993
11003
|
undefined
|
|
10994
11004
|
);
|
|
10995
11005
|
|
|
10996
|
-
__vue_component__$
|
|
11006
|
+
__vue_component__$a.install = Vue => Vue.component(__vue_component__$a.name, __vue_component__$a);
|
|
10997
11007
|
|
|
10998
11008
|
//
|
|
10999
11009
|
//
|
|
@@ -11003,7 +11013,7 @@ __vue_component__$9.install = Vue => Vue.component(__vue_component__$9.name, __v
|
|
|
11003
11013
|
//
|
|
11004
11014
|
//
|
|
11005
11015
|
|
|
11006
|
-
var script$
|
|
11016
|
+
var script$9 = {
|
|
11007
11017
|
props: {
|
|
11008
11018
|
label: {
|
|
11009
11019
|
type: String
|
|
@@ -11012,10 +11022,10 @@ var script$8 = {
|
|
|
11012
11022
|
};
|
|
11013
11023
|
|
|
11014
11024
|
/* script */
|
|
11015
|
-
const __vue_script__$
|
|
11025
|
+
const __vue_script__$9 = script$9;
|
|
11016
11026
|
|
|
11017
11027
|
/* template */
|
|
11018
|
-
var __vue_render__$
|
|
11028
|
+
var __vue_render__$9 = function () {
|
|
11019
11029
|
var _vm = this;
|
|
11020
11030
|
var _h = _vm.$createElement;
|
|
11021
11031
|
var _c = _vm._self._c || _h;
|
|
@@ -11025,34 +11035,34 @@ var __vue_render__$8 = function () {
|
|
|
11025
11035
|
_c("span", { staticClass: "label__suffix" }, [_vm._v(":")]),
|
|
11026
11036
|
])
|
|
11027
11037
|
};
|
|
11028
|
-
var __vue_staticRenderFns__$
|
|
11029
|
-
__vue_render__$
|
|
11038
|
+
var __vue_staticRenderFns__$9 = [];
|
|
11039
|
+
__vue_render__$9._withStripped = true;
|
|
11030
11040
|
|
|
11031
11041
|
/* style */
|
|
11032
|
-
const __vue_inject_styles__$
|
|
11042
|
+
const __vue_inject_styles__$9 = function (inject) {
|
|
11033
11043
|
if (!inject) return
|
|
11034
11044
|
inject("data-v-07e596bf_0", { source: ".g-search__label[data-v-07e596bf] {\n /* width: 69px; */\n flex-basis: 69px;\n height: 32px;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n}\n.g-search__label .label__title[data-v-07e596bf], .g-search__label .label__suffix[data-v-07e596bf] {\n font-size: 14px;\n color: rgba(0, 0, 0, 0.88);\n white-space: nowrap;\n}\n.g-search__label .label__suffix[data-v-07e596bf] {\n margin-left: 4px;\n}\n\n/*# sourceMappingURL=label.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/composite-components/search-area/src/label.vue","label.vue"],"names":[],"mappings":"AAkBA;EACA,iBAAA;EACA,gBAAA;EACA,YAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,8BAAA;ACjBA;ADkBA;EACA,eAAA;EACA,0BAAA;EACA,mBAAA;AChBA;ADkBA;EACA,gBAAA;AChBA;;AAEA,oCAAoC","file":"label.vue","sourcesContent":["<template>\n <div class=\"g-search__label\">\n <span class=\"label__title\">{{ label }}</span>\n <span class=\"label__suffix\">:</span>\n </div>\n</template>\n\n<script>\nexport default {\n props: {\n label: {\n type: String\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.g-search__label {\n /* width: 69px; */\n flex-basis: 69px;\n height: 32px;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n .label__title, .label__suffix {\n font-size: 14px;\n color: rgba(0, 0, 0, 0.88);\n white-space: nowrap;\n }\n .label__suffix {\n margin-left: 4px;\n }\n}\n</style>",".g-search__label {\n /* width: 69px; */\n flex-basis: 69px;\n height: 32px;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n}\n.g-search__label .label__title, .g-search__label .label__suffix {\n font-size: 14px;\n color: rgba(0, 0, 0, 0.88);\n white-space: nowrap;\n}\n.g-search__label .label__suffix {\n margin-left: 4px;\n}\n\n/*# sourceMappingURL=label.vue.map */"]}, media: undefined });
|
|
11035
11045
|
|
|
11036
11046
|
};
|
|
11037
11047
|
/* scoped */
|
|
11038
|
-
const __vue_scope_id__$
|
|
11048
|
+
const __vue_scope_id__$9 = "data-v-07e596bf";
|
|
11039
11049
|
/* module identifier */
|
|
11040
|
-
const __vue_module_identifier__$
|
|
11050
|
+
const __vue_module_identifier__$9 = undefined;
|
|
11041
11051
|
/* functional template */
|
|
11042
|
-
const __vue_is_functional_template__$
|
|
11052
|
+
const __vue_is_functional_template__$9 = false;
|
|
11043
11053
|
/* style inject SSR */
|
|
11044
11054
|
|
|
11045
11055
|
/* style inject shadow dom */
|
|
11046
11056
|
|
|
11047
11057
|
|
|
11048
11058
|
|
|
11049
|
-
const __vue_component__$
|
|
11050
|
-
{ render: __vue_render__$
|
|
11051
|
-
__vue_inject_styles__$
|
|
11052
|
-
__vue_script__$
|
|
11053
|
-
__vue_scope_id__$
|
|
11054
|
-
__vue_is_functional_template__$
|
|
11055
|
-
__vue_module_identifier__$
|
|
11059
|
+
const __vue_component__$9 = /*#__PURE__*/normalizeComponent(
|
|
11060
|
+
{ render: __vue_render__$9, staticRenderFns: __vue_staticRenderFns__$9 },
|
|
11061
|
+
__vue_inject_styles__$9,
|
|
11062
|
+
__vue_script__$9,
|
|
11063
|
+
__vue_scope_id__$9,
|
|
11064
|
+
__vue_is_functional_template__$9,
|
|
11065
|
+
__vue_module_identifier__$9,
|
|
11056
11066
|
false,
|
|
11057
11067
|
createInjector,
|
|
11058
11068
|
undefined,
|
|
@@ -11060,10 +11070,10 @@ __vue_render__$8._withStripped = true;
|
|
|
11060
11070
|
);
|
|
11061
11071
|
|
|
11062
11072
|
//
|
|
11063
|
-
var script$
|
|
11073
|
+
var script$8 = {
|
|
11064
11074
|
name: 'ele-search-area',
|
|
11065
11075
|
components: {
|
|
11066
|
-
Label: __vue_component__$
|
|
11076
|
+
Label: __vue_component__$9
|
|
11067
11077
|
},
|
|
11068
11078
|
props: {
|
|
11069
11079
|
gutter: {
|
|
@@ -11202,10 +11212,10 @@ var script$7 = {
|
|
|
11202
11212
|
};
|
|
11203
11213
|
|
|
11204
11214
|
/* script */
|
|
11205
|
-
const __vue_script__$
|
|
11215
|
+
const __vue_script__$8 = script$8;
|
|
11206
11216
|
|
|
11207
11217
|
/* template */
|
|
11208
|
-
var __vue_render__$
|
|
11218
|
+
var __vue_render__$8 = function () {
|
|
11209
11219
|
var _vm = this;
|
|
11210
11220
|
var _h = _vm.$createElement;
|
|
11211
11221
|
var _c = _vm._self._c || _h;
|
|
@@ -11391,44 +11401,44 @@ var __vue_render__$7 = function () {
|
|
|
11391
11401
|
1
|
|
11392
11402
|
)
|
|
11393
11403
|
};
|
|
11394
|
-
var __vue_staticRenderFns__$
|
|
11395
|
-
__vue_render__$
|
|
11404
|
+
var __vue_staticRenderFns__$8 = [];
|
|
11405
|
+
__vue_render__$8._withStripped = true;
|
|
11396
11406
|
|
|
11397
11407
|
/* style */
|
|
11398
|
-
const __vue_inject_styles__$
|
|
11408
|
+
const __vue_inject_styles__$8 = function (inject) {
|
|
11399
11409
|
if (!inject) return
|
|
11400
11410
|
inject("data-v-48ea0d0b_0", { source: ".search-area__wrapper[data-v-48ea0d0b] {\n padding-top: 16px;\n padding-left: 16px;\n padding-right: 16px;\n}\n.search-area__wrapper[data-v-48ea0d0b] .ant-col:last-child {\n float: right;\n}\n.search-area__wrapper .search-area__item[data-v-48ea0d0b] {\n height: 32px;\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.search-area__wrapper .search-area__item.search-area--action[data-v-48ea0d0b] {\n justify-content: end;\n}\n.search-area__wrapper .search-area__item .expand-collapse[data-v-48ea0d0b] {\n margin-left: 8px;\n height: 32px;\n padding: 4px 16px;\n color: var(--idooel-primary-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n}\n.search-area__wrapper .search-area__item .expand-collapse .expand-collapse__text[data-v-48ea0d0b] {\n font-size: 14px;\n}\n.search-area__wrapper .search-area__item .expand-collapse .expand-collapse__icon[data-v-48ea0d0b] {\n font-size: 16px;\n margin-left: 8px;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/composite-components/search-area/src/index.vue","index.vue"],"names":[],"mappings":"AAwLA;EACA,iBAAA;EACA,kBAAA;EACA,mBAAA;ACvLA;ADyLA;EACA,YAAA;ACvLA;AD0LA;EACA,YAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;ACxLA;ADyLA;EACA,oBAAA;ACvLA;ADyLA;EACA,gBAAA;EACA,YAAA;EACA,iBAAA;EACA,kCAAA;EACA,aAAA;EACA,mBAAA;EACA,mBAAA;EACA,uBAAA;EACA,eAAA;ACvLA;ADwLA;EACA,eAAA;ACtLA;ADwLA;EACA,eAAA;EACA,gBAAA;ACtLA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"search-area__wrapper\">\n <a-row :gutter=\"gutter\">\n <template v-for=\"(item, idx) in innerDataSource\">\n <a-col v-if=\"item._show\" :span=\"item.span || span\" :key=\"idx\">\n <div v-if=\"item.type == '_action'\" class=\"search-area__item search-area--action\">\n <ele-button icon=\"search\" type=\"primary\" @click=\"handleClickSearch\">查询</ele-button>\n <ele-button style=\"margin-left:8px;\" icon=\"reload\" @click=\"handleClickReset\">重置</ele-button>\n <div v-if=\"innerDataSource.length > cuttingFormula + 1\" class=\"expand-collapse\" @click=\"handleClickExpandCollapse\">\n <span class=\"expand-collapse__text\">{{ isExpand ? '收起' : '展开' }}</span>\n <span class=\"expand-collapse__icon\">\n <a-icon v-if=\"isExpand\" type=\"up\" />\n <a-icon v-else type=\"down\" />\n </span>\n </div>\n </div>\n <div v-else class=\"search-area__item\">\n <template v-if=\"item.type == 'Input'\">\n <Label :label=\"item.label\"></Label>\n <ele-input v-model=\"item._value\"></ele-input>\n </template>\n <template v-else-if=\"item.type == 'Select'\">\n <Label :label=\"item.label\"></Label>\n <ele-select v-model=\"item._value\" :multiple=\"item.multiple\" :data-source=\"item.optionList\"></ele-select>\n </template>\n <template v-else-if=\"item.type == 'DatePicker'\">\n <Label :label=\"item.label\"></Label>\n <ele-date v-model=\"item._value\" :format=\"item.format\"></ele-date>\n </template>\n <template v-else-if=\"item.type == 'ele-date-range'\">\n <Label :label=\"item.label\"></Label>\n <ele-date-range v-model=\"item._value\" :format=\"item.format\" :show-time=\"item.showTime\"></ele-date-range>\n </template>\n </div>\n </a-col>\n </template>\n </a-row>\n </div>\n</template>\n\n<script>\nimport Label from './label.vue'\nimport moment from 'moment'\nimport { parse } from '@idooel/expression'\nexport default {\n name: 'ele-search-area',\n components: {\n Label\n },\n props: {\n gutter: {\n type: [Number, Array, Object],\n default: () => ([\n 16, 8\n ])\n },\n span: {\n type: Number,\n default: 8\n },\n dataSource: {\n type: Array,\n required: true\n }\n },\n data() {\n return {\n isExpand: false\n }\n },\n computed: {\n cuttingFormula () {\n return (24 / this.span - 1)\n },\n buildDataSource () {\n return this.controlDisplayByFormula(this.mapDefaultValueToValue())\n },\n innerDataSource () {\n return [ ...this.buildDataSource, { type: '_action', _show: true }]\n }\n },\n created() {},\n methods: {\n controlDisplayByFormula (dataSource = []) {\n if (this.isExpand) {\n dataSource.forEach(item => {\n this.$set(item, '_show', true)\n })\n } else {\n dataSource.forEach((item, idx) => {\n if (idx < this.cuttingFormula) {\n this.$set(item, '_show', true)\n } else {\n this.$set(item, '_show', false)\n }\n })\n }\n return dataSource\n },\n buildDefaultValue (arg) {\n if (!arg || arg.charAt(0) !== '_') return arg\n return parse(arg, {\n _route: this.$route.query\n })\n },\n mapDefaultValueToValue () {\n this.dataSource.forEach(props => {\n this.$set(props, '_show', this.isExpand)\n if (props.defaultValue) {\n this.$set(props, '_value', this.buildDefaultValue(props.defaultValue))\n }\n })\n return this.dataSource\n },\n handleClickExpandCollapse () {\n this.isExpand = !this.isExpand\n },\n handleClickSearch () {\n const querys = this.extractValues()\n this.$emit('search', querys)\n },\n buildMapto (mapTo = [], dataSource) {\n const [ startField, endField ] = mapTo\n const [ startValue, endValue ] = dataSource || [null, null]\n return {\n [startField]: startValue,\n [endField]: endValue\n }\n },\n extractValues () {\n let ret = {}\n this.innerDataSource.filter(item => item.type !== '_action').forEach(item => {\n switch (item.type) {\n case 'DatePicker':\n ret[item.name] = typeof item._value == 'undefined' ? undefined : moment(item._value).format(item.format)\n break\n case 'ele-date-range':\n if (item.mapTo) {\n Object.assign(ret, this.buildMapto(item.mapTo, item._value))\n } else {\n ret[item.name] = (item._value || []).join(',')\n }\n break\n default:\n ret[item.name] = item._value\n break\n }\n })\n return ret\n },\n handleClickReset () {\n this.innerDataSource.filter(item => item.type !== '_action').forEach(item => {\n const { defaultValue } = item\n switch (item.type) {\n case 'Select':\n defaultValue && this.$set(item, '_value', this.buildDefaultValue(defaultValue))\n !defaultValue && this.$set(item, '_value', null)\n break\n case 'DatePicker':\n defaultValue && this.$set(item, '_value', this.buildDefaultValue(defaultValue))\n !defaultValue && this.$set(item, '_value', undefined)\n break\n case 'ele-date-range':\n defaultValue && this.$set(item, '_value', this.buildDefaultValue(defaultValue))\n !defaultValue && this.$set(item, '_value', [])\n break\n default:\n defaultValue && this.$set(item, '_value', this.buildDefaultValue(defaultValue))\n !defaultValue && this.$set(item, '_value', null)\n break\n }\n })\n //TODO defaultValue\n const querys = this.extractValues()\n this.$emit('search', querys)\n },\n onChangeSelect (value, props) {\n this.$set(props, '_value', value)\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.search-area__wrapper {\n padding-top: 16px;\n padding-left: 16px;\n padding-right: 16px;\n ::v-deep .ant-col {\n &:last-child {\n float: right;\n }\n }\n .search-area__item {\n height: 32px;\n display: flex;\n flex-direction: row;\n align-items: center;\n &.search-area--action {\n justify-content: end;\n }\n .expand-collapse {\n margin-left: 8px;\n height: 32px;\n padding: 4px 16px;\n color: var(--idooel-primary-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n .expand-collapse__text {\n font-size: 14px;\n }\n .expand-collapse__icon {\n font-size: 16px;\n margin-left: 8px;\n }\n }\n }\n}\n</style>",".search-area__wrapper {\n padding-top: 16px;\n padding-left: 16px;\n padding-right: 16px;\n}\n.search-area__wrapper ::v-deep .ant-col:last-child {\n float: right;\n}\n.search-area__wrapper .search-area__item {\n height: 32px;\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.search-area__wrapper .search-area__item.search-area--action {\n justify-content: end;\n}\n.search-area__wrapper .search-area__item .expand-collapse {\n margin-left: 8px;\n height: 32px;\n padding: 4px 16px;\n color: var(--idooel-primary-color);\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n}\n.search-area__wrapper .search-area__item .expand-collapse .expand-collapse__text {\n font-size: 14px;\n}\n.search-area__wrapper .search-area__item .expand-collapse .expand-collapse__icon {\n font-size: 16px;\n margin-left: 8px;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
11401
11411
|
|
|
11402
11412
|
};
|
|
11403
11413
|
/* scoped */
|
|
11404
|
-
const __vue_scope_id__$
|
|
11414
|
+
const __vue_scope_id__$8 = "data-v-48ea0d0b";
|
|
11405
11415
|
/* module identifier */
|
|
11406
|
-
const __vue_module_identifier__$
|
|
11416
|
+
const __vue_module_identifier__$8 = undefined;
|
|
11407
11417
|
/* functional template */
|
|
11408
|
-
const __vue_is_functional_template__$
|
|
11418
|
+
const __vue_is_functional_template__$8 = false;
|
|
11409
11419
|
/* style inject SSR */
|
|
11410
11420
|
|
|
11411
11421
|
/* style inject shadow dom */
|
|
11412
11422
|
|
|
11413
11423
|
|
|
11414
11424
|
|
|
11415
|
-
const __vue_component__$
|
|
11416
|
-
{ render: __vue_render__$
|
|
11417
|
-
__vue_inject_styles__$
|
|
11418
|
-
__vue_script__$
|
|
11419
|
-
__vue_scope_id__$
|
|
11420
|
-
__vue_is_functional_template__$
|
|
11421
|
-
__vue_module_identifier__$
|
|
11425
|
+
const __vue_component__$8 = /*#__PURE__*/normalizeComponent(
|
|
11426
|
+
{ render: __vue_render__$8, staticRenderFns: __vue_staticRenderFns__$8 },
|
|
11427
|
+
__vue_inject_styles__$8,
|
|
11428
|
+
__vue_script__$8,
|
|
11429
|
+
__vue_scope_id__$8,
|
|
11430
|
+
__vue_is_functional_template__$8,
|
|
11431
|
+
__vue_module_identifier__$8,
|
|
11422
11432
|
false,
|
|
11423
11433
|
createInjector,
|
|
11424
11434
|
undefined,
|
|
11425
11435
|
undefined
|
|
11426
11436
|
);
|
|
11427
11437
|
|
|
11428
|
-
__vue_component__$
|
|
11438
|
+
__vue_component__$8.install = Vue => Vue.component(__vue_component__$8.name, __vue_component__$8);
|
|
11429
11439
|
|
|
11430
11440
|
//
|
|
11431
|
-
var script$
|
|
11441
|
+
var script$7 = {
|
|
11432
11442
|
name: 'ele-button-group',
|
|
11433
11443
|
props: {
|
|
11434
11444
|
dataSource: {
|
|
@@ -11513,10 +11523,10 @@ var script$6 = {
|
|
|
11513
11523
|
};
|
|
11514
11524
|
|
|
11515
11525
|
/* script */
|
|
11516
|
-
const __vue_script__$
|
|
11526
|
+
const __vue_script__$7 = script$7;
|
|
11517
11527
|
|
|
11518
11528
|
/* template */
|
|
11519
|
-
var __vue_render__$
|
|
11529
|
+
var __vue_render__$7 = function () {
|
|
11520
11530
|
var _vm = this;
|
|
11521
11531
|
var _h = _vm.$createElement;
|
|
11522
11532
|
var _c = _vm._self._c || _h;
|
|
@@ -11574,44 +11584,44 @@ var __vue_render__$6 = function () {
|
|
|
11574
11584
|
2
|
|
11575
11585
|
)
|
|
11576
11586
|
};
|
|
11577
|
-
var __vue_staticRenderFns__$
|
|
11578
|
-
__vue_render__$
|
|
11587
|
+
var __vue_staticRenderFns__$7 = [];
|
|
11588
|
+
__vue_render__$7._withStripped = true;
|
|
11579
11589
|
|
|
11580
11590
|
/* style */
|
|
11581
|
-
const __vue_inject_styles__$
|
|
11591
|
+
const __vue_inject_styles__$7 = function (inject) {
|
|
11582
11592
|
if (!inject) return
|
|
11583
11593
|
inject("data-v-643f1a24_0", { source: ".button-group__wrapper[data-v-643f1a24] {\n display: flex;\n padding-left: 16px;\n padding-right: 16px;\n}\n.button-group__wrapper .ant-btn[data-v-643f1a24] {\n margin-left: 8px;\n}\n.button-group__wrapper .ant-btn[data-v-643f1a24]:first-child {\n margin-left: 0;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/composite-components/button-group/src/index.vue","index.vue"],"names":[],"mappings":"AAsGA;EACA,aAAA;EACA,kBAAA;EACA,mBAAA;ACrGA;ADsGA;EACA,gBAAA;ACpGA;ADqGA;EACA,cAAA;ACnGA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <div class=\"button-group__wrapper\">\n <template v-for=\"(item, idx) in innerDatasource\" >\n <ele-button\n v-if=\"isBool(item._show) ? item._show : true\"\n :type=\"item.type\"\n :icon=\"item.icon\"\n :mode=\"item.mode\"\n :data-source=\"item.optionList\"\n :event-name=\"item.eventName\"\n :record=\"item\"\n v-on=\"overrideButtonEvent\"\n :key=\"idx\">\n {{ item.label }}\n </ele-button>\n </template>\n <ele-modal-confirm v-model=\"modalConfirmValue\" :contextProp=\"currentContext\" v-on=\"overrideModalConfirmEvent\" v-bind=\"modalConfirmMeta\"></ele-modal-confirm>\n </div>\n</template>\n\n<script>\nimport { type } from '@idooel/shared'\nimport { parse } from '@idooel/expression'\nimport { CONTEXT } from '../../../utils'\nexport default {\n name: 'ele-button-group',\n props: {\n dataSource: {\n type: Array,\n default: () => []\n }\n },\n data() {\n return {\n innerDatasource: [],\n modalConfirmValue: false,\n modalConfirmMeta: {}\n }\n },\n inject: {\n [CONTEXT]: {\n default: () => (() => ({}))\n }\n },\n computed: {\n overrideButtonEvent () {\n const events = this.dataSource.reduce((ret, item) => {\n ret[item.eventName || 'click'] = (e) => {\n const { modalConfirm } = item\n if (modalConfirm) {\n this.modalConfirmMeta = modalConfirm\n this.modalConfirmValue = true\n }\n this.$emit(item.eventName || 'click', { ...e, record: item, ...this.currentContext })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events\n }\n },\n overrideModalConfirmEvent () {\n return {\n ...this.$listeners\n }\n },\n currentContext () {\n return {\n _route: this.$route.query,\n _routeMeta: this.$route.meta,\n ...this[CONTEXT]()\n }\n }\n },\n watch: {\n dataSource: {\n handler (dataSource) {\n this.innerDatasource = dataSource.map(item => {\n return {\n ...item,\n _show: this.executeExpression(item.show)\n }\n })\n },\n immediate: true\n }\n },\n methods: {\n executeExpression (expression) {\n if (type.isBool(expression)) return expression\n if (type.isEmpty(expression)) return true\n return parse(expression, { ...this.currentContext })\n },\n isBool (arg) {\n return type.isBool(arg)\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.button-group__wrapper {\n display: flex;\n padding-left: 16px;\n padding-right: 16px;\n .ant-btn {\n margin-left: 8px;\n &:first-child {\n margin-left: 0;\n }\n }\n}\n</style>",".button-group__wrapper {\n display: flex;\n padding-left: 16px;\n padding-right: 16px;\n}\n.button-group__wrapper .ant-btn {\n margin-left: 8px;\n}\n.button-group__wrapper .ant-btn:first-child {\n margin-left: 0;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
11584
11594
|
|
|
11585
11595
|
};
|
|
11586
11596
|
/* scoped */
|
|
11587
|
-
const __vue_scope_id__$
|
|
11597
|
+
const __vue_scope_id__$7 = "data-v-643f1a24";
|
|
11588
11598
|
/* module identifier */
|
|
11589
|
-
const __vue_module_identifier__$
|
|
11599
|
+
const __vue_module_identifier__$7 = undefined;
|
|
11590
11600
|
/* functional template */
|
|
11591
|
-
const __vue_is_functional_template__$
|
|
11601
|
+
const __vue_is_functional_template__$7 = false;
|
|
11592
11602
|
/* style inject SSR */
|
|
11593
11603
|
|
|
11594
11604
|
/* style inject shadow dom */
|
|
11595
11605
|
|
|
11596
11606
|
|
|
11597
11607
|
|
|
11598
|
-
const __vue_component__$
|
|
11599
|
-
{ render: __vue_render__$
|
|
11600
|
-
__vue_inject_styles__$
|
|
11601
|
-
__vue_script__$
|
|
11602
|
-
__vue_scope_id__$
|
|
11603
|
-
__vue_is_functional_template__$
|
|
11604
|
-
__vue_module_identifier__$
|
|
11608
|
+
const __vue_component__$7 = /*#__PURE__*/normalizeComponent(
|
|
11609
|
+
{ render: __vue_render__$7, staticRenderFns: __vue_staticRenderFns__$7 },
|
|
11610
|
+
__vue_inject_styles__$7,
|
|
11611
|
+
__vue_script__$7,
|
|
11612
|
+
__vue_scope_id__$7,
|
|
11613
|
+
__vue_is_functional_template__$7,
|
|
11614
|
+
__vue_module_identifier__$7,
|
|
11605
11615
|
false,
|
|
11606
11616
|
createInjector,
|
|
11607
11617
|
undefined,
|
|
11608
11618
|
undefined
|
|
11609
11619
|
);
|
|
11610
11620
|
|
|
11611
|
-
__vue_component__$
|
|
11621
|
+
__vue_component__$7.install = Vue => Vue.component(__vue_component__$7.name, __vue_component__$7);
|
|
11612
11622
|
|
|
11613
11623
|
//
|
|
11614
|
-
var script$
|
|
11624
|
+
var script$6 = {
|
|
11615
11625
|
name: 'ele-modal-form',
|
|
11616
11626
|
model: {
|
|
11617
11627
|
prop: 'value',
|
|
@@ -11882,10 +11892,10 @@ var script$5 = {
|
|
|
11882
11892
|
};
|
|
11883
11893
|
|
|
11884
11894
|
/* script */
|
|
11885
|
-
const __vue_script__$
|
|
11895
|
+
const __vue_script__$6 = script$6;
|
|
11886
11896
|
|
|
11887
11897
|
/* template */
|
|
11888
|
-
var __vue_render__$
|
|
11898
|
+
var __vue_render__$6 = function () {
|
|
11889
11899
|
var _vm = this;
|
|
11890
11900
|
var _h = _vm.$createElement;
|
|
11891
11901
|
var _c = _vm._self._c || _h;
|
|
@@ -11906,17 +11916,17 @@ var __vue_render__$5 = function () {
|
|
|
11906
11916
|
1
|
|
11907
11917
|
)
|
|
11908
11918
|
};
|
|
11909
|
-
var __vue_staticRenderFns__$
|
|
11910
|
-
__vue_render__$
|
|
11919
|
+
var __vue_staticRenderFns__$6 = [];
|
|
11920
|
+
__vue_render__$6._withStripped = true;
|
|
11911
11921
|
|
|
11912
11922
|
/* style */
|
|
11913
|
-
const __vue_inject_styles__$
|
|
11923
|
+
const __vue_inject_styles__$6 = undefined;
|
|
11914
11924
|
/* scoped */
|
|
11915
|
-
const __vue_scope_id__$
|
|
11925
|
+
const __vue_scope_id__$6 = undefined;
|
|
11916
11926
|
/* module identifier */
|
|
11917
|
-
const __vue_module_identifier__$
|
|
11927
|
+
const __vue_module_identifier__$6 = undefined;
|
|
11918
11928
|
/* functional template */
|
|
11919
|
-
const __vue_is_functional_template__$
|
|
11929
|
+
const __vue_is_functional_template__$6 = false;
|
|
11920
11930
|
/* style inject */
|
|
11921
11931
|
|
|
11922
11932
|
/* style inject SSR */
|
|
@@ -11925,20 +11935,20 @@ __vue_render__$5._withStripped = true;
|
|
|
11925
11935
|
|
|
11926
11936
|
|
|
11927
11937
|
|
|
11928
|
-
const __vue_component__$
|
|
11929
|
-
{ render: __vue_render__$
|
|
11930
|
-
__vue_inject_styles__$
|
|
11931
|
-
__vue_script__$
|
|
11932
|
-
__vue_scope_id__$
|
|
11933
|
-
__vue_is_functional_template__$
|
|
11934
|
-
__vue_module_identifier__$
|
|
11938
|
+
const __vue_component__$6 = /*#__PURE__*/normalizeComponent(
|
|
11939
|
+
{ render: __vue_render__$6, staticRenderFns: __vue_staticRenderFns__$6 },
|
|
11940
|
+
__vue_inject_styles__$6,
|
|
11941
|
+
__vue_script__$6,
|
|
11942
|
+
__vue_scope_id__$6,
|
|
11943
|
+
__vue_is_functional_template__$6,
|
|
11944
|
+
__vue_module_identifier__$6,
|
|
11935
11945
|
false,
|
|
11936
11946
|
undefined,
|
|
11937
11947
|
undefined,
|
|
11938
11948
|
undefined
|
|
11939
11949
|
);
|
|
11940
11950
|
|
|
11941
|
-
__vue_component__$
|
|
11951
|
+
__vue_component__$6.install = Vue => Vue.component(__vue_component__$6.name, __vue_component__$6);
|
|
11942
11952
|
|
|
11943
11953
|
//
|
|
11944
11954
|
//
|
|
@@ -11950,7 +11960,7 @@ __vue_component__$5.install = Vue => Vue.component(__vue_component__$5.name, __v
|
|
|
11950
11960
|
//
|
|
11951
11961
|
//
|
|
11952
11962
|
|
|
11953
|
-
var script$
|
|
11963
|
+
var script$5 = {
|
|
11954
11964
|
name: 'ele-modal-tree',
|
|
11955
11965
|
model: {
|
|
11956
11966
|
event: 'input',
|
|
@@ -12008,10 +12018,10 @@ var script$4 = {
|
|
|
12008
12018
|
};
|
|
12009
12019
|
|
|
12010
12020
|
/* script */
|
|
12011
|
-
const __vue_script__$
|
|
12021
|
+
const __vue_script__$5 = script$5;
|
|
12012
12022
|
|
|
12013
12023
|
/* template */
|
|
12014
|
-
var __vue_render__$
|
|
12024
|
+
var __vue_render__$5 = function () {
|
|
12015
12025
|
var _vm = this;
|
|
12016
12026
|
var _h = _vm.$createElement;
|
|
12017
12027
|
var _c = _vm._self._c || _h;
|
|
@@ -12033,44 +12043,44 @@ var __vue_render__$4 = function () {
|
|
|
12033
12043
|
1
|
|
12034
12044
|
)
|
|
12035
12045
|
};
|
|
12036
|
-
var __vue_staticRenderFns__$
|
|
12037
|
-
__vue_render__$
|
|
12046
|
+
var __vue_staticRenderFns__$5 = [];
|
|
12047
|
+
__vue_render__$5._withStripped = true;
|
|
12038
12048
|
|
|
12039
12049
|
/* style */
|
|
12040
|
-
const __vue_inject_styles__$
|
|
12050
|
+
const __vue_inject_styles__$5 = function (inject) {
|
|
12041
12051
|
if (!inject) return
|
|
12042
12052
|
inject("data-v-205df81d_0", { source: "\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":";;AAEA,oCAAoC","file":"index.vue"}, media: undefined });
|
|
12043
12053
|
|
|
12044
12054
|
};
|
|
12045
12055
|
/* scoped */
|
|
12046
|
-
const __vue_scope_id__$
|
|
12056
|
+
const __vue_scope_id__$5 = "data-v-205df81d";
|
|
12047
12057
|
/* module identifier */
|
|
12048
|
-
const __vue_module_identifier__$
|
|
12058
|
+
const __vue_module_identifier__$5 = undefined;
|
|
12049
12059
|
/* functional template */
|
|
12050
|
-
const __vue_is_functional_template__$
|
|
12060
|
+
const __vue_is_functional_template__$5 = false;
|
|
12051
12061
|
/* style inject SSR */
|
|
12052
12062
|
|
|
12053
12063
|
/* style inject shadow dom */
|
|
12054
12064
|
|
|
12055
12065
|
|
|
12056
12066
|
|
|
12057
|
-
const __vue_component__$
|
|
12058
|
-
{ render: __vue_render__$
|
|
12059
|
-
__vue_inject_styles__$
|
|
12060
|
-
__vue_script__$
|
|
12061
|
-
__vue_scope_id__$
|
|
12062
|
-
__vue_is_functional_template__$
|
|
12063
|
-
__vue_module_identifier__$
|
|
12067
|
+
const __vue_component__$5 = /*#__PURE__*/normalizeComponent(
|
|
12068
|
+
{ render: __vue_render__$5, staticRenderFns: __vue_staticRenderFns__$5 },
|
|
12069
|
+
__vue_inject_styles__$5,
|
|
12070
|
+
__vue_script__$5,
|
|
12071
|
+
__vue_scope_id__$5,
|
|
12072
|
+
__vue_is_functional_template__$5,
|
|
12073
|
+
__vue_module_identifier__$5,
|
|
12064
12074
|
false,
|
|
12065
12075
|
createInjector,
|
|
12066
12076
|
undefined,
|
|
12067
12077
|
undefined
|
|
12068
12078
|
);
|
|
12069
12079
|
|
|
12070
|
-
__vue_component__$
|
|
12080
|
+
__vue_component__$5.install = Vue => Vue.component(__vue_component__$5.name, __vue_component__$5);
|
|
12071
12081
|
|
|
12072
12082
|
//
|
|
12073
|
-
var script$
|
|
12083
|
+
var script$4 = {
|
|
12074
12084
|
name: 'ele-modal-confirm',
|
|
12075
12085
|
model: {
|
|
12076
12086
|
event: 'change',
|
|
@@ -12163,10 +12173,10 @@ var script$3 = {
|
|
|
12163
12173
|
};
|
|
12164
12174
|
|
|
12165
12175
|
/* script */
|
|
12166
|
-
const __vue_script__$
|
|
12176
|
+
const __vue_script__$4 = script$4;
|
|
12167
12177
|
|
|
12168
12178
|
/* template */
|
|
12169
|
-
var __vue_render__$
|
|
12179
|
+
var __vue_render__$4 = function () {
|
|
12170
12180
|
var _vm = this;
|
|
12171
12181
|
var _h = _vm.$createElement;
|
|
12172
12182
|
var _c = _vm._self._c || _h;
|
|
@@ -12198,18 +12208,175 @@ var __vue_render__$3 = function () {
|
|
|
12198
12208
|
1
|
|
12199
12209
|
)
|
|
12200
12210
|
};
|
|
12211
|
+
var __vue_staticRenderFns__$4 = [];
|
|
12212
|
+
__vue_render__$4._withStripped = true;
|
|
12213
|
+
|
|
12214
|
+
/* style */
|
|
12215
|
+
const __vue_inject_styles__$4 = function (inject) {
|
|
12216
|
+
if (!inject) return
|
|
12217
|
+
inject("data-v-07f0e100_0", { source: ".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n.margin-t-8 {\n margin-top: 8px;\n}\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":"AAAA;EACE,qBAAqB;AACvB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AACA;EACE,cAAc;AAChB;AAEA;EACE,eAAe;AACjB;AAEA;EACE,+BAA+B;EAC/B,sCAAsC;EACtC,sCAAsC;EACtC,sCAAsC;EACtC,uCAAuC;EACvC,uCAAuC;EACvC,uCAAuC;EACvC,mDAAmD;EACnD,4BAA4B;EAC5B,4BAA4B;EAC5B,0BAA0B;EAC1B,wBAAwB;EACxB,8BAA8B;EAC9B,+BAA+B;EAC/B,qCAAqC;EACrC,gCAAgC;EAChC,4BAA4B;EAC5B,qDAAqD;EACrD,kDAAkD;EAClD,gDAAgD;EAChD,gCAAgC;EAChC,uCAAuC;EACvC,yBAAyB;EACzB,yBAAyB;EACzB,oCAAoC;AACtC;AAEA;EACE,4DAA4D;AAC9D;AAEA;EACE,4DAA4D;AAC9D;;AAEA,oCAAoC","file":"index.vue","sourcesContent":[".has-error .ele-upload__wrapper .ele-upload__inner {\n border-color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--icon .anticon-cloud-upload {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__message {\n color: #F5222D;\n}\n.has-error .ele-upload__wrapper .ele-upload__inner .ele-upload__area .ele-upload__area--text .ele-upload__ext {\n color: #FFA39E;\n}\n\n.margin-t-8 {\n margin-top: 8px;\n}\n\n:root {\n --idooel-primary-color: #1890FF;\n --idoole-black-02: rgba(0, 0, 0, 0.04);\n --idoole-black-06: rgba(0, 0, 0, 0.44);\n --idoole-black-07: rgba(0, 0, 0, 0.64);\n --idoole-black-064: rgba(0, 0, 0, 0.64);\n --idoole-black-088: rgba(0, 0, 0, 0.88);\n --idoole-black-016: rgba(0, 0, 0, 0.16);\n --idooel-disabled-border-color: rgba(0, 0, 0, 0.16);\n --idoole-success-06: #52C41A;\n --idoole-warning-06: #FAAD14;\n --idoole-error-06: #F5222D;\n --idooel-border-width: 2;\n --idooel-border-color: #53a8ff;\n --idooel-column-border-width: 1;\n --idooel-column-border-color: #d9ecff;\n --idooel-row-even-color: #F0FAFF;\n --idooel-row-odd-color: #FFF;\n --idooel-form-title-border-color: rgba(0, 0, 0, 0.16);\n --idooel-form-upload-bg-color: rgba(0, 0, 0, 0.02);\n --idooel-form-upload-border-hover-color: #40A9FF;\n --idooel-form-border-radius: 2px;\n --idooel-form-border-err-color: #F5222D;\n --idooel-link-06: #1890FF;\n --idooel-link-03: #91D5FF;\n --idooel-img-crop-err-color: #FFA39E;\n}\n\n.ant-input-disabled {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n.ant-select-disabled .ant-select-selection {\n border-color: var(--idooel-disabled-border-color) !important;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined })
|
|
12218
|
+
,inject("data-v-07f0e100_1", { source: ".ele-modal-confirm__content[data-v-07f0e100] {\n margin-top: 8px;\n color: var(--idoole-black-088);\n font-size: 14px;\n line-height: 22px;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/composite-components/modal-confirm/src/index.vue","index.vue"],"names":[],"mappings":"AAkGA;EACA,eAAA;EACA,8BAAA;EACA,eAAA;EACA,iBAAA;ACjGA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <ele-modal :title=\"title\" :value=\"value\" :size=\"size\" @cancel=\"onCancel\" v-on=\"overrideEvents\" :buttonGroupMeta=\"buttonGroupMeta\">\n <ele-alert v-if=\"alert\" v-bind=\"alert\"></ele-alert>\n <div v-if=\"contentText\" class=\"ele-modal-confirm__content\">\n {{ contentText }}\n </div>\n </ele-modal>\n</template>\n\n<script>\nimport { CONTEXT } from '../../../utils'\nexport default {\n name: 'ele-modal-confirm',\n model: {\n event: 'change',\n prop: 'value'\n },\n props: {\n title: {\n type: String\n },\n size: {\n type: String,\n default: 'small'\n },\n alert: {\n type: [Object, Boolean],\n default: () => ({\n type: 'warning',\n message: '确定要删除吗?',\n description: '删除后将无法恢复',\n closable: false\n })\n },\n contentText: {\n type: String\n },\n value: {\n type: Boolean,\n default: false\n },\n buttonGroupMeta: {\n type: Object\n },\n //!deprecated\n contextProp: {\n type: Object,\n default: () => ({})\n }\n },\n inject: {\n [CONTEXT]: {\n default: () => (() => ({}))\n }\n },\n data () {\n return {}\n },\n computed: {\n currentContext () {\n const { exposed: exposedData = {} } = this[CONTEXT]()\n const exposed = Object.assign({}, exposedData, { closeModalConfirm: this.closeModalConfirm })\n return {\n _route: this.$route.query,\n _routeMeta: this.$route.meta,\n ...this[CONTEXT](),\n exposed\n }\n },\n overrideEvents () {\n if (!this.buttonGroupMeta) return {}\n const { elements = [] } = this.buttonGroupMeta\n const events = elements.reduce((ret, ele) =>{\n ret[ele.eventName || 'click'] = (e) => {\n this.$emit(ele.eventName || 'click', { ...e, ...this.currentContext })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events\n }\n }\n },\n methods: {\n closeModalConfirm () {\n this.$emit('change', false)\n },\n onCancel () {\n this.$emit('change', false)\n }\n }\n}\n</script>\n<style lang=\"scss\">\n@import '../../../theme/index';\n</style>\n<style lang=\"scss\" scoped>\n.ele-modal-confirm__content {\n margin-top: 8px;\n color: var(--idoole-black-088);\n font-size: 14px;\n line-height: 22px;\n}\n</style>",".ele-modal-confirm__content {\n margin-top: 8px;\n color: var(--idoole-black-088);\n font-size: 14px;\n line-height: 22px;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
12219
|
+
|
|
12220
|
+
};
|
|
12221
|
+
/* scoped */
|
|
12222
|
+
const __vue_scope_id__$4 = "data-v-07f0e100";
|
|
12223
|
+
/* module identifier */
|
|
12224
|
+
const __vue_module_identifier__$4 = undefined;
|
|
12225
|
+
/* functional template */
|
|
12226
|
+
const __vue_is_functional_template__$4 = false;
|
|
12227
|
+
/* style inject SSR */
|
|
12228
|
+
|
|
12229
|
+
/* style inject shadow dom */
|
|
12230
|
+
|
|
12231
|
+
|
|
12232
|
+
|
|
12233
|
+
const __vue_component__$4 = /*#__PURE__*/normalizeComponent(
|
|
12234
|
+
{ render: __vue_render__$4, staticRenderFns: __vue_staticRenderFns__$4 },
|
|
12235
|
+
__vue_inject_styles__$4,
|
|
12236
|
+
__vue_script__$4,
|
|
12237
|
+
__vue_scope_id__$4,
|
|
12238
|
+
__vue_is_functional_template__$4,
|
|
12239
|
+
__vue_module_identifier__$4,
|
|
12240
|
+
false,
|
|
12241
|
+
createInjector,
|
|
12242
|
+
undefined,
|
|
12243
|
+
undefined
|
|
12244
|
+
);
|
|
12245
|
+
|
|
12246
|
+
__vue_component__$4.install = Vue => Vue.component(__vue_component__$4.name, __vue_component__$4);
|
|
12247
|
+
|
|
12248
|
+
//
|
|
12249
|
+
var script$3 = {
|
|
12250
|
+
name: 'ele-modal-table',
|
|
12251
|
+
model: {
|
|
12252
|
+
event: 'change',
|
|
12253
|
+
prop: 'value'
|
|
12254
|
+
},
|
|
12255
|
+
props: {
|
|
12256
|
+
value: {
|
|
12257
|
+
type: Boolean,
|
|
12258
|
+
default: false
|
|
12259
|
+
},
|
|
12260
|
+
title: {
|
|
12261
|
+
type: String
|
|
12262
|
+
},
|
|
12263
|
+
size: {
|
|
12264
|
+
type: String,
|
|
12265
|
+
default: 'big'
|
|
12266
|
+
},
|
|
12267
|
+
meta: {
|
|
12268
|
+
type: Object,
|
|
12269
|
+
default: () => ({})
|
|
12270
|
+
}
|
|
12271
|
+
},
|
|
12272
|
+
data() {
|
|
12273
|
+
return {
|
|
12274
|
+
currentTableSelection: null
|
|
12275
|
+
};
|
|
12276
|
+
},
|
|
12277
|
+
computed: {
|
|
12278
|
+
exposed() {
|
|
12279
|
+
return {
|
|
12280
|
+
closeModal: this.closeModal,
|
|
12281
|
+
currentTableSelection: this.currentTableSelection
|
|
12282
|
+
};
|
|
12283
|
+
},
|
|
12284
|
+
assignAttrForEvents() {
|
|
12285
|
+
const events = this.footerMetaElements.reduce((ret, ele) => {
|
|
12286
|
+
ret[ele.eventName] = e => {
|
|
12287
|
+
this.$emit(ele.eventName || 'click', {
|
|
12288
|
+
...e,
|
|
12289
|
+
exposed: this.exposed
|
|
12290
|
+
});
|
|
12291
|
+
};
|
|
12292
|
+
return ret;
|
|
12293
|
+
}, {});
|
|
12294
|
+
return {
|
|
12295
|
+
...this.$listeners,
|
|
12296
|
+
...events
|
|
12297
|
+
};
|
|
12298
|
+
},
|
|
12299
|
+
footerMetaElements() {
|
|
12300
|
+
const {
|
|
12301
|
+
elements = []
|
|
12302
|
+
} = this.buttonGroupMeta;
|
|
12303
|
+
if (type.isFunction(elements)) {
|
|
12304
|
+
return elements.call(this);
|
|
12305
|
+
}
|
|
12306
|
+
return elements;
|
|
12307
|
+
},
|
|
12308
|
+
buildButtonGroupMeta() {
|
|
12309
|
+
return {
|
|
12310
|
+
...this.buttonGroupMeta,
|
|
12311
|
+
elements: this.footerMetaElements
|
|
12312
|
+
};
|
|
12313
|
+
},
|
|
12314
|
+
buttonGroupMeta() {
|
|
12315
|
+
const {
|
|
12316
|
+
footerMeta = {}
|
|
12317
|
+
} = this.meta;
|
|
12318
|
+
return footerMeta;
|
|
12319
|
+
}
|
|
12320
|
+
},
|
|
12321
|
+
methods: {
|
|
12322
|
+
closeModal() {
|
|
12323
|
+
this.$emit('change', false);
|
|
12324
|
+
},
|
|
12325
|
+
onChangeTableSelection(selection) {
|
|
12326
|
+
this.currentTableSelection = selection;
|
|
12327
|
+
}
|
|
12328
|
+
}
|
|
12329
|
+
};
|
|
12330
|
+
|
|
12331
|
+
/* script */
|
|
12332
|
+
const __vue_script__$3 = script$3;
|
|
12333
|
+
|
|
12334
|
+
/* template */
|
|
12335
|
+
var __vue_render__$3 = function () {
|
|
12336
|
+
var _vm = this;
|
|
12337
|
+
var _h = _vm.$createElement;
|
|
12338
|
+
var _c = _vm._self._c || _h;
|
|
12339
|
+
return _c(
|
|
12340
|
+
"ele-modal",
|
|
12341
|
+
_vm._g(
|
|
12342
|
+
{
|
|
12343
|
+
attrs: {
|
|
12344
|
+
title: _vm.title,
|
|
12345
|
+
"button-group-meta": _vm.buildButtonGroupMeta,
|
|
12346
|
+
value: _vm.value,
|
|
12347
|
+
size: _vm.size,
|
|
12348
|
+
},
|
|
12349
|
+
},
|
|
12350
|
+
_vm.assignAttrForEvents
|
|
12351
|
+
),
|
|
12352
|
+
[
|
|
12353
|
+
_c(
|
|
12354
|
+
"ele-tree-table-model",
|
|
12355
|
+
_vm._b(
|
|
12356
|
+
{
|
|
12357
|
+
attrs: { "over-height": 156 },
|
|
12358
|
+
on: { "on-change-table-selection": _vm.onChangeTableSelection },
|
|
12359
|
+
},
|
|
12360
|
+
"ele-tree-table-model",
|
|
12361
|
+
_vm.meta,
|
|
12362
|
+
false
|
|
12363
|
+
)
|
|
12364
|
+
),
|
|
12365
|
+
],
|
|
12366
|
+
1
|
|
12367
|
+
)
|
|
12368
|
+
};
|
|
12201
12369
|
var __vue_staticRenderFns__$3 = [];
|
|
12202
12370
|
__vue_render__$3._withStripped = true;
|
|
12203
12371
|
|
|
12204
12372
|
/* style */
|
|
12205
12373
|
const __vue_inject_styles__$3 = function (inject) {
|
|
12206
12374
|
if (!inject) return
|
|
12207
|
-
inject("data-v-
|
|
12208
|
-
,inject("data-v-07f0e100_1", { source: ".ele-modal-confirm__content[data-v-07f0e100] {\n margin-top: 8px;\n color: var(--idoole-black-088);\n font-size: 14px;\n line-height: 22px;\n}\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["/Users/huangshan/Goldgov/front/ganjiao/base-elearning-frontend-model/packages/components/packages/composite-components/modal-confirm/src/index.vue","index.vue"],"names":[],"mappings":"AAkGA;EACA,eAAA;EACA,8BAAA;EACA,eAAA;EACA,iBAAA;ACjGA;;AAEA,oCAAoC","file":"index.vue","sourcesContent":["<template>\n <ele-modal :title=\"title\" :value=\"value\" :size=\"size\" @cancel=\"onCancel\" v-on=\"overrideEvents\" :buttonGroupMeta=\"buttonGroupMeta\">\n <ele-alert v-if=\"alert\" v-bind=\"alert\"></ele-alert>\n <div v-if=\"contentText\" class=\"ele-modal-confirm__content\">\n {{ contentText }}\n </div>\n </ele-modal>\n</template>\n\n<script>\nimport { CONTEXT } from '../../../utils'\nexport default {\n name: 'ele-modal-confirm',\n model: {\n event: 'change',\n prop: 'value'\n },\n props: {\n title: {\n type: String\n },\n size: {\n type: String,\n default: 'small'\n },\n alert: {\n type: [Object, Boolean],\n default: () => ({\n type: 'warning',\n message: '确定要删除吗?',\n description: '删除后将无法恢复',\n closable: false\n })\n },\n contentText: {\n type: String\n },\n value: {\n type: Boolean,\n default: false\n },\n buttonGroupMeta: {\n type: Object\n },\n //!deprecated\n contextProp: {\n type: Object,\n default: () => ({})\n }\n },\n inject: {\n [CONTEXT]: {\n default: () => (() => ({}))\n }\n },\n data () {\n return {}\n },\n computed: {\n currentContext () {\n const { exposed: exposedData = {} } = this[CONTEXT]()\n const exposed = Object.assign({}, exposedData, { closeModalConfirm: this.closeModalConfirm })\n return {\n _route: this.$route.query,\n _routeMeta: this.$route.meta,\n ...this[CONTEXT](),\n exposed\n }\n },\n overrideEvents () {\n if (!this.buttonGroupMeta) return {}\n const { elements = [] } = this.buttonGroupMeta\n const events = elements.reduce((ret, ele) =>{\n ret[ele.eventName || 'click'] = (e) => {\n this.$emit(ele.eventName || 'click', { ...e, ...this.currentContext })\n }\n return ret\n }, {})\n return {\n ...this.$listeners,\n ...events\n }\n }\n },\n methods: {\n closeModalConfirm () {\n this.$emit('change', false)\n },\n onCancel () {\n this.$emit('change', false)\n }\n }\n}\n</script>\n<style lang=\"scss\">\n@import '../../../theme/index';\n</style>\n<style lang=\"scss\" scoped>\n.ele-modal-confirm__content {\n margin-top: 8px;\n color: var(--idoole-black-088);\n font-size: 14px;\n line-height: 22px;\n}\n</style>",".ele-modal-confirm__content {\n margin-top: 8px;\n color: var(--idoole-black-088);\n font-size: 14px;\n line-height: 22px;\n}\n\n/*# sourceMappingURL=index.vue.map */"]}, media: undefined });
|
|
12375
|
+
inject("data-v-0b93fa62_0", { source: "\n\n/*# sourceMappingURL=index.vue.map */", map: {"version":3,"sources":["index.vue"],"names":[],"mappings":";;AAEA,oCAAoC","file":"index.vue"}, media: undefined });
|
|
12209
12376
|
|
|
12210
12377
|
};
|
|
12211
12378
|
/* scoped */
|
|
12212
|
-
const __vue_scope_id__$3 = "data-v-
|
|
12379
|
+
const __vue_scope_id__$3 = "data-v-0b93fa62";
|
|
12213
12380
|
/* module identifier */
|
|
12214
12381
|
const __vue_module_identifier__$3 = undefined;
|
|
12215
12382
|
/* functional template */
|
|
@@ -12792,18 +12959,18 @@ __vue_render__._withStripped = true;
|
|
|
12792
12959
|
|
|
12793
12960
|
__vue_component__.install = Vue => Vue.component(__vue_component__.name, __vue_component__);
|
|
12794
12961
|
|
|
12795
|
-
__vue_component__$
|
|
12796
|
-
|
|
12797
|
-
__vue_component__$s.install = Vue => Vue.component(__vue_component__$s.name, __vue_component__$s);
|
|
12962
|
+
__vue_component__$v.install = Vue => Vue.component(__vue_component__$v.name, __vue_component__$v);
|
|
12798
12963
|
|
|
12799
12964
|
__vue_component__$t.install = Vue => Vue.component(__vue_component__$t.name, __vue_component__$t);
|
|
12800
12965
|
|
|
12801
|
-
__vue_component__$
|
|
12966
|
+
__vue_component__$u.install = Vue => Vue.component(__vue_component__$u.name, __vue_component__$u);
|
|
12967
|
+
|
|
12968
|
+
__vue_component__$s.install = Vue => Vue.component(__vue_component__$s.name, __vue_component__$s);
|
|
12802
12969
|
|
|
12803
|
-
const compositeComponents = [__vue_component__$
|
|
12970
|
+
const compositeComponents = [__vue_component__$7, __vue_component__$8, __vue_component__$6, __vue_component__$5, __vue_component__$c, __vue_component__$4, __vue_component__$3];
|
|
12804
12971
|
const businessComponents = [__vue_component__$2, __vue_component__$1, __vue_component__];
|
|
12805
|
-
const models = [__vue_component__$
|
|
12806
|
-
const components = [__vue_component__$B, __vue_component__$A, __vue_component__$z, __vue_component__$
|
|
12972
|
+
const models = [__vue_component__$v, __vue_component__$t, __vue_component__$u, __vue_component__$s];
|
|
12973
|
+
const components = [__vue_component__$C, __vue_component__$B, __vue_component__$A, __vue_component__$z, __vue_component__$x, __vue_component__$w, __vue_component__$r, __vue_component__$q, __vue_component__$p, __vue_component__$o, __vue_component__$n, __vue_component__$m, __vue_component__$l, __vue_component__$k, __vue_component__$j, __vue_component__$i, __vue_component__$h, __vue_component__$g, __vue_component__$f, __vue_component__$e, __vue_component__$d, __vue_component__$b, __vue_component__$a, ...compositeComponents, ...businessComponents, ...models];
|
|
12807
12974
|
const install = Vue => {
|
|
12808
12975
|
if (install.installed) return;
|
|
12809
12976
|
install.installed = true;
|
|
@@ -12812,4 +12979,4 @@ const install = Vue => {
|
|
|
12812
12979
|
});
|
|
12813
12980
|
};
|
|
12814
12981
|
|
|
12815
|
-
export { __vue_component__$
|
|
12982
|
+
export { __vue_component__$p as EleAlert, __vue_component__$h as EleBatchExport, __vue_component__$C as EleButton, __vue_component__$7 as EleButtonGroup, __vue_component__$j as EleCheckbox, __vue_component__$B as EleDate, __vue_component__$g as EleDateRange, __vue_component__$q as EleForm, __vue_component__$u as EleFormGroupModel, __vue_component__$t as EleFormPageModel, __vue_component__$m as EleIcon, __vue_component__$A as EleInput, __vue_component__$l as EleInputNumber, __vue_component__$k as EleModal, __vue_component__$4 as EleModalConfirm, __vue_component__$6 as EleModalForm, __vue_component__ as EleModalFsm, __vue_component__$c as EleModalImgCrop, __vue_component__$2 as EleModalImport, __vue_component__$3 as EleModalTable, __vue_component__$1 as EleModalTimeline, __vue_component__$5 as EleModalTree, __vue_component__$i as EleRadio, __vue_component__$8 as EleSearchArea, __vue_component__$z as EleSelect, __vue_component__$n as EleSelectEntity, __vue_component__$s as EleStepModel, __vue_component__$x as EleTable, __vue_component__$d as EleTabs, __vue_component__$e as EleText, __vue_component__$b as EleTextEditor, __vue_component__$a as EleTextarea, __vue_component__$f as EleTimeline, __vue_component__$r as EleTpl, __vue_component__$w as EleTree, __vue_component__$v as EleTreeTableModel, __vue_component__$o as EleUpload, install as default, models };
|