From fe27651e34167e464c1a1578efab1e16154edc90 Mon Sep 17 00:00:00 2001 From: Xuan Loi Date: Fri, 16 Jan 2026 10:28:24 +0700 Subject: [PATCH] changes --- components/user/SetPassword.vue | 2 +- plugins/02-connection.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/components/user/SetPassword.vue b/components/user/SetPassword.vue index 7eaec35..00c6770 100644 --- a/components/user/SetPassword.vue +++ b/components/user/SetPassword.vue @@ -63,7 +63,7 @@ export default { async changePassword() { if(!this.checkPassword()) return let user = await this.$getdata('user', undefined, {filter: {id: this.row.id}}, true) - const response = await fetch(`https://api.y99.vn/password/${this.password}/`) + const response = await fetch(`${this.$getpath()}password/${this.password}/`) let hash = await response.json(); user.password = hash let rs1 = await this.$updateapi('user', user) diff --git a/plugins/02-connection.js b/plugins/02-connection.js index f09cc5d..1e6a838 100644 --- a/plugins/02-connection.js +++ b/plugins/02-connection.js @@ -4,7 +4,7 @@ import axios from 'axios' export default defineNuxtPlugin(() => { const module = 'system' - const mode = 'prod' + const mode = 'dev' const paths = [ { name: "dev", url: "https://dev.api.utopia.com.vn/" }, { name: "local", url: "http://localhost:8000/" }, @@ -141,7 +141,7 @@ export default defineNuxtPlugin(() => { const requestLogin = function() { store.commit('login', undefined) - window.location.href = `https://${mode==='dev'? '' : ''}login.utopia.com.vn/signin?module=${module}&link=${window.location.origin}` + window.location.href = `https://${mode==='dev'? 'dev.' : ''}login.utopia.com.vn/signin?module=${module}&link=${window.location.origin}` }