first setup

This commit is contained in:
Afrina Alimi
2023-10-11 09:36:41 +08:00
parent db37a99c90
commit c4bebeac5d
3 changed files with 11152 additions and 66 deletions
+11142 -19
View File
File diff suppressed because it is too large Load Diff
+6 -5
View File
@@ -126,19 +126,20 @@ Vue.use(require('vue-pusher'), {
} }
}); });
Vue.prototype.$api1 = 'http://api.arrahn/' Vue.prototype.$api1 = 'http://api-xtra.test/'
Vue.prototype.$username = document.querySelector("meta[name='user_name']").getAttribute('content'); Vue.prototype.$username = document.querySelector("meta[name='user_name']").getAttribute('content');
Vue.prototype.$userroles = document.querySelector("meta[name='user_roles']").getAttribute('content'); Vue.prototype.$userroles = document.querySelector("meta[name='user_roles']").getAttribute('content');
let initial = 'KB2'; let initial = 'X0301';
let initialhostname = 'http://api.arrahn/'; let initialhostname = 'http://api-xtra.test/';
let initialtahun = new Date().getFullYear(); let initialtahun = new Date().getFullYear();
const store = new Vuex.Store({ const store = new Vuex.Store({
state: { state: {
$kodcaw: 'KB2', $kodcaw: 'X0301',
$hostname: 'http://api.arrahn/',
$hostname: 'http://api-xtra.test/',
$tahun: new Date().getFullYear() $tahun: new Date().getFullYear()
}, },
plugins: [createPersistedState()], plugins: [createPersistedState()],
+4 -42
View File
@@ -71,51 +71,13 @@
}, },
pembahagiancawangan: function(cawangannama){ pembahagiancawangan: function(cawangannama){
switch (cawangannama) { switch (cawangannama) {
case 'KB2': case 'X0301':
case 'WCY': case 'X0201':
case '1STOP':
case '020301':
case 'WB':
case 'ALS':
case '020306':
case 'ARM':
case 'APM':
case '010311':
case 'GC':
case 'JLI':
case 'ARP':
case '020303':{ case '020303':{
this.sethostname('http://api.arrahn') this.sethostname('http://api-xtra.test/')
break; break;
} }
case '010621': default: this.sethostname('http://api-xtra.test/')
case '010136':
case '011235':
case '010620':
case '010617':
case '010915':
case '010219':
case '010618':
case '011013':
case '011412':{
// this.$hostname = 'http://api2.arrahn'
this.sethostname('http://api2.arrahn')
break;
}
case '011229':
case '011230':
case '011227':
case '011231':
case '011232':
case '011228':
case '011234':
case '011237':
case '011233':{
// this.$hostname = 'http://api3.arrahn'
this.sethostname('http://api2.arrahn')
break;
}
default: this.sethostname('http://api.arrahn')
break; break;
} }
} }