Commit ea641c19 authored by youjie's avatar youjie

no message

parent 6cdf8762
......@@ -23,34 +23,44 @@
</el-col>
</el-row>
</div>
<div style="padding: 0 0;background: #ffffff;">
<div style="padding: 0 0 30px 0;background: #ffffff;">
<el-table
v-loading="loading"
:data="dataList"
style="width: 100%"
border
:span-method="objectSpanMethod">
<el-table-column width="150" fixed prop="EmpName" label="姓名"></el-table-column>
<el-table-column width="100" prop="ranking" label="排名">
<template slot="header" slot-scope="scope">
排名
</template>
<template slot-scope="scope">
{{scope.row.ranking}}
</template>
</el-table-column>
<el-table-column width="100" prop="RankName" label="排名"></el-table-column>
<el-table-column :label="i.Name" align="center" v-for="i in PlatformTypeList">
<el-table-column
v-for="item in ModuleTypeList"
v-for="(item,index) in ModuleTypeList" :key="index"
prop="province"
:label="item.Name"
width="80">
<template slot-scope="scope">
<template v-for="items in scope.row.xhs">
<template v-if="item.Name==items.name">
{{items.num}}
</template>
<template v-if="i.Name=='小红书'">
<span v-for="(itemOne,indexs) in scope.row.oneArr" :key="indexs">
<template v-if="index==indexs">
{{itemOne>0?itemOne:''}}
</template>
</span>
</template>
<template v-if="i.Name=='微博'">
<span v-for="(itemOne,indexs) in scope.row.twoArr" :key="indexs">
<template v-if="index==indexs">
{{itemOne>0?itemOne:''}}
</template>
</span>
</template>
<template v-if="i.Name=='抖音'">
<span v-for="(itemOne,indexs) in scope.row.threeArr" :key="indexs">
<template v-if="index==indexs">
{{itemOne>0?itemOne:''}}
</template>
</span>
</template>
</template>
</el-table-column>
</el-table-column>
......@@ -84,7 +94,7 @@
</template>
</el-table-column>
</el-table-column> -->
<el-table-column fixed="right" prop="hj" label="合计"></el-table-column>
<el-table-column fixed="right" prop="TotalNum" label="合计"></el-table-column>
</el-table>
</div>
......@@ -313,28 +323,25 @@
(res) => {
this.loading = false;
if(res.data.data){
if(res.data.data){
let allList = JSON.parse(JSON.stringify(res.data.data))
let RankList = []
let list = []
for(let i = 0;i<allList.length;i++){
allList[i].ranking
let j = 0
for(j;j<allList[i].RankList.length;j++){
allList[i].ranking = j
list.push(allList[i])
console.log(res.data.data)
let List = JSON.parse(JSON.stringify(res.data.data))
for(let j=0;j<List.length;j++){
List[j].oneArr = []
List[j].twoArr = []
List[j].threeArr = []
for(let i = 0;i<List[j].NumList.length;i++){
if(i<5){
List[j].oneArr.push(List[j].NumList[i])
}
if(i>4&&i<10){
List[j].twoArr.push(List[j].NumList[i])
}
if(i>9&&i<15){
List[j].threeArr.push(List[j].NumList[i])
}
}
}
// allList.forEach(item => {
// item.ranking = ''
// for(let i=0;i<2;i++){
// item.ranking = i+1
// }
// list.push(item)
// });
this.dataList = list
console.log(this.dataList)
}
this.dataList = List
}
},
(e) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment