Browse Source

零星收费修改

王新雷 4 năm trước cách đây
mục cha
commit
2bc5aef3e6

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/index.html


+ 0 - 1
dist/static/css/chunk-3117c8bc.34efb1f8.css

@@ -1 +0,0 @@
-.right-code .title[data-v-3830fd38]{font-size:18px;text-align:center;padding-bottom:8px}.newBand[data-v-3830fd38]{display:inline-block}

+ 1 - 0
dist/static/css/chunk-96232cd8.467a1756.css

@@ -0,0 +1 @@
+.right-code .title[data-v-066cd54a]{font-size:18px;text-align:center;padding-bottom:8px}.newBand[data-v-066cd54a]{display:inline-block}

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/static/js/app.cea3a874.js


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/static/js/chunk-3117c8bc.f0dfb54f.js


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 0 - 0
dist/static/js/chunk-96232cd8.af7c0581.js


+ 8 - 0
src/api/zeroManager.js

@@ -10,6 +10,14 @@ export function addZero (data) {
   })
 }
 
+export function updateZero (data) {
+  return request({
+    url: api + '/sporadicChargeInfo/update',
+    method: 'POST',
+    data: qs.stringify(data)
+  })
+}
+
 export function getZero (data) {
   return request({
     url: api + '/sporadicChargeInfo/queryPage',

+ 28 - 7
src/views/sporadicManager/sporadicList.vue

@@ -134,9 +134,14 @@
                            label="操作">
             <template slot-scope="scope">
               <div>
-                <el-button type="text"
+                <el-button type="text" v-if="scope.row.chargeType == 12" key="update"
+                           v-permission="'sporadicChargeInfo/update'"
+                           @click="lookVisible(scope.row)">修改</el-button>
+                <el-button type="text" v-else  key="update"
                            v-permission="'sporadicChargeInfo/look'"
                            @click="lookVisible(scope.row)">查看</el-button>
+
+
                 <el-button type="text"
                            v-permission="'sporadicChargeInfo/delete'"
                            @click="removeItem(scope.row)">删除</el-button>
@@ -194,11 +199,10 @@
                     :disabled='!isNew'></el-input>
         </el-form-item>
         <el-form-item label="报名人数"
-                      v-if="maskForm.type == 12">
+                      v-show="maskForm.type == 12">
           <el-input v-model.trim="maskForm.maxNum"
                     type="number"
-                    @mousewheel.native.prevent
-                    :disabled='!isNew'></el-input>
+                    @mousewheel.native.prevent></el-input>
         </el-form-item>
         <el-form-item label="减免金额"
                       v-if="maskForm.type == 6"
@@ -258,7 +262,7 @@
                    @click="addZero">确 定</el-button>
         <el-button v-if="!isNew"
                    type="primary"
-                   @click="zeroVisible = false">确定</el-button>
+                   @click="updateZero">确定</el-button>
       </span>
     </el-dialog>
 
@@ -373,7 +377,7 @@
 import { getEmployeeOrgan } from '@/api/buildTeam'
 import pagination from '@/components/Pagination/index'
 import { vaildStudentUrl } from '@/utils/validate'
-import { addZero, getZero, removeZero, getBasic, updateOpenFlag, queryOrganMusicInfos, queryUserMusicInfos } from '@/api/zeroManager'
+import { addZero, getZero, updateZero, removeZero, getBasic, updateOpenFlag, queryOrganMusicInfos, queryUserMusicInfos } from '@/api/zeroManager'
 import axios from 'axios'
 import qs from 'qs'
 import {
@@ -525,7 +529,6 @@ export default {
           musicGroupId: null,
           type: null,
           money: null,
-          maxNum: null,
           desc: null,
           title: null,
           code: null
@@ -578,6 +581,7 @@ export default {
         maskForm.code = url
       }
       maskForm.type = parseInt(row.chargeType)
+      maskForm.id = row.id
       maskForm.desc = row.detail
       maskForm.title = row.title
       maskForm.organId = row.organId
@@ -610,6 +614,23 @@ export default {
         }
       })
     },
+    updateZero() {
+      let maskForm = this.maskForm
+      // 
+      console.log(maskForm)
+      if(maskForm.type != 12) {
+        this.zeroVisible = false
+        return
+      }
+
+      updateZero({ id: maskForm.id, maxNum: maskForm.maxNum }).then(res => {
+        if (res.code == 200) {
+            this.$message.success('更新成功')
+            this.zeroVisible = false;
+            this.getList()
+          }
+      })
+    },
     addZero () {
       this.$refs['maskForm'].validate(item => {
         if (item) {

Một số tệp đã không được hiển thị bởi vì quá nhiều tập tin thay đổi trong này khác