This commit is contained in:
lmj
2022-09-07 16:53:14 +08:00
parent 4019580230
commit c6781abee3
11 changed files with 586 additions and 7 deletions

View File

@@ -121,10 +121,16 @@
</li>
</ul>
</div>
<div class="course-resources">
资源位
<img :src="fileBaseUrl + resonimg.image" alt="">
</div>
</div>
</div>
</div>
</div>
<el-row :gutter="10">
@@ -154,6 +160,7 @@ import apiUser from '@/api/system/user.js';
import apiSearchterm from '@/api/modules/searchterm.js';
import articleImage from '@/components/Article/articleImage.vue';
import editItems from '@/components/Article/editItems.vue';
import apiPlace from "@/api/modules/place.js"
export default {
name: 'index',
components: { editItems,portalHeader, portalFooter,articleImage, portalFloatTools, interactBar, timeShow, author },
@@ -169,6 +176,7 @@ export default {
},
data() {
return {
resonimg:{},
moreState:1,// 1 加载更多 2 加载中 3无数据
searchRecords: [],
fileBaseUrl: process.env.VUE_APP_FILE_BASE_URL,
@@ -212,11 +220,22 @@ export default {
"scroll",
this.handleScroll
);
this.couresreso();
},
beforeDestroy(){
window.removeEventListener("scroll",this.handleScroll);
},
methods: {
couresreso(){
let key = 'article';
apiPlace.detail(key).then(res=>{
console.log(res)
let lmj = JSON.parse(res.result.content)
// console.log(lmj)
this.resonimg = lmj[0]
console.log(this.resonimg.image)
})
},
emitInput(val){
this.articleList.keyword = val;
this.isSeach =true;
@@ -400,6 +419,13 @@ export default {
</script>
<style scoped lang="scss">
.course-resources{
width: 410px;
img{
width: 100%;
height: 100%;
}
}
.article-banner{
height: 240px;
background: url('/images/article-banner.png');