文章排行榜添加个人组织

This commit is contained in:
lmj
2022-10-21 18:39:20 +08:00
parent 57a41194cd
commit 6e71911763

View File

@@ -79,24 +79,25 @@
<p class="ranking-title">贡献榜</p>
<ul class="ranking-data">
<li v-for="(item, index) in ankingList" :key="index" style="margin-top:30px;line-height: 22px;cursor: pointer;">
<router-link :to="'article/detail?id=' + item.id">
<span class="portal-right-text orange-one" v-if="index==0" style="margin-right:94px">
<!-- <router-link :to="'article/detail?id=' + item.id"> -->
<span class="portal-right-text orange-one" v-if="index==0" style="margin-right:25px">
<img :src="`${webBaseUrl}/images/listblue01.png`" alt="">
</span>
<span class="portal-right-text orange-tow" v-if="index==1" style="margin-right:94px">
<span class="portal-right-text orange-tow" v-if="index==1" style="margin-right:25px">
<img :src="`${webBaseUrl}/images/listblue02.png`" alt="">
</span>
<span class="portal-right-text orange-three" v-if="index==2" style="margin-right:94px">
<span class="portal-right-text orange-three" v-if="index==2" style="margin-right:25px">
<img :src="`${webBaseUrl}/images/listblue03.png`" alt="">
</span>
<span class="portal-right-text" v-if="index==3" style="margin-right:94px">
<span class="portal-right-text" v-if="index==3" style="margin-right:25px">
<img :src="`${webBaseUrl}/images/list04.png`" alt="">
</span>
<span class="portal-right-text" v-if="index==4" style="margin-right:94px">
<span class="portal-right-text" v-if="index==4" style="margin-right:25px">
<img :src="`${webBaseUrl}/images/list05.png`" alt="">
</span>
<span class="portal-title-desc">{{ item.sysCreateUname }}</span>
</router-link>
<span class="portal-title-desc">{{ item.sysCreateUname }}<span class="orinfo-text">({{ item.orinfo }})</span> </span>
<!-- {{ item.sysCreateAid }} -->
<!-- </router-link> -->
</li>
</ul>
</div>
@@ -150,6 +151,7 @@ export default {
},
data() {
return {
ankIds:[],
resonimg:{},
moreState:1,// 1 加载更多 2 加载中 3无数据
searchRecords: [],
@@ -390,6 +392,20 @@ export default {
apiArticle.countsUsername(5).then(res => {
if (res.status == 200) {
this.ankingList = res.result;
let ids = [];
this.ankingList.forEach(item =>{
ids.push(item.sysCreateAid);
})
apiUser.getByIds(ids).then(res=>{
res.result.forEach(item=>{
this.ankIds.push(item.orgInfo);
this.ankingList.forEach((value, index) => {
value['orinfo'] = this.ankIds[index];
})
})
// console.log(this.ankingList);
})
}
});
},
@@ -398,6 +414,11 @@ export default {
</script>
<style scoped lang="scss">
.orinfo-text{
font-size: 13px;
color: #666666;
font-weight: 400;
}
.course-resources{
margin-top: 26px;
width:100%;