@hostlink/nuxt-light 1.14.1 → 1.14.3

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.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "light",
3
3
  "configKey": "light",
4
- "version": "1.14.1",
4
+ "version": "1.14.3",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "0.8.3",
7
7
  "unbuild": "2.0.0"
@@ -8,6 +8,7 @@ const { humanStorageSize } = format
8
8
  const light = useLight();
9
9
  const i18n = useI18n();
10
10
  const quasar = useQuasar();
11
+ const $q = quasar;
11
12
  const emit = defineEmits(["input", "close"]);
12
13
 
13
14
  const props = defineProps({
@@ -339,7 +340,7 @@ const showUploadFiles = ref(false);
339
340
 
340
341
  const onUploadFiles = async () => {
341
342
 
342
- quasar.loading.show({
343
+ $q.loading.show({
343
344
  message: "Uploading files...",
344
345
  });
345
346
 
@@ -352,17 +353,16 @@ const onUploadFiles = async () => {
352
353
  });
353
354
  }
354
355
  } catch (e) {
355
- quasar.dialog({
356
+ $q.dialog({
356
357
  title: "Error",
357
358
  message: e.message,
358
359
  });
359
-
360
+ $q.loading.hide();
360
361
  return;
361
-
362
362
  }
363
363
  uploadFiles.value = [];
364
364
 
365
- quasar.loading.hide();
365
+ $q.loading.hide();
366
366
 
367
367
  showUploadFiles.value = false;
368
368
 
@@ -1,13 +1,14 @@
1
1
  <script setup lang="ts">
2
2
  import { ref, computed, useAttrs } from "vue";
3
3
  import { useLight, m, q } from '#imports';
4
- import { Loading, useQuasar } from "quasar";
4
+ import { useQuasar } from "quasar";
5
5
  import { useI18n } from "vue-i18n";
6
6
  import { format } from 'quasar'
7
7
  const { humanStorageSize } = format
8
8
  const light = useLight();
9
9
  const i18n = useI18n();
10
10
  const quasar = useQuasar();
11
+ const $q = quasar;
11
12
 
12
13
  const { system } = await q({
13
14
  system: {
@@ -90,7 +91,7 @@ const onUploadFile = async () => {
90
91
  return;
91
92
  }
92
93
 
93
- Loading.show({
94
+ $q.loading.show({
94
95
  message: i18n.t("Uploading file..."),
95
96
  });
96
97
 
@@ -105,22 +106,20 @@ const onUploadFile = async () => {
105
106
  if (v.startsWith("/")) v = v.substr(1);
106
107
 
107
108
  localValue.value = v;
108
-
109
- Loading.hide();
110
-
111
109
  show.value = false;
112
110
  uploadFile.value = null;
113
- return;
114
111
  } catch (e: any) {
115
- quasar.dialog({
112
+ $q.loading.hide();
113
+
114
+ $q.dialog({
116
115
  title: i18n.t("Error"),
117
116
  message: e.message,
118
117
  });
119
- Loading.hide();
120
118
  }
119
+ $q.loading.hide();
120
+
121
121
 
122
122
 
123
- Loading.hide();
124
123
  }
125
124
 
126
125
  </script>
@@ -1,5 +1,4 @@
1
1
  <script setup>
2
- import { ref } from 'vue'
3
2
  import { useRouter, useRoute } from "vue-router";
4
3
  import { useQuasar } from "quasar";
5
4
  import { model } from "#imports"
@@ -26,6 +25,7 @@ if (props.context.bordered !== undefined) {
26
25
 
27
26
  let redirect = true;
28
27
  if (props.context.attrs.onSubmitted) {
28
+
29
29
  redirect = false;
30
30
  }
31
31
 
@@ -96,7 +96,7 @@ if (!props.context.onSubmit) {
96
96
  </div>
97
97
  </q-card-section>
98
98
 
99
- <q-card-actions align="right">
99
+ <q-card-actions align="right" v-if="context.actions">
100
100
  <l-btn icon="sym_o_check" :label="context.submitLabel ?? 'Submit'" @click="onSubmit"
101
101
  :disabled="!context.state.dirty" :loading="context.state.loading"></l-btn>
102
102
  </q-card-actions>
@@ -92,7 +92,6 @@ export const createLightPlugin = () => {
92
92
  "actions",
93
93
  "submitLabel",
94
94
  "submit",
95
- "actions",
96
95
  "onSubmit",
97
96
  "gutter",
98
97
  "bordered"
@@ -9,8 +9,10 @@ const { system: { database } } = await api.query({
9
9
  system: {
10
10
  database: {
11
11
  table: true,
12
- version: true
12
+ version: true,
13
+ tableStatus: true
13
14
  }
15
+
14
16
  }
15
17
  })
16
18
 
@@ -121,6 +123,19 @@ const removeField = async (table) => {
121
123
  </l-list>
122
124
  </l-card>
123
125
 
126
+
127
+ <q-card flat bordered>
128
+ <q-list class="rounded-borders" separator bordered>
129
+ <q-expansion-item label="Table Status" dense>
130
+ <div class="q-ma-sm">
131
+ <q-table :rows="database.tableStatus" hide-pagination flat bordered separator="cell" dense
132
+ :rows-per-page-options="[0]">
133
+ </q-table>
134
+ </div>
135
+ </q-expansion-item>
136
+ </q-list>
137
+ </q-card>
138
+
124
139
  <q-card flat bordered>
125
140
  <q-list class="rounded-borders" separator bordered>
126
141
  <q-expansion-item :label="table.name" v-for="table in tables" dense>
@@ -151,7 +151,7 @@ const tab = ref('general')
151
151
  false-value="0" />
152
152
  </q-field>
153
153
 
154
- <FormKit type="q-select" label="Revision" name="revision" use-input use-chips multiple
154
+ <FormKit type="l-select" label="Revision" name="revision" use-input use-chips multiple
155
155
  hide-dropdown-icon input-debounce="0" new-value-mode="add-unique" />
156
156
 
157
157
 
@@ -16,7 +16,6 @@ const columns = model("User").columns({
16
16
  has2FA: true,
17
17
  })
18
18
 
19
- console.log(columns);
20
19
 
21
20
  const status = ref("0");
22
21
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hostlink/nuxt-light",
3
- "version": "1.14.1",
3
+ "version": "1.14.3",
4
4
  "description": "HostLink Nuxt Light Framework",
5
5
  "repository": {
6
6
  "type": "git",