|
|
@ -1,9 +1,15 @@ |
|
|
|
/** @format */ |
|
|
|
import { dateUtil } from '/nerv-lib/util/date-util'; |
|
|
|
import mockResource from './resource.json'; |
|
|
|
import { http } from '/nerv-lib/saas'; |
|
|
|
import { ref } from 'vue'; |
|
|
|
const value = ref('1'); |
|
|
|
|
|
|
|
const transform = (data, map) => { |
|
|
|
return Object.keys(map).reduce((pre, cur) => { |
|
|
|
pre[cur] = data[map[cur]]; |
|
|
|
return pre; |
|
|
|
}, {}); |
|
|
|
}; |
|
|
|
export const appConfig = { |
|
|
|
projectType: 'web', |
|
|
|
baseApi: '/api', |
|
|
@ -21,6 +27,25 @@ export const appConfig = { |
|
|
|
// },
|
|
|
|
|
|
|
|
// customUpdatePwd: () => import('/@/view/updatePassword/updatePassword.vue'),
|
|
|
|
|
|
|
|
// userInfoApi: () => {
|
|
|
|
// return {
|
|
|
|
// code: 200,
|
|
|
|
// success: true,
|
|
|
|
// data: {
|
|
|
|
// accountCode: '1305107806187376793',
|
|
|
|
// accountName: 'adm*n',
|
|
|
|
// accountType: 'admin',
|
|
|
|
// accountStatus: 1,
|
|
|
|
// accountRealName: 'admin',
|
|
|
|
// organizationCode: 'dingcloud',
|
|
|
|
// authConfigList: [],
|
|
|
|
// organizeResCode: [],
|
|
|
|
// leadDepartmentUuidList: [],
|
|
|
|
// },
|
|
|
|
// };
|
|
|
|
// },
|
|
|
|
|
|
|
|
headerSlotConfig: { |
|
|
|
component: 'NsSelect', |
|
|
|
componentProps: { |
|
|
@ -42,22 +67,17 @@ export const appConfig = { |
|
|
|
return { data: mockResource.menus }; |
|
|
|
}, |
|
|
|
userInfoApi: () => { |
|
|
|
return { |
|
|
|
code: 200, |
|
|
|
success: true, |
|
|
|
data: { |
|
|
|
accountCode: '1305107806187376793', |
|
|
|
accountName: 'adm*n', |
|
|
|
accountType: 'admin', |
|
|
|
accountStatus: 1, |
|
|
|
accountRealName: 'admin', |
|
|
|
organizationCode: 'dingcloud', |
|
|
|
authConfigList: [], |
|
|
|
organizeResCode: [], |
|
|
|
leadDepartmentUuidList: [], |
|
|
|
}, |
|
|
|
}; |
|
|
|
return http.post('/carbon-smart/user/login/logInInfo').then((res) => { |
|
|
|
const info = res.data; |
|
|
|
const trD = transform(info, { |
|
|
|
accountCode: 'userId', |
|
|
|
accountName: 'realName', |
|
|
|
accountRealName: 'realName', |
|
|
|
}); |
|
|
|
return { data: { ...trD } }; |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
useHistoryTag: false, |
|
|
|
// 修改密码配置
|
|
|
|
updatePassWordInfo: { |
|
|
|