yumeng преди 1 година
родител
ревизия
a0a37f4a2f
променени са 4 файла, в които са добавени 70 реда и са изтрити 17 реда
  1. 7 1
      src/api/index.js
  2. 8 0
      src/views/promoter/promoterList.vue
  3. 3 3
      src/views/staging.vue
  4. 52 13
      src/views/supplyChain/channelListV2.vue

+ 7 - 1
src/api/index.js

@@ -99,7 +99,13 @@ export function getDataAnalysis(query) {
 }
 
 
-
+export function getMediaId(query) {
+  return request({
+    url: '/itemCollectSamples/getMediaId',
+    method: 'get',
+    params: query
+  })
+}
 
 
 

+ 8 - 0
src/views/promoter/promoterList.vue

@@ -235,6 +235,14 @@
           <div v-else>-</div>
         </template>
       </el-table-column>
+      <el-table-column label="绑定时间" align="center" prop="createTime" width="160px">
+        <template slot-scope="scope">
+          <div v-if="!!scope.row.createTime">
+            {{ scope.row.createTime }}
+          </div>
+          <div v-else>-</div>
+        </template>
+      </el-table-column>
       <el-table-column
         label="佣金要求"
         align="center"

+ 3 - 3
src/views/staging.vue

@@ -65,6 +65,7 @@
           :picker-options="pickerOptions"
           @change="getOrderData"
         ></el-date-picker>
+
         <el-radio-group v-model="mediaId" style="float: right" @change="changeMedia">
           <el-radio-button label="2">快手</el-radio-button>
           <el-radio-button label="1">抖音</el-radio-button>
@@ -600,8 +601,6 @@
     created() {
       this.userId = this.$store.getters.userId;
       this.getMediaId();
-
-
       this.type =
         this.$store.getters.roles[0] == "courtshipManager" ||
         this.$store.getters.roles[0] == "courtship"
@@ -621,7 +620,7 @@
       dd = dd < 10 ? "0" + dd : dd;
       this.uploadDate = [`${y}-${MM}-${dd}`, `${y}-${MM}-${dd}`];
       this.getInfomation();
-      this.getOrderData(this.mediaId);
+      this.getOrderData();
       this.getDataAnalysis();
       // this.getIndexPromoterRank();
       // this.getIndexOrderRank();
@@ -663,6 +662,7 @@
         });
       },
       getOrderData() {
+
         if (this.uploadDate && this.uploadDate.length == 2) {
           this.loading = true;
           getOrderData(

+ 52 - 13
src/views/supplyChain/channelListV2.vue

@@ -48,7 +48,7 @@
           </el-option>
         </el-select>
       </el-form-item>
-      <el-form-item label="选择日期">
+      <el-form-item label="出单日期">
         <el-date-picker
           v-model="uploadDate"
           style="width: 240px"
@@ -58,9 +58,25 @@
           range-separator="-"
           start-placeholder="开始日期"
           end-placeholder="结束日期"
+          @change="cleanBindDate()"
         ></el-date-picker>
       </el-form-item>
 
+      <el-form-item label="绑定日期">
+        <el-date-picker
+          v-model="bindDate"
+          style="width: 240px"
+          value-format="yyyy-MM-dd"
+          format="yyyy-MM-dd"
+          type="daterange"
+          range-separator="-"
+          start-placeholder="开始日期"
+          end-placeholder="结束日期"
+          @change="cleanUploadDate()"
+        ></el-date-picker>
+      </el-form-item>
+
+
       <el-form-item>
         <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"
         >搜索
@@ -107,7 +123,10 @@
       >
         <template slot-scope="scope">
           {{ scope.row.promotersCount }}
-          <el-button  v-if="$store.getters.roles[0] == 'admin' ||$store.getters.roles[0] == 'bdManager' || $store.getters.roles[0] == 'supplyChainAdmin' " size="mini" type="text" @click="editCount(scope.row)">编辑</el-button>
+          <el-button
+            v-if="$store.getters.roles[0] == 'admin' ||$store.getters.roles[0] == 'bdManager' || $store.getters.roles[0] == 'supplyChainAdmin' "
+            size="mini" type="text" @click="editCount(scope.row)">编辑
+          </el-button>
         </template>
       </el-table-column>
 
@@ -123,13 +142,13 @@
           {{ scope.row.sampleRate}}
         </template>
       </el-table-column>-->
-     <!-- <el-table-column
-        label="(总)未领样数"
-        align="center"
-        prop="notSampleCount"
-        width="100px"
-      >
-      </el-table-column>-->
+      <!-- <el-table-column
+         label="(总)未领样数"
+         align="center"
+         prop="notSampleCount"
+         width="100px"
+       >
+       </el-table-column>-->
       <el-table-column label="发样数" align="center" prop="sendTotalCount" width="100px">
       </el-table-column>
       <el-table-column
@@ -251,7 +270,7 @@
     dicts: ["sys_normal_disable"],
     data() {
       return {
-        submitUserId:null,
+        submitUserId: null,
         promotersCountLoading: false,
         promotersCount: null,
         editCountVisible: false,
@@ -304,6 +323,7 @@
           orderEndDate: undefined,
         },
         uploadDate: [new Date(), new Date()],
+        bindDate: [],
         //查询参数所用下拉数据
         queryParamsList: {
           personList: [],
@@ -320,6 +340,7 @@
       let dd = date.getDate();
       dd = dd < 10 ? "0" + dd : dd;
       this.uploadDate = [`${y}-${MM}-${dd}`, `${y}-${MM}-${dd}`];
+      this.bindDate = [];
     },
     mounted() {
       this.$nextTick(() => {
@@ -328,12 +349,19 @@
       });
     },
     methods: {
+      cleanBindDate(){
+        this.bindDate = [];
+      },
+
+      cleanUploadDate(){
+        this.uploadDate = [];
+      },
       submitPromotersCount() {
         if (!!this.promotersCount) {
           this.promotersCountLoading = true;
           submitPromotersCount({
-            userId : this.submitUserId,
-            promotersCount:this.promotersCount,
+            userId: this.submitUserId,
+            promotersCount: this.promotersCount,
             mediaId: 2,
           })
             .then((res) => {
@@ -360,6 +388,12 @@
       /** 导出按钮操作 */
       handleExport() {
         this.downLoadLoading = true;
+
+        if (!!this.bindDate) {
+          this.queryParams.bindStartDate = this.bindDate[0],
+          this.queryParams.bindEndDate = this.bindDate[1]
+        }
+
         downFilePost(
           "/isv/supply_chain/exportBdReportListV2",
           this.addDateRange(
@@ -367,7 +401,7 @@
             this.uploadDate,
             "orderStartDate",
             "orderEndDate"
-          )
+          ),
         ).then((res) => {
           let blob = new Blob([res], {
             type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
@@ -404,6 +438,10 @@
         if (this.roleId == 'bd') {
           this.queryParams.collectSampleId = this.userId
         }
+        if (!!this.bindDate) {
+          this.queryParams.bindStartDate = this.bindDate[0],
+          this.queryParams.bindEndDate = this.bindDate[1]
+        }
         getBdReportListV2(
           this.addDateRange(
             this.queryParams,
@@ -444,6 +482,7 @@
         let dd = date.getDate();
         dd = dd < 10 ? "0" + dd : dd;
         this.uploadDate = [`${y}-${MM}-${dd}`, `${y}-${MM}-${dd}`];
+        this.bindDate = [];
         this.resetForm("queryForm");
         this.queryParams.pageNum = 1;
         this.handleQuery();