Prechádzať zdrojové kódy

1、优化推广管理

huangmp 1 rok pred
rodič
commit
af85bd26d8

+ 6 - 0
src/components/order-card-item/index.vue

@@ -209,6 +209,12 @@
           }else if(prodName.indexOf("63x108") !== -1){
             width = 874;
             height = 1287;
+          }else if(prodName.indexOf("60x180") !== -1){
+            width = 780;
+            height = 2197;
+          }else if(prodName.indexOf("70x210") !== -1){
+            width = 898;
+            height = 2551;
           }
           let _URL = window.URL || window.webkitURL;
           let img = new Image();

+ 5 - 0
src/store/modules/user.js

@@ -42,6 +42,9 @@ export default {
     },
     updateShopStatus (state, shopStatus) {
       state.shopStatus = shopStatus
+    },
+    updateEmployeeNickName (state, nickName) {
+      state.employeeNickName = nickName
     }
   },
   actions: {
@@ -61,6 +64,7 @@ export default {
           commit('updateEmployeeId', data.employeeId)
           commit('updateEmployeeType', data.employeeType)
           commit('updateShopName', data.shopName)
+          commit('updateNickName', data.nickName)
           resolve(state)
         }).catch(error => {
           reject(error)
@@ -85,6 +89,7 @@ export default {
           commit('updateShopStatus', data.shopStatus)
           commit('updateShopId', data.shopId)
           commit('updateEmployeeId', data.employeeId)
+          commit('updateEmployeeNickName', data.employeeNickName)
           resolve(state)
         }).catch(error => {
           reject(error)

+ 18 - 12
src/views/common/home.vue

@@ -458,21 +458,27 @@ export default {
       employeeId:this.$store.state.user.employeeId
     }
   },
+  created() {
+    this.getAuditingInfo()
+  },
   mounted () {
     let user = this.$store.state.user
     this.employeeType = user.employeeType
-    this.getpayActualTotalByDay()
-    this.getpayActualTotalByHour()
-    this.getOrderRefundDayByTime()
-    this.getOrderCount()
-    this.getRefundInfo()
-    this.getRefundRankingByProd()
-    this.getRefundRankingByReason()
-    this.getpayInfo()
-    this.getRefSumEchartData()
-    this.getRefPerEchartData()
-    this.getAuditingInfo()
-    this.getEntiretyDataChart()
+    if(this.employeeType === 0){
+      this.getpayActualTotalByDay()
+      this.getpayActualTotalByHour()
+      this.getOrderRefundDayByTime()
+      this.getOrderCount()
+      this.getRefundInfo()
+      this.getRefundRankingByProd()
+      this.getRefundRankingByReason()
+      this.getpayInfo()
+      this.getRefSumEchartData()
+      this.getRefPerEchartData()
+      this.getAuditingInfo()
+      this.getEntiretyDataChart()
+    }
+
     let erd = elementResizeDetectorMaker()
     erd.listenTo(document.getElementById('entirety-data-chart'), this.resizeFunc)
   },

+ 1 - 0
src/views/modules/order/order.vue

@@ -1032,6 +1032,7 @@
 <!--          <el-option key="WoNiu" label="蜗牛" value="WoNiu"></el-option>-->
           <el-option key="KuaiYin" label="快印" value="KuaiYin"></el-option>
           <el-option key="Lightning" label="闪电" value="Lightning"></el-option>
+          <el-option key="WoNiu" label="蜗牛" value="WoNiu"></el-option>
         </el-select>
       </el-form-item>
     </el-form>

+ 3 - 3
src/views/modules/print/print-order.vue

@@ -182,7 +182,7 @@
           <span v-if="dataListSelections.size" class="had-selected" style="font-weight: bold;color: red;font-size: 20px"> {{selectSheets}}张</span>
           <el-button size="small" type="primary" icon="el-icon-plus" @click="openGenerateWaveDialog">生成波次</el-button>
           <el-button size="small" icon="el-icon-upload2" @click="openAddToWaveDialog">添加已有波次</el-button>
-<!--          <el-button size="small" type="success" @click="checkAndAutoCreateWave">自动生成波次</el-button>-->
+          <el-button size="small" type="success" @click="checkAndAutoCreateWave">一键生成波次</el-button>
         </div>
         <!-- 列标题 -->
         <div :class="['tit', showHeadScroll ? 'fixed-top' : '']">
@@ -717,7 +717,7 @@
           this.$http({
             url: this.$http.adornUrl(`/wave/wave/checkAndAutoCreateWave`),
             method: 'POST',
-            data: this.$http.adornData()
+            data: this.$http.adornData({shopName: this.$store.state.user.shopName})
           }).then(({data}) => {
             if(data){
               this.$message({
@@ -799,7 +799,7 @@
         this.wave.waveName = dateStr + "-" + (shopName? (shopName + "-"): "") + (this.wave.colorPrint !== '8'? "4S-":"") + this.wave.prodName + "-" + this.wave.skuName + "-" + sheets + "套" + "-" + "BC" + bc
       },
       createWave(){
-        let dataBody = {colorPrint: this.wave.colorPrint, gram: this.wave.gram, waveName: this.wave.waveName, "orderNumberList": [...this.dataListSelections], "printChannel": this.printChannel};
+        let dataBody = {prodName: this.wave.prodName, skuName: this.wave.skuName, colorPrint: this.wave.colorPrint, gram: this.wave.gram, waveName: this.wave.waveName, "orderNumberList": [...this.dataListSelections], "printChannel": this.printChannel};
         this.$http({
           url: this.$http.adornUrl(`/wave/wave/create`),
           method: 'POST',

+ 6 - 1
src/views/modules/prod/prodTemplate-add-or-update.vue

@@ -30,6 +30,8 @@
           <el-option key="3CFZFP" label="3寸仿真拍立得" value="3CFZFP"></el-option>
           <el-option key="4CFZFP" label="4寸仿真拍立得" value="4CFZFP"></el-option>
           <el-option key="5CFZFP" label="5寸仿真拍立得" value="5CFZFP"></el-option>
+          <el-option key="XL3CFZFP" label="撕拉3寸花式仿真拍立得" value="XL3CFZFP"></el-option>
+          <el-option key="YOUXK" label="游戏卡" value="YOUXK"></el-option>
           <el-option key="YYK" label="语音卡" value="YYYXK,YYZJXK"></el-option>
         </el-select>
       </el-form-item>
@@ -157,7 +159,7 @@ export default {
           }else if(templateUsage.indexOf("5CFP") !== -1 || templateUsage.indexOf("5CFZFP") !== -1){
             width = 1346;
             height = 1087;
-          }else if(templateUsage.indexOf("FP") !== -1 || templateUsage.indexOf("3CFZFP") !== -1){
+          }else if(templateUsage.indexOf("FP") !== -1 || templateUsage.indexOf("3CFZFP") !== -1 || templateUsage.indexOf("XL3CFZFP") !== -1){
             width = 709;
             height = 1087;
           }else if(templateUsage.indexOf("EGG") !== -1){
@@ -175,6 +177,9 @@ export default {
           }else if(templateUsage.indexOf("FK") !== -1){
             width = 1229;
             height = 1229;
+          }else if(templateUsage.indexOf("YOUXK") !== -1){
+            width = 803;
+            height = 1098;
           }
           if(isBack){
             let imageFormat = imageStr.split('.').pop();

+ 1 - 1
src/views/modules/promotion/promotionOrder-add-or-update.vue

@@ -178,7 +178,7 @@
         lang: localStorage.getItem('lang') || 'zh_CN',
         dataForm: {
           id: null,
-          tgUserName: null,
+          tgUserName: this.$store.state.user.employeeNickName,
           upId: null,
           upName: null,
           orderNumber: null,

+ 1 - 1
src/views/modules/promotion/promotionOrder.vue

@@ -221,7 +221,7 @@ export default {
         pageSize: 10 // 每页显示多少条
       },
       shopId: this.$store.state.user.shopId,
-      searchForm: {}, // 搜索
+      searchForm: {tgUserName: this.$store.state.user.employeeNickName}, // 搜索
       dataListLoading: false,
       addOrUpdateVisible: false,
       shopList: [],

+ 11 - 12
src/views/modules/promotion/promotionUp-add-or-update.vue

@@ -34,17 +34,16 @@
       </el-row>
       <el-row>
         <el-col :span="10">
-          <el-form-item label="视频平台" prop="publishPlatform" size="small">
-            <el-autocomplete
-              class="inline-input"
-              v-model="dataForm.publishPlatform"
-              :fetch-suggestions="querySearch"
-              placeholder="请输入内容"
-              style="width :330px;">
-              <template slot-scope="{ item }">
-                <div class="name">{{ item.label }}</div>
-              </template>
-            </el-autocomplete>
+          <el-form-item label="发布平台" prop="publishPlatform">
+            <el-select v-model="dataForm.publishPlatform">
+              <el-option
+                v-for="item in videoPlatformList"
+                :key="item.value"
+                :label="item.label"
+                :value="item.value"
+              >
+              </el-option>
+            </el-select>
           </el-form-item>
         </el-col>
         <el-col :span="10" :offset="1">
@@ -92,7 +91,7 @@ export default {
         upName: null,
         publishPlatform: null,
         fansNum: null,
-        tgUserName: null,
+        tgUserName: this.$store.state.user.employeeNickName,
         shopId: this.$store.state.user.shopId,
         shopName: null
       },

+ 1 - 1
src/views/modules/promotion/promotionUp.vue

@@ -162,7 +162,7 @@ export default {
         pageSize: 10 // 每页显示多少条
       },
       shopId: this.$store.state.user.shopId,
-      searchForm: {}, // 搜索
+      searchForm: {tgUserName: this.$store.state.user.employeeNickName}, // 搜索
       dataListLoading: false,
       addOrUpdateVisible: false,
       shopList: [],

+ 1 - 1
src/views/modules/promotion/promotionVideo-add-or-update.vue

@@ -199,7 +199,7 @@ export default {
       lang: localStorage.getItem('lang') || 'zh_CN',
       dataForm: {
         id: null,
-        tgUserName: null,
+        tgUserName: this.$store.state.user.employeeNickName,
         upId: null,
         upName: null,
         videoUrl: null,

+ 10 - 10
src/views/modules/promotion/promotionVideo.vue

@@ -16,15 +16,15 @@
           <el-input v-model="searchForm.upName" :clearable="true"></el-input>
         </el-form-item>
         <el-form-item label="发布平台" prop="publishPlatform">
-          <el-autocomplete
-            class="inline-input"
-            v-model="searchForm.publishPlatform"
-            :fetch-suggestions="querySearch"
-            placeholder="请输入内容">
-            <template slot-scope="{ item }">
-              <div class="name">{{ item.label }}</div>
-            </template>
-          </el-autocomplete>
+          <el-select v-model="searchForm.publishPlatform">
+            <el-option
+              v-for="item in videoPlatformList"
+             :key="item.value"
+             :label="item.label"
+             :value="item.value"
+            >
+            </el-option>
+          </el-select>
         </el-form-item>
         <el-form-item label="寄拍/付费" prop="payType">
           <el-select v-model="searchForm.payType" placeholder="请选择" size="small" :clearable="true">
@@ -281,7 +281,7 @@
         },
         syncVisible: false,
         shopId: this.$store.state.user.shopId,
-        searchForm: {}, // 搜索
+        searchForm: {tgUserName: this.$store.state.user.employeeNickName}, // 搜索
         dataListLoading: false,
         addOrUpdateVisible: false,
         shopList: [],