Browse Source

Merge branch 'master' of http://git.tjyourong.com.cn/ctop/adsp-vue

zhuxinbo 4 years ago
parent
commit
d2d5ba4229

+ 48 - 9
src/views/modules/BatchCreate/TouTiaoBatch.vue

@@ -152,6 +152,7 @@
                     :pagination="ipagination"
                     :loading="loading"
                     @change="sort"
+                    
                 >
                     <template slot="name" slot-scope="text,record">
                         <a href="javascript:;" @click="goNextPage(record)">
@@ -310,7 +311,7 @@
 <script>
 import moment from 'moment';
 import { getAction, postAction, downFile, downFilePost } from '@/api/manage';
-import { JeecgListMixin } from '@/mixins/ipagination'
+// import { JeecgListMixin } from '@/mixins/ipagination'
 import editableCell from './editableCell'
 import Treeselect from '@/views/modules/Statistics/components/Treeselect.vue'
 import qs from 'qs'
@@ -580,9 +581,27 @@ export default {
         editableCell,
         Treeselect,
     },
-    mixins: [JeecgListMixin],
+    // mixins: [JeecgListMixin],
     data() {
         return {
+            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;
+                }
+            },
             currentGroup:{},
             currentPlan:{},           
 
@@ -681,6 +700,7 @@ export default {
                     startDate:this.dateString[0],
                     endDate:this.dateString[1],
                     pageNo:this.ipagination.current,
+                    pageSize:this.ipagination.pageSize,
                     campaignId:item.id
                 })
 
@@ -700,7 +720,8 @@ export default {
                     status:this.statusValue,
                     startDate:this.dateString[0],
                     endDate:this.dateString[1],
-                    pageNo:this.ipagination.current
+                    pageNo:this.ipagination.current,
+                    pageSize:this.ipagination.pageSize,
                 })
                 let planInfo=JSON.stringify([item])
                 localStorage.setItem('planInfo',planInfo)
@@ -718,6 +739,7 @@ export default {
                 startDate:this.dateString[0],
                 endDate:this.dateString[1],
                 pageNo:this.ipagination.current,
+                pageSize:this.ipagination.pageSize,
                 campaignId:this.currentGroup.id
             })
         },
@@ -732,6 +754,7 @@ export default {
                 startDate:this.dateString[0],
                 endDate:this.dateString[1],
                 pageNo:this.ipagination.current,
+                pageSize:this.ipagination.pageSize,
                 planId:this.currentPlan.id,
             })
         },
@@ -793,6 +816,7 @@ export default {
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
                         pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                         
                     });
                 }else if(key=='plan'){
@@ -803,6 +827,7 @@ export default {
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
                         pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                         campaignId:this.currentGroup.id
                     })
 
@@ -815,7 +840,8 @@ export default {
                         status:this.statusValue,
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
-                        pageNo:this.ipagination.current
+                        pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                       });
                 }
             }
@@ -887,7 +913,8 @@ export default {
                         status:this.statusValue,
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
-                        pageNo:this.ipagination.current
+                        pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                     })
                 }else if(this.tabkey=='plan'){
                     this.columns=planColumns;
@@ -898,6 +925,7 @@ export default {
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
                         pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                         campaignId:this.currentGroup.id
                     })
                 }else if(this.tabkey=='idea'){
@@ -909,6 +937,7 @@ export default {
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
                         pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                         planId:this.currentPlan.id,
                     })
                 }
@@ -927,6 +956,8 @@ export default {
         sort(pagination, filters, sorter, { currentDataSource }){
             
             this.ipagination.current=pagination.current;
+
+            this.ipagination.pageSize=pagination.pageSize;
             this.search()
         },
         //重置按钮事件
@@ -957,7 +988,9 @@ export default {
                                 status:this.statusValue,
                                 startDate:this.dateString[0],
                                 endDate:this.dateString[1],
-                                pageNo:this.ipagination.current
+                                pageNo:this.ipagination.current,
+                                pageSize:this.ipagination.pageSize,
+                                
                             })
                             this.$message.success(res.message)
                     }else{
@@ -993,6 +1026,7 @@ export default {
                                 startDate:this.dateString[0],
                                 endDate:this.dateString[1],
                                 pageNo:this.ipagination.current,
+                                pageSize:this.ipagination.pageSize,
                                 planId:this.currentPlan.id,
                                 
                             })
@@ -1050,7 +1084,8 @@ export default {
                         status:this.statusValue,
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
-                        pageNo:this.ipagination.current
+                        pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                     })
                 }else{
                     this.loading=false
@@ -1264,6 +1299,7 @@ export default {
                             startDate:this.dateString[0],
                             endDate:this.dateString[1],
                             pageNo:this.ipagination.current,
+                            pageSize:this.ipagination.pageSize,
                             campaignId:this.currentGroup.id
                         })
                     }
@@ -1287,6 +1323,7 @@ export default {
                         startDate:this.dateString[0],
                         endDate:this.dateString[1],
                         pageNo:this.ipagination.current,
+                        pageSize:this.ipagination.pageSize,
                         campaignId:this.currentGroup.id
                     })
                     this.$message.error(res.message)
@@ -1339,7 +1376,8 @@ export default {
                                         status:this.statusValue,
                                         startDate:this.dateString[0],
                                         endDate:this.dateString[1],
-                                        pageNo:this.ipagination.current
+                                        pageNo:this.ipagination.current,
+                                        pageSize:this.ipagination.pageSize,
                                     })
                                 }
                             })
@@ -1381,6 +1419,7 @@ export default {
                                     startDate:this.dateString[0],
                                     endDate:this.dateString[1],
                                     pageNo:this.ipagination.current,
+                                    pageSize:this.ipagination.pageSize,
                                     campaignId:this.currentGroup.id
                                 })
                             }
@@ -1487,7 +1526,7 @@ export default {
         accountHttp(){
             this.treeData=[];
             this.accountID=undefined;
-            getAction('/ctop/projectMember/getProjectAccountByUserId', {}).then(res => {
+            getAction('/ctop/projectMember/getProjectAccountByUserId?mediaType=1', {}).then(res => {
             if(res.success){
                     // console.log(res);
                     if(res.result){

+ 1 - 1
src/views/modules/BatchCreate/components/Treeselect.vue

@@ -178,7 +178,7 @@
         // })
         this.options=[];
         this.accountID=undefined;
-            getAction('/ctop/projectMember/getProjectAccountByUserId', {}).then(res => {
+            getAction('/ctop/projectMember/getProjectAccountByUserId?mediaType=1', {}).then(res => {
                 if(res.success){
                     // console.log(res);
                     if(res.result){

+ 1 - 1
src/views/modules/BatchCreate/directedPackage.vue

@@ -167,7 +167,7 @@ export default {
         accountHttp(){
             this.treeData=[];
             this.accountID=undefined;
-            getAction('/ctop/projectMember/getProjectAccountByUserId', {}).then(res => {
+            getAction('/ctop/projectMember/getProjectAccountByUserId?mediaType=1', {}).then(res => {
             if(res.success){
                     // console.log(res);
                 if(res.result){

+ 1 - 1
src/views/modules/BatchCreate/newGroup.vue

@@ -174,7 +174,7 @@ export default {
         accountHttp(){
             this.treeData=[];
             this.accountID=undefined;
-            getAction('/ctop/projectMember/getProjectAccountByUserId', {}).then(res => {
+            getAction('/ctop/projectMember/getProjectAccountByUserId?mediaType=1', {}).then(res => {
             if(res.success){
                     // console.log(res);
                     if(res.result){

File diff suppressed because it is too large
+ 1529 - 0
src/views/modules/Statistics/KSAccountReport.vue


+ 29 - 24
src/views/modules/Statistics/accountReport.vue

@@ -253,7 +253,7 @@
                 
             </a-table>
      </div>
-      <customColumn :visible='visible'  :listNum='listNum' :fiexColumn='columnsFixd'  @closeCustomColumn='closeCustomColumn' @changeColumn='changeColumn' />
+      <customColumn :visible='visible'  :listNum='listNum' :fiexColumn='columnsFixd' :mediaType='1'  @closeCustomColumn='closeCustomColumn' @changeColumn='changeColumn' />
   </div>
 </template>
 
@@ -347,6 +347,8 @@ const columnsFixd = [
     scopedSlots: { customRender: 'date' },
     align: 'center',
     key:'date',
+    width:150,
+    fixed:'left',
     // customRender: (value, row, index) => {
     //   const obj = {
     //     children: value,
@@ -368,16 +370,18 @@ const columnsFixd = [
     dataIndex: 'accountId',
     align: 'center',
     width: 150,
+    fixed:'left',
     scopedSlots: { customRender: 'accountId' }
   },
   {
     title: '账户昵称',
     dataIndex: 'authName',
     align: 'center',
-   
+    width: 250,
+    fixed:'left',
   },
   {
-    title: '消耗',
+    title: '消耗(元)',
     dataIndex: 'cost',
     scopedSlots: { customRender: 'cost' },
     align: 'center',
@@ -408,21 +412,21 @@ const columnsFixd = [
     sorter: (a,b)=>{}
   },
   {
-        title: '平均千次展现费用(元)',
-        dataIndex: 'cpm',
-        tip: '广告平均每一千次展现所付出的费用,计算公式是:总花费/展示数*1000',
-        align: 'center',
-      
-        scopedSlots: { customRender: 'cpm' },
-        sorter: (a,b)=>{}
+    title: '平均千次展现费用(元)',
+    dataIndex: 'cpm',
+    tip: '广告平均每一千次展现所付出的费用,计算公式是:总花费/展示数*1000',
+    align: 'center',
+  
+    scopedSlots: { customRender: 'cpm' },
+    sorter: (a,b)=>{}
   },
   {
-        title: '平均点击单价(元)',
-        dataIndex: 'cpc',
-        tip: '广告主为每次点击付出的费用成本,计算公式是:总花费/点击数',
-        align: 'center',   
-        scopedSlots: { customRender: 'cpc' },
-        sorter: (a,b)=>{}
+    title: '平均点击单价(元)',
+    dataIndex: 'cpc',
+    tip: '广告主为每次点击付出的费用成本,计算公式是:总花费/点击数',
+    align: 'center',   
+    scopedSlots: { customRender: 'cpc' },
+    sorter: (a,b)=>{}
   }
 ]
 
@@ -836,7 +840,7 @@ export default {
    accountHttp(){
      this.treeData=[];
      this.treeValue=[];
-     getAction('/ctop/projectMember/getProjectAccountByUserId', {}).then(res => {
+     getAction('/ctop/projectMember/getProjectAccountByUserId?mediaType=1', {}).then(res => {
        if(res.success){
             // console.log(res);
             if(res.result){
@@ -1166,7 +1170,7 @@ export default {
     changeColumn(val){
         this.columns=[...val];
         if(this.columns.length> this.columnsFixd.length){
-              this.scrollX=200*(this.columns.length-this.columnsFixd.length)
+              this.scrollX=2000+200*(this.columns.length-this.columnsFixd.length)
         }else{
           this.scrollX=0
         }
@@ -1176,8 +1180,8 @@ export default {
         //   console.log(this.listNum.length, this.columns)
 
         if (this.listNum.length >= 9 || this.columns.length >= 9) {
-          this.tableWidth = 120
-          this.scrollX = this.columns.length * 120
+          this.tableWidth = 160
+          this.scrollX = this.columns.length * 160
           // console.log(this.scrollX)
         } else {
           this.scrollX = 0
@@ -1346,7 +1350,8 @@ export default {
     padding: 15px  15px;
     position: relative;
     
-    margin: 20px 15px 15px;
+    // margin: 20px 15px 15px;
+    margin-bottom: 15px;
     
     background-color: #fff;
     // border: 1px solid #ccc;
@@ -1378,7 +1383,7 @@ export default {
     width: 100%;
     display: flex;
     justify-content: space-between;
-    padding: 0px 15px;
+    // padding: 0px 15px;
     box-sizing: border-box;
 
     .showBox {
@@ -1439,12 +1444,12 @@ export default {
   }
   .chartBox{
     background-color: #fff;
-    margin: 15px 15px;
+    margin: 15px 0px;
     padding: 2px 10px 30px;
   }
   .tableBox{
     background-color: #fff;
-    margin: 15px 15px;
+    margin: 15px 0px;
     padding: 15px 10px;
     .tableTop{
       position: relative;

+ 24 - 4
src/views/modules/Statistics/components/customColumn.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="customColumn">
+  <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>
@@ -11,11 +11,25 @@
           <p>可添加的列</p>
           <div class="selectionList">
             <!--  v-for="(item,index) in addColumns" :key="index" -->
-            <selectComponent
+            <!-- <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">
@@ -52,11 +66,13 @@
 
 <script>
 import selectComponent from './selectComponent'
+import selectComponentKS from './selectComponentKS'
 export default {
   components: {
-    selectComponent
+    selectComponent,
+    selectComponentKS,
   },
-  props: ['visible', 'listNum', 'fiexColumn'],
+  props: ['visible', 'listNum', 'fiexColumn','mediaType'],
 
   data() {
     return {
@@ -74,6 +90,7 @@ export default {
     },
     listNum: {
       handler(newValue, oldValue) {
+        console.log(newValue, oldValue)
         this.mylistNum = newValue
       },
       immediate: true
@@ -184,6 +201,8 @@ export default {
 </script>
 
 <style lang="scss" scoped>
+
+
 .addlist {
   float: left;
   width: 70%;
@@ -271,4 +290,5 @@ export default {
     }
   }
 }
+
 </style>

+ 28 - 8
src/views/modules/Statistics/components/selectComponent.vue

@@ -14,7 +14,8 @@
         <!-- {{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" name="type" @change="checkboxClick(zhi)">
+
+            <a-checkbox :value="zhi.dataIndex" :disabled="zhi.disabled"  name="type" @change="checkboxClick(zhi)">
               <a-tooltip
                 class="select-component"
                 placement="top"
@@ -30,14 +31,14 @@
 </template>
 
 <script>
-import  customFields  from '../../columnConst/accountConst'
+import  {TTcustomFields ,KScustomFields}  from '../../columnConst/accountConst'
 // let customFields=customFields
 export default {
-  props: ['showCol','fixedCol'],
+  props: ['showCol','fixedCol','mediaType'],
   data() {
     return {
         // customFields,
-      customFields:[...customFields],
+      customFields:[],
       quanxuanflag: [],
       hovered: false,
       tooltipShow: 'tooltipShow',
@@ -47,7 +48,7 @@ export default {
   watch: {
     
     showCol(n) {
-      console.log(n)
+      // console.log(n)
       //
       if (this.showCol.length == this.fixedCol.length) {
 
@@ -84,10 +85,18 @@ export default {
         })
       }
       // console.log(this.form)
-    }
+    },
+  
   },
   mounted() {
-    for (let i = 0; i < customFields.length; i++) {
+    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)
@@ -100,8 +109,19 @@ export default {
         })
       })
     })
+    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)
+    // console.log(this.customFields);
+    
   },
   methods: {
     hide() {

+ 240 - 0
src/views/modules/Statistics/components/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 '../../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>

+ 26 - 61
src/views/modules/Statistics/dataDisplayStatistics.vue

@@ -204,11 +204,14 @@ th div {
             :columns="columns"
             :dataSource="data"
             bordered
-            id="outTable"
             :pagination="false"
             :scroll="{ x: scrollX }"
+            ref="accountTable"
+            :width="tableWidth"
+            
+            style="word-break: break-all;font-size:16px;font-weight:600"
           ></a-table>
-          <!-- <customColumn :visible='visible'  :listNum='listNum' :fiexColumn='columnsFixd'  @closeCustomColumn='closeCustomColumn' @changeColumn='changeColumn' /> -->
+          <!-- <customColumn :visible='visible'  :listNum='listNum' :fiexColumn='columnsFixd' :mediaType='2'   @closeCustomColumn='closeCustomColumn' @changeColumn='changeColumn' /> -->
         </a-card>
       </a-col>
     </a-row>
@@ -428,12 +431,13 @@ const columns = [
 ]
 
 
-const columnsWu = [
+const columnsFixd = [
   {
     title: '时间',
     dataIndex: 'date',
     align: 'center',
     width: 150,
+    fixed:'left',
     customRender: function(text, record, index) {
       const obj = {
         children: text,
@@ -455,7 +459,8 @@ const columnsWu = [
     title: '账户Id',
     dataIndex: 'accountId',
     align: 'center',
-    width: 150,
+    width: 200,
+    fixed:'left',
     customRender: function(text, record, index) {
       const obj = {
         children: text,
@@ -482,7 +487,8 @@ const columnsWu = [
     dataIndex: 'accountName',
     scopedSlots: { customRender: 'cost' },
     align: 'center',
-    width: 150,
+    width: 250,
+    fixed:'left',
     customRender: function(text, record, index) {
       const obj = {
         children: text,
@@ -536,68 +542,25 @@ const columnsWu = [
     dataIndex: 'photoClickRatio',
     align: 'center'
   },
-  {
-    title: 'cvr',
-    dataIndex: 'cvr',
-    align: 'center'
-  },
-  {
-    title: 'cpm(¥)',
-    dataIndex: 'cpm',
-    align: 'center'
-  },
+  
   {
     title: '行为数',
     dataIndex: 'bClick',
     align: 'center'
   },
   {
-    title: '转化数',
-    dataIndex: 'formCount',
-    align: 'center'
-  },
-  {
-    title: '折前转化单价(¥)',
-    dataIndex: 'beforeFormPrice',
-    align: 'center'
-  },
-  {
-    title: '折后转化单价(¥)',
-    dataIndex: 'afterFormPrice',
-    align: 'center'
-  },
-
-  {
-    title: '注册数',
-    dataIndex: 'eventRegister',
+    title: '行为率',
+    dataIndex: 'bClicks',
     align: 'center'
   },
   {
-    title: '注册成本(¥)',
-    dataIndex: 'eventRegisterCost',
+    title: '平均千次封面曝光花费',
+    dataIndex: 'CPM',
     align: 'center'
   },
-  {
-    title: '单价区间',
-    dataIndex: 'price',
-    align: 'center',
-    customRender: function(text, record, index) {
-      const obj = {
-        children: text,
-        attrs: {}
-      }
-      for (let i = 0; i < length; i++) {
-        if (index == 0 && i == 0) {
-          obj.attrs.rowSpan = length
-        } else {
-          if (index == i) {
-            obj.attrs.rowSpan = 0
-          }
-        }
-      }
-      return obj
-    }
-  }
+  
+  
+  
 ]
 export default {
   name: 'data-display-statistics',
@@ -616,7 +579,8 @@ export default {
       title: '账户数据展示',
       show: true,
       data: [],
-      columns:columnsWu,
+      columns:JSON.parse(JSON.stringify(columnsFixd)),
+      columnsFixd,
       options: [],
       list: [],
       appId: [],
@@ -678,7 +642,8 @@ export default {
       statDate: '',
       visible:false,//自定义页面的打开
        listNum:[],
-       scrollX:0,
+       scrollX:2000,
+       tableWidth:'',
     }
   },
   filters: {
@@ -713,7 +678,7 @@ export default {
     changeColumn(val){
         this.columns=[...val];
         if(this.columns.length> this.columnsFixd.length){
-              this.scrollX=200*(this.columns.length-this.columnsFixd.length)
+              this.scrollX=2000+200*(this.columns.length-this.columnsFixd.length)
         }else{
           this.scrollX=0
         }
@@ -723,8 +688,8 @@ export default {
         //   console.log(this.listNum.length, this.columns)
 
         if (this.listNum.length >= 9 || this.columns.length >= 9) {
-          this.tableWidth = 120
-          this.scrollX = this.columns.length * 120
+          this.tableWidth = 160
+          this.scrollX = this.columns.length * 160
           // console.log(this.scrollX)
         } else {
           this.scrollX = 0

+ 50 - 6
src/views/modules/Statistics/materialRank.vue

@@ -24,9 +24,12 @@
       </a-radio-group>
       <div class="btn">
         <a-button type='primary' @click="getData">查询</a-button>
+        <a-button type='primary' @click="exportExcel" style="margin-left:20px">导出报表</a-button>
+
       </div>
     </div>
-    <a-table :columns="columns" :data-source="dataSource" tableLayout='auto' bordered :pagination='false' :loading='loading'>
+    <div class="tableBody">
+      <a-table :columns="columns" :data-source="dataSource" tableLayout='auto' bordered :pagination='false' :loading='loading'>
       <div slot="videoU" slot-scope="test,records">
         <img :src="records.coverUrl" alt="" style="width:140px"
           @click="openVideo(records.url)">
@@ -43,6 +46,8 @@
         showQuickJumper :pageSize.sync="ipagination.pageSize" :total="ipagination.total" v-model="ipagination.current"
         @change="getDataSource" /> -->
     </div>
+    </div>
+    
     <a-modal v-model="Videovisible" title="视频详情" @ok="videoOk" :footer="null" width='50%'>
       <video @click.stop class="video" :src="videoUrl" controls="controls" style="height:600px;width:100%">您的浏览器不支持
         video 标签。</video>
@@ -219,6 +224,42 @@
     },
     methods: {
       moment,
+        //导出报表
+        exportExcel() {
+           
+            // var name = this.data.filter(item => {
+            //     return item.signature == this.signature
+            // })[0].projectName
+            let companyName=''
+            if(this.company){
+                this.selectOption.company.forEach((item)=>{
+                    if(item.companyId==this.company){
+                        companyName=item.area
+                    }
+                   
+                })
+            }
+            var name =`${ this.dateStr[0]}~${this.dateStr[1]}`;
+            
+            downFilePost(`/ctop/material/top//excel?target=${this.target}&order=${this.order}`, {
+            startDate: this.dateStr[0],
+            endDate: this.dateStr[1],
+
+          }).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 = name+'.xlsx'    //下载后文件名
+                document.body.appendChild(downloadElement)
+                downloadElement.click() //点击下载
+                document.body.removeChild(downloadElement) //下载完成移除元素
+                window.URL.revokeObjectURL(href) //释放掉blob对象
+            })
+        },
+
       // 查看相关人员
       showRelevantPeople(record){
         this.relevantPeopleVisible=true;
@@ -321,17 +362,17 @@
   .materialRank {
     width: 100%;
     height: 100%;
-    background: #fff;
-    padding: 10px 15px;
+    
+    // padding: 10px 15px;
   }
 
   .optionLine {
     padding: 30px 5px;
     position: relative;
     margin-top: 20px;
-    ;
+    background: #fff;
     margin-bottom: 15px;
-    border: 1px solid #ccc;
+    // border: 1px solid #ccc;
 
     span {
       display: inline-block;
@@ -350,7 +391,10 @@
       top: 30px;
     }
   }
-
+  .tableBody{
+    background: #fff;
+    padding: 20px 15px;
+  }
   .fenye {
     margin: 30px 15px 10px;
     overflow: hidden;

+ 432 - 2
src/views/modules/columnConst/accountConst.js

@@ -1,4 +1,7 @@
-let customFields=  [
+
+
+
+ export const TTcustomFields= [
     {
       id: 0,
       title: '展现数据',
@@ -886,8 +889,435 @@ let customFields=  [
         // }
       ]
     }
+  ];
+
+  export const KScustomFields= [
+    {
+      id: 0,
+      title: '展现数据',
+      checkall: false,
+      form:[],
+      specificFields: [
+        {
+          title: '消耗(元)',
+          dataIndex: 'cost',
+          width:150,
+          tip: '广告在投放期间的花费总额',
+          align: 'center',
+          scopedSlots: { customRender: 'cost' },
+          sorter: () => {}
+        },
+        {
+          title: '封面曝光数',
+          dataIndex: 'photoShow',
+          tip: '广告在瀑布流被观看次数',
+          align: 'center',       
+          scopedSlots: { customRender: 'photoShow' },
+          sorter:() => {}
+        },
+        {
+          title: '封面点击数',
+          dataIndex: 'photoClick',
+          tip: '用户点击封面进入视频播放页的次数(数据会进行反作弊去重)',
+          align: 'center',
+        
+          scopedSlots: { customRender: 'photoClick' },
+          sorter: () => {}
+        },
+        {
+          title: '素材曝光数',
+          dataIndex: 'aClick',
+          tip: '用户进入视频播放页观看的次数(数据会进行反作弊去重)',
+          align: 'center',
+       
+          scopedSlots: { customRender: 'aClick' },
+          sorter:() => {}
+        },
+        {
+          title: '行为数',
+          dataIndex: 'bClick',
+          tip: '用户在视频播放页单击转化按钮的次数/展示数*100%',
+          align: 'center',
+        
+          scopedSlots: { customRender: 'bClick' },
+          sorter:() => {}
+        },
+        {
+          title: '封面点击率',
+          dataIndex: 'clickRate',
+          tip: '封面点击数占封面展示数百分比',
+          align: 'center',    
+          scopedSlots: { customRender: 'clickRate' },
+          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:() => {}
+        },
+      ]
+    },
+    {
+      id: 1,
+      title: '应用下载数据',
+      checkall: false,
+      form:[],
+      specificFields: [
+        {
+          title: '安卓下载开始数',
+          dataIndex: 'downloadStart',
+          width:150,
+          tip: '安卓端调起下载器并开始下载的次数',
+          align: 'center',
+          scopedSlots: { customRender: 'downloadStart' },
+          sorter: () => {}
+        },
+        {
+          title: '安卓下载开始率',
+          dataIndex: 'downloadStartRate',
+          tip: '安卓下载开始数/行为数',
+          align: 'center',       
+          scopedSlots: { customRender: 'downloadStartRate' },
+          sorter:() => {}
+        },
+        {
+          title: '安卓下载开始单价(元)',
+          dataIndex: 'downloadStartCost',
+          tip: '花费/安卓下载开始数',
+          align: 'center',
+        
+          scopedSlots: { customRender: 'downloadStartCost' },
+          sorter: () => {}
+        },
+        {
+          title: '安卓下载完成数',
+          dataIndex: 'downloadFinish',
+          tip: '安卓端调起下载器并完成下载的次数',
+          align: 'center',
+       
+          scopedSlots: { customRender: 'downloadFinish' },
+          sorter:() => {}
+        },
+        {
+          title: '安卓下载完成率',
+          dataIndex: 'downloadFinishRate',
+          tip: '安卓下载完成数/安卓下载开始数',
+          align: 'center',
+        
+          scopedSlots: { customRender: 'downloadFinishRate' },
+          sorter:() => {}
+        },
+        {
+          title: '安卓下载完成单价(元)',
+          dataIndex: 'downloadFinishCost',
+          tip: '花费/安卓下载完成数',
+          align: 'center',    
+          scopedSlots: { customRender: 'downloadFinishCost' },
+          sorter:() => {}
+        },
+        {
+          title: '激活数',
+          dataIndex: 'active',
+          tip: '广告主回传的应用激活次数',
+          align: 'center',    
+          scopedSlots: { customRender: 'active' },
+          sorter:() => {}
+        },
+        {
+          title: '激活单价',
+          dataIndex: 'activeCost',
+          tip: '花费/激活数',
+          align: 'center',    
+          scopedSlots: { customRender: 'activeCost' },
+          sorter:() => {}
+        },
+        {
+          title: '下载完成激活率',
+          dataIndex: 'activeRate',
+          tip: '激活数/安卓下载完成数',
+          align: 'center',    
+          scopedSlots: { customRender: 'activeRate' },
+          sorter:() => {}
+        },
+        {
+          title: '首日付费次数',
+          dataIndex: 'firstDayPay',
+          tip: '当日激活的用户在当天产生的付费行为次数',
+          align: 'center',    
+          scopedSlots: { customRender: 'firstDayPay' },
+          sorter:() => {}
+        },
+        {
+          title: '首日付费金额',
+          dataIndex: 'firstDayPayAmount',
+          tip: '当日激活的用户在当天产生的付费行为所带来的付费金额',
+          align: 'center',    
+          scopedSlots: { customRender: 'firstDayPayAmount' },
+          sorter:() => {}
+        },
+        {
+          title: '首日付费成本',
+          dataIndex: 'firstDayPayCost',
+          tip: '消耗/首日付费次数',
+          align: 'center',    
+          scopedSlots: { customRender: 'firstDayPayCost' },
+          sorter:() => {}
+        },
+        {
+          title: '首日ROI',
+          dataIndex: 'firstDayPayROI',
+          tip: '首日付费金额/当日消耗',
+          align: 'center',    
+          scopedSlots: { customRender: 'firstDayPayROI' },
+          sorter:() => {}
+        },
+        {
+          title: '付费次数',
+          dataIndex: 'eventPay',
+          tip: '当日回传的付费行为次数',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventPay' },
+          sorter:() => {}
+        },
+        {
+          title: '付费金额',
+          dataIndex: 'eventPayPurchaseAmount',
+          tip: '当日回传的付费行为所带来的付费金额',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventPayPurchaseAmount' },
+          sorter:() => {}
+        },
+        {
+          title: '付费次数成本',
+          dataIndex: 'eventPayCost',
+          tip: '消耗/付费次数',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventPayCost' },
+          sorter:() => {}
+        },
+        {
+          title: 'ROI',
+          dataIndex: 'ROI',
+          tip: '付费金额/当日消耗',
+          align: 'center',    
+          scopedSlots: { customRender: 'ROI' },
+          sorter:() => {}
+        },
+        {
+          title: '注册数',
+          dataIndex: 'register',
+          tip: '付费金额/当日消耗',
+          align: 'center',    
+          scopedSlots: { customRender: 'register' },
+          sorter:() => {}
+        },
+        {
+          title: '注册成本',
+          dataIndex: 'activeRegisterCost',
+          tip: '当日消耗/当日回传注册数',
+          align: 'center',    
+          scopedSlots: { customRender: 'activeRegisterCost' },
+          sorter:() => {}
+        },
+        {
+          title: '注册率',
+          dataIndex: 'activeRegisterRate',
+          tip: '当日回传注册数/当日激活数',
+          align: 'center',    
+          scopedSlots: { customRender: 'activeRegisterRate' },
+          sorter:() => {}
+        },
+          // {
+          //   title: '次留数',
+          //   dataIndex: 'nextDayOpen',
+          //   tip: '前一日激活用户在次日继续访问的PV',
+          //   align: 'center',    
+          //   scopedSlots: { customRender: 'nextDayOpen' },
+          //   sorter:() => {}
+          // },
+          // {
+          //   title: '次留成本',
+          //   dataIndex: 'nextDayOpenCost',
+          //   tip: '消耗/次日留存PV',
+          //   align: 'center',    
+          //   scopedSlots: { customRender: 'nextDayOpenCost' },
+          //   sorter:() => {}
+          // },
+          // {
+          //   title: '次留率',
+          //   dataIndex: 'nextDayOpenRate',
+          //   tip: '前一日激活用户在次日继续访问的PV/前一日激活数',
+          //   align: 'center',    
+          //   scopedSlots: { customRender: 'nextDayOpenRate' },
+          //   sorter:() => {}
+          // },
+        {
+          title: '完件数',
+          dataIndex: 'eventJinJianApp',
+          tip: '当日回传完件数',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventJinJianApp' },
+          sorter:() => {}
+        },
+        {
+          title: '完件成本',
+          dataIndex: 'eventJinJianAppCost',
+          tip: '当日消耗/当日回传完件数',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventJinJianAppCost' },
+          sorter:() => {}
+        },
+        {
+          title: '授信数',
+          dataIndex: 'eventCreditGrantApp',
+          tip: '当日回传授信数',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventCreditGrantApp' },
+          sorter:() => {}
+        },
+        {
+          title: '授信成本',
+          dataIndex: 'eventCreditGrantAppCost',
+          tip: '当日消耗/当日回传授信数',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventCreditGrantAppCost' },
+          sorter:() => {}
+        },
+        {
+          title: '授信率',
+          dataIndex: 'eventCreditGrantAppRate',
+          tip: '当日回传授信数/当日回传的完件数',
+          align: 'center',    
+          scopedSlots: { customRender: 'eventCreditGrantAppRate' },
+          sorter:() => {}
+        },
+      ]
+    },
+    {
+      id: 2,
+      title: '落地页数据',
+      checkall: false,
+      form:[],
+      specificFields: [
+        {
+          title: '表单提交数',
+          dataIndex: 'formCount',
+          tip: '当日回传表单数',
+          align: 'center',
+          scopedSlots: { customRender: 'formCount' },
+          sorter: () => {}
+        },
+        {
+          title: '表单提交点击率',
+          dataIndex: 'formCountRate',         
+          tip: '当日回传表单数/当日行为数',
+          align: 'center',
+          scopedSlots: { customRender: 'formCountRate' },
+          sorter: () => {}
+        },
+        {
+          title: '表单提交单价',
+          dataIndex: 'formCountCost',         
+          tip: '当日消耗/当日回传表单数',
+          align: 'center',
+          scopedSlots: { customRender: 'formCountCost' },
+          sorter: () => {}
+        },
+        {
+          title: '落地页完件数',
+          dataIndex: 'eventJinJianLandingPage',         
+          tip: '当日回传完件数',
+          align: 'center',
+          scopedSlots: { customRender: 'eventJinJianLandingPage' },
+          sorter: () => {}
+        },
+        {
+          title: '落地页完件成本',
+          dataIndex: 'eventJinJianLandingPageCost',         
+          tip: '当日消耗/当日回传完件数',
+          align: 'center',
+          scopedSlots: { customRender: 'eventJinJianLandingPageCost' },
+          sorter: () => {}
+        },
+        {
+          title: '落地页授信数',
+          dataIndex: 'eventCreditGrantLandingPage',         
+          tip: '当日回传授信数',
+          align: 'center',
+          scopedSlots: { customRender: 'eventCreditGrantLandingPage' },
+          sorter: () => {}
+        },
+        {
+          title: '落地页授信成本',
+          dataIndex: 'eventCreditGrantLandingPageCost',         
+          tip: '当日消耗/当日回传授信数',
+          align: 'center',
+          scopedSlots: { customRender: 'eventCreditGrantLandingPageCost' },
+          sorter: () => {}
+        },
+        {
+          title: '落地页授信率',
+          dataIndex: 'eventCreditGrantLandingPageRate',         
+          tip: '当日回传授信数/当日回传的完件数',
+          align: 'center',
+          scopedSlots: { customRender: 'eventCreditGrantLandingPageRate' },
+          sorter: () => {}
+        },
+        {
+          title: '按钮点击数',
+          dataIndex: 'submit',         
+          tip: '用户当日点击按钮的次数',
+          align: 'center',
+          scopedSlots: { customRender: 'submit' },
+          sorter: () => {}
+        },
+        {
+          title: '按钮点击率',
+          dataIndex: 'submitRate',         
+          tip: '当日按钮点击数 / 当日行为数',
+          align: 'center',
+          scopedSlots: { customRender: 'submitRate' },
+          sorter: () => {}
+        },
+        {
+          title: '按钮点击成本',
+          dataIndex: 'submitCost',         
+          tip: '当日消耗 / 当日按钮点击数',
+          align: 'center',
+          scopedSlots: { customRender: 'submitCost' },
+          sorter: () => {}
+        },
+      ]
+    }
   ]
 
 
 
- export default customFields
+//  export default { TTcustomFields, KScustomFields }

+ 38 - 14
src/views/modules/kuaishouapp/account/accountIndex.vue

@@ -86,7 +86,7 @@
           </div>
         </a-modal>
         <a-table size="middle" :loading="loadingList" :columns="columns" :dataSource="dataList" bordered
-          :scroll="{ x: 2000 }" :customRow="rowClick" :pagination="ipagination"
+          :scroll="{ x: 2000 }" :customRow="rowClick" :pagination="ipagination" @change="sort"
           :rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }">
           <template slot="campaignName" slot-scope="text, record">
             <div style="display:flex;justify-content: center;">
@@ -346,25 +346,31 @@
         ipagination: {
           current: 1,
           pageSize: 10,
+          //   pageSizeOptions: ['10', '20', '30'],
           showTotal: (total, range) => {
-            return range[0] + '-' + range[1] + ' 共' + total + '条'
+              return range[0] + "-" + range[1] + " 共" + total + "条"
           },
           showQuickJumper: true,
-          onChange: current => {
+          showSizeChanger:true,
+          pageSizeOptions: ['10', '30', '50'],
+          total: 0,
+          onChange: (current, pageSize) => {
+            console.log(current, pageSize)
             // 切换分页时的回调,
             // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
             this.ipagination.current = current
-            if (this.campaignId == '' && this.campaignName == '') {
-              this.addUser()
-            } else {
-              var params = {}
-              params.accountId = this.appId + ''
-              params.pageNo = current
-              params.pageSize = this.ipagination.pageSize
-              params.campaignId = this.campaignId
-              params.campaignName = this.campaignName
-              this.getCampaignList(params)
-            }
+            this.ipagination.pageSize= pageSize
+            // if (this.campaignId == '' && this.campaignName == '') {
+            //   this.addUser()
+            // } else {
+            //   var params = {}
+            //   params.accountId = this.appId + ''
+            //   params.pageNo = this.ipagination.current
+            //   params.pageSize = this.ipagination.pageSize
+            //   params.campaignId = this.campaignId
+            //   params.campaignName = this.campaignName
+            //   this.getCampaignList(params)
+            // }
 
           },
           total: 0
@@ -415,6 +421,24 @@
       }
     },
     methods: {
+       sort(pagination, filters, sorter, { currentDataSource }){
+            
+            this.ipagination.current=pagination.current;
+
+            this.ipagination.pageSize=pagination.pageSize;
+            // this.search()
+            if (this.campaignId == '' && this.campaignName == '') {
+              this.addUser()
+            } else {
+              var params = {}
+              params.accountId = this.appId + ''
+              params.pageNo = this.ipagination.current
+              params.pageSize = this.ipagination.pageSize
+              params.campaignId = this.campaignId
+              params.campaignName = this.campaignName
+              this.getCampaignList(params)
+            }
+      },
       failInfoShow(item) {
         if (item) {
           this.visible = true

+ 15 - 6
src/views/modules/kuaishouapp/account/advertisingGroup.vue

@@ -92,7 +92,7 @@
               :pagination="ipagination" :scroll="{ x: 2500 }" :rowSelection="{
                 selectedRowKeys: selectedRowKeys,
                 onChange: onSelectChange
-              }" style="margin-top:30px" :loading="loadingList">
+              }"   @change="sort"    style="margin-top:30px" :loading="loadingList">
               <!-- getCheckboxProps: getCheckboxProps -->
               <span slot="unitName" slot-scope="text, record" :title="text">
                 <div style="display:flex;justify-content: center;">
@@ -104,7 +104,7 @@
               <span slot="action" slot-scope="text, record">
                 <a-switch v-model="record.showSwich" @change="onChangeSwitch(record)" />
               </span>
-              <span slot="deepConversionType" slot-scope="text,record">{{text|deepConversionType}}</span>
+              <span slot="deepConversionType" slot-scope="text">{{text|deepConversionType}}</span>
               <span slot="actionTwo" slot-scope="text, record">
                 <a @click="editDetail(record)">编辑</a>
                 <a-divider type="vertical" />
@@ -595,18 +595,20 @@
         }),
         ipagination: {
           current: 1,
-          pageSize: 50,
+          pageSize: 10,
           //   pageSizeOptions: ['10', '20', '30'],
           showTotal: (total, range) => {
-            return range[0] + '-' + range[1] + ' 共' + total + '条'
+              return range[0] + "-" + range[1] + " 共" + total + "条"
           },
           showQuickJumper: true,
-          //   showSizeChanger: true,
+          showSizeChanger:true,
+          pageSizeOptions: ['10', '30', '50'],
           total: 0,
-          onChange: current => {
+          onChange: (current, pageSize) => {
             // 切换分页时的回调,
             // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
             this.ipagination.current = current
+            this.ipagination.pageSize= pageSize;
             this.getDataList(this.titleKey)
           }
         },
@@ -739,6 +741,13 @@
       }
     },
     methods: {
+       sort(pagination, filters, sorter, { currentDataSource }){
+            
+            this.ipagination.current=pagination.current;
+
+            this.ipagination.pageSize=pagination.pageSize;
+           this.getDataList(this.titleKey)
+      },
       // getCheckboxProps(record) {
       //   return {
       //     props: {

+ 2 - 2
vue.config.js

@@ -66,10 +66,10 @@ module.exports = {
         // target: 'http://192.168.0.230:8088', //请求本地 需要jeecg-boot后台项目  孙震
         // target: 'http://192.168.1.51:8080', //请求本地 需要jeecg-boot后台项目  毕洁泉
 
-        // target: 'http://192.168.1.51:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
+        target: 'http://192.168.1.51:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.0.252:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.0.170:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
-         target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目 
+        //  target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目 
         // target: 'https://trac.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目 
         // target: 'http://39.106.184.70:8088/', //请求本地 需要jeecg-boot后台项目 
          // target: 'http://adsp.tjyourong.com.cn/', //请求本地 需要jeecg-boot后台项目