@cmstops/pro-compo 0.3.7 → 0.3.8
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/es/contentDetailList/components/ShowQRCode/QrcodeView/index.js +78 -86
- package/es/contentDetailList/components/ShowQRCode/index.js +28 -9
- package/lib/contentDetailList/components/ShowQRCode/QrcodeView/index.js +76 -84
- package/lib/contentDetailList/components/ShowQRCode/index.js +26 -7
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent, ref, computed, onMounted, onBeforeUnmount, openBlock, createElementBlock, createCommentVNode,
|
|
2
|
-
import {
|
|
1
|
+
import { defineComponent, ref, computed, onMounted, onBeforeUnmount, openBlock, createElementBlock, createCommentVNode, createElementVNode, Fragment, createVNode, unref, withCtx, renderList, createBlock, toDisplayString, createTextVNode, nextTick } from "vue";
|
|
2
|
+
import { Select, Option, Button, Message } from "@arco-design/web-vue";
|
|
3
3
|
import { IconQrcode } from "@arco-design/web-vue/es/icon";
|
|
4
4
|
import html2canvas from "html2canvas";
|
|
5
5
|
import QRCode from "qrcodejs2-fix";
|
|
@@ -41,8 +41,10 @@ const _sfc_main = defineComponent({
|
|
|
41
41
|
docData: {},
|
|
42
42
|
BASE_API: {}
|
|
43
43
|
},
|
|
44
|
-
|
|
44
|
+
emits: ["changeLoading"],
|
|
45
|
+
setup(__props, { emit: __emit }) {
|
|
45
46
|
const props = __props;
|
|
47
|
+
const emit = __emit;
|
|
46
48
|
const qrcode = ref();
|
|
47
49
|
const dataInfo = ref(null);
|
|
48
50
|
const expirationOptions = ref([
|
|
@@ -56,7 +58,6 @@ const _sfc_main = defineComponent({
|
|
|
56
58
|
{ label: "30\u5929", value: 60 * 60 * 24 * 30 }
|
|
57
59
|
]);
|
|
58
60
|
const expiration = ref(60 * 60 * 24);
|
|
59
|
-
const loading = ref(false);
|
|
60
61
|
const interval = ref(null);
|
|
61
62
|
const time = ref("");
|
|
62
63
|
const local_url = ref("");
|
|
@@ -115,7 +116,7 @@ const _sfc_main = defineComponent({
|
|
|
115
116
|
}
|
|
116
117
|
};
|
|
117
118
|
const genTimeLink = async (expiration2, force = true, tip = true) => {
|
|
118
|
-
|
|
119
|
+
emit("changeLoading", true);
|
|
119
120
|
const data = {
|
|
120
121
|
force,
|
|
121
122
|
hash_id: dataInfo.value.hash_id || dataInfo.value.hashid
|
|
@@ -133,7 +134,7 @@ const _sfc_main = defineComponent({
|
|
|
133
134
|
nextTick(() => {
|
|
134
135
|
loadQrcode(`${message.inner_url}?reqTime=${reqTime}`);
|
|
135
136
|
setTimeout(() => {
|
|
136
|
-
|
|
137
|
+
emit("changeLoading", false);
|
|
137
138
|
}, 500);
|
|
138
139
|
});
|
|
139
140
|
} else {
|
|
@@ -162,7 +163,6 @@ const _sfc_main = defineComponent({
|
|
|
162
163
|
};
|
|
163
164
|
onMounted(() => {
|
|
164
165
|
dataInfo.value = props.docData;
|
|
165
|
-
console.log(1111, dataInfo.value);
|
|
166
166
|
if (needLoadQR.value) {
|
|
167
167
|
genTimeLink(60 * 60 * 24, false, false);
|
|
168
168
|
}
|
|
@@ -177,87 +177,79 @@ const _sfc_main = defineComponent({
|
|
|
177
177
|
return (_ctx, _cache) => {
|
|
178
178
|
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
179
179
|
createCommentVNode(" \u9884\u89C8\u624B\u673A\u626B\u7801 "),
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
class: "qrcode"
|
|
192
|
-
}, null, 8, _hoisted_3)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
193
|
-
!is_publish.value ? (openBlock(), createElementBlock("div", _hoisted_4, [
|
|
194
|
-
createElementVNode("div", _hoisted_5, [
|
|
195
|
-
createVNode(unref(IconQrcode), { size: 200 })
|
|
196
|
-
])
|
|
197
|
-
])) : (openBlock(), createElementBlock("div", _hoisted_6, "\u6682\u65E0\u4E8C\u7EF4\u7801"))
|
|
198
|
-
], 64)),
|
|
199
|
-
is_share.value ? (openBlock(), createElementBlock("div", _hoisted_7, "\u626B\u63CF\u4E8C\u7EF4\u7801\u8BBF\u95EE")) : (openBlock(), createElementBlock("div", _hoisted_8, [
|
|
200
|
-
_hoisted_9,
|
|
201
|
-
createElementVNode("span", null, [
|
|
202
|
-
createVNode(unref(Select), {
|
|
203
|
-
modelValue: expiration.value,
|
|
204
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => expiration.value = $event),
|
|
205
|
-
size: "mini",
|
|
206
|
-
placeholder: "\u8BF7\u9009\u62E9"
|
|
207
|
-
}, {
|
|
208
|
-
default: withCtx(() => [
|
|
209
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(expirationOptions.value, (time2, index) => {
|
|
210
|
-
return openBlock(), createBlock(unref(Option), {
|
|
211
|
-
key: index,
|
|
212
|
-
label: time2.label,
|
|
213
|
-
value: time2.value
|
|
214
|
-
}, null, 8, ["label", "value"]);
|
|
215
|
-
}), 128))
|
|
216
|
-
]),
|
|
217
|
-
_: 1
|
|
218
|
-
}, 8, ["modelValue"])
|
|
219
|
-
])
|
|
220
|
-
])),
|
|
221
|
-
is_share.value && time.value ? (openBlock(), createElementBlock("div", _hoisted_10, "\u94FE\u63A5\u5269\u4F59\u65F6\u95F4: " + toDisplayString(time.value), 1)) : is_share.value && time.value === 0 ? (openBlock(), createElementBlock("div", _hoisted_11, "\u94FE\u63A5\u5DF2\u8FC7\u671F")) : createCommentVNode("v-if", true),
|
|
222
|
-
createElementVNode("div", _hoisted_12, [
|
|
223
|
-
showGetLink.value ? (openBlock(), createBlock(unref(Button), {
|
|
224
|
-
key: 0,
|
|
225
|
-
type: "primary",
|
|
226
|
-
light: "",
|
|
227
|
-
onClick: _cache[1] || (_cache[1] = ($event) => genTimeLink(expiration.value))
|
|
228
|
-
}, {
|
|
229
|
-
default: withCtx(() => [
|
|
230
|
-
createTextVNode("\u751F\u6210\u9884\u89C8\u94FE\u63A5")
|
|
231
|
-
]),
|
|
232
|
-
_: 1
|
|
233
|
-
})) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
234
|
-
createVNode(unref(Button), {
|
|
235
|
-
class: "auto",
|
|
236
|
-
light: "",
|
|
237
|
-
onClick: _cache[2] || (_cache[2] = ($event) => clipUrl("img"))
|
|
238
|
-
}, {
|
|
239
|
-
default: withCtx(() => [
|
|
240
|
-
createTextVNode("\u590D\u5236\u4E8C\u7EF4\u7801")
|
|
241
|
-
]),
|
|
242
|
-
_: 1
|
|
243
|
-
}),
|
|
244
|
-
createVNode(unref(Button), {
|
|
245
|
-
class: "auto",
|
|
246
|
-
type: "primary",
|
|
247
|
-
light: "",
|
|
248
|
-
onClick: _cache[3] || (_cache[3] = ($event) => clipUrl("text"))
|
|
249
|
-
}, {
|
|
250
|
-
default: withCtx(() => [
|
|
251
|
-
createTextVNode(toDisplayString(time.value ? "\u590D\u5236\u9884\u89C8\u5730\u5740" : "\u590D\u5236\u8BBF\u95EE\u5730\u5740"), 1)
|
|
252
|
-
]),
|
|
253
|
-
_: 1
|
|
254
|
-
})
|
|
255
|
-
], 64))
|
|
180
|
+
createElementVNode("div", _hoisted_2, [
|
|
181
|
+
is_share.value ? (openBlock(), createElementBlock("div", {
|
|
182
|
+
key: 0,
|
|
183
|
+
id: dynamicQRId.value,
|
|
184
|
+
ref_key: "qrcode",
|
|
185
|
+
ref: qrcode,
|
|
186
|
+
class: "qrcode"
|
|
187
|
+
}, null, 8, _hoisted_3)) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
188
|
+
!is_publish.value ? (openBlock(), createElementBlock("div", _hoisted_4, [
|
|
189
|
+
createElementVNode("div", _hoisted_5, [
|
|
190
|
+
createVNode(unref(IconQrcode), { size: 200 })
|
|
256
191
|
])
|
|
192
|
+
])) : (openBlock(), createElementBlock("div", _hoisted_6, "\u6682\u65E0\u4E8C\u7EF4\u7801"))
|
|
193
|
+
], 64)),
|
|
194
|
+
is_share.value ? (openBlock(), createElementBlock("div", _hoisted_7, "\u626B\u63CF\u4E8C\u7EF4\u7801\u8BBF\u95EE")) : (openBlock(), createElementBlock("div", _hoisted_8, [
|
|
195
|
+
_hoisted_9,
|
|
196
|
+
createElementVNode("span", null, [
|
|
197
|
+
createVNode(unref(Select), {
|
|
198
|
+
modelValue: expiration.value,
|
|
199
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => expiration.value = $event),
|
|
200
|
+
size: "mini",
|
|
201
|
+
placeholder: "\u8BF7\u9009\u62E9"
|
|
202
|
+
}, {
|
|
203
|
+
default: withCtx(() => [
|
|
204
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(expirationOptions.value, (time2, index) => {
|
|
205
|
+
return openBlock(), createBlock(unref(Option), {
|
|
206
|
+
key: index,
|
|
207
|
+
label: time2.label,
|
|
208
|
+
value: time2.value
|
|
209
|
+
}, null, 8, ["label", "value"]);
|
|
210
|
+
}), 128))
|
|
211
|
+
]),
|
|
212
|
+
_: 1
|
|
213
|
+
}, 8, ["modelValue"])
|
|
257
214
|
])
|
|
258
|
-
]),
|
|
259
|
-
|
|
260
|
-
|
|
215
|
+
])),
|
|
216
|
+
is_share.value && time.value ? (openBlock(), createElementBlock("div", _hoisted_10, "\u94FE\u63A5\u5269\u4F59\u65F6\u95F4: " + toDisplayString(time.value), 1)) : is_share.value && time.value === 0 ? (openBlock(), createElementBlock("div", _hoisted_11, "\u94FE\u63A5\u5DF2\u8FC7\u671F")) : createCommentVNode("v-if", true),
|
|
217
|
+
createElementVNode("div", _hoisted_12, [
|
|
218
|
+
showGetLink.value ? (openBlock(), createBlock(unref(Button), {
|
|
219
|
+
key: 0,
|
|
220
|
+
type: "primary",
|
|
221
|
+
light: "",
|
|
222
|
+
onClick: _cache[1] || (_cache[1] = ($event) => genTimeLink(expiration.value))
|
|
223
|
+
}, {
|
|
224
|
+
default: withCtx(() => [
|
|
225
|
+
createTextVNode("\u751F\u6210\u9884\u89C8\u94FE\u63A5")
|
|
226
|
+
]),
|
|
227
|
+
_: 1
|
|
228
|
+
})) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
229
|
+
createVNode(unref(Button), {
|
|
230
|
+
class: "auto",
|
|
231
|
+
light: "",
|
|
232
|
+
onClick: _cache[2] || (_cache[2] = ($event) => clipUrl("img"))
|
|
233
|
+
}, {
|
|
234
|
+
default: withCtx(() => [
|
|
235
|
+
createTextVNode("\u590D\u5236\u4E8C\u7EF4\u7801")
|
|
236
|
+
]),
|
|
237
|
+
_: 1
|
|
238
|
+
}),
|
|
239
|
+
createVNode(unref(Button), {
|
|
240
|
+
class: "auto",
|
|
241
|
+
type: "primary",
|
|
242
|
+
light: "",
|
|
243
|
+
onClick: _cache[3] || (_cache[3] = ($event) => clipUrl("text"))
|
|
244
|
+
}, {
|
|
245
|
+
default: withCtx(() => [
|
|
246
|
+
createTextVNode(toDisplayString(time.value ? "\u590D\u5236\u9884\u89C8\u5730\u5740" : "\u590D\u5236\u8BBF\u95EE\u5730\u5740"), 1)
|
|
247
|
+
]),
|
|
248
|
+
_: 1
|
|
249
|
+
})
|
|
250
|
+
], 64))
|
|
251
|
+
])
|
|
252
|
+
])
|
|
261
253
|
]);
|
|
262
254
|
};
|
|
263
255
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent, ref, openBlock, createBlock, unref, withCtx, withModifiers, createCommentVNode, createElementVNode
|
|
2
|
-
import { Popover } from "@arco-design/web-vue";
|
|
1
|
+
import { defineComponent, ref, openBlock, createBlock, unref, withCtx, createVNode, withModifiers, createCommentVNode, createElementVNode } from "vue";
|
|
2
|
+
import { Popover, Spin } from "@arco-design/web-vue";
|
|
3
3
|
import { IconQrcode } from "@arco-design/web-vue/es/icon";
|
|
4
4
|
import { getDocDetailsNew } from "../../script/api.js";
|
|
5
5
|
import _sfc_main$1 from "./QrcodeView/index.js";
|
|
@@ -12,6 +12,7 @@ const _sfc_main = defineComponent({
|
|
|
12
12
|
},
|
|
13
13
|
setup(__props) {
|
|
14
14
|
const props = __props;
|
|
15
|
+
const loading = ref(false);
|
|
15
16
|
const docData = ref(null);
|
|
16
17
|
const showQR = ref(false);
|
|
17
18
|
const getDocDetail = async () => {
|
|
@@ -23,26 +24,44 @@ const _sfc_main = defineComponent({
|
|
|
23
24
|
}
|
|
24
25
|
};
|
|
25
26
|
const openPopover = () => {
|
|
27
|
+
loading.value = true;
|
|
26
28
|
getDocDetail();
|
|
27
29
|
setTimeout(() => {
|
|
28
30
|
showQR.value = true;
|
|
29
31
|
}, 500);
|
|
30
32
|
};
|
|
33
|
+
const handleChangeLoading = (val) => {
|
|
34
|
+
loading.value = val;
|
|
35
|
+
console.log(1111, loading.value);
|
|
36
|
+
};
|
|
31
37
|
return (_ctx, _cache) => {
|
|
32
38
|
return openBlock(), createBlock(unref(Popover), {
|
|
39
|
+
"content-style": {
|
|
40
|
+
minWidth: "224px",
|
|
41
|
+
minHeight: "300px"
|
|
42
|
+
},
|
|
33
43
|
position: "bottom",
|
|
34
44
|
trigger: "click",
|
|
35
45
|
onShow: openPopover,
|
|
36
46
|
onHide: _cache[1] || (_cache[1] = ($event) => showQR.value = false)
|
|
37
47
|
}, {
|
|
38
48
|
content: withCtx(() => [
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
49
|
+
createVNode(unref(Spin), {
|
|
50
|
+
loading: loading.value,
|
|
51
|
+
style: { "min-width": "224px", "min-height": "300px" }
|
|
52
|
+
}, {
|
|
53
|
+
default: withCtx(() => [
|
|
54
|
+
showQR.value ? (openBlock(), createBlock(_sfc_main$1, {
|
|
55
|
+
key: 0,
|
|
56
|
+
BASE_API: _ctx.BASE_API,
|
|
57
|
+
docData: docData.value || props.item,
|
|
58
|
+
onChangeLoading: handleChangeLoading,
|
|
59
|
+
onClick: _cache[0] || (_cache[0] = withModifiers(() => {
|
|
60
|
+
}, ["stop"]))
|
|
61
|
+
}, null, 8, ["BASE_API", "docData"])) : createCommentVNode("v-if", true)
|
|
62
|
+
]),
|
|
63
|
+
_: 1
|
|
64
|
+
}, 8, ["loading"])
|
|
46
65
|
]),
|
|
47
66
|
default: withCtx(() => [
|
|
48
67
|
createElementVNode("section", _hoisted_1, [
|
|
@@ -47,8 +47,10 @@ const _sfc_main = vue.defineComponent({
|
|
|
47
47
|
docData: {},
|
|
48
48
|
BASE_API: {}
|
|
49
49
|
},
|
|
50
|
-
|
|
50
|
+
emits: ["changeLoading"],
|
|
51
|
+
setup(__props, { emit: __emit }) {
|
|
51
52
|
const props = __props;
|
|
53
|
+
const emit = __emit;
|
|
52
54
|
const qrcode = vue.ref();
|
|
53
55
|
const dataInfo = vue.ref(null);
|
|
54
56
|
const expirationOptions = vue.ref([
|
|
@@ -62,7 +64,6 @@ const _sfc_main = vue.defineComponent({
|
|
|
62
64
|
{ label: "30\u5929", value: 60 * 60 * 24 * 30 }
|
|
63
65
|
]);
|
|
64
66
|
const expiration = vue.ref(60 * 60 * 24);
|
|
65
|
-
const loading = vue.ref(false);
|
|
66
67
|
const interval = vue.ref(null);
|
|
67
68
|
const time = vue.ref("");
|
|
68
69
|
const local_url = vue.ref("");
|
|
@@ -121,7 +122,7 @@ const _sfc_main = vue.defineComponent({
|
|
|
121
122
|
}
|
|
122
123
|
};
|
|
123
124
|
const genTimeLink = async (expiration2, force = true, tip = true) => {
|
|
124
|
-
|
|
125
|
+
emit("changeLoading", true);
|
|
125
126
|
const data = {
|
|
126
127
|
force,
|
|
127
128
|
hash_id: dataInfo.value.hash_id || dataInfo.value.hashid
|
|
@@ -139,7 +140,7 @@ const _sfc_main = vue.defineComponent({
|
|
|
139
140
|
vue.nextTick(() => {
|
|
140
141
|
loadQrcode(`${message.inner_url}?reqTime=${reqTime}`);
|
|
141
142
|
setTimeout(() => {
|
|
142
|
-
|
|
143
|
+
emit("changeLoading", false);
|
|
143
144
|
}, 500);
|
|
144
145
|
});
|
|
145
146
|
} else {
|
|
@@ -168,7 +169,6 @@ const _sfc_main = vue.defineComponent({
|
|
|
168
169
|
};
|
|
169
170
|
vue.onMounted(() => {
|
|
170
171
|
dataInfo.value = props.docData;
|
|
171
|
-
console.log(1111, dataInfo.value);
|
|
172
172
|
if (needLoadQR.value) {
|
|
173
173
|
genTimeLink(60 * 60 * 24, false, false);
|
|
174
174
|
}
|
|
@@ -183,87 +183,79 @@ const _sfc_main = vue.defineComponent({
|
|
|
183
183
|
return (_ctx, _cache) => {
|
|
184
184
|
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
|
|
185
185
|
vue.createCommentVNode(" \u9884\u89C8\u624B\u673A\u626B\u7801 "),
|
|
186
|
-
vue.
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
class: "qrcode"
|
|
198
|
-
}, null, 8, _hoisted_3)) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
199
|
-
!is_publish.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4, [
|
|
200
|
-
vue.createElementVNode("div", _hoisted_5, [
|
|
201
|
-
vue.createVNode(vue.unref(icon.IconQrcode), { size: 200 })
|
|
202
|
-
])
|
|
203
|
-
])) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_6, "\u6682\u65E0\u4E8C\u7EF4\u7801"))
|
|
204
|
-
], 64)),
|
|
205
|
-
is_share.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7, "\u626B\u63CF\u4E8C\u7EF4\u7801\u8BBF\u95EE")) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_8, [
|
|
206
|
-
_hoisted_9,
|
|
207
|
-
vue.createElementVNode("span", null, [
|
|
208
|
-
vue.createVNode(vue.unref(webVue.Select), {
|
|
209
|
-
modelValue: expiration.value,
|
|
210
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => expiration.value = $event),
|
|
211
|
-
size: "mini",
|
|
212
|
-
placeholder: "\u8BF7\u9009\u62E9"
|
|
213
|
-
}, {
|
|
214
|
-
default: vue.withCtx(() => [
|
|
215
|
-
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(expirationOptions.value, (time2, index) => {
|
|
216
|
-
return vue.openBlock(), vue.createBlock(vue.unref(webVue.Option), {
|
|
217
|
-
key: index,
|
|
218
|
-
label: time2.label,
|
|
219
|
-
value: time2.value
|
|
220
|
-
}, null, 8, ["label", "value"]);
|
|
221
|
-
}), 128))
|
|
222
|
-
]),
|
|
223
|
-
_: 1
|
|
224
|
-
}, 8, ["modelValue"])
|
|
225
|
-
])
|
|
226
|
-
])),
|
|
227
|
-
is_share.value && time.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_10, "\u94FE\u63A5\u5269\u4F59\u65F6\u95F4: " + vue.toDisplayString(time.value), 1)) : is_share.value && time.value === 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_11, "\u94FE\u63A5\u5DF2\u8FC7\u671F")) : vue.createCommentVNode("v-if", true),
|
|
228
|
-
vue.createElementVNode("div", _hoisted_12, [
|
|
229
|
-
showGetLink.value ? (vue.openBlock(), vue.createBlock(vue.unref(webVue.Button), {
|
|
230
|
-
key: 0,
|
|
231
|
-
type: "primary",
|
|
232
|
-
light: "",
|
|
233
|
-
onClick: _cache[1] || (_cache[1] = ($event) => genTimeLink(expiration.value))
|
|
234
|
-
}, {
|
|
235
|
-
default: vue.withCtx(() => [
|
|
236
|
-
vue.createTextVNode("\u751F\u6210\u9884\u89C8\u94FE\u63A5")
|
|
237
|
-
]),
|
|
238
|
-
_: 1
|
|
239
|
-
})) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
240
|
-
vue.createVNode(vue.unref(webVue.Button), {
|
|
241
|
-
class: "auto",
|
|
242
|
-
light: "",
|
|
243
|
-
onClick: _cache[2] || (_cache[2] = ($event) => clipUrl("img"))
|
|
244
|
-
}, {
|
|
245
|
-
default: vue.withCtx(() => [
|
|
246
|
-
vue.createTextVNode("\u590D\u5236\u4E8C\u7EF4\u7801")
|
|
247
|
-
]),
|
|
248
|
-
_: 1
|
|
249
|
-
}),
|
|
250
|
-
vue.createVNode(vue.unref(webVue.Button), {
|
|
251
|
-
class: "auto",
|
|
252
|
-
type: "primary",
|
|
253
|
-
light: "",
|
|
254
|
-
onClick: _cache[3] || (_cache[3] = ($event) => clipUrl("text"))
|
|
255
|
-
}, {
|
|
256
|
-
default: vue.withCtx(() => [
|
|
257
|
-
vue.createTextVNode(vue.toDisplayString(time.value ? "\u590D\u5236\u9884\u89C8\u5730\u5740" : "\u590D\u5236\u8BBF\u95EE\u5730\u5740"), 1)
|
|
258
|
-
]),
|
|
259
|
-
_: 1
|
|
260
|
-
})
|
|
261
|
-
], 64))
|
|
186
|
+
vue.createElementVNode("div", _hoisted_2, [
|
|
187
|
+
is_share.value ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
188
|
+
key: 0,
|
|
189
|
+
id: dynamicQRId.value,
|
|
190
|
+
ref_key: "qrcode",
|
|
191
|
+
ref: qrcode,
|
|
192
|
+
class: "qrcode"
|
|
193
|
+
}, null, 8, _hoisted_3)) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
194
|
+
!is_publish.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4, [
|
|
195
|
+
vue.createElementVNode("div", _hoisted_5, [
|
|
196
|
+
vue.createVNode(vue.unref(icon.IconQrcode), { size: 200 })
|
|
262
197
|
])
|
|
198
|
+
])) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_6, "\u6682\u65E0\u4E8C\u7EF4\u7801"))
|
|
199
|
+
], 64)),
|
|
200
|
+
is_share.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_7, "\u626B\u63CF\u4E8C\u7EF4\u7801\u8BBF\u95EE")) : (vue.openBlock(), vue.createElementBlock("div", _hoisted_8, [
|
|
201
|
+
_hoisted_9,
|
|
202
|
+
vue.createElementVNode("span", null, [
|
|
203
|
+
vue.createVNode(vue.unref(webVue.Select), {
|
|
204
|
+
modelValue: expiration.value,
|
|
205
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => expiration.value = $event),
|
|
206
|
+
size: "mini",
|
|
207
|
+
placeholder: "\u8BF7\u9009\u62E9"
|
|
208
|
+
}, {
|
|
209
|
+
default: vue.withCtx(() => [
|
|
210
|
+
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(expirationOptions.value, (time2, index) => {
|
|
211
|
+
return vue.openBlock(), vue.createBlock(vue.unref(webVue.Option), {
|
|
212
|
+
key: index,
|
|
213
|
+
label: time2.label,
|
|
214
|
+
value: time2.value
|
|
215
|
+
}, null, 8, ["label", "value"]);
|
|
216
|
+
}), 128))
|
|
217
|
+
]),
|
|
218
|
+
_: 1
|
|
219
|
+
}, 8, ["modelValue"])
|
|
263
220
|
])
|
|
264
|
-
]),
|
|
265
|
-
|
|
266
|
-
|
|
221
|
+
])),
|
|
222
|
+
is_share.value && time.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_10, "\u94FE\u63A5\u5269\u4F59\u65F6\u95F4: " + vue.toDisplayString(time.value), 1)) : is_share.value && time.value === 0 ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_11, "\u94FE\u63A5\u5DF2\u8FC7\u671F")) : vue.createCommentVNode("v-if", true),
|
|
223
|
+
vue.createElementVNode("div", _hoisted_12, [
|
|
224
|
+
showGetLink.value ? (vue.openBlock(), vue.createBlock(vue.unref(webVue.Button), {
|
|
225
|
+
key: 0,
|
|
226
|
+
type: "primary",
|
|
227
|
+
light: "",
|
|
228
|
+
onClick: _cache[1] || (_cache[1] = ($event) => genTimeLink(expiration.value))
|
|
229
|
+
}, {
|
|
230
|
+
default: vue.withCtx(() => [
|
|
231
|
+
vue.createTextVNode("\u751F\u6210\u9884\u89C8\u94FE\u63A5")
|
|
232
|
+
]),
|
|
233
|
+
_: 1
|
|
234
|
+
})) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
|
|
235
|
+
vue.createVNode(vue.unref(webVue.Button), {
|
|
236
|
+
class: "auto",
|
|
237
|
+
light: "",
|
|
238
|
+
onClick: _cache[2] || (_cache[2] = ($event) => clipUrl("img"))
|
|
239
|
+
}, {
|
|
240
|
+
default: vue.withCtx(() => [
|
|
241
|
+
vue.createTextVNode("\u590D\u5236\u4E8C\u7EF4\u7801")
|
|
242
|
+
]),
|
|
243
|
+
_: 1
|
|
244
|
+
}),
|
|
245
|
+
vue.createVNode(vue.unref(webVue.Button), {
|
|
246
|
+
class: "auto",
|
|
247
|
+
type: "primary",
|
|
248
|
+
light: "",
|
|
249
|
+
onClick: _cache[3] || (_cache[3] = ($event) => clipUrl("text"))
|
|
250
|
+
}, {
|
|
251
|
+
default: vue.withCtx(() => [
|
|
252
|
+
vue.createTextVNode(vue.toDisplayString(time.value ? "\u590D\u5236\u9884\u89C8\u5730\u5740" : "\u590D\u5236\u8BBF\u95EE\u5730\u5740"), 1)
|
|
253
|
+
]),
|
|
254
|
+
_: 1
|
|
255
|
+
})
|
|
256
|
+
], 64))
|
|
257
|
+
])
|
|
258
|
+
])
|
|
267
259
|
]);
|
|
268
260
|
};
|
|
269
261
|
}
|
|
@@ -13,6 +13,7 @@ const _sfc_main = vue.defineComponent({
|
|
|
13
13
|
},
|
|
14
14
|
setup(__props) {
|
|
15
15
|
const props = __props;
|
|
16
|
+
const loading = vue.ref(false);
|
|
16
17
|
const docData = vue.ref(null);
|
|
17
18
|
const showQR = vue.ref(false);
|
|
18
19
|
const getDocDetail = async () => {
|
|
@@ -24,26 +25,44 @@ const _sfc_main = vue.defineComponent({
|
|
|
24
25
|
}
|
|
25
26
|
};
|
|
26
27
|
const openPopover = () => {
|
|
28
|
+
loading.value = true;
|
|
27
29
|
getDocDetail();
|
|
28
30
|
setTimeout(() => {
|
|
29
31
|
showQR.value = true;
|
|
30
32
|
}, 500);
|
|
31
33
|
};
|
|
34
|
+
const handleChangeLoading = (val) => {
|
|
35
|
+
loading.value = val;
|
|
36
|
+
console.log(1111, loading.value);
|
|
37
|
+
};
|
|
32
38
|
return (_ctx, _cache) => {
|
|
33
39
|
return vue.openBlock(), vue.createBlock(vue.unref(webVue.Popover), {
|
|
40
|
+
"content-style": {
|
|
41
|
+
minWidth: "224px",
|
|
42
|
+
minHeight: "300px"
|
|
43
|
+
},
|
|
34
44
|
position: "bottom",
|
|
35
45
|
trigger: "click",
|
|
36
46
|
onShow: openPopover,
|
|
37
47
|
onHide: _cache[1] || (_cache[1] = ($event) => showQR.value = false)
|
|
38
48
|
}, {
|
|
39
49
|
content: vue.withCtx(() => [
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
50
|
+
vue.createVNode(vue.unref(webVue.Spin), {
|
|
51
|
+
loading: loading.value,
|
|
52
|
+
style: { "min-width": "224px", "min-height": "300px" }
|
|
53
|
+
}, {
|
|
54
|
+
default: vue.withCtx(() => [
|
|
55
|
+
showQR.value ? (vue.openBlock(), vue.createBlock(index, {
|
|
56
|
+
key: 0,
|
|
57
|
+
BASE_API: _ctx.BASE_API,
|
|
58
|
+
docData: docData.value || props.item,
|
|
59
|
+
onChangeLoading: handleChangeLoading,
|
|
60
|
+
onClick: _cache[0] || (_cache[0] = vue.withModifiers(() => {
|
|
61
|
+
}, ["stop"]))
|
|
62
|
+
}, null, 8, ["BASE_API", "docData"])) : vue.createCommentVNode("v-if", true)
|
|
63
|
+
]),
|
|
64
|
+
_: 1
|
|
65
|
+
}, 8, ["loading"])
|
|
47
66
|
]),
|
|
48
67
|
default: vue.withCtx(() => [
|
|
49
68
|
vue.createElementVNode("section", _hoisted_1, [
|