Ver Fonte

'暂存'

魏志佳 há 4 anos atrás
pai
commit
5d875e9769
54 ficheiros alterados com 5647 adições e 704 exclusões
  1. 1 1
      package.json
  2. BIN
      public/avatar2.jpg
  3. BIN
      public/feishu.png
  4. BIN
      public/goright.png
  5. 1 0
      src/App.vue
  6. 2 1
      src/components/ctop/propModal.vue
  7. 2 4
      src/components/formComponents/selectRegion.vue
  8. 27 26
      src/components/uploadFile.vue
  9. 266 0
      src/components/youtTable/YoutTable.vue
  10. 300 0
      src/components/youtTable/customColumn.vue
  11. 240 0
      src/components/youtTable/selectComponent.vue
  12. 240 0
      src/components/youtTable/selectComponentKS.vue
  13. 98 0
      src/directive.js
  14. 301 0
      src/filters.js
  15. 4 1
      src/main.js
  16. 7 7
      src/router/index.js
  17. 1323 0
      src/utils/columnConst/accountConst.js
  18. 0 0
      src/utils/columnConst/videoConst.js
  19. 24 79
      src/views/dashboard/Analysis.vue
  20. 0 9
      src/views/modules/BatchCreate/newCreate.vue
  21. 7 7
      src/views/modules/Statistics/KSAccountReport.vue
  22. 509 0
      src/views/modules/Statistics/materialReport/materialReport.vue
  23. 2 2
      src/views/modules/Statistics/newPlanStatic/newPlanStatic.vue
  24. 2 2
      src/views/modules/Statistics/popularVideo.vue
  25. 5 1
      src/views/modules/advertiser/ProjectList.vue
  26. 8 1
      src/views/modules/advertiser/modules/projectListModal.vue
  27. 0 0
      src/views/modules/autoLaunch/configLaunchInfo.vue
  28. 1083 0
      src/views/modules/autoLaunch/configLaunchList.vue
  29. 1 2
      src/views/modules/autoLaunch/index.vue
  30. 7 9
      src/views/modules/autoLaunch/setDirectional.vue
  31. 1 1
      src/views/modules/autoRules/newBlankRule.vue
  32. 2 2
      src/views/modules/earlyWarningRules/configRules.vue
  33. 249 0
      src/views/modules/earlyWarningRules/historyWarning.vue
  34. 2 2
      src/views/modules/earlyWarningRules/index.vue
  35. 28 20
      src/views/modules/earlyWarningRules/ruleModule.vue
  36. 96 33
      src/views/modules/earlyWarningRules/useRuleList.vue
  37. 2 0
      src/views/modules/kuaishouapp/account/accountIndex.vue
  38. 28 17
      src/views/modules/kuaishouapp/account/copyAllUnit.vue
  39. 5 4
      src/views/modules/kuaishouapp/account/stepForm/Step2.vue
  40. 47 31
      src/views/modules/kuaishouapp/account/stepForm/stepModule/targetedPopulation.vue
  41. 1 0
      src/views/modules/kuaishouapp/batchCreation/campaignList.vue
  42. 2 2
      src/views/modules/kuaishouapp/batchCreation/creat/creatCampaign.vue
  43. 7 1
      src/views/modules/kuaishouapp/batchCreation/creat/creatUnit.vue
  44. 3 3
      src/views/modules/kuaishouapp/crossAccount/templateModal.vue
  45. 216 160
      src/views/modules/kuaishouapp/populationAnalysis/index.vue
  46. 2 2
      src/views/modules/workBench/designLeader/platForm.vue
  47. 2 2
      src/views/modules/workBench/designPeople/platForm.vue
  48. 55 14
      src/views/modules/workBench/materialList.vue
  49. 173 78
      src/views/modules/workBench/operator/materialList.vue
  50. 3 3
      src/views/modules/workBench/operator/platForm.vue
  51. 240 162
      src/views/modules/workBench/orderDetail.vue
  52. 1 1
      src/views/modules/workBench/orderList.vue
  53. 16 11
      src/views/modules/workBench/placeOrder.vue
  54. 6 3
      vue.config.js

+ 1 - 1
package.json

@@ -131,4 +131,4 @@
     "last 2 versions",
     "not ie <= 8"
   ]
-}
+}

BIN
public/avatar2.jpg


BIN
public/feishu.png


BIN
public/goright.png


+ 1 - 0
src/App.vue

@@ -51,6 +51,7 @@ export default {
 <style>
 #app {
   height: 100%;
+  min-width: 1280px;
 }
 
 body {

+ 2 - 1
src/components/ctop/propModal.vue

@@ -117,8 +117,9 @@
         that.form.resetFields();
         that.model = Object.assign({}, record);
         that.visible = true;
-        that.imageUrl = record.coverUrl?[record.coverUrl]:[]
+        
         that.$nextTick(() => {
+          that.imageUrl = record.coverUrl?[record.coverUrl]:[]
           that.form.setFieldsValue(pick(this.model, 'name', 'desc'))
           //时间格式化
         });

+ 2 - 4
src/components/formComponents/selectRegion.vue

@@ -168,8 +168,7 @@
     mounted() {
       this.$nextTick(() => {
         this.getData().then(() => {
-            console.log(this.dataValue)
-          if (this.dataValue.length>0&&this.dataValue[0].value) {
+          if (this.dataValue&&this.dataValue.length>0&&this.dataValue[0].value) {
             return
           } else {
             postAction('/kuaishou/batch/getRegionDetail', {
@@ -201,9 +200,8 @@
         deep: true,
         immediate: true, // immediate选项可以开启首次赋值监听
         handler(n, o) {
-          if (n.length > 0 && n[0].value) {
+          if (n&&n.length > 0 && n[0].value) {
             // this.getData().then(() => {
-            console.log(1)
             //   if (n.length > 0) {
             this.$nextTick(() => {
               this.checkData = n

+ 27 - 26
src/components/uploadFile.vue

@@ -144,36 +144,37 @@ export default {
     value: {
       immediate: true,
       handler(n, o) {
-        console.log(n,o)
-        if (this.fileList&&this.fileList.length == 0) {
-          if (typeof n == 'object') {
-            this.fileList = n.map((item, index) => {
-              return {
-                uid: index + 1,
-                name: index + 1,
-                status: 'done',
-                url: item,
+        this.$nextTick(() => {
+          if (this.fileList && this.fileList.length == 0) {
+            if (typeof n == 'object') {
+              this.fileList = n.map((item, index) => {
+                return {
+                  uid: index + 1,
+                  name: index + 1,
+                  status: 'done',
+                  url: item,
+                }
+              })
+            } else {
+              if (n == '') {
+                this.fileList = []
+              } else {
+                this.fileList = [
+                  {
+                    uid: 1,
+                    name: 1,
+                    status: 'done',
+                    url: n,
+                  },
+                ]
               }
-            })
+            }
           } else {
-            if (n == '') {
-              this.fileList = []
-            } else {
-              this.fileList = [
-                {
-                  uid: 1,
-                  name: 1,
-                  status: 'done',
-                  url: n,
-                },
-              ]
+            if (n.length == 0 || n == '') {
+              this.clearAll()
             }
           }
-        } else {
-          if (n.length == 0 || n == '') {
-            this.clearAll()
-          }
-        }
+        })
       },
       deep: true,
     },

+ 266 - 0
src/components/youtTable/YoutTable.vue

@@ -0,0 +1,266 @@
+
+<template>
+    <div class="youtTable">
+        <div class="yout-header">
+            <p class="headTitle">{{headTitle}}</p>
+            <div class="opt-btn">
+                <a-button type='default' v-if="isNeedCustomColumn" @click="customColumns" style="margin-right:15px">自定义列</a-button>
+                <a-button type='default' v-if='isNeedExport' @click="exportExcel" :loading="exportloading">导出报表</a-button>
+            </div>
+        </div>
+        <div class="tableBody">
+            <a-table
+                :size="size"
+                :columns="columns"
+                :dataSource="data"
+                bordered
+                id="outTable"
+                :pagination="pagination"
+                :scroll="{ x: scrollX, y: scrollY }"
+                :loading="loading"
+                ref="accountTable"
+                @change="change"                
+              >
+
+                <span slot="ctr" slot-scope="ctr">{{ ctr | toPercentage }}</span>
+                <span slot="cost" slot-scope="cost">{{ cost | decimalsHandle }}</span>
+                <span slot="clickMaterial" slot-scope="clickMaterial">{{ clickMaterial | formatCurrency }}</span>
+                <span slot="showMaterial" slot-scope="showMaterial">{{ showMaterial | formatCurrency }}</span>
+                <span slot="convertMaterial" slot-scope="convertMaterial">{{ convertMaterial | formatCurrency }}</span>
+                <span slot="play25FeedBreak" slot-scope="play25FeedBreak">{{ play25FeedBreak | formatCurrency }}</span>
+                <span slot="play50FeedBreak" slot-scope="play50FeedBreak">{{ play50FeedBreak | formatCurrency }}</span>
+                <span slot="play75FeedBreak" slot-scope="play75FeedBreak">{{ play75FeedBreak | formatCurrency }}</span>
+                <span slot="play100FeedBreak" slot-scope="play100FeedBreak">{{ play100FeedBreak | formatCurrency }}</span>
+                <span slot="nextDayOpen" slot-scope="nextDayOpen">{{ nextDayOpen | formatCurrency }}</span>
+                <span slot="downloadFinish" slot-scope="downloadFinish">{{ downloadFinish | formatCurrency }}</span>
+                <span slot="downloadStart" slot-scope="downloadStart">{{ downloadStart | formatCurrency }}</span>
+                <span slot="likeMaterial" slot-scope="likeMaterial">{{ likeMaterial | formatCurrency }}</span>
+                <span slot="shareMaterial" slot-scope="shareMaterial">{{ shareMaterial | formatCurrency }}</span>
+                <span slot="register" slot-scope="register">{{ register | formatCurrency }}</span>
+                <span slot="follow" slot-scope="follow">{{ follow | formatCurrency }}</span>
+                <span slot="formCount" slot-scope="formCount">{{ formCount | formatCurrency }}</span>
+                <span slot="formCountCost" slot-scope="formCountCost">{{ formCountCost | decimalsHandle }}</span>
+                <span slot="aClick" slot-scope="aClick">{{ aClick | formatCurrency }}</span>
+                <span slot="photoShow" slot-scope="photoShow">{{ photoShow | formatCurrency }}</span>
+                <span slot="photoClick" slot-scope="photoClick">{{ photoClick | formatCurrency }}</span>
+                <span slot="bClick" slot-scope="bClick">{{ bClick | formatCurrency }}</span>
+                <span slot="active" slot-scope="active">{{ active | formatCurrency }}</span>
+                <span slot="submit" slot-scope="submit">{{ submit | formatCurrency }}</span>
+                <span slot="nextDayOpen" slot-scope="nextDayOpen">{{ nextDayOpen | formatCurrency }}</span>
+                <span slot="eventCreditGrantLandingPage" slot-scope="eventCreditGrantLandingPage">{{ eventCreditGrantLandingPage | formatCurrency }}</span>
+                <span slot="submitCost" slot-scope="submitCost">{{ submitCost | decimalsHandle }}</span>
+                <span slot="eventCreditGrantLandingPageCost" slot-scope="eventCreditGrantLandingPageCost">{{ eventCreditGrantLandingPageCost | decimalsHandle }}</span>
+                <span slot="submitRate" slot-scope="submitRate">{{ submitRate | toPercentage }}</span>
+                <span slot="eventCreditGrantLandingPageRate" slot-scope="eventCreditGrantLandingPageRate">{{ eventCreditGrantLandingPageRate | toPercentage }}</span>
+                <span
+                  slot="play25FeedBreakRate"
+                  slot-scope="play25FeedBreakRate"
+                >{{ play25FeedBreakRate | toPercentage }}</span>
+                <span slot="playOverRate" slot-scope="playOverRate">{{ playOverRate | toPercentage }}</span>
+                <!-- 新加数据 -->
+
+                <span slot="convertRate" slot-scope="convertRate">{{ convertRate | toPercentage }}</span>
+                <span slot="nextDayOpenRate" slot-scope="nextDayOpenRate">{{ nextDayOpenRate | toPercentage }}</span>
+                <span slot="ctr" slot-scope="ctr">{{ ctr | toPercentage }}</span>
+                <span slot="cpc" slot-scope="cpc">{{ cpc | decimalsHandle }}</span>
+                <span slot="cpm" slot-scope="cpm">{{ cpm | decimalsHandle }}</span>
+                <span slot="activeRate" slot-scope="activeRate">{{ activeRate | toPercentage }}</span>
+                <span
+                  slot="installFinishRate"
+                  slot-scope="installFinishRate"
+                >{{ installFinishRate | toPercentage }}</span>
+                <span slot="validPlayRate" slot-scope="validPlayRate">{{ validPlayRate | toPercentage }}</span>
+                <span slot="activePayCost" slot-scope="activePayCost">{{ activePayCost | decimalsHandle }}</span>
+                <span slot="nextDayOpenCost" slot-scope="nextDayOpenCost">{{ nextDayOpenCost | decimalsHandle }}</span>
+                <span slot="validPlayCost" slot-scope="validPlayCost">{{ validPlayCost | decimalsHandle }}</span>
+                <span slot="activeCost" slot-scope="activeCost">{{ activeCost | decimalsHandle }}</span>
+                <span slot="nextDayOpenCost" slot-scope="nextDayOpenCost">{{ nextDayOpenCost | decimalsHandle }}</span>
+                <span
+                  slot="gameAddictionCost"
+                  slot-scope="gameAddictionCost"
+                >{{ gameAddictionCost | decimalsHandle }}</span>
+                <span
+                  slot="downloadFinishCost"
+                  slot-scope="downloadFinishCost"
+                >{{ downloadFinishCost | decimalsHandle }}</span>
+                <span
+                  slot="downloadStartCost"
+                  slot-scope="downloadStartCost"
+                >{{ downloadStartCost | decimalsHandle }}</span>
+                <span
+                  slot="installFinishCost"
+                  slot-scope="installFinishCost"
+                >{{ installFinishCost | decimalsHandle }}</span>
+                <span slot="convertCost" slot-scope="convertCost">{{ convertCost | decimalsHandle }}</span>
+
+                <!--  -->
+                <span
+                  slot="downloadStartRate"
+                  slot-scope="downloadStartRate"
+                >{{ downloadStartRate | toPercentage }}</span>
+                <span
+                  slot="downloadFinishRate"
+                  slot-scope="downloadFinishRate"
+                >{{ downloadFinishRate | toPercentage }}</span>
+                <span slot="activeRate" slot-scope="activeRate">{{ activeRate | toPercentage }}</span>
+                <span
+                  slot="activeRegisterRate"
+                  slot-scope="activeRegisterRate"
+                >{{ activeRegisterRate | toPercentage }}</span>
+                <span
+                  slot="gameAddictionRate"
+                  slot-scope="gameAddictionRate"
+                >{{ gameAddictionRate | toPercentage }}</span>
+                <span slot="nextDayOpenRate" slot-scope="nextDayOpenRate">{{ nextDayOpenRate | toPercentage }}</span>
+                <!-- <span slot="nextDayOpenRate" slot-scope="nextDayOpenRate">{{ nextDayOpenRate | toPercentage }}</span> -->
+
+
+                <slot name="customContext"></slot>
+                
+            </a-table>
+            <customColumn :visible='visible'  :listNum='listNum' :fiexColumn='columnsFixd' :mediaType='mediaType'  @closeCustomColumn='closeCustomColumn' @changeColumn='changeColumn' />
+        </div>
+    </div>
+</template>
+
+<script>
+import customColumn from './customColumn.vue'
+    export default {
+        components:{
+            
+            customColumn,
+        },
+        data() {
+            return {
+                exportloading:false,
+                visible:false,
+                listNum:[],
+            }
+        },
+        props:{
+            // 表格的标题
+            headTitle:{
+                type:String,
+                default:'',
+            },
+            // 是否需要自定义列
+            isNeedCustomColumn:{
+                type:Boolean,
+                default:false,
+            },
+            // 是否需要导出报表
+            isNeedExport:{
+                type:Boolean,
+                default:false,
+            },
+            
+            // 表格大小
+            size:{
+                type:String,
+                default:'middle'
+            },
+            columns:{
+                type:Array,
+                require:true,
+            },
+            columnsFixd:{
+                type:Array,
+                require:true,
+            },
+            data:{
+                type:Array,
+                default(){
+                    return []
+                }
+            },
+            pagination:{
+                default(){
+                    return false
+                }
+            },
+            loading:{
+                default:false,
+            },
+            scrollX:{
+                default:0
+            },
+            scrollY:{
+                default:0
+            },
+            mediaType:{
+                // 1-头条,2-快手
+                type:Number,
+                require:true,
+            },
+            
+
+        },
+        methods: {
+            exportExcel(){
+                this.$emit('exportExcel')
+            },
+            change(pagination, filters, sorter, { currentDataSource }){
+                this.$emit('tableChange',{pagination, filters, sorter,  currentDataSource })
+            },
+            closeCustomColumn(){
+                this.visible=false;
+            },
+            //自定义之后修改父元素表头
+            changeColumn(val){
+                this.columns=[...val];
+                this.columns=[...val];
+                if(this.columns.length> this.columnsFixd.length&&this.columns.length<8){
+                this.columns.forEach((element,index) => {
+                    if(index<this.columns.length-1){
+                    element.width='auto'
+                    element.fixed=false
+                    }             
+                });
+
+                // this.scrollX=2000+200*(this.columns.length-this.columnsFixd.length)
+                }else if(this.columns.length>=8){
+                this.columns.forEach((element,index) => {
+                    if(index<this.columnsFixd.length){
+                    element.width=200
+                    element.fixed='left'
+                    }             
+                });
+
+                this.scrollX=1000+200*(this.columns.length-this.columnsFixd.length)
+                } else{
+                this.scrollX=0;
+                this.columns.forEach(element => {
+                    element.width='auto'
+                    element.fixed=false
+                });
+                }
+            },
+            //弹出框打开,自定义列
+            customColumns() {
+                this.visible = true
+                this.listNum = [...this.columns]
+            },
+            
+        },
+    }
+</script>
+
+<style lang="scss" scoped>
+.youtTable{
+    background: white;
+    margin-bottom: 20px;
+    
+    .yout-header{       
+        padding: 20px ;
+        display: flex;
+        justify-content:space-between;
+        .headTitle{
+            margin-bottom: 0;
+            font-size: 15px;
+            font-weight: 600;
+            height: 32px;
+            line-height: 32px;
+        }
+    }
+}
+</style>

+ 300 - 0
src/components/youtTable/customColumn.vue

@@ -0,0 +1,300 @@
+<template>
+  <div class="customColumnKS">
+    <a-modal v-model="visibleOk" title="自定义列" on-ok="handleOk" @cancel="handleCancel" width="65%">
+      <template slot="footer">
+        <a-button key="back" @click="handleCancel">取消</a-button>
+        <a-button key="submit" type="primary" :loading="loading" @click="handleOk">应用</a-button>
+      </template>
+      <!-- <a-input-search placeholder="输入要添加的列的名称" style="width: 40%" enter-button @search="onSearch" /> -->
+      <div class="zhuti">
+        <div class="addlist">
+          <p>可添加的列</p>
+          <div class="selectionList">
+            <!--  v-for="(item,index) in addColumns" :key="index" -->
+            <!-- <div v-if="mediaType==1"> -->
+              <selectComponent
+              :showCol="mylistNum"
+              @getshowlist="getshowlist"
+              :fixedCol="fiexColumn"
+              :mediaType='mediaType'
+              
+              />
+            <!-- </div> -->
+            <!-- <div v-if="mediaType==2">
+              <selectComponentKS
+              :showCol="mylistNum"
+              @getshowlist="getshowlist"
+              :fixedCol="fiexColumn"
+              :mediaType='mediaType'
+              
+            />
+            </div> -->
+            
+          </div>
+        </div>
+        <div class="listNum">
+          <p>已选{{mylistNum.length}}列</p>
+          <a-button id="btn" type="link" @click="clearAllList">清空全部</a-button>
+          <ul class="selectlist">
+                <!-- draggable="true"
+                  @dragstart="handleDragStart($event, item.dataIndex)"
+                  @dragover.prevent="handleDragOver($event, item.dataIndex)"
+                  @dragenter="handleDragEnter($event, item.dataIndex)"
+                  @dragend="handleDragEnd($event, item.dataIndex)" -->
+            <li v-for="(item,index) in mylistNum" :key="index">
+              <span v-if=" index < fiexColumn.length">
+                <a-icon type="lock" />
+                <span class="listText">{{item.title}}</span>
+              </span>
+              <span v-else-if=" index >=fiexColumn.length"  >
+                <a-icon type="menu" style="color:#ccc" />
+                <span class="listText">{{item.title}}</span>
+                <a-icon
+                  type="close"
+                  @click="deleteCol(item,index)"
+                  id="closeStyle"
+                  style="fontSize:12px;"
+                />
+              </span>
+            </li>
+          </ul>
+        </div>
+      </div>
+    </a-modal>
+  </div>
+</template>
+
+<script>
+import selectComponent from './selectComponent'
+import selectComponentKS from './selectComponentKS'
+export default {
+  components: {
+    selectComponent,
+    selectComponentKS,
+  },
+  props: ['visible', 'listNum', 'fiexColumn','mediaType'],
+
+  data() {
+    return {
+      dragging: null,
+      dataKey: 0,
+      visibleOk: false,
+      mylistNum: [],
+      loading: false
+    }
+  },
+  watch: {
+    visible(n, o) {
+      // console.log(n,o)
+      this.visibleOk = this.visible
+    },
+    listNum: {
+      handler(newValue, oldValue) {
+        console.log(newValue, oldValue)
+        this.mylistNum = newValue
+      },
+      immediate: true
+      // deep: true
+    }
+  },
+  methods: {
+     //li展示里的关闭按钮 删除当前被选中的这一个列
+    deleteCol(item, index) {
+      this.mylistNum = this.mylistNum.filter((item1, num) => {
+        return num != index
+      })
+    },
+    handleDragStart(e, item) {
+      this.dragging = item
+    },
+    handleDragEnd(e, item) {
+      this.dragging = null
+    },
+    //首先把div变成可以放置的元素,即重写dragenter/dragover
+    handleDragOver(e) {
+      e.dataTransfer.dropEffect = 'move' // e.dataTransfer.dropEffect="move";//在dragenter中针对放置目标来设置!
+    },
+    handleDragEnter(e, item) {
+      e.dataTransfer.effectAllowed = 'move' //为需要移动的元素设置dragstart事件
+      if (item === this.dragging) {
+        return
+      }
+      const newItems = [...this.mylistNum]
+      console.log(newItems)
+      const src = newItems.findIndex(v => v.dataIndex === this.dragging)
+      const dst = newItems.findIndex(v => v.dataIndex === item)
+
+      newItems.splice(dst, 0, ...newItems.splice(src, 1))
+
+      this.mylistNum = newItems
+    },
+    //弹出框确定
+    handleOk(e) {
+      this.loading = false
+      this.visibleOk = false
+      this.$emit('closeCustomColumn', false)
+      this.$emit('changeColumn', this.mylistNum)
+    },
+    //取消按钮
+    handleCancel() {
+      this.visibleOk = false
+      this.$emit('closeCustomColumn', false)
+    },
+    //清空全部
+    clearAllList() {
+      this.mylistNum = [...this.fiexColumn]
+    },
+    //从自定义列拿选择的项
+    getshowlist(val) {
+      var arr = []
+
+      // console.log(val)
+      if (val.length) {
+        if (val.flag) {
+          let newArr = val.arr
+          newVal.map((item, index) => {
+            // if(JSON.stringify(this.listNum).indexOf(JSON.stringify(item))==-1){
+            //  this.listNum.push(item); // 进行动态的操作
+            // }
+            var result = this.listNum.some(items => {
+              if (items.dataIndex == item.dataIndex) {
+                return true
+              }
+            })
+
+            // console.log(result)
+            if (result) {
+              newArr.splice(index, 1)
+            }
+          })
+
+          this.mylistNum = [...this.mylistNum, ...newArr]
+        } else {
+          //取消全选  清楚listNum中的val里的值
+          val.arr.map((item, index) => {
+            var result = this.mylistNum.some(items => {
+              if (items.dataIndex == item.dataIndex) {
+                return true
+              }
+            })
+            // console.log(result)
+            if (result) {
+              this.mylistNum.splice(index, 1)
+            }
+          })
+        }
+      } else {
+        arr = this.mylistNum.filter((item, index) => {
+          return item.dataIndex == val.dataIndex
+        })
+      }
+      if (arr.length) {
+        var index
+        this.mylistNum.map((item, ind) => {
+          if (item.dataIndex == val.dataIndex) {
+            index = ind
+          }
+        })
+        console.log(index)
+        this.mylistNum.splice(index, 1)
+      } else {
+        this.mylistNum.push(val)
+      }
+    }
+  },
+  mounted() {}
+}
+</script>
+
+<style lang="scss" scoped>
+
+
+.addlist {
+  float: left;
+  width: 70%;
+  border: 1px solid #eee;
+  .selectionList {
+    padding: 10px 15px;
+    height: 450px;
+    overflow: auto;
+    .leibie {
+      .leiName {
+        font-size: 26px;
+        text-align: left;
+      }
+    }
+    .jutixiang {
+      display: inline-block;
+      width: 32%;
+      box-sizing: border-box;
+      padding: 10px 3px;
+    }
+  }
+}
+.listNum {
+  float: right;
+  width: 28%;
+  border: 1px solid #eee;
+  position: relative;
+}
+.zhuti {
+  margin-top: 15px;
+  overflow: hidden;
+
+  p {
+    height: 40px;
+    line-height: 20px;
+    padding: 10px 15px;
+
+    background: rgb(249, 250, 253);
+    border-bottom: 1px solid #eee;
+  }
+  #btn {
+    position: absolute;
+    right: 0;
+    top: 5px;
+  }
+  .selectlist {
+    width: 100%;
+    list-style: none;
+    margin: 0;
+    height: 450px;
+    padding: 0 15px 10px;
+    overflow: auto;
+
+    li {
+      width: 100%;
+      padding: 5px 8px;
+      margin: 6px 0;
+      border-radius: 10px;
+      background: rgb(248, 248, 248);
+      height: 32px;
+      position: relative;
+      span {
+        width: 80%;
+        height: 100%;
+        display: inline-block;
+        margin: 0 10px;
+        // overflow:hidden;
+        // text-overflow:ellipsis;
+        // white-space: nowrap;
+      }
+      .listText {
+        position: absolute;
+        top: 2;
+        left: 10;
+        width: 60%;
+        overflow: hidden;
+        white-space: nowrap;
+        text-overflow: ellipsis;
+      }
+      #closeStyle {
+        position: absolute;
+        top: 9px;
+        right: 7px;
+      }
+    }
+  }
+}
+
+</style>

+ 240 - 0
src/components/youtTable/selectComponent.vue

@@ -0,0 +1,240 @@
+<template>
+  <div>
+    <div v-for="(item,index) in customFields" :key="index">
+      <div class="leibie">
+        <p class="leiName">{{item.title}}</p>
+        <!-- <span class="jutixiang">
+          <a-checkbox
+            :value="index"
+            name="type"
+            @change="isSelectAll($event,index)"
+            :checked="item.checkall"
+          >全选</a-checkbox>
+        </span> -->
+        <!-- {{item.form}} -->
+        <a-checkbox-group v-model="item.form" >
+          <span class="jutixiang" v-for="(zhi,num) in item.specificFields " :key="num">
+
+            <a-checkbox :value="zhi.dataIndex" :disabled="zhi.disabled"  name="type" @change="checkboxClick(zhi)">
+              <a-tooltip
+                class="select-component"
+                placement="top"
+                :title="zhi.tip"
+                :overlayClassName="tooltipShow"
+              >{{zhi.title}}</a-tooltip>
+            </a-checkbox>
+          </span>
+        </a-checkbox-group>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import  {TTcustomFields ,KScustomFields}  from '../../utils/columnConst/accountConst'
+// let customFields=customFields
+export default {
+  props: ['showCol','fixedCol','mediaType'],
+  data() {
+    return {
+        // customFields,
+      customFields:[],
+      quanxuanflag: [],
+      hovered: false,
+      tooltipShow: 'tooltipShow',
+      toParentArr: []
+    }
+  },
+  watch: {
+    
+    showCol(n) {
+      // console.log(n)
+      //
+      if (this.showCol.length == this.fixedCol.length) {
+
+        for (let i = 0; i < this.customFields.length; i++) {
+          this.customFields[i].form=[]          
+        }
+        this.showCol.map((item, index) => {
+          this.customFields.map((it, ind) => {
+            it.specificFields.map((i, d) => {
+              if (i.dataIndex === item.dataIndex) {
+                it.form.push(item.dataIndex)
+              }else{
+
+              }
+            })
+          })
+        })
+      } else {
+        
+       for (let i = 0; i < this.customFields.length; i++) {
+          this.customFields[i].form=[]
+          
+        }
+        n.map((item, index) => {
+          this.customFields.map((it, ind) => {
+            it.specificFields.map((i, d) => {
+              if (i.dataIndex === item.dataIndex) {
+                it.form.push(item.dataIndex)
+              }else{
+
+              }
+            })
+          })
+        })
+      }
+      // console.log(this.form)
+    },
+  
+  },
+  mounted() {
+    if(this.mediaType==1){
+      //头条自定义列
+      this.customFields=TTcustomFields
+    }else if(this.mediaType==2){
+      //快手自定义列
+      this.customFields=KScustomFields
+    }
+    for (let i = 0; i < this.customFields.length; i++) {
+      this.customFields[i].form=[]
+    }
+    // console.log(1)
+    this.showCol.map((item, index) => {
+      this.customFields.map((it, ind) => {
+        it.specificFields.map((i, d) => {
+          if (i.dataIndex === item.dataIndex) {
+            it.form.push(item.dataIndex)
+          }
+        })
+      })
+    })
+    this.fixedCol.map((item, index) => {
+      this.customFields.map((it, ind) => {
+        it.specificFields.map((i, d) => {
+          if (i.dataIndex === item.dataIndex) {
+            i.disabled=true;
+          }
+        })
+      })
+    })
+
+
+    // console.log(this.customFields);
+    
+  },
+  methods: {
+    hide() {
+      this.clicked = false
+      this.hovered = false
+    },
+    handleHoverChange(visible) {
+      this.clicked = false
+      this.hovered = visible
+    },
+    getPopupContainer() {
+      console.log(this)
+    },
+
+    //全选框   判断是否全选
+    isSelectAll(e, val) {
+      //像父元素传递
+      console.log(e, val)
+      let arr=JSON.parse(JSON.stringify(this.customFields[val].specificFields))
+      let valArr={
+        flag:true,
+        arr
+      }
+      this.customFields[val].checkall = e.target.checked
+      console.log(this.customFields[val].checkall)
+
+      if (this.customFields[val].checkall) {
+       
+        this.customFields[val].form=[]
+ 
+        this.customFields[val].specificFields.map((item, index) => {
+
+          this.customFields[val].form.push(item.dataIndex)
+
+        })
+        valArr.flag=true;
+        this.$emit('getshowlist', valArr)
+      } else {
+        console.log(this.customFields[val])
+        this.customFields[val].form=[];
+        valArr.flag=false;
+        console.log(this.customFields[val].form=[])
+        this.$emit('getshowlist', valArr)
+      }
+
+      console.log(this.form[val])
+    },
+
+    onChange(){
+        
+    },
+
+    //复选框的点击事件
+    checkboxClick(val) {
+      // console.log(val)
+    //   this.$emit('update:count',)
+      this.$emit('getshowlist', val)
+      // console.log(val,this.customFields[0].form)
+      // this.customFields[val].checkall=!this.customFields[val].checkall
+      // for (let i = 0; i < this.customFields.length; i++) {
+      //   // console.log(this.customFields[0].form,this.customFields[i].specificFields.length)
+      //   if(this.customFields[i].form.length==this.customFields[i].specificFields.length-1){
+      //       this.customFields[i].checkall=true;
+      //   }else{
+      //     this.customFields[i].checkall=false;
+      //   }
+          
+      //   }
+    }
+  }
+}
+</script>
+<style>
+.tooltipShow {
+  max-width: 30%;
+}
+.tooltipShow .ant-tooltip-content .ant-tooltip-inner {
+  background: white;
+  font-size: 10px;
+  color: #333;
+}
+.ant-tooltip-content .ant-tooltip-arrow::before {
+  background-color: white;
+}
+</style>
+<style lang="scss" scoped>
+.leibie {
+  width: 100%;
+  margin-bottom: 10px;
+  .leiName {
+    font-size: 20px;
+    text-align: left;
+    margin-bottom: 5px;
+    margin-top: 0px;
+  }
+}
+.jutixiang {
+  display: inline-block;
+  width: 32%;
+  box-sizing: border-box;
+  padding: 8px 3px;
+  height: 30px;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.ant-tooltip-content .tooltipShow {
+  background: #eee;
+  font-size: 10px;
+  color: #333;
+}
+
+.ant-checkbox-group {
+  width: 100%;
+}
+</style>

+ 240 - 0
src/components/youtTable/selectComponentKS.vue

@@ -0,0 +1,240 @@
+<template>
+  <div>
+    <div v-for="(item,index) in customFields" :key="index">
+      <div class="leibie">
+        <p class="leiName">{{item.title}}</p>
+        <!-- <span class="jutixiang">
+          <a-checkbox
+            :value="index"
+            name="type"
+            @change="isSelectAll($event,index)"
+            :checked="item.checkall"
+          >全选</a-checkbox>
+        </span> -->
+        <!-- {{item.form}} -->
+        <a-checkbox-group v-model="item.form" >
+          <span class="jutixiang" v-for="(zhi,num) in item.specificFields " :key="num">
+
+            <a-checkbox :value="zhi.dataIndex" :disabled="zhi.disabled"  name="type" @change="checkboxClick(zhi)">
+              <a-tooltip
+                class="select-component"
+                placement="top"
+                :title="zhi.tip"
+                :overlayClassName="tooltipShow"
+              >{{zhi.title}}</a-tooltip>
+            </a-checkbox>
+          </span>
+        </a-checkbox-group>
+      </div>
+    </div>
+  </div>
+</template>
+
+<script>
+import  {TTcustomFields ,KScustomFields}  from '../../utils/columnConst/accountConst'
+// let customFields=customFields
+export default {
+  props: ['showCol','fixedCol','mediaType'],
+  data() {
+    return {
+        // customFields,
+      customFields:[],
+      quanxuanflag: [],
+      hovered: false,
+      tooltipShow: 'tooltipShow',
+      toParentArr: []
+    }
+  },
+  watch: {
+    
+    showCol(n) {
+      // console.log(n)
+      //
+      if (this.showCol.length == this.fixedCol.length) {
+
+        for (let i = 0; i < this.customFields.length; i++) {
+          this.customFields[i].form=[]          
+        }
+        this.showCol.map((item, index) => {
+          this.customFields.map((it, ind) => {
+            it.specificFields.map((i, d) => {
+              if (i.dataIndex === item.dataIndex) {
+                it.form.push(item.dataIndex)
+              }else{
+
+              }
+            })
+          })
+        })
+      } else {
+        
+       for (let i = 0; i < this.customFields.length; i++) {
+          this.customFields[i].form=[]
+          
+        }
+        n.map((item, index) => {
+          this.customFields.map((it, ind) => {
+            it.specificFields.map((i, d) => {
+              if (i.dataIndex === item.dataIndex) {
+                it.form.push(item.dataIndex)
+              }else{
+
+              }
+            })
+          })
+        })
+      }
+      // console.log(this.form)
+    },
+  
+  },
+  mounted() {
+    if(this.mediaType==1){
+      //头条自定义列
+      this.customFields=TTcustomFields
+    }else if(this.mediaType==2){
+      //快手自定义列
+      this.customFields=KScustomFields
+    }
+    for (let i = 0; i < this.customFields.length; i++) {
+      this.customFields[i].form=[]
+    }
+    // console.log(1)
+    this.showCol.map((item, index) => {
+      this.customFields.map((it, ind) => {
+        it.specificFields.map((i, d) => {
+          if (i.dataIndex === item.dataIndex) {
+            it.form.push(item.dataIndex)
+          }
+        })
+      })
+    })
+    this.fixedCol.map((item, index) => {
+      this.customFields.map((it, ind) => {
+        it.specificFields.map((i, d) => {
+          if (i.dataIndex === item.dataIndex) {
+            i.disabled=true;
+          }
+        })
+      })
+    })
+
+
+    // console.log(this.customFields);
+    
+  },
+  methods: {
+    hide() {
+      this.clicked = false
+      this.hovered = false
+    },
+    handleHoverChange(visible) {
+      this.clicked = false
+      this.hovered = visible
+    },
+    getPopupContainer() {
+      console.log(this)
+    },
+
+    //全选框   判断是否全选
+    isSelectAll(e, val) {
+      //像父元素传递
+      console.log(e, val)
+      let arr=JSON.parse(JSON.stringify(this.customFields[val].specificFields))
+      let valArr={
+        flag:true,
+        arr
+      }
+      this.customFields[val].checkall = e.target.checked
+      console.log(this.customFields[val].checkall)
+
+      if (this.customFields[val].checkall) {
+       
+        this.customFields[val].form=[]
+ 
+        this.customFields[val].specificFields.map((item, index) => {
+
+          this.customFields[val].form.push(item.dataIndex)
+
+        })
+        valArr.flag=true;
+        this.$emit('getshowlist', valArr)
+      } else {
+        console.log(this.customFields[val])
+        this.customFields[val].form=[];
+        valArr.flag=false;
+        console.log(this.customFields[val].form=[])
+        this.$emit('getshowlist', valArr)
+      }
+
+      console.log(this.form[val])
+    },
+
+    onChange(){
+        
+    },
+
+    //复选框的点击事件
+    checkboxClick(val) {
+      // console.log(val)
+    //   this.$emit('update:count',)
+      this.$emit('getshowlist', val)
+      // console.log(val,this.customFields[0].form)
+      // this.customFields[val].checkall=!this.customFields[val].checkall
+      // for (let i = 0; i < this.customFields.length; i++) {
+      //   // console.log(this.customFields[0].form,this.customFields[i].specificFields.length)
+      //   if(this.customFields[i].form.length==this.customFields[i].specificFields.length-1){
+      //       this.customFields[i].checkall=true;
+      //   }else{
+      //     this.customFields[i].checkall=false;
+      //   }
+          
+      //   }
+    }
+  }
+}
+</script>
+<style>
+.tooltipShow {
+  max-width: 30%;
+}
+.tooltipShow .ant-tooltip-content .ant-tooltip-inner {
+  background: white;
+  font-size: 10px;
+  color: #333;
+}
+.ant-tooltip-content .ant-tooltip-arrow::before {
+  background-color: white;
+}
+</style>
+<style lang="scss" scoped>
+.leibie {
+  width: 100%;
+  margin-bottom: 10px;
+  .leiName {
+    font-size: 20px;
+    text-align: left;
+    margin-bottom: 5px;
+    margin-top: 0px;
+  }
+}
+.jutixiang {
+  display: inline-block;
+  width: 32%;
+  box-sizing: border-box;
+  padding: 8px 3px;
+  height: 30px;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+
+.ant-tooltip-content .tooltipShow {
+  background: #eee;
+  font-size: 10px;
+  color: #333;
+}
+
+.ant-checkbox-group {
+  width: 100%;
+}
+</style>

+ 98 - 0
src/directive.js

@@ -0,0 +1,98 @@
+const directives = {
+    'card': {
+        inserted(el, binding, vnode, oldVnode) {
+            el.classList.add('page-card');
+            el.style.height = window.innerHeight - 125 + 'px';
+
+            function heightHandler(e) {
+                el.style.height = window.innerHeight - 125 + 'px';
+            }
+            // 给当前元素绑定个私有变量,方便在unbind中可以解除事件监听
+            el.__page_card__ = heightHandler;
+            window.addEventListener('resize', heightHandler);
+        },
+        unbind(el, binding) {
+            // 解除事件监听
+            window.removeEventListener('resize', el.__page_card__);
+            delete el.__page_card__;
+        }
+    },
+    'dialog-drag': { // 弹窗拖拽
+        bind(el, binding, vnode, oldVnode) {
+            const dialogHeaderEl = el.querySelector('.ant-modal-header');
+            const dragDom = el.querySelector('.ant-modal-content');
+            dialogHeaderEl.style.cursor = 'move';
+    
+            // 获取原有属性 ie dom元素.currentStyle 火狐谷歌 window.getComputedStyle(dom元素, null);
+            const sty = dragDom.currentStyle || window.getComputedStyle(dragDom, null);
+            
+            dialogHeaderEl.onmousedown = (e) => {
+                // 鼠标按下,计算当前元素距离可视区的距离
+                const disX = e.clientX - dialogHeaderEl.offsetLeft;
+                const disY = e.clientY - dialogHeaderEl.offsetTop;
+                
+                // 获取到的值带px 正则匹配替换
+                let styL, styT;
+    
+                // 注意在ie中 第一次获取到的值为组件自带50% 移动之后赋值为px
+                if(sty.left.includes('%')) {
+                    styL = +document.body.clientWidth * (+sty.left.replace(/\%/g, '') / 100);
+                    styT = +document.body.clientHeight * (+sty.top.replace(/\%/g, '') / 100);
+                }else {
+                    styL = +sty.left.replace(/\px/g, '');
+                    styT = +sty.top.replace(/\px/g, '');
+                };
+                
+                document.onmousemove = function (e) {
+                    // 通过事件委托,计算移动的距离 
+                    const l = e.clientX - disX;
+                    const t = e.clientY - disY;
+                    // 移动当前元素  
+                    dragDom.style.left = `${l + styL}px`;
+                    dragDom.style.top = `${t + styT}px`;
+    
+                    //将此时的位置传出去
+                    //binding.value({x:e.pageX,y:e.pageY})
+                };
+    
+                document.onmouseup = function (e) {
+                    document.onmousemove = null;
+                    document.onmouseup = null;
+                };
+            }  
+        }
+    },
+    'clickoutside': {
+        // 初始化指令
+        bind(el, binding, vnode) {
+            function documentHandler(e) {
+                // 这里判断点击的元素是否是本身,是本身,则返回
+                if (el.contains(e.target)) {
+                    return false;
+                }
+                // 判断指令中是否绑定了函数
+                if (binding.expression) {
+                    // 如果绑定了函数 则调用那个函数,此处binding.value就是handleClose方法
+                    binding.value(e);
+                }
+            }
+            // 给当前元素绑定个私有变量,方便在unbind中可以解除事件监听
+            el.__vueClickOutside__ = documentHandler;
+            document.addEventListener('click', documentHandler);
+        },
+        update() {},
+        unbind(el, binding) {
+            // 解除事件监听
+            document.removeEventListener('click', el.__vueClickOutside__);
+            delete el.__vueClickOutside__;
+        },
+    }
+}
+
+export default {
+    install: function(Vue) {
+        Object.keys(directives).forEach(key => {
+            Vue.directive(key, directives[key]);
+        })
+    }
+}

+ 301 - 0
src/filters.js

@@ -0,0 +1,301 @@
+
+import moment from 'moment';
+function fixedZero(val) {
+    return val * 1 < 10 ? `0${val}` : val;
+}
+const filters = {
+    // 格式化时间展示多长时间之前
+    formatTime(time) {
+        let formatTime
+        const date = new Date(time)
+        const dateObj = {
+            year: date.getFullYear(),
+            month: date.getMonth(),
+            date: date.getDate(),
+            hours: date.getHours(),
+            minutes: date.getMinutes()
+        }
+        const newTime = new Date()
+        const diff = newTime.getTime() - time
+        if (newTime.getDate() === dateObj.date && diff < 60000) {
+            formatTime = '刚刚'
+        } else if (
+            newTime.getDate() === dateObj.date &&
+            diff > 60000 &&
+            diff < 3600000
+        ) {
+            formatTime = `${Math.floor(diff / 60000)}分钟前`
+        } else if (
+            newTime.getDate() === dateObj.date &&
+            diff > 3600000 &&
+            diff < 86400000
+        ) {
+            formatTime = `${addZero(dateObj.hours)}:${addZero(dateObj.minutes)}`
+        } else if (newTime.getDate() !== dateObj.date && diff < 86400000) {
+            formatTime = `昨天${addZero(dateObj.hours)}:${addZero(dateObj.minutes)}`
+        } else if (newTime.getFullYear() === dateObj.year) {
+            formatTime = `${dateObj.month + 1}月${dateObj.date}日`
+        } else {
+            formatTime = `${dateObj.year}年${dateObj.month + 1}月${dateObj.date}日`
+        }
+        return formatTime
+    },
+    //时间日期格式化
+    format(time) {
+        const hours = 60 * 60 * 1000;
+        const minutes = 60 * 1000;
+
+        const h = Math.floor(time / hours);
+        const m = Math.floor((time - h * hours) / minutes);
+        const s = Math.floor((time - h * hours - m * minutes) / 1000);
+        return `${fixedZero(h)}:${fixedZero(m)}:${fixedZero(s)}`
+    },
+    //年月日格式化
+    getDate(value) {
+        let date = new Date(value)
+        let y = date.getFullYear()
+        let MM = date.getMonth() + 1
+        MM = MM < 10 ? '0' + MM : MM
+        let d = date.getDate()
+        d = d < 10 ? '0' + d : d
+        return y + '-' + MM + '-' + d
+    },
+    //年月日时分秒格式化
+    formatDate: function (value) {
+        let date = new Date(value)
+        let y = date.getFullYear()
+        let MM = date.getMonth() + 1
+        MM = MM < 10 ? '0' + MM : MM
+        let d = date.getDate()
+        d = d < 10 ? '0' + d : d
+        let h = date.getHours()
+        h = h < 10 ? '0' + h : h
+        let m = date.getMinutes()
+        m = m < 10 ? '0' + m : m
+        let s = date.getSeconds()
+        s = s < 10 ? '0' + s : s
+        return y + '-' + MM + '-' + d + ' ' + h + ':' + m + ':' + s
+    },
+    //bidType类型
+    bidType(sta) {
+        var data = {
+            null: '-',
+            1: 'CPM',
+            2: 'CPC',
+            6: 'OCPC',
+            10: 'OCPM',
+        }
+        return data[sta]
+    },
+    //ocpxActionType类型
+    ocpxActionType(sta) {
+        var data = {
+            null: '-',
+            0: '封面点击',
+            2: '行为数',
+            10: '曝光',
+            11: '点击',
+            31: '下载完成',
+            53: '提交线索',
+            180: '激活',
+            190: '付费',
+            191: '首日ROI',
+            348: '有效线索',
+            383: '授信',
+            384: '完件',
+            394: '订单提交',
+        }
+        return data[sta]
+    },
+    //角色类型
+    roleCode(value) {
+        var state = {
+            clip: '剪辑',
+            shot: '拍摄',
+            plan: '策划',
+            plane: '平面',
+            admin: '管理员',
+            operator: '运营专员',
+            kuaishouOperationManager: '快手运营经理',
+            designTeamLeader: '设计组长',
+            planeLeader: '平面组长',
+            touTiaoOperationManager: '头条运营经理',
+            operationAssistant: '运营助理',
+        }
+
+        if (value) {
+            return state[value]
+        } else {
+            return '暂无'
+        }
+    },
+    //保留两位小数并且变成货币格式
+    decimalsHandle(val) {
+        if (val && typeof val != 'string') {
+            if (val >= 0) {
+                val = parseFloat(val).toFixed(2);
+                let numberStr = val.toString()
+                let str = numberStr.split('.')
+
+                let str0 = str[0].split('').reverse();
+                for (let i = 0; i < str0.length; i++) {
+                    if ((i + 1) % 4 === 0) {
+                        str0.splice(i, 0, ',')
+                    }
+                }
+                str0.reverse()
+                let handleResult = ''
+                for (let j = 0; j < str0.length; j++) {
+                    handleResult += str0[j]
+                }
+
+                return handleResult + '.' + str[1]
+            } else {
+                val = parseFloat(val).toFixed(2);
+                let numberStr = val.toString()
+                let str = numberStr.split('.')
+
+                let str0 = str[0].substr(1).split('').reverse();
+                for (let i = 0; i < str0.length; i++) {
+                    if ((i + 1) % 4 === 0) {
+                        str0.splice(i, 0, ',')
+                    }
+                }
+                str0.reverse()
+                let handleResult = ''
+                for (let j = 0; j < str0.length; j++) {
+                    handleResult += str0[j]
+                }
+
+                return '-' + handleResult + '.' + str[1]
+            }
+
+        } else if (typeof val == 'string') {
+            return val
+        }
+        else {
+            return 0
+        }
+    },
+    //变成货币格式
+    formatCurrency(val) {
+        if ((val || val == 0) && typeof val != 'string') {
+            let numberStr = val.toString()
+            let str = numberStr.split('').reverse()
+            for (let i = 0; i < str.length; i++) {
+                if ((i + 1) % 4 === 0) {
+                    str.splice(i, 0, ',')
+                }
+            }
+            str.reverse()
+            let handleResult = ''
+            for (let j = 0; j < str.length; j++) {
+                handleResult += str[j]
+            }
+            return handleResult
+        } else if (typeof val == 'string') {
+            return val
+        }
+        else {
+            return '-'
+        }
+
+    },
+    //加百分比
+    toPercentage(val) {
+        if (val) {
+            if (typeof val != 'string') {
+                return (val * 100).toFixed(2) + '%'
+            } else {
+                return val
+            }
+        } else if (typeof val == 'string') {
+            return val
+        }
+        else {
+            return 0
+        }
+    },
+    //媒体类型
+    handleMediaType(val) {
+        switch (val) {
+            case 1:
+                return '头条'
+                break
+
+            case 2:
+                return '快手'
+                break
+
+            case 3:
+                return '头条内广'
+                break
+
+            case 4:
+                return '快手内广'
+                break
+
+            default:
+                break
+        }
+    },
+    //文件大小
+    sizeShow(value) {
+        return (value / 1024).toFixed(2)
+    },
+    //预警计算符号
+    conditionName(val) {
+        var data = {
+            equal: '=',//'等于',
+            not_equal: '≠',//不等于,
+            greater: '>',//大于
+            less: '<',//小于
+            greater_equal: '≥',//大于等于
+            less_equal: '≤',//小于等于
+        }
+
+        return data[val]
+    },
+}
+
+// 获取当前月的第一天
+function getCurrentMonthFirst() {
+    let date = new Date();
+    date.setDate(1);
+    return date;
+}
+// 获取当前月的最后一天
+function getCurrentMonthLast() {
+    let date = new Date();
+    let currentMonth = date.getMonth();
+    let nextMonth = ++currentMonth;
+    let nextMonthFirstDay = new Date(date.getFullYear(), nextMonth, 1);
+    let oneDay = 1000 * 60 * 60 * 24;
+    return new Date(nextMonthFirstDay - oneDay);
+}
+// 今日日期小于15号时和今日日期大于等于15号时
+function getCurrentMonthFifty() {
+    let date = new Date();
+    if (date.getDate() < 15) {
+        let bb = date.setTime(new Date().getTime() - 3600 * 1000 * 24 * 15);
+        return bb;
+    } else if (date.getDate() >= 15) {
+        let year = date.getFullYear();
+        let month = date.getMonth();
+        let myDate = new Date(year, month, 0);
+        let lastDay = year + "-" + month + "-" + myDate.getDate();//上个月的最后一天
+        return lastDay;
+    }
+
+}
+
+export default {
+    install: function (Vue) {
+        Object.keys(filters).forEach(key => {
+            Vue.filter(key, filters[key])
+        })
+    }
+
+}
+
+

+ 4 - 1
src/main.js

@@ -28,7 +28,10 @@ import 'vue-photo-preview/dist/skin.css'
 import VuePreview from 'vue-preview';
 import promiseFinally from 'promise.prototype.finally';
 promiseFinally.shim();
-
+import directive from './directive'
+import filters from './filters'
+Vue.use(directive)
+Vue.use(filters)
 import md5 from 'blueimp-md5';
 
 // import KFormDesign from 'k-form-design'

+ 7 - 7
src/router/index.js

@@ -1,14 +1,14 @@
 import Vue from 'vue'
 import Router from 'vue-router'
-import {constantRouterMap} from '@/config/router.config'
+import { constantRouterMap } from '@/config/router.config'
 
 try {
-    const originalPush = Router.prototype.push
-    Router.prototype.push = function push(location) {
-      return originalPush.call(this, location).catch(err => err)
-    }
-  } catch (e) {
+  const originalPush = Router.prototype.push
+  Router.prototype.push = function push(location) {
+    return originalPush.call(this, location).catch(err => err)
   }
+} catch (e) {
+}
 
 Vue.use(Router)
 
@@ -22,6 +22,6 @@ Vue.use(Router)
 export default new Router({
   mode: 'history',
   base: process.env.BASE_URL,
-  scrollBehavior: () => ({y: 0}),
+  scrollBehavior: () => ({ y: 0 }),
   routes: constantRouterMap
 })

Diff do ficheiro suprimidas por serem muito extensas
+ 1323 - 0
src/utils/columnConst/accountConst.js


src/views/modules/autoLaunch/setCreate.vue → src/utils/columnConst/videoConst.js


+ 24 - 79
src/views/dashboard/Analysis.vue

@@ -237,105 +237,50 @@
          <a-icon type="notification" theme='twoTone'/> 更新通告
       </div>
       <div class="Updatecontent">
+        
         <div class="Updateitem">
             <div class="Updatetime">
                  <a-icon type="dashboard" theme='twoTone' class="updateicon" />
-                 <span class="updateSpan">{{updateTime[3]}}</span>
-            </div>
-            <div class="updateText">
-              <div class="updateBox">
-                <h3 class="textTitle">1.脚本库加word下载;</h3>
-              </div>
-              <div class="updateBox">
-                <h3 class="textTitle">2.上线媒介报表;</h3>
-                
-              </div>
-              <div class="updateBox">
-                <h3 class="textTitle">3.快手批量工具更新:</h3>
-                <ul class="updatelist">
-                  <li> <span class="circular"></span>创建组时--商业兴趣加智能推荐</li>
-                  <li><span class="circular"></span>在复制组时可选是否修改定向</li>
-                  <li><span class="circular"></span>计划、组、创意列表页加id、名称模糊搜索</li>
-                  <li><span class="circular"></span>复制组时连带组名一起复制,可对组名进行修改</li>
-                </ul>
-              </div>
-                      
-            </div>
-        </div>
-        <div class="Updateitem">
-            <div class="Updatetime">
-                 <a-icon type="dashboard" theme='twoTone' class="updateicon" />
-                 <span class="updateSpan">{{updateTime[2]}}</span>
+                 <span class="updateSpan">{{updateTime[0]}}</span>
             </div>
             <div class="updateText">
               <div class="updateBox">
-                <h3 class="textTitle">1.快手批量工具更新:</h3>
+                <h3 class="textTitle">1.预警管理新功能上线</h3>
                 <ul class="updatelist">
-                  <li> <span class="circular"></span> 批量创建创意页面加入推荐文案,可根据关键词匹配文案;</li>
-                  <li><span class="circular"></span>批量创建创意选择内部素材可根据时间排序、筛选(天维度);</li>
+                  <li><span class="circular"></span>预警检查频率提升到15分钟一次;</li>
+                  <li><span class="circular"></span>预警系统增加历史导出记录;</li>
+                  <li><span class="circular"></span>推送预警模板增加操作符显示;</li>
                 </ul>
               </div>
               <div class="updateBox">
-                <h3 class="textTitle">2.脚本库重磅上线(位置:素材管理--脚本库)</h3>
-                <ul class="updatelist">
-                  <li> <span class="circular"></span> 脚本可在线编辑,并实时保存;</li>
-                  <li><span class="circular"></span>可在线打印,支持导出脚本;</li>
-                  <li><span class="circular"></span>可在线打印,支持导出脚本;</li>
-                </ul>
-              </div>
-              <div class="updateBox">
-                <h3 class="textTitle">3.支持飞书扫码登录助手</h3>
-                
-              </div>
-                      
-            </div>
-        </div>
-        <div class="Updateitem">
-            <div class="Updatetime">
-                 <a-icon type="dashboard" theme='twoTone' class="updateicon" />
-                 <span class="updateSpan">{{updateTime[1]}}</span>
-            </div>
-            <div class="updateText">
-              <div class="updateBox">
-                <h3 class="textTitle">1.快手批量工具更新:</h3>
-                <ul class="updatelist">
-                  <li> <span class="circular"></span> 批量更改监测链接;</li>
-                  <li><span class="circular"></span>素材审核驳回在企业微信发消息提醒;</li>
-                  <li><span class="circular"></span>推送失败在企业微信发消息;</li>
-                  <li><span class="circular"></span>广告语加入动态词包;</li>
-                  <li><span class="circular"></span>屏蔽停投的账户;</li>
+                <h3 class="textTitle">2.头条内广更新</h3>
+                <ul>
+                  <li><span class="circular"></span>头条内广数据API重新接入,历史数据持续补充;</li>
                 </ul>
               </div>
               <div class="updateBox">
-                <h3 class="textTitle">2.素材管理--视频素材-加素材名称搜索</h3>
-              </div>
-                      
-            </div>
-        </div>
-        <div class="Updateitem">
-            <div class="Updatetime">
-                 <a-icon type="dashboard" theme='twoTone' class="updateicon" />
-                 <span class="updateSpan">{{updateTime[0]}}</span>
-            </div>
-            <div class="updateText">
-              <div class="updateBox">
-                <h3 class="textTitle">1.头条-账户报表上线通知</h3>
-                <ul class="updatelist">
-                  <li><span class="circular"></span>点击“统计报表-头条报表-账户报表”查看模块</li>
-                  <li><span class="circular"></span>可根据项目账户筛选查看数据,支持时间筛选</li>
-                  <li><span class="circular"></span>支持报表导出</li>
+                <h3 class="textTitle">3.素材下单制优化</h3>
+                <ul>
+                  <li><span class="circular"></span>优化视频(视频、标签、封面)、脚本下方位置按钮,根据屏幕适配位置;</li>
+                  <li><span class="circular"></span>已上传未审核的脚本,视频支持重新上传;</li>
+                  <li><span class="circular"></span>当投放系统为安卓时,apk的链接修改为非必填;</li>
+                  <li><span class="circular"></span>运营下单时,日均产量修改非必填;</li>
+                  <li><span class="circular"></span>视频素材入库区分类型(真人、剪辑);</li>
+                  <li><span class="circular"></span>修复了相关BUG;</li>
                 </ul>
               </div>
               <div class="updateBox">
-                <h3 class="textTitle">2.快手批量工具更新</h3>
+                <h3 class="textTitle">4.预警管理优化</h3>
                 <ul>
-                  <li><span class="circular"></span>在创建创意模块加了时间维度筛选</li>
+                  <li><span class="circular"></span>预警模版新增字段添加;</li>
+                  <li><span class="circular"></span>相关字段后台逻辑优化;</li>
                 </ul>
               </div>
               <div class="updateBox">
-                <h3 class="textTitle">3.视频报表修改</h3>
+                <h3 class="textTitle">5.优化浏览器进入汇创助手加载速度,清理缓存垃圾;</h3>
                 <ul>
-                  <li><span class="circular"></span>添加了视频上传时间字段</li>
+                  <!-- <li><span class="circular"></span>预警模版新增字段添加;</li>
+                  <li><span class="circular"></span>相关字段后台逻辑优化;</li> -->
                 </ul>
               </div>
             </div>
@@ -412,7 +357,7 @@
         indicator: <a-icon type="loading" style="font-size: 24px" spin />,
         roleCode: localStorage.getItem('roleCode'),
         visible:false,//更新通知消息提示框
-        updateTime:['2020-06-10','2020-06-17','2020-06-24','2020-07-01'],
+        updateTime:['2021-01-20'],
         versionId:0,//存储版本号 判断通知什么时候显示
       }
     },

+ 0 - 9
src/views/modules/BatchCreate/newCreate.vue

@@ -99,7 +99,6 @@
               </a-form-item>
             </div>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -129,7 +128,6 @@
             </div> -->
             <material ref="material" :creativeType="getFormData('creativeWay')"></material>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -145,7 +143,6 @@
               </a-form-item>
             </div>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -158,7 +155,6 @@
               </a-form-item>
             </div>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -178,7 +174,6 @@
               </a-form-item>
             </div>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -191,7 +186,6 @@
               </a-form-item>
             </div>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -204,7 +198,6 @@
               </a-form-item>
             </div>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -220,7 +213,6 @@
               </a-form-item>
             </div>
           </div>
-
           <div class="row-item">
             <div class="hint-item"></div>
             <div class="label-item">
@@ -678,7 +670,6 @@
                     // res.data.forEach((item)=>{
                     //   this.$message.error(item.message)
                     // })
-
                   } else {
                     this.loading=false;
                   }

+ 7 - 7
src/views/modules/Statistics/KSAccountReport.vue

@@ -1284,13 +1284,13 @@ export default {
     },
   },
   mounted() {
-    this.accountHttp()
-    new Promise((resolve, reject) => {
-      this.getEchartData('sectionChart', this.sectionOption)
-      resolve()
-    }).then(()=>{
-      this.myChart.clear()
-    })
+    // this.accountHttp()
+    // new Promise((resolve, reject) => {
+    //   this.getEchartData('sectionChart', this.sectionOption)
+    //   resolve()
+    // }).then(()=>{
+    //   this.myChart.clear()
+    // })
     
     postAction('/toutiao/videoReportDaily/getColumnJson', {
       columnType: 2

+ 509 - 0
src/views/modules/Statistics/materialReport/materialReport.vue

@@ -0,0 +1,509 @@
+<template>
+    <div class="materialReport">
+        <div class="card-container">
+            <a-tabs type="card">
+            <a-tab-pane key="1" >
+                <span slot="tab">
+                    <a-icon type="apple" />
+                    大盘
+                </span>  
+            </a-tab-pane>
+            <a-tab-pane key="2" >
+                <span slot="tab">
+                    <a-icon type="apple" />
+                   快手
+                </span>
+            </a-tab-pane>
+            <a-tab-pane key="3" >
+                <span slot="tab">
+                    <a-icon type="apple" />
+                    头条
+                </span>
+            </a-tab-pane>
+            </a-tabs>
+            <div class="option">
+                <div class="item">
+                    <span>上传时间</span>
+                    <a-range-picker
+                    v-model="dateValue"
+                    :ranges="dateRanges"
+                    
+                    :disabled-date="disabledDate"
+                    style="width:250px"
+                    />
+                </div>
+                <div class="item">
+                    <span>数据日期</span>
+                    <a-range-picker
+                    v-model="dateValue"
+                    :ranges="dateRanges"
+                    
+                    :disabled-date="disabledDate"
+                    style="width:250px"
+                    />
+                </div>
+                <div class="item">
+                    <span>数据维度</span>
+                    <a-radio-group v-model="dataDimension" @change="dataDimensionChange">
+                        <a-radio-button value="a">媒体</a-radio-button>
+                        <a-radio-button value="b">组别</a-radio-button>
+                        <a-radio-button value="c">项目</a-radio-button>
+                        <a-radio-button value="d">设计</a-radio-button>
+                    </a-radio-group>
+                    <a-select  style="width: 200px;margin-left:10px" v-model="dataDimensionValue" allowClear  :loading='specificLoading'>
+                        <a-select-option v-for="(item,index) in dataDimensionList" :key="index" :value='item.id'>
+                            {{item.name}}
+                        </a-select-option>
+                    </a-select>
+                </div>
+            </div>
+        </div>
+
+        <div class="echart">
+            <div class="echart-header">
+                数据趋势
+            </div>
+            <div class="echartBody">
+                <div id="echart" ref="echart" style="width:100%;height:350px">
+                    <!-- <a-empty style="position: relative; top: 50%; margin-top: -65px" /> -->
+                </div>
+            </div>
+        </div>
+
+        <div class="tableBody">
+            <YoutTable 
+                headTitle='详细数据'
+                :isNeedCustomColumn='true'
+                :isNeedExport='true'
+                :mediaType='1'
+                :columns='column'
+                :columnsFixd='columnsFixd'
+                :scrollX='2500'
+                :pagination='ipagination'
+                @exportExcel='exportExcel'
+                @change='tableChange'
+            >
+
+            </YoutTable>
+        </div>
+    </div>
+</template>
+
+<script>
+import moment from 'moment';
+import { getAction, postAction, downFile, downFilePost } from '@/api/manage';
+import YoutTable from '@/components/youtTable/YoutTable'
+var echarts = require('echarts')
+
+const columnsFixd = [
+    {
+        title: '时间',
+        dataIndex: 'date',
+        scopedSlots: { customRender: 'date' },
+        align: 'center',
+        key:'date',
+        width:200,
+        fixed:'left',
+        
+    },
+    {
+        title: '账户ID',
+        dataIndex: 'accountId',
+        align: 'center',
+        width: 200,
+        fixed:'left',
+        scopedSlots: { customRender: 'accountId' }
+    },
+    {
+        title: '账户昵称',
+        dataIndex: 'authName',
+        align: 'center',
+        width: 200,
+        fixed:'left',
+    },
+    
+]
+
+const initVariableColimns=[
+    {
+          title: '消耗(元)',
+          dataIndex: 'cost',
+          width:150,
+          tip: '广告在投放期间的花费总额',
+          align: 'center',
+          scopedSlots: { customRender: 'cost' },
+          sorter: () => {}
+    },
+      // {
+      //     title: '折后消耗(元)',
+      //     dataIndex: 'discountCost',
+      //     width:150,
+      //     tip: '广告在投放期间的花费总额',
+      //     align: 'center',
+      //     scopedSlots: { customRender: 'discountCost' },
+      //     sorter: () => {}
+      // },
+    {
+        title: '封面曝光数',
+        dataIndex: 'photoShow',
+        tip: '广告在瀑布流被观看次数',
+        align: 'center',       
+        scopedSlots: { customRender: 'photoShow' },
+        sorter:() => {}
+    },
+    {
+        title: '封面点击数',
+        dataIndex: 'photoClick',
+        tip: '用户点击封面进入视频播放页的次数(数据会进行反作弊去重)',
+        align: 'center',
+    
+        scopedSlots: { customRender: 'photoClick' },
+        sorter: () => {}
+    },
+    {
+        title: '封面点击率',
+        dataIndex: 'clickRate',
+        tip: '封面点击数占封面展示数百分比',
+        align: 'center',    
+        scopedSlots: { customRender: 'clickRate' },
+        sorter:() => {}
+    },
+    {
+        title: '素材曝光数',
+        dataIndex: 'aClick',
+        tip: '用户进入视频播放页观看的次数(数据会进行反作弊去重)',
+        align: 'center',
+    
+        scopedSlots: { customRender: 'aClick' },
+        sorter:() => {}
+    },
+    {
+        title: '行为数',
+        dataIndex: 'bClick',
+        tip: '用户在视频播放页单击转化按钮的次数/展示数*100%',
+        align: 'center',
+    
+        scopedSlots: { customRender: 'bClick' },
+        sorter:() => {}
+    },
+    
+    {
+        title: '行为率',
+        dataIndex: 'bClickRate',
+        tip: '行为数占素材曝光数百分比',
+        align: 'center',    
+        scopedSlots: { customRender: 'bClickRate' },
+        sorter:() => {}
+    },
+    {
+        title: '平均千次封面曝光花费(元)',
+        dataIndex: 'cpm',
+        tip: '花费/封面曝光数*1000',
+        align: 'center',    
+        scopedSlots: { customRender: 'cpm' },
+        sorter:() => {}
+    },
+    {
+        title: '平均封面点击单价(元)',
+        dataIndex: 'cpc',
+        tip: '花费/封面点击数',
+        align: 'center',    
+        scopedSlots: { customRender: 'cpc' },
+        sorter:() => {}
+    },
+    {
+        title: '平均行为单价(元)',
+        dataIndex: 'cpb',
+        tip: '总花费/行为数',
+        align: 'center',    
+        scopedSlots: { customRender: 'cpb' },
+        sorter:() => {}
+    },
+]
+    export default {
+        components:{
+            YoutTable,
+        },
+        data() {
+            return {
+                column:[...columnsFixd,...initVariableColimns] ,//table的表头
+                columnsFixd,
+                ipagination: {
+                    current: 1,
+                    pageSize: 10,
+                    //   pageSizeOptions: ['10', '20', '30'],
+                    showTotal: (total, range) => {
+                        return range[0] + "-" + range[1] + " 共" + total + "条"
+                    },
+                    showQuickJumper: true,
+                    showSizeChanger:true,
+                    pageSizeOptions: ['10', '30', '50'],
+                    total: 0,
+                    onChange: (current, pageSize) => {
+                        // 切换分页时的回调,
+                        // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
+                        this.ipagination.current = current;
+                        this.ipagination.pageSize= pageSize;
+                    }
+                },
+
+                dateRanges:{ '今天': [moment(), moment()],
+                '昨天':[moment().subtract(1,'days'), moment().subtract(1,'days')],
+                '半个月': [moment(), moment().endOf('month')], 
+                '一个月': [moment(), moment().endOf('month')], 
+                },
+                dateValue:[],
+                dataDimension:'a',
+                dataDimensionValue:'',
+                dataDimensionList:[],
+                specificLoading:false,
+            }
+        },
+        methods: {
+            //导出报表
+            exportExcel() {
+                console.log('触发导出事件')
+                let column = this.columns.map((item, index) => {
+                    
+                        return item.dataIndex      
+                        
+                })
+                let columns=column.splice(3)
+                    // console.log(columns)
+                downFilePost('/ctop/kuaishou/dailyPage/report/excel', {
+                    
+                    mediaId:this.mediaId,
+                    discount:this.discount,
+                    accountIds:this.accountId,
+                    startDate:this.dateValue[0].format('YYYY-MM-DD'),
+                    endDate:this.dateValue[1].format('YYYY-MM-DD'),
+                    hour:this.timeSelectValue,
+                    target:this.target,
+                    order:this.order,
+                    columns,
+                    
+                }).then(res => {
+                    let blob = new Blob([res], {
+                    type:'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
+                    })
+                    let downloadElement = document.createElement('a')
+                    let href = window.URL.createObjectURL(blob) //创建下载的链接
+                    downloadElement.href = href
+                    downloadElement.download = moment().format('YYYY-MM-DD') + '账户报表.xlsx' //下载后文件名
+                    document.body.appendChild(downloadElement)
+                    downloadElement.click() //点击下载
+                    document.body.removeChild(downloadElement) //下载完成移除元素
+                    window.URL.revokeObjectURL(href) //释放掉blob对象
+                })
+            },
+            tableChange(data){
+                console.log(data)
+            },
+            //获取echart的值
+            initEchart(idName, optionName) {
+                const chart = this.$refs[idName]
+                //   console.log(chart)
+                if (chart) {
+                    const myChart = echarts.init(document.getElementById(idName))
+                    // myChart.showLoading({
+                    //     text: "图表数据正在努力加载..."
+                    // });
+                    
+                    myChart.setOption(optionName)
+                    window.addEventListener('resize', function() {
+                    myChart.resize()
+                    })
+                }
+            },
+            handlerEchartOption(data){
+                
+                var option ={
+                    // title: {
+                    //     text: '折线图堆叠'
+                    // },
+                    tooltip: {
+                        trigger: 'axis'
+                    },
+                    // legend: {
+                    //     data: ['邮件营销', '联盟广告', ]
+                    // },
+                    grid: {
+                        left: '3%',
+                        right: '4%',
+                        bottom: '3%',
+                        containLabel: true
+                    },
+                    legend: {
+                        icon: 'circle',
+                        top: '5%',
+                        right: '5%',
+                        itemWidth: 6,
+                        itemGap: 20,
+                        textStyle: {
+                            color: '#556677'
+                        }
+                    },
+                    toolbox: {
+                        // feature: {
+                        //     saveAsImage: {}
+                        // }
+                    },
+                    xAxis: {
+                        type: 'category',
+                        data: ['1','2','3','4','5','6','7'],
+                        boundaryGap: false,
+                        // 坐标轴线
+                        axisLine: {
+                            show: false,
+                            lineStyle: {
+                            color: '#999'
+                            }
+                        },
+                        // 分割线
+                        splitLine: {
+                            show: true,
+                            lineStyle: {
+                            type: 'dashed',
+                            color: '#e5e5e5'
+                            }
+                        }
+                    },
+                    yAxis: {
+                        type: 'value',
+                        axisLine: {
+                            show: false,
+                            lineStyle: {
+                                color: '#999'
+                            }
+                        },
+                        splitLine: {
+                            lineStyle: {
+                                type: 'dashed',
+                                color: '#e5e5e5'
+                            }
+                        }
+                    },
+                    series: [
+                        {
+                            name: '邮件营销',
+                            type: 'line',
+                            stack: '总量',
+                            data: [120, 132, 101, 134, 90, 230, 210],
+                            symbol: 'circle',
+                            symbolSize: 1,
+                            lineStyle: {
+                            normal: {
+                                width: 2,
+                                // color: '#0bcd74'
+                            }
+                            },
+                            itemStyle: {
+                                borderColor: '#ffffff',
+                                borderWidth: 0
+                            },
+                        },
+                        {
+                            name: '联盟广告',
+                            type: 'line',
+                            stack: '总量',
+                            data: [220, 182, 191, 234, 290, 330, 310],
+                            symbol: 'circle',
+                            symbolSize: 1,
+                            lineStyle: {
+                                normal: {
+                                    width: 2,
+                                    // color: '#0bcd74'
+                                }
+                            },
+                            itemStyle: {
+                                borderColor: '#ffffff',
+                                borderWidth: 3
+                            },
+                        },
+                        
+                    ]
+                }
+
+                return option
+            },
+            disabledDate(current) {
+                return current && current > moment().endOf('day');
+            },
+            dataDimensionChange(e){
+                console.log(`checked = ${e.target.value}`);
+            },
+            
+        },
+        mounted() {
+            this.$nextTick(()=>{
+                this.initEchart('echart',this.handlerEchartOption([]))
+            })
+        },
+    }
+</script>
+
+<style lang="scss" scoped>
+.materialReport{
+    .option{
+        background: white;
+        padding: 20px;
+        display: flex;
+        justify-content: flex-start;
+        flex-wrap :wrap;
+        .item{
+            margin-right: 15px;
+            margin-bottom: 15px;
+            height: 32px;
+            line-height: 32px;
+            flex-shrink: 0;
+            span{
+                margin-right:10px;
+            }
+        }
+        
+    }
+    .echart{
+        margin-top: 20px;
+        padding:0 20px 20px;
+        background: white;
+        .echart-header{
+            padding:20px 0;
+            font-size: 15px;
+            font-weight: 600;
+        }
+    }
+    .tableBody{
+        margin-top: 20px;
+    }
+}
+</style>
+<style>
+    .card-container {
+        
+        overflow: hidden;
+        /* padding: 24px; */
+    }
+    .card-container > .ant-tabs-card > .ant-tabs-content {
+        /* height: 120px; */
+        margin-top: -16px;
+    }
+
+    .card-container > .ant-tabs-card > .ant-tabs-content > .ant-tabs-tabpane {
+        background: #fff ;
+        /* padding: 16px; */
+    }
+
+    .card-container > .ant-tabs-card > .ant-tabs-bar {
+        border-color: #fff;
+    }
+
+    .card-container > .ant-tabs-card > .ant-tabs-bar .ant-tabs-tab {
+        border-color: transparent;
+        background: transparent !important;
+    }
+
+    .card-container > .ant-tabs-card > .ant-tabs-bar .ant-tabs-tab-active {
+        border-color: #fff;
+        background: #fff !important;
+    }
+</style>

+ 2 - 2
src/views/modules/Statistics/newPlanStatic/newPlanStatic.vue

@@ -766,7 +766,7 @@ export default {
       SHOW_PARENT,
 
       type:3,
-      dateValue:[moment().subtract(7,'days'), moment()],
+      dateValue:[moment().subtract(7, 'days'), moment().subtract(1, 'days')],
 
       operate:'',
       operateList:[],
@@ -927,7 +927,7 @@ export default {
     tabChange(key){
       console.log(key);
       this.treeValue=[];
-      this.operate=''
+      this.operate=undefined;
       if(key==1){
         // toutiao
         this.treeData=this.TTaccountList;

+ 2 - 2
src/views/modules/Statistics/popularVideo.vue

@@ -170,7 +170,7 @@
   <div class="newPlanStatic">
     <div class="tabbody">
       <a-tabs v-model="tabKey" @change="tabChange">
-        <a-tab-pane :key="1" tab="头条">        
+        <a-tab-pane :key="1" tab="头条外广">        
         </a-tab-pane>
         <a-tab-pane :key="2" tab="快手">       
         </a-tab-pane>
@@ -270,7 +270,7 @@
     <a-row style="margin-bottom:15px;margin-top:12px">
       <a-col :span="24">
         <div class="tableBody">
-          <a-button  type='primary' class="export" style="margin-bottom:20px" @click="exportExcel" :loading="exportloading">导出报表</a-button>
+          <!-- <a-button  type='primary' class="export" style="margin-bottom:20px" @click="exportExcel" :loading="exportloading">导出报表</a-button> -->
           <a-table :columns="columns" :dataSource="dataTable" :pagination="ipagination" :loading="loading" bordered @change="tableChange">  
                 <span slot="createImg" slot-scope="text,record">  
                     <a-popover placement="right">

+ 5 - 1
src/views/modules/advertiser/ProjectList.vue

@@ -133,7 +133,7 @@
           <!-- {{ text | ocpxActionType }} -->
         </span>
         <span slot="bidType" slot-scope="text">
-          <div v-if="text&&JSON.parse(text).length>0">
+          <div v-if="text && JSON.parse(text).length > 0">
             <span v-for="(item, index) of JSON.parse(text)" :key="index"
               >{{ item | bidType }}{{ index == JSON.parse(text).length - 1 ? '' : ',' }}</span
             >
@@ -297,6 +297,10 @@ export default {
         383: '授信',
         384: '完件',
         394: '订单提交',
+        324: '唤起应用',
+        715: '微信复制优化目标',
+        716: '多转化事件',
+        396:'注册优化目标'
       }
       return data[sta]
     },

+ 8 - 1
src/views/modules/advertiser/modules/projectListModal.vue

@@ -95,6 +95,10 @@
               "
             >
               <a-select v-model="model.ocpxActionType" mode="multiple">
+
+
+
+                
                 <a-select-option :value="2">行为数</a-select-option>
                 <a-select-option :value="180">激活</a-select-option>
                 <a-select-option :value="53">表单提交</a-select-option>
@@ -107,7 +111,10 @@
                 <a-select-option :value="191">首日ROI</a-select-option>
                 <a-select-option :value="396">注册优化目标</a-select-option>
                 <a-select-option :value="717">广告观看事件</a-select-option>
-                <a-select-option :value="700">唤起应用</a-select-option>
+                <a-select-option :value="324">唤起应用</a-select-option>
+
+                 <a-select-option :value="715">微信复制优化目标</a-select-option>
+                 <a-select-option :value="716">多转化事件</a-select-option>
               </a-select>
             </a-form-item>
           </div>

+ 0 - 0
src/views/modules/autoLaunch/configLaunchInfo.vue


Diff do ficheiro suprimidas por serem muito extensas
+ 1083 - 0
src/views/modules/autoLaunch/configLaunchList.vue


+ 1 - 2
src/views/modules/autoLaunch/index.vue

@@ -23,8 +23,7 @@ export default {
     },
     components:{   
         createStrategy: () => import('./createStrategy'), 
-        setDirectional: () => import('./setDirectional'), 
-        setCreate: () => import('./setCreate'), 
+        setDirectional: () => import('./setDirectional'),  
         previewStrategy: () => import('./previewStrategy'), 
         
     },

+ 7 - 9
src/views/modules/autoLaunch/setDirectional.vue

@@ -1507,17 +1507,15 @@ export default {
                     postAction('/kuaishouStrategy/add',params).then(res=>{
                         console.log(res)
                         this.goNextloading=false
-                        if(res.success){
-                            
-                            // this.$parent.strategyInfo={}
-                            // this.$router.replace('/autoLaunch/autoLaunchList')
-                            // this.$bus.$emit('remove', '/autoLaunch/newStrategy')
-                            
+                        if(res.success){                            
+                            this.$parent.strategyInfo={}
+                            this.$router.replace('/autoLaunch/autoLaunchList')
+                            this.$bus.$emit('remove', '/autoLaunch/newStrategy')                            
                         }else{
                             this.$messgae.error(res.message)
-                            // this.$parent.strategyInfo={}
-                            // this.$router.replace('/autoLaunch/autoLaunchList')
-                            // this.$bus.$emit('remove', '/autoLaunch/newStrategy')
+                            this.$parent.strategyInfo={}
+                            this.$router.replace('/autoLaunch/autoLaunchList')
+                            this.$bus.$emit('remove', '/autoLaunch/newStrategy')
                         }
                     })
 

+ 1 - 1
src/views/modules/autoRules/newBlankRule.vue

@@ -915,7 +915,7 @@ export default {
         },
 
         goBack() {
-            this.$router.replace('/autoRules')
+            this.$router.push('/autoRules')
             this.$bus.$emit('remove', '/newBlankRule')
            
         },

+ 2 - 2
src/views/modules/earlyWarningRules/configRules.vue

@@ -221,10 +221,10 @@
                                                         </div>
 
 
-                                                        <div class="rules-list-item-subject" v-if="ele.dataType=='number'">
+                                                        <!-- <div class="rules-list-item-subject" v-if="ele.dataType=='number'">
                                                             <a-input-number :min="0" style="width:100%" :max="9999999.99" :step="1" v-model="ele.threshold" placeholder="请输入" :disabled="!!ele.ruleId" />
                                                             <span style="margin-left:8px;line-height:32px">{{ele.dataUnit }}</span>
-                                                        </div>
+                                                        </div> -->
                                                         <div class="rules-list-item-subject" >
                                                             <a-form-model-item ref="isUnlimited"  prop="isUnlimited">
                                                                 <a-select   v-model="ele.isUnlimited" placeholder="是否必填" :disabled="!!ele.ruleId">

+ 249 - 0
src/views/modules/earlyWarningRules/historyWarning.vue

@@ -0,0 +1,249 @@
+<template>
+  <a-card :bordered="false" title="预警管理">
+    <!-- 查询区域 -->
+    <div class="table-page-search-wrapper">
+      <a-form layout="inline">
+        <a-row :gutter="24">
+          <a-col :md="6" :sm="8">
+            <a-form-item label="媒体">
+              <a-radio-group v-model="mediaType">
+                <a-radio-button value=""> 全部 </a-radio-button>
+                <a-radio-button value="快手"> 快手 </a-radio-button>
+                <a-radio-button value="头条"> 头条 </a-radio-button>
+              </a-radio-group>
+            </a-form-item>
+          </a-col>
+          <a-col :md="6" :sm="8">
+            <a-form-item label="运营名称">
+              <a-input placeholder="请输入运营名称" v-model="userId"></a-input>
+            </a-form-item>
+          </a-col>
+          <template>
+            <a-col :md="6" :sm="8">
+              <a-form-item label="账户ID">
+                <Treeselect :appId.sync="accountId" :multiple="false" ref="treeSelect" style="width: 100%" />
+              </a-form-item>
+            </a-col>
+          </template>
+          <a-col :md="6" :sm="8">
+            <span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
+              <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
+              <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
+            </span>
+          </a-col>
+        </a-row>
+      </a-form>
+    </div>
+
+    <!-- 操作按钮区域 -->
+    <!-- <div class="table-operator">
+      <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
+    </div>-->
+
+    <!-- table区域-begin -->
+    <!-- 供应商 -->
+    <div>
+      <a-table
+        ref="table"
+        size="middle"
+        bordered
+        rowKey="id"
+        :columns="columns"
+        :dataSource="dataSource"
+        :pagination="ipagination"
+        :loading="loading"
+        style="word-break: break-all"
+      >
+        <span slot="userId" slot-scope="text">{{ text.split('_')[0] }}</span>
+        <div slot="alarmDetail" slot-scope="text" style="text-align: left; width: 100%; padding: 0 10px">
+          {{ text }}
+        </div>
+      </a-table>
+    </div>
+  </a-card>
+</template>
+
+<script>
+import JTreeSelect from '@/components/jeecg/JTreeSelect'
+import { httpAction, getAction } from '@/api/manage'
+import Treeselect from './pushTreeSelect.vue'
+export default {
+  name: 'ProjectList',
+  components: {
+    JTreeSelect,
+    Treeselect,
+  },
+  data() {
+    return {
+      dataSource: [],
+      mediaType: '',
+      userId: '',
+      accountId: '',
+      description: '项目管理页面',
+      // 表头
+      columns: [
+        {
+          title: '媒体',
+          align: 'center',
+          dataIndex: 'mediaType',
+          width: 100,
+        },
+        {
+          title: '账户ID',
+          align: 'center',
+          dataIndex: 'accountId',
+          width: 200,
+        },
+        {
+          title: '运营',
+          align: 'center',
+          dataIndex: 'userId',
+          scopedSlots: {
+            customRender: 'userId',
+          },
+          width: 100,
+        },
+        {
+          title: '预警字段',
+          align: 'center',
+          dataIndex: 'groupName',
+          scopedSlots: {
+            customRender: 'groupName',
+          },
+          width: 100,
+        },
+        {
+          title: '预警时间',
+          align: 'center',
+          dataIndex: 'createTime',
+          scopedSlots: {
+            customRender: 'createTime',
+          },
+          width: 200,
+        },
+        {
+          title: '预警信息',
+          align: 'center',
+          dataIndex: 'alarmDetail',
+          scopedSlots: {
+            customRender: 'alarmDetail',
+          },
+        },
+      ],
+      list: [],
+      options: [],
+      loading: false,
+      ipagination: {
+        current: 1,
+        pageSize: 10,
+        //   pageSizeOptions: ['10', '20', '30'],
+        showTotal: (total, range) => {
+          return range[0] + '-' + range[1] + ' 共' + total + '条'
+        },
+        showQuickJumper: true,
+        //   showSizeChanger: true,
+        total: 0,
+        onChange: (current) => {
+          // 切换分页时的回调,
+          // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
+          this.ipagination.current = current
+        },
+      },
+    }
+  },
+  computed: {
+    importExcelUrl: function () {
+      return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`
+    },
+  },
+  watch: {
+    'ipagination.current': function (n, o) {
+      if (n != o) {
+        this.getHistoryList()
+      }
+    },
+  },
+  methods: {
+    searchQuery() {
+      this.ipagination.current = 1
+      this.getHistoryList()
+    },
+    searchReset() {
+      this.mediaType = ''
+      this.userId = ''
+      this.accountId = ''
+      this.ipagination.current = 1
+      this.getHistoryList()
+    },
+    getHistoryList() {
+      this.loading = true
+      var params = {}
+      params.mediaType = this.mediaType
+      params.userId = this.userId
+      params.accountId = this.accountId
+      params.pageNo = this.ipagination.current
+      params.pageSize = this.ipagination.pageSize
+
+      getAction('/alarm/alarmEventSend/pageList', params).then((res) => {
+        this.loading = false
+        if (res.success) {
+          this.dataSource = res.result.list.map((item, index) => {
+            return { ...item, key: index }
+          })
+          this.ipagination.total = res.result.total
+        } else {
+          this.$message.error(res.message)
+        }
+      })
+    },
+    getList() {
+      var params = {}
+      // params.userId = this.userInfo().id
+      params.pageSize = 1000
+      params.pageNo = 1
+      getAction('/ctop/advertiser/list', params)
+        .then((res) => {
+          if (res.success) {
+            this.list = res.result.records
+          } else {
+            this.$message.warning(res.message)
+          }
+        })
+        .finally(() => {})
+    },
+    filterOption(input, option) {
+      return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+    },
+    getAllUserList(value) {
+      this.options = []
+      getAction('/sys/user/getAllUserList', { pageSize: 50, pageNo: 1, userName: value }).then((res) => {
+        if (res.success) {
+          this.options = res.result.list
+        }
+      })
+    },
+    search(value) {
+      this.options = []
+      if (value != '') {
+        // this.options = this.list.filter(item => {
+        //   var data = item.realName + ' ' + item.roleName
+        //   return data.toLowerCase().indexOf(value.toLowerCase()) > -1
+        // })
+        // this.options = [...this.options]
+        this.getAllUserList(value)
+      } else {
+        this.getAllUserList()
+      }
+    },
+  },
+  created() {},
+  mounted() {
+    this.getHistoryList()
+    // this.getAllUserList()
+    // this.getList()
+  },
+}
+</script>
+<style scoped>
+@import '~@assets/less/common.less';
+</style>

+ 2 - 2
src/views/modules/earlyWarningRules/index.vue

@@ -9,8 +9,8 @@
                 <a-input v-model="templateName" placeholder="模板名字" style="width:250px;margin-right:40px"/>
             </div>
             <div>
-                <span>模板id:</span>
-                <a-input v-model="templateId" placeholder="模板id" style="width:250px"/>
+                <span>模板ID:</span>
+                <a-input v-model="templateId" placeholder="模板ID" style="width:250px"/>
             </div>
             
 

+ 28 - 20
src/views/modules/earlyWarningRules/ruleModule.vue

@@ -60,6 +60,9 @@
                         trigger: value.dataType == 'array' ? 'change' : 'blur',
                       }"
                     >
+                      <span style="color: red;font-size:16px;font-weight:500" v-if="value.modelType == 'numberText'">
+                        {{ value.ruleCondition | conditionName }}
+                      </span>
                       <a-input-number
                         :disabled="!editShow"
                         v-model="value.threshold"
@@ -189,6 +192,10 @@
                                     }"
                                     v-if="value.modelType == 'numberText'"
                                   >
+                                    <span style="color: red;font-size:16px;font-weight:500">
+                                      {{ value.ruleCondition | conditionName }}
+                                    </span>
+
                                     <a-input-number
                                       :disabled="!editShow"
                                       style="width: 100px; margin-right: 5px"
@@ -331,6 +338,9 @@
                                     }"
                                     v-if="value.modelType == 'numberText'"
                                   >
+                                    <span style="color: red;font-size:16px;font-weight:500">
+                                      {{ value.ruleCondition | conditionName }}
+                                    </span>
                                     <a-input-number
                                       :disabled="!editShow"
                                       style="width: 100px; margin-right: 5px"
@@ -359,7 +369,12 @@
                                     }"
                                     v-else-if="value.modelType == 'text'"
                                   >
-                                    <a-input :disabled="!editShow" v-model="value.threshold" style="width: 95%"  @change='inputChange'/>
+                                    <a-input
+                                      :disabled="!editShow"
+                                      v-model="value.threshold"
+                                      style="width: 95%"
+                                      @change="inputChange"
+                                    />
                                   </a-form-model-item>
                                   <a-form-model-item
                                     :label-col="{ span: 6 }"
@@ -784,11 +799,9 @@ export default {
     },
   },
   methods: {
-    inputChange(value){
-      
-      
-      value.threshold=value.threshold.trim()
-      console.log(value);
+    inputChange(value) {
+      value.threshold = value.threshold.trim()
+      console.log(value)
     },
     addData(valueElse, value, index) {
       // alert(1)
@@ -808,7 +821,7 @@ export default {
     disabledDate(current) {
       return current && current < moment().subtract(1, 'days')
     },
-    
+
     // 获取计划列表
     getCampaignList() {
       getAction('/kuaishou/batch/getCampaignList', {
@@ -870,8 +883,6 @@ export default {
       }
     },
 
-    
-
     filterOption(input, option) {
       return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
     },
@@ -890,13 +901,10 @@ export default {
     resetForm() {
       this.$refs.ruleForm.resetFields()
     },
-   
+
     displayRender({ labels }) {
       return labels[labels.length - 1]
     },
-    
-
-    
 
     saveHandler() {
       this.$refs.ruleForm.validate((valid) => {
@@ -927,19 +935,19 @@ export default {
                   return {
                     ...end,
                     threshold: isArray(end.threshold)
-                      ? end.dataType != 'array'
+                      ? end.dataType == 'array'
                         ? end.modelType == 'region'
                           ? JSON.stringify(
                               end.threshold.map((c) => {
                                 return c.value
                               })
                             )
-                          : end.threshold[0]
-                        : end.modelType == 'scheduleTime'
-                        ? end.threshold == str
-                          ? ''
-                          : end.threshold
-                        : JSON.stringify(end.threshold)
+                          : JSON.stringify(end.threshold)
+                        : end.threshold[0]
+                      : end.modelType == 'scheduleTime'
+                      ? end.threshold == str
+                        ? ''
+                        : end.threshold
                       : end.threshold,
                   }
                 }

+ 96 - 33
src/views/modules/earlyWarningRules/useRuleList.vue

@@ -8,7 +8,8 @@
     <div class="tabBody">
       <a-tabs v-model="tabKey" @change="tabChange">
         <a-tab-pane key="1" tab="模板列表"></a-tab-pane>
-        <a-tab-pane key="2" tab="我的模板"></a-tab-pane>
+        <a-tab-pane key="2" tab="我的模板"> </a-tab-pane>
+        <a-button slot="tabBarExtraContent" type="link" @click="toHistory"> 预警历史 </a-button>
       </a-tabs>
     </div>
     <div class="tableBody">
@@ -25,6 +26,29 @@
           @search="onSearch"
         />
       </div> -->
+      <div class="table-page-search-wrapper" v-if="tabKey == '2'">
+        <a-form layout="inline">
+          <a-row :gutter="24">
+            <a-col :md="6" :sm="8">
+              <a-form-item label="账户名称">
+                <Treeselect :appId.sync="projectId" :multiple="false" ref="treeSelect" style="width: 100%" />
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="8">
+              <a-form-item label="绑定人">
+                <a-input placeholder="请输入绑定的运营" v-model="userName"></a-input>
+              </a-form-item>
+            </a-col>
+
+            <a-col :md="6" :sm="8">
+              <span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
+                <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
+                <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
+              </span>
+            </a-col>
+          </a-row>
+        </a-form>
+      </div>
       <div class="table">
         <a-table
           size="middle"
@@ -49,9 +73,9 @@
             {{ text | handleMediaType }}
           </span>
           <span slot="accountStatus" slot-scope="text">
-              <span class="bohui" v-if="text==1"></span>
-              <span class="shenhe" v-if="text==0"></span>
-              {{text?'暂停':'投放中'}}
+            <span class="bohui" v-if="text == 1"></span>
+            <span class="shenhe" v-if="text == 0"></span>
+            {{ text ? '暂停' : '投放中' }}
           </span>
           <span slot="processMethod" slot-scope="text">
             {{ text == 'SEND' ? '仅发送通知' : '发送并关停组' }}
@@ -72,7 +96,14 @@
       </div>
     </div>
     <!-- pushRuleVisible -->
-    <a-modal v-model="pushRuleVisible" title="推送账户选择" @ok="handleOk" @cancel='cancelPush' :confirmLoading="confirmLoading" width="60%">
+    <a-modal
+      v-model="pushRuleVisible"
+      title="推送账户选择"
+      @ok="handleOk"
+      @cancel="cancelPush"
+      :confirmLoading="confirmLoading"
+      width="60%"
+    >
       <a-form layout="inline" class="rule-tree-select">
         <a-form-item
           label="请选择账户"
@@ -89,7 +120,7 @@
 <script>
 import moment from 'moment'
 import Treeselect from './pushTreeSelect.vue'
-import { getAction, postAction, downFile, downFilePost, deleteAction , putAction } from '@/api/manage'
+import { getAction, postAction, downFile, downFilePost, deleteAction, putAction } from '@/api/manage'
 let existColumns = [
   // {
   //     title: '运行/暂停',
@@ -134,14 +165,13 @@ let existColumns = [
 ]
 
 let recordsColumns = [
-
-    {
-      title: '运行/暂停',
-      dataIndex: 'status',
-      align: 'center',
-      width:100,
-      key: 'status',
-      scopedSlots: { customRender: 'status' }
+  {
+    title: '运行/暂停',
+    dataIndex: 'status',
+    align: 'center',
+    width: 100,
+    key: 'status',
+    scopedSlots: { customRender: 'status' },
   },
   {
     title: '模板名称',
@@ -201,6 +231,8 @@ export default {
   name: 'useRuleList',
   data() {
     return {
+      projectId: '',
+      userName: '',
       relationCount: 2,
       pushRuleVisible: false,
       confirmLoading: false,
@@ -251,12 +283,44 @@ export default {
     Treeselect,
   },
   methods: {
+    toHistory() {
+      this.$router.replace({ path: '/earlyWarningRules/historyWarning' })
+    },
+
+    searchQuery() {
+      this.ipagination.current = 1
+      let url = ''
+      if (this.tabKey == '1') {
+        this.columns = [...existColumns]
+        url = '/ruleTemplate/list'
+      } else {
+        this.columns = [...recordsColumns]
+        url = '/ruleAccountTemplate/getTemplateApplied'
+      }
+      this.getTableListHttp(url)
+    },
+    searchReset() {
+      this.ipagination.current = 1
+      this.projectId = ''
+      this.userName = ''
+      let url = ''
+      if (this.tabKey == '1') {
+        this.columns = [...existColumns]
+        url = '/ruleTemplate/list'
+      } else {
+        this.columns = [...recordsColumns]
+        url = '/ruleAccountTemplate/getTemplateApplied'
+      }
+      this.getTableListHttp(url)
+    },
     moment,
     onSearch(value) {
       console.log(value)
     },
     tabChange(key) {
       console.log(key)
+      this.projectId = ''
+      this.userName = ''
       this.ipagination.current = 1
       let url = ''
       if (key == '1') {
@@ -298,8 +362,7 @@ export default {
     },
 
     handleOk() {
-      
-      if(this.accountId){
+      if (this.accountId) {
         this.confirmLoading = true
         getAction('/ruleAccountTemplate/checkAccountTemplate', { accountId: this.accountId }).then((res) => {
           console.log(res)
@@ -309,16 +372,15 @@ export default {
                 templateId: this.templateId,
                 accountId: this.accountId,
               }).then((r) => {
-                if(r.success){
+                if (r.success) {
                   var data = { id: this.templateId, edit: true, accountId: this.accountId }
                   localStorage.setItem('getRuleDetail', JSON.stringify(data))
                   this.$router.push('/earlyWarningRules/ruleModule')
                   this.confirmLoading = false
-                  this.accountId=undefined
-                }else{
+                  this.accountId = undefined
+                } else {
                   this.$message.error(r.message)
                 }
-                
               })
             } else {
               // this.accountId = ''
@@ -331,15 +393,12 @@ export default {
             this.confirmLoading = false
           }
         })
-      }else{
+      } else {
         this.$message.error('请选择需要推送的账户')
       }
-      
     },
-    cancelPush(){
-      
-      this.accountId=''
-      
+    cancelPush() {
+      this.accountId = ''
     },
     // recordsRule(record){
     //     console.log(record);
@@ -388,7 +447,7 @@ export default {
     },
     switchChange(text, record) {
       console.log(text, record)
-      if(record.accountStatus==0 || record.accountStatus==1&&text){
+      if (record.accountStatus == 0 || (record.accountStatus == 1 && text)) {
         record.spin = true
         let templateStatus = 0
         if (text) {
@@ -419,19 +478,24 @@ export default {
             // this.getTableListHttp()
           }
         })
-      }else{        
-          this.$message.error('当前账户已关停,预警规则不支持开启!')
+      } else {
+        this.$message.error('当前账户已关停,预警规则不支持开启!')
       }
-      
     },
 
     getTableListHttp(url) {
       this.data = []
       this.loading = true
       // let url='/alarm/alarmEventRule/list'
+      var params = {}
+      if (this.tabKey == '2') {
+        params.accountId = this.projectId
+        params.userName = this.userName
+      }
       getAction(url, {
         pageNo: this.ipagination.current,
         pageSize: this.ipagination.pageSize,
+        ...params,
       }).then((res) => {
         console.log(res)
         this.loading = false
@@ -519,7 +583,7 @@ export default {
       margin-bottom: 15px;
     }
 
-    .shenhe{
+    .shenhe {
       width: 6px;
       height: 6px;
       display: inline-block;
@@ -528,7 +592,7 @@ export default {
       position: relative;
       top: -2px;
     }
-    .bohui{
+    .bohui {
       width: 6px;
       height: 6px;
       display: inline-block;
@@ -538,6 +602,5 @@ export default {
       top: -2px;
     }
   }
-
 }
 </style>

+ 2 - 0
src/views/modules/kuaishouapp/account/accountIndex.vue

@@ -978,6 +978,7 @@ export default {
       this.searchLabel()
     },
     addUser() {
+      
       this.loading = true
       this.dataList = []
       var params = {}
@@ -987,6 +988,7 @@ export default {
       if (this.appId) {
         this.getSpend(params)
         this.getCampaignList(params)
+        localStorage.setItem('accountId',this.appId)
       } else {
         this.$message.error('请选择账户')
       }

+ 28 - 17
src/views/modules/kuaishouapp/account/copyAllUnit.vue

@@ -31,6 +31,16 @@
   <a-card :body-style="{ padding: '24px 32px' }" :bordered="false" class="group-creat">
     <a-form @submit="handleSubmit" :form="form">
       <a-form-item
+        label="投放范围"
+        :labelCol="{ lg: { span: 7 }, sm: { span: 7 } }"
+        :wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
+      >
+        <a-radio-group buttonStyle="solid" v-model="allForm.allianceAccount">
+          <a-radio-button value="1">默认</a-radio-button>
+          <a-radio-button value="2">联盟广告</a-radio-button>
+        </a-radio-group>
+      </a-form-item>
+      <a-form-item
         label="选择模板"
         :labelCol="{ lg: { span: 7 }, sm: { span: 7 } }"
         :wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
@@ -152,6 +162,7 @@
         label="场景广告位"
         :labelCol="{ lg: { span: 7 }, sm: { span: 7 } }"
         :wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
+        v-if="allForm.allianceAccount == '1'"
       >
         <checkBoxGroup
           :options="[
@@ -660,22 +671,22 @@ export default {
         }
       })
 
-      //   getAction('/kuaishou/batch/getWhiteList', {
-      //     accountId: item.accountId,
-      //   }).then((res) => {
-      //     if (res.success) {
-      //       // console.log(res)
-      //       if (res.result) {
-      //         this.creativeCategorySwitch = res.result.creative_category_switch == 1 ? true : false
-      //         this.allianceAccount = res.result.alliance_account == 1 ? true : false
-      //         this.actionbarClickUrlSwitch = res.result.actionbar_click_url_switch == 1 ? true : false
-      //       } else {
-      //         this.allianceAccount = false
-      //         this.creativeCategorySwitch = false
-      //         this.actionbarClickUrlSwitch = false
-      //       }
-      //     }
-      //   })
+        getAction('/kuaishou/batch/getWhiteList', {
+          accountId: item.accountId,
+        }).then((res) => {
+          if (res.success) {
+            // console.log(res)
+            if (res.result) {
+              // this.creativeCategorySwitch = res.result.creative_category_switch == 1 ? true : false
+              this.allianceAccount = res.result.alliance_account == 1 ? true : false
+              // this.actionbarClickUrlSwitch = res.result.actionbar_click_url_switch == 1 ? true : false
+            } else {
+              this.allianceAccount = false
+              // this.creativeCategorySwitch = false
+              // this.actionbarClickUrlSwitch = false
+            }
+          }
+        })
       getAction('/kuaishou/batch/getProjectMaxBid', {
         accountId: item.accountId,
       }).then((res) => {
@@ -976,7 +987,7 @@ export default {
           }
           postAction('/kuaishouCampaignCopyData/add', params).then((res) => {
             if (res.success) {
-                this.$emit('getUnitData')
+              this.$emit('getUnitData')
             } else {
               this.$message.error(res.message)
             }

+ 5 - 4
src/views/modules/kuaishouapp/account/stepForm/Step2.vue

@@ -941,10 +941,7 @@
             }
             postAction('/kuaishou/batch/createUnit', paramsEnd).then(res => {
               if (res.success) {
-                this.visible = true
-                this.allForm.fail = res.result.fail
-                this.allForm.success = res.result.success
-                this.loading = false
+               
                 if (res.result.success.length > 0) {
 
                   var dataElse =  res.result.success.map(item => {
@@ -959,6 +956,10 @@
                   var dataJson = JSON.stringify(dataElse)
                   localStorage.setItem('pans', dataJson)
                   localStorage.setItem('appId', this.getData('appId'))
+                  this.visible = true
+                  this.allForm.fail = res.result.fail
+                  this.allForm.success = res.result.success
+                  this.loading = false
                 }
               } else {
                 this.loading = false

+ 47 - 31
src/views/modules/kuaishouapp/account/stepForm/stepModule/targetedPopulation.vue

@@ -171,7 +171,7 @@ li:hover {
         <a-radio-button value="ageLimit">限定年龄段</a-radio-button>
         <a-radio-button value="ageCustom">自定义年龄段</a-radio-button>
       </a-radio-group>
-      <div v-if="allForm.ageType == 'ageLimit'" style="margin-top:5px">
+      <div v-if="allForm.ageType == 'ageLimit'" style="margin-top: 5px">
         <a-checkbox-group v-decorator="['agesRange', { rules: [{ required: true, message: '请选择年龄段' }] }]">
           <!-- <a-checkbox :value="0">0-11岁</a-checkbox>
           <a-checkbox :value="12">12-17岁</a-checkbox> -->
@@ -211,7 +211,6 @@ li:hover {
             initialValue: 0,
           },
         ]"
-        
       >
         <a-radio-button :value="0">不限</a-radio-button>
         <a-radio-button :value="1">女性</a-radio-button>
@@ -235,7 +234,7 @@ li:hover {
       :wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
       v-if="allForm.platform_os == 1"
       class="else-label"
-      style="margin-top:-16px"
+      style="margin-top: -16px"
     >
       <a-radio-group
         v-decorator="[
@@ -258,7 +257,7 @@ li:hover {
       :wrapperCol="{ lg: { span: 10 }, sm: { span: 17 } }"
       v-if="allForm.platform_os == 2"
       class="else-label"
-      style="margin-top:-16px"
+      style="margin-top: -16px"
     >
       <a-radio-group
         v-decorator="[
@@ -285,22 +284,22 @@ li:hover {
         <a-radio-button value="0">不限</a-radio-button>
         <a-radio-button value="1">选择品牌</a-radio-button>
       </a-radio-group>
-      <div v-if="allForm.device == '1'" style="width: 120%;margin-top:15px">
+      <div v-if="allForm.device == '1'" style="width: 120%; margin-top: 15px">
         <a-checkbox-group
           v-decorator="['deviceBrand', { rules: [{ required: true, message: '请选择设备品牌' }] }]"
           style="width: 120%"
         >
-          <a-checkbox :value="1" style='margin-bottom:8px'>OPPO</a-checkbox>
-          <a-checkbox :value="2" style='margin-bottom:8px'>VIVO</a-checkbox>
-          <a-checkbox :value="3" style='margin-bottom:8px'>华为</a-checkbox>
-          <a-checkbox :value="4" style='margin-bottom:8px'>小米</a-checkbox>
-          <a-checkbox :value="5" style='margin-bottom:8px'>荣耀</a-checkbox>
-          <a-checkbox :value="6" style='margin-bottom:8px'>三星</a-checkbox>
-          <a-checkbox :value="7" style='margin-bottom:8px'>金立</a-checkbox>
-          <a-checkbox :value="8" style="margin:0 0 8px 0">魅族</a-checkbox>
-          <a-checkbox :value="9" style='margin-bottom:8px'>乐视</a-checkbox>
-          <a-checkbox :value="10" style='margin-bottom:8px'>其他</a-checkbox>
-          <a-checkbox :value="11" v-if="allForm.platform_os == 0" style='margin-bottom:8px'>苹果</a-checkbox>
+          <a-checkbox :value="1" style="margin-bottom: 8px">OPPO</a-checkbox>
+          <a-checkbox :value="2" style="margin-bottom: 8px">VIVO</a-checkbox>
+          <a-checkbox :value="3" style="margin-bottom: 8px">华为</a-checkbox>
+          <a-checkbox :value="4" style="margin-bottom: 8px">小米</a-checkbox>
+          <a-checkbox :value="5" style="margin-bottom: 8px">荣耀</a-checkbox>
+          <a-checkbox :value="6" style="margin-bottom: 8px">三星</a-checkbox>
+          <a-checkbox :value="7" style="margin-bottom: 8px">金立</a-checkbox>
+          <a-checkbox :value="8" style="margin: 0 0 8px 0">魅族</a-checkbox>
+          <a-checkbox :value="9" style="margin-bottom: 8px">乐视</a-checkbox>
+          <a-checkbox :value="10" style="margin-bottom: 8px">其他</a-checkbox>
+          <a-checkbox :value="11" v-if="allForm.platform_os == 0" style="margin-bottom: 8px">苹果</a-checkbox>
         </a-checkbox-group>
       </div>
     </a-form-item>
@@ -313,21 +312,21 @@ li:hover {
         <a-radio-button value="0">不限</a-radio-button>
         <a-radio-button value="1">选择价格</a-radio-button>
       </a-radio-group>
-      <div v-if="allForm.price == '1'" style="width: 120%;margin-top:10px">
+      <div v-if="allForm.price == '1'" style="width: 120%; margin-top: 10px">
         <a-checkbox-group
           v-decorator="['devicePrice', { rules: [{ required: true, message: '请选择设备价格' }] }]"
           style="width: 120%"
         >
-          <a-checkbox :value="1" style='margin-bottom:8px'>1500以下</a-checkbox>
-          <a-checkbox :value="2" style='margin-bottom:8px'>1501~2000</a-checkbox>
-          <a-checkbox :value="3" style='margin-bottom:8px'>2001~2500</a-checkbox>
-          <a-checkbox :value="4" style='margin-bottom:8px'>2501~3000</a-checkbox>
-          <a-checkbox :value="5" style="margin-left:0;margin-bottom:8px">3001~3500</a-checkbox>
-          <a-checkbox :value="6" style='margin-bottom:8px'>3501~4000</a-checkbox>
-          <a-checkbox :value="7" style='margin-bottom:8px'>4001~4500</a-checkbox>
-          <a-checkbox :value="8" style='margin-bottom:8px'>4501~5000</a-checkbox>
-          <a-checkbox :value="9" style="margin-left:0;margin-bottom:8px">5001~5500</a-checkbox>
-          <a-checkbox :value="10" style='margin-bottom:8px'>5500以上</a-checkbox>
+          <a-checkbox :value="1" style="margin-bottom: 8px">1500以下</a-checkbox>
+          <a-checkbox :value="2" style="margin-bottom: 8px">1501~2000</a-checkbox>
+          <a-checkbox :value="3" style="margin-bottom: 8px">2001~2500</a-checkbox>
+          <a-checkbox :value="4" style="margin-bottom: 8px">2501~3000</a-checkbox>
+          <a-checkbox :value="5" style="margin-left: 0; margin-bottom: 8px">3001~3500</a-checkbox>
+          <a-checkbox :value="6" style="margin-bottom: 8px">3501~4000</a-checkbox>
+          <a-checkbox :value="7" style="margin-bottom: 8px">4001~4500</a-checkbox>
+          <a-checkbox :value="8" style="margin-bottom: 8px">4501~5000</a-checkbox>
+          <a-checkbox :value="9" style="margin-left: 0; margin-bottom: 8px">5001~5500</a-checkbox>
+          <a-checkbox :value="10" style="margin-bottom: 8px">5500以上</a-checkbox>
         </a-checkbox-group>
       </div>
     </a-form-item>
@@ -962,8 +961,14 @@ export default {
   computed: {},
   methods: {
     getPeople() {
+      var data = ''
+      if (this.$route.path == '/creat/creatUnit') {
+        data = localStorage.getItem('campaignAccountId')
+      } else {
+        data = localStorage.getItem('accountId')
+      }
       return new Promise((resolve, reject) => {
-        getAction('/kuaishou/batch/getPopulationList', { accountId: localStorage.getItem('accountId') }).then((res) => {
+        getAction('/kuaishou/batch/getPopulationList', { accountId: data }).then((res) => {
           if (res.success) {
             if (res.result) {
               this.dataList = res.result.map((item, index) => {
@@ -1215,10 +1220,15 @@ export default {
     getAppAllElse(e) {
       this.checkArr = this.optionsAll
       // this.getAppAll()
-
+      var data = ''
+      if (this.$route.path == '/creat/creatUnit') {
+        data = localStorage.getItem('campaignAccountId')
+      } else {
+        data = localStorage.getItem('accountId')
+      }
       if (this.appListValue != '') {
         getAction('/kuaishou/batch/getAppSearch', {
-          accountId: localStorage.getItem('accountId'),
+          accountId: data,
           appName: e.target.value,
         }).then((res) => {
           if (res.result) {
@@ -1236,9 +1246,15 @@ export default {
       }
     },
     getAppAll(e) {
+      var data = ''
+      if (this.$route.path == '/creat/creatUnit') {
+        data = localStorage.getItem('campaignAccountId')
+      } else {
+        data = localStorage.getItem('accountId')
+      }
       if (e.target.value !== '') {
         getAction('/kuaishou/batch/getAppSearch', {
-          accountId: localStorage.getItem('accountId'),
+          accountId: data,
           appName: e.target.value,
         }).then((res) => {
           if (res.result) {

+ 1 - 0
src/views/modules/kuaishouapp/batchCreation/campaignList.vue

@@ -882,6 +882,7 @@ export default {
       if (this.appId) {
         this.getSpend(params)
         this.getCampaignList(params)
+        localStorage.setItem('campaignAccountId',this.appId)
       } else {
         this.$message.error('请选择账户')
       }

+ 2 - 2
src/views/modules/kuaishouapp/batchCreation/creat/creatCampaign.vue

@@ -135,10 +135,10 @@ export default {
               localStorage.setItem('campaignList', res.result)
               localStorage.setItem('campaignType', this.type)
               this.loading = false
-              this.$router.replace({
+              this.$bus.$emit('remove', '/creat/creatCampaign')
+              this.$router.push({
                 path: '/creat/creatUnit',
               })
-              this.$bus.$emit('remove', '/creat/creatCampaign')
             } else {
               this.$message.error(res.message)
               this.loading = false

+ 7 - 1
src/views/modules/kuaishouapp/batchCreation/creat/creatUnit.vue

@@ -790,7 +790,7 @@
       :width="1000"
     >
       <a-tabs type="card" @change="callback" v-model="active" class="check-video">
-        <div slot="tabBarExtraContent">
+        <div slot="tabBarExtraContent"> 
           当前选择数量
           {{ sumContent + '/' + (getData('createType')=='0'?getData('createCount'):getData('createCount')*15) }}
           <a-button  type="primary" @click="tongbu()" :loading="tongbuLoading" style="margin-left:10px">
@@ -1197,12 +1197,17 @@ export default {
       checkVideo: [],
       checkVideoAll: [],
       checkVideoWai: [],
+      checkVideoWhole:[],
       dataSource: [],
       active: 0,
       time: [],
       channelType: 0,
       creativeMaterialType: '',
       tab: [
+        // {
+        //   value: 2,
+        //   label: '全部',
+        // },
         {
           value: 0,
           label: '内部',
@@ -2268,6 +2273,7 @@ export default {
       this.checkVideo = []
       this.checkVideoAll = []
       this.checkVideoWai = []
+
       this.sumContent = 0
     },
     filterOption(input, option) {

+ 3 - 3
src/views/modules/kuaishouapp/crossAccount/templateModal.vue

@@ -109,7 +109,7 @@ export default {
           this.populationData.interestVideo = dataJson.interestVideo ? JSON.parse(dataJson.interestVideo) : null
           this.populationData.deviceBrand = dataJson.deviceBrand ? JSON.parse(dataJson.deviceBrand) : null
 
-          this.populationData.age = dataJson.ageMin ? [dataJson.ageMin, dataJson.ageMax] : []
+          this.populationData.age = dataJson.min ? [dataJson.min, dataJson.max] : []
           this.populationData.agesRange = dataJson.agesRange ? JSON.parse(dataJson.agesRange) : []
           this.populationData.devicePrice = dataJson.devicePrice ? dataJson.devicePrice : null
           this.populationData.allForm = {}
@@ -127,7 +127,7 @@ export default {
           // })
 
           this.populationData.allForm.ageType =
-            dataJson.agesRange.length > 0 ? 'ageLimit' : dataJson.ageMin ? 'ageCustom' : 'noLimit'
+            dataJson.agesRange.length > 0 ? 'ageLimit' : dataJson.min ? 'ageCustom' : 'noLimit'
           this.populationData.allForm.device = dataJson.deviceBrand ? '1' : '0'
           this.populationData.allForm.price = dataJson.devicePrice ? '1' : '0'
           this.populationData.allForm.appType = dataJson.appInterest ? '1' : dataJson.appIds ? '2' : '0'
@@ -141,7 +141,7 @@ export default {
           this.populationData.allForm.noAreaBreak = dataJson.noAreaBreak + ''
           this.populationData.allForm.checkArr =
             this.populationData.allForm.appType == '2' ? JSON.parse(dataJson.appIds) : []
-          this.$nextTick(() => {
+          this.$nextTick(() => { 
             console.log(dataJson)
             this.form.setFieldsValue(pick(dataJson, ['templateName']))
             this.spinning = false

+ 216 - 160
src/views/modules/kuaishouapp/populationAnalysis/index.vue

@@ -1,22 +1,21 @@
 <template>
   <div class="autoLaunchReport">
-    
     <div class="topOptions">
-      <span class="OptinItem" style="position:relative;top:12px;margin-right:20px">
+      <span class="OptinItem" style="position: relative; top: 12px; margin-right: 20px">
         <Treeselect
           :appId.sync="accountIds"
           :multiple="true"
           request="2,4"
           ref="treeSelect"
           style="width: 600px"
-          :limit='1'
+          :limit="1"
         />
       </span>
       <span class="OptinItem">
         <a-range-picker @change="dateChange" v-model="dateRange" :disabled-date="disabledDate" style="width: 300px" />
       </span>
       <span>
-        <a-button type="primary" style="position:absolute;right:10px;top:45px" @click="search">查询</a-button>
+        <a-button type="primary" style="position: absolute; right: 10px; top: 45px" @click="search">查询</a-button>
         <!-- <a-button type='default' @click="reset">重置</a-button> -->
       </span>
     </div>
@@ -270,64 +269,58 @@ const regionColumns = [
   //   },
 ]
 
-const province =[
+const province = [
   {
     title: '省份',
     dataIndex: 'province',
     key: 'province',
     align: 'center',
     scopedSlots: { customRender: 'province' },
-   
   },
 ]
-const city =[
+const city = [
   {
     title: '城市',
     dataIndex: 'city',
     key: 'city',
     align: 'center',
     scopedSlots: { customRender: 'city' },
-    
   },
 ]
-const ageSegment =[
+const ageSegment = [
   {
     title: '年龄',
     dataIndex: 'ageSegment',
     key: 'ageSegment',
     align: 'center',
     scopedSlots: { customRender: 'ageSegment' },
-    
   },
 ]
-const gender =[
+const gender = [
   {
     title: '性别',
     dataIndex: 'gender',
     key: 'gender',
     align: 'center',
     scopedSlots: { customRender: 'gender' },
-   
   },
 ]
-const businessInterestTags =[
+const businessInterestTags = [
   {
     title: '商业兴趣',
     dataIndex: 'businessInterestTags',
     key: 'businessInterestTags',
     align: 'center',
     scopedSlots: { customRender: 'businessInterestTags' },
-    
-  }
+  },
 ]
-const client =[
+const client = [
   {
     title: '系统',
     dataIndex: 'client',
     key: 'client',
     align: 'center',
     scopedSlots: { customRender: 'client' },
-    
   },
 ]
 
@@ -371,7 +364,7 @@ export default {
       accountList: [],
       directionalId: undefined,
       value: 1,
-      columns: [...province,...regionColumns],
+      columns: [...province, ...regionColumns],
       tableData: [],
       dateRange: [moment().subtract(2, 'day'), moment().subtract(2, 'day')],
       topOption: JSON.parse(JSON.stringify(option)),
@@ -407,7 +400,6 @@ export default {
   },
   methods: {
     filterOption(input, option) {
-      console.log(input, option)
       return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
     },
 
@@ -422,29 +414,24 @@ export default {
     },
     tableTypeChange(e) {
       //   console.log('radio checked', e.target.value)
-        if (e.target.value == 'province') {
-          this.columns = [...province, ...regionColumns]
-        } else if (e.target.value == 'city') {
-          this.columns = [...city, ...regionColumns]
-        } else if (e.target.value == 'gender') {
-          this.columns = [...gender, ...regionColumns]
-        }
-         else if (e.target.value == 'ageSegment') {
-          this.columns = [...ageSegment, ...regionColumns]
-        }
-         else if (e.target.value == 'clientId') {
-          this.columns = [...client, ...regionColumns]
-        }
-         else if (e.target.value == 'businessInterestTags') {
-          this.columns = [...businessInterestTags, ...regionColumns]
-        }
+      if (e.target.value == 'province') {
+        this.columns = [...province, ...regionColumns]
+      } else if (e.target.value == 'city') {
+        this.columns = [...city, ...regionColumns]
+      } else if (e.target.value == 'gender') {
+        this.columns = [...gender, ...regionColumns]
+      } else if (e.target.value == 'ageSegment') {
+        this.columns = [...ageSegment, ...regionColumns]
+      } else if (e.target.value == 'clientId') {
+        this.columns = [...client, ...regionColumns]
+      } else if (e.target.value == 'businessInterestTags') {
+        this.columns = [...businessInterestTags, ...regionColumns]
+      }
       this.ipagination.current = 1
       this.getDetailTableData()
     },
 
-    directionalIdChange(val) {
-      console.log(val)
-    },
+    directionalIdChange(val) {},
     //获取echart的值
     initEchart(idName, optionName) {
       const chart = this.$refs[idName]
@@ -456,8 +443,11 @@ export default {
         // });
 
         myChart.setOption(optionName)
+        var that = this
         window.addEventListener('resize', function () {
-          myChart.resize()
+          that.$nextTick(() => {
+            myChart.resize()
+          })
         })
       }
     },
@@ -469,6 +459,41 @@ export default {
     handlerMapEchartOption(province, data) {
       var res = []
       var dataEnd = []
+      var smallValue = [
+        {
+          min: 100000,
+          color: '#73240D',
+        },
+        {
+          min: 50000,
+          max: 100000,
+          color: '#BB0000',
+        },
+        {
+          min: 30000,
+          max: 50000,
+          color: '#BD430A',
+        },
+        {
+          min: 10000,
+          max: 30000,
+          color: '#E08150',
+        },
+        {
+          min: 5000,
+          max: 10000,
+          color: '#E9B090',
+        },
+        {
+          min: 1000,
+          max: 5000,
+          color: '#F2DDD2',
+        },
+        {
+          value: 0,
+          color: '#F1eeee',
+        },
+      ]
       if (this.value == 1) {
         res = data.map((item) => {
           return item.photoShow
@@ -489,10 +514,80 @@ export default {
         res = data.map((item) => {
           return item.photoClickRatio
         })
+        smallValue = [
+          {
+            min: 55,
+            color: '#73240D',
+          },
+          {
+            min: 45,
+            max: 55,
+            color: '#BB0000',
+          },
+          {
+            min: 35,
+            max: 45,
+            color: '#BD430A',
+          },
+          {
+            min: 25,
+            max: 35,
+            color: '#E08150',
+          },
+          {
+            min: 15,
+            max: 25,
+            color: '#E9B090',
+          },
+          {
+            min: 5,
+            max: 15,
+            color: '#F2DDD2',
+          },
+          {
+            value: 0,
+            color: '#F1eeee',
+          },
+        ]
       } else if (this.value == 6) {
         res = data.map((item) => {
           return item.actionRatio
         })
+        smallValue = [
+          {
+            min: 55,
+            color: '#73240D',
+          },
+          {
+            min: 45,
+            max: 55,
+            color: '#BB0000',
+          },
+          {
+            min: 35,
+            max: 45,
+            color: '#BD430A',
+          },
+          {
+            min: 25,
+            max: 35,
+            color: '#E08150',
+          },
+          {
+            min: 15,
+            max: 25,
+            color: '#E9B090',
+          },
+          {
+            min: 5,
+            max: 15,
+            color: '#F2DDD2',
+          },
+          {
+            value: 0,
+            color: '#F1eeee',
+          },
+        ]
       }
 
       for (var j = 0; j < province.length; j++) {
@@ -501,6 +596,7 @@ export default {
           value: res[j],
         })
       }
+
       var that = this
       var option = {
         title: {
@@ -520,44 +616,11 @@ export default {
             return str
           },
         },
+        layoutCenter: ['30%', '30%'],
         visualMap: {
           type: 'piecewise',
           // text: ['头', '尾'],
-          pieces: [
-            {
-              min: 100000,
-              color: '#73240D',
-            },
-            {
-              min: 50000,
-              max: 100000,
-              color: '#BB0000',
-            },
-            {
-              min: 30000,
-              max: 50000,
-              color: '#BD430A',
-            },
-            {
-              min: 10000,
-              max: 30000,
-              color: '#E08150',
-            },
-            {
-              min: 5000,
-              max: 10000,
-              color: '#E9B090',
-            },
-            {
-              min: 1000,
-              max: 5000,
-              color: '#F2DDD2',
-            },
-            {
-              value: 0,
-              color: '#F1eeee',
-            },
-          ],
+          pieces: smallValue,
           orient: 'vertical',
           itemSymbol: 'circle',
           itemWidth: 20,
@@ -573,9 +636,11 @@ export default {
         grid: {
           right: '5%',
           top: '20%',
-          left: '20%',
+          left: '60%',
           bottom: '10%',
-          width: '20%',
+          width: '100%',
+          x: '40%',
+          containLabel: true,
         },
         xAxis: {
           min: 0,
@@ -612,7 +677,6 @@ export default {
           },
         ],
       }
-      console.log(option)
       return option
     },
 
@@ -647,7 +711,7 @@ export default {
         color: ['#37a2da', '#32c5e9', '#9fe6b8', '#ffdb5c', '#ff9f7f', '#fb7293', '#e7bcf3', '#8378ea'],
         tooltip: {
           trigger: 'item',
-          formatter: '{a} <br/>{b} : {c} ({d}%)',
+          formatter: '{b} : {c} ',
         },
         toolbox: {
           show: true,
@@ -657,23 +721,27 @@ export default {
           // subtext: '仅供参考',
           left: 'left',
         },
-        legend: {
-          type: 'scroll',
-          orient: 'vertical',
-          left: '10%',
-          align: 'left',
-          top: 'middle',
-          textStyle: {
-            color: '#8C8C8C',
-          },
-          height: 100,
+        grid: {
+          containLabel: true,
         },
+        // legend: {
+        //   type: 'scroll',
+        //   orient: 'vertical',
+        //   left: '10%',
+        //   align: 'left',
+        //   top: 'middle',
+        //   textStyle: {
+        //     color: '#8C8C8C',
+        //   },
+        //   height: 100,
+        // },
         series: [
           {
             type: 'pie',
             radius: [0, 100],
 
             data: res,
+            minAngle: 10,
           },
         ],
       }
@@ -758,7 +826,7 @@ export default {
                                         borderRadius: 1,
                                         padding: [1, -1, 1, -1]
                             */
-              formatter: '{a|{b}:}{b|{d}%}',
+              formatter: '{a|{b}  }',
               rich: {
                 a: {
                   padding: [0, 0, 0, 10],
@@ -844,7 +912,7 @@ export default {
         ],
         yAxis: [
           {
-            type: 'value',
+            type: 'log',
           },
         ],
         series: [
@@ -927,7 +995,7 @@ export default {
         ],
         yAxis: [
           {
-            type: 'value',
+            type: 'log',
           },
         ],
         series: [
@@ -944,7 +1012,6 @@ export default {
     },
     //点击分页
     sort(pagination, filters, sorter, { currentDataSource }) {
-      console.log(pagination, sorter)
       this.ipagination.current = pagination.current
       this.ipagination.pageSize = pagination.pageSize
 
@@ -958,7 +1025,6 @@ export default {
       this.getTableData()
     },
     materialTableChange(pagination, filters, sorter, { currentDataSource }) {
-      console.log(pagination)
       this.materialipagination.current = pagination.current
       this.materialipagination.pageSize = pagination.pageSize
     },
@@ -995,68 +1061,62 @@ export default {
     },
 
     getRelativeData() {
-      
       let params = this.handlerParams()
       // params.dataType=this.tableValue
-      if(params.accountIds){
-      this.spinning = true
-      getAction('/audienceReport/queryAllReportForm', params).then((res) => {
-        console.log(res)
-        this.spinning = false
-        if (res.success) {
-          this.province = res.result.province.map((item) => {
-            return item.province
-          })
-          this.provinceData = res.result.province
-          this.initEchart('mapEchart', this.handlerMapEchartOption(this.province, this.provinceData))
-          this.sexData = res.result.gender
-          this.initEchart('sexEchart', this.handlerSexOption(this.sexData))
-          this.ageData = res.result.ageSegment
-          this.initEchart('ageEchart', this.handlerAgeOption(this.ageData))
-          this.businessData = res.result.businessInterestTags
-          this.initEchart('businessEchart', this.handlerBusinessOption(this.businessData))
-          this.systemData = res.result.client
-          this.initEchart('systemEchart', this.handlerSystemOption(this.systemData))
-        } else {
-          this.$message.error(res.message)
-          this.province = []
-          this.provinceData = []
-          this.sexData = []
-          this.ageData = []
-          this.businessData = []
-          this.systemData = []
-          this.initEchart('mapEchart', this.handlerMapEchartOption(this.province, this.provinceData))
-          this.initEchart('sexEchart', this.handlerSexOption(this.sexData))
-          this.initEchart('ageEchart', this.handlerAgeOption(this.ageData))
-          this.initEchart('businessEchart', this.handlerBusinessOption(this.businessData))
-          this.initEchart('systemEchart', this.handlerSystemOption(this.systemData))
-        }
-      })
-      
+      if (params.accountIds) {
+        this.spinning = true
+        getAction('/audienceReport/queryAllReportForm', params).then((res) => {
+          this.spinning = false
+          if (res.success) {
+            this.province = res.result.province.map((item) => {
+              return item.province
+            })
+            this.provinceData = res.result.province
+            this.initEchart('mapEchart', this.handlerMapEchartOption(this.province, this.provinceData))
+            this.sexData = res.result.gender
+            this.initEchart('sexEchart', this.handlerSexOption(this.sexData))
+            this.ageData = res.result.ageSegment
+            this.initEchart('ageEchart', this.handlerAgeOption(this.ageData))
+            this.businessData = res.result.businessInterestTags
+            this.initEchart('businessEchart', this.handlerBusinessOption(this.businessData))
+            this.systemData = res.result.client
+            this.initEchart('systemEchart', this.handlerSystemOption(this.systemData))
+          } else {
+            this.$message.error(res.message)
+            this.province = []
+            this.provinceData = []
+            this.sexData = []
+            this.ageData = []
+            this.businessData = []
+            this.systemData = []
+            this.initEchart('mapEchart', this.handlerMapEchartOption(this.province, this.provinceData))
+            this.initEchart('sexEchart', this.handlerSexOption(this.sexData))
+            this.initEchart('ageEchart', this.handlerAgeOption(this.ageData))
+            this.initEchart('businessEchart', this.handlerBusinessOption(this.businessData))
+            this.initEchart('systemEchart', this.handlerSystemOption(this.systemData))
+          }
+        })
       }
     },
     getTableData() {
-      
       let params = this.handlerParams() || {}
-      if(params.accountIds){
-      this.materialloading = true
-      params.audienceType = this.tableValue
-      params.pageNo = this.ipagination.current
-      params.pageSize = this.ipagination.pageSize
-      params.orderType = this.target
-      params.upOrDown = this.order
-      // params.dataType=this.tableValue
-      getAction('/audienceReport/queryPageList', params).then((res) => {
-        console.log(res)
-        this.materialloading = false
-        if (res) {
-          this.tableData = res.list
-          this.ipagination.total = res.total
-        } else {
-          this.$message.error('出错了')
-        }
-      })
-      
+      if (params.accountIds) {
+        this.materialloading = true
+        params.audienceType = this.tableValue
+        params.pageNo = this.ipagination.current
+        params.pageSize = this.ipagination.pageSize
+        params.orderType = this.target
+        params.upOrDown = this.order
+        // params.dataType=this.tableValue
+        getAction('/audienceReport/queryPageList', params).then((res) => {
+          this.materialloading = false
+          if (res) {
+            this.tableData = res.list
+            this.ipagination.total = res.total
+          } else {
+            this.$message.error('出错了')
+          }
+        })
       }
     },
     search() {
@@ -1073,16 +1133,13 @@ export default {
         this.spinning = false
         return
       } else {
-        params.accountIds ='';
-        this.accountIds.forEach((item,index)=>{
-          
-            if(index!=this.accountIds.length-1){
-              params.accountIds+=`${item},`
-            }else{
-              params.accountIds+=`${item}`
-            }
-          
-
+        params.accountIds = ''
+        this.accountIds.forEach((item, index) => {
+          if (index != this.accountIds.length - 1) {
+            params.accountIds += `${item},`
+          } else {
+            params.accountIds += `${item}`
+          }
         })
       }
 
@@ -1225,7 +1282,6 @@ export default {
       }
     },
   },
-  
 }
 </script>
 

+ 2 - 2
src/views/modules/workBench/designLeader/platForm.vue

@@ -100,13 +100,13 @@
                                             <span class="item-icon"></span>
                                             <div class="content">
                                                 <p class="name">{{item.orderTitle}}</p>
-                                                <p class="desc">{{item.orderRemark}}</p>
+                                                <p class="desc">{{item.orderRemark || '-'}}</p>
                                             </div>
                                         </div>
                                         
                                         <div class="progress" v-if="item.orderStatus==1||item.orderStatus==3">
                                             <a-progress type="circle" :percent="(item.materialFinishAmount/item.materialAmount)*100" :width='30' :showInfo='false'  :strokeWidth='10' />
-                                            <span style="margin-left:15px">{{(item.materialFinishAmount/item.materialAmount)*100}}%</span>
+                                            <span style="margin-left:15px">{{Math.round((item.materialFinishAmount/item.materialAmount)*100)}}%</span>
                                         </div>
                                         <div class="progress" v-else>
                                             {{item.orderStatus|handleOrderStatus}}

+ 2 - 2
src/views/modules/workBench/designPeople/platForm.vue

@@ -80,13 +80,13 @@
                                             <span class="item-icon"></span>
                                             <div class="content">
                                                 <p class="name">{{item.orderTitle}}</p>
-                                                <p class="desc">{{item.orderRemark}}</p>
+                                                <p class="desc">{{item.orderRemark || '-'}}</p>
                                             </div>
                                         </div>
                                         
                                         <div class="progress" v-if="item.orderStatus==1||item.orderStatus==3">
                                             <a-progress type="circle" :percent="(item.materialFinishAmount/item.materialAmount)*100" :width='30' :showInfo='false'  :strokeWidth='10' />
-                                            <span style="margin-left:15px">{{(item.materialFinishAmount/item.materialAmount)*100}}%</span>
+                                            <span style="margin-left:15px">{{Math.round((item.materialFinishAmount/item.materialAmount)*100)}}%</span>
                                         </div>
                                         <div class="progress" v-else>
                                             {{item.orderStatus|handleOrderStatus}}

+ 55 - 14
src/views/modules/workBench/materialList.vue

@@ -235,11 +235,11 @@
 }
 .videomarterialInfo{
     position: relative;
-    height: 800px;
+    // height: 800px;
 }
 .marterialInfo{
     overflow: auto;   
-    height: 800px;
+    // height: 800px;
     position: relative;
     p{margin-bottom: 0;}
     ul,li{
@@ -430,11 +430,12 @@
                                             :value.sync="urlList.url"
                                             @overUpload="overUpload"
                                             @removeUpload="removeUpload"
-                                            :fileCount="10"
+                                            :fileCount="1"
                                             uploadType="video"
                                             :multiple="false"
                                         />
                                         <span v-if="repeat" style="color: red">此素材重复,请重新选择上传</span>
+                                        <!-- {{urlList.url }} -->
                                         <span v-if="confirmLoading && urlList.url != ''" style="color: green">上传成功</span>
                                     </a-form-item>
                                     
@@ -555,7 +556,7 @@
                                         <a-textarea
                                             placeholder="请输入描述"
                                             v-decorator="[
-                                            'materialDescribe', // 给表单赋值或拉取表单时,该input对应的key
+                                            'description', // 给表单赋值或拉取表单时,该input对应的key
                                             ]"
                                             :auto-size="{ minRows: 3, maxRows: 10 }"
                                         />
@@ -637,14 +638,30 @@
                                 <p>{{ currentVideo.videoAdvise }}</p>
                             </div>
                             <!-- <div class="info-item btnBody"> -->
-                                <div class="bottom-btn">
-                                    <a-button type='primary' v-if="currentVideo.videoStatus==2" @click="modifyVideo" style="margin-right:20px">修改视频信息</a-button>
+                                <!-- <div class="bottom-btn">
+                                    <a-button type='primary' v-if="currentVideo.videoStatus>=1" @click="modifyVideo"  :disabled="!(currentVideo.clip==userInfo.id)" style="margin-right:20px">修改视频信息</a-button>
                                     <a-button type='default' @click="onClose">关闭</a-button>
-                                </div>
+                                </div> -->
                             <!-- </div> -->
                             
                         </div>
                         </a-spin>
+                        <div
+                            :style="{
+                            position: 'absolute',
+                            right: 0,
+                            bottom: 0,
+                            width: '100%',
+                            borderTop: '1px solid #e9e9e9',
+                            padding: '10px 16px',
+                            background: '#fff',
+                            textAlign: 'right',
+                            zIndex: 1,
+                            }"
+                        >
+                            <a-button type='primary' v-if="currentVideo.videoStatus>=1" @click="modifyVideo"  :disabled="!(currentVideo.clip==userInfo.id)" style="margin-right:20px">修改视频信息</a-button>
+                            <a-button type='default' @click="onClose">关闭</a-button>
+                        </div>    
                     </a-drawer>
                     
 
@@ -656,7 +673,7 @@
                     :visible="scriptVisible"
                     @close="scriptClose"
                     >
-                        
+                        <a-spin :spinning="visibleLoading">
                         <div class="marterialInfo">
                             <div class="info-item">
                                 <span>脚本状态:</span>
@@ -687,7 +704,7 @@
                                 <div v-if="currentScript.scriptStatus>0" style="margin-right:20px">
                                     <a :href="currentScript.url">{{currentScript.scriptName}}</a>
                                 </div>
-                                <div v-if="currentScript.scriptStatus==0||currentScript.scriptStatus==2">
+                                <div v-if="currentScript.scriptStatus<3">
                                    
                                     <p v-if="currentMaterial.plan==userInfo.id">
                                         <a-upload
@@ -728,11 +745,27 @@
                                 
                             </div>
                                                        
-                            <div class="scriptbottom-btn">
+                            <!-- <div class="scriptbottom-btn">
  
                                 <a-button type='default' @click="scriptClose">关闭</a-button>
-                            </div>
+                            </div> -->
                         </div>
+                        </a-spin>  
+                        <div
+                            :style="{
+                            position: 'absolute',
+                            right: 0,
+                            bottom: 0,
+                            width: '100%',
+                            borderTop: '1px solid #e9e9e9',
+                            padding: '10px 16px',
+                            background: '#fff',
+                            textAlign: 'right',
+                            zIndex: 1,
+                            }"
+                        >
+                            <a-button type='default' @click="scriptClose">关闭</a-button>
+                        </div>    
                     </a-drawer>
 
 
@@ -756,7 +789,7 @@
                                 <a-select-option :value="item.userId" v-for="item of ascription" :key="item.userId">{{item.userName}}</a-select-option>
                                 </a-select>
                             </a-form-model-item>
-                            <a-form-model-item  label="拍摄"  ref="shot"  prop="shot">
+                            <a-form-model-item  label="拍摄"  ref="shot"  prop="shot" :rules='[{ required: currentMaterial.materialType==1, message: "拍摄人员必须指派" ,trigger: "change" }]'>
                                 <a-select
                                     
                                     v-model="formPerson.shot"
@@ -1339,10 +1372,12 @@ export default {
             this.currentMaterial=record
             this.currentScript={};
             if(record.scriptId){
+                this.visibleLoading=true 
                 getAction(this.url.scriptDetail,{
                     scriptId:record.scriptId
                 }).then(res=>{
                     console.log(res);
+                    this.visibleLoading=false
                     if(res.success){
                         this.currentScript=res.result;
                         this.scriptVisible = true;
@@ -1414,6 +1449,7 @@ export default {
            
         },
 
+
         handlerParamsRole(role){
             if(this.$parent.role=='operator'){
                 this.panes=this.operatorPanes
@@ -1425,8 +1461,9 @@ export default {
 
         beforeUpload(file) {
 
-            // this.uploadAction= `http://api.tjyourong.com.cn/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.materialId}&projectId=${this.currentMaterial.projectId}`
-            this.uploadAction= `http://139.186.151.174:8804/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.materialId}&projectId=${this.currentMaterial.projectId}`
+            this.uploadAction= `http://jiaoyangapi.shyouteng.com.cn/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.materialId}&projectId=${this.currentMaterial.projectId}`
+            // this.uploadAction= `http://139.186.151.174:8804/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.materialId}&projectId=${this.currentMaterial.projectId}`
+            // this.uploadAction= `http://192.168.1.43:8088/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.materialId}&projectId=${this.currentMaterial.projectId}`
             this.loadDisabled = true
             const size = (Number(file.size) / (1024 * 1024)).toFixed(2)
             const fileName = file.name
@@ -1578,6 +1615,10 @@ export default {
 
         // 上传视频相关方法
         removeUpload() {
+            this.urlList.url='';
+            this.urlList.md5='';
+            this.urlList.name='';
+           
             this.form.setFieldsValue({
                 contentTagList: null,
                 modalityTagList: null,

+ 173 - 78
src/views/modules/workBench/operator/materialList.vue

@@ -236,11 +236,11 @@
 }
 .videomarterialInfo{
     position: relative;
-    height: 800px;
+    // height: 800px;
 }
 .marterialInfo{
     overflow: auto;
-    height: 800px;
+    // height: 800px;
     position: relative;
     p{margin-bottom: 0;}
     ul,li{
@@ -449,16 +449,34 @@
                                 <p>{{ currentVideo.videoAdvise }}</p>
                             </div>
                             
-                            <div class="bottom-btn">
+                            <!-- <div class="bottom-btn">
                                 <a-button type='primary' @click="approved" v-if="currentMaterial.materialStatus==5" :loading='acceptLoading' style="margin-right:20px">通过审核</a-button>                               
                                 <a-button type='default' @click="()=>{videoRejectVisiable=true}" v-if="currentMaterial.materialStatus==5"  style="margin-right:20px">驳回</a-button>
                                                             
                                 <a-button type='default' @click="onClose">关闭</a-button>
-                            </div>
+                            </div> -->
                             
                         
                         </div>
-                        </a-spin>   
+                        </a-spin>
+                        <div
+                            :style="{
+                            position: 'absolute',
+                            right: 0,
+                            bottom: 0,
+                            width: '100%',
+                            borderTop: '1px solid #e9e9e9',
+                            padding: '10px 16px',
+                            background: '#fff',
+                            textAlign: 'right',
+                            zIndex: 1,
+                            }"
+                        >
+                            <a-button type='primary' @click="approved" v-if="currentMaterial.materialStatus==5" :loading='acceptLoading' style="margin-right:20px">通过审核</a-button>                               
+                                <a-button type='default' @click="()=>{videoRejectVisiable=true}" v-if="currentMaterial.materialStatus==5"  style="margin-right:20px">驳回</a-button>
+                                                            
+                                <a-button type='default' @click="onClose">关闭</a-button>
+                        </div>   
                     </a-drawer>
                     <a-drawer
                     title="脚本详情"
@@ -499,14 +517,33 @@
                             </div>
                                                        
                             <div class="scriptbottom-btn">
-                                <a-button type='primary' @click="scriptApproved" v-if="currentMaterial.materialStatus==2" style="margin-right:20px" >通过审核</a-button>
+                                <!-- <a-button type='primary' @click="scriptApproved" v-if="currentMaterial.materialStatus==2" :loading='acceptLoading' style="margin-right:20px" >通过审核</a-button>
                                
                                 <a-button type='default' v-if="currentMaterial.materialStatus==2" @click="()=>{scriptRejectVisiable=true}"  style="margin-right:20px">驳回</a-button>
                                 
-                                <a-button type='default' @click="scriptClose">关闭</a-button>
+                                <a-button type='default' @click="scriptClose">关闭</a-button> -->
                             </div>
                         </div>
-                        </a-spin>   
+                        </a-spin>
+                        <div
+                            :style="{
+                            position: 'absolute',
+                            right: 0,
+                            bottom: 0,
+                            width: '100%',
+                            borderTop: '1px solid #e9e9e9',
+                            padding: '10px 16px',
+                            background: '#fff',
+                            textAlign: 'right',
+                            zIndex: 1,
+                            }"
+                        >
+                            <a-button type='primary' @click="scriptApproved" v-if="currentMaterial.materialStatus==2" :loading='acceptLoading' style="margin-right:20px" >通过审核</a-button>
+                               
+                                <a-button type='default' v-if="currentMaterial.materialStatus==2" @click="()=>{scriptRejectVisiable=true}"  style="margin-right:20px">驳回</a-button>
+                                
+                                <a-button type='default' @click="scriptClose">关闭</a-button>
+                        </div>    
                     </a-drawer>
 
                     <!-- bohui -->
@@ -515,24 +552,32 @@
                         <a-button key="back" @click="()=>{videoRejectVisiable=false}">取消</a-button>
                         <a-button type="primary"  @click="reject" :loading="loadingElse">确定驳回</a-button>
                     </template>
-                   <a-textarea
-                    v-model="videoAdvise"
-                    placeholder="请填写驳回理由"
-                    :auto-size="{ minRows: 3, maxRows: 5 }"
-                    />
+                    <div style="position:relative">
+                        <a-textarea
+                        v-model="videoAdvise"
+                        placeholder="请填写驳回理由"
+                        :auto-size="{ minRows: 3, maxRows: 5 }"
+                        :maxLength='50'
+                        />
+                        <span style="position:absolute;bottom:5px;right:10px;line-height:24px"><span style="color:#1890ff">{{videoAdvise.length}}</span>/50</span> 
+                    </div>
+                   
                 </a-modal>
                 <a-modal v-model="scriptRejectVisiable" title="脚本驳回"  width='600px'>
                      <template slot="footer">
                         <a-button key="back" @click="()=>{scriptRejectVisiable=false}">取消</a-button>
                         <a-button type="primary"  @click="scriptReject" :loading="loadingElse">确定驳回</a-button>
                     </template>                   
-                    
+                    <div style="position:relative">
                         <a-textarea
-                        v-model="scriptAdvise"
-                        placeholder="请填写驳回理由"
-                        :auto-size="{ minRows: 3, maxRows: 5 }"
+                            v-model="scriptAdvise"
+                            placeholder="请填写驳回理由"
+                            :auto-size="{ minRows: 3, maxRows: 5 }"
+                            :maxLength='50'
                         />
-                                      
+                        <span style="position:absolute;bottom:5px;right:10px;line-height:24px"><span style="color:#1890ff">{{scriptAdvise.length}}</span>/50</span>     
+                    </div>
+                               
                 </a-modal>
                 
                 </div>
@@ -809,95 +854,145 @@ export default {
 
         // 脚本通过审核
         scriptApproved(){
-            postAction(this.url.scriptAccept,{
-                id:this.currentMaterial.materialId,
-                orderCode:this.currentMaterial.orderCode,
-                materialCode:this.currentMaterial.materialCode
+            this.acceptLoading=true;
+            getAction('/platform/material/verifyScript',{
+                materialCode:this.currentMaterial.materialCode,
+                scriptId:this.currentMaterial.scriptId,
             }).then(res=>{
-                console.log(res);
-
-                this.scriptVisible=false;
                 if(res.success){
-                    this.$message.success(res.message);
-                    this.tableHttp(this.$parent.materialStatus)
+                    postAction(this.url.scriptAccept,{
+                        id:this.currentMaterial.materialId,
+                        orderCode:this.currentMaterial.orderCode,
+                        materialCode:this.currentMaterial.materialCode
+                    }).then(res=>{
+                        console.log(res);
+                        this.acceptLoading=false;
+                        this.scriptVisible=false;
+                        if(res.success){
+                            
+                            this.$message.success(res.message);
+                            this.tableHttp(this.$parent.materialStatus)
+                        }else{
+                            this.$message.error(res.message)
+                        }
+                    })
                 }else{
+                    this.acceptLoading=false;
+                    this.scriptVisible=false;
+                    this.tableHttp(this.$parent.materialStatus)
                     this.$message.error(res.message)
                 }
             })
+            
         },
         // 脚本驳回
         scriptReject(){
             this.loadingElse=true
-            if(this.scriptAdvise){
-                postAction(this.url.scriptReject,{
-                    id:this.currentMaterial.materialId,
-                    scriptAdvise:this.scriptAdvise,
-                    materialCode:this.currentMaterial.materialCode
-                }).then(res=>{
-                    console.log(res);
-                    this.scriptAdvise=''
-                    this.scriptVisible=false;
-                    this.loadingElse=false;
-                    this.scriptRejectVisiable=false
-                    if(res.success){
-                        this.$message.success(res.message);
-                        this.tableHttp(this.$parent.materialStatus)
+             getAction('/platform/material/verifyScript',{
+                materialCode:this.currentMaterial.materialCode,
+                scriptId:this.currentMaterial.scriptId,
+            }).then(res=>{
+                if(res.success){
+                    if(this.scriptAdvise){
+                        postAction(this.url.scriptReject,{
+                            id:this.currentMaterial.materialId,
+                            scriptAdvise:this.scriptAdvise,
+                            materialCode:this.currentMaterial.materialCode
+                        }).then(res=>{
+                            console.log(res);
+                            this.scriptAdvise=''
+                            this.scriptVisible=false;
+                            this.loadingElse=false;
+                            this.scriptRejectVisiable=false
+                            if(res.success){
+                                this.$message.success(res.message);
+                                this.tableHttp(this.$parent.materialStatus)
+                            }else{
+                                this.$message.error(res.message)
+                            }
+                        })
                     }else{
-                        this.$message.error(res.message)
+                        this.loadingElse=false;
+                        this.$message.error('请填写驳回理由')
                     }
-                })
-            }else{
-                this.loadingElse=false;
-                this.$messgae.error('请填写驳回理由')
-            }
-            
+                }else{
+                    this.loadingElse=false;
+                    this.scriptVisible=false;
+                    this.tableHttp(this.$parent.materialStatus)
+                    this.$message.error(res.message)
+                }
+            })
         },
         // 视频通过审核
         approved(){
             this.acceptLoading=true;
-            postAction(this.url.videoAccept,{
-                id:this.currentMaterial.materialId,
-                orderCode:this.currentMaterial.orderCode,
+            getAction('/platform/material/verifyVideo',{
                 materialCode:this.currentMaterial.materialCode,
-                videoId:this.currentVideo.videoId
+                videoId:this.currentMaterial.videoId,
             }).then(res=>{
-                console.log(res);
-                this.acceptLoading=false;
-                this.visible=false;
                 if(res.success){
-                    this.$message.success(res.message);
-                    this.tableHttp(this.$parent.materialStatus)
+                    postAction(this.url.videoAccept,{
+                        id:this.currentMaterial.materialId,
+                        orderCode:this.currentMaterial.orderCode,
+                        materialCode:this.currentMaterial.materialCode,
+                        videoId:this.currentVideo.videoId
+                    }).then(res=>{
+                        console.log(res);
+                        this.acceptLoading=false;
+                        this.visible=false;
+                        if(res.success){
+                            this.$message.success(res.message);
+                            this.tableHttp(this.$parent.materialStatus)
+                        }else{
+                            this.$message.error(res.message)
+                        }
+                    })
                 }else{
                     this.$message.error(res.message)
+                    this.acceptLoading=false
+                    this.visible=false;
+                    this.tableHttp(this.$parent.materialStatus)
                 }
             })
+            
         },
         // 视频驳回
         reject(){
             this.loadingElse=true
-            if(this.videoAdvise){
-                postAction(this.url.videoReject,{
-                    id:this.currentMaterial.materialId,
-                    videoAdvise:this.videoAdvise,
-                    materialCode:this.currentMaterial.materialCode
-                }).then(res=>{
-                    console.log(res);
-                    this.videoAdvise='';
-                    this.visible=false;
-                    this.loadingElse=false;
-                    this.videoRejectVisiable=false
-                    if(res.success){
-                        this.$message.success(res.message);
-                        this.tableHttp(this.$parent.materialStatus)
+            getAction('/platform/material/verifyVideo',{
+                materialCode:this.currentMaterial.materialCode,
+                videoId:this.currentMaterial.videoId,
+            }).then(res=>{
+                if(res.success){
+                    if(this.videoAdvise){
+                        postAction(this.url.videoReject,{
+                            id:this.currentMaterial.materialId,
+                            videoAdvise:this.videoAdvise,
+                            materialCode:this.currentMaterial.materialCode
+                        }).then(res=>{
+                            console.log(res);
+                            this.videoAdvise='';
+                            this.visible=false;
+                            this.loadingElse=false;
+                            this.videoRejectVisiable=false
+                            if(res.success){
+                                this.$message.success(res.message);
+                                this.tableHttp(this.$parent.materialStatus)
+                            }else{
+                                this.$message.error(res.message)
+                            }
+                        })
                     }else{
-                        this.$message.error(res.message)
+                        this.loadingElse=false;
+                        this.$message.error('请填写驳回理由')
                     }
-                })
-            }else{
-                this.loadingElse=false;
-                this.$message.error('请填写驳回理由')
-            }
-            
+                }else{
+                    this.$message.error(res.message)
+                    this.loadingElse=false
+                    this.visible=false;
+                    this.tableHttp(this.$parent.materialStatus)
+                }
+            })
         },
         
         search(){

+ 3 - 3
src/views/modules/workBench/operator/platForm.vue

@@ -93,13 +93,13 @@
                                             <span class="item-icon"></span>
                                             <div class="content">
                                                 <p class="name">{{item.orderTitle}}</p>
-                                                <p class="desc">{{item.orderRemark}}</p>
+                                                <p class="desc">{{item.orderRemark|| '-'}}</p>
                                             </div>
                                         </div>
                                         
                                         <div class="progress" v-if="item.orderStatus==1||item.orderStatus==3">
                                             <a-progress type="circle" :percent="(item.materialFinishAmount/item.materialAmount)*100" :width='30' :showInfo='false'  :strokeWidth='10' />
-                                            <span style="margin-left:15px">{{(item.materialFinishAmount/item.materialAmount)*100}}%</span>
+                                            <span style="margin-left:15px;">{{Math.round((item.materialFinishAmount/item.materialAmount)*100)}}%</span>
                                         </div>
                                         <div class="progress" v-else>
                                             {{item.orderStatus|handleOrderStatus}}
@@ -269,7 +269,7 @@ export default {
                        
                             let time='';
                             let startTime=moment(item.createTime)
-                            console.log(startTime) 
+                            // console.log(startTime) 
                             if(moment().diff(startTime,'hours')>24){
                                 time=item.createTime.split(/[ ]+/)[0]
                                 return {

+ 240 - 162
src/views/modules/workBench/orderDetail.vue

@@ -238,11 +238,11 @@
 }
 .videomarterialInfo{
     position: relative;
-    height: 800px;
+    // height: 800px;
 }
 .marterialInfo{
     overflow: auto;
-     height: 800px;
+    //  height: 800px;
     position: relative;
     p{margin-bottom: 0;}
     ul,li{
@@ -363,21 +363,8 @@
                 <div class="optBody">
                     <div class="btnBody" v-if="role=='designLeader'">
                         <a-button type='primary' @click="confirmOrder" :loading='confirmOrderBtnLoading' v-if="currentOrderInfo.orderStatus==0">确定订单</a-button>
-                        <a-popover
-                            title="驳回"
-                            trigger="click"
-                            >
-                            <div slot="content">
-                               <a-textarea
-                                v-model="orderAdvice"
-                                placeholder="请填写驳回理由"
-                                :auto-size="{ minRows: 3, maxRows: 5 }"
-                                />
-                                <a @click="rejectOrder" style="margin-top:30px;text-align:right">确定驳回</a>
-                            </div>
-                             <a-button type='default'   :loading='rejectOrderBtnLoading' v-if="currentOrderInfo.orderStatus==0">驳回订单</a-button>
-                        </a-popover>
-                       
+                        <a-button type='default' @click="()=>{orderRejectVisiable=true}"  :loading='rejectOrderBtnLoading' v-if="currentOrderInfo.orderStatus==0">
+                            驳回订单</a-button>                
                     </div>
                     <div class="btnBody" v-if="role=='operator'">
                         <a-popconfirm
@@ -401,12 +388,27 @@
                             <p class="big">{{ currentOrderInfo.orderStatus | handlerOrderStatus}}</p>
                         </div>
                         <div>
-                            <p class="markName">订单度</p>
-                            <p class="big">{{(currentOrderInfo.materialFinishAmount/currentOrderInfo.materialAmount)*100|| 0 }}%</p>
+                            <p class="markName">订单完成度</p>
+                            <p class="big">{{Math.round((currentOrderInfo.materialFinishAmount/currentOrderInfo.materialAmount)*100)|| 0 }}%</p>
                         </div>
                     </div>
                 </div>
-                
+                <a-modal v-model="orderRejectVisiable" title="订单驳回"  width='600px'>
+                     <template slot="footer">
+                        <a-button key="back" @click="()=>{orderRejectVisiable=false}">取消</a-button>
+                        <a-button type="primary"  @click="rejectOrder" :loading="loadingElse">确定驳回</a-button>
+                    </template>
+                    <div style="position:relative">
+                    <a-textarea
+                    v-model="orderAdvice"
+                    placeholder="请填写驳回理由"
+                    :auto-size="{ minRows: 3, maxRows: 5 }"
+                    :maxLength='50'
+                    />
+                    <span style="position:absolute;bottom:5px;right:10px;line-height:24px"><span style="color:#1890ff">{{orderAdvice.length}}</span>/50</span>
+                    </div>
+                   
+                </a-modal>
             </div>
         </div>
         <div class="section">
@@ -489,7 +491,7 @@
                         </div>
                         <div class="bottom">
                             <h4>备注</h4>
-                            <p>{{currentOrderInfo.orderRemark}}</p>
+                            <p style="line-height:24px;text-indent:2em">{{currentOrderInfo.orderRemark}}</p>
                         </div>
                     </div>
 
@@ -586,7 +588,7 @@
                                             :multiple="false"
                                         />
                                         <span v-if="repeat" style="color: red">此素材重复,请重新选择上传</span>
-                                        <span v-if="confirmLoading && videoinfo.url != ''" style="color: green">上传成功</span>
+                                        <span v-if="confirmLoading && urlList.url != ''" style="color: green">上传成功</span>
                                     </a-form-item>
                                     <a-form-item
                                         label="封面上传"
@@ -697,34 +699,7 @@
                                             style="width: 100%"
                                         ></el-cascader>
                                     </a-form-item>
-                                    <!-- <a-form-item
                                     
-                                        label="其他"
-                                        v-if="add"
-                                        >
-                                        <template v-for="(tag, index) in tags">
-                                            <a-tooltip v-if="tag.length > 20" :key="tag" :title="tag">
-                                            <a-tag :key="tag" :closable="index !== 0" :afterClose="() => handleClose(tag)">{{
-                                                `${tag.slice(0, 20)}...`
-                                            }}</a-tag>
-                                            </a-tooltip>
-                                            <a-tag v-else :key="tag" :closable="true" :afterClose="() => handleClose(tag)">{{ tag }}</a-tag>
-                                        </template>
-                                        <a-input
-                                            v-if="inputVisible"
-                                            ref="input"
-                                            type="text"
-                                            size="small"
-                                            :style="{ width: '78px' }"
-                                            :value="inputValue"
-                                            @change="handleInputChange"
-                                            @blur="handleInputConfirm"
-                                            @keyup.enter="handleInputConfirm"
-                                        />
-                                        <a-tag v-else @click="showInput" style="background: #fff; borderstyle: dashed">
-                                            <a-icon type="plus" />New Tag
-                                        </a-tag>
-                                    </a-form-item> -->
                                     <a-form-item
                                     
                                         label="描述"
@@ -733,7 +708,7 @@
                                         <a-textarea
                                             placeholder="请输入描述"
                                             v-decorator="[
-                                            'describe', // 给表单赋值或拉取表单时,该input对应的key
+                                            'description', // 给表单赋值或拉取表单时,该input对应的key
                                             ]"
                                             :auto-size="{ minRows: 3, maxRows: 10 }"
                                         />
@@ -815,13 +790,32 @@
                                 <p>{{ currentVideo.videoAdvise }}</p>
                             </div>
                             <div class="bottom-btn">
-                                <a-button type='primary' @click="approved" v-if="role=='operator'&&currentMaterial.materialStatus==5" style="margin-right:20px">通过审核</a-button>
+                                <!-- <a-button type='primary' @click="approved" v-if="role=='operator'&&currentMaterial.materialStatus==5" style="margin-right:20px">通过审核</a-button>
                                 <a-button type='default' @click="()=>{videoRejectVisiable=true}" v-if="role=='operator'&&currentMaterial.materialStatus==5"  style="margin-right:20px">驳回</a-button>            
-                                 <a-button type='primary' v-if="role!='operator'&&currentVideo.videoStatus==2" :disabled="currentVideo.clip!=userInfo.id" @click="modifyVideo" style="margin-right:20px">修改视频信息</a-button>                                                   
-                                <a-button type='default' @click="onClose">关闭</a-button>
+                                 <a-button type='primary' v-if="role!='operator'&&currentVideo.videoStatus>=1" :disabled="currentVideo.clip!=userInfo.id" @click="modifyVideo" style="margin-right:20px">修改视频信息</a-button>                                                   
+                                <a-button type='default' @click="onClose">关闭</a-button> -->
                             </div>
                         </div>
+                        
                         </a-spin>   
+                        <div
+                            :style="{
+                            position: 'absolute',
+                            right: 0,
+                            bottom: 0,
+                            width: '100%',
+                            borderTop: '1px solid #e9e9e9',
+                            padding: '10px 16px',
+                            background: '#fff',
+                            textAlign: 'right',
+                            zIndex: 1,
+                            }"
+                        >
+                            <a-button type='primary' @click="approved" v-if="role=='operator'&&currentMaterial.materialStatus==5" style="margin-right:20px">通过审核</a-button>
+                            <a-button type='default' @click="()=>{videoRejectVisiable=true}" v-if="role=='operator'&&currentMaterial.materialStatus==5"  style="margin-right:20px">驳回</a-button>            
+                                <a-button type='primary' v-if="role!='operator'&&currentVideo.videoStatus>=1" :disabled="currentVideo.clip!=userInfo.id" @click="modifyVideo" style="margin-right:20px">修改视频信息</a-button>                                                   
+                            <a-button type='default' @click="onClose">关闭</a-button>
+                        </div>
                     </a-drawer>
                     
 
@@ -864,7 +858,7 @@
                                 <div v-if="currentScript.scriptStatus>0" style="margin-right:20px">
                                     <a :href="currentScript.url">{{currentScript.scriptName}}</a>
                                 </div>
-                                <div v-if="currentScript.scriptStatus==0||currentScript.scriptStatus==2">
+                                <div v-if="currentScript.scriptStatus<3">
                                    
                                     <p v-if="currentMaterial.plan==userInfo.id">
                                         <a-upload
@@ -904,16 +898,28 @@
                                 </div>
                                 
                             </div>
-                                                       
-                            <div class="scriptbottom-btn">
-                                <a-button type='primary' @click="scriptApproved" style="margin-right:20px" v-if="role=='operator'&&currentMaterial.materialStatus==2">通过审核</a-button>
+                        </div>
+                        
+                        </a-spin>  
+                        <div
+                            :style="{
+                            position: 'absolute',
+                            right: 0,
+                            bottom: 0,
+                            width: '100%',
+                            borderTop: '1px solid #e9e9e9',
+                            padding: '10px 16px',
+                            background: '#fff',
+                            textAlign: 'right',
+                            zIndex: 1,
+                            }"
+                        >
+                            <a-button type='primary' @click="scriptApproved" style="margin-right:20px" :loading='acceptLoading' v-if="role=='operator'&&currentMaterial.materialStatus==2">通过审核</a-button>
                                 
                                 <a-button type='default' v-if="role=='operator'&&currentMaterial.materialStatus==2" @click="()=>{scriptRejectVisiable=true}"  style="margin-right:20px">驳回</a-button>
                                 <!-- <a-button type='primary' @click="dowmLoadScript" style="margin-right:20px">下载脚本</a-button> -->
                                 <a-button type='default' @click="scriptClose">关闭</a-button>
-                            </div>
-                        </div>
-                        </a-spin>   
+                        </div> 
                     </a-drawer>
                     
                 </div>
@@ -939,13 +945,14 @@
                                 <a-select-option :value="item.userId" v-for="item of ascription" :key="item.userId">{{item.userName}}</a-select-option>
                                 </a-select>
                             </a-form-model-item>
-                            <a-form-model-item  label="拍摄"  ref="shot"  prop="shot">
-                                <a-select
-                                    
+                            <!-- {{currentMaterial.materialType==1?true:false}} -->
+                            <a-form-model-item  label="拍摄"  ref="shot"  prop="shot" :rules='[{ required: currentMaterial.materialType==1, message: "拍摄人员必须指派" ,trigger: "change" }]'>
+                                <a-select                                   
                                     v-model="formPerson.shot"
                                     showSearch
                                     optionFilterProp="children"
                                     :filterOption="filterOption"
+                                    
                                 >
                                 <a-select-option :value="item.userId" v-for="item of ascription" :key="item.userId">{{item.userName}}</a-select-option>
                                 </a-select>
@@ -970,23 +977,32 @@
                         <a-button key="back" @click="()=>{videoRejectVisiable=false}">取消</a-button>
                         <a-button type="primary"  @click="reject" :loading="loadingElse">确定驳回</a-button>
                     </template>
-                    
-                   <a-textarea
-                    v-model="videoAdvise"
-                    placeholder="请填写驳回理由"
-                    :auto-size="{ minRows: 3, maxRows: 5 }"
-                    />
+                    <div style="position:relative">
+                        <a-textarea
+                        v-model="videoAdvise"
+                        placeholder="请填写驳回理由"
+                        :auto-size="{ minRows: 3, maxRows: 5 }"
+                        :maxLength='50'
+                        />
+                        <span style="position:absolute;bottom:5px;right:10px;line-height:24px"><span style="color:#1890ff">{{videoAdvise.length}}</span>/50</span>
+                    </div>
+                   
                 </a-modal>
                 <a-modal v-model="scriptRejectVisiable" title="脚本驳回"  width='600px'>
                     <template slot="footer">
                         <a-button key="back" @click="()=>{scriptRejectVisiable=false}">取消</a-button>
                         <a-button type="primary"  @click="scriptReject" :loading="loadingElse">确定驳回</a-button>
                     </template>
-                   <a-textarea
-                    v-model="scriptAdvise"
-                    placeholder="请填写驳回理由"
-                    :auto-size="{ minRows: 3, maxRows: 5 }"
-                    />
+                    <div style="position:relative">
+                        <a-textarea
+                        v-model="scriptAdvise"
+                        placeholder="请填写驳回理由"
+                        :auto-size="{ minRows: 3, maxRows: 5 }"
+                        :maxLength='50'
+                        />
+                        <span style="position:absolute;bottom:5px;right:10px;line-height:24px"><span style="color:#1890ff">{{scriptAdvise.length}}</span>/50</span>
+                    </div>
+                   
                 </a-modal>
             </div>
         </div>
@@ -1130,15 +1146,17 @@ export default {
     },
     data() {
         return {
+            orderRejectVisiable:false,
+            acceptLoading:false,
             videoEchoInfo:{},
             videoUploadLoading:false,
             videoRejectType:'1',
             assignVisibleLoading:false,
             visibleLoading:false,
-             rules: {
+            rules: {
                 
                 clip: [{ required: true, message: '剪辑人员必须指派', trigger: 'change' }],
-                // shot: [{ required: true, message: '拍摄人员必须指派', trigger: 'change' }],
+                // shot: [],
                 plan: [{ required: true, message: '编导人员必须指派', trigger: 'change' }],
                 
             },
@@ -1486,6 +1504,7 @@ export default {
                 postAction(this.url.rejectOrder,params).then(res=>{
                     console.log(res)
                     this.rejectOrderBtnLoading=false;
+                    this.orderRejectVisiable=false;
                     if(res.success){
                         this.$message.success(res.message)
                         this.orderDetailHttp()
@@ -1615,7 +1634,9 @@ export default {
                 this.data=[]
                 if(res.success){
                     this.data=res.result.list;
+                    // this.data=res.result.list.filter(item=>item.materialType==this.tabKey);
                     this.ipagination.total=res.result.total
+                    // this.ipagination.total=this.data.length
                     this.loading=false
                 }
             })
@@ -1625,73 +1646,111 @@ export default {
 
         // tabqiehuan
         tabChange(key){
-            console.log(key);
-            
+            // console.log(key);
+            this.materialHttp()
+            this.ipagination.current=1
         },
 
         // shipin通过审核
         approved(){
-            postAction(this.url.videoAccept,{
-                id:this.currentMaterial.id,
-                orderCode:this.currentMaterial.orderCode,
+            this.acceptLoading=true;
+            getAction('/platform/material/verifyVideo',{
                 materialCode:this.currentMaterial.materialCode,
-                videoId:this.currentVideo.videoId
+                videoId:this.currentMaterial.videoId,
             }).then(res=>{
-                console.log(res);
-
-                this.visible=false;
-                this.videoAdvise=''
                 if(res.success){
-                    this.$message.success(res.message);
-                    // this.tableHttp(this.$parent.materialStatus)
-                    this.materialHttp()
+                    postAction(this.url.videoAccept,{
+                        id:this.currentMaterial.id,
+                        orderCode:this.currentMaterial.orderCode,
+                        materialCode:this.currentMaterial.materialCode,
+                        videoId:this.currentVideo.videoId
+                    }).then(res=>{
+                        console.log(res);
+                        this.acceptLoading=false
+                        this.visible=false;
+                        this.videoAdvise=''
+                        if(res.success){
+                            this.$message.success(res.message);
+                            
+                            this.materialHttp()
+                        }else{
+                            this.$message.error(res.message)
+                        }
+                    })
                 }else{
                     this.$message.error(res.message)
+                    this.acceptLoading=false
+                    this.materialHttp()
                 }
             })
         },
         // 视频驳回
         reject(){   
             this.loadingElse=true;
-            if(this.videoAdvise){
-                postAction(this.url.videoReject,{
-                    id:this.currentMaterial.id,
-                    videoAdvise:this.videoAdvise,
-                    materialCode:this.currentMaterial.materialCode
-                    
-                }).then(res=>{
-                    console.log(res);
-                    this.videoAdvise=''
-                    this.visible=false;
-                    this.videoRejectVisiable=false;
-                    if(res.success){
-                        this.$message.success(res.message);
-                        this.materialHttp()
+            getAction('/platform/material/verifyVideo',{
+                materialCode:this.currentMaterial.materialCode,
+                videoId:this.currentMaterial.videoId,
+            }).then(res=>{
+                if(res.success){
+                    if(this.videoAdvise){
+                        postAction(this.url.videoReject,{
+                            id:this.currentMaterial.id,
+                            videoAdvise:this.videoAdvise,
+                            materialCode:this.currentMaterial.materialCode
+                            
+                        }).then(res=>{
+                            console.log(res);
+                            this.loadingElse=false
+                            this.videoAdvise=''
+                            this.visible=false;
+                            this.videoRejectVisiable=false;
+                            if(res.success){
+                                this.$message.success(res.message);
+                                this.materialHttp()
+                            }else{
+                                this.$message.error(res.message)
+                            }
+                        })
                     }else{
-                        this.$message.error(res.message)
-                    }
-                })
-            }else{
-                this.loadingElse=false;
-                this.$message.error('请填写驳回理由')
-            }        
-            
+                        this.loadingElse=false;
+                        this.$message.error('请填写驳回理由')
+                    }        
+                }else{
+                    this.$message.error(res.message)
+                    this.loadingElse=false
+                    this.materialHttp()
+                }
+            })
 
         },
         // 脚本通过审核
         scriptApproved(){
-            postAction(this.url.scriptAccept,{
-                id:this.currentMaterial.id,
-                 orderCode:this.currentMaterial.orderCode,
-                 materialCode:this.currentMaterial.materialCode
+            // console.log(this.currentMaterial)
+            this.acceptLoading=true;
+            getAction('/platform/material/verifyScript',{
+                materialCode:this.currentMaterial.materialCode,
+                scriptId:this.currentMaterial.scriptId,
             }).then(res=>{
-                console.log(res);
-
-                this.scriptVisible=false;
                 if(res.success){
-                    this.$message.success(res.message);
-                    this.materialHttp()
+                    postAction(this.url.scriptAccept,{
+                        id:this.currentMaterial.id,
+                        orderCode:this.currentMaterial.orderCode,
+                        materialCode:this.currentMaterial.materialCode
+                    }).then(res=>{
+                        console.log(res);
+                        this.acceptLoading=false
+                        this.scriptVisible=false;
+                        if(res.success){
+                            this.$message.success(res.message);
+                            this.materialHttp()
+                        }else{
+                            this.$message.error(res.message)
+                        }
+                    })
                 }else{
+                    this.acceptLoading=false;
+                    this.scriptVisible=false;
+                    this.materialHttp()
                     this.$message.error(res.message)
                 }
             })
@@ -1699,30 +1758,41 @@ export default {
         // 脚本驳回
         scriptReject(){
             this.loadingElse=true;
-            if(this.scriptAdvise){
-                postAction(this.url.scriptReject,{
-                    id:this.currentMaterial.id,
-                    scriptAdvise:this.scriptAdvise,
-                    materialCode:this.currentMaterial.materialCode
-                }).then(res=>{
-                    console.log(res);
+            getAction('/platform/material/verifyScript',{
+                materialCode:this.currentMaterial.materialCode,
+                scriptId:this.currentMaterial.scriptId,
+            }).then(res=>{
+                if(res.success){
+                    if(this.scriptAdvise){
+                        postAction(this.url.scriptReject,{
+                            id:this.currentMaterial.id,
+                            scriptAdvise:this.scriptAdvise,
+                            materialCode:this.currentMaterial.materialCode
+                        }).then(res=>{
+                            console.log(res);
 
-                    this.scriptVisible=false;
-                    this.scriptAdvise=''
-                    this.scriptRejectVisiable=false;
-                    this.loadingElse=false;
-                    if(res.success){
-                        this.$message.success(res.message);
-                        this.materialHttp()
+                            this.scriptVisible=false;
+                            this.scriptAdvise=''
+                            this.scriptRejectVisiable=false;
+                            this.loadingElse=false;
+                            if(res.success){
+                                this.$message.success(res.message);
+                                this.materialHttp()
+                            }else{
+                                this.$message.error(res.message)
+                            }
+                        })
                     }else{
-                        this.$message.error(res.message)
+                        this.loadingElse=false;
+                        this.$message.error('请填写驳回理由')
                     }
-                })
-            }else{
-                this.loadingElse=false;
-                this.$messgae.error('请填写驳回理由')
-            }
-            
+                }else{
+                    this.loadingElse=false;
+                    this.scriptVisible=false;
+                    this.materialHttp()
+                    this.$message.error(res.message)
+                }
+            })
         },
         // 生成水印
         getWater() {
@@ -1748,30 +1818,29 @@ export default {
         // 请求order详情数据
         orderDetailHttp(){
             this.pageSpinning=true;
+            this.currentOrderInfo={}
             getAction(this.url.orderDetail,{
                 id:this.currentOrderId
             }).then(res=>{
                 console.log(res)
                 this.pageSpinning=false;
-                this.currentOrderInfo={}
                 if(res.success){
                     this.currentOrderInfo=res.result;
-                    if(res.result.orderStatus){
-                        switch(res.result.orderStatus){
-                            case 0:
-                                this.currentStep=1;
-                                break
-                            case 1:
-                                this.currentStep=2;
-                                break
-                            case 2:
-                                this.currentStep=0;
-                                break
-                            case 3:
-                                this.currentStep=3;
-                                break
+                    // res.result.orderStatus
+                    console.log(this.currentOrderInfo.orderStatus)
+                    if(this.currentOrderInfo.orderStatus || this.currentOrderInfo.orderStatus==0){
+                        if(this.currentOrderInfo.orderStatus==0){
+                            this.currentStep=1;
+                        }else if(this.currentOrderInfo.orderStatus==1){
+                            this.currentStep=2;
+                        }else if(this.currentOrderInfo.orderStatus==2){
+                            this.currentStep=0;
+                        }else if(this.currentOrderInfo.orderStatus==3){
+                            this.currentStep=3;
                         }
+                        
                     }
+                    console.log(this.currentStep)
 
                     this.materialHttp()
                 }
@@ -1803,8 +1872,9 @@ export default {
 
 
         beforeUpload(file) {
-            // this.uploadAction= `http://api.tjyourong.com.cn/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.id}&projectId=${this.currentMaterial.projectId}`
-            this.uploadAction= `http://139.186.151.174:8804/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.id}&projectId=${this.currentMaterial.projectId}`
+            this.uploadAction= `http://jiaoyangapi.shyouteng.com.cn/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.id}&projectId=${this.currentMaterial.projectId}`
+            // this.uploadAction= `http://192.168.1.43:8088/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.id}&projectId=${this.currentMaterial.projectId}`
+            // this.uploadAction= `http://139.186.151.174:8804/jeecg-boot/platform/file/uploadScript?materialId=${this.currentMaterial.id}&projectId=${this.currentMaterial.projectId}`
 
             this.loadDisabled = true
             const size = (Number(file.size) / (1024 * 1024)).toFixed(2)
@@ -2026,6 +2096,10 @@ export default {
 
         // 上传视频相关方法
         removeUpload() {
+            this.urlList.url='';
+            this.urlList.md5='';
+            this.urlList.name='';
+           
             this.form.setFieldsValue({
                 contentTagList: null,
                 modalityTagList: null,
@@ -2323,10 +2397,7 @@ export default {
         // });
 
         this.getTagListAll()
-        
-    },
-    mounted() {
-       let userInfo=localStorage.getItem('pro__Login_Userinfo');
+         let userInfo=localStorage.getItem('pro__Login_Userinfo');
         if(userInfo){
             this.userInfo=JSON.parse(userInfo).value
         }
@@ -2337,6 +2408,13 @@ export default {
         if(this.currentOrderId){
             this.orderDetailHttp()
         } 
+        
+    },
+    mounted() {
+       
+    },
+    destroyed() {
+        this.currentOrderInfo={}
     },
     activated() {
         this.currentOrderId=this.$parent.orderId;

+ 1 - 1
src/views/modules/workBench/orderList.vue

@@ -333,7 +333,7 @@
                         </div>
                         <div class="opt-item">
                             <a-button type='primary' @click="search" style="margin-right:20px">查询</a-button>
-                            <a-button type='default' @click="reset">查询</a-button>
+                            <a-button type='default' @click="reset">重置</a-button>
                         </div>
                     </div>
                         

+ 16 - 11
src/views/modules/workBench/placeOrder.vue

@@ -266,7 +266,7 @@
                         <div class="hint-item"></div>
                         <div class="label-item">
                             <div class="text-item">APK链接</div>
-                            <div class="required-item"></div>
+                            <!-- <div class="required-item"></div> -->
                         </div>
                         <div class="input-item"> 
                             <a-form-model-item ref="sysPackage"  prop="sysPackage">
@@ -302,7 +302,7 @@
                         <div class="hint-item"></div>
                         <div class="label-item">
                             <div class="text-item">日均产量</div>
-                            <div class="required-item"></div>
+                            <!-- <div class="required-item"></div> -->
                         </div>
                         <div class="input-item"> 
                             <a-form-model-item ref="materialAmountDay"  prop="materialAmountDay">
@@ -362,8 +362,10 @@
                                 <a-textarea
                                     v-model="form.orderRemark"
                                     placeholder="请输入订单备注"
-                                    :auto-size="{ minRows: 3,  }"
+                                    :auto-size="{ minRows: 7, }"
+                                    :maxLength='200'
                                 />
+                                <span style="position:absolute;bottom:0px;right:10px;line-height:24px"><span style="color:#1890ff">{{form.orderRemark.length}}</span>/200</span>
                             </a-form-model-item>
                         </div>
                     </div>
@@ -465,15 +467,15 @@ export default {
             rules: {
                 orderTitle: [
                     { required: true, message: '请填写订单标题', trigger: 'blur' },
-                    { min: 2, message: '长度不得小于2', trigger: 'blur' },
-                ],
-                sysPackage: [
-                    { required: true, message: '请输入APK链接', trigger: 'blur' },
-                    { min: 2, message: '长度不得小于2', trigger: 'blur' },
+                    { min: 2, message: '订单标题长度不得小于2', trigger: 'blur' },
                 ],
+                // sysPackage: [
+                //     { required: true, message: '请输入APK链接', trigger: 'blur' },
+                //     { min: 2, message: '长度不得小于2', trigger: 'blur' },
+                // ],
                 dataValue: [{ required: true, message: '请选择订单周期', trigger: 'change' }],
-                materialAmount: [{ required: true, message: '素材总数必须大于1', trigger: 'change' }],
-                materialAmountDay: [{required: true, message: '日均产量必须填写', trigger: 'change' }],
+                materialAmount: [{ required: true, message: '素材总数必须大于等于1', trigger: 'change' }],
+                // materialAmountDay: [{required: true, message: '日均产量必须填写', trigger: 'change' }],
                 project: [{required: true, message: '请选择关联项目', trigger: 'change' }],
                 design: [{required: true, message: '请选择设计组长', trigger: 'change' }],
                 cutAmount: [
@@ -501,6 +503,7 @@ export default {
         }
     },
     methods: {
+        
         goPlantForm(){
             if(this.$parent.role=='operator'){
                 this.$parent.currentTabComponent='operatorPlatform'
@@ -509,6 +512,7 @@ export default {
             }else if(this.$parent.role=='design'){
                 this.$parent.currentTabComponent='operatorPlatform'
             }
+            this.$parent.isEdit=false;
         },
         disabledDate(current) {
             return current && current < moment().subtract(1,'days')
@@ -698,7 +702,8 @@ export default {
 
         beforeUpload(file) {
             // ${this.form.project}
-            this.uploadAction= `http://api.tjyourong.com.cn/jeecg-boot/platform/file/uploadAttachment?projectId=772`
+            this.uploadAction= `http://jiaoyangapi.shyouteng.com.cn/jeecg-boot/platform/file/uploadAttachment?projectId=772`
+            // this.uploadAction= `http://139.186.151.174:8804/jeecg-boot/platform/file/uploadAttachment?projectId=772`
             this.loadDisabled = true
             const size = (Number(file.size) / (1024 * 1024)).toFixed(2)
             const fileName = file.name

+ 6 - 3
vue.config.js

@@ -63,7 +63,7 @@ module.exports = {
 
   devServer: {
     hot:true,
-    // inline: true,
+    // inline: true,
     port: 3000,
     open : true,
     proxy: {
@@ -74,11 +74,11 @@ module.exports = {
         // target: 'http://192.168.1.188:8088', //请求本地 需要jeecg-boot后台项目  英豪
         // target: 'http://192.168.2.115:8080', //请求本地 需要jeecg-boot后台项目  祚云
         // target: 'http://192.168.1.43:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
-        // target: 'http://192.168.1.43:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
+        target: 'http://192.168.1.43:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.1.43:8087', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.0.252:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.1.219:8080', //请求本地 需要jeecg-boot后台项目  赵西安
-        // target: 'http://192.168.1.193:8088', //请求本地 需要jeecg-boot后台项目  李煜一
+        // target: 'http://192.168.1.193:8080', //请求本地 需要jeecg-boot后台项目  李煜一
         //  target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'https://trac.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'http://39.106.184.70:8088/', //请求本地 需要jeecg-boot后台项目
@@ -86,8 +86,11 @@ module.exports = {
         // target: 'http://192.168.1.251/', //请求本地 需要jeecg-boot后台项目
         // target:'http://118.24.244.213:8804',
         // target:'http://139.186.151.174:8804', //测试
+<<<<<<< HEAD
 
 
+=======
+>>>>>>> master
 
         ws: false,