Commit 644a8f8b authored by 罗超's avatar 罗超

调整

parent c2a5c88e
# 开发环境配置 - 使用Mock数据
VITE_OTA_API_BASE_URL=http://192.168.5.39:8081/api/app/
VITE_ERP_API_BASE_URL=http://192.168.5.214:8700/
VITE_OTA_API_BASE_URL=http://localhost:19002/api/app/
VITE_ERP_API_BASE_URL=http://192.168.5.204/
VITE_FILEUPLOAD_API_BASE_URL=http://192.168.5.214:8120/
VITE_FILEPREVIEW_API_BASE_URL=http://192.168.5.214:8130/
# 开发环境特定配置
......
......@@ -100,12 +100,9 @@ service.interceptors.response.use(
response.data.resultCode == ApiResult.REMOTE_LOGIN
) {
ResultMessage.Error(response.data.message)
console.log(response.data.message)
setTimeout(() => {
useUserStore().signOutAsync()
}, 1000)
}
window.location.href = '/login'
//window.location.href = '/login'
datas = response
return Promise.resolve(datas)
} else {
......
......@@ -35,6 +35,11 @@ export default class ErpUserService {
return Api.Post('admin_get_EmployeeList', msg)
}
static async GetGroupAdmininfoAsync(id:number): Promise<HttpResponse> {
const msg = {Id:id}
return Api.Post('admin_get_GetIdByAdminAccount', msg)
}
/**
* 谷歌登录
* @param credential 谷歌token
......
......@@ -161,10 +161,10 @@ export const useSystemConfigStore = defineStore('systemConfig', {
* 获取分组信息
*/
async getGroupInfoAsync(groupId:number) {
// const groupInfo = await ErpUserService.GetGroupInfoAsync(groupId)
// if(groupInfo.data.resultCode === ApiResult.SUCCESS) {
// this.erpAdminUserId = groupInfo.data.data.pageData[0].EmployeeId || 0
// }
const groupInfo = await ErpUserService.GetGroupAdmininfoAsync(groupId)
if(groupInfo.data.resultCode === ApiResult.SUCCESS) {
this.erpAdminUserId = groupInfo.data.data
}
},
/**
......@@ -193,7 +193,7 @@ export const useSystemConfigStore = defineStore('systemConfig', {
this.platformConfig = data.platform || null
this.config = data.config
this.groupId = data.erpGroupId || 2
this.groupId = data.erpGroupId
// 如果有租户ID,加载代理商配置
if (this.tenantId) {
await this.getGroupInfoAsync(this.groupId)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment