Skip to content
Snippets Groups Projects
Commit e82983e8 authored by Sébastien DA ROCHA's avatar Sébastien DA ROCHA :bicyclist:
Browse files

Merge branch 'redmine-issues/11982' into 'develop'

REDMINE_ISSUE-11982

See merge request !91
parents ec13bea9 87cdc7af
No related branches found
No related tags found
No related merge requests found
{
"BASE_URL":"/",
"BASE_URL":"/geocontrib/",
"DOMAIN":"http://localhost:8010/",
"NODE_ENV":"development",
"VUE_APP_LOCALE":"fr-FR",
......
......@@ -14,25 +14,26 @@ Vue.config.productionTip = false
axios.get("/config/config.json")
.then((response) => {
if (response && response.status === 200) {
store.commit("SET_CONFIG", response.data);
window.proxy_url=response.data.VUE_APP_DJANGO_API_BASE+"proxy/"
axios.all([store.dispatch("USER_INFO"),
store.dispatch("GET_ALL_PROJECTS"),
store.dispatch("GET_STATIC_PAGES"),
store.dispatch("GET_USER_LEVEL_PROJECTS"),
store.dispatch("map/GET_AVAILABLE_LAYERS"),
store.dispatch("GET_USER_LEVEL_PERMISSIONS"),
]).then(axios.spread(function () {
new Vue({
router,
store,
render: h => h(App)
}).$mount('#app')
}))
}
})
.catch((error) => {
throw error;
store.commit("SET_CONFIG", response.data);
window.proxy_url = response.data.VUE_APP_DJANGO_API_BASE + "proxy/"
axios.all([
store.dispatch("USER_INFO"),
store.dispatch("GET_ALL_PROJECTS"),
store.dispatch("GET_STATIC_PAGES"),
store.dispatch("GET_USER_LEVEL_PROJECTS"),
store.dispatch("map/GET_AVAILABLE_LAYERS"),
store.dispatch("GET_USER_LEVEL_PERMISSIONS"),
]).then(axios.spread(function () {
new Vue({
router,
store,
render: h => h(App)
}).$mount('#app')
}))
}
})
.catch((error) => {
throw error;
});
......
......@@ -120,7 +120,7 @@ const routes = [
const router = new VueRouter({
mode: 'history',
base: process.env.BASE_URL,
base: '/geocontrib/',
routes,
routerHistory: [],
scrollBehavior(to, from, savedPosition) { //* record each route change to turn back to origin after redirect
......
......@@ -3,14 +3,15 @@ const fs = require('fs')
const packageJson = fs.readFileSync('./package.json')
const version = JSON.parse(packageJson).version || 0
module.exports = {
configureWebpack: {
plugins: [
new webpack.DefinePlugin({
'process.env': {
PACKAGE_VERSION: '"' + version + '"'
}
})
]
},
// the rest of your original module.exports code goes here
publicPath: '/geocontrib/',
configureWebpack: {
plugins: [
new webpack.DefinePlugin({
'process.env': {
PACKAGE_VERSION: '"' + version + '"'
}
})
]
},
// the rest of your original module.exports code goes here
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment