af-mobile-client-vue3 1.1.12 → 1.1.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "af-mobile-client-vue3",
3
3
  "type": "module",
4
- "version": "1.1.12",
4
+ "version": "1.1.13",
5
5
  "description": "Vue + Vite component lib",
6
6
  "license": "MIT",
7
7
  "engines": {
@@ -24,6 +24,10 @@ export interface UserInfo {
24
24
  avatar: string
25
25
  functions: Array<any>
26
26
  rolestr: string
27
+ f_operator: string
28
+ f_operatorid: string
29
+ f_orgid: string
30
+ f_orgname: string
27
31
  }
28
32
 
29
33
  interface IUserState {
@@ -1,11 +1,13 @@
1
1
  <script setup lang="ts">
2
2
  import XCellList from '@af-mobile-client-vue3/components/data/XCellList/index.vue'
3
3
  import NormalDataLayout from '@af-mobile-client-vue3/components/layout/NormalDataLayout/index.vue'
4
+ import { useUserStore } from '@af-mobile-client-vue3/stores/modules/user'
4
5
  import { defineEmits, ref } from 'vue'
5
6
  import { useRouter } from 'vue-router'
6
7
 
7
8
  // 定义事件
8
9
  const emit = defineEmits(['deleteRow'])
10
+ const userInfo = useUserStore().getUserInfo()
9
11
  // 访问路由
10
12
  const router = useRouter()
11
13
  // 获取默认值
@@ -89,6 +91,7 @@ function addOption(callback) {
89
91
 
90
92
  // 修改功能
91
93
  function updateRow(result, callback) {
94
+ console.log('用户----', userInfo)
92
95
  router.push({
93
96
  name: 'XFormGroupView',
94
97
  // params: { id: result.o_id, openid: result.o_id },
@@ -159,6 +159,7 @@ function closeWindows() {
159
159
  }
160
160
 
161
161
  async function afterGeneral(result) {
162
+ console.log('用户根本---', result)
162
163
  const user: UserInfo = {
163
164
  id: result.id,
164
165
  username: result.ename,
@@ -167,6 +168,10 @@ async function afterGeneral(result) {
167
168
  avatar: result.avatar ? result.avatar : setting.getSetting()?.defaultAvatarUrl,
168
169
  functions: result.functions,
169
170
  rolestr: result.rolestr,
171
+ f_operator: result.name,
172
+ f_operatorid: result.id,
173
+ f_orgid: result.orgid,
174
+ f_orgname: result.orgs,
170
175
  }
171
176
  userState.setUserInfo(user)
172
177
  // 如果result中没有返回 权限 需要主动获取权限列表