Moved to _dev

This commit is contained in:
2025-09-20 16:11:47 +02:00
parent fb1a8753b7
commit b2ba11fcd3
1670 changed files with 224899 additions and 0 deletions

View File

@@ -0,0 +1,31 @@
import axios from 'axios'
import Ls from '@/scripts/services/ls.js'
window.Ls = Ls
window.axios = axios
axios.defaults.withCredentials = true
axios.defaults.headers.common = {
'X-Requested-With': 'XMLHttpRequest',
}
/**
* Interceptors
*/
axios.interceptors.request.use(function (config) {
// Pass selected company to header on all requests
const companyId = Ls.get('selectedCompany')
const authToken = Ls.get('auth.token')
if (authToken) {
config.headers.common.Authorization = authToken
}
if (companyId) {
config.headers.common['company'] = companyId
}
return config
})

View File

@@ -0,0 +1,9 @@
import { createI18n } from 'vue-i18n'
export default (messages) => {
return createI18n({
locale: 'en',
fallbackLocale: 'en',
messages
})
}