curse.vue 2.02 KB
<template>
<div >
    <div class="finish-wrap">
      <h3 class="box_h3">
        <img :src="kcsz.minicon" alt="" class="circular">
        <span class="circular_title">{{kcsz.title}}</span>
      </h3>        
       <div class="major_title" 
          v-for="(item,index) of kcsz.itemarr" 
          :key="index"
          :style="{backgroundImage: 'url(' + item.imgUrl + ') ', backgroundRepeat:'no-repeat', backgroundPosition:'center center', backgroundSize: '94% 110%'}"
          >
         <h4>{{item.itemtitle}}</h4>
         <ul class="oul">
           <li v-for="(itemsub,subindex) of item.subitemarr" :key="subindex">{{itemsub}}</li>
         </ul>
       </div>
    </div>
</div>
</template>
<script>
import list from '@/assets/json/homecenter.json';

export default {
	name: 'curse',
	components: {},
    data(){
		return {
      homelist: [],
      kcsz:{}
		}
  },
    methods: {
      parseContent(){
         $(".oul li").each(function(index){
          if($(this).text().indexOf("(")>=0){
            $(this).css("color","#666")
          }else if($(this).text().indexOf("工具")>=0 || $(this).text().indexOf("商业分析方法")>=0 || $(this).text().indexOf("商业分析应用")>=0) {
             $(this).css({"font-size":".28rem","padding":".16rem 0","line-height":".28rem","color":"#000"})
          }
         })
      }
    },
    created() {
      this.homelist = list.homecenter.home;
      var index = this.$route.query.index;
      this.kcsz = this.homelist[index].kcsz;
      // this.initWx()  
      this.$share.initWx('/master')

    },
      mounted(){
        this.parseContent()
        document.querySelector('body').setAttribute('style', 'background-color:#F5F9FC;')
    }
}
</script>

<style lang="" scoped>
body{background:#F5F9FC;}
.banner_img{width:100%;}
.major_title{text-align:center;padding:.4rem 0;margin-bottom:.2rem;}
h4{color:#02B5B2;font-size:.36rem;padding-bottom:.16rem;}
li{font-size:.24rem;font-weight:600;line-height: .4rem;letter-spacing: .01rem;}
.back_title{color:red;}
h3.box_h3{padding-top:5%;}
</style>