(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2d0a3cbb"],{"0467":function(e,a,t){"use strict";t.r(a);var n=function(){var e=this,a=e.$createElement,t=e._self._c||a;return t("a-card",{attrs:{bordered:!1}},[t("a-table",{attrs:{rowKey:"rowIndex",bordered:"",columns:e.columns,dataSource:e.dataSource,pagination:e.ipagination},on:{change:e.handleTableChange}})],1)},i=[];function o(e,a,t){return a in e?Object.defineProperty(e,a,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[a]=t,e}var r={name:"TableTotal",data:function(){return{columns:[{title:"#",width:"180px",align:"center",dataIndex:"rowIndex",customRender:function(e,a,t){return"合计"!==e?parseInt(t)+1:e}},{title:"姓名",dataIndex:"name"},{title:"贡献点",dataIndex:"point"},{title:"等级",dataIndex:"level"},{title:"更新时间",dataIndex:"updateTime"}],ipagination:{current:1,pageSize:10,pageSizeOptions:["10","20","30"],showTotal:function(e,a){return a[0]+"-"+a[1]+" 共"+e+"条"},showQuickJumper:!0,showSizeChanger:!0,total:0},dataSource:[{id:"1",name:"张三",point:23,level:3,updateTime:"2019-8-14"},{name:"小王",point:6,level:1,updateTime:"2019-8-13"},{name:"李四",point:53,level:8,updateTime:"2019-8-12"},{name:"小红",point:44,level:5,updateTime:"2019-8-11"},{name:"王五",point:97,level:10,updateTime:"2019-8-10"},{name:"小明",point:33,level:2,updateTime:"2019-8-10"},{name:"小张",point:33,level:2,updateTime:"2019-8-10"},{name:"小六",point:33,level:2,updateTime:"2019-8-10"},{name:"小五",point:33,level:2,updateTime:"2019-8-10"},{name:"小赵",point:33,level:2,updateTime:"2019-8-10"},{name:"李华",point:33,level:2,updateTime:"2019-8-10"},{name:"小康",point:33,level:2,updateTime:"2019-8-10"},{name:"小鹿",point:33,level:2,updateTime:"2019-8-10"}],newArr:[],newDataSource:[]}},mounted:function(){this.newDataSource=this.dataSource,this.dataHandling(this.ipagination.pageSize-1)},watch:{"ipagination.pageSize":function(e){this.dataHandling(e-1)}},methods:{tableAddTotalRow:function(e,a){var t="rowIndex",n=o({},t,"合计");e.forEach((function(e){var i=e.key,o=e.dataIndex;if(![i,o].includes(t)){var r=0;a.forEach((function(e){r+=/^\d+\.?\d?$/.test(e[o])?Number.parseInt(e[o]):Number.NaN})),Number.isNaN(r)&&(r="-"),n[o]=r}})),a.push(n)},handleTableChange:function(e,a,t){this.ipagination=e},dataHandling:function(e){this.newArr=[];for(var a=this.newDataSource.length,t=0,n=0;n<a;n++)n%e===0&&0!==n&&(this.newArr.push(this.newDataSource.slice(t,n)),t=n),n+1===a&&this.newArr.push(this.newDataSource.slice(t,n+1));for(var i=this.newArr,o=0;o<i.length;o++){for(var r=i[o],l={name:"-",updateTime:"-",rowIndex:"合计"},u=0,d=0,p=0;p<r.length;p++)u+=r[p].level,d+=r[p].point;l.level=u,l.point=d,i[o].push(l)}for(var c=[],s=0;s<i.length;s++){var m=i[s];for(var h in m)c.push(m[h])}this.dataSource=Object.values(c)}}},l=r,u=t("2877"),d=Object(u["a"])(l,n,i,!1,null,"bf07d0ec",null);a["default"]=d.exports}}]);