Browse Source

Merge branch 'dev' of http://git.ycjcjy.com/SpaceOfCheng/admin into dev

yuantianjiao 6 years ago
parent
commit
98f31606bf

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

@@ -202,6 +202,7 @@ export default {
202 202
         })
203 203
         return
204 204
       }
205
+      var that = this
205 206
       this.VipCharge({
206 207
         code: this.vip.VipCardChildCode,
207 208
         tel: this.customer.Phone,
@@ -212,6 +213,10 @@ export default {
212 213
           type: 'success',
213 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,7 +3,7 @@
3 3
     <form class="mainForm">
4 4
       <ul>
5 5
         <li class="flex-h">
6
-          <!-- <span>选择案场:</span> -->
6
+          <span>选择案场:</span>
7 7
           <div class="flex-item">
8 8
             <div style="width:50%">
9 9
               <el-select v-model="CaseId" placeholder="请选择">

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

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

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

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

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

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

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

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

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

@@ -79,9 +79,11 @@ export default {
79 79
     }),
80 80
     defaultChecked: {
81 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,11 +101,9 @@ export default {
99 101
       return this.toolClass.dateFormat(date)
100 102
     },
101 103
     handleSizeChange (val) {
102
-      console.log(`每页 ${val} 条`)
103 104
     },
104 105
     handleCurrentChange (val) {
105 106
       this.GetRolesList({ page: val })
106
-      console.log(`当前页: ${val}`)
107 107
     },
108 108
     handleEdit (index, row) {
109 109
       // 编辑
@@ -140,7 +140,6 @@ export default {
140 140
       this.dialogTableVisible = true
141 141
     },
142 142
     handleNodeClick (node) {
143
-      console.log(node)
144 143
     },
145 144
     searchList (key) {
146 145
       this.key = key
@@ -150,8 +149,7 @@ export default {
150 149
       this.$router.push({ name: 'editRole' })
151 150
     },
152 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 153
       this.SaveRoleMenus({
156 154
         id: this.selid,
157 155
         menuids: menuids,

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

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

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

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