@yoooloo42/joker 1.0.85 → 1.0.86
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/index.cjs.js +76 -76
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +76 -76
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -40914,9 +40914,9 @@ const props = __props;
|
|
|
40914
40914
|
const emit = __emit;
|
|
40915
40915
|
|
|
40916
40916
|
const myProps_box = reactive(Object.assign({}, ly0default, props.myProps));
|
|
40917
|
-
const fileList_box =
|
|
40917
|
+
const fileList_box = ref([]);
|
|
40918
40918
|
props.modelValue.forEach((item, index) => {
|
|
40919
|
-
fileList_box.push({
|
|
40919
|
+
fileList_box.value.push({
|
|
40920
40920
|
name: item.substring(item.lastIndexOf('/') + 1) ?? 'Old_' + index,
|
|
40921
40921
|
url: item,
|
|
40922
40922
|
response: {
|
|
@@ -40947,9 +40947,9 @@ const hdl = {
|
|
|
40947
40947
|
},
|
|
40948
40948
|
remove (file, fileList) { // 文件列表移除文件时的钩子
|
|
40949
40949
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
40950
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
40950
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
40951
40951
|
const arr = [];
|
|
40952
|
-
fileList_box.forEach(i=>{
|
|
40952
|
+
fileList_box.value.forEach(i=>{
|
|
40953
40953
|
arr.push(i.response.data.src);
|
|
40954
40954
|
});
|
|
40955
40955
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -40957,10 +40957,10 @@ const hdl = {
|
|
|
40957
40957
|
},
|
|
40958
40958
|
success (response, file, fileList) { // 上传成功
|
|
40959
40959
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
40960
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
40960
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
40961
40961
|
if (response.code === 0) {
|
|
40962
40962
|
const arr = [];
|
|
40963
|
-
fileList_box.forEach(i=>{
|
|
40963
|
+
fileList_box.value.forEach(i=>{
|
|
40964
40964
|
arr.push(i.response.data.src);
|
|
40965
40965
|
});
|
|
40966
40966
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -40973,7 +40973,7 @@ const hdl = {
|
|
|
40973
40973
|
},
|
|
40974
40974
|
deleteAll () { // 删除全部已上传文件
|
|
40975
40975
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
40976
|
-
fileList_box.splice(0, fileList_box.length);
|
|
40976
|
+
fileList_box.value.splice(0, fileList_box.value.length);
|
|
40977
40977
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
40978
40978
|
emit("update:modelValue", []);
|
|
40979
40979
|
}
|
|
@@ -40986,8 +40986,8 @@ return (_ctx, _cache) => {
|
|
|
40986
40986
|
return (openBlock(), createElementBlock("div", null, [
|
|
40987
40987
|
createVNode(_component_el_upload, {
|
|
40988
40988
|
action: myProps_box.uploadUrl,
|
|
40989
|
-
"file-list": fileList_box,
|
|
40990
|
-
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box) = $event)),
|
|
40989
|
+
"file-list": fileList_box.value,
|
|
40990
|
+
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box).value = $event)),
|
|
40991
40991
|
"list-type": "text",
|
|
40992
40992
|
"before-upload": hdl.beforeUpload,
|
|
40993
40993
|
"on-preview": hdl.preview,
|
|
@@ -41011,10 +41011,10 @@ return (_ctx, _cache) => {
|
|
|
41011
41011
|
]),
|
|
41012
41012
|
_: 1 /* STABLE */
|
|
41013
41013
|
}, 8 /* PROPS */, ["action", "file-list", "before-upload", "on-preview", "on-remove", "on-success", "limit"]),
|
|
41014
|
-
(fileList_box.length>0)
|
|
41015
|
-
? (openBlock(), createElementBlock("div", _hoisted_2$b, toDisplayString("已上传"+fileList_box.length+"个文件"), 1 /* TEXT */))
|
|
41014
|
+
(fileList_box.value.length>0)
|
|
41015
|
+
? (openBlock(), createElementBlock("div", _hoisted_2$b, toDisplayString("已上传"+fileList_box.value.length+"个文件"), 1 /* TEXT */))
|
|
41016
41016
|
: createCommentVNode("v-if", true),
|
|
41017
|
-
(fileList_box.length>0)
|
|
41017
|
+
(fileList_box.value.length>0)
|
|
41018
41018
|
? (openBlock(), createBlock(_component_el_button, {
|
|
41019
41019
|
key: 1,
|
|
41020
41020
|
size: "small",
|
|
@@ -41061,9 +41061,9 @@ const props = __props;
|
|
|
41061
41061
|
const emit = __emit;
|
|
41062
41062
|
|
|
41063
41063
|
const myProps_box = reactive(Object.assign({}, ly0default, props.myProps));
|
|
41064
|
-
const fileList_box =
|
|
41064
|
+
const fileList_box = ref([]);
|
|
41065
41065
|
props.modelValue.forEach((item, index) => {
|
|
41066
|
-
fileList_box.push({
|
|
41066
|
+
fileList_box.value.push({
|
|
41067
41067
|
name: item.substring(item.lastIndexOf('/') + 1) ?? 'Old_' + index,
|
|
41068
41068
|
url: item,
|
|
41069
41069
|
response: {
|
|
@@ -41119,17 +41119,17 @@ const hdl = {
|
|
|
41119
41119
|
remove (file, fileList) { // 文件列表移除文件时的钩子
|
|
41120
41120
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41121
41121
|
// 因为只能上传一个图片,移除即清空
|
|
41122
|
-
fileList_box.splice(0, fileList_box.length);
|
|
41122
|
+
fileList_box.value.splice(0, fileList_box.value.length);
|
|
41123
41123
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
41124
41124
|
emit("update:modelValue", []);
|
|
41125
41125
|
},
|
|
41126
41126
|
success (response, file, fileList) { // 上传
|
|
41127
41127
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41128
41128
|
// 只能上传一个图片
|
|
41129
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41129
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41130
41130
|
if (response.code === 0) {
|
|
41131
41131
|
const arr = [];
|
|
41132
|
-
fileList_box.forEach(i=>{
|
|
41132
|
+
fileList_box.value.forEach(i=>{
|
|
41133
41133
|
arr.push(i.response.data.src);
|
|
41134
41134
|
});
|
|
41135
41135
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -41142,7 +41142,7 @@ const hdl = {
|
|
|
41142
41142
|
},
|
|
41143
41143
|
deleteAll () { // 删除全部已上传文件
|
|
41144
41144
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41145
|
-
fileList_box.splice(0, fileList_box.length);
|
|
41145
|
+
fileList_box.value.splice(0, fileList_box.value.length);
|
|
41146
41146
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
41147
41147
|
emit("update:modelValue", []);
|
|
41148
41148
|
}
|
|
@@ -41159,8 +41159,8 @@ return (_ctx, _cache) => {
|
|
|
41159
41159
|
class: "avatar",
|
|
41160
41160
|
style: normalizeStyle(style.avatarBox),
|
|
41161
41161
|
action: myProps_box.uploadUrl,
|
|
41162
|
-
"file-list": fileList_box,
|
|
41163
|
-
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box) = $event)),
|
|
41162
|
+
"file-list": fileList_box.value,
|
|
41163
|
+
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box).value = $event)),
|
|
41164
41164
|
"show-file-list": false,
|
|
41165
41165
|
"before-upload": hdl.beforeUpload,
|
|
41166
41166
|
"on-preview": hdl.preview,
|
|
@@ -41169,10 +41169,10 @@ return (_ctx, _cache) => {
|
|
|
41169
41169
|
limit: 1
|
|
41170
41170
|
}, {
|
|
41171
41171
|
default: withCtx(() => [
|
|
41172
|
-
(fileList_box.length>0 && fileList_box[0].response && fileList_box[0].response.data && fileList_box[0].response.data.src)
|
|
41172
|
+
(fileList_box.value.length>0 && fileList_box.value[0].response && fileList_box.value[0].response.data && fileList_box.value[0].response.data.src)
|
|
41173
41173
|
? (openBlock(), createElementBlock("img", {
|
|
41174
41174
|
key: 0,
|
|
41175
|
-
src: fileList_box[0].response.data.src,
|
|
41175
|
+
src: fileList_box.value[0].response.data.src,
|
|
41176
41176
|
class: "avatar",
|
|
41177
41177
|
style: normalizeStyle(style.avatarImage)
|
|
41178
41178
|
}, null, 12 /* STYLE, PROPS */, _hoisted_1$a))
|
|
@@ -41189,7 +41189,7 @@ return (_ctx, _cache) => {
|
|
|
41189
41189
|
]),
|
|
41190
41190
|
_: 1 /* STABLE */
|
|
41191
41191
|
}, 8 /* PROPS */, ["style", "action", "file-list", "before-upload", "on-preview", "on-remove", "on-success"]),
|
|
41192
|
-
(fileList_box.length>0 && fileList_box[0].response && fileList_box[0].response.data && fileList_box[0].response.data.src)
|
|
41192
|
+
(fileList_box.value.length>0 && fileList_box.value[0].response && fileList_box.value[0].response.data && fileList_box.value[0].response.data.src)
|
|
41193
41193
|
? (openBlock(), createElementBlock("div", _hoisted_2$a, [
|
|
41194
41194
|
createVNode(_component_el_button, {
|
|
41195
41195
|
size: "small",
|
|
@@ -41248,9 +41248,9 @@ const myProps_box = reactive(Object.assign({}, ly0default, {
|
|
|
41248
41248
|
}
|
|
41249
41249
|
}, props.myProps));
|
|
41250
41250
|
|
|
41251
|
-
const fileList_box =
|
|
41251
|
+
const fileList_box = ref([]);
|
|
41252
41252
|
props.modelValue.forEach((item, index) => {
|
|
41253
|
-
fileList_box.push({
|
|
41253
|
+
fileList_box.value.push({
|
|
41254
41254
|
name: item.src.substring(item.lastIndexOf('/') + 1) ?? 'Old_' + index,
|
|
41255
41255
|
url: item.src,
|
|
41256
41256
|
response: {
|
|
@@ -41309,7 +41309,7 @@ const hdl = {
|
|
|
41309
41309
|
remove (file, fileList) { // 文件列表移除文件时的钩子
|
|
41310
41310
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41311
41311
|
// 因为只能上传一个图片,移除即清空
|
|
41312
|
-
fileList_box.splice(0, fileList_box.length);
|
|
41312
|
+
fileList_box.value.splice(0, fileList_box.value.length);
|
|
41313
41313
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
41314
41314
|
emit("update:modelValue", []);
|
|
41315
41315
|
}};
|
|
@@ -41325,8 +41325,8 @@ return (_ctx, _cache) => {
|
|
|
41325
41325
|
class: "avatar",
|
|
41326
41326
|
style: normalizeStyle(style.avatarBox),
|
|
41327
41327
|
action: myProps_box.uploadUrl,
|
|
41328
|
-
"file-list": fileList_box,
|
|
41329
|
-
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box) = $event)),
|
|
41328
|
+
"file-list": fileList_box.value,
|
|
41329
|
+
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box).value = $event)),
|
|
41330
41330
|
"show-file-list": false,
|
|
41331
41331
|
"before-upload": hdl.beforeUpload,
|
|
41332
41332
|
"on-preview": hdl.preview,
|
|
@@ -41335,15 +41335,15 @@ return (_ctx, _cache) => {
|
|
|
41335
41335
|
}, {
|
|
41336
41336
|
default: withCtx(() => [
|
|
41337
41337
|
(
|
|
41338
|
-
fileList_box.length>0 &&
|
|
41339
|
-
fileList_box[0].response &&
|
|
41340
|
-
fileList_box[0].response.data &&
|
|
41341
|
-
fileList_box[0].response.data.src
|
|
41338
|
+
fileList_box.value.length>0 &&
|
|
41339
|
+
fileList_box.value[0].response &&
|
|
41340
|
+
fileList_box.value[0].response.data &&
|
|
41341
|
+
fileList_box.value[0].response.data.src
|
|
41342
41342
|
)
|
|
41343
41343
|
? (openBlock(), createElementBlock("img", {
|
|
41344
41344
|
key: 0,
|
|
41345
41345
|
class: "avatar",
|
|
41346
|
-
src:
|
|
41346
|
+
src: fileList_box.value[0].response.data.src,
|
|
41347
41347
|
style: normalizeStyle(style.avatarImage())
|
|
41348
41348
|
}, null, 12 /* STYLE, PROPS */, _hoisted_1$9))
|
|
41349
41349
|
: (openBlock(), createBlock(_component_el_icon, {
|
|
@@ -41360,22 +41360,22 @@ return (_ctx, _cache) => {
|
|
|
41360
41360
|
_: 1 /* STABLE */
|
|
41361
41361
|
}, 8 /* PROPS */, ["style", "action", "file-list", "before-upload", "on-preview", "on-remove", "on-success"]),
|
|
41362
41362
|
(
|
|
41363
|
-
fileList_box.length>0 &&
|
|
41364
|
-
fileList_box[0].response &&
|
|
41365
|
-
fileList_box[0].response.data &&
|
|
41366
|
-
fileList_box[0].response.data.result &&
|
|
41367
|
-
fileList_box[0].response.data.result.txt
|
|
41363
|
+
fileList_box.value.length>0 &&
|
|
41364
|
+
fileList_box.value[0].response &&
|
|
41365
|
+
fileList_box.value[0].response.data &&
|
|
41366
|
+
fileList_box.value[0].response.data.result &&
|
|
41367
|
+
fileList_box.value[0].response.data.result.txt
|
|
41368
41368
|
)
|
|
41369
41369
|
? (openBlock(), createElementBlock("div", _hoisted_2$9, [
|
|
41370
41370
|
_cache[1] || (_cache[1] = createElementVNode("span", null, "车牌识别结果:", -1 /* CACHED */)),
|
|
41371
|
-
createElementVNode("span", _hoisted_3$4, toDisplayString(fileList_box[0].response.data.result.txt), 1 /* TEXT */)
|
|
41371
|
+
createElementVNode("span", _hoisted_3$4, toDisplayString(fileList_box.value[0].response.data.result.txt), 1 /* TEXT */)
|
|
41372
41372
|
]))
|
|
41373
41373
|
: createCommentVNode("v-if", true),
|
|
41374
41374
|
(
|
|
41375
|
-
fileList_box.length>0 &&
|
|
41376
|
-
fileList_box[0].response &&
|
|
41377
|
-
fileList_box[0].response.data &&
|
|
41378
|
-
fileList_box[0].response.data.src
|
|
41375
|
+
fileList_box.value.length>0 &&
|
|
41376
|
+
fileList_box.value[0].response &&
|
|
41377
|
+
fileList_box.value[0].response.data &&
|
|
41378
|
+
fileList_box.value[0].response.data.src
|
|
41379
41379
|
)
|
|
41380
41380
|
? (openBlock(), createElementBlock("div", _hoisted_4$2, [
|
|
41381
41381
|
createVNode(_component_el_button, {
|
|
@@ -41429,9 +41429,9 @@ const props = __props;
|
|
|
41429
41429
|
const emit = __emit;
|
|
41430
41430
|
|
|
41431
41431
|
const myProps_box = reactive(Object.assign({}, ly0default, props.myProps));
|
|
41432
|
-
const fileList_box =
|
|
41432
|
+
const fileList_box = ref([]);
|
|
41433
41433
|
props.modelValue.forEach((item, index) => {
|
|
41434
|
-
fileList_box.push({
|
|
41434
|
+
fileList_box.value.push({
|
|
41435
41435
|
name: item.substring(item.lastIndexOf('/') + 1) ?? 'Old_' + index,
|
|
41436
41436
|
url: item,
|
|
41437
41437
|
response: {
|
|
@@ -41462,9 +41462,9 @@ const hdl = {
|
|
|
41462
41462
|
},
|
|
41463
41463
|
remove (file, fileList) { // 文件列表移除文件时的钩子
|
|
41464
41464
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41465
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41465
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41466
41466
|
const arr = [];
|
|
41467
|
-
fileList_box.forEach(i=>{
|
|
41467
|
+
fileList_box.value.forEach(i=>{
|
|
41468
41468
|
arr.push(i.response.data.src);
|
|
41469
41469
|
});
|
|
41470
41470
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -41472,10 +41472,10 @@ const hdl = {
|
|
|
41472
41472
|
},
|
|
41473
41473
|
success (response, file, fileList) { // 上传
|
|
41474
41474
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41475
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41475
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41476
41476
|
if (response.code === 0) {
|
|
41477
41477
|
const arr = [];
|
|
41478
|
-
fileList_box.forEach(i=>{
|
|
41478
|
+
fileList_box.value.forEach(i=>{
|
|
41479
41479
|
arr.push(i.response.data.src);
|
|
41480
41480
|
});
|
|
41481
41481
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -41488,7 +41488,7 @@ const hdl = {
|
|
|
41488
41488
|
},
|
|
41489
41489
|
deleteAll () { // 删除全部已上传文件
|
|
41490
41490
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41491
|
-
fileList_box.splice(0, fileList_box.length);
|
|
41491
|
+
fileList_box.value.splice(0, fileList_box.value.length);
|
|
41492
41492
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
41493
41493
|
emit("update:modelValue", []);
|
|
41494
41494
|
}
|
|
@@ -41503,8 +41503,8 @@ return (_ctx, _cache) => {
|
|
|
41503
41503
|
return (openBlock(), createElementBlock("div", null, [
|
|
41504
41504
|
createVNode(_component_el_upload, {
|
|
41505
41505
|
action: myProps_box.uploadUrl,
|
|
41506
|
-
"file-list": fileList_box,
|
|
41507
|
-
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box) = $event)),
|
|
41506
|
+
"file-list": fileList_box.value,
|
|
41507
|
+
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box).value = $event)),
|
|
41508
41508
|
"list-type": "text",
|
|
41509
41509
|
"before-upload": hdl.beforeUpload,
|
|
41510
41510
|
"on-preview": hdl.preview,
|
|
@@ -41530,10 +41530,10 @@ return (_ctx, _cache) => {
|
|
|
41530
41530
|
]),
|
|
41531
41531
|
_: 1 /* STABLE */
|
|
41532
41532
|
}, 8 /* PROPS */, ["action", "file-list", "before-upload", "on-preview", "on-remove", "on-success", "limit"]),
|
|
41533
|
-
(fileList_box.length>0)
|
|
41534
|
-
? (openBlock(), createElementBlock("div", _hoisted_2$8, toDisplayString("已上传"+fileList_box.length+"个文件"), 1 /* TEXT */))
|
|
41533
|
+
(fileList_box.value.length>0)
|
|
41534
|
+
? (openBlock(), createElementBlock("div", _hoisted_2$8, toDisplayString("已上传"+fileList_box.value.length+"个文件"), 1 /* TEXT */))
|
|
41535
41535
|
: createCommentVNode("v-if", true),
|
|
41536
|
-
(fileList_box.length>0)
|
|
41536
|
+
(fileList_box.value.length>0)
|
|
41537
41537
|
? (openBlock(), createBlock(_component_el_button, {
|
|
41538
41538
|
key: 1,
|
|
41539
41539
|
size: "small",
|
|
@@ -41583,9 +41583,9 @@ const props = __props;
|
|
|
41583
41583
|
const emit = __emit;
|
|
41584
41584
|
|
|
41585
41585
|
const myProps_box = reactive(Object.assign({}, ly0default, props.myProps));
|
|
41586
|
-
const fileList_box =
|
|
41586
|
+
const fileList_box = ref([]);
|
|
41587
41587
|
props.modelValue.forEach((item, index) => {
|
|
41588
|
-
fileList_box.push({
|
|
41588
|
+
fileList_box.value.push({
|
|
41589
41589
|
name: item.substring(item.lastIndexOf('/') + 1) ?? 'Old_' + index,
|
|
41590
41590
|
url: item,
|
|
41591
41591
|
response: {
|
|
@@ -41616,9 +41616,9 @@ const hdl = {
|
|
|
41616
41616
|
},
|
|
41617
41617
|
remove (file, fileList) { // 文件列表移除文件时的钩子
|
|
41618
41618
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41619
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41619
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41620
41620
|
const arr = [];
|
|
41621
|
-
fileList_box.forEach(i=>{
|
|
41621
|
+
fileList_box.value.forEach(i=>{
|
|
41622
41622
|
arr.push(i.response.data.src);
|
|
41623
41623
|
});
|
|
41624
41624
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -41626,10 +41626,10 @@ const hdl = {
|
|
|
41626
41626
|
},
|
|
41627
41627
|
success (response, file, fileList) { // 上传
|
|
41628
41628
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41629
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41629
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41630
41630
|
if (response.code === 0) {
|
|
41631
41631
|
const arr = [];
|
|
41632
|
-
fileList_box.forEach(i=>{
|
|
41632
|
+
fileList_box.value.forEach(i=>{
|
|
41633
41633
|
arr.push(i.response.data.src);
|
|
41634
41634
|
});
|
|
41635
41635
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -41642,7 +41642,7 @@ const hdl = {
|
|
|
41642
41642
|
},
|
|
41643
41643
|
deleteAll () { // 删除全部已上传图片
|
|
41644
41644
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41645
|
-
fileList_box.splice(0, fileList_box.length);
|
|
41645
|
+
fileList_box.value.splice(0, fileList_box.value.length);
|
|
41646
41646
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
41647
41647
|
emit("update:modelValue", []);
|
|
41648
41648
|
}
|
|
@@ -41655,8 +41655,8 @@ return (_ctx, _cache) => {
|
|
|
41655
41655
|
return (openBlock(), createElementBlock("div", null, [
|
|
41656
41656
|
createVNode(_component_el_upload, {
|
|
41657
41657
|
action: myProps_box.uploadUrl,
|
|
41658
|
-
"file-list": fileList_box,
|
|
41659
|
-
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box) = $event)),
|
|
41658
|
+
"file-list": fileList_box.value,
|
|
41659
|
+
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box).value = $event)),
|
|
41660
41660
|
"list-type": "picture",
|
|
41661
41661
|
"before-upload": hdl.beforeUpload,
|
|
41662
41662
|
"on-preview": hdl.preview,
|
|
@@ -41680,10 +41680,10 @@ return (_ctx, _cache) => {
|
|
|
41680
41680
|
]),
|
|
41681
41681
|
_: 1 /* STABLE */
|
|
41682
41682
|
}, 8 /* PROPS */, ["action", "file-list", "before-upload", "on-preview", "on-remove", "on-success", "limit"]),
|
|
41683
|
-
(fileList_box.length>0)
|
|
41684
|
-
? (openBlock(), createElementBlock("div", _hoisted_2$7, toDisplayString("已上传"+fileList_box.length+"个图片"), 1 /* TEXT */))
|
|
41683
|
+
(fileList_box.value.length>0)
|
|
41684
|
+
? (openBlock(), createElementBlock("div", _hoisted_2$7, toDisplayString("已上传"+fileList_box.value.length+"个图片"), 1 /* TEXT */))
|
|
41685
41685
|
: createCommentVNode("v-if", true),
|
|
41686
|
-
(fileList_box.length>0)
|
|
41686
|
+
(fileList_box.value.length>0)
|
|
41687
41687
|
? (openBlock(), createBlock(_component_el_button, {
|
|
41688
41688
|
key: 1,
|
|
41689
41689
|
size: "small",
|
|
@@ -41734,9 +41734,9 @@ const props = __props;
|
|
|
41734
41734
|
const emit = __emit;
|
|
41735
41735
|
|
|
41736
41736
|
const myProps_box = reactive(Object.assign({}, ly0default, props.myProps));
|
|
41737
|
-
const fileList_box =
|
|
41737
|
+
const fileList_box = ref([]);
|
|
41738
41738
|
props.modelValue.forEach((item, index) => {
|
|
41739
|
-
fileList_box.push({
|
|
41739
|
+
fileList_box.value.push({
|
|
41740
41740
|
name: item.substring(item.lastIndexOf('/') + 1) ?? 'Old_' + index,
|
|
41741
41741
|
url: item,
|
|
41742
41742
|
response: {
|
|
@@ -41772,9 +41772,9 @@ const hdl = {
|
|
|
41772
41772
|
},
|
|
41773
41773
|
remove (file, fileList) { // 文件列表移除文件时的钩子
|
|
41774
41774
|
// 重置文件列表, 注意:通过使用splice保持响应性
|
|
41775
|
-
fileList_box.splice(0, fileList_box.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41775
|
+
fileList_box.value.splice(0, fileList_box.value.length, ...JSON.parse(JSON.stringify(fileList)));
|
|
41776
41776
|
const arr = [];
|
|
41777
|
-
fileList_box.forEach(i=>{
|
|
41777
|
+
fileList_box.value.forEach(i=>{
|
|
41778
41778
|
arr.push(i.response.data.src);
|
|
41779
41779
|
});
|
|
41780
41780
|
// 触发 update:modelValue 事件更新父组件的 v-model 绑定的值
|
|
@@ -41791,8 +41791,8 @@ return (_ctx, _cache) => {
|
|
|
41791
41791
|
return (openBlock(), createElementBlock("div", null, [
|
|
41792
41792
|
createVNode(_component_el_upload, {
|
|
41793
41793
|
action: myProps_box.uploadUrl,
|
|
41794
|
-
"file-list": fileList_box,
|
|
41795
|
-
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box) = $event)),
|
|
41794
|
+
"file-list": fileList_box.value,
|
|
41795
|
+
"onUpdate:fileList": _cache[0] || (_cache[0] = $event => ((fileList_box).value = $event)),
|
|
41796
41796
|
"list-type": "picture-card",
|
|
41797
41797
|
"before-upload": hdl.beforeUpload,
|
|
41798
41798
|
"on-preview": hdl.preview,
|
|
@@ -41826,10 +41826,10 @@ return (_ctx, _cache) => {
|
|
|
41826
41826
|
]),
|
|
41827
41827
|
_: 1 /* STABLE */
|
|
41828
41828
|
}, 8 /* PROPS */, ["modelValue"]),
|
|
41829
|
-
(fileList_box.length>0)
|
|
41830
|
-
? (openBlock(), createElementBlock("div", _hoisted_3$3, toDisplayString("已上传"+fileList_box.length+"个图片"), 1 /* TEXT */))
|
|
41829
|
+
(fileList_box.value.length>0)
|
|
41830
|
+
? (openBlock(), createElementBlock("div", _hoisted_3$3, toDisplayString("已上传"+fileList_box.value.length+"个图片"), 1 /* TEXT */))
|
|
41831
41831
|
: createCommentVNode("v-if", true),
|
|
41832
|
-
(fileList_box.length>0)
|
|
41832
|
+
(fileList_box.value.length>0)
|
|
41833
41833
|
? (openBlock(), createBlock(_component_el_button, {
|
|
41834
41834
|
key: 1,
|
|
41835
41835
|
size: "small",
|