Update to use v2
This commit is contained in:
parent
5ded3b16f0
commit
9ec7e1c65f
5 changed files with 14 additions and 8 deletions
2
.env
2
.env
|
@ -1,5 +1,5 @@
|
||||||
VUE_APP_APIENDPOINT=/api/
|
VUE_APP_APIENDPOINT=/api/
|
||||||
VUE_APP_APIVERSION=v1
|
VUE_APP_APIVERSION=v2
|
||||||
VUE_APP_GATEWAYENDPOINT=/socket.io/
|
VUE_APP_GATEWAYENDPOINT=/socket.io/
|
||||||
VUE_APP_STAGING=true
|
VUE_APP_STAGING=true
|
||||||
VUE_APP_I18N_LOCALE=en
|
VUE_APP_I18N_LOCALE=en
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
VUE_APP_APIENDPOINT="/api/"
|
VUE_APP_APIENDPOINT="/api/"
|
||||||
VUE_APP_APIVERSION="v1"
|
VUE_APP_APIVERSION="v2"
|
||||||
VUE_APP_GATEWAYENDPOINT="/socket.io/"
|
VUE_APP_GATEWAYENDPOINT="/socket.io/"
|
||||||
VUE_APP_STAGING=true
|
VUE_APP_STAGING=true
|
||||||
VUE_APP_RELEASE="Canary"
|
VUE_APP_RELEASE="Canary"
|
|
@ -475,7 +475,8 @@ export default {
|
||||||
doRegister() {
|
doRegister() {
|
||||||
this.register.loading = true;
|
this.register.loading = true;
|
||||||
this.axios
|
this.axios
|
||||||
.post("/api/v1/passkey/register", {
|
.post(process.env.VUE_APP_APIENDPOINT +
|
||||||
|
process.env.VUE_APP_APIVERSION + "/passkey/register", {
|
||||||
username: this.register.username,
|
username: this.register.username,
|
||||||
password: this.register.password,
|
password: this.register.password,
|
||||||
email: this.register.email,
|
email: this.register.email,
|
||||||
|
@ -510,7 +511,8 @@ export default {
|
||||||
doLogin() {
|
doLogin() {
|
||||||
this.login.loading = true;
|
this.login.loading = true;
|
||||||
this.axios
|
this.axios
|
||||||
.post("/api/v1/users/login", {
|
.post(process.env.VUE_APP_APIENDPOINT +
|
||||||
|
process.env.VUE_APP_APIVERSION + "/users/login", {
|
||||||
username: this.login.username,
|
username: this.login.username,
|
||||||
password: this.login.password,
|
password: this.login.password,
|
||||||
})
|
})
|
||||||
|
|
|
@ -53,7 +53,8 @@ export default {
|
||||||
},
|
},
|
||||||
authTest() {
|
authTest() {
|
||||||
this.axios
|
this.axios
|
||||||
.get("/api/v1/userinfo/auth")
|
.get(process.env.VUE_APP_APIENDPOINT +
|
||||||
|
process.env.VUE_APP_APIVERSION + "/userinfo/auth")
|
||||||
.then(() => {
|
.then(() => {
|
||||||
this.$buefy.snackbar.open({
|
this.$buefy.snackbar.open({
|
||||||
message: this.$t("errors.authSuccess"),
|
message: this.$t("errors.authSuccess"),
|
||||||
|
|
|
@ -185,7 +185,8 @@ export default {
|
||||||
},
|
},
|
||||||
doInit() {
|
doInit() {
|
||||||
this.register.init.loading = true
|
this.register.init.loading = true
|
||||||
this.axios.post('/api/v1/passkey/register', {
|
this.axios.post(process.env.VUE_APP_APIENDPOINT +
|
||||||
|
process.env.VUE_APP_APIVERSION + '/passkey/register', {
|
||||||
username: this.register.init.username,
|
username: this.register.init.username,
|
||||||
password: this.register.init.password,
|
password: this.register.init.password,
|
||||||
email: this.register.init.email,
|
email: this.register.init.email,
|
||||||
|
@ -206,7 +207,8 @@ export default {
|
||||||
},
|
},
|
||||||
doInfo() {
|
doInfo() {
|
||||||
this.register.personal.loading = true
|
this.register.personal.loading = true
|
||||||
this.axios.put('/api/v1/users/preferences', {
|
this.axios.put(process.env.VUE_APP_APIENDPOINT +
|
||||||
|
process.env.VUE_APP_APIVERSION + '/users/preferences', {
|
||||||
description: this.register.personal.description
|
description: this.register.personal.description
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
this.getInfo()
|
this.getInfo()
|
||||||
|
@ -220,7 +222,8 @@ export default {
|
||||||
},
|
},
|
||||||
doTheme(theme) {
|
doTheme(theme) {
|
||||||
this.register.customization.loading = true
|
this.register.customization.loading = true
|
||||||
this.axios.put('/api/v1/users/preferences', {
|
this.axios.put(process.env.VUE_APP_APIENDPOINT +
|
||||||
|
process.env.VUE_APP_APIVERSION + '/users/preferences', {
|
||||||
theme: theme
|
theme: theme
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
this.getInfo()
|
this.getInfo()
|
||||||
|
|
Loading…
Reference in a new issue