update:同步CID用数据
This commit is contained in:
@@ -10,7 +10,8 @@
|
||||
:props="{
|
||||
TENANT_ID,
|
||||
TOKEN,
|
||||
USER_ID
|
||||
USER_ID,
|
||||
USER_INFO_DATA
|
||||
}"
|
||||
/>
|
||||
</template>
|
||||
@@ -23,6 +24,7 @@ import Cookies from 'js-cookie';
|
||||
|
||||
// const SPDM_URL = 'http://192.168.65.64:3001';
|
||||
const SPDM_URL = 'http://192.168.65.161:80';
|
||||
const USER_INFO_DATA = Cookies.get('cid_user_info');
|
||||
const USER_ID = Cookies.get('cid_user_id');
|
||||
const TENANT_ID = Cookies.get('cid_tenant_id');
|
||||
const TOKEN = Cookies.get('cid_token');
|
||||
|
||||
@@ -56,6 +56,8 @@ export const useUserInfo = defineStore('userInfo', {
|
||||
return new Promise((resolve, reject) => {
|
||||
login(data)
|
||||
.then(({data: res}) => {
|
||||
// SPDM子应用使用
|
||||
Cookies.set('cid_user_info', JSON.stringify(res))
|
||||
Cookies.set('cid_user_id', res.user_id)
|
||||
Session.setTenant(res.tenant_id);
|
||||
// 存储token 信息
|
||||
|
||||
Reference in New Issue
Block a user