@web-utils/component 3.0.4 → 3.0.5
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/address-input/index.mjs +22 -24
- package/awesome-button/index.mjs +29 -30
- package/card/index.mjs +40 -42
- package/carousel/index.mjs +25 -27
- package/chat/index.mjs +57 -67
- package/chunks/FormTemp.7f91629d.mjs +165 -0
- package/chunks/confirmable-mixin.817b542f.mjs +116 -0
- package/chunks/{dataformat.e655611c.mjs → dataformat.f995e2f9.mjs} +3 -3
- package/chunks/{event.10295951.mjs → event.b5d855dd.mjs} +1 -1
- package/chunks/{form-input-mixin.78a567bc.mjs → form-input-mixin.4632ad36.mjs} +1 -1
- package/chunks/{form-item-mixin.57cb2019.mjs → form-item-mixin.ad148e7b.mjs} +13 -13
- package/color-picker/index.mjs +128 -0
- package/confirm-button/index.mjs +1 -1
- package/confirmable/index.mjs +1 -1
- package/data-box/index.mjs +32 -34
- package/data-card/index.mjs +33 -35
- package/data-cardtext/index.mjs +27 -29
- package/data-display/index.mjs +33 -35
- package/data-icons/index.mjs +28 -30
- package/data-imgtext/index.mjs +27 -30
- package/data-operatext/index.mjs +39 -41
- package/data-panel/index.mjs +36 -38
- package/data-pay/index.mjs +20 -23
- package/data-price/index.mjs +32 -34
- package/data-progress/index.mjs +27 -30
- package/data-rotate/index.mjs +17 -19
- package/data-table-picker/index.mjs +22 -23
- package/data-tabs/index.mjs +31 -33
- package/dialog-form/index.mjs +22 -27
- package/dynamic-table/index.mjs +36 -40
- package/editable-progress/index.mjs +14 -16
- package/editable-tree/index.mjs +139 -143
- package/egd-collapse-item/index.mjs +2 -1
- package/element-dialog/index.mjs +24 -25
- package/flow-designer/index.mjs +1095 -1111
- package/form-block/index.mjs +22 -24
- package/form-cascader/index.mjs +20 -20
- package/form-checkbox-group/index.mjs +24 -25
- package/form-date-picker/index.mjs +18 -19
- package/form-holder/index.mjs +14 -15
- package/form-input/index.mjs +23 -23
- package/form-input-email/index.mjs +17 -17
- package/form-input-id-card/index.mjs +24 -24
- package/form-input-number/index.mjs +1 -1
- package/form-input-phone-number/index.mjs +26 -26
- package/form-input-tag/index.mjs +1 -1
- package/form-input-time/index.mjs +17 -17
- package/form-item/index.mjs +54 -56
- package/form-item-group/index.mjs +31 -33
- package/form-radio-group/index.mjs +51 -52
- package/form-select/index.mjs +31 -32
- package/form-switch/index.mjs +22 -22
- package/form-textarea/index.mjs +20 -20
- package/fy-array/index.mjs +61 -65
- package/fy-cascader/index.mjs +19 -20
- package/fy-checkbox/index.mjs +32 -37
- package/fy-code/index.mjs +13 -10
- package/fy-curd/index.mjs +638 -660
- package/fy-date/index.mjs +20 -21
- package/fy-draggable/index.mjs +19 -20
- package/fy-dynamic/index.mjs +26 -27
- package/fy-form/index.mjs +111 -122
- package/fy-form-design/index.mjs +1238 -1270
- package/fy-input/index.mjs +15 -17
- package/fy-input-color/index.mjs +25 -27
- package/fy-input-icon/index.mjs +20 -21
- package/fy-input-map/index.mjs +22 -24
- package/fy-input-number/index.mjs +22 -23
- package/fy-input-table/index.mjs +15 -17
- package/fy-input-tree/index.mjs +28 -32
- package/fy-progress/index.mjs +23 -24
- package/fy-radio/index.mjs +18 -23
- package/fy-rate/index.mjs +12 -13
- package/fy-select/index.mjs +40 -44
- package/fy-slider/index.mjs +17 -18
- package/fy-switch/index.mjs +20 -21
- package/fy-tabs/index.mjs +19 -21
- package/fy-time/index.mjs +14 -20
- package/fy-title/index.mjs +1 -1
- package/fy-tree/index.mjs +17 -21
- package/fy-upload/index.mjs +74 -76
- package/guide-steps/index.mjs +22 -24
- package/image-cropper/index.mjs +50 -51
- package/image-preview/index.mjs +24 -26
- package/index.mjs +480 -477
- package/input-number/index.mjs +13 -14
- package/input-number-range/index.mjs +23 -24
- package/login/index.mjs +35 -40
- package/nav-bar/index.mjs +13 -14
- package/notice/index.mjs +18 -19
- package/package.json +3 -3
- package/page-index/index.mjs +33 -34
- package/page-index-top/index.mjs +22 -24
- package/pageable-table/index.mjs +92 -96
- package/pageable-view/index.mjs +33 -34
- package/search/index.mjs +21 -23
- package/static-pageable-table/index.mjs +18 -20
- package/swiper/index.mjs +22 -23
- package/table-view/index.mjs +49 -53
- package/tag-render/index.mjs +19 -21
- package/text-ellipsis/index.mjs +11 -12
- package/tinymce-editor/index.mjs +50 -51
- package/toolbar-button/index.mjs +18 -19
- package/vue-cron/index.mjs +104 -112
- package/web-types.json +85 -1
- package/x-input-tag/index.mjs +47 -50
- package/chunks/FormTemp.d079292b.mjs +0 -139
- package/chunks/confirmable-mixin.26e1d0e0.mjs +0 -197
- package/chunks/detail.d6f8e347.mjs +0 -29
package/chat/index.mjs
CHANGED
|
@@ -1,17 +1,7 @@
|
|
|
1
|
-
import { formatDate as
|
|
2
|
-
import { s as
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
import p from "element-ui/lib/form";
|
|
6
|
-
import l from "element-ui/lib/button";
|
|
7
|
-
import _ from "element-ui/lib/tooltip";
|
|
8
|
-
import d from "element-ui/lib/dropdown-item";
|
|
9
|
-
import h from "element-ui/lib/scrollbar";
|
|
10
|
-
import g from "element-ui/lib/popover";
|
|
11
|
-
import y from "element-ui/lib/dropdown-menu";
|
|
12
|
-
import v from "element-ui/lib/dropdown";
|
|
13
|
-
import { n as b } from "../chunks/vueComponentNormalizer.446f5dc4.mjs";
|
|
14
|
-
var w = function() {
|
|
1
|
+
import { formatDate as c } from "@web-utils/integrations/dayjs";
|
|
2
|
+
import { s as l } from "../chunks/util.ae730cde.mjs";
|
|
3
|
+
import { n as d } from "../chunks/vueComponentNormalizer.446f5dc4.mjs";
|
|
4
|
+
var u = function() {
|
|
15
5
|
var t = this, o = t.$createElement, e = t._self._c || o;
|
|
16
6
|
return e("div", {
|
|
17
7
|
staticClass: "avue-chat",
|
|
@@ -59,9 +49,9 @@ var w = function() {
|
|
|
59
49
|
}, [e("div", {
|
|
60
50
|
ref: "main",
|
|
61
51
|
staticClass: "web__main"
|
|
62
|
-
}, t._l(t.list, function(i,
|
|
52
|
+
}, t._l(t.list, function(i, a) {
|
|
63
53
|
return e("div", {
|
|
64
|
-
key:
|
|
54
|
+
key: a,
|
|
65
55
|
staticClass: "web__main-item",
|
|
66
56
|
class: {
|
|
67
57
|
"web__main-item--mine": i.mine
|
|
@@ -85,11 +75,11 @@ var w = function() {
|
|
|
85
75
|
}
|
|
86
76
|
}), i.text.list ? t._e() : e("ul", {
|
|
87
77
|
staticClass: "web__main-list"
|
|
88
|
-
}, t._l(i.text.list, function(s,
|
|
78
|
+
}, t._l(i.text.list, function(s, n) {
|
|
89
79
|
return e("li", {
|
|
90
|
-
key:
|
|
80
|
+
key: n,
|
|
91
81
|
on: {
|
|
92
|
-
click: function(
|
|
82
|
+
click: function(g) {
|
|
93
83
|
return t.handleItemMsg(s);
|
|
94
84
|
}
|
|
95
85
|
}
|
|
@@ -145,7 +135,7 @@ var w = function() {
|
|
|
145
135
|
}
|
|
146
136
|
}), e("div", {
|
|
147
137
|
staticClass: "web__msg-menu"
|
|
148
|
-
}, [e(
|
|
138
|
+
}, [e("ElDropdown", {
|
|
149
139
|
staticClass: "web__msg-submit",
|
|
150
140
|
attrs: {
|
|
151
141
|
"split-button": "",
|
|
@@ -159,7 +149,7 @@ var w = function() {
|
|
|
159
149
|
scopedSlots: t._u([{
|
|
160
150
|
key: "dropdown",
|
|
161
151
|
fn: function() {
|
|
162
|
-
return [e(
|
|
152
|
+
return [e("ElDropdownMenu", [e("ElDropdownItem", [e("ElPopover", {
|
|
163
153
|
attrs: {
|
|
164
154
|
placement: "top",
|
|
165
155
|
width: "160"
|
|
@@ -167,7 +157,7 @@ var w = function() {
|
|
|
167
157
|
scopedSlots: t._u([{
|
|
168
158
|
key: "reference",
|
|
169
159
|
fn: function() {
|
|
170
|
-
return [e(
|
|
160
|
+
return [e("ElButton", {
|
|
171
161
|
attrs: {
|
|
172
162
|
type: "text",
|
|
173
163
|
icon: "el-icon-plus"
|
|
@@ -183,7 +173,7 @@ var w = function() {
|
|
|
183
173
|
},
|
|
184
174
|
expression: "visible"
|
|
185
175
|
}
|
|
186
|
-
}, [e(
|
|
176
|
+
}, [e("ElInput", {
|
|
187
177
|
staticStyle: {
|
|
188
178
|
"margin-bottom": "10px"
|
|
189
179
|
},
|
|
@@ -207,7 +197,7 @@ var w = function() {
|
|
|
207
197
|
margin: "0",
|
|
208
198
|
"text-align": "right"
|
|
209
199
|
}
|
|
210
|
-
}, [e(
|
|
200
|
+
}, [e("ElButton", {
|
|
211
201
|
attrs: {
|
|
212
202
|
size: "mini",
|
|
213
203
|
type: "text"
|
|
@@ -217,7 +207,7 @@ var w = function() {
|
|
|
217
207
|
t.visible = !1;
|
|
218
208
|
}
|
|
219
209
|
}
|
|
220
|
-
}, [t._v(" 取消 ")]), e(
|
|
210
|
+
}, [t._v(" 取消 ")]), e("ElButton", {
|
|
221
211
|
attrs: {
|
|
222
212
|
type: "primary",
|
|
223
213
|
size: "mini"
|
|
@@ -225,19 +215,19 @@ var w = function() {
|
|
|
225
215
|
on: {
|
|
226
216
|
click: t.addKey
|
|
227
217
|
}
|
|
228
|
-
}, [t._v(" 确定 ")])], 1)], 1)], 1), e(
|
|
218
|
+
}, [t._v(" 确定 ")])], 1)], 1)], 1), e("ElScrollbar", {
|
|
229
219
|
staticStyle: {
|
|
230
220
|
height: "100px"
|
|
231
221
|
}
|
|
232
|
-
}, t._l(t.keylist, function(i,
|
|
233
|
-
return e(
|
|
234
|
-
key:
|
|
222
|
+
}, t._l(t.keylist, function(i, a) {
|
|
223
|
+
return e("ElDropdownItem", {
|
|
224
|
+
key: a,
|
|
235
225
|
nativeOn: {
|
|
236
226
|
click: function(s) {
|
|
237
227
|
return t.sendKey(i);
|
|
238
228
|
}
|
|
239
229
|
}
|
|
240
|
-
}, [e(
|
|
230
|
+
}, [e("ElTooltip", {
|
|
241
231
|
attrs: {
|
|
242
232
|
effect: "dark",
|
|
243
233
|
content: i,
|
|
@@ -263,7 +253,7 @@ var w = function() {
|
|
|
263
253
|
scopedSlots: t._u([{
|
|
264
254
|
key: "footer",
|
|
265
255
|
fn: function() {
|
|
266
|
-
return [e(
|
|
256
|
+
return [e("ElButton", {
|
|
267
257
|
attrs: {
|
|
268
258
|
size: "small"
|
|
269
259
|
},
|
|
@@ -272,7 +262,7 @@ var w = function() {
|
|
|
272
262
|
t.upload.box = !1;
|
|
273
263
|
}
|
|
274
264
|
}
|
|
275
|
-
}, [t._v("取 消")]), e(
|
|
265
|
+
}, [t._v("取 消")]), e("ElButton", {
|
|
276
266
|
attrs: {
|
|
277
267
|
type: "primary",
|
|
278
268
|
size: "small"
|
|
@@ -284,12 +274,12 @@ var w = function() {
|
|
|
284
274
|
},
|
|
285
275
|
proxy: !0
|
|
286
276
|
}], null, !1, 99567638)
|
|
287
|
-
}, [e(
|
|
277
|
+
}, [e("ElForm", {
|
|
288
278
|
ref: "form",
|
|
289
279
|
attrs: {
|
|
290
280
|
model: t.upload
|
|
291
281
|
}
|
|
292
|
-
}, [e(
|
|
282
|
+
}, [e("ElFormItem", {
|
|
293
283
|
attrs: {
|
|
294
284
|
prop: "src",
|
|
295
285
|
rules: [{
|
|
@@ -297,7 +287,7 @@ var w = function() {
|
|
|
297
287
|
message: "地址不能为空"
|
|
298
288
|
}]
|
|
299
289
|
}
|
|
300
|
-
}, [e(
|
|
290
|
+
}, [e("ElInput", {
|
|
301
291
|
staticStyle: {
|
|
302
292
|
"margin-bottom": "10px"
|
|
303
293
|
},
|
|
@@ -357,8 +347,8 @@ var w = function() {
|
|
|
357
347
|
controls: "controls"
|
|
358
348
|
}
|
|
359
349
|
}) : t._e()])], 1) : t._e()]);
|
|
360
|
-
},
|
|
361
|
-
const
|
|
350
|
+
}, f = [];
|
|
351
|
+
const m = {
|
|
362
352
|
name: "Chat",
|
|
363
353
|
props: {
|
|
364
354
|
beforeOpen: Function,
|
|
@@ -437,12 +427,12 @@ const S = {
|
|
|
437
427
|
},
|
|
438
428
|
heightStyleName() {
|
|
439
429
|
return {
|
|
440
|
-
height:
|
|
430
|
+
height: l(this.height)
|
|
441
431
|
};
|
|
442
432
|
},
|
|
443
433
|
widthStyleName() {
|
|
444
434
|
return {
|
|
445
|
-
width:
|
|
435
|
+
width: l(this.width)
|
|
446
436
|
};
|
|
447
437
|
},
|
|
448
438
|
msgActive() {
|
|
@@ -473,32 +463,32 @@ const S = {
|
|
|
473
463
|
getNotification(t) {
|
|
474
464
|
const o = this, e = Notification || window.Notification;
|
|
475
465
|
if (e) {
|
|
476
|
-
let
|
|
477
|
-
e.requestPermission(function(
|
|
478
|
-
|
|
466
|
+
let a = function() {
|
|
467
|
+
e.requestPermission(function(n) {
|
|
468
|
+
n === "granted" ? s() : console.log("用户无情残忍的拒绝了你!!!");
|
|
479
469
|
});
|
|
480
470
|
}, s = function() {
|
|
481
|
-
const
|
|
471
|
+
const n = new Notification(o.config.name, {
|
|
482
472
|
body: t,
|
|
483
473
|
icon: o.config.img
|
|
484
474
|
});
|
|
485
|
-
|
|
475
|
+
n.onshow = function() {
|
|
486
476
|
o.getAudio(), setTimeout(() => {
|
|
487
|
-
|
|
477
|
+
n.close();
|
|
488
478
|
}, 2500);
|
|
489
|
-
},
|
|
490
|
-
|
|
479
|
+
}, n.onclick = function() {
|
|
480
|
+
n.close();
|
|
491
481
|
};
|
|
492
482
|
};
|
|
493
483
|
const i = e.permission;
|
|
494
|
-
i === "granted" ? s() : i === "denied" ? console.log("用户拒绝了你!!!") :
|
|
484
|
+
i === "granted" ? s() : i === "denied" ? console.log("用户拒绝了你!!!") : a();
|
|
495
485
|
}
|
|
496
486
|
},
|
|
497
487
|
// mine为'我'的对话
|
|
498
488
|
// text为内容
|
|
499
489
|
pushMsg(t = {}) {
|
|
500
|
-
const o = t.mine === !0, e = t.text || {},
|
|
501
|
-
date: t.date ||
|
|
490
|
+
const o = t.mine === !0, e = t.text || {}, a = {
|
|
491
|
+
date: t.date || c(Date.now(), "YYYY-MM-DD HH:mm:ss"),
|
|
502
492
|
text: (() => typeof e != "object" ? {
|
|
503
493
|
text: e
|
|
504
494
|
} : e)(),
|
|
@@ -506,7 +496,7 @@ const S = {
|
|
|
506
496
|
img: o ? this.config.myImg : this.config.img,
|
|
507
497
|
name: o ? this.config.myName : this.config.name
|
|
508
498
|
};
|
|
509
|
-
this.list.push(
|
|
499
|
+
this.list.push(a), setTimeout(() => {
|
|
510
500
|
this.setScroll();
|
|
511
501
|
}, 50);
|
|
512
502
|
},
|
|
@@ -528,8 +518,8 @@ const S = {
|
|
|
528
518
|
const o = t;
|
|
529
519
|
return setTimeout(() => {
|
|
530
520
|
(this.$refs.content || []).forEach((i) => {
|
|
531
|
-
for (let
|
|
532
|
-
const s = i.children[
|
|
521
|
+
for (let a = 0; a < i.children.length; a++) {
|
|
522
|
+
const s = i.children[a];
|
|
533
523
|
s.getAttribute("data-flag") !== "0" && (s.setAttribute("data-flag", 0), s.onclick = () => {
|
|
534
524
|
this.handleEvent(s.dataset);
|
|
535
525
|
}, s.tagName === "IMG" ? (s.className = "web__msg--img", s.src = s.getAttribute("data-src")) : s.tagName === "VIDEO" ? (s.className = "web__msg--video", s.src = s.getAttribute("data-src")) : s.tagName === "AUDIO" ? (s.className = "web__msg--audio", s.controls = "controls", s.src = s.getAttribute("data-src")) : s.tagName === "FILE" ? (s.className = "web__msg--file", s.innerHTML = `<h2>File</h2><span>${s.getAttribute("data-name")}</span>`) : s.tagName === "MAP" && (s.className = "web__msg--file web__msg--map", s.innerHTML = `<h2>Map</h2><span>${s.getAttribute("data-longitude")} , ${s.getAttribute(
|
|
@@ -540,7 +530,7 @@ const S = {
|
|
|
540
530
|
}, 0), o;
|
|
541
531
|
},
|
|
542
532
|
getDetail(t = {}) {
|
|
543
|
-
const { type: o, src: e, name: i, longitude:
|
|
533
|
+
const { type: o, src: e, name: i, longitude: a, latitude: s, address: n } = t;
|
|
544
534
|
if (o === "img")
|
|
545
535
|
return `<img data-type="IMG" data-src="${e}" alt=""/>`;
|
|
546
536
|
if (o === "video")
|
|
@@ -550,7 +540,7 @@ const S = {
|
|
|
550
540
|
if (o === "file")
|
|
551
541
|
return `<file data-type="FILE" data-name="${i}" data-src="${e}"></file>`;
|
|
552
542
|
if (o === "map")
|
|
553
|
-
return `<map data-type="MAP" data-src="${e}" data-address="${
|
|
543
|
+
return `<map data-type="MAP" data-src="${e}" data-address="${n} " data-latitude="${s}" data-longitude="${a}"></map>`;
|
|
554
544
|
},
|
|
555
545
|
// 处理事件
|
|
556
546
|
handleEvent(t) {
|
|
@@ -565,24 +555,24 @@ const S = {
|
|
|
565
555
|
}), this.notice && this.getNotification(t.text || t);
|
|
566
556
|
}
|
|
567
557
|
}
|
|
568
|
-
},
|
|
569
|
-
var
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
558
|
+
}, r = {};
|
|
559
|
+
var p = /* @__PURE__ */ d(
|
|
560
|
+
m,
|
|
561
|
+
u,
|
|
562
|
+
f,
|
|
573
563
|
!1,
|
|
574
|
-
|
|
564
|
+
h,
|
|
575
565
|
null,
|
|
576
566
|
null,
|
|
577
567
|
null
|
|
578
568
|
);
|
|
579
|
-
function
|
|
580
|
-
for (let o in
|
|
581
|
-
this[o] =
|
|
569
|
+
function h(t) {
|
|
570
|
+
for (let o in r)
|
|
571
|
+
this[o] = r[o];
|
|
582
572
|
}
|
|
583
|
-
const
|
|
584
|
-
return
|
|
573
|
+
const b = /* @__PURE__ */ function() {
|
|
574
|
+
return p.exports;
|
|
585
575
|
}();
|
|
586
576
|
export {
|
|
587
|
-
|
|
577
|
+
b as default
|
|
588
578
|
};
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
import { isBlank as h } from "@web-utils/core";
|
|
2
|
+
import { formatDate as i } from "@web-utils/integrations/dayjs";
|
|
3
|
+
import { p as g, M as b, A as v, b as c, q as A, e as S, k as d, t as T, h as x, v as C, u as j } from "./util.ae730cde.mjs";
|
|
4
|
+
import "@web-utils/component/fy-u-editor/style.css";
|
|
5
|
+
import { a as D, b as O } from "./dataformat.f995e2f9.mjs";
|
|
6
|
+
import { s as L } from "./slot.4b391395.mjs";
|
|
7
|
+
import { n as Y } from "./vueComponentNormalizer.446f5dc4.mjs";
|
|
8
|
+
const U = (e = {}, r = {}, o = {}, n = []) => {
|
|
9
|
+
let t = e[r.prop];
|
|
10
|
+
const a = r.type, s = r.separator;
|
|
11
|
+
if (r.bind && (t = g(e, r.bind)), h(t))
|
|
12
|
+
t = "";
|
|
13
|
+
else {
|
|
14
|
+
const y = b.includes(r.type) && r.multiple, _ = v.includes(r.type);
|
|
15
|
+
if ((["string", "number"].includes(r.dataType) || y || _) && !Array.isArray(t) && (t = `${t}`.split(s || c), r.dataType === "number" && (t = A(t))), S.includes(a))
|
|
16
|
+
Array.isArray(t) ? t = t.join(s || d) : t = t.split(s || c).join(s || d);
|
|
17
|
+
else if (a === "password")
|
|
18
|
+
t = T(t, "*");
|
|
19
|
+
else if (x.includes(a) && r.format) {
|
|
20
|
+
const u = r.format.replace("dd", "DD").replace("yyyy", "YYYY"), m = i(Date.now(), "YYYY-MM-DD");
|
|
21
|
+
if (a.indexOf("range") !== -1) {
|
|
22
|
+
let l = t[0] || "", p = t[1] || "";
|
|
23
|
+
a === "timerange" && l.length <= 8 && p.length < 8 && (l = `${m} ${l}`, p = `${m} ${p}`), t = [i(l, u), i(p, u)].join(r.separator || "~");
|
|
24
|
+
} else
|
|
25
|
+
a === "time" && t.length <= 8 && (t = `${m} ${t}`), t = i(t, u);
|
|
26
|
+
}
|
|
27
|
+
t = C(n, t, r.props || o.props);
|
|
28
|
+
}
|
|
29
|
+
return r.formatter && typeof r.formatter == "function" && (t = r.formatter(e, e[r.prop], t, r)), t;
|
|
30
|
+
};
|
|
31
|
+
var k = function() {
|
|
32
|
+
var e = this, r = e.$createElement, o = e._self._c || r;
|
|
33
|
+
return o(e.getComponent(e.column.type, e.column.component), e._g(e._b({
|
|
34
|
+
ref: "temp",
|
|
35
|
+
tag: "Component",
|
|
36
|
+
attrs: {
|
|
37
|
+
column: Object.assign(e.column, e.params),
|
|
38
|
+
dic: e.dic,
|
|
39
|
+
disabled: e.column.disabled || e.disabled,
|
|
40
|
+
readonly: e.column.readonly || e.readonly,
|
|
41
|
+
placeholder: e.getPlaceholder(e.column),
|
|
42
|
+
props: e.column.props || e.props,
|
|
43
|
+
"props-http": e.column.propsHttp || e.propsHttp,
|
|
44
|
+
size: e.column.size || e.size,
|
|
45
|
+
"table-data": e.tableData,
|
|
46
|
+
type: e.type || e.column.type,
|
|
47
|
+
"column-slot": e.columnSlot
|
|
48
|
+
},
|
|
49
|
+
nativeOn: {
|
|
50
|
+
keyup: function(n) {
|
|
51
|
+
return !n.type.indexOf("key") && e._k(n.keyCode, "enter", 13, n.key, "Enter") ? null : e.enterChange.apply(null, arguments);
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
scopedSlots: e._u([e._l(e.columnSlot, function(n) {
|
|
55
|
+
return {
|
|
56
|
+
key: n,
|
|
57
|
+
fn: function(t) {
|
|
58
|
+
return [e._t(n, null, null, t)];
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
})], null, !0),
|
|
62
|
+
model: {
|
|
63
|
+
value: e.text,
|
|
64
|
+
callback: function(n) {
|
|
65
|
+
e.text = n;
|
|
66
|
+
},
|
|
67
|
+
expression: "text"
|
|
68
|
+
}
|
|
69
|
+
}, "Component", Object.assign(e.column, e.uploadFun(e.column)), !1), e.event), [e.params.html ? o("span", {
|
|
70
|
+
domProps: {
|
|
71
|
+
innerHTML: e._s(e.params.html)
|
|
72
|
+
}
|
|
73
|
+
}) : e._e()]);
|
|
74
|
+
}, F = [];
|
|
75
|
+
const I = {
|
|
76
|
+
name: "FormTemp",
|
|
77
|
+
components: { FyUEditor: () => import("@web-utils/component/fy-u-editor") },
|
|
78
|
+
mixins: [L],
|
|
79
|
+
props: {
|
|
80
|
+
value: [String, Object, Number, Boolean, Array],
|
|
81
|
+
columnSlot: {
|
|
82
|
+
type: Array,
|
|
83
|
+
default: () => []
|
|
84
|
+
},
|
|
85
|
+
tableData: {
|
|
86
|
+
type: Object,
|
|
87
|
+
default: () => ({})
|
|
88
|
+
},
|
|
89
|
+
enter: {
|
|
90
|
+
type: Boolean,
|
|
91
|
+
default: !1
|
|
92
|
+
},
|
|
93
|
+
type: {
|
|
94
|
+
type: String
|
|
95
|
+
},
|
|
96
|
+
propsHttp: {
|
|
97
|
+
type: Object,
|
|
98
|
+
default: () => ({})
|
|
99
|
+
},
|
|
100
|
+
props: {
|
|
101
|
+
type: Object
|
|
102
|
+
},
|
|
103
|
+
dic: {
|
|
104
|
+
type: Array
|
|
105
|
+
},
|
|
106
|
+
size: {
|
|
107
|
+
type: String
|
|
108
|
+
},
|
|
109
|
+
disabled: {
|
|
110
|
+
type: Boolean
|
|
111
|
+
},
|
|
112
|
+
readonly: {
|
|
113
|
+
type: Boolean
|
|
114
|
+
},
|
|
115
|
+
column: {
|
|
116
|
+
type: Object,
|
|
117
|
+
default: () => ({})
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
computed: {
|
|
121
|
+
params() {
|
|
122
|
+
return this.column.params || {};
|
|
123
|
+
},
|
|
124
|
+
event() {
|
|
125
|
+
return this.column.event || {};
|
|
126
|
+
},
|
|
127
|
+
text: {
|
|
128
|
+
get() {
|
|
129
|
+
return this.value;
|
|
130
|
+
},
|
|
131
|
+
set(e) {
|
|
132
|
+
this.$emit("input", e), this.$emit("change", e);
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
methods: {
|
|
137
|
+
uploadFun: j,
|
|
138
|
+
getComponent: D,
|
|
139
|
+
getPlaceholder: O,
|
|
140
|
+
enterChange() {
|
|
141
|
+
typeof this.column.enter == "function" ? this.column.enter({ value: this.text, column: this.column }) : this.enter && this.$emit("enter");
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
}, f = {};
|
|
145
|
+
var $ = /* @__PURE__ */ Y(
|
|
146
|
+
I,
|
|
147
|
+
k,
|
|
148
|
+
F,
|
|
149
|
+
!1,
|
|
150
|
+
P,
|
|
151
|
+
null,
|
|
152
|
+
null,
|
|
153
|
+
null
|
|
154
|
+
);
|
|
155
|
+
function P(e) {
|
|
156
|
+
for (let r in f)
|
|
157
|
+
this[r] = f[r];
|
|
158
|
+
}
|
|
159
|
+
const N = /* @__PURE__ */ function() {
|
|
160
|
+
return $.exports;
|
|
161
|
+
}();
|
|
162
|
+
export {
|
|
163
|
+
N as F,
|
|
164
|
+
U as d
|
|
165
|
+
};
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
var M = Object.defineProperty, C = Object.defineProperties;
|
|
2
|
+
var D = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var x = Object.getOwnPropertySymbols;
|
|
4
|
+
var F = Object.prototype.hasOwnProperty, I = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var b = (e, t, a) => t in e ? M(e, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : e[t] = a, T = (e, t) => {
|
|
6
|
+
for (var a in t || (t = {}))
|
|
7
|
+
F.call(t, a) && b(e, a, t[a]);
|
|
8
|
+
if (x)
|
|
9
|
+
for (var a of x(t))
|
|
10
|
+
I.call(t, a) && b(e, a, t[a]);
|
|
11
|
+
return e;
|
|
12
|
+
}, S = (e, t) => C(e, D(t));
|
|
13
|
+
var w = (e, t, a) => new Promise((o, n) => {
|
|
14
|
+
var r = (i) => {
|
|
15
|
+
try {
|
|
16
|
+
f(a.next(i));
|
|
17
|
+
} catch (l) {
|
|
18
|
+
n(l);
|
|
19
|
+
}
|
|
20
|
+
}, c = (i) => {
|
|
21
|
+
try {
|
|
22
|
+
f(a.throw(i));
|
|
23
|
+
} catch (l) {
|
|
24
|
+
n(l);
|
|
25
|
+
}
|
|
26
|
+
}, f = (i) => i.done ? o(i.value) : Promise.resolve(i.value).then(r, c);
|
|
27
|
+
f((a = a.apply(e, t)).next());
|
|
28
|
+
});
|
|
29
|
+
import v from "element-ui/lib/loading";
|
|
30
|
+
import B from "element-ui/lib/message-box";
|
|
31
|
+
import { isFunction as g } from "@web-utils/core";
|
|
32
|
+
function L(e, t, a) {
|
|
33
|
+
return w(this, null, function* () {
|
|
34
|
+
const { stop: o, prevent: n, message: r, loadable: c, loadingText: f, confirmable: i, confirmType: l, confirmText: k, confirmTitle: h } = t;
|
|
35
|
+
o && e.stopPropagation(), n && e.preventDefault();
|
|
36
|
+
const { before: p, click: s, cancel: d, after: m } = a;
|
|
37
|
+
if (g(s))
|
|
38
|
+
try {
|
|
39
|
+
let u = !0;
|
|
40
|
+
if (g(p) && (u = yield p(e)), u === !1)
|
|
41
|
+
return;
|
|
42
|
+
i && (yield (B.confirm || B.default.confirm)(r || k, {
|
|
43
|
+
type: l,
|
|
44
|
+
title: h
|
|
45
|
+
}));
|
|
46
|
+
let y;
|
|
47
|
+
c && (y = (v.service || v.default.service)({
|
|
48
|
+
background: "rgba(0,0,0,0.3)",
|
|
49
|
+
text: f
|
|
50
|
+
}));
|
|
51
|
+
try {
|
|
52
|
+
yield s(e);
|
|
53
|
+
} catch (P) {
|
|
54
|
+
}
|
|
55
|
+
c && y.close(), g(m) && (yield m(e));
|
|
56
|
+
} catch (u) {
|
|
57
|
+
g(d) && (yield d(u));
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
const E = {
|
|
62
|
+
functional: !0,
|
|
63
|
+
props: {
|
|
64
|
+
stop: {
|
|
65
|
+
type: Boolean,
|
|
66
|
+
default: !0
|
|
67
|
+
},
|
|
68
|
+
prevent: {
|
|
69
|
+
type: Boolean,
|
|
70
|
+
default: !0
|
|
71
|
+
},
|
|
72
|
+
text: {
|
|
73
|
+
type: String,
|
|
74
|
+
default: ""
|
|
75
|
+
},
|
|
76
|
+
message: {
|
|
77
|
+
type: String,
|
|
78
|
+
default: "你确定要删除该记录吗?"
|
|
79
|
+
},
|
|
80
|
+
confirmable: {
|
|
81
|
+
type: Boolean,
|
|
82
|
+
default: !0
|
|
83
|
+
},
|
|
84
|
+
confirmText: {
|
|
85
|
+
type: String,
|
|
86
|
+
default: "你确定要删除该记录吗?"
|
|
87
|
+
},
|
|
88
|
+
confirmType: {
|
|
89
|
+
type: String,
|
|
90
|
+
default: "warning"
|
|
91
|
+
},
|
|
92
|
+
confirmTitle: String,
|
|
93
|
+
loadable: Boolean,
|
|
94
|
+
loadingText: {
|
|
95
|
+
type: String,
|
|
96
|
+
default: "正在处理中请稍候..."
|
|
97
|
+
},
|
|
98
|
+
tag: {
|
|
99
|
+
type: String,
|
|
100
|
+
default: "i"
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
render(e, { props: t, data: a, children: o, listeners: n }) {
|
|
104
|
+
return e(
|
|
105
|
+
t.tag,
|
|
106
|
+
S(T({}, a), {
|
|
107
|
+
on: { click: (r) => L(r, t, n) },
|
|
108
|
+
props: t
|
|
109
|
+
}),
|
|
110
|
+
o || t.text
|
|
111
|
+
);
|
|
112
|
+
}
|
|
113
|
+
};
|
|
114
|
+
export {
|
|
115
|
+
E as c
|
|
116
|
+
};
|
|
@@ -147,10 +147,10 @@ const v = (e, n = 12, t = !1) => {
|
|
|
147
147
|
return l(n) ? L.includes(e.type) ? `${u("tip.select")} ${t}` : `${u("tip.input")} ${t}` : n;
|
|
148
148
|
};
|
|
149
149
|
export {
|
|
150
|
-
|
|
151
|
-
|
|
150
|
+
N as a,
|
|
151
|
+
O as b,
|
|
152
152
|
R as c,
|
|
153
|
-
|
|
153
|
+
v as d,
|
|
154
154
|
M as f,
|
|
155
155
|
$ as g,
|
|
156
156
|
C as i,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { D as r, a as i, b as a } from "./util.ae730cde.mjs";
|
|
2
2
|
import { s as l } from "./slot.4b391395.mjs";
|
|
3
3
|
import { isBlank as s } from "@web-utils/core";
|
|
4
|
-
import { i as p } from "./dataformat.
|
|
4
|
+
import { i as p } from "./dataformat.f995e2f9.mjs";
|
|
5
5
|
const f = {
|
|
6
6
|
mixins: [l],
|
|
7
7
|
data() {
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
var m = Object.defineProperty;
|
|
2
2
|
var l = Object.getOwnPropertySymbols;
|
|
3
3
|
var f = Object.prototype.hasOwnProperty, c = Object.prototype.propertyIsEnumerable;
|
|
4
|
-
var i = (e,
|
|
5
|
-
for (var
|
|
6
|
-
f.call(
|
|
4
|
+
var i = (e, r, t) => r in e ? m(e, r, { enumerable: !0, configurable: !0, writable: !0, value: t }) : e[r] = t, s = (e, r) => {
|
|
5
|
+
for (var t in r || (r = {}))
|
|
6
|
+
f.call(r, t) && i(e, t, r[t]);
|
|
7
7
|
if (l)
|
|
8
|
-
for (var
|
|
9
|
-
c.call(
|
|
8
|
+
for (var t of l(r))
|
|
9
|
+
c.call(r, t) && i(e, t, r[t]);
|
|
10
10
|
return e;
|
|
11
11
|
};
|
|
12
12
|
import { d as o } from "./index.57f871af.mjs";
|
|
13
|
-
import
|
|
13
|
+
import a from "element-ui/lib/col";
|
|
14
14
|
import u from "element-ui/lib/form-item";
|
|
15
|
-
const d = ["span"],
|
|
15
|
+
const d = ["span"], n = [...Object.keys(a.props || a.default.props)], h = n.filter((e) => !d.includes(e)), b = ["label", "prop", "rules", "labelWidth", "required"], p = [...Object.keys(u.props || u.default.props)], g = p.filter((e) => !b.includes(e)), y = [
|
|
16
16
|
"wrapCol",
|
|
17
17
|
"wrapFormItem",
|
|
18
18
|
"unwrap",
|
|
@@ -21,7 +21,7 @@ const d = ["span"], a = [...Object.keys(n.props || n.default.props)], h = a.filt
|
|
|
21
21
|
"placeholder",
|
|
22
22
|
"prefixPick",
|
|
23
23
|
"half",
|
|
24
|
-
...
|
|
24
|
+
...n,
|
|
25
25
|
...p
|
|
26
26
|
], C = {
|
|
27
27
|
inject: {
|
|
@@ -99,8 +99,8 @@ const d = ["span"], a = [...Object.keys(n.props || n.default.props)], h = a.filt
|
|
|
99
99
|
computeRules() {
|
|
100
100
|
const e = [...this.rules || []];
|
|
101
101
|
if (this.required) {
|
|
102
|
-
const
|
|
103
|
-
|
|
102
|
+
const r = e.find((t) => t.required);
|
|
103
|
+
r ? r.ref ? r.label = r.label || this.label : r.message = e.message || this.message : e.unshift(this.getRequireRule());
|
|
104
104
|
}
|
|
105
105
|
return e.concat(this.getRules());
|
|
106
106
|
},
|
|
@@ -111,7 +111,7 @@ const d = ["span"], a = [...Object.keys(n.props || n.default.props)], h = a.filt
|
|
|
111
111
|
return o(s(s({}, this.$props), this.$attrs), y);
|
|
112
112
|
},
|
|
113
113
|
elFormItemProps() {
|
|
114
|
-
return o(s(s({}, this.$props), this.$attrs),
|
|
114
|
+
return o(s(s({}, this.$props), this.$attrs), g);
|
|
115
115
|
},
|
|
116
116
|
elColProps() {
|
|
117
117
|
return o(s(s({}, this.$props), this.$attrs), h);
|
|
@@ -119,8 +119,8 @@ const d = ["span"], a = [...Object.keys(n.props || n.default.props)], h = a.filt
|
|
|
119
119
|
},
|
|
120
120
|
watch: {
|
|
121
121
|
computeRules() {
|
|
122
|
-
var e,
|
|
123
|
-
(
|
|
122
|
+
var e, r;
|
|
123
|
+
(r = (e = this.elForm) == null ? void 0 : e.clearValidate) == null || r.call(e, this.prop);
|
|
124
124
|
}
|
|
125
125
|
},
|
|
126
126
|
methods: {
|