iking-web-ui-pro 0.0.1
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/Demo/index.es.js +13 -0
- package/dist/Demo/index.umd.js +1 -0
- package/dist/Demo/package.json +7 -0
- package/dist/IKApprovalProcess/index.es.js +13026 -0
- package/dist/IKApprovalProcess/index.umd.js +32 -0
- package/dist/IKApprovalProcess/package.json +7 -0
- package/dist/IKApprovalProcess/style.css +7 -0
- package/dist/IKApprovalProcessDetail/index.es.js +630 -0
- package/dist/IKApprovalProcessDetail/index.umd.js +1 -0
- package/dist/IKApprovalProcessDetail/package.json +7 -0
- package/dist/IKApprovalProcessDetail/style.css +1 -0
- package/dist/IKCalendar/index.es.js +22495 -0
- package/dist/IKCalendar/index.umd.js +32 -0
- package/dist/IKCalendar/package.json +7 -0
- package/dist/IKCalendar/style.css +7 -0
- package/dist/IKDescription/index.es.js +105 -0
- package/dist/IKDescription/index.umd.js +1 -0
- package/dist/IKDescription/style.css +1 -0
- package/dist/IKDetailPreviewFiles/index.es.js +1599 -0
- package/dist/IKDetailPreviewFiles/index.umd.js +1 -0
- package/dist/IKDetailPreviewFiles/style.css +1 -0
- package/dist/IKExpandCollapse/index.es.js +1388 -0
- package/dist/IKExpandCollapse/index.umd.js +1 -0
- package/dist/IKExpandCollapse/style.css +1 -0
- package/dist/IKHorizontalStepBar/index.es.js +251 -0
- package/dist/IKHorizontalStepBar/index.umd.js +1 -0
- package/dist/IKHorizontalStepBar/package.json +7 -0
- package/dist/IKHorizontalStepBar/style.css +1 -0
- package/dist/IKPreviewFile/index.es.js +108 -0
- package/dist/IKPreviewFile/index.umd.js +1 -0
- package/dist/IKPreviewFile/style.css +1 -0
- package/dist/IKSearch/index.es.js +13406 -0
- package/dist/IKSearch/index.umd.js +57 -0
- package/dist/IKSearch/package.json +7 -0
- package/dist/IKSearch/style.css +7 -0
- package/dist/IKSearchHead/index.es.js +116 -0
- package/dist/IKSearchHead/index.umd.js +1 -0
- package/dist/IKSearchHead/package.json +7 -0
- package/dist/IKSearchHead/style.css +1 -0
- package/dist/IKVerticalStepBar/index.es.js +1481 -0
- package/dist/IKVerticalStepBar/index.umd.js +9 -0
- package/dist/IKVerticalStepBar/package.json +7 -0
- package/dist/IKVerticalStepBar/style.css +1 -0
- package/dist/IkBottomOperate/index.es.js +210 -0
- package/dist/IkBottomOperate/index.umd.js +1 -0
- package/dist/IkBottomOperate/style.css +1 -0
- package/dist/IkBtnContent/index.es.js +101 -0
- package/dist/IkBtnContent/index.umd.js +1 -0
- package/dist/IkBtnContent/style.css +1 -0
- package/dist/IkBtnSetting/index.es.js +12854 -0
- package/dist/IkBtnSetting/index.umd.js +32 -0
- package/dist/IkBtnSetting/style.css +7 -0
- package/dist/IkDragList/index.es.js +11071 -0
- package/dist/IkDragList/index.umd.js +32 -0
- package/dist/IkDragList/style.css +7 -0
- package/dist/IkFullCalendar/index.es.js +20327 -0
- package/dist/IkFullCalendar/index.umd.js +32 -0
- package/dist/IkFullCalendar/style.css +7 -0
- package/dist/IkIconPicker/index.es.js +13693 -0
- package/dist/IkIconPicker/index.umd.js +32 -0
- package/dist/IkIconPicker/style.css +7 -0
- package/dist/IkOnlyOffice/index.es.js +393 -0
- package/dist/IkOnlyOffice/index.umd.js +1 -0
- package/dist/IkOnlyOffice/style.css +0 -0
- package/dist/IkPageFull/index.es.js +15725 -0
- package/dist/IkPageFull/index.umd.js +48 -0
- package/dist/IkPageFull/style.css +7 -0
- package/dist/IkPageTabs/index.es.js +135 -0
- package/dist/IkPageTabs/index.umd.js +1 -0
- package/dist/IkPageTabs/style.css +1 -0
- package/dist/IkPicker/index.es.js +12629 -0
- package/dist/IkPicker/index.umd.js +32 -0
- package/dist/IkPicker/style.css +7 -0
- package/dist/IkPickerUser/index.es.js +12508 -0
- package/dist/IkPickerUser/index.umd.js +32 -0
- package/dist/IkPickerUser/style.css +7 -0
- package/dist/IkPrintConfig/index.es.js +62 -0
- package/dist/IkPrintConfig/index.umd.js +1 -0
- package/dist/IkPrintView/index.es.js +79 -0
- package/dist/IkPrintView/index.umd.js +1 -0
- package/dist/IkRadioGroup/index.es.js +75 -0
- package/dist/IkRadioGroup/index.umd.js +1 -0
- package/dist/IkRadioGroup/style.css +1 -0
- package/dist/IkSchedule/index.es.js +22228 -0
- package/dist/IkSchedule/index.umd.js +32 -0
- package/dist/IkSchedule/style.css +7 -0
- package/dist/IkStatu/index.es.js +119 -0
- package/dist/IkStatu/index.umd.js +1 -0
- package/dist/IkStatu/style.css +1 -0
- package/dist/IkSvgIcon/index.es.js +1343 -0
- package/dist/IkSvgIcon/index.umd.js +1 -0
- package/dist/IkSvgIcon/style.css +1 -0
- package/dist/IkTemplateOfficeConfig/index.es.js +805 -0
- package/dist/IkTemplateOfficeConfig/index.umd.js +1 -0
- package/dist/IkTemplateOfficeConfig/style.css +1 -0
- package/dist/IkTooltip/index.es.js +49 -0
- package/dist/IkTooltip/index.umd.js +1 -0
- package/dist/IkUploadFile/index.es.js +12098 -0
- package/dist/IkUploadFile/index.umd.js +32 -0
- package/dist/IkUploadFile/style.css +7 -0
- package/dist/IkUploadImage/index.es.js +11442 -0
- package/dist/IkUploadImage/index.umd.js +32 -0
- package/dist/IkUploadImage/style.css +7 -0
- package/dist/index.es.js +33843 -0
- package/dist/index.umd.js +81 -0
- package/dist/style.css +7 -0
- package/package.json +66 -0
|
@@ -0,0 +1,805 @@
|
|
|
1
|
+
import { defineComponent as I, openBlock as u, createElementBlock as g, ref as E, normalizeStyle as M, createVNode as O, unref as P, watch as U, resolveComponent as D, Fragment as T, renderList as F, createBlock as C, withCtx as m, createElementVNode as d, toDisplayString as R, createCommentVNode as S, normalizeClass as A, pushScopeId as H, popScopeId as N, useCssVars as j } from "vue";
|
|
2
|
+
const $ = (e, t) => {
|
|
3
|
+
if (e.install = (n) => {
|
|
4
|
+
for (const i of [e, ...Object.values(t ?? {})])
|
|
5
|
+
n.component(i.name, i);
|
|
6
|
+
}, t)
|
|
7
|
+
for (const [n, i] of Object.entries(t))
|
|
8
|
+
e[n] = i;
|
|
9
|
+
return e;
|
|
10
|
+
};
|
|
11
|
+
function G(e, t, n, i) {
|
|
12
|
+
function s(o) {
|
|
13
|
+
return o instanceof n ? o : new n(function(r) {
|
|
14
|
+
r(o);
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
return new (n || (n = Promise))(function(o, r) {
|
|
18
|
+
function h(f) {
|
|
19
|
+
try {
|
|
20
|
+
a(i.next(f));
|
|
21
|
+
} catch (_) {
|
|
22
|
+
r(_);
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
function k(f) {
|
|
26
|
+
try {
|
|
27
|
+
a(i.throw(f));
|
|
28
|
+
} catch (_) {
|
|
29
|
+
r(_);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
function a(f) {
|
|
33
|
+
f.done ? o(f.value) : s(f.value).then(h, k);
|
|
34
|
+
}
|
|
35
|
+
a((i = i.apply(e, t || [])).next());
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
function z(e, t) {
|
|
39
|
+
var n = { label: 0, sent: function() {
|
|
40
|
+
if (o[0] & 1)
|
|
41
|
+
throw o[1];
|
|
42
|
+
return o[1];
|
|
43
|
+
}, trys: [], ops: [] }, i, s, o, r;
|
|
44
|
+
return r = { next: h(0), throw: h(1), return: h(2) }, typeof Symbol == "function" && (r[Symbol.iterator] = function() {
|
|
45
|
+
return this;
|
|
46
|
+
}), r;
|
|
47
|
+
function h(a) {
|
|
48
|
+
return function(f) {
|
|
49
|
+
return k([a, f]);
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
function k(a) {
|
|
53
|
+
if (i)
|
|
54
|
+
throw new TypeError("Generator is already executing.");
|
|
55
|
+
for (; r && (r = 0, a[0] && (n = 0)), n; )
|
|
56
|
+
try {
|
|
57
|
+
if (i = 1, s && (o = a[0] & 2 ? s.return : a[0] ? s.throw || ((o = s.return) && o.call(s), 0) : s.next) && !(o = o.call(s, a[1])).done)
|
|
58
|
+
return o;
|
|
59
|
+
switch (s = 0, o && (a = [a[0] & 2, o.value]), a[0]) {
|
|
60
|
+
case 0:
|
|
61
|
+
case 1:
|
|
62
|
+
o = a;
|
|
63
|
+
break;
|
|
64
|
+
case 4:
|
|
65
|
+
return n.label++, { value: a[1], done: !1 };
|
|
66
|
+
case 5:
|
|
67
|
+
n.label++, s = a[1], a = [0];
|
|
68
|
+
continue;
|
|
69
|
+
case 7:
|
|
70
|
+
a = n.ops.pop(), n.trys.pop();
|
|
71
|
+
continue;
|
|
72
|
+
default:
|
|
73
|
+
if (o = n.trys, !(o = o.length > 0 && o[o.length - 1]) && (a[0] === 6 || a[0] === 2)) {
|
|
74
|
+
n = 0;
|
|
75
|
+
continue;
|
|
76
|
+
}
|
|
77
|
+
if (a[0] === 3 && (!o || a[1] > o[0] && a[1] < o[3])) {
|
|
78
|
+
n.label = a[1];
|
|
79
|
+
break;
|
|
80
|
+
}
|
|
81
|
+
if (a[0] === 6 && n.label < o[1]) {
|
|
82
|
+
n.label = o[1], o = a;
|
|
83
|
+
break;
|
|
84
|
+
}
|
|
85
|
+
if (o && n.label < o[2]) {
|
|
86
|
+
n.label = o[2], n.ops.push(a);
|
|
87
|
+
break;
|
|
88
|
+
}
|
|
89
|
+
o[2] && n.ops.pop(), n.trys.pop();
|
|
90
|
+
continue;
|
|
91
|
+
}
|
|
92
|
+
a = t.call(e, n);
|
|
93
|
+
} catch (f) {
|
|
94
|
+
a = [6, f], s = 0;
|
|
95
|
+
} finally {
|
|
96
|
+
i = o = 0;
|
|
97
|
+
}
|
|
98
|
+
if (a[0] & 5)
|
|
99
|
+
throw a[1];
|
|
100
|
+
return { value: a[0] ? a[1] : void 0, done: !0 };
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
var W = function(e, t) {
|
|
104
|
+
return G(void 0, void 0, void 0, function() {
|
|
105
|
+
return z(this, function(n) {
|
|
106
|
+
return [2, new Promise(function(i, s) {
|
|
107
|
+
try {
|
|
108
|
+
if (document.getElementById(t)) {
|
|
109
|
+
if (window.DocsAPI)
|
|
110
|
+
return i(null);
|
|
111
|
+
var o = setInterval(function() {
|
|
112
|
+
if (window.DocsAPI)
|
|
113
|
+
return clearInterval(o), i(null);
|
|
114
|
+
}, 500);
|
|
115
|
+
} else {
|
|
116
|
+
var r = document.createElement("script");
|
|
117
|
+
r.setAttribute("type", "text/javascript"), r.setAttribute("id", t), r.onload = i, r.onerror = s, r.src = e, r.async = !0, document.body.appendChild(r);
|
|
118
|
+
}
|
|
119
|
+
} catch (h) {
|
|
120
|
+
console.error(h);
|
|
121
|
+
}
|
|
122
|
+
})];
|
|
123
|
+
});
|
|
124
|
+
});
|
|
125
|
+
}, V = I({
|
|
126
|
+
name: "DocumentEditor",
|
|
127
|
+
props: {
|
|
128
|
+
id: {
|
|
129
|
+
type: String,
|
|
130
|
+
required: !0
|
|
131
|
+
},
|
|
132
|
+
documentServerUrl: {
|
|
133
|
+
type: String,
|
|
134
|
+
required: !0
|
|
135
|
+
},
|
|
136
|
+
config: {
|
|
137
|
+
type: Object,
|
|
138
|
+
required: !0
|
|
139
|
+
},
|
|
140
|
+
document_fileType: String,
|
|
141
|
+
document_title: String,
|
|
142
|
+
documentType: String,
|
|
143
|
+
editorConfig_lang: String,
|
|
144
|
+
height: String,
|
|
145
|
+
type: String,
|
|
146
|
+
width: String,
|
|
147
|
+
onLoadComponentError: Function,
|
|
148
|
+
events_onAppReady: Function,
|
|
149
|
+
events_onDocumentStateChange: Function,
|
|
150
|
+
events_onMetaChange: Function,
|
|
151
|
+
events_onDocumentReady: Function,
|
|
152
|
+
events_onInfo: Function,
|
|
153
|
+
events_onWarning: Function,
|
|
154
|
+
events_onError: Function,
|
|
155
|
+
events_onRequestSharingSettings: Function,
|
|
156
|
+
events_onRequestRename: Function,
|
|
157
|
+
events_onMakeActionLink: Function,
|
|
158
|
+
events_onRequestInsertImage: Function,
|
|
159
|
+
events_onRequestSaveAs: Function,
|
|
160
|
+
events_onRequestMailMergeRecipients: Function,
|
|
161
|
+
events_onRequestCompareFile: Function,
|
|
162
|
+
events_onRequestEditRights: Function,
|
|
163
|
+
events_onRequestHistory: Function,
|
|
164
|
+
events_onRequestHistoryClose: Function,
|
|
165
|
+
events_onRequestHistoryData: Function,
|
|
166
|
+
events_onRequestRestore: Function
|
|
167
|
+
},
|
|
168
|
+
mounted: function() {
|
|
169
|
+
var e = this, t = this.documentServerUrl;
|
|
170
|
+
t.endsWith("/") || (t += "/");
|
|
171
|
+
var n = "".concat(t, "web-apps/apps/api/documents/api.js");
|
|
172
|
+
W(n, "onlyoffice-api-script").then(function() {
|
|
173
|
+
return e.onLoad();
|
|
174
|
+
}).catch(function() {
|
|
175
|
+
e.onError(-2);
|
|
176
|
+
});
|
|
177
|
+
},
|
|
178
|
+
unmounted: function() {
|
|
179
|
+
var e, t = this.id || "";
|
|
180
|
+
!((e = window == null ? void 0 : window.DocEditor) === null || e === void 0) && e.instances[t] && (window.DocEditor.instances[t].destroyEditor(), window.DocEditor.instances[t] = void 0);
|
|
181
|
+
},
|
|
182
|
+
watch: {
|
|
183
|
+
config: {
|
|
184
|
+
handler: function(e, t) {
|
|
185
|
+
this.onChangeProps();
|
|
186
|
+
},
|
|
187
|
+
deep: !0
|
|
188
|
+
},
|
|
189
|
+
document_fileType: function(e, t) {
|
|
190
|
+
this.onChangeProps();
|
|
191
|
+
},
|
|
192
|
+
document_title: function(e, t) {
|
|
193
|
+
this.onChangeProps();
|
|
194
|
+
},
|
|
195
|
+
documentType: function(e, t) {
|
|
196
|
+
this.onChangeProps();
|
|
197
|
+
},
|
|
198
|
+
editorConfig_lang: function(e, t) {
|
|
199
|
+
this.onChangeProps();
|
|
200
|
+
},
|
|
201
|
+
height: function(e, t) {
|
|
202
|
+
this.onChangeProps();
|
|
203
|
+
},
|
|
204
|
+
type: function(e, t) {
|
|
205
|
+
this.onChangeProps();
|
|
206
|
+
},
|
|
207
|
+
width: function(e, t) {
|
|
208
|
+
this.onChangeProps();
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
methods: {
|
|
212
|
+
onLoad: function() {
|
|
213
|
+
var e, t;
|
|
214
|
+
try {
|
|
215
|
+
var n = this.id || "";
|
|
216
|
+
if (window.DocsAPI || this.onError(-3), !((e = window == null ? void 0 : window.DocEditor) === null || e === void 0) && e.instances[n]) {
|
|
217
|
+
console.log("Skip loading. Instance already exists", n);
|
|
218
|
+
return;
|
|
219
|
+
}
|
|
220
|
+
!((t = window == null ? void 0 : window.DocEditor) === null || t === void 0) && t.instances || (window.DocEditor = { instances: {} });
|
|
221
|
+
var i = Object.assign({
|
|
222
|
+
document: {
|
|
223
|
+
fileType: this.document_fileType,
|
|
224
|
+
title: this.document_title
|
|
225
|
+
},
|
|
226
|
+
documentType: this.documentType,
|
|
227
|
+
editorConfig: {
|
|
228
|
+
lang: this.editorConfig_lang
|
|
229
|
+
},
|
|
230
|
+
events: {
|
|
231
|
+
onAppReady: this.onAppReady,
|
|
232
|
+
onDocumentStateChange: this.events_onDocumentStateChange,
|
|
233
|
+
onMetaChange: this.events_onMetaChange,
|
|
234
|
+
onDocumentReady: this.events_onDocumentReady,
|
|
235
|
+
onInfo: this.events_onInfo,
|
|
236
|
+
onWarning: this.events_onWarning,
|
|
237
|
+
onError: this.events_onError,
|
|
238
|
+
onRequestSharingSettings: this.events_onRequestSharingSettings,
|
|
239
|
+
onRequestRename: this.events_onRequestRename,
|
|
240
|
+
onMakeActionLink: this.events_onMakeActionLink,
|
|
241
|
+
onRequestInsertImage: this.events_onRequestInsertImage,
|
|
242
|
+
onRequestSaveAs: this.events_onRequestSaveAs,
|
|
243
|
+
onRequestMailMergeRecipients: this.events_onRequestMailMergeRecipients,
|
|
244
|
+
onRequestCompareFile: this.events_onRequestCompareFile,
|
|
245
|
+
onRequestEditRights: this.events_onRequestEditRights,
|
|
246
|
+
onRequestHistory: this.events_onRequestHistory,
|
|
247
|
+
onRequestHistoryClose: this.events_onRequestHistoryClose,
|
|
248
|
+
onRequestHistoryData: this.events_onRequestHistoryData,
|
|
249
|
+
onRequestRestore: this.events_onRequestRestore
|
|
250
|
+
},
|
|
251
|
+
height: this.height,
|
|
252
|
+
type: this.type,
|
|
253
|
+
width: this.width
|
|
254
|
+
}, this.config || {}), s = window.DocsAPI.DocEditor(n, i);
|
|
255
|
+
window.DocEditor.instances[n] = s;
|
|
256
|
+
} catch (o) {
|
|
257
|
+
console.error(o), this.onError(-1);
|
|
258
|
+
}
|
|
259
|
+
},
|
|
260
|
+
onError: function(e) {
|
|
261
|
+
var t;
|
|
262
|
+
switch (e) {
|
|
263
|
+
case -2:
|
|
264
|
+
t = "Error load DocsAPI from " + this.documentServerUrl;
|
|
265
|
+
break;
|
|
266
|
+
case -3:
|
|
267
|
+
t = "DocsAPI is not defined";
|
|
268
|
+
break;
|
|
269
|
+
default:
|
|
270
|
+
t = "Unknown error loading component", e = -1;
|
|
271
|
+
}
|
|
272
|
+
typeof this.onLoadComponentError > "u" ? console.error(t) : this.onLoadComponentError(e, t);
|
|
273
|
+
},
|
|
274
|
+
onAppReady: function() {
|
|
275
|
+
var e = this.id || "";
|
|
276
|
+
this.events_onAppReady(window.DocEditor.instances[e]);
|
|
277
|
+
},
|
|
278
|
+
onChangeProps: function() {
|
|
279
|
+
var e, t = this.id || "";
|
|
280
|
+
!((e = window == null ? void 0 : window.DocEditor) === null || e === void 0) && e.instances[t] && (window.DocEditor.instances[t].destroyEditor(), window.DocEditor.instances[t] = void 0, console.log("Important props have been changed. Load new Editor."), this.onLoad());
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
});
|
|
284
|
+
const K = ["id"];
|
|
285
|
+
function J(e, t, n, i, s, o) {
|
|
286
|
+
return u(), g("div", { id: e.id }, null, 8, K);
|
|
287
|
+
}
|
|
288
|
+
V.render = J;
|
|
289
|
+
V.__file = "src/components/DocumentEditor.vue";
|
|
290
|
+
const X = /* @__PURE__ */ I({
|
|
291
|
+
__name: "IkOnlyOffice",
|
|
292
|
+
props: {
|
|
293
|
+
// 文件服务器的服务的地址
|
|
294
|
+
documentServerUrl: {
|
|
295
|
+
type: String,
|
|
296
|
+
default: ""
|
|
297
|
+
},
|
|
298
|
+
// 当前onlyoffice的模式 (edit 编辑模式 view是查看模式)
|
|
299
|
+
mode: {
|
|
300
|
+
type: String,
|
|
301
|
+
default: ""
|
|
302
|
+
},
|
|
303
|
+
// 配置项
|
|
304
|
+
configOptions: {
|
|
305
|
+
type: Object,
|
|
306
|
+
default: () => {
|
|
307
|
+
}
|
|
308
|
+
},
|
|
309
|
+
// 元素的高度
|
|
310
|
+
officeHeight: {
|
|
311
|
+
type: String,
|
|
312
|
+
default: "100%"
|
|
313
|
+
},
|
|
314
|
+
// 加密后的token
|
|
315
|
+
token: {
|
|
316
|
+
type: String,
|
|
317
|
+
default: ""
|
|
318
|
+
}
|
|
319
|
+
},
|
|
320
|
+
setup(e) {
|
|
321
|
+
var s, o, r, h;
|
|
322
|
+
const t = e, n = E({
|
|
323
|
+
width: "100%",
|
|
324
|
+
height: "100%",
|
|
325
|
+
document: (s = t.configOptions) == null ? void 0 : s.document,
|
|
326
|
+
// word cell(表格) slide(PPT)
|
|
327
|
+
documentType: (o = t.configOptions) == null ? void 0 : o.documentType,
|
|
328
|
+
editorConfig: {
|
|
329
|
+
callbackUrl: (h = (r = t.configOptions) == null ? void 0 : r.editorConfig) == null ? void 0 : h.callbackUrl,
|
|
330
|
+
// 保存的回调函数
|
|
331
|
+
lang: "zh-CN",
|
|
332
|
+
mode: t.mode,
|
|
333
|
+
// 强制保存
|
|
334
|
+
customization: {
|
|
335
|
+
forcesave: !0,
|
|
336
|
+
autosave: !0
|
|
337
|
+
}
|
|
338
|
+
},
|
|
339
|
+
// 权限
|
|
340
|
+
permissions: {
|
|
341
|
+
comment: !0,
|
|
342
|
+
commentGroups: {
|
|
343
|
+
edit: ["Group1"],
|
|
344
|
+
remove: ["Group1"],
|
|
345
|
+
view: ""
|
|
346
|
+
},
|
|
347
|
+
copy: !0,
|
|
348
|
+
deleteCommentAuthorOnly: !0,
|
|
349
|
+
download: !0,
|
|
350
|
+
edit: !0,
|
|
351
|
+
editCommentAuthorOnly: !0,
|
|
352
|
+
fillForms: !0,
|
|
353
|
+
modifyContentControl: !0,
|
|
354
|
+
modifyFilter: !0,
|
|
355
|
+
print: !0,
|
|
356
|
+
review: !0,
|
|
357
|
+
reviewGroups: ["Group1", "Group2", "Group3"],
|
|
358
|
+
userInfoGroups: ["Group1"]
|
|
359
|
+
},
|
|
360
|
+
mode: t.mode,
|
|
361
|
+
token: t.token
|
|
362
|
+
}), i = () => {
|
|
363
|
+
console.log("文档加载中");
|
|
364
|
+
};
|
|
365
|
+
return (k, a) => (u(), g(
|
|
366
|
+
"div",
|
|
367
|
+
{
|
|
368
|
+
style: M({ height: t.officeHeight })
|
|
369
|
+
},
|
|
370
|
+
[
|
|
371
|
+
O(P(V), {
|
|
372
|
+
id: `${(/* @__PURE__ */ new Date()).getTime()}`,
|
|
373
|
+
ref: "editorRef",
|
|
374
|
+
"document-server-url": e.documentServerUrl,
|
|
375
|
+
config: n.value,
|
|
376
|
+
events_onDocumentReady: i
|
|
377
|
+
}, null, 8, ["id", "document-server-url", "config"])
|
|
378
|
+
],
|
|
379
|
+
4
|
|
380
|
+
/* STYLE */
|
|
381
|
+
));
|
|
382
|
+
}
|
|
383
|
+
});
|
|
384
|
+
const x = (e, t) => {
|
|
385
|
+
const n = e.__vccOpts || e;
|
|
386
|
+
for (const [i, s] of t)
|
|
387
|
+
n[i] = s;
|
|
388
|
+
return n;
|
|
389
|
+
}, Q = /* @__PURE__ */ x(X, [["__scopeId", "data-v-58129d20"]]), Y = $(Q), Z = Y, L = (e) => (H("data-v-af8d674c"), e = e(), N(), e), ee = { class: "template-data" }, te = { class: "operate-btn" }, ne = ["onClick"], oe = ["onClick"], ie = { class: "m-12 point" }, ae = { class: "flex" }, se = ["onClick"], re = /* @__PURE__ */ L(() => /* @__PURE__ */ d(
|
|
390
|
+
"i",
|
|
391
|
+
{ class: "icon-icon_particulars iconfont tips" },
|
|
392
|
+
null,
|
|
393
|
+
-1
|
|
394
|
+
/* HOISTED */
|
|
395
|
+
)), le = /* @__PURE__ */ L(() => /* @__PURE__ */ d(
|
|
396
|
+
"p",
|
|
397
|
+
null,
|
|
398
|
+
"鼠标右键选择操作的数据类型",
|
|
399
|
+
-1
|
|
400
|
+
/* HOISTED */
|
|
401
|
+
)), ce = { class: "flex data-block" }, de = { class: "operate-btn" }, ue = ["onClick"], pe = ["onClick"], he = { class: "operate-btn" }, fe = ["onClick"], _e = ["onClick"], ve = ["onClick"], me = ["onClick"], ye = /* @__PURE__ */ I({
|
|
402
|
+
__name: "templateOfficeData",
|
|
403
|
+
props: {
|
|
404
|
+
// 详情数据
|
|
405
|
+
data: {
|
|
406
|
+
type: Array,
|
|
407
|
+
default: () => []
|
|
408
|
+
},
|
|
409
|
+
// 标题是否能编辑,删除
|
|
410
|
+
isShowTitleOperate: {
|
|
411
|
+
type: Boolean,
|
|
412
|
+
default: !1
|
|
413
|
+
},
|
|
414
|
+
//内容是否能编辑和删除
|
|
415
|
+
isShowContentOperate: {
|
|
416
|
+
type: Boolean,
|
|
417
|
+
default: !1
|
|
418
|
+
},
|
|
419
|
+
// 映射的属性
|
|
420
|
+
defaultProps: {
|
|
421
|
+
type: Object,
|
|
422
|
+
default: () => {
|
|
423
|
+
}
|
|
424
|
+
}
|
|
425
|
+
},
|
|
426
|
+
emits: ["handleTitleEdit", "handleTitleDel", "handleGetTitleData", "handleDataBlockEdit", "handleDataBlockDel", "handleChooseDataBlock", "handleDifferentTypeDataBlock"],
|
|
427
|
+
setup(e, { emit: t }) {
|
|
428
|
+
const n = e, i = t, s = (c) => {
|
|
429
|
+
i("handleTitleEdit", c);
|
|
430
|
+
}, o = (c) => {
|
|
431
|
+
i("handleTitleDel", c);
|
|
432
|
+
}, r = (c) => {
|
|
433
|
+
i("handleGetTitleData", c);
|
|
434
|
+
}, h = (c) => {
|
|
435
|
+
i("handleDataBlockEdit", c);
|
|
436
|
+
}, k = (c) => {
|
|
437
|
+
i("handleDataBlockDel", c);
|
|
438
|
+
}, a = (c, w) => {
|
|
439
|
+
for (const y of v.value)
|
|
440
|
+
y.children.forEach((p) => p.isChoose = !1);
|
|
441
|
+
w.isChoose = !0, i("handleChooseDataBlock", c, w);
|
|
442
|
+
}, f = (c, w) => {
|
|
443
|
+
i("handleDifferentTypeDataBlock", c, w);
|
|
444
|
+
}, _ = (c) => {
|
|
445
|
+
let w = c.map((y) => ({
|
|
446
|
+
name: y[n.defaultProps.name],
|
|
447
|
+
children: y[n.defaultProps.children].map((p) => ({
|
|
448
|
+
childName: p[n.defaultProps.childName],
|
|
449
|
+
childId: p[n.defaultProps.childId]
|
|
450
|
+
}))
|
|
451
|
+
}));
|
|
452
|
+
v.value = w;
|
|
453
|
+
}, v = E(n.data);
|
|
454
|
+
return U(
|
|
455
|
+
() => n.data,
|
|
456
|
+
(c) => {
|
|
457
|
+
_(c);
|
|
458
|
+
},
|
|
459
|
+
{ immediate: !0 }
|
|
460
|
+
), document.addEventListener("contextmenu", (c) => {
|
|
461
|
+
n.isShowTitleOperate && c.preventDefault();
|
|
462
|
+
}), (c, w) => {
|
|
463
|
+
const y = D("el-popover");
|
|
464
|
+
return u(), g("div", ee, [
|
|
465
|
+
(u(!0), g(
|
|
466
|
+
T,
|
|
467
|
+
null,
|
|
468
|
+
F(v.value, (p, q) => (u(), g("div", {
|
|
469
|
+
key: q,
|
|
470
|
+
class: "mt-4"
|
|
471
|
+
}, [
|
|
472
|
+
e.isShowTitleOperate ? (u(), C(
|
|
473
|
+
y,
|
|
474
|
+
{
|
|
475
|
+
key: 0,
|
|
476
|
+
"popper-class": "sort-popper",
|
|
477
|
+
placement: "right",
|
|
478
|
+
width: "60",
|
|
479
|
+
trigger: "contextmenu"
|
|
480
|
+
},
|
|
481
|
+
{
|
|
482
|
+
reference: m(() => [
|
|
483
|
+
d(
|
|
484
|
+
"span",
|
|
485
|
+
ie,
|
|
486
|
+
R(p.name),
|
|
487
|
+
1
|
|
488
|
+
/* TEXT */
|
|
489
|
+
)
|
|
490
|
+
]),
|
|
491
|
+
default: m(() => [
|
|
492
|
+
d("div", te, [
|
|
493
|
+
d("p", {
|
|
494
|
+
class: "point",
|
|
495
|
+
style: { margin: "0" },
|
|
496
|
+
onClick: (l) => s(p)
|
|
497
|
+
}, "编辑", 8, ne),
|
|
498
|
+
d("p", {
|
|
499
|
+
style: { color: "var(--ik-error)", margin: "0" },
|
|
500
|
+
class: "point",
|
|
501
|
+
onClick: (l) => o(p)
|
|
502
|
+
}, " 删除 ", 8, oe)
|
|
503
|
+
])
|
|
504
|
+
]),
|
|
505
|
+
_: 2
|
|
506
|
+
/* DYNAMIC */
|
|
507
|
+
},
|
|
508
|
+
1024
|
|
509
|
+
/* DYNAMIC_SLOTS */
|
|
510
|
+
)) : (u(), g(
|
|
511
|
+
T,
|
|
512
|
+
{ key: 1 },
|
|
513
|
+
[
|
|
514
|
+
S(" 不能操作的标题 "),
|
|
515
|
+
d("div", ae, [
|
|
516
|
+
d("p", {
|
|
517
|
+
class: "mb-2 point",
|
|
518
|
+
onClick: (l) => r(p)
|
|
519
|
+
}, R(p.name), 9, se),
|
|
520
|
+
p.resultType === "LIST" ? (u(), C(y, {
|
|
521
|
+
key: 0,
|
|
522
|
+
placement: "right",
|
|
523
|
+
width: 210,
|
|
524
|
+
trigger: "hover"
|
|
525
|
+
}, {
|
|
526
|
+
reference: m(() => [
|
|
527
|
+
re
|
|
528
|
+
]),
|
|
529
|
+
default: m(() => [
|
|
530
|
+
le
|
|
531
|
+
]),
|
|
532
|
+
_: 1
|
|
533
|
+
/* STABLE */
|
|
534
|
+
})) : S("v-if", !0)
|
|
535
|
+
])
|
|
536
|
+
],
|
|
537
|
+
2112
|
|
538
|
+
/* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
|
|
539
|
+
)),
|
|
540
|
+
S(" 标题下的内容 "),
|
|
541
|
+
d("div", ce, [
|
|
542
|
+
(u(!0), g(
|
|
543
|
+
T,
|
|
544
|
+
null,
|
|
545
|
+
F(p.children, (l, B) => (u(), g("div", {
|
|
546
|
+
key: B,
|
|
547
|
+
style: { "flex-grow": "1" }
|
|
548
|
+
}, [
|
|
549
|
+
n.isShowContentOperate && p.resultType === "LIST" ? (u(), C(
|
|
550
|
+
y,
|
|
551
|
+
{
|
|
552
|
+
key: 0,
|
|
553
|
+
"popper-class": "operate-popper",
|
|
554
|
+
placement: "bottom-end",
|
|
555
|
+
width: "60",
|
|
556
|
+
trigger: "contextmenu"
|
|
557
|
+
},
|
|
558
|
+
{
|
|
559
|
+
reference: m(() => [
|
|
560
|
+
d(
|
|
561
|
+
"p",
|
|
562
|
+
{
|
|
563
|
+
class: A([{ "choose-item": l.isChoose }, "item-block"]),
|
|
564
|
+
title: "鼠标右键选择操作的数据类型"
|
|
565
|
+
},
|
|
566
|
+
R(l.chileName),
|
|
567
|
+
3
|
|
568
|
+
/* TEXT, CLASS */
|
|
569
|
+
)
|
|
570
|
+
]),
|
|
571
|
+
default: m(() => [
|
|
572
|
+
d("div", de, [
|
|
573
|
+
d("p", {
|
|
574
|
+
class: "point",
|
|
575
|
+
style: { margin: "0" },
|
|
576
|
+
onClick: (b) => f(l, "TABLE")
|
|
577
|
+
}, "表格", 8, ue),
|
|
578
|
+
d("p", {
|
|
579
|
+
class: "point",
|
|
580
|
+
style: { margin: "0" },
|
|
581
|
+
onClick: (b) => f(l, "LIST")
|
|
582
|
+
}, "列表", 8, pe)
|
|
583
|
+
])
|
|
584
|
+
]),
|
|
585
|
+
_: 2
|
|
586
|
+
/* DYNAMIC */
|
|
587
|
+
},
|
|
588
|
+
1024
|
|
589
|
+
/* DYNAMIC_SLOTS */
|
|
590
|
+
)) : S("v-if", !0),
|
|
591
|
+
n.isShowContentOperate ? (u(), C(
|
|
592
|
+
y,
|
|
593
|
+
{
|
|
594
|
+
key: 1,
|
|
595
|
+
"popper-class": "operate-popper",
|
|
596
|
+
placement: "bottom-end",
|
|
597
|
+
width: "60",
|
|
598
|
+
trigger: "contextmenu"
|
|
599
|
+
},
|
|
600
|
+
{
|
|
601
|
+
reference: m(() => [
|
|
602
|
+
d("p", {
|
|
603
|
+
class: A([{ "choose-item": l.isChoose }, "item-block"]),
|
|
604
|
+
onClick: (b) => a(p, l)
|
|
605
|
+
}, R(l.childName), 11, ve)
|
|
606
|
+
]),
|
|
607
|
+
default: m(() => [
|
|
608
|
+
d("div", he, [
|
|
609
|
+
d("p", {
|
|
610
|
+
class: "point",
|
|
611
|
+
style: { margin: "0" },
|
|
612
|
+
onClick: (b) => h(l)
|
|
613
|
+
}, "编辑", 8, fe),
|
|
614
|
+
d("p", {
|
|
615
|
+
style: { color: "var(--ik-error)", cursor: "pointer", margin: "0" },
|
|
616
|
+
onClick: (b) => k(l)
|
|
617
|
+
}, " 删除 ", 8, _e)
|
|
618
|
+
])
|
|
619
|
+
]),
|
|
620
|
+
_: 2
|
|
621
|
+
/* DYNAMIC */
|
|
622
|
+
},
|
|
623
|
+
1024
|
|
624
|
+
/* DYNAMIC_SLOTS */
|
|
625
|
+
)) : (u(), g("p", {
|
|
626
|
+
key: 2,
|
|
627
|
+
class: A([{ "choose-item": l.isChoose }, "item-block"]),
|
|
628
|
+
onClick: (b) => a(p, l)
|
|
629
|
+
}, R(l.childName), 11, me))
|
|
630
|
+
]))),
|
|
631
|
+
128
|
|
632
|
+
/* KEYED_FRAGMENT */
|
|
633
|
+
))
|
|
634
|
+
])
|
|
635
|
+
]))),
|
|
636
|
+
128
|
|
637
|
+
/* KEYED_FRAGMENT */
|
|
638
|
+
))
|
|
639
|
+
]);
|
|
640
|
+
};
|
|
641
|
+
}
|
|
642
|
+
});
|
|
643
|
+
const ge = /* @__PURE__ */ x(ye, [["__scopeId", "data-v-af8d674c"]]), we = { class: "template-config" }, ke = { class: "template-config-data" }, Ce = { class: "template-panel" }, Se = /* @__PURE__ */ I({
|
|
644
|
+
__name: "IkTemplateOfficeConfig",
|
|
645
|
+
props: {
|
|
646
|
+
// 标题
|
|
647
|
+
title: {
|
|
648
|
+
type: String,
|
|
649
|
+
default: "模板配置"
|
|
650
|
+
},
|
|
651
|
+
// 显示
|
|
652
|
+
visible: {
|
|
653
|
+
type: Boolean,
|
|
654
|
+
default: !1
|
|
655
|
+
},
|
|
656
|
+
// onlyOffice的配置项
|
|
657
|
+
onlyOfficeConfig: {
|
|
658
|
+
type: Object,
|
|
659
|
+
default: () => {
|
|
660
|
+
}
|
|
661
|
+
},
|
|
662
|
+
// 是否展示tabs
|
|
663
|
+
isShowTabs: {
|
|
664
|
+
type: Boolean,
|
|
665
|
+
default: !0
|
|
666
|
+
},
|
|
667
|
+
// tabs下的搜索框
|
|
668
|
+
isShowSearchCondition: {
|
|
669
|
+
type: Boolean,
|
|
670
|
+
default: !0
|
|
671
|
+
},
|
|
672
|
+
// TABS的数据
|
|
673
|
+
tabsData: {
|
|
674
|
+
type: Array,
|
|
675
|
+
default: () => []
|
|
676
|
+
},
|
|
677
|
+
// 每个tabs下面的表格数据
|
|
678
|
+
tableData: {
|
|
679
|
+
type: Array,
|
|
680
|
+
default: () => []
|
|
681
|
+
},
|
|
682
|
+
// office的文档服务器地址
|
|
683
|
+
documentServerUrl: {
|
|
684
|
+
type: String,
|
|
685
|
+
default: ""
|
|
686
|
+
},
|
|
687
|
+
// onlyOffice的加密token
|
|
688
|
+
jwtToken: {
|
|
689
|
+
type: String,
|
|
690
|
+
default: ""
|
|
691
|
+
},
|
|
692
|
+
// 内容展示的高度
|
|
693
|
+
contentHeight: {
|
|
694
|
+
type: String,
|
|
695
|
+
default: "650px"
|
|
696
|
+
},
|
|
697
|
+
// 映射的属性
|
|
698
|
+
defaultProps: {
|
|
699
|
+
type: Object,
|
|
700
|
+
default: () => {
|
|
701
|
+
}
|
|
702
|
+
},
|
|
703
|
+
// 标题是否能编辑,删除
|
|
704
|
+
isShowTitleOperate: {
|
|
705
|
+
type: Boolean,
|
|
706
|
+
default: !1
|
|
707
|
+
},
|
|
708
|
+
//内容是否能编辑和删除
|
|
709
|
+
isShowContentOperate: {
|
|
710
|
+
type: Boolean,
|
|
711
|
+
default: !1
|
|
712
|
+
}
|
|
713
|
+
},
|
|
714
|
+
emits: ["handleSearchDataBlock", "handleClickBlockData"],
|
|
715
|
+
setup(e, { expose: t, emit: n }) {
|
|
716
|
+
j((_) => ({
|
|
717
|
+
f1632ab6: e.contentHeight
|
|
718
|
+
}));
|
|
719
|
+
const i = e, s = n, o = E(i.tabsData[0].id), r = (_) => {
|
|
720
|
+
h.value = "", o.value = _, _ && s("handleSearchDataBlock", "", o.value);
|
|
721
|
+
}, h = E(""), k = () => {
|
|
722
|
+
s("handleSearchDataBlock", h.value, o.value);
|
|
723
|
+
}, a = (_, v) => {
|
|
724
|
+
s("handleClickBlockData", _, v);
|
|
725
|
+
};
|
|
726
|
+
return t({ handleSendMessage: (_) => {
|
|
727
|
+
window[0][0].postMessage(JSON.stringify({ type: "INSERT_TEXT", text: _ }), "*");
|
|
728
|
+
} }), (_, v) => {
|
|
729
|
+
const c = D("el-tab-pane"), w = D("el-tabs"), y = D("el-input"), p = D("el-col"), q = D("el-row");
|
|
730
|
+
return u(), g("div", we, [
|
|
731
|
+
O(q, { gutter: 10 }, {
|
|
732
|
+
default: m(() => [
|
|
733
|
+
O(p, { span: 6 }, {
|
|
734
|
+
default: m(() => [
|
|
735
|
+
d("div", ke, [
|
|
736
|
+
i.isShowTabs ? (u(), C(w, {
|
|
737
|
+
key: 0,
|
|
738
|
+
modelValue: o.value,
|
|
739
|
+
"onUpdate:modelValue": v[0] || (v[0] = (l) => o.value = l),
|
|
740
|
+
onTabClick: v[1] || (v[1] = (l) => r(l.props.name))
|
|
741
|
+
}, {
|
|
742
|
+
default: m(() => [
|
|
743
|
+
(u(!0), g(
|
|
744
|
+
T,
|
|
745
|
+
null,
|
|
746
|
+
F(i.tabsData, (l, B) => (u(), C(c, {
|
|
747
|
+
key: B,
|
|
748
|
+
label: l.label,
|
|
749
|
+
name: l.id
|
|
750
|
+
}, null, 8, ["label", "name"]))),
|
|
751
|
+
128
|
|
752
|
+
/* KEYED_FRAGMENT */
|
|
753
|
+
))
|
|
754
|
+
]),
|
|
755
|
+
_: 1
|
|
756
|
+
/* STABLE */
|
|
757
|
+
}, 8, ["modelValue"])) : S("v-if", !0),
|
|
758
|
+
i.isShowSearchCondition ? (u(), C(y, {
|
|
759
|
+
key: 1,
|
|
760
|
+
modelValue: h.value,
|
|
761
|
+
"onUpdate:modelValue": v[2] || (v[2] = (l) => h.value = l),
|
|
762
|
+
placeholder: "请输入关键字",
|
|
763
|
+
clearable: "",
|
|
764
|
+
onInput: v[3] || (v[3] = (l) => k())
|
|
765
|
+
}, null, 8, ["modelValue"])) : S("v-if", !0),
|
|
766
|
+
O(ge, {
|
|
767
|
+
data: i.tableData,
|
|
768
|
+
type: o.value,
|
|
769
|
+
defaultProps: i.defaultProps,
|
|
770
|
+
onHandleChooseDataBlock: a,
|
|
771
|
+
isShowTitleOperate: i.isShowTitleOperate,
|
|
772
|
+
isShowContentOperate: i.isShowContentOperate
|
|
773
|
+
}, null, 8, ["data", "type", "defaultProps", "isShowTitleOperate", "isShowContentOperate"])
|
|
774
|
+
])
|
|
775
|
+
]),
|
|
776
|
+
_: 1
|
|
777
|
+
/* STABLE */
|
|
778
|
+
}),
|
|
779
|
+
O(p, { span: 18 }, {
|
|
780
|
+
default: m(() => [
|
|
781
|
+
d("div", Ce, [
|
|
782
|
+
i.visible ? (u(), C(P(Z), {
|
|
783
|
+
key: 0,
|
|
784
|
+
"config-options": i.onlyOfficeConfig,
|
|
785
|
+
documentServerUrl: i.documentServerUrl,
|
|
786
|
+
token: i.jwtToken
|
|
787
|
+
}, null, 8, ["config-options", "documentServerUrl", "token"])) : S("v-if", !0)
|
|
788
|
+
])
|
|
789
|
+
]),
|
|
790
|
+
_: 1
|
|
791
|
+
/* STABLE */
|
|
792
|
+
})
|
|
793
|
+
]),
|
|
794
|
+
_: 1
|
|
795
|
+
/* STABLE */
|
|
796
|
+
})
|
|
797
|
+
]);
|
|
798
|
+
};
|
|
799
|
+
}
|
|
800
|
+
});
|
|
801
|
+
const De = /* @__PURE__ */ x(Se, [["__scopeId", "data-v-d31d0157"]]), Re = $(De);
|
|
802
|
+
export {
|
|
803
|
+
Re as IkTemplateOfficeConfig,
|
|
804
|
+
Re as default
|
|
805
|
+
};
|