Browse Source

Merge branch 'dev' of http://113.31.163.91:7777/quanshu/mp-ui-pc into dev

Liugl 3 years ago
parent
commit
08a2985ced

+ 8 - 2
src/api/admin/salesite.js

@@ -11,6 +11,14 @@ export function listSaleSite(urlParams, data) {
   })
 }
 
+// 查询所有经销商列表
+export function listAllSaleSite() {
+  return request({
+    url: '/api/v1/mp/admin/salesite/listAll',
+    method: 'post'
+  })
+}
+
 export function getSaleSiteDetail(channelId) {
   return request({
     url: '/api/v1/mp/admin/salesite/detail',
@@ -48,5 +56,3 @@ export function updateSaleSiteStatus(data) {
     data: data
   })
 }
-
-

+ 13 - 2
src/api/business/order.js

@@ -20,7 +20,7 @@ export function companyList(data) {
 }
 
 // 经销商盲票组列表
-export function channelList(data) {
+export function boxList(data) {
   return request({
     url: '/api/v1/mp/admin/channel/order/item/list',
     method: 'post',
@@ -108,4 +108,15 @@ export function deliverOrderExport(data) {
     method: 'post',
     data
   })
-}
+}
+
+
+// 经销商订单导出
+export function channelOrderExport(data) {
+  return request({
+    url: '/api/v1/mp/admin/channel/order/export',
+    method: 'post',
+    timeout: 15 * 60 * 1000,
+    data
+  })
+}

+ 6 - 3
src/views/business/coupon/add.vue

@@ -61,7 +61,9 @@
           <el-form-item v-else label="使用范围:" prop="useArea">
             <el-radio-group v-model="addData.useArea" :disabled="readonly">
               <el-radio :label="0">所有盲票</el-radio>
-              <!-- <el-radio :label="1">指定盲票</el-radio> -->
+              <el-radio :label="3">线上盲票</el-radio>
+              <el-radio :label="4">线下盲票</el-radio>
+<!--              <el-radio :label="1">指定盲票</el-radio>-->
             </el-radio-group>
           </el-form-item>
         </el-form>
@@ -113,6 +115,7 @@ import SelectTicket from './components/selectTicket'
 import { publicFileGetUrl } from '@/api/common'
 import { getCouponDetail, addCoupon } from '@/api/business/coupon'
 import { accDiv, accMul } from '@/utils/util'
+import {addData} from "../../../api/system/dict/data";
 export default {
   name: 'CouponAdd',
   components: {
@@ -126,7 +129,7 @@ export default {
       readonly: this.$route.name === 'View',
       addData: {
         ticketBoxList:[],
-        useArea: 2,
+        useArea: 5,
         dueDays: 90,
         type: 2
       },
@@ -176,7 +179,7 @@ export default {
   methods: {
     update() {
       if (this.addData.type == 1) {
-        if(this.addData.useArea !== 0) {
+        if(this.addData.useArea !== 0 && this.addData.useArea !== 1 && this.addData.useArea !== 3 && this.addData.useArea !== 4) {
           this.$message({
             message: '请选择使用范围!',
             type: 'warning'

+ 9 - 2
src/views/business/salesite/index.vue

@@ -1,6 +1,12 @@
 <template>
   <div class="app-container">
-    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="75px">
+    <el-form 
+      :model="queryParams" 
+      ref="queryForm" 
+      :inline="true" 
+      v-show="showSearch" 
+      label-width="75px"
+      >
       <el-form-item label="上级渠道" prop="parentId">
         <el-select
           v-model="queryParams.parentId"
@@ -327,7 +333,6 @@ export default {
 
 
     dataFilter(val) {
-      this.value = val;
       if (val) { //val存在
         this.channelList = this.channelCopyList.filter((item) => {
           if (!!~item.mobile.indexOf(val) || !!~item.mobile.toUpperCase().indexOf(val.toUpperCase())
@@ -338,6 +343,8 @@ export default {
       } else { //val为空时,还原数组
         this.channelList = this.channelCopyList;
       }
+      console.log("this.channelList == "+JSON.stringify(this.channelList))
+      console.log("this.channelCopyList == "+JSON.stringify(this.channelCopyList))
     },
 
 

+ 5 - 0
src/views/finance/withdraw/components/Detail.vue

@@ -43,6 +43,11 @@
           <el-form-item label="持卡人:">
             <span>{{ info.userName || "--" }}</span>
           </el-form-item>
+          <el-form-item label="银行:">
+            <span>{{ info.bankName || "--" }}</span>
+          </el-form-item>
+        </div>
+        <div class="form-flex">
           <el-form-item label="开户行:">
             <span>{{ info.branchName || "--" }}</span>
           </el-form-item>

+ 96 - 7
src/views/order/channel/index.vue

@@ -7,7 +7,7 @@
       v-show="showSearch"
       label-width="90px"
     >
-      <el-form-item label="盲票组名称">
+      <el-form-item label="盲票组名称"  prop="title">
         <el-input
           v-model="queryParams.title"
           placeholder="请输入盲票组名称"
@@ -17,7 +17,7 @@
           @keyup.enter.native="handleQuery"
         />
       </el-form-item>
-      <el-form-item label="订单号">
+      <el-form-item label="订单号" prop="orderId">
         <el-input
           v-model="queryParams.orderId"
           placeholder="输入订单编号"
@@ -27,6 +27,28 @@
           @keyup.enter.native="handleQuery"
         />
       </el-form-item>
+      <el-form-item label="经销商" prop="channelId">
+        <el-select
+          v-model="queryParams.channelId"
+          placeholder="请选择经销商"
+          style="width: 100%;"
+          filterable
+          clearable
+          :filter-method="dataFilter"
+          @change="handleQuery"
+        >
+          <el-option
+            v-for="(item, index) in siteList"
+            :key="item.channelId"
+            :label="item.name"
+            :value="item.channelId">
+            <div>
+              <span style="float: left;">{{item.name}} </span>
+              <span style="float: right;">{{item.mobile}}</span>
+            </div>
+          </el-option>
+        </el-select>
+      </el-form-item>
       <!-- <el-form-item label="经销商">
         <el-select
           v-model="queryParams.channelId"
@@ -71,7 +93,18 @@
         >
       </el-form-item>
     </el-form>
-    <el-row :gutter="10">
+    <el-row :gutter="10" style="margin-bottom: 15px;">
+      <el-col :span="1.5">
+        <el-button
+          type="infor"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleOrderExport"
+          v-hasPermi="['order:channel:export']"
+          >导出订单</el-button
+        >
+      </el-col>
       <right-toolbar
         :showSearch.sync="showSearch"
         @queryTable="getList"
@@ -194,7 +227,8 @@
   </div>
 </template>
 <script>
-import { getOrderList, companyList, channelList } from "@/api/business/order";
+import { getOrderList, companyList, boxList, channelOrderExport} from "@/api/business/order";
+import { listAllSaleSite} from "@/api/admin/salesite";
 import { publicFileGetUrl } from "@/api/common";
 import SendGoods from "./components/SendGoods";
 export default {
@@ -235,8 +269,13 @@ export default {
       goodsInfo: {},
       // 盲票组下拉列表
       boxData: [],
+      siteList:[],
+      siteCopyList:[]
     };
   },
+  mounted() {
+    this.getSaleSiteList()
+  },
   created() {
     this.getList();
   },
@@ -273,14 +312,40 @@ export default {
     },
 
     // 盲票组列表
-    getChannelList(row) {
-      channelList({ orderId: row.orderId }).then((res) => {
+    getBoxList(row) {
+      boxList({ orderId: row.orderId }).then((res) => {
         this.boxData = res.data;
       });
     },
 
+    // 获取经销商下拉列表
+    getSaleSiteList(){
+      listAllSaleSite({}).then(response => {
+         this.siteList = response.data || [];
+         this.siteCopyList = response.data || [];
+      });
+    },
+
+
+    dataFilter(val) {
+      if (val) { //val存在
+        this.siteList = this.siteCopyList.filter((item) => {
+          if (!!~item.mobile.indexOf(val) || !!~item.mobile.toUpperCase().indexOf(val.toUpperCase())
+                 || !!~item.name.indexOf(val) || !!~item.name.indexOf(val)) {
+             return true
+          }
+        })
+      } else { //val为空时,还原数组
+        this.siteList = this.siteCopyList;
+      }
+      console.log("this.siteList == "+JSON.stringify(this.siteList))
+      console.log("this.siteCopyList == "+JSON.stringify(this.siteCopyList))
+    },
+
     //搜索
     handleQuery() {
+      this.siteList = this.siteCopyList;
+      this.queryParams.pageNum = 1;
       this.getList();
     },
 
@@ -327,7 +392,7 @@ export default {
     toGoods(row) {
       this.goodsShow = true;
       this.goodsInfo = row;
-      this.getChannelList(row);
+      this.getBoxList(row);
     },
 
     // 关闭发货弹框
@@ -335,6 +400,30 @@ export default {
       this.goodsShow = false;
       this.getList();
     },
+
+    // 导出订单
+    handleOrderExport() {
+      this.$confirm("是否确认导出订单?", "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      })
+        .then(() => {
+          this.vloading = this.$loading({
+            lock: true,
+            text: "正在导出订单.....",
+            background: "rgba(0, 0, 0, 0.7)",
+          });
+          return channelOrderExport(this.queryParams);
+        })
+        .then((response) => {
+          this.vloading.close();
+          this.download(response.msg);
+        })
+        .catch(() => {
+          this.vloading.close();
+        });
+    },
   },
 };
 </script>

+ 1 - 1
src/views/order/deliver/index.vue

@@ -69,7 +69,7 @@
         <el-button
           type="infor"
           plain
-          icon="el-icon-printer"
+          icon="el-icon-download"
           size="small"
           @click="handleExportDraw"
           v-hasPermi="['order:deliver:export']"

+ 2 - 2
vue.config.js

@@ -34,8 +34,8 @@ module.exports = {
       // detail: https://cli.vuejs.org/config/#devserver-proxy
       [process.env.VUE_APP_BASE_API]: {
       //target: `http://113.31.163.91:8090`,
-      target: `http://localhost:8080`,
-      //target: `https://test-mp.quanshu123.com`,
+      // target: `http://localhost:8080`,
+      target: `https://test-mp.quanshu123.com`,
         changeOrigin: true,
         pathRewrite: {
           ['^' + process.env.VUE_APP_BASE_API]: ''