mirror of
https://github.com/InvoiceShelf/InvoiceShelf.git
synced 2026-04-18 10:44:08 +00:00
Complete dashboard translations & small UI improvements (#69)
* fix dropdown action Estimate Dashboard and fix translating full Dasboard page * Update app.php * fix locale in app.php config * Wizard install with translation, customer portal with translation, and fixing hardcoding strings to get translation * fixes asked to review * fixes pint --------- Co-authored-by: Max <contact@agencetwogether.fr> Co-authored-by: Darko Gjorgjijoski <5760249+gdarko@users.noreply.github.com>
This commit is contained in:
@@ -2,6 +2,7 @@ import { handleError } from '@/scripts/customer/helpers/error-handling'
|
||||
import { useUserStore } from './user'
|
||||
const { defineStore } = window.pinia
|
||||
import axios from 'axios'
|
||||
const { global } = window.i18n
|
||||
export const useGlobalStore = defineStore({
|
||||
id: 'CustomerPortalGlobalStore',
|
||||
state: () => ({
|
||||
@@ -29,7 +30,12 @@ export const useGlobalStore = defineStore({
|
||||
this.currency = response.data.data.currency
|
||||
this.enabledModules = response.data.meta.modules
|
||||
Object.assign(userStore.userForm, response.data.data)
|
||||
window.i18n.locale = response.data.default_language
|
||||
|
||||
if(typeof global.locale !== 'string') {
|
||||
global.locale.value =
|
||||
response.data.meta.current_company_language || 'en'
|
||||
}
|
||||
|
||||
this.isAppLoaded = true
|
||||
resolve(response)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user