Feat:千县店铺

This commit is contained in:
LinCyJang
2025-12-14 11:34:20 +08:00
parent f055036001
commit 0292dbd056
2 changed files with 60 additions and 30 deletions
+7
View File
@@ -282,3 +282,10 @@ export function getCityNewsDetail(id) {
export function getCityNewsCategory() {
return request.get('/countyFamous/newsCategory', {}, {login: true})
}
/**
* 获取县城店铺列表
*/
export function getCityShopList(params) {
return request.get('/countyFamous/hotel', params, {login: true})
}
+53 -30
View File
@@ -532,15 +532,15 @@
<view v-if="industryTabIndex === 1">
<view class="card-wrap">
<!-- <image
:src="webUrl + '/page/qianxian/card-bg2.png'"
class="bg"
:src="webUrl + '/page/qianxian/card-bg3.png'"
class="bg bg3"
/> -->
<view class="card-cont">
<view class="tab-wrap">
<view
v-for="(tab, tabIndex) in industryTab"
:key="tabIndex"
:class="industryTabIndex === tabIndex ? 'tab-item1' : ''"
:class="industryTabIndex === tabIndex ? 'tab-item0' : ''"
class="item"
@click="industryTabItemClick(tabIndex)"
>
@@ -551,41 +551,52 @@
{{ tab.name }}
</view>
</view>
<view class="file-wrap" :class="[{'v12-align-center': investmentFileList.length === 0}, {'v12-justify-center': investmentFileList.length === 0}]">
<view v-if="investmentFileList.length > 0" class="file-list">
<view class="list-cont">
<view
v-for="(file, fileIndex) in investmentFileList"
:key="fileIndex"
class="file-item file-item2"
@click="fileItemClick(file)"
>
<view class="name more-t">
·&nbsp;&nbsp;{{ file.title }}
</view>
<view class="village-wrap v12-pt-3">
<view v-if="shopList.length > 0" class="village-list">
<view
v-for="(shop, shopIndex) in shopList"
:key="shopIndex"
class="village-item v12-white"
@click="villageItemClick(shop)"
>
<view class="img-wrap">
<image
:src="webUrl + '/page/qianxian/icon-05.png'"
class="icon"
:src="shop.cover + (shop.coverType === 2 ? '?vframe/jpg/offset/1' : '')"
class="img"
/>
<view class="location">
<image
:src="webUrl + '/page/qianxian/icon-08.png'"
class="icon"
/>
<view class="addr one-t">
{{ shop.address }}
</view>
</view>
</view>
<view class="info">
<view class="intro more-t">
{{ shop.content }}
</view>
<view class="name-wrap">
<image
:src="shop.logo"
class="logo"
/>
<view class="name one-t">
{{ shop.name }}
</view>
</view>
</view>
</view>
</view>
<view v-else class="no-data">暂无招商政策</view>
<view v-else class="no-data">暂无店铺</view>
</view>
</view>
</view>
<view v-if="investmentFileList.length > 0" class="more-btn-wrap">
<view class="more-btn" @click="gotoInvestment('', 'investment')">
更多政策
</view>
</view>
</view>
<view v-if="industryTabIndex === 2">
<view class="card-wrap">
<!-- <image
:src="webUrl + '/page/qianxian/card-bg3.png'"
class="bg bg3"
/> -->
<view class="card-cont">
<view class="tab-wrap">
<view
@@ -864,7 +875,8 @@ import {
getShareImg,
getSaleList,
getJiaLouList,
getCityNewsCategory
getCityNewsCategory,
getCityShopList
} from '@/api/qianxian'
import ProductWindow from '@/components/ProductWindow'
import goCartMixin from '@/mixins/goCartMixins'
@@ -940,7 +952,7 @@ export default {
villageList: [],
industryTab: [
{ name: '项目', icon: '/page/qianxian/icon-04.png' },
{ name: '招商', icon: '/page/qianxian/icon-03.png' },
{ name: '店铺', icon: '/page/qianxian/icon-03.png' },
{ name: '旅居', icon: '/page/qianxian/icon-03.png' },
{ name: '租售', icon: '/page/qianxian/icon-07.png' }
],
@@ -952,7 +964,8 @@ export default {
jiaLouList: [],
countyId: null,
newsCategoryList: [],
newsCurrent: 0
newsCurrent: 0,
shopList: [],
}
},
onShareAppMessage() {
@@ -1642,6 +1655,16 @@ export default {
this.jiaLouList = res.data.records || []
})
}
if(index === 1) {
const params = {
countyFamousDataId: this.id,
page: 1,
limit: 9999
}
getCityShopList(params).then(res => {
this.shopList = res.data.records || []
})
}
},
fileItemClick(file) {
const url = file.attachment || ''