|
|
@@ -78,19 +78,7 @@ export default {
|
|
|
NewsInfo
|
|
|
},
|
|
|
computed: {
|
|
|
- ...mapState(['userInfo']),
|
|
|
- bgImg() {
|
|
|
- let img = '';
|
|
|
- if (this.active === 0 && this.products.length > 0) {
|
|
|
- img = this.getImg(this.changeImgs(this.products[0].pic));
|
|
|
- }
|
|
|
-
|
|
|
- if (this.active === 1 && this.news.length > 0) {
|
|
|
- img = this.getImg(this.news[0].pic);
|
|
|
- }
|
|
|
-
|
|
|
- return img;
|
|
|
- }
|
|
|
+ ...mapState(['userInfo'])
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
@@ -101,7 +89,8 @@ export default {
|
|
|
loading: false,
|
|
|
finished: false,
|
|
|
page: 0,
|
|
|
- empty: false
|
|
|
+ empty: false,
|
|
|
+ bgImg: ''
|
|
|
};
|
|
|
},
|
|
|
mounted() {
|
|
|
@@ -110,6 +99,9 @@ export default {
|
|
|
StatusBar.styleDefault();
|
|
|
}
|
|
|
this.getInit();
|
|
|
+ this.$http.get('sysConfig/get/home_bg').then(res => {
|
|
|
+ this.bgImg = res.value;
|
|
|
+ });
|
|
|
},
|
|
|
methods: {
|
|
|
getInit() {
|