Browse Source

配件申请 配件回收 新增 领用部门领用人 更换数据获取方式

8521520123jsy 1 year ago
parent
commit
309621d713

+ 5 - 1
src/views/salesServiceManagement/accessory/components/accessoryDialog.vue

@@ -166,6 +166,7 @@ import {
   accessorySave,
   accessoryUpdate
 } from '@/api/salesServiceManagement/index';
+import { getCurrentUser } from '@/utils/token-util';
 
 export default {
   data() {
@@ -188,7 +189,9 @@ export default {
   },
   methods: {
     init(row, type) {
-      let currentUser = JSON.parse(sessionStorage['currentUser']);
+      // let currentUser = JSON.parse(sessionStorage['currentUser']);
+      let currentUser = getCurrentUser();
+      console.log(currentUser,'currentUser')
       this.form.receivingDeptId = currentUser.currentGroupId; // 部门id
       this.roleVOListData();
       this.addRepairNotesDialog = true;
@@ -202,6 +205,7 @@ export default {
         // 下拉数据 name 赋值
         this.echoData();
       }
+      console.log(this.form,'form --')
     },
     getDetail(data) {
       const row = JSON.parse(JSON.stringify(data));

+ 4 - 1
src/views/salesServiceManagement/recycle/component/recycleDialog.vue

@@ -174,6 +174,7 @@ import {
   getSalesWorkOrderById,
   recycleDetails
 } from '@/api/salesServiceManagement/index';
+import { getCurrentUser } from '@/utils/token-util';
 export default {
   props: {},
   components: { workOrderList, spareInfo },
@@ -210,7 +211,8 @@ export default {
       this.editRepairNotesDialog = true;
       this.type = type;
       this.title = type == 'add' ? '新增' : type == 'edit' ? '编辑' : '详情';
-      let currentUser = JSON.parse(sessionStorage['currentUser']);
+      // let currentUser = JSON.parse(sessionStorage['currentUser']);
+      let currentUser = getCurrentUser();
       this.form.recycleDeptId = currentUser.currentGroupId; // 部门id
       this.roleVOListData();
       if (row?.id) {
@@ -220,6 +222,7 @@ export default {
         // 下拉数据 name 赋值
         this.echoData();
       }
+      console.log(this.form,'form --')
     },
     async getDetail(data) {
       const row = JSON.parse(JSON.stringify(data));

+ 1 - 0
src/views/salesServiceManagement/recycle/index.vue

@@ -99,6 +99,7 @@ export default {
           align: 'center',
           showOverflowTooltip: true,
           formatter: (row) => {
+            console.log(row,'row 数据')
             if (!row.details) return '';
             let str = '';
             row.details.map((el, idx) => {