mo 2 anni fa
parent
commit
50fa40d19f

+ 19 - 0
src/views/teamDetail/api.js

@@ -128,3 +128,22 @@ export const deleteMusicGroupAddr = data => request2({
   requestType: 'form'
 })
 // courseScheduleConvert/queryCourse
+
+// 获取乐团已发货地址
+export const getMusicGroupDeliveryRecord = data => request2({
+  url: '/api-web/musicGroupDeliveryRecord/queryPage',
+  data,
+  params: data,
+  method: 'get',
+  requestType: 'form'
+})
+
+
+// 获取地址详情
+export const getMusicGroupDeliveryDetail = data => request2({
+  url: '/api-web/musicGroupDeliveryRecord/queryGoodsDetail',
+  data,
+  params: data,
+  method: 'get',
+  requestType: 'form'
+})

+ 1 - 1
src/views/teamDetail/teamDetailedList.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="teamDetailedList">
     <el-tabs v-model="activeName">
-      <el-tab-pane label="已发清单" name="waitTeamList" v-permission="'order/getMusicalList'">
+      <el-tab-pane label="已发清单" name="waitTeamList" v-permission="'musicGroupDeliveryRecord/queryPage'">
         <endTeamList v-if="activeName=='waitTeamList'" />
       </el-tab-pane>
       <el-tab-pane label="待发清单" name="endTeamList"  v-permission="'order/getMusicalList/wait'">

+ 66 - 43
src/views/teamDetail/teamListComponent/endTeamList.vue

@@ -6,23 +6,34 @@
           :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
           :data="tableList"
         >
-          <el-table-column label="商品编号" prop="sn" align="center">
+          <el-table-column label="发货时间" prop="createTime" align="center">
           </el-table-column>
-          <el-table-column label="商品名称" align="center" prop="name">
+          <el-table-column label="快递公司" align="center" prop="expressCompany">
           </el-table-column>
-          <el-table-column label="商品类型" align="center" prop="type">
+          <el-table-column label="快递单号" align="center" prop="expressBillNo">
+
+          </el-table-column>
+          <el-table-column label="详细地址" align="center" prop="musicGroupShippingAddress">
+          </el-table-column>
+          <el-table-column label="操作人" align="center" prop="operatorUserName">
+          </el-table-column>
+          <el-table-column label="详情" align="center" prop="operatorUserName">
             <template slot-scope="scope">
               <div>
-                {{ scope.row.type | shopType }}
+                <el-button type="text" @click="gotoDetail(scope.row)">详情</el-button>
               </div>
             </template>
           </el-table-column>
-          <el-table-column label="具体型号" align="center" prop="specification">
-          </el-table-column>
-          <el-table-column label="数量统计" align="center" prop="sellCount">
-          </el-table-column>
         </el-table>
       </div>
+      <pagination
+          sync
+          :total.sync="rules.total"
+          :page.sync="rules.page"
+          :limit.sync="rules.limit"
+          :page-sizes="rules.page_size"
+          @pagination="getList"
+        />
     </div>
     <div class="btnWrap" style="margin-top: 20px">
       <!-- <el-button
@@ -39,30 +50,28 @@
         @click="musicalListDetailExport"
         >分发清单导出</el-button
       >
-      <!-- <el-button
-        type="primary"
-        @click="onDelivery"
-        v-if="musicalStatus && $helpers.permission('musicGroup/takeEffectOfinstrumentInsurance')"
-        >确认发货</el-button> -->
-      <!-- <el-button
-        type="warning okBtn"
-        v-if="team_status == 'PREPARE'&&!hasVerifyMusicalList"
-        v-permission="'order/verifyMusicalList'"
-        @click="okDetailList"
-        >乐器清单确认</el-button
-      > -->
-      <!-- <div class="okBtn" v-permission="'order/verifyMusicalList'"
-           @click="okDetailList">确认</div> -->
     </div>
+    <el-dialog :visible.sync="addrVisiable" title="发货详情" width="1000px">
+      <shipmentDetails v-if="addrVisiable"  ref='shipmentDetails' @close='()=>{addrVisiable = false}' @getList='getList'/>
+      <div slot="footer" class="dialog-footer">
+        <!-- <el-button @click="addrVisiable = false">取 消</el-button> -->
+        <el-button type="primary" @click="addrVisiable = false"
+          >确 定</el-button
+        >
+      </div>
+    </el-dialog>
   </div>
 </template>
 <script>
 import { getTeamDetailList, getTeamBaseInfo } from "@/api/buildTeam";
 import { getTeamList } from "@/api/teamServer";
 import { verifyMusicalList, takeEffectOfinstrumentInsurance } from "@/api/orderManager";
+import { getMusicGroupDeliveryRecord } from '../api'
+import shipmentDetails from './shipmentDetails'
 import axios from "axios";
 import qs from "qs";
 import { getToken, getTenantId } from "@/utils/auth";
+import pagination from "@/components/Pagination/index";
 import load from "@/utils/loading";
 export default {
   data() {
@@ -72,51 +81,65 @@ export default {
       Fsearch: null,
       Frules: null,
       team_status: "",
-      musicalInstrumentsProvideStatus: 0, // 是否确认发货  1已发货
-      hasVerifyMusicalList:true
+      rules: {
+        // 分页规则
+        limit: 10, // 限制显示条数
+        page: 1, // 当前页
+        total: 0, // 总条数
+        page_size: [10, 20, 40, 50], // 选择限制显示条数
+      },
+      addrVisiable:false
     };
   },
+  components: { pagination,shipmentDetails },
   mounted() {
     this.init();
   },
   activated() {
     this.init();
   },
-  computed: {
-    musicalStatus() {
-      const template = ['PREPARE', 'PROGRESS']
-      const teamStatus = this.$route.query.team_status
-      const status = template.includes(teamStatus)
-      console.log(this.musicalInstrumentsProvideStatus, status)
-      return !this.musicalInstrumentsProvideStatus && status ? true : false
-    }
-  },
+
   methods: {
     init() {
       this.team_status = this.$route.query.team_status;
       this.teamid = this.$route.query.id;
       if (this.teamid) {
+        // this.getMusicInfo()
         // getTeamList({ musicGroupId: this.teamid }).then(res=>{
         //   if(res.code == 200){
         //     this.hasVerifyMusicalList = res?.data?.rows[0]?.hasVerifyMusicalList
         //   }
         // })
-        getTeamDetailList({ musicGroupId: this.teamid,deliveryStatus:'1' }).then((res) => {
-          if (res.code == 200) {
-            this.tableList = res.data ? res.data : [];
-          }
-        });
-        this.getMusicInfo()
+          this.getList()
+
       }
     },
-    async getMusicInfo() {
-        await getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+    getList(){
+      getMusicGroupDeliveryRecord({ musicGroupId: this.teamid,page:this.rules.page,rows:this.rules.limit }).then((res) => {
           if (res.code == 200) {
-            this.musicalInstrumentsProvideStatus = res.data?.musicGroup?.musicalInstrumentsProvideStatus
-            this.hasVerifyMusicalList = res.data?.musicGroup?.hasVerifyMusicalList
+            this.tableList = res.data.rows ? res.data.rows : [];
+            this.rules.total = res.data.total
           }
         });
     },
+    gotoDetail(row){
+      this.addrVisiable = true
+
+      this.$nextTick(()=>{
+        console.log(this.$refs.shipmentDetails)
+        this.$refs.shipmentDetails.init(row)
+      })
+
+
+    },
+    // async getMusicInfo() {
+    //     await getTeamBaseInfo({ musicGroupId: this.teamid }).then((res) => {
+    //       if (res.code == 200) {
+    //         this.musicalInstrumentsProvideStatus = res.data?.musicGroup?.musicalInstrumentsProvideStatus
+    //         this.hasVerifyMusicalList = res.data?.musicGroup?.hasVerifyMusicalList
+    //       }
+    //     });
+    // },
     onCancel() {
       this.$store.dispatch("delVisitedViews", this.$route);
       this.$router.push({ path: "/teamList" });

+ 89 - 0
src/views/teamDetail/teamListComponent/shipmentDetails.vue

@@ -0,0 +1,89 @@
+<template>
+  <div class="">
+    <div class="">
+      <div class="tableWrap">
+        <el-table
+          :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
+          :data="tableList"
+        >
+          <el-table-column label="商品编号" prop="sn" align="center">
+          </el-table-column>
+          <el-table-column label="商品名称" align="center" prop="name">
+          </el-table-column>
+          <el-table-column label="商品类型" align="center" prop="type">
+            <template slot-scope="scope">
+              <div>
+                {{ scope.row.type | shopType }}
+              </div>
+            </template>
+          </el-table-column>
+          <el-table-column label="具体型号" align="center" prop="specification">
+          </el-table-column>
+          <el-table-column label="数量统计" align="center" prop="sellCount">
+          </el-table-column>
+        </el-table>
+      </div>
+    </div>
+  </div>
+</template>
+<script>
+import { getTeamDetailList, getTeamBaseInfo } from "@/api/buildTeam";
+import { getTeamList } from "@/api/teamServer";
+import { verifyMusicalList, takeEffectOfinstrumentInsurance } from "@/api/orderManager";
+import { getMusicGroupDeliveryDetail } from '../api'
+import axios from "axios";
+import qs from "qs";
+import { getToken, getTenantId } from "@/utils/auth";
+import load from "@/utils/loading";
+
+export default {
+  data() {
+    return {
+      teamid: "",
+      tableList: [],
+      Fsearch: null,
+      Frules: null,
+      team_status: "",
+      musicalInstrumentsProvideStatus: 0, // 是否确认发货  1已发货
+      hasVerifyMusicalList:true,
+
+    };
+  },
+  mounted() {
+    // this.init();
+  },
+  activated() {
+    // this.init();
+  },
+  computed: {
+    musicalStatus() {
+      const template = ['PREPARE', 'PROGRESS']
+      const teamStatus = this.$route.query.team_status
+      const status = template.includes(teamStatus)
+      console.log(this.musicalInstrumentsProvideStatus, status)
+      return !this.musicalInstrumentsProvideStatus && status ? true : false
+    }
+  },
+  methods: {
+    init(row) {
+      this.team_status = this.$route.query.team_status;
+      this.teamid = this.$route.query.id;
+      if (this.teamid) {
+        getMusicGroupDeliveryDetail({ musicGroupId: this.teamid,deliveryBatchNo:row.deliveryBatchNo }).then((res) => {
+          if (res.code == 200) {
+            this.tableList = res.data ? res.data: [];
+          }
+        });
+      }
+    },
+
+    onCancel() {
+      this.$store.dispatch("delVisitedViews", this.$route);
+      this.$router.push({ path: "/teamList" });
+    },
+  },
+};
+</script>
+
+<style lang="scss" scoped>
+</style>