# Conflicts:
#	pkg_product/views/famousQianxianVillageShop.vue
This commit is contained in:
linxi
2024-08-28 15:18:31 +08:00
4 changed files with 45 additions and 22 deletions
+2 -2
View File
@@ -140,11 +140,12 @@ export default {
.county-index {
position: relative;
min-height: 100vh;
background-color: #fff;
background-color: #f0f0f0;
.top-img {
position: relative;
z-index: 5;
padding: 21rpx;
background-color: #fff;
.img {
display: block;
width: 100%;
@@ -175,7 +176,6 @@ export default {
}
}
.list-wrap {
background-color: #F0F0F0;
.loadend {
width: 100%;
}
+36 -13
View File
@@ -26,18 +26,17 @@
class="icon"
/>
</view>
<!-- <image
:src="webUrl + '/home/no-data-bg.png'"
mode="widthFix"
class="loadend"
/> -->
<view v-if="currentList.length === 0" class="no-data-txt">
暂无数据~
</view>
</view>
<goo-skeleton v-else />
</view>
</template>
<script>
import {
getCountyFamousInvestmentFile
getCountyFamousInvestmentFile,
getCountyFamousIndustryProjectFile
} from '@/api/qianxian'
import { pageListenMixins } from '@/mixins/pageListenMixins'
export default {
@@ -55,18 +54,36 @@ export default {
},
onLoad(options) {
const id = options.id
this.getListReq(id)
const type = options.type || 'investment'
const title = options.title || ''
if (title) {
uni.setNavigationBarTitle({ title })
}
this.getListReq(id, type)
},
methods: {
handleSearch() {
this.currentList = this.list.filter(item => item.title.indexOf(this.keyword) > -1)
},
getListReq(id) {
getCountyFamousInvestmentFile({
countyFamousDataId: id,
page: 1,
limit: 9999
}).then(res => {
getListReq(id, type) {
let reqFn = null
let params = {}
if (type === 'investment') {
reqFn = getCountyFamousInvestmentFile
params = {
countyFamousDataId: id,
page: 1,
limit: 9999
}
} else {
reqFn = getCountyFamousIndustryProjectFile
params = {
industryProjectId: id,
page: 1,
limit: 9999
}
}
reqFn(params).then(res => {
const { success, data } = res
if (success) {
this.isLoad = true
@@ -126,5 +143,11 @@ export default {
.loadend {
width: 100%;
}
.no-data-txt {
text-align: center;
line-height: 200rpx;
color: #999;
font-size: 36rpx;
}
}
</style>
+4 -3
View File
@@ -360,6 +360,7 @@
<image
:src="item.image"
class="img"
@click="gotoInvestment(item.title, 'project', item.id)"
/>
</view>
</view>
@@ -412,7 +413,7 @@
</view>
</view>
<view v-if="investmentFileList.length > 0" class="more-btn-wrap">
<view class="more-btn" @click="gotoInvestment">
<view class="more-btn" @click="gotoInvestment('', 'investment')">
更多政策
</view>
</view>
@@ -949,8 +950,8 @@ export default {
}
})
},
gotoInvestment() {
uni.navigateTo({ url: `/pkg_product/views/famousQianxianInvestment?id=${this.id}` })
gotoInvestment(title = '', type = 'investment', id = '') {
uni.navigateTo({ url: `/pkg_product/views/famousQianxianInvestment?id=${id || this.id}&title=${title}&type=${type}` })
},
villageItemClick(item) {
uni.navigateTo({ url: `/pkg_product/views/famousQianxianVillageShop?id=${item.id}` })
@@ -56,9 +56,9 @@
<image :src="inn.logo" v-if="inn.logo"></image>
<image :src="webUrl + '/20230609145651814148.png'" v-else/>
</view>
<view class="a3 flex v12-justify-between" style="width: calc(100% - 140rpx);">
<view class="a3 flex" style="width: 100%">
<view class="inn-owner one-t">{{ inn.name }}</view>
<view class="inn-owner-desc one-t">
<view class="inn-owner-desc">
{{ inn.contact }}/联系人
</view>
</view>
@@ -444,7 +444,7 @@ export default {
line-height: 48rpx;
}
.inn-owner {
width: calc(100% - 180rpx);
width: calc(100% - 240rpx);
font-size: 36rpx;
font-weight: bold;
color: #333;
@@ -455,7 +455,6 @@ export default {
color: #999;
font-size: 24rpx;
line-height: 40rpx;
max-width: 160rpx;
}
.inn-tag-wrap {
margin-top: 10rpx;