mo 2 年之前
父節點
當前提交
f8a699892a

+ 20 - 0
src/views/branchPayManager/api.js

@@ -20,3 +20,23 @@ export function getCoopCalenderList(data) {
     data
   })
 }
+
+
+export function getCoopShareList(data) {
+  return request2({
+    url: api + '/cooperationShareProfit/queryPage',
+    method: 'post',
+    // requestType:'form',
+    data
+  })
+}
+
+
+export function addCoopShare(data) {
+  return request2({
+    url: api + '/cooperationShareProfit/addCredentials',
+    method: 'post',
+    // requestType:'form',
+    data
+  })
+}

+ 65 - 12
src/views/branchPayManager/modals/addPayCode.vue

@@ -2,24 +2,77 @@
   <div>
     <el-dialog
       title="添加付款记录"
-      width="760px"
+      width="500px"
       :visible.sync="visitVisible"
       append-to-body
     >
-      <visit
-        v-if="visitVisible && activeRow"
-        :detail="activeRow"
-        :username="activeRow.username"
-        @close="visitVisible = false"
-        @submited="getList"
-        :isMainGo="false"
-        :useVisitType="false"
-      />
+      <el-form :model="form" ref="ruleForm" @close="closeDialog">
+        <el-form-item
+          label="付款流水号"
+          prop="paymentNo"
+          :rules="[{ required: true, message: '请输入付款流水号' }]"
+        >
+          <el-input v-model.trim="form.paymentNo" autocomplete="off"></el-input>
+        </el-form-item>
+        <el-form-item
+          label="备注"
+          prop="memo"
+        >
+          <el-input :rows="3" type="textarea" placeholder="请输入付款备注" v-model.trim="form.memo" autocomplete="off"></el-input>
+        </el-form-item>
+        <el-form-item label="上传凭证"  prop="credentials" :rules="[{ required: true, message: '请上传凭证' }]">
+        <div style="width: 80% !important">
+          <uploadImageList :uploaded="form.credentials" />
+          <!-- bucket_name="cooperation" -->
+        </div>
+      </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="visitVisible = false">取 消</el-button>
+        <el-button type="primary" @click="submit">确 定</el-button>
+      </span>
     </el-dialog>
   </div>
 </template>
 <script>
+import { addCoopShare } from '../api'
 export default {
-
-}
+  data() {
+    return {
+      visitVisible: false,
+      form:{
+        id:'',
+        paymentNo:'',
+        credentials:[],
+      }
+    };
+  },
+  mounted() {},
+  methods: {
+   async submit(){
+    console.log(this.form)
+    this.$refs.ruleForm.validate( async flag=>{
+      if(flag){
+        let {credentials,...reset} = this.form
+        let url = credentials.map(item=>{return item.url})
+        try{
+          const res = await addCoopShare({...reset,credentials:url.join(',')})
+          this.$message.success('添加成功')
+          this.$emit('getList')
+          this.closeDialog()
+        }catch(e){
+          console.log(e)
+        }
+      }
+    })
+   },
+    openDialog(row){
+      this.visitVisible = true
+    },
+    closeDialog(){
+      this.$refs.ruleForm.resetFields()
+      this.visitVisible = false
+    }
+  },
+};
 </script>

+ 8 - 0
src/views/branchPayManager/payList.vue

@@ -53,6 +53,12 @@
           <el-button native-type="reset" type="danger">重置</el-button>
         </el-form-item>
       </save-form>
+      <div style="font-size: 14px; color: #f85043; padding-bottom: 10px">
+
+        欠费总额:{{ amount | moneyFormat }}元<i
+          style="width: 10px; display: inline-block"
+        ></i>
+      </div>
       <div class="tableWrap">
         <el-table
           style="width: 100%"
@@ -161,6 +167,7 @@ export default {
         id: null,
       },
       resetVisible: false,
+      amount:0
     };
   },
   //生命周期 - 创建完成(可以访问当前this实例)
@@ -186,6 +193,7 @@ export default {
         const res = await getCoopRefundList(params);
         this.tableList = res.data.pageInfo.rows;
         this.rules.total = res.data.pageInfo.total;
+        this.amount = res.data.amount
       } catch (e) {
         console.log(e);
       }

+ 45 - 41
src/views/branchPayManager/payShareList.vue

@@ -31,9 +31,9 @@
             ></el-option>
           </el-select>
         </el-form-item>
-        <el-form-item prop="search">
+        <el-form-item prop="cooperationOrganId">
           <el-select
-            v-model.trim="searchForm.search"
+            v-model.trim="searchForm.cooperationOrganId"
             :disabled="!searchForm.organId"
             filterable
             clearable
@@ -53,8 +53,8 @@
             clearable
             placeholder="付款状态"
           >
-            <el-option label="已付款" :value="1"></el-option>
-            <el-option label="未付款" :value="0"></el-option>
+            <el-option label="已缴费" value="PAID_COMPLETED"></el-option>
+            <el-option label="未缴费" value="NON_PAYMENT"></el-option>
           </el-select>
         </el-form-item>
         <el-form-item>
@@ -75,20 +75,20 @@
           ></el-table-column>
           <el-table-column
             align="center"
-            prop="cooperationOrganName"
+            prop="cooperationName"
             label="合作单位"
           ></el-table-column>
           <el-table-column
             align="center"
-            prop="cooperationOrganName"
+            prop="musicGroupName"
             label="乐团"
           ></el-table-column>
           <el-table-column
             align="center"
-            prop="cooperationOrganName"
+            prop="musicalNum"
             label="乐器数量"
           ></el-table-column>
-          <el-table-column
+          <!-- <el-table-column
             align="center"
             prop="cooperationOrganName"
             label="分润金额(每件/元)"
@@ -98,7 +98,7 @@
                 {{ scope.row.receivable | moneyFormat }}
               </div>
             </template>
-          </el-table-column>
+          </el-table-column> -->
           <el-table-column
             align="center"
             prop="cooperationOrganName"
@@ -106,49 +106,45 @@
           >
             <template slot-scope="scope">
               <div>
-                {{ scope.row.receivable | moneyFormat }}
+                {{ scope.row.totalAmount | moneyFormat }}
               </div>
             </template></el-table-column
           >
-          <el-table-column align="center" prop="studentId" label="乐团主管">
-            <template slot-scope="scope">
-              <div>
-                {{ scope.row.receivable | moneyFormat }}
-              </div>
-            </template>
+          <el-table-column align="center" prop="educationUserName" label="乐团主管">
+
           </el-table-column>
           <el-table-column align="center" prop="studentId" label="付款状态">
             <template slot-scope="scope">
               <div>
-                {{ scope.row.income | moneyFormat }}
+                {{ scope.row.paymentStatus | paymentStatusDetall }}
               </div>
             </template>
           </el-table-column>
-          <el-table-column align="center" prop="studentId" label="付款流水号">
-            <template slot-scope="scope">
-              <div>
-                {{ scope.row.prepaidFee | moneyFormat }}
-              </div>
-            </template>
+          <el-table-column align="center" prop="paymentNo" label="付款流水号">
           </el-table-column>
           <el-table-column
             align="center"
-            prop="备注"
-            label="乐团主管"
+            prop="memo"
+            label="备注"
             width="100px"
           >
           </el-table-column>
           <el-table-column align="center" prop="studentId" label="凭证">
             <template slot-scope="scope">
-              <div>
-                {{ scope.row.prepaidFee | moneyFormat }}
-              </div>
-            </template>
+            <el-image
+              v-if="scope.row.credentials"
+              style="width: 60px; height: 60px"
+              fit="cover"
+              :src="scope.row.credentials.split(',')[0]"
+              :previewSrcList="scope.row.credentials.split(',')"
+            >
+            </el-image>
+          </template>
           </el-table-column>
           <el-table-column align="center" prop="studentId" label="操作">
             <template slot-scope="scope">
               <div>
-                <auth auths="musicGroupCalenderRefundPeriod/queryCoopCalender">
+                <auth auths="cooperationShareProfit/addCredentials">
                   <el-button type="text" @click="addPayCode(scope.row)"
                     >添加付款记录</el-button
                   >
@@ -167,6 +163,7 @@
         />
       </div>
     </div>
+    <addPayCode  ref='addPayCode' @getList="getList"/>
   </div>
 </template>
 
@@ -178,20 +175,19 @@ import { getTimes } from "@/utils";
 import load from "@/utils/loading";
 import { backTypeList } from "@/utils/searchArray";
 import { Export } from "@/utils/downLoadFile";
-import { getCoopRefundList } from "./api";
+import { getCoopShareList } from "./api";
 import { queryByOrganId } from "@/api/systemManage";
+import  addPayCode  from './modals/addPayCode'
 import qs from "qs";
 export default {
-  components: { pagination },
+  components: { pagination,addPayCode },
   data() {
     return {
       searchForm: {
-        search: null,
-        returnFeeType: null,
+        cooperationOrganId: null,
+        paymentStatus: null,
         organId: null,
-        backTime: [],
-        payTime: [],
-        returnFeeFlag: null,
+
       },
       backTypeList,
       tableList: [],
@@ -230,9 +226,10 @@ export default {
         rows: this.rules.limit,
       };
       try {
-        const res = await getCoopRefundList(params);
-        this.tableList = res.data.pageInfo.rows;
-        this.rules.total = res.data.pageInfo.total;
+        const res = await getCoopShareList(params);
+        this.tableList = res.data.rows;
+
+        this.rules.total = res.data.total;
       } catch (e) {
         console.log(e);
       }
@@ -246,7 +243,7 @@ export default {
       this.search();
     },
     addPayCode(row) {
-
+      this.$refs.addPayCode.openDialog(row)
       // /financialManager/payschoolList
     },
 
@@ -301,6 +298,13 @@ export default {
     width: 260px !important;
   }
 }
+::v-deep .el-table .cell {
+  display: -webkit-box;
+  overflow: hidden;
+  text-overflow: ellipsis;
+  -webkit-line-clamp: 3;
+  -webkit-box-orient: vertical;
+}
 .form {
   ::v-deep .el-input {
     width: 220px;

+ 1 - 1
src/views/resetTeaming/modals/paySchoolInfo.vue

@@ -286,7 +286,7 @@
             buttonText="上传合同"
             accept=".pdf"
             v-model="form.contractUrl"
-            bucket_name="contracts"
+            bucket_name="cooperation"
           />
         </el-form-item>
       </el-row>

+ 23 - 13
src/views/teamBuild/modals/change-voice.vue

@@ -87,21 +87,28 @@
                     "元"
                   : "免费"
               }`
-            }}</el-radio
-          >
+            }}
+          </el-radio>
         </el-radio-group>
         <span v-else-if="changeInfo && changeInfo.kitGroupPurchaseType">{{
           kitGroupPurchaseTypeFormater[changeInfo.kitGroupPurchaseType]
         }}</span>
       </el-form-item>
+      <el-form-item label="分部分润金额" prop="musicalGoods" v-if="form.musicalGoods&&musicalGoodsById[form.musicalGoods]&&form.type=='GROUP'">
+        <el-input :value=" musicalGoodsById[form.musicalGoods].organShareProfit" disabled>
+          <template slot="append">元</template>
+        </el-input>
+      </el-form-item>
       <template>
         <!--      v-show="
             (courseViewType == 2 && form.musicalGoods == 'OWNED') ||
             courseViewType != 2
           " -->
         <el-form-item
-
-          v-if="(activeAccessories.length || groupList.length || changeInfo)&&form.musicalGoods"
+          v-if="
+            (activeAccessories.length || groupList.length || changeInfo) &&
+            form.musicalGoods
+          "
           label="更换教辅"
         >
           <accessories
@@ -109,7 +116,6 @@
             :list.sync="activeAccessories"
             :groupList.sync="groupList"
             @change="accessoriesChange"
-
             v-if="!changeInfo"
           />
           <span v-else-if="changeInfo">{{ changeAccessoriesGoods }}</span>
@@ -210,16 +216,20 @@ const formatAllGoods = (data, kitGroupPurchaseType) => {
 
   if (data) {
     const { musicGroupSubjectGoodsGroupList } = data;
-
+// 乐器还是辅件
+/**
+ * {
+ * ACCESSORIES:[],
+ * INSTRUMENT:[]
+ * }
+ */
     const types = {};
-
     for (const item of musicGroupSubjectGoodsGroupList) {
       if (!types[item.type]) {
         types[item.type] = [];
       }
       types[item.type].push(item);
     }
-
     const typesKeys = Object.keys(types);
 
     for (const key of typesKeys) {
@@ -246,7 +256,9 @@ const formatAllGoods = (data, kitGroupPurchaseType) => {
                 : kitGroupPurchaseType === "LEASE"
                 ? item.depositFee
                 : item.price,
+
           };
+
           musicalGoods.push(_item);
           musicalGoodsById[item.goodsIdList] = _item;
           if (!types.ACCESSORIES) {
@@ -332,6 +344,7 @@ export default {
       }
     },
     "form.musicalGoods"() {
+      console.log(this.form, "form");
       this.$set(this.form, "type", "");
     },
     "form.type"() {
@@ -351,10 +364,9 @@ export default {
       );
     },
     activeAccessories() {
-
       const { musicalGoods } = this.form || {};
-        let arr = musicalGoods ? this.accessoriesByGoods[musicalGoods] || [] : [];
-      return arr
+      let arr = musicalGoods ? this.accessoriesByGoods[musicalGoods] || [] : [];
+      return arr;
     },
     changeSubjectName() {
       let name = "";
@@ -467,7 +479,6 @@ export default {
           data = res.data;
           this.musicGroupSubjectPlanFee = res.data.musicGroupSubjectPlan.fee;
           // 更改辅件了列表
-
         } catch (e) {
           console.log(e);
         }
@@ -475,7 +486,6 @@ export default {
         this.musicGroupSubjectPlanFee = 0;
       }
 
-
       const items = formatAllGoods(data, this.item.kitGroupPurchaseType);
       for (const key in items) {
         if (items.hasOwnProperty(key)) {