diff --git a/quasar.config.js b/quasar.config.js index 83265295f..9aefa9fda 100644 --- a/quasar.config.js +++ b/quasar.config.js @@ -23,7 +23,7 @@ module.exports = configure(function (ctx) { // app boot file (/src/boot) // --> boot files are part of "main.js" // https://v2.quasar.dev/quasar-cli-webpack/boot-files - boot: ['i18n', 'axios'], + boot: ['i18n', 'axios', 'pinia'], // https://v2.quasar.dev/quasar-cli-webpack/quasar-config-js#Property%3A-css css: ['app.scss'], diff --git a/src/boot/pinia.js b/src/boot/pinia.js new file mode 100644 index 000000000..5c6c0da28 --- /dev/null +++ b/src/boot/pinia.js @@ -0,0 +1,8 @@ +import { boot } from 'quasar/wrappers'; +import { createPinia } from 'pinia'; + +export default boot(({ app }) => { + const pinia = createPinia(); + + app.use(pinia); +}); diff --git a/src/components/FavoriteModules.vue b/src/components/FavoriteModules.vue index 65d070d95..26e39025c 100644 --- a/src/components/FavoriteModules.vue +++ b/src/components/FavoriteModules.vue @@ -1,43 +1,44 @@ - - - - +--> +onMounted(() => { + navigation.fetchPinned(); +}); + - - - - - - - - - - - - - - - - - - - - - - - - - - - + diff --git a/src/components/LeftMenu.vue b/src/components/LeftMenu.vue index 38563df39..8578df9d9 100644 --- a/src/components/LeftMenu.vue +++ b/src/components/LeftMenu.vue @@ -1,53 +1,95 @@ - + + + + + + + + + + diff --git a/src/composables/useRole.js b/src/composables/useRole.js index eb2eebd28..b8da153d3 100644 --- a/src/composables/useRole.js +++ b/src/composables/useRole.js @@ -6,7 +6,7 @@ export function useRole() { async function fetch() { const { data } = await axios.get('Accounts/acl'); - const roles = data.roles.map(userRoles => userRoles.role.name); + const roles = data.roles.map((userRoles) => userRoles.role.name); const userData = { id: data.user.id, @@ -14,7 +14,7 @@ export function useRole() { nickname: data.user.nickname, lang: data.user.lang || 'es', darkMode: data.user.userConfig.darkMode, - } + }; state.setUser(userData); state.setRoles(roles); } @@ -32,6 +32,6 @@ export function useRole() { return { fetch, hasAny, - state + state, }; -} \ No newline at end of file +} diff --git a/src/pages/Claim/Card/ClaimCard.vue b/src/pages/Claim/Card/ClaimCard.vue index 32dd3f24e..cf8f7687c 100644 --- a/src/pages/Claim/Card/ClaimCard.vue +++ b/src/pages/Claim/Card/ClaimCard.vue @@ -1,9 +1,8 @@