Browse Source

联调修复

wangfei 6 years ago
parent
commit
4d9248d9c9

+ 5
- 0
src/pages/system/cardAndCouponManager/vipManager/activateVip.vue View File

202
         })
202
         })
203
         return
203
         return
204
       }
204
       }
205
+      var that = this
205
       this.VipCharge({
206
       this.VipCharge({
206
         code: this.vip.VipCardChildCode,
207
         code: this.vip.VipCardChildCode,
207
         tel: this.customer.Phone,
208
         tel: this.customer.Phone,
212
           type: 'success',
213
           type: 'success',
213
           message: '激活成功!',
214
           message: '激活成功!',
214
         })
215
         })
216
+        setTimeout(() => {
217
+          that.setNull()
218
+          that.centerDialogVisible = false
219
+        }, 1000)
215
       })
220
       })
216
     },
221
     },
217
   },
222
   },

+ 1
- 1
src/pages/system/channelManager/channelList/add.vue View File

3
     <form class="mainForm">
3
     <form class="mainForm">
4
       <ul>
4
       <ul>
5
         <li class="flex-h">
5
         <li class="flex-h">
6
-          <!-- <span>选择案场:</span> -->
6
+          <span>选择案场:</span>
7
           <div class="flex-item">
7
           <div class="flex-item">
8
             <div style="width:50%">
8
             <div style="width:50%">
9
               <el-select v-model="CaseId" placeholder="请选择">
9
               <el-select v-model="CaseId" placeholder="请选择">

+ 1
- 1
src/pages/system/channelManager/channelList/edit.vue View File

3
     <form class="mainForm">
3
     <form class="mainForm">
4
       <ul>
4
       <ul>
5
         <li class="flex-h">
5
         <li class="flex-h">
6
-          <!-- <span>选择案场:</span> -->
6
+          <span>选择案场:</span>
7
           <div class="flex-item">
7
           <div class="flex-item">
8
             <div style="width:50%">
8
             <div style="width:50%">
9
               <el-select v-model="CaseId" placeholder="请选择">
9
               <el-select v-model="CaseId" placeholder="请选择">

+ 4
- 2
src/pages/system/courseManager/courseList/add.vue View File

323
         if (!this.detail.CaseId || this.detail.CaseId === '') {
323
         if (!this.detail.CaseId || this.detail.CaseId === '') {
324
           this.detail.CaseId = this.caseid
324
           this.detail.CaseId = this.caseid
325
         }
325
         }
326
-        this.AddCourse(this.detail)
326
+        this.AddCourse({...this.detail, callback: _that.afterSave})
327
       } else {
327
       } else {
328
-        this.UpdateCourse(this.detail)
328
+        this.UpdateCourse({...this.detail, callback: _that.afterSave})
329
       }
329
       }
330
+    },
331
+    afterSave () {
330
       this.$message({
332
       this.$message({
331
         type: 'success',
333
         type: 'success',
332
         message: '操作成功'
334
         message: '操作成功'

+ 1
- 1
src/pages/system/goodsManager/goodsSpecManager/add.vue View File

15
           </div>
15
           </div>
16
         </li>
16
         </li>
17
         <li class="flex-h">
17
         <li class="flex-h">
18
-          <!-- <span>选择案场:</span> -->
18
+          <span>选择案场:</span>
19
           <div class="flex-item">
19
           <div class="flex-item">
20
             <div style="width:50%">
20
             <div style="width:50%">
21
               <el-select v-model="CaseId" placeholder="请选择">
21
               <el-select v-model="CaseId" placeholder="请选择">

+ 1
- 1
src/pages/system/goodsManager/goodsSpecManager/edit.vue View File

15
           </div>
15
           </div>
16
         </li>
16
         </li>
17
         <li class="flex-h">
17
         <li class="flex-h">
18
-          <!-- <span>选择案场:</span> -->
18
+          <span>选择案场:</span>
19
           <div class="flex-item">
19
           <div class="flex-item">
20
             <div style="width:50%">
20
             <div style="width:50%">
21
               <el-select v-model="CaseId" placeholder="请选择">
21
               <el-select v-model="CaseId" placeholder="请选择">

+ 6
- 8
src/pages/system/systemSet/roleManager/index.vue View File

79
     }),
79
     }),
80
     defaultChecked: {
80
     defaultChecked: {
81
       get () {
81
       get () {
82
-        const sels = (this.roleMenus || []).map(x => x.MenuId)
83
-        console.log(sels)
84
-        return sels
82
+        if (this.roleMenus.length && this.roleMenus.length > 0) {
83
+          const sels = (this.roleMenus || []).map(x => x.MenuId)
84
+          return sels
85
+        }
86
+        return []
85
       },
87
       },
86
     },
88
     },
87
   },
89
   },
99
       return this.toolClass.dateFormat(date)
101
       return this.toolClass.dateFormat(date)
100
     },
102
     },
101
     handleSizeChange (val) {
103
     handleSizeChange (val) {
102
-      console.log(`每页 ${val} 条`)
103
     },
104
     },
104
     handleCurrentChange (val) {
105
     handleCurrentChange (val) {
105
       this.GetRolesList({ page: val })
106
       this.GetRolesList({ page: val })
106
-      console.log(`当前页: ${val}`)
107
     },
107
     },
108
     handleEdit (index, row) {
108
     handleEdit (index, row) {
109
       // 编辑
109
       // 编辑
140
       this.dialogTableVisible = true
140
       this.dialogTableVisible = true
141
     },
141
     },
142
     handleNodeClick (node) {
142
     handleNodeClick (node) {
143
-      console.log(node)
144
     },
143
     },
145
     searchList (key) {
144
     searchList (key) {
146
       this.key = key
145
       this.key = key
150
       this.$router.push({ name: 'editRole' })
149
       this.$router.push({ name: 'editRole' })
151
     },
150
     },
152
     getCheckedNodes () { // 获取选中的节点
151
     getCheckedNodes () { // 获取选中的节点
153
-      const menuids = this.$refs.tree.getCheckedNodes().map(x => x.id).join(',')
154
-      console.log(menuids)
152
+      const menuids = (this.$refs.tree.getCheckedNodes() || []).map(x => x.id).join(',')
155
       this.SaveRoleMenus({
153
       this.SaveRoleMenus({
156
         id: this.selid,
154
         id: this.selid,
157
         menuids: menuids,
155
         menuids: menuids,

+ 4
- 4
src/pages/system/systemSet/userManager/add.vue View File

23
                 :action='$api.file.image.url'
23
                 :action='$api.file.image.url'
24
                 :show-file-list="false"
24
                 :show-file-list="false"
25
                 :on-success="handleAvatarSuccess">
25
                 :on-success="handleAvatarSuccess">
26
-                <img v-if="postData.HeadImgUrl" :src="postData.HeadImgUrl" class="avatar">
26
+                <img v-if="postData.Headimgurl" :src="postData.Headimgurl" class="avatar">
27
                 <i v-else class="el-icon-plus avatar-uploader-icon"></i>
27
                 <i v-else class="el-icon-plus avatar-uploader-icon"></i>
28
               </el-upload>
28
               </el-upload>
29
             </div>
29
             </div>
59
             <div style="width:50%">
59
             <div style="width:50%">
60
               <el-input
60
               <el-input
61
                 placeholder="请输入工号"
61
                 placeholder="请输入工号"
62
-                v-model="postData.workNo"
62
+                v-model="postData.WorkNo"
63
                 clearable>
63
                 clearable>
64
               </el-input>
64
               </el-input>
65
             </div>
65
             </div>
145
         WorkNo: '', // 工号
145
         WorkNo: '', // 工号
146
         Email: '', // 邮箱
146
         Email: '', // 邮箱
147
         Phone: '', // 手机号
147
         Phone: '', // 手机号
148
-        HeadImgUrl: '', // 头像
148
+        Headimgurl: '', // 头像
149
         TypeId: '', // 用户类型id
149
         TypeId: '', // 用户类型id
150
         TagIds: '', // 用户标签
150
         TagIds: '', // 用户标签
151
         BelongCaseId: '', // 所属案场id
151
         BelongCaseId: '', // 所属案场id
192
       this.postData.TagIds = val.join(',')
192
       this.postData.TagIds = val.join(',')
193
     },
193
     },
194
     handleAvatarSuccess (res, file) {
194
     handleAvatarSuccess (res, file) {
195
-      this.postData.HeadImgUrl = res.result.url
195
+      this.postData.Headimgurl = res.result.url
196
     },
196
     },
197
     submit () { // 提交数据
197
     submit () { // 提交数据
198
       if (this.postData.UserName === '') {
198
       if (this.postData.UserName === '') {

+ 10
- 9
src/pages/system/systemSet/userManager/edit.vue View File

23
                 :action='$api.file.image.url'
23
                 :action='$api.file.image.url'
24
                 :show-file-list="false"
24
                 :show-file-list="false"
25
                 :on-success="handleAvatarSuccess">
25
                 :on-success="handleAvatarSuccess">
26
-                <img v-if="postData.HeadImgUrl" :src="postData.HeadImgUrl" class="avatar">
26
+                <img v-if="postData.Headimgurl" :src="postData.Headimgurl" class="avatar">
27
                 <i v-else class="el-icon-plus avatar-uploader-icon"></i>
27
                 <i v-else class="el-icon-plus avatar-uploader-icon"></i>
28
               </el-upload>
28
               </el-upload>
29
             </div>
29
             </div>
59
             <div style="width:50%">
59
             <div style="width:50%">
60
               <el-input
60
               <el-input
61
                 placeholder="请输入工号"
61
                 placeholder="请输入工号"
62
-                v-model="postData.workNo"
62
+                v-model="postData.WorkNo"
63
                 clearable>
63
                 clearable>
64
               </el-input>
64
               </el-input>
65
             </div>
65
             </div>
105
         <li class="flex-h">
105
         <li class="flex-h">
106
           <span>选择案场:</span>
106
           <span>选择案场:</span>
107
           <div class="flex-item">
107
           <div class="flex-item">
108
-            <el-select v-model="CaseId" placeholder="请选择">
108
+            <el-select v-model="BelongCaseId" placeholder="请选择">
109
               <el-option
109
               <el-option
110
                 v-for="item in cases"
110
                 v-for="item in cases"
111
                 :key="item.CaseId"
111
                 :key="item.CaseId"
145
         WorkNo: '', // 工号
145
         WorkNo: '', // 工号
146
         Email: '', // 邮箱
146
         Email: '', // 邮箱
147
         Phone: '', // 手机号
147
         Phone: '', // 手机号
148
-        HeadImgUrl: '', // 头像
148
+        Headimgurl: '', // 头像
149
         TypeId: '', // 用户类型id
149
         TypeId: '', // 用户类型id
150
         TagIds: '', // 用户标签
150
         TagIds: '', // 用户标签
151
-        BelongCaseId: '', // 所属案场id
151
+        BelongCaseId: '',
152
+        UserCase: [],
152
       }
153
       }
153
     }
154
     }
154
   },
155
   },
158
       cases: x => x.app.cases.list,
159
       cases: x => x.app.cases.list,
159
       defaultCaseId: x => x.app.cases.default,
160
       defaultCaseId: x => x.app.cases.default,
160
     }),
161
     }),
161
-    CaseId: {
162
+    BelongCaseId: {
162
       get () {
163
       get () {
163
-        return this.postData.BelongCaseId || this.defaultCaseId
164
+        return ((this.postData.UserCase || []).filter(x => x.IsBelong === 1)[0] || {}).CaseId
164
       },
165
       },
165
       set (val) {
166
       set (val) {
166
         this.postData.BelongCaseId = val
167
         this.postData.BelongCaseId = val
209
       this.postData.TagIds = val.join(',')
210
       this.postData.TagIds = val.join(',')
210
     },
211
     },
211
     handleAvatarSuccess (res, file) {
212
     handleAvatarSuccess (res, file) {
212
-      this.postData.HeadImgUrl = res.result.url
213
+      this.postData.Headimgurl = res.result.url
213
     },
214
     },
214
     submit () { // 提交数据
215
     submit () { // 提交数据
215
       if (this.postData.UserName === '') {
216
       if (this.postData.UserName === '') {
234
         })
235
         })
235
         return false
236
         return false
236
       }
237
       }
237
-      if (this.postData.BelongCaseId === '') this.postData.BelongCaseId = this.CaseId
238
+      if (this.postData.BelongCaseId === '') this.postData.BelongCaseId = this.BelongCaseId
238
       if (this.postData.TagIds === '') this.postData.TagIds = this.TagIds.join(',')
239
       if (this.postData.TagIds === '') this.postData.TagIds = this.TagIds.join(',')
239
       this.$ajax(this.$api.systemSet.editUser.url, {
240
       this.$ajax(this.$api.systemSet.editUser.url, {
240
         method: this.$api.systemSet.editUser.method,
241
         method: this.$api.systemSet.editUser.method,