@hostlink/nuxt-light 1.27.7 → 1.28.0
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/module.d.mts +2 -1
- package/dist/module.json +3 -3
- package/dist/module.mjs +40 -42
- package/dist/runtime/components/L/CustomField/Add.vue +41 -52
- package/dist/runtime/components/L/CustomField/Add.vue.d.ts +2 -0
- package/dist/runtime/components/L/CustomField/List.vue +26 -30
- package/dist/runtime/components/L/CustomField/List.vue.d.ts +2 -0
- package/dist/runtime/components/L/Database/create-table-dialog.vue +22 -38
- package/dist/runtime/components/L/Database/create-table-dialog.vue.d.ts +2 -0
- package/dist/runtime/components/L/Fieldset.vue +19 -23
- package/dist/runtime/components/L/Fieldset.vue.d.ts +2 -0
- package/dist/runtime/components/L/ForgetPasswordDialog.vue +39 -41
- package/dist/runtime/components/L/ForgetPasswordDialog.vue.d.ts +2 -0
- package/dist/runtime/components/L/Revision.vue +101 -137
- package/dist/runtime/components/L/Revision.vue.d.ts +2 -0
- package/dist/runtime/components/L/Storage.vue +26 -30
- package/dist/runtime/components/L/Storage.vue.d.ts +2 -0
- package/dist/runtime/components/L/System/Setting/authentication.vue +22 -44
- package/dist/runtime/components/L/System/Setting/authentication.vue.d.ts +2 -0
- package/dist/runtime/components/L/System/Setting/developer.vue +43 -59
- package/dist/runtime/components/L/System/Setting/developer.vue.d.ts +2 -0
- package/dist/runtime/components/L/System/Setting/forget-password.vue +42 -58
- package/dist/runtime/components/L/System/Setting/forget-password.vue.d.ts +2 -0
- package/dist/runtime/components/L/System/Setting/general.vue +29 -41
- package/dist/runtime/components/L/System/Setting/general.vue.d.ts +2 -0
- package/dist/runtime/components/L/System/Setting/mail.vue +39 -42
- package/dist/runtime/components/L/System/Setting/mail.vue.d.ts +2 -0
- package/dist/runtime/components/L/System/Setting/modules.vue +9 -9
- package/dist/runtime/components/L/System/Setting/modules.vue.d.ts +2 -0
- package/dist/runtime/components/L/System/Setting/security.vue +20 -39
- package/dist/runtime/components/L/System/Setting/security.vue.d.ts +2 -0
- package/dist/runtime/components/L/User/eventlog.vue +26 -26
- package/dist/runtime/components/L/User/eventlog.vue.d.ts +2 -0
- package/dist/runtime/components/L/User/overview.vue +25 -27
- package/dist/runtime/components/L/User/overview.vue.d.ts +2 -0
- package/dist/runtime/components/L/User/userlog.vue +22 -28
- package/dist/runtime/components/L/User/userlog.vue.d.ts +2 -0
- package/dist/runtime/components/L/ValidationInput.vue +68 -91
- package/dist/runtime/components/L/ValidationInput.vue.d.ts +2 -0
- package/dist/runtime/components/MyTest.vue +8 -7
- package/dist/runtime/components/MyTest.vue.d.ts +2 -0
- package/dist/runtime/components/l-add-btn.vue +13 -12
- package/dist/runtime/components/l-add-btn.vue.d.ts +2 -0
- package/dist/runtime/components/l-alert.vue +25 -29
- package/dist/runtime/components/l-alert.vue.d.ts +2 -0
- package/dist/runtime/components/l-app-main.vue +226 -294
- package/dist/runtime/components/l-app-main.vue.d.ts +2 -0
- package/dist/runtime/components/l-app.vue +76 -89
- package/dist/runtime/components/l-app.vue.d.ts +2 -0
- package/dist/runtime/components/l-audit-card.vue +8 -14
- package/dist/runtime/components/l-audit-card.vue.d.ts +2 -0
- package/dist/runtime/components/l-back-btn.vue.d.ts +2 -0
- package/dist/runtime/components/l-banner.vue +28 -34
- package/dist/runtime/components/l-banner.vue.d.ts +2 -0
- package/dist/runtime/components/l-bar.vue +21 -25
- package/dist/runtime/components/l-bar.vue.d.ts +2 -0
- package/dist/runtime/components/l-btn.vue +62 -39
- package/dist/runtime/components/l-btn.vue.d.ts +2 -0
- package/dist/runtime/components/l-card.vue +90 -141
- package/dist/runtime/components/l-card.vue.d.ts +2 -0
- package/dist/runtime/components/l-checkbox.vue +30 -7
- package/dist/runtime/components/l-checkbox.vue.d.ts +2 -0
- package/dist/runtime/components/l-col.vue +21 -29
- package/dist/runtime/components/l-col.vue.d.ts +2 -0
- package/dist/runtime/components/l-customizer.vue +84 -100
- package/dist/runtime/components/l-customizer.vue.d.ts +2 -0
- package/dist/runtime/components/l-date-picker.vue +101 -147
- package/dist/runtime/components/l-date-picker.vue.d.ts +2 -0
- package/dist/runtime/components/l-delete-btn.vue +22 -27
- package/dist/runtime/components/l-delete-btn.vue.d.ts +2 -0
- package/dist/runtime/components/l-dialog-database-field-add.vue +19 -36
- package/dist/runtime/components/l-dialog-database-field-add.vue.d.ts +2 -0
- package/dist/runtime/components/l-drag-drop-container.vue +44 -62
- package/dist/runtime/components/l-drag-drop-container.vue.d.ts +2 -0
- package/dist/runtime/components/l-drag-drop-group.vue +49 -70
- package/dist/runtime/components/l-drag-drop-group.vue.d.ts +2 -0
- package/dist/runtime/components/l-drag-drop.vue +33 -44
- package/dist/runtime/components/l-drag-drop.vue.d.ts +2 -0
- package/dist/runtime/components/l-edit-btn.vue.d.ts +2 -0
- package/dist/runtime/components/l-editor.vue +185 -172
- package/dist/runtime/components/l-editor.vue.d.ts +2 -0
- package/dist/runtime/components/l-facebook-button.vue +18 -26
- package/dist/runtime/components/l-facebook-button.vue.d.ts +2 -0
- package/dist/runtime/components/l-fav-menu.vue +19 -24
- package/dist/runtime/components/l-fav-menu.vue.d.ts +2 -0
- package/dist/runtime/components/l-field.vue +49 -18
- package/dist/runtime/components/l-field.vue.d.ts +2 -0
- package/dist/runtime/components/l-file-manager-labels.vue +46 -48
- package/dist/runtime/components/l-file-manager-labels.vue.d.ts +2 -0
- package/dist/runtime/components/l-file-manager-move.vue +53 -68
- package/dist/runtime/components/l-file-manager-move.vue.d.ts +2 -0
- package/dist/runtime/components/l-file-manager-preview.vue +46 -81
- package/dist/runtime/components/l-file-manager-preview.vue.d.ts +2 -0
- package/dist/runtime/components/l-file-manager.vue +498 -640
- package/dist/runtime/components/l-file-manager.vue.d.ts +2 -0
- package/dist/runtime/components/l-file-upload.vue +80 -109
- package/dist/runtime/components/l-file-upload.vue.d.ts +2 -0
- package/dist/runtime/components/l-file.vue +37 -61
- package/dist/runtime/components/l-file.vue.d.ts +2 -0
- package/dist/runtime/components/l-form-dialog.vue +71 -83
- package/dist/runtime/components/l-form-dialog.vue.d.ts +2 -0
- package/dist/runtime/components/l-form.vue +82 -96
- package/dist/runtime/components/l-form.vue.d.ts +2 -0
- package/dist/runtime/components/l-group-select.vue +59 -94
- package/dist/runtime/components/l-group-select.vue.d.ts +2 -0
- package/dist/runtime/components/l-icon-picker.vue +3265 -3274
- package/dist/runtime/components/l-icon-picker.vue.d.ts +2 -0
- package/dist/runtime/components/l-input-xlsx.vue +30 -38
- package/dist/runtime/components/l-input-xlsx.vue.d.ts +2 -0
- package/dist/runtime/components/l-input.vue +142 -126
- package/dist/runtime/components/l-input.vue.d.ts +2 -0
- package/dist/runtime/components/l-item.vue +30 -21
- package/dist/runtime/components/l-item.vue.d.ts +2 -0
- package/dist/runtime/components/l-link.vue +16 -15
- package/dist/runtime/components/l-link.vue.d.ts +2 -0
- package/dist/runtime/components/l-list.vue +27 -35
- package/dist/runtime/components/l-list.vue.d.ts +2 -0
- package/dist/runtime/components/l-login.vue +246 -287
- package/dist/runtime/components/l-login.vue.d.ts +2 -0
- package/dist/runtime/components/l-menu.vue +45 -54
- package/dist/runtime/components/l-menu.vue.d.ts +2 -0
- package/dist/runtime/components/l-microsoft-button.vue +42 -52
- package/dist/runtime/components/l-microsoft-button.vue.d.ts +2 -0
- package/dist/runtime/components/l-page.vue +48 -67
- package/dist/runtime/components/l-page.vue.d.ts +2 -0
- package/dist/runtime/components/l-row.vue +8 -13
- package/dist/runtime/components/l-row.vue.d.ts +2 -0
- package/dist/runtime/components/l-save-btn.vue.d.ts +2 -0
- package/dist/runtime/components/l-select.vue +150 -76
- package/dist/runtime/components/l-select.vue.d.ts +2 -0
- package/dist/runtime/components/l-small-box.vue +18 -31
- package/dist/runtime/components/l-small-box.vue.d.ts +2 -0
- package/dist/runtime/components/l-statistic.vue +17 -23
- package/dist/runtime/components/l-statistic.vue.d.ts +2 -0
- package/dist/runtime/components/l-tab.vue +20 -15
- package/dist/runtime/components/l-tab.vue.d.ts +2 -0
- package/dist/runtime/components/l-table.vue +444 -560
- package/dist/runtime/components/l-table.vue.d.ts +2 -0
- package/dist/runtime/components/l-tabs.vue +34 -16
- package/dist/runtime/components/l-tabs.vue.d.ts +2 -0
- package/dist/runtime/components/l-test2.vue +10 -9
- package/dist/runtime/components/l-test2.vue.d.ts +2 -0
- package/dist/runtime/components/l-time-picker.vue +53 -68
- package/dist/runtime/components/l-time-picker.vue.d.ts +2 -0
- package/dist/runtime/components/l-view-btn.vue.d.ts +2 -0
- package/dist/runtime/composables/mytest.d.ts +2 -0
- package/dist/runtime/composables/mytest.js +3 -0
- package/dist/runtime/formkit/Checkbox.vue +15 -18
- package/dist/runtime/formkit/Checkbox.vue.d.ts +2 -0
- package/dist/runtime/formkit/DatePicker.vue +15 -18
- package/dist/runtime/formkit/DatePicker.vue.d.ts +2 -0
- package/dist/runtime/formkit/Editor.vue +15 -18
- package/dist/runtime/formkit/Editor.vue.d.ts +2 -0
- package/dist/runtime/formkit/File.vue +30 -37
- package/dist/runtime/formkit/File.vue.d.ts +2 -0
- package/dist/runtime/formkit/FilePicker.vue +22 -25
- package/dist/runtime/formkit/FilePicker.vue.d.ts +2 -0
- package/dist/runtime/formkit/FileUpload.vue +22 -25
- package/dist/runtime/formkit/FileUpload.vue.d.ts +2 -0
- package/dist/runtime/formkit/Form.vue +79 -100
- package/dist/runtime/formkit/Form.vue.d.ts +2 -0
- package/dist/runtime/formkit/GroupSelect.vue +21 -27
- package/dist/runtime/formkit/GroupSelect.vue.d.ts +2 -0
- package/dist/runtime/formkit/Input.vue +53 -61
- package/dist/runtime/formkit/Input.vue.d.ts +2 -0
- package/dist/runtime/formkit/InputXlsx.vue +15 -18
- package/dist/runtime/formkit/InputXlsx.vue.d.ts +2 -0
- package/dist/runtime/formkit/OptionGroup.vue +20 -26
- package/dist/runtime/formkit/OptionGroup.vue.d.ts +2 -0
- package/dist/runtime/formkit/Radio.vue +15 -18
- package/dist/runtime/formkit/Radio.vue.d.ts +2 -0
- package/dist/runtime/formkit/Repeater.vue +62 -76
- package/dist/runtime/formkit/Repeater.vue.d.ts +2 -0
- package/dist/runtime/formkit/Select.vue +21 -29
- package/dist/runtime/formkit/Select.vue.d.ts +2 -0
- package/dist/runtime/formkit/TimePicker.vue +15 -19
- package/dist/runtime/formkit/TimePicker.vue.d.ts +2 -0
- package/dist/runtime/formkit/Toggle.vue +13 -16
- package/dist/runtime/formkit/Toggle.vue.d.ts +2 -0
- package/dist/runtime/light.d.ts +1129 -6
- package/dist/runtime/pages/CustomField/[custom_field_id]/edit.vue +24 -26
- package/dist/runtime/pages/CustomField/[custom_field_id]/edit.vue.d.ts +2 -0
- package/dist/runtime/pages/CustomField/index.vue +22 -29
- package/dist/runtime/pages/CustomField/index.vue.d.ts +2 -0
- package/dist/runtime/pages/EventLog/_eventlog_id/view.vue +8 -8
- package/dist/runtime/pages/EventLog/_eventlog_id/view.vue.d.ts +2 -0
- package/dist/runtime/pages/EventLog/index.vue +7 -6
- package/dist/runtime/pages/EventLog/index.vue.d.ts +2 -0
- package/dist/runtime/pages/FileManager/index.vue.d.ts +2 -0
- package/dist/runtime/pages/MailLog/index.vue +7 -6
- package/dist/runtime/pages/MailLog/index.vue.d.ts +2 -0
- package/dist/runtime/pages/Permission/add.vue +26 -29
- package/dist/runtime/pages/Permission/add.vue.d.ts +2 -0
- package/dist/runtime/pages/Permission/all.vue +57 -73
- package/dist/runtime/pages/Permission/all.vue.d.ts +2 -0
- package/dist/runtime/pages/Permission/export.vue +49 -62
- package/dist/runtime/pages/Permission/export.vue.d.ts +2 -0
- package/dist/runtime/pages/Permission/index.vue +19 -20
- package/dist/runtime/pages/Permission/index.vue.d.ts +2 -0
- package/dist/runtime/pages/Role/_name/update-child.vue +12 -14
- package/dist/runtime/pages/Role/_name/update-child.vue.d.ts +2 -0
- package/dist/runtime/pages/Role/add.vue +13 -15
- package/dist/runtime/pages/Role/add.vue.d.ts +2 -0
- package/dist/runtime/pages/Role/add2.vue +27 -38
- package/dist/runtime/pages/Role/add2.vue.d.ts +2 -0
- package/dist/runtime/pages/Role/index.vue +100 -127
- package/dist/runtime/pages/Role/index.vue.d.ts +2 -0
- package/dist/runtime/pages/System/database/backup.vue +28 -36
- package/dist/runtime/pages/System/database/backup.vue.d.ts +2 -0
- package/dist/runtime/pages/System/database/process.vue +33 -43
- package/dist/runtime/pages/System/database/process.vue.d.ts +2 -0
- package/dist/runtime/pages/System/database/table.vue +168 -205
- package/dist/runtime/pages/System/database/table.vue.d.ts +2 -0
- package/dist/runtime/pages/System/fs.vue +95 -107
- package/dist/runtime/pages/System/fs.vue.d.ts +2 -0
- package/dist/runtime/pages/System/index.vue +30 -31
- package/dist/runtime/pages/System/index.vue.d.ts +2 -0
- package/dist/runtime/pages/System/mailtest.vue +29 -35
- package/dist/runtime/pages/System/mailtest.vue.d.ts +2 -0
- package/dist/runtime/pages/System/menu/index.vue +175 -223
- package/dist/runtime/pages/System/menu/index.vue.d.ts +2 -0
- package/dist/runtime/pages/System/package.vue +21 -21
- package/dist/runtime/pages/System/package.vue.d.ts +2 -0
- package/dist/runtime/pages/System/phpinfo.vue +11 -10
- package/dist/runtime/pages/System/phpinfo.vue.d.ts +2 -0
- package/dist/runtime/pages/System/setting.vue +42 -59
- package/dist/runtime/pages/System/setting.vue.d.ts +2 -0
- package/dist/runtime/pages/System/test.vue.d.ts +2 -0
- package/dist/runtime/pages/System/view_as.vue +65 -68
- package/dist/runtime/pages/System/view_as.vue.d.ts +2 -0
- package/dist/runtime/pages/SystemValue/_systemvalue_id/edit.vue +7 -7
- package/dist/runtime/pages/SystemValue/_systemvalue_id/edit.vue.d.ts +2 -0
- package/dist/runtime/pages/SystemValue/add.vue.d.ts +2 -0
- package/dist/runtime/pages/SystemValue/index.vue +7 -6
- package/dist/runtime/pages/SystemValue/index.vue.d.ts +2 -0
- package/dist/runtime/pages/Translate/index.vue +81 -100
- package/dist/runtime/pages/Translate/index.vue.d.ts +2 -0
- package/dist/runtime/pages/User/_user_id/change-password.vue +38 -45
- package/dist/runtime/pages/User/_user_id/change-password.vue.d.ts +2 -0
- package/dist/runtime/pages/User/_user_id/edit.vue +35 -26
- package/dist/runtime/pages/User/_user_id/edit.vue.d.ts +2 -0
- package/dist/runtime/pages/User/_user_id/update-role.vue +33 -43
- package/dist/runtime/pages/User/_user_id/update-role.vue.d.ts +2 -0
- package/dist/runtime/pages/User/_user_id/view.vue +35 -37
- package/dist/runtime/pages/User/_user_id/view.vue.d.ts +2 -0
- package/dist/runtime/pages/User/add.vue +52 -60
- package/dist/runtime/pages/User/add.vue.d.ts +2 -0
- package/dist/runtime/pages/User/index.vue +23 -32
- package/dist/runtime/pages/User/index.vue.d.ts +2 -0
- package/dist/runtime/pages/User/profile.vue +52 -58
- package/dist/runtime/pages/User/profile.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/bio-auth.vue +85 -95
- package/dist/runtime/pages/User/setting/bio-auth.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/index.vue +27 -28
- package/dist/runtime/pages/User/setting/index.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/information.vue +28 -27
- package/dist/runtime/pages/User/setting/information.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/my_favorite.vue +29 -35
- package/dist/runtime/pages/User/setting/my_favorite.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/open_id.vue +140 -165
- package/dist/runtime/pages/User/setting/open_id.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/password.vue +37 -44
- package/dist/runtime/pages/User/setting/password.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/style.vue +84 -102
- package/dist/runtime/pages/User/setting/style.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting/two-factor-auth.vue +51 -61
- package/dist/runtime/pages/User/setting/two-factor-auth.vue.d.ts +2 -0
- package/dist/runtime/pages/User/setting.vue +9 -9
- package/dist/runtime/pages/User/setting.vue.d.ts +2 -0
- package/dist/runtime/pages/UserLog/index.vue +7 -6
- package/dist/runtime/pages/UserLog/index.vue.d.ts +2 -0
- package/dist/types.d.mts +3 -1
- package/package.json +9 -11
- package/dist/module.cjs +0 -5
- package/dist/module.d.ts +0 -7
- package/dist/types.d.ts +0 -1
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
<script setup>
|
|
2
|
-
const props = defineProps({
|
|
3
|
-
|
|
4
|
-
})
|
|
5
|
-
</script>
|
|
6
|
-
|
|
1
|
+
<script setup>
|
|
2
|
+
const props = defineProps({
|
|
3
|
+
test: String
|
|
4
|
+
});
|
|
5
|
+
</script>
|
|
6
|
+
|
|
7
|
+
<template>
|
|
7
8
|
<div>
|
|
8
9
|
{{ props }}
|
|
9
10
|
</div>
|
|
10
|
-
</template>
|
|
11
|
+
</template>
|
|
@@ -1,15 +1,16 @@
|
|
|
1
|
-
<script setup>
|
|
2
|
-
const props = defineProps({
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
});
|
|
10
|
-
</script>
|
|
11
|
-
|
|
1
|
+
<script setup>
|
|
2
|
+
const props = defineProps({
|
|
3
|
+
label: {
|
|
4
|
+
type: String,
|
|
5
|
+
default: "Add"
|
|
6
|
+
},
|
|
7
|
+
to: String,
|
|
8
|
+
color: String
|
|
9
|
+
});
|
|
10
|
+
</script>
|
|
11
|
+
|
|
12
|
+
<template>
|
|
12
13
|
<l-btn icon="sym_o_add" v-bind="$props" :to="to ?? $route.path + '/add'">
|
|
13
14
|
<q-tooltip>{{ $t(label) }}</q-tooltip>
|
|
14
15
|
</l-btn>
|
|
15
|
-
</template>
|
|
16
|
+
</template>
|
|
@@ -1,31 +1,27 @@
|
|
|
1
|
-
<script setup>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
</script>
|
|
27
|
-
|
|
28
|
-
<template>
|
|
1
|
+
<script setup>
|
|
2
|
+
import { computed } from "vue";
|
|
3
|
+
const props = defineProps({
|
|
4
|
+
type: {
|
|
5
|
+
type: String,
|
|
6
|
+
default: "info"
|
|
7
|
+
//info, warning, negative, positive
|
|
8
|
+
}
|
|
9
|
+
});
|
|
10
|
+
const icon = computed(() => {
|
|
11
|
+
switch (props.type) {
|
|
12
|
+
case "info":
|
|
13
|
+
return "sym_o_info";
|
|
14
|
+
case "warning":
|
|
15
|
+
return "sym_o_warning";
|
|
16
|
+
case "negative":
|
|
17
|
+
return "sym_o_error";
|
|
18
|
+
case "positive":
|
|
19
|
+
return "sym_o_check_circle_outline";
|
|
20
|
+
}
|
|
21
|
+
});
|
|
22
|
+
</script>
|
|
23
|
+
|
|
24
|
+
<template>
|
|
29
25
|
<q-item :class="`bg-${type}`">
|
|
30
26
|
<q-item-section avatar>
|
|
31
27
|
<q-icon :name="icon" class="text-white" />
|
|
@@ -34,4 +30,4 @@ const icon = computed(() => {
|
|
|
34
30
|
<slot></slot>
|
|
35
31
|
</q-item-section>
|
|
36
32
|
</q-item>
|
|
37
|
-
</template>
|
|
33
|
+
</template>
|
|
@@ -1,298 +1,230 @@
|
|
|
1
|
-
<script setup
|
|
2
|
-
import { useRoute, useRouter } from
|
|
3
|
-
import { useLight, q, m } from "#imports";
|
|
4
|
-
import { useQuasar } from
|
|
5
|
-
import { useI18n } from
|
|
6
|
-
import { ref, computed, reactive, provide, watch, toRaw } from
|
|
7
|
-
import { useRuntimeConfig } from
|
|
8
|
-
import { api
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
light.
|
|
65
|
-
|
|
66
|
-
light.
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
const
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
const
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
const
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
})
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
})
|
|
206
|
-
|
|
207
|
-
const
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
const
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
const onToggleFav = async () => {
|
|
225
|
-
|
|
226
|
-
if (isFav.value) {
|
|
227
|
-
await m("removeMyFavorite", {
|
|
228
|
-
path: route.fullPath,
|
|
229
|
-
})
|
|
230
|
-
|
|
231
|
-
//reload my.myFavorites
|
|
232
|
-
light.reloadMyFavorites();
|
|
233
|
-
return;
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
light.dialog({
|
|
237
|
-
title: 'Add to favorite',
|
|
238
|
-
message: 'Enter favorite label',
|
|
239
|
-
prompt: {
|
|
240
|
-
//get window title, remove - and replace with space
|
|
241
|
-
model: route.name.replace(/-/g, ' '),
|
|
242
|
-
isValid: (val) => val !== '',
|
|
243
|
-
},
|
|
244
|
-
cancel: true,
|
|
245
|
-
persistent: true,
|
|
246
|
-
}).onOk(async (data) => {
|
|
247
|
-
if (await m("addMyFavorite", {
|
|
248
|
-
path: route.fullPath,
|
|
249
|
-
label: data,
|
|
250
|
-
})) {
|
|
251
|
-
light.reloadMyFavorites();
|
|
252
|
-
}
|
|
253
|
-
})
|
|
254
|
-
}
|
|
255
|
-
|
|
256
|
-
const isFav = computed(() => {
|
|
257
|
-
//check my.myFavorites
|
|
258
|
-
let fav = my.myFavorites.find((item) => {
|
|
259
|
-
return item.path == route.fullPath;
|
|
260
|
-
})
|
|
261
|
-
return fav;
|
|
262
|
-
})
|
|
263
|
-
|
|
264
|
-
$q.loading.hide()
|
|
265
|
-
|
|
266
|
-
const menuWidth = ref(my.styles.menuWidth || 280);
|
|
267
|
-
|
|
268
|
-
watch(menuWidth, () => {
|
|
269
|
-
light.setStyle("menuWidth", menuWidth.value)
|
|
270
|
-
})
|
|
271
|
-
|
|
272
|
-
const c1 = computed(() => {
|
|
273
|
-
return light.getColorValue()
|
|
274
|
-
})
|
|
275
|
-
|
|
276
|
-
if (route.fullPath == "/" && my.default_page) {
|
|
277
|
-
router.push(my.default_page);
|
|
278
|
-
|
|
279
|
-
}
|
|
280
|
-
|
|
281
|
-
const onLogout = async () => {
|
|
282
|
-
await api.auth.logout();
|
|
283
|
-
emits('logout');
|
|
284
|
-
}
|
|
285
|
-
|
|
286
|
-
</script>
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
1
|
+
<script setup>
|
|
2
|
+
import { useRoute, useRouter } from "vue-router";
|
|
3
|
+
import { useLight, q, m } from "#imports";
|
|
4
|
+
import { useQuasar } from "quasar";
|
|
5
|
+
import { useI18n } from "vue-i18n";
|
|
6
|
+
import { ref, computed, reactive, provide, watch, toRaw } from "vue";
|
|
7
|
+
import { useRuntimeConfig } from "nuxt/app";
|
|
8
|
+
import { api } from "#imports";
|
|
9
|
+
const emits = defineEmits(["logout"]);
|
|
10
|
+
const $q = useQuasar();
|
|
11
|
+
$q.loading.show();
|
|
12
|
+
const config = useRuntimeConfig();
|
|
13
|
+
const appVersion = config.public.appVersion ?? "0.0.1";
|
|
14
|
+
const tt = await q({
|
|
15
|
+
system: {
|
|
16
|
+
devMode: true,
|
|
17
|
+
time: true,
|
|
18
|
+
storage: {
|
|
19
|
+
freeSpace: true,
|
|
20
|
+
usageSpace: true,
|
|
21
|
+
totalSpace: true
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
app: {
|
|
25
|
+
menus: true,
|
|
26
|
+
viewAsMode: true,
|
|
27
|
+
languages: true,
|
|
28
|
+
copyrightName: true,
|
|
29
|
+
copyrightYear: true,
|
|
30
|
+
hasFavorite: true,
|
|
31
|
+
i18nMessages: {
|
|
32
|
+
name: true,
|
|
33
|
+
value: true
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
my: {
|
|
37
|
+
username: true,
|
|
38
|
+
first_name: true,
|
|
39
|
+
last_name: true,
|
|
40
|
+
roles: true,
|
|
41
|
+
styles: true,
|
|
42
|
+
language: true,
|
|
43
|
+
permissions: true,
|
|
44
|
+
default_page: true,
|
|
45
|
+
myFavorites: {
|
|
46
|
+
my_favorite_id: true,
|
|
47
|
+
label: true,
|
|
48
|
+
path: true,
|
|
49
|
+
icon: true
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
let app = tt.app;
|
|
54
|
+
let my = reactive(tt.my);
|
|
55
|
+
const light = useLight();
|
|
56
|
+
light.devMode = tt.system.devMode;
|
|
57
|
+
light.init(my.styles);
|
|
58
|
+
light.setPermissions(my.permissions);
|
|
59
|
+
light.setMyFavorites(toRaw(my.myFavorites));
|
|
60
|
+
const myFavorites = computed(() => {
|
|
61
|
+
return light.getMyFavorites();
|
|
62
|
+
});
|
|
63
|
+
const myFavoritesCount = computed(() => {
|
|
64
|
+
return light.getMyFavorites().length;
|
|
65
|
+
});
|
|
66
|
+
$q.dark.set(light.isDarkMode());
|
|
67
|
+
const i18n = useI18n();
|
|
68
|
+
i18n.locale = my.language || "en";
|
|
69
|
+
let system = tt.system;
|
|
70
|
+
let messages = i18n.messages.value[i18n.locale];
|
|
71
|
+
for (let t of app.i18nMessages) {
|
|
72
|
+
messages[t.name] = t.value;
|
|
73
|
+
}
|
|
74
|
+
i18n.setLocaleMessage(i18n.locale, messages);
|
|
75
|
+
const menus = ref(app.menus);
|
|
76
|
+
const leftDrawerOpen = ref(false);
|
|
77
|
+
const rightDrawerOpen = ref(false);
|
|
78
|
+
const toggleLeftDrawer = () => {
|
|
79
|
+
leftDrawerOpen.value = !leftDrawerOpen.value;
|
|
80
|
+
};
|
|
81
|
+
const toggleRightDrawer = () => {
|
|
82
|
+
rightDrawerOpen.value = !rightDrawerOpen.value;
|
|
83
|
+
};
|
|
84
|
+
let showViewAs = false;
|
|
85
|
+
if (my && my.roles.indexOf("Administrators") != -1) {
|
|
86
|
+
showViewAs = true;
|
|
87
|
+
light.isAdmin = true;
|
|
88
|
+
}
|
|
89
|
+
const layoutView = computed(() => {
|
|
90
|
+
let s = "";
|
|
91
|
+
s += style.menuOverlayHeader ? "l" : "h";
|
|
92
|
+
s += "Hh LpR lFr";
|
|
93
|
+
return s;
|
|
94
|
+
});
|
|
95
|
+
const style = reactive({
|
|
96
|
+
miniState: my.styles?.miniState || false,
|
|
97
|
+
dense: my.styles?.dense || false,
|
|
98
|
+
footer: my.styles?.footer || false,
|
|
99
|
+
menuOverlayHeader: my.styles?.menuOverlayHeader || false
|
|
100
|
+
});
|
|
101
|
+
const isMouseOnDrawer = ref(false);
|
|
102
|
+
const isMini = computed(() => {
|
|
103
|
+
if (isMouseOnDrawer.value) {
|
|
104
|
+
return false;
|
|
105
|
+
}
|
|
106
|
+
if (style.miniState) {
|
|
107
|
+
return true;
|
|
108
|
+
}
|
|
109
|
+
return false;
|
|
110
|
+
});
|
|
111
|
+
const menuDark = computed(() => {
|
|
112
|
+
if (light.theme == "dark") {
|
|
113
|
+
return true;
|
|
114
|
+
}
|
|
115
|
+
if (light.theme == "semi-dark") {
|
|
116
|
+
return true;
|
|
117
|
+
}
|
|
118
|
+
return false;
|
|
119
|
+
});
|
|
120
|
+
const languages = app.languages;
|
|
121
|
+
const onChangeLocale = async (locale) => {
|
|
122
|
+
localStorage.setItem("locale", locale);
|
|
123
|
+
await m("updateMyLanguage", { name: locale });
|
|
124
|
+
window.location.reload();
|
|
125
|
+
};
|
|
126
|
+
const reloadMenu = async () => {
|
|
127
|
+
let app2 = await q("app", ["menus"]);
|
|
128
|
+
menus.value = app2.menus;
|
|
129
|
+
};
|
|
130
|
+
provide("reloadMenu", reloadMenu);
|
|
131
|
+
watch(() => style.footer, async (value) => await light.setStyle("footer", value));
|
|
132
|
+
watch(() => style.dense, async (value) => await light.setStyle("dense", value));
|
|
133
|
+
watch(() => light.theme, async () => {
|
|
134
|
+
$q.dark.set(light.isDarkMode());
|
|
135
|
+
});
|
|
136
|
+
watch(() => style.menuOverlayHeader, async (value) => {
|
|
137
|
+
await light.setStyle("menuOverlayHeader", value);
|
|
138
|
+
});
|
|
139
|
+
watch(() => style.miniState, async (value) => {
|
|
140
|
+
await m("updateMyStyle", {
|
|
141
|
+
name: "miniState",
|
|
142
|
+
value
|
|
143
|
+
});
|
|
144
|
+
});
|
|
145
|
+
const exitViewAs = async () => {
|
|
146
|
+
await m("cancelViewAs");
|
|
147
|
+
window.location.reload();
|
|
148
|
+
};
|
|
149
|
+
const storageColor = computed(() => {
|
|
150
|
+
if (system.storage) {
|
|
151
|
+
const percent = system.storage.freeSpace / system.storage.totalSpace;
|
|
152
|
+
if (percent < 0.05) {
|
|
153
|
+
return "negative";
|
|
154
|
+
}
|
|
155
|
+
if (percent < 0.1) {
|
|
156
|
+
return "warning";
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
});
|
|
160
|
+
const containerClass = computed(() => {
|
|
161
|
+
return light.theme == "dark" ? {} : { "bg-grey-2": true };
|
|
162
|
+
});
|
|
163
|
+
const containerStyle = computed(() => {
|
|
164
|
+
if (light.theme == "dark") {
|
|
165
|
+
return {};
|
|
166
|
+
}
|
|
167
|
+
return {
|
|
168
|
+
color: "#1f1f1f"
|
|
169
|
+
};
|
|
170
|
+
});
|
|
171
|
+
const route = useRoute();
|
|
172
|
+
const router = useRouter();
|
|
173
|
+
const onToggleFav = async () => {
|
|
174
|
+
if (isFav.value) {
|
|
175
|
+
await m("removeMyFavorite", {
|
|
176
|
+
path: route.fullPath
|
|
177
|
+
});
|
|
178
|
+
light.reloadMyFavorites();
|
|
179
|
+
return;
|
|
180
|
+
}
|
|
181
|
+
light.dialog({
|
|
182
|
+
title: "Add to favorite",
|
|
183
|
+
message: "Enter favorite label",
|
|
184
|
+
prompt: {
|
|
185
|
+
//get window title, remove - and replace with space
|
|
186
|
+
model: route.name.replace(/-/g, " "),
|
|
187
|
+
isValid: (val) => val !== ""
|
|
188
|
+
},
|
|
189
|
+
cancel: true,
|
|
190
|
+
persistent: true
|
|
191
|
+
}).onOk(async (data) => {
|
|
192
|
+
if (await m("addMyFavorite", {
|
|
193
|
+
path: route.fullPath,
|
|
194
|
+
label: data
|
|
195
|
+
})) {
|
|
196
|
+
light.reloadMyFavorites();
|
|
197
|
+
}
|
|
198
|
+
});
|
|
199
|
+
};
|
|
200
|
+
const isFav = computed(() => {
|
|
201
|
+
let fav = my.myFavorites.find((item) => {
|
|
202
|
+
return item.path == route.fullPath;
|
|
203
|
+
});
|
|
204
|
+
return fav;
|
|
205
|
+
});
|
|
206
|
+
$q.loading.hide();
|
|
207
|
+
const menuWidth = ref(my.styles.menuWidth || 280);
|
|
208
|
+
watch(menuWidth, () => {
|
|
209
|
+
light.setStyle("menuWidth", menuWidth.value);
|
|
210
|
+
});
|
|
211
|
+
const c1 = computed(() => {
|
|
212
|
+
return light.getColorValue();
|
|
213
|
+
});
|
|
214
|
+
if (route.fullPath == "/" && my.default_page) {
|
|
215
|
+
router.push(my.default_page);
|
|
216
|
+
}
|
|
217
|
+
const onLogout = async () => {
|
|
218
|
+
await api.auth.logout();
|
|
219
|
+
emits("logout");
|
|
220
|
+
};
|
|
221
|
+
</script>
|
|
222
|
+
|
|
290
223
|
<style scoped>
|
|
291
224
|
.q-layout__section--marginal{background-color:v-bind(c1)}
|
|
292
|
-
</style>
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
<template>
|
|
225
|
+
</style>
|
|
226
|
+
|
|
227
|
+
<template>
|
|
296
228
|
<q-layout :view="layoutView">
|
|
297
229
|
<q-header bordered class="text-white" :class="`bg-${light.color}`">
|
|
298
230
|
<q-toolbar>
|
|
@@ -464,4 +396,4 @@ const onLogout = async () => {
|
|
|
464
396
|
</q-item>
|
|
465
397
|
</q-footer>
|
|
466
398
|
</q-layout>
|
|
467
|
-
</template>
|
|
399
|
+
</template>
|