Commit eba51d59 authored by agping's avatar agping

修改

parent 068c48f2
//公用js文件
let ServerHost = 'https://pre2.tonglianjituan.com';
//let ServerHost = 'https://pre2.tonglianjituan.com';
let ServerHost = 'https://api.tonglianjituan.com';
if(location.origin === 'https://api.tonglianjituan.com') {
ServerHost = location.origin;
};
......
......@@ -5,20 +5,23 @@
<div v-for="(item, index) in mainData" :key="item.title" :class="{active:index === initTabNumMain}" @click="tabMain(index)">{{item.title}}</div>
</div>
<div class="nav-seat"></div>
<div class="nav-main-choose">
<div v-for="(item, index) in mainDataChoose" :key="item.title" :class="{active:index === initTabNumMainChoose}" @click="tabMainChoose(index)">{{item.title}}</div>
</div>
</nav>
<main class="main-content">
<section v-for="(item, index) in mainData" v-show="index === initTabNumMain">
<pagination-load :canload="!item.isStop" :distance="10" @load="getLoad">
<pagination-load :canload="!item.isStop" :distance="10" @load="getList">
<ul>
<li class="main-sec-li" v-for="(item2, index2) in item.dataList">
<div class="shop-list-img shop-list">
<img :src="item2.api_path + item2.images[0].img_name" alt=""/>
<img-error :datasrc="selesctImg(item2)" :imgtype="'div'"></img-error>
</div>
<div class="shop-list-con shop-list">
<p class="shop-title">{{item2.title}}</p>
<p class="shop-rent">{{item2.rent_type}}</p>
<p>
<span class="shop-lable">{{item2.industry_type}}</span>
<p class="shop-title shop-list-top">{{item2.title}}</p>
<p class="shop-rent shop-list-top">{{selesctRent(item2)}}</p>
<p class="shop-list-top">
<span v-for="(item3, index3) in item2.shop_sign.split(',').splice(0, 3)" class="shop-lable">{{item3}}</span>
</p>
</div>
</li>
......@@ -59,9 +62,18 @@
'noDataFlag': false,//是否是无数据
}
],//请求返回的数据体集合
pageSize: 3,
pageSize: 15,
initTabNumMain: 0,
isLoading: false,//是否正在加载
mainDataChoose:[{
'title': '区域',
}, {
'title': '业态',
}, {
'title': '面积',
}, {
'title': '更多',
}],
}),
created() {
let _this = this;
......@@ -78,10 +90,10 @@
},
mounted() {
let _this = this;
_this.getLoad();
_this.getList();
},
methods: {
getLoad() {
getList() {
let _this = this;
let _index = _this.initTabNumMain;
if(!_this.isLoading && !_this.mainData[_index].isStop) {
......@@ -127,6 +139,31 @@
_this.getList();
};
},
selesctImg(item){
var _img = '';
if(item.images.length == 0){
_img = item.api_path + '';
}else{
_img = item.api_path + item.images[0].img_name;
};
return _img;
},
selesctRent(item){
var _rent_type = '';
if(item.rent_type == 1){
_rent_type ='租金均价:' + item.rent_price + '元/月';
};
if(item.rent_type == 2){
_rent_type ='租金均价:' + item.rent_price + '%';
};
if(item.rent_type == 3){
_rent_type ='租金均价:' + item.rent_price + '元/天/m²';
};
if(item.rent_type == 4){
_rent_type ='租金均价:' + item.rent_price + '元/年';
};
return _rent_type;
},
}
}
</script>
......@@ -182,11 +219,10 @@
.main-sec-li {
background: #fff;
font-size: .3rem;
/*height: 2.4rem;*/
height: 7rem;
padding: .4rem 0;
height: 2.4rem;
box-sizing: border-box;
border-bottom:1px solid #F0F0F0;
padding: .4rem 0;
}
.main-sec-li-26 {
......@@ -199,30 +235,38 @@
}
.main-sec-li .shop-list{
height: 1.6rem;
width: 2.1rem;
}
.shop-list>img{
height: 1.6rem;
width: 2.1rem;
}
.main-sec-li .shop-list-con{
margin-left: .2rem;
margin-left: .24rem;
}
.shop-list-con{
width: 4.2rem;
overflow: hidden;
}
.shop-list-con .shop-title{
font-size: .3rem;
width: 4.6rem;
width: 4.2rem;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
.shop-list-con .shop-rent{
font-size: .26rem;
color: #FF5C50;
}
.shop-list-con .shop-lable{
font-size: .22rem;
padding: .05rem .1rem;
color: #FFA900;
background-color: #FFF4DF;
margin-right: .1rem;
}
.shop-list-top{
margin-top: .12rem;
}
</style>
......@@ -5,7 +5,6 @@
<td>[%= it[item]['create_time'] %]</td>
<td>[%= it[item]['income_time'] %]</td>
<td>[%= it[item]['report_agent_name'] %]-[%= it[item]['report_agent_phone'] %]</td>
<td>[%= it[item]['district_name'] %]</td>
<td>[%= it[item]['store_name'] %]</td>
<td>[%= it[item]['money'] %]</td>
<td>[%= it[item]['real_money'] %]</td>
......
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