free-fe-core-modules 0.0.1 → 0.0.2
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/components/Basic/SummaryHead.vue +0 -2
- package/components/Dialog/BasicDialog.vue +10 -77
- package/components/Dialog/index.js +44 -34
- package/components/Dialog/index2.js +44 -0
- package/components/SelectLocales/index.vue +3 -4
- package/components/StickyButtons/index.vue +2 -2
- package/components/ThemeSwitch/index.vue +7 -3
- package/field-components/Fields/File.vue +2 -2
- package/field-components/Fields/FileList.vue +3 -3
- package/field-components/Fields/FileListCombined.vue +2 -2
- package/field-components/Fields/Image.vue +2 -2
- package/field-components/Fields/Select.vue +0 -1
- package/index.js +4 -19
- package/package.json +1 -1
- package/view/dict/index.vue +0 -2
- package/view/menu/index.vue +0 -5
- package/components/Dialog/index1.js +0 -49
|
@@ -85,7 +85,6 @@ export default defineComponent({
|
|
|
85
85
|
has_multiple_head: { type: Boolean, default: false },
|
|
86
86
|
},
|
|
87
87
|
created() {
|
|
88
|
-
this.Bus?.$on('update_summary_head', this.refreshData);
|
|
89
88
|
},
|
|
90
89
|
methods: {
|
|
91
90
|
filteredValue(item) {
|
|
@@ -137,7 +136,6 @@ export default defineComponent({
|
|
|
137
136
|
},
|
|
138
137
|
},
|
|
139
138
|
beforeUnmount() {
|
|
140
|
-
this.Bus?.$off('update_summary_head', this.refreshData);
|
|
141
139
|
},
|
|
142
140
|
});
|
|
143
141
|
</script>
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
<q-card
|
|
7
7
|
:class="['basic-dialog-card', dialogClass]"
|
|
8
8
|
:style="`min-height: ${size.h}px;
|
|
9
|
-
|
|
9
|
+
width: ${size.w}px; min-width: ${size.w}`"
|
|
10
10
|
>
|
|
11
11
|
<q-btn
|
|
12
12
|
class="float-right close-dialog-button"
|
|
@@ -32,10 +32,6 @@
|
|
|
32
32
|
v-if="tips"
|
|
33
33
|
class="tips"
|
|
34
34
|
>{{ tips }}</div>
|
|
35
|
-
<!-- <div
|
|
36
|
-
v-if="warning"
|
|
37
|
-
class="warning"
|
|
38
|
-
>{{ warning }}</div> -->
|
|
39
35
|
<div
|
|
40
36
|
v-if="warning"
|
|
41
37
|
class="warning no-wrap"
|
|
@@ -106,6 +102,8 @@
|
|
|
106
102
|
<script>
|
|
107
103
|
import mixins from 'free-fe-mixins';
|
|
108
104
|
import { defineComponent } from 'vue';
|
|
105
|
+
import FreeField from '../../field-components/components/FieldComponents.vue';
|
|
106
|
+
import EIcon from '../Basic/EIcon.vue';
|
|
109
107
|
|
|
110
108
|
export default defineComponent({
|
|
111
109
|
name: 'BasicDialog',
|
|
@@ -149,6 +147,12 @@ export default defineComponent({
|
|
|
149
147
|
fieldsData: { type: Object, default: () => ({}) },
|
|
150
148
|
fieldsClass: { type: String, default: '' },
|
|
151
149
|
dialogClass: { type: String, default: '' },
|
|
150
|
+
|
|
151
|
+
remove: { type: Function, default: () => {}}
|
|
152
|
+
},
|
|
153
|
+
components: {
|
|
154
|
+
FreeField,
|
|
155
|
+
EIcon,
|
|
152
156
|
},
|
|
153
157
|
data() {
|
|
154
158
|
return {
|
|
@@ -161,13 +165,6 @@ export default defineComponent({
|
|
|
161
165
|
reject: '',
|
|
162
166
|
};
|
|
163
167
|
},
|
|
164
|
-
// created() {
|
|
165
|
-
// if (this.visible) {
|
|
166
|
-
// this.show();
|
|
167
|
-
// } else {
|
|
168
|
-
// this.hide();
|
|
169
|
-
// }
|
|
170
|
-
// },
|
|
171
168
|
watch: {
|
|
172
169
|
visible() {
|
|
173
170
|
if (this.visible) {
|
|
@@ -200,7 +197,7 @@ export default defineComponent({
|
|
|
200
197
|
// following method is REQUIRED
|
|
201
198
|
// (don't change its name --> "show")
|
|
202
199
|
show() {
|
|
203
|
-
debugger
|
|
200
|
+
// debugger
|
|
204
201
|
this.$refs.dialog.show();
|
|
205
202
|
this.timeout_counter();
|
|
206
203
|
|
|
@@ -257,15 +254,6 @@ export default defineComponent({
|
|
|
257
254
|
this.remove();
|
|
258
255
|
}
|
|
259
256
|
},
|
|
260
|
-
// show_msg_box() {
|
|
261
|
-
// this.show();
|
|
262
|
-
// this.promise = new Promise((resolve, reject) => {
|
|
263
|
-
// this.resolve = resolve;
|
|
264
|
-
// this.reject = reject;
|
|
265
|
-
// });
|
|
266
|
-
|
|
267
|
-
// return this.promise;
|
|
268
|
-
// },
|
|
269
257
|
btnCancel() {
|
|
270
258
|
this.$emit('cancel');
|
|
271
259
|
|
|
@@ -280,12 +268,6 @@ export default defineComponent({
|
|
|
280
268
|
}
|
|
281
269
|
},
|
|
282
270
|
btn_ok() {
|
|
283
|
-
// // validate
|
|
284
|
-
// if (this.validateFunc && typeof this.validateFunc === 'function') {
|
|
285
|
-
// // now we only have such content, but later we might will have more
|
|
286
|
-
// this.textValid = this.validateFunc(this.textContent);
|
|
287
|
-
// if (!this.textValid) return;
|
|
288
|
-
// }
|
|
289
271
|
if (!this.validate()) {
|
|
290
272
|
return;
|
|
291
273
|
}
|
|
@@ -322,10 +304,6 @@ export default defineComponent({
|
|
|
322
304
|
}
|
|
323
305
|
}, 1000);
|
|
324
306
|
},
|
|
325
|
-
remove() {
|
|
326
|
-
this.$destroy();
|
|
327
|
-
document.body.removeChild(this.$el);
|
|
328
|
-
},
|
|
329
307
|
onInputFieldInput(field){
|
|
330
308
|
if(field.onInput) {
|
|
331
309
|
field.onInput(field);
|
|
@@ -394,49 +372,4 @@ export default defineComponent({
|
|
|
394
372
|
text-align: center;
|
|
395
373
|
color: red;
|
|
396
374
|
}
|
|
397
|
-
|
|
398
|
-
// .admin {
|
|
399
|
-
// margin-top: 10px;
|
|
400
|
-
// text-align: center;
|
|
401
|
-
// color: red;
|
|
402
|
-
// font-size: 12px;
|
|
403
|
-
// }
|
|
404
|
-
|
|
405
|
-
// .cancel-btn {
|
|
406
|
-
// background: rgba(255, 255, 255, 1);
|
|
407
|
-
// border: 1px solid rgba(74, 74, 74, 1);
|
|
408
|
-
// color: rgba(74, 74, 74, 1);
|
|
409
|
-
// }
|
|
410
|
-
|
|
411
|
-
// .cancel-btn:hover {
|
|
412
|
-
// background: rgba(0, 69, 156, 1);
|
|
413
|
-
// color: rgba(255, 255, 255, 1);
|
|
414
|
-
// border: 0;
|
|
415
|
-
// }
|
|
416
|
-
|
|
417
|
-
// .disabled-cancel-btn {
|
|
418
|
-
// background: rgba(255, 255, 255, 1);
|
|
419
|
-
// border: 1px solid rgba(155, 155, 155, 1);
|
|
420
|
-
// color: rgba(155, 155, 155, 1);
|
|
421
|
-
// }
|
|
422
|
-
|
|
423
|
-
// .ok-btn {
|
|
424
|
-
// background: rgba(24, 115, 220, 1);
|
|
425
|
-
// color: rgba(255, 255, 255, 1);
|
|
426
|
-
// }
|
|
427
|
-
|
|
428
|
-
// .ok-btn:hover {
|
|
429
|
-
// background: rgba(0, 69, 156, 1);
|
|
430
|
-
// color: rgba(255, 255, 255, 1);
|
|
431
|
-
// }
|
|
432
|
-
|
|
433
|
-
// .disabled-ok-btn {
|
|
434
|
-
// background: rgba(155, 155, 155, 1);
|
|
435
|
-
// color: rgba(255, 255, 255, 1);
|
|
436
|
-
// }
|
|
437
|
-
|
|
438
|
-
// .disabled-ok-btn:hover {
|
|
439
|
-
// background: rgba(155, 155, 155, 1);
|
|
440
|
-
// color: rgba(255, 255, 255, 1);
|
|
441
|
-
// }
|
|
442
375
|
</style>
|
|
@@ -1,38 +1,48 @@
|
|
|
1
|
-
import { createApp } from 'vue'
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
let $inst
|
|
5
|
-
// 创建挂载实例
|
|
6
|
-
let createMount = (opts) => {
|
|
7
|
-
const app = createApp(BasicDialog, {
|
|
8
|
-
...opts, modelValue: true,
|
|
9
|
-
remove () {
|
|
10
|
-
app.unmount(mountNode)
|
|
11
|
-
document.body.removeChild(mountNode)
|
|
12
|
-
}
|
|
13
|
-
})
|
|
14
|
-
return app.mount('#eis-dialog')
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
function MsgDialog (options = {}) {
|
|
18
|
-
if (typeof options === 'string') {
|
|
19
|
-
options = {content: options};
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
$inst = createMount(options)
|
|
23
|
-
|
|
24
|
-
return $inst.show()
|
|
25
|
-
.then((val) => {
|
|
26
|
-
return Promise.resolve(val);
|
|
27
|
-
})
|
|
28
|
-
.catch((err) => {
|
|
29
|
-
return Promise.reject(err);
|
|
30
|
-
});
|
|
31
|
-
}
|
|
1
|
+
import { createApp } from 'vue';
|
|
2
|
+
import Dialog from './BasicDialog.vue'
|
|
32
3
|
|
|
4
|
+
const MsgDialog = {};
|
|
33
5
|
MsgDialog.install = (app) => {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
6
|
+
let MsgDialogInstance;
|
|
7
|
+
const init = (opts) => {
|
|
8
|
+
const dialogApp = createApp(Dialog, {
|
|
9
|
+
...opts, modelValue: true,
|
|
10
|
+
remove: () => {
|
|
11
|
+
dialogApp.unmount();
|
|
12
|
+
}
|
|
13
|
+
});
|
|
14
|
+
|
|
15
|
+
dialogApp.config.globalProperties = app.config.globalProperties;
|
|
16
|
+
|
|
17
|
+
const { reload, ...appContext } = app._context;
|
|
18
|
+
Object.assign(dialogApp._context, appContext);
|
|
19
|
+
|
|
20
|
+
MsgDialogInstance = dialogApp.mount('#free-dialog');
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
app.config.globalProperties.$MsgDialog = (options) => {
|
|
24
|
+
const opts = {};
|
|
25
|
+
|
|
26
|
+
if (typeof options === 'string') {
|
|
27
|
+
opts.content = options;
|
|
28
|
+
} else if (typeof options === 'object') {
|
|
29
|
+
Object.assign(opts, options);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
if (!MsgDialogInstance) {
|
|
33
|
+
init(opts);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
return MsgDialogInstance.show()
|
|
37
|
+
.then((val) => {
|
|
38
|
+
MsgDialogInstance = null;
|
|
39
|
+
return Promise.resolve(val);
|
|
40
|
+
})
|
|
41
|
+
.catch((err) => {
|
|
42
|
+
MsgDialogInstance = null;
|
|
43
|
+
return Promise.reject(err);
|
|
44
|
+
});
|
|
45
|
+
};
|
|
46
|
+
};
|
|
37
47
|
|
|
38
48
|
export default MsgDialog;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { createApp } from 'vue';
|
|
2
|
+
import dialog from './BasicDialog.vue';
|
|
3
|
+
|
|
4
|
+
// 创建挂载实例
|
|
5
|
+
let createMount = (opts) => {
|
|
6
|
+
const app = createApp(dialog, {
|
|
7
|
+
...opts, modelValue: true,
|
|
8
|
+
// remove () {
|
|
9
|
+
// app.unmount(mountNode)
|
|
10
|
+
// document.body.removeChild(mountNode)
|
|
11
|
+
// }
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
return app.mount('#free-dialog')
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
function MsgDialog (options = {}) {
|
|
18
|
+
if (typeof options === 'string') {
|
|
19
|
+
options = {content: options};
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const $inst = createMount(options)
|
|
23
|
+
|
|
24
|
+
console.error($inst)
|
|
25
|
+
if (!$inst) {
|
|
26
|
+
console.error($inst)
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
return $inst.show()
|
|
31
|
+
.then((val) => {
|
|
32
|
+
return Promise.resolve(val);
|
|
33
|
+
})
|
|
34
|
+
.catch((err) => {
|
|
35
|
+
return Promise.reject(err);
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
MsgDialog.install = (app) => {
|
|
40
|
+
app.config.globalProperties.$MsgDialog = MsgDialog;
|
|
41
|
+
// app.provide('MsgDialog', MsgDialog)
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export default MsgDialog;
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
clickable
|
|
9
9
|
v-close-popup
|
|
10
10
|
@click="localeChanged(locale.locale)"
|
|
11
|
+
:active="$i18n.locale === locale.locale"
|
|
11
12
|
>
|
|
12
13
|
<q-item-section>{{locale.name}}</q-item-section>
|
|
13
14
|
</q-item>
|
|
@@ -30,10 +31,8 @@ export default defineComponent({
|
|
|
30
31
|
},
|
|
31
32
|
},
|
|
32
33
|
created() {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
// this.$i18n.locale = this.locales[0].locale;
|
|
36
|
-
// }
|
|
34
|
+
const appStore = useAppStore();
|
|
35
|
+
this.$i18n.locale = appStore.locale || (this.locales && (this.locales.length > 0) && this.locales[0]);
|
|
37
36
|
},
|
|
38
37
|
methods: {
|
|
39
38
|
localeChanged(l){
|
|
@@ -47,7 +47,7 @@ export default defineComponent({
|
|
|
47
47
|
emits: ['click'],
|
|
48
48
|
props: {
|
|
49
49
|
position: { type: String, default: 'bottom-right' },
|
|
50
|
-
offset: { type: Array, default: () => [36, 128
|
|
50
|
+
offset: { type: Array, default: () => [36, 128] },
|
|
51
51
|
fab: { type: Boolean, default: true },
|
|
52
52
|
fabIcon: { type: String, default: 'add' },
|
|
53
53
|
fabColor: { type: String, default: '' },
|
|
@@ -58,7 +58,7 @@ export default defineComponent({
|
|
|
58
58
|
},
|
|
59
59
|
data() {
|
|
60
60
|
return {
|
|
61
|
-
stickyOffset: [36, 128
|
|
61
|
+
stickyOffset: [36, 128],
|
|
62
62
|
draggingSticky: false,
|
|
63
63
|
};
|
|
64
64
|
},
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
clickable
|
|
15
15
|
v-close-popup
|
|
16
16
|
@click="theme = tm"
|
|
17
|
+
:active="theme === tm"
|
|
17
18
|
>
|
|
18
19
|
<q-item-section>{{$t(tm)}}</q-item-section>
|
|
19
20
|
</q-item>
|
|
@@ -25,6 +26,7 @@
|
|
|
25
26
|
|
|
26
27
|
<script>
|
|
27
28
|
import { defineComponent } from 'vue';
|
|
29
|
+
import useAppStore from '@/stores/app';
|
|
28
30
|
|
|
29
31
|
export default defineComponent({
|
|
30
32
|
name: 'ThemeSwitch',
|
|
@@ -65,13 +67,15 @@ export default defineComponent({
|
|
|
65
67
|
arr.push(`theme-${v}`);
|
|
66
68
|
|
|
67
69
|
appEle.className = arr.join(' ');
|
|
70
|
+
|
|
71
|
+
const appStore = useAppStore();
|
|
72
|
+
appStore.SET_THEME(v);
|
|
68
73
|
}
|
|
69
74
|
},
|
|
70
75
|
},
|
|
71
76
|
created() {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
}
|
|
77
|
+
const appStore = useAppStore();
|
|
78
|
+
this.theme = appStore.theme || (this.themes && (this.themes.length > 0) && this.themes[0]);
|
|
75
79
|
},
|
|
76
80
|
});
|
|
77
81
|
</script>
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
<a
|
|
46
46
|
class="ellipsis"
|
|
47
47
|
target="_blank"
|
|
48
|
-
:href="
|
|
48
|
+
:href="$filter('serverPath',file.id)"
|
|
49
49
|
:download="file.name"
|
|
50
50
|
>
|
|
51
51
|
{{ file.name }}
|
|
@@ -135,7 +135,7 @@
|
|
|
135
135
|
<a
|
|
136
136
|
v-if="file && file.id"
|
|
137
137
|
target="_blank"
|
|
138
|
-
:href="
|
|
138
|
+
:href="$filter('serverPath',file.id)"
|
|
139
139
|
:download="file.name">
|
|
140
140
|
{{ file.name }}
|
|
141
141
|
</a>
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
<a
|
|
47
47
|
class="ellipsis"
|
|
48
48
|
target="_blank"
|
|
49
|
-
:href="
|
|
49
|
+
:href="$filter('serverPath',file.id)"
|
|
50
50
|
:download="file.name"
|
|
51
51
|
>
|
|
52
52
|
{{ file.name }}
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
<span class="file-name full-width ellipsis">
|
|
110
110
|
<a
|
|
111
111
|
target="_blank"
|
|
112
|
-
:href="
|
|
112
|
+
:href="$filter('serverPath',file.id)"
|
|
113
113
|
:download="file.name">
|
|
114
114
|
{{ file.name }}
|
|
115
115
|
</a>
|
|
@@ -160,7 +160,7 @@
|
|
|
160
160
|
<span class="file-name full-width ellipsis">
|
|
161
161
|
<a
|
|
162
162
|
target="_blank"
|
|
163
|
-
:href="
|
|
163
|
+
:href="$filter('serverPath',file.id)"
|
|
164
164
|
:download="file.name">
|
|
165
165
|
{{ file.name }}
|
|
166
166
|
</a>
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
<span class="file-name full-width ellipsis">
|
|
31
31
|
<a
|
|
32
32
|
target="_blank"
|
|
33
|
-
:href="
|
|
33
|
+
:href="$filter('serverPath',file.id)"
|
|
34
34
|
:download="file.name">
|
|
35
35
|
{{ file.name }}
|
|
36
36
|
</a>
|
|
@@ -71,7 +71,7 @@
|
|
|
71
71
|
<span class="file-name full-width ellipsis">
|
|
72
72
|
<a
|
|
73
73
|
target="_blank"
|
|
74
|
-
:href="
|
|
74
|
+
:href="$filter('serverPath',file.id)"
|
|
75
75
|
:download="file.name">
|
|
76
76
|
{{ file.name }}
|
|
77
77
|
</a>
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
</q-btn>
|
|
69
69
|
<q-img
|
|
70
70
|
v-if="onlyIcon && scope.files.length > 0"
|
|
71
|
-
:src="
|
|
71
|
+
:src="$filter('serverThumb',`${scope.files[0].id}`)"
|
|
72
72
|
style="width: 32px; max-height: 32px;"
|
|
73
73
|
>
|
|
74
74
|
<q-uploader-add-trigger/>
|
|
@@ -125,7 +125,7 @@
|
|
|
125
125
|
<a
|
|
126
126
|
v-if="file && file.id"
|
|
127
127
|
target="_blank"
|
|
128
|
-
:href="
|
|
128
|
+
:href="$filter('serverPath',file.id)"
|
|
129
129
|
:download="file.name">
|
|
130
130
|
{{ file.name }}
|
|
131
131
|
</a>
|
package/index.js
CHANGED
|
@@ -13,21 +13,12 @@ import LeveledMenus from './components/Basic/LeveledMenus.vue';
|
|
|
13
13
|
import BreadCrumbs from './components/Basic/BreadCrumbs.vue';
|
|
14
14
|
import ThemeSwitch from './components/ThemeSwitch/index.vue';
|
|
15
15
|
|
|
16
|
+
import Mourning from './view/mourning/mourning.vue';
|
|
17
|
+
|
|
16
18
|
import FieldComponents from './field-components';
|
|
17
19
|
import FreeFields from './free-fields';
|
|
18
20
|
import routers from './router';
|
|
19
21
|
|
|
20
|
-
// Vue.component('EIcon', () => import('./components/Basic/EIcon.vue'));
|
|
21
|
-
// Vue.component('StickyButtons', () => import('./components/StickyButtons'));
|
|
22
|
-
// Vue.component('SelectLocales', () => import('./components/SelectLocales'));
|
|
23
|
-
// Vue.component('SummaryHead', () => import('./components/Basic/SummaryHead.vue'));
|
|
24
|
-
// Vue.component('SlidingCarousel', () => import('./components/SlidingCarousel/index.vue'));
|
|
25
|
-
// Vue.component('SlidingNews', () => import('./components/SlidingNews/index.vue'));
|
|
26
|
-
// Vue.component('FloatingWindow', () => import('./components/FloatingWindow/index.vue'));
|
|
27
|
-
// Vue.component('LeveledMenus', () => import('./components/Basic/LeveledMenus.vue'));
|
|
28
|
-
// Vue.component('BreadCrumbs', () => import('./components/Basic/BreadCrumbs.vue'));
|
|
29
|
-
// Vue.component('ThemeSwitch', () => import('./components/ThemeSwitch/index.vue'));
|
|
30
|
-
|
|
31
22
|
// global filters
|
|
32
23
|
const filters = {
|
|
33
24
|
serverImage: url => (url ? `${config.imageUrlBase}${url}` : ''),
|
|
@@ -144,14 +135,8 @@ const filters = {
|
|
|
144
135
|
},
|
|
145
136
|
};
|
|
146
137
|
|
|
147
|
-
// export default {
|
|
148
|
-
// config: {},
|
|
149
|
-
// routers: [],
|
|
150
|
-
// filters,
|
|
151
|
-
// components
|
|
152
|
-
// }
|
|
153
|
-
|
|
154
138
|
export default (app, root) => {
|
|
139
|
+
console.error('register dialog')
|
|
155
140
|
root.use(MsgDialog);
|
|
156
141
|
|
|
157
142
|
return {
|
|
@@ -294,7 +279,7 @@ export default (app, root) => {
|
|
|
294
279
|
ThemeSwitch,
|
|
295
280
|
...FieldComponents.components,
|
|
296
281
|
...FreeFields,
|
|
297
|
-
|
|
282
|
+
Mourning,
|
|
298
283
|
},
|
|
299
284
|
fieldComponents: FieldComponents.fieldComponents,
|
|
300
285
|
|
package/package.json
CHANGED
package/view/dict/index.vue
CHANGED
|
@@ -271,13 +271,11 @@ export default defineComponent({
|
|
|
271
271
|
|
|
272
272
|
<style lang="sass" scoped>
|
|
273
273
|
.admin-dictionary-mgmt-wrapper
|
|
274
|
-
background: $background
|
|
275
274
|
.dictionary-head
|
|
276
275
|
.description
|
|
277
276
|
max-width: 680px
|
|
278
277
|
font-size: 12px
|
|
279
278
|
font-weight: 400
|
|
280
|
-
color: $grey-7
|
|
281
279
|
.dictionary-data-name
|
|
282
280
|
font-size: 14px
|
|
283
281
|
font-weight: normal
|
package/view/menu/index.vue
CHANGED
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import {createApp} from 'vue';
|
|
2
|
-
import BasicDialog from './BasicDialog.vue';
|
|
3
|
-
|
|
4
|
-
let _i18n = null;
|
|
5
|
-
|
|
6
|
-
export function setI18n (i18n) {
|
|
7
|
-
_i18n = i18n
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
const MsgDialog = {};
|
|
11
|
-
MsgDialog.install = (app) => {
|
|
12
|
-
// const MessageDialogInstance = app.extend(BasicDialog);
|
|
13
|
-
// const MessageDialogInstance = createApp(BasicDialog);
|
|
14
|
-
|
|
15
|
-
let MsgDialogInstance;
|
|
16
|
-
const init = () => {
|
|
17
|
-
// app.config.globalProperties._i18n = _i18n;
|
|
18
|
-
|
|
19
|
-
// MsgDialogInstance = new MessageDialogInstance();
|
|
20
|
-
MsgDialogInstance = createApp(BasicDialog);
|
|
21
|
-
MsgDialogInstance = MsgDialogInstance.mount('#eis-dialog');
|
|
22
|
-
// document.body.appendChild(msgBoxEl);
|
|
23
|
-
};
|
|
24
|
-
|
|
25
|
-
app.config.globalProperties.$MsgDialog = (options) => {
|
|
26
|
-
if (!MsgDialogInstance) {
|
|
27
|
-
init();
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
if (typeof options === 'string') {
|
|
31
|
-
MsgDialogInstance.content = options;
|
|
32
|
-
} else if (typeof options === 'object') {
|
|
33
|
-
Object.assign(MsgDialogInstance.$props, options);
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
// return MsgDialogInstance.show_msg_box()
|
|
37
|
-
return MsgDialogInstance.show()
|
|
38
|
-
.then((val) => {
|
|
39
|
-
MsgDialogInstance = null;
|
|
40
|
-
return Promise.resolve(val);
|
|
41
|
-
})
|
|
42
|
-
.catch((err) => {
|
|
43
|
-
MsgDialogInstance = null;
|
|
44
|
-
return Promise.reject(err);
|
|
45
|
-
});
|
|
46
|
-
};
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
export default MsgDialog;
|