魏志佳 hace 4 años
padre
commit
439d6b987a
Se han modificado 30 ficheros con 3604 adiciones y 261 borrados
  1. BIN
      public/avatar2.jpg
  2. BIN
      public/feishu.png
  3. BIN
      public/goright.png
  4. 1 0
      src/App.vue
  5. 2 1
      src/components/ctop/propModal.vue
  6. 2 4
      src/components/formComponents/selectRegion.vue
  7. 27 26
      src/components/uploadFile.vue
  8. 254 3
      src/components/youtTable/YoutTable.vue
  9. 300 0
      src/components/youtTable/customColumn.vue
  10. 240 0
      src/components/youtTable/selectComponent.vue
  11. 240 0
      src/components/youtTable/selectComponentKS.vue
  12. 98 0
      src/directive.js
  13. 288 0
      src/filters.js
  14. 4 1
      src/main.js
  15. 1323 0
      src/utils/columnConst/accountConst.js
  16. 0 0
      src/utils/columnConst/videoConst.js
  17. 1 1
      src/utils/request.js
  18. 7 7
      src/views/modules/Statistics/KSAccountReport.vue
  19. 509 0
      src/views/modules/Statistics/materialReport/materialReport.vue
  20. 2 2
      src/views/modules/Statistics/popularVideo.vue
  21. 5 1
      src/views/modules/advertiser/ProjectList.vue
  22. 8 1
      src/views/modules/advertiser/modules/projectListModal.vue
  23. 18 20
      src/views/modules/earlyWarningRules/ruleModule.vue
  24. 2 0
      src/views/modules/kuaishouapp/account/accountIndex.vue
  25. 47 31
      src/views/modules/kuaishouapp/account/stepForm/stepModule/targetedPopulation.vue
  26. 1 0
      src/views/modules/kuaishouapp/batchCreation/campaignList.vue
  27. 7 1
      src/views/modules/kuaishouapp/batchCreation/creat/creatUnit.vue
  28. 216 160
      src/views/modules/kuaishouapp/populationAnalysis/index.vue
  29. 2 1
      src/views/modules/workBench/placeOrder.vue
  30. 0 1
      vue.config.js

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,
     },

+ 254 - 3
src/components/youtTable/YoutTable.vue

@@ -1,15 +1,266 @@
+
 <template>
-    <div>
+    <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]);
+        })
+    }
+}

+ 288 - 0
src/filters.js

@@ -0,0 +1,288 @@
+
+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)
+    },
+}
+
+// 获取当前月的第一天
+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'

La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 1323 - 0
src/utils/columnConst/accountConst.js


+ 0 - 0
src/utils/columnConst/videoConst.js


+ 1 - 1
src/utils/request.js

@@ -15,7 +15,7 @@ else if (process.env.NODE_ENV == 'debug') {
 else if (process.env.NODE_ENV == 'production') { 
   
   // axios.defaults.baseURL = 'http://192.168.1.251/jeecg-boot';
-  axios.defaults.baseURL = 'http://139.186.151.174:8804/jeecg-boot';
+  axios.defaults.baseURL = 'http://139.186.151.174:8804/jeecg-boot';     
   // axios.defaults.baseURL = 'http://api.tjyourong.com.cn/jeecg-boot';
 }
 const service = axios.create({

+ 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/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>

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

@@ -359,7 +359,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 +789,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 +811,7 @@ export default {
     disabledDate(current) {
       return current && current < moment().subtract(1, 'days')
     },
-    
+
     // 获取计划列表
     getCampaignList() {
       getAction('/kuaishou/batch/getCampaignList', {
@@ -870,8 +873,6 @@ export default {
       }
     },
 
-    
-
     filterOption(input, option) {
       return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
     },
@@ -890,13 +891,10 @@ export default {
     resetForm() {
       this.$refs.ruleForm.resetFields()
     },
-   
+
     displayRender({ labels }) {
       return labels[labels.length - 1]
     },
-    
-
-    
 
     saveHandler() {
       this.$refs.ruleForm.validate((valid) => {
@@ -927,19 +925,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,
                   }
                 }

+ 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('请选择账户')
       }

+ 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('请选择账户')
       }

+ 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) {

+ 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 - 1
src/views/modules/workBench/placeOrder.vue

@@ -698,7 +698,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://api.tjyourong.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

+ 0 - 1
vue.config.js

@@ -87,7 +87,6 @@ module.exports = {
         target:'http://139.186.151.174:8804', //测试
 
 
-
         ws: false,
 
         changeOrigin: true,