Commit abd34f0a authored by 张娇(东信)'s avatar 张娇(东信)

乡村旅居页面跳转

parent cb41caec
<template> <template>
<div class="route-details"> <div class="route-details">
<scroll-view class="container" scroll-y> <scroll-view class="container" scroll-y>
<img class="back-img" src="/static/assistingAgriculture/assets/left.png" @tap="back" />
<!-- 轮播 --> <!-- 轮播 -->
<div class="banner"> <div class="banner">
<!-- --> <!-- -->
...@@ -60,7 +61,7 @@ ...@@ -60,7 +61,7 @@
<span>/5分</span> <span>/5分</span>
</p> </p>
</div> </div>
<div class="link">查看全部(526) ></div> <div class="link" @click="toCommentDetail">查看全部(526) ></div>
</div> </div>
<div class="tags"> <div class="tags">
<p>景色优美 (153)</p> <p>景色优美 (153)</p>
...@@ -78,7 +79,7 @@ ...@@ -78,7 +79,7 @@
<div class="album"> <div class="album">
<div class="top flex-between"> <div class="top flex-between">
<div class="title">用户相册</div> <div class="title">用户相册</div>
<div class="link">查看全部(526) ></div> <div class="link" @click="toAlbum">查看全部(526) ></div>
</div> </div>
<div class="img-list"> <div class="img-list">
<wd-img <wd-img
...@@ -268,6 +269,26 @@ const swiperList = ref([ ...@@ -268,6 +269,26 @@ const swiperList = ref([
'https://registry.npmmirror.com/wot-design-uni-assets/*/files/moon.jpg', 'https://registry.npmmirror.com/wot-design-uni-assets/*/files/moon.jpg',
'https://registry.npmmirror.com/wot-design-uni-assets/*/files/meng.jpg', 'https://registry.npmmirror.com/wot-design-uni-assets/*/files/meng.jpg',
]); ]);
// 返回上一级
function back() {
xma.navigateBack({
delta: 1,
});
}
// 跳转详情页
function toCommentDetail() {
// TODO: 跳转到评论详情页
xma.navigateTo({
url: '/pages/assistingAgriculture/commentList/index',
});
}
// 跳转用户相册
function toAlbum() {
// TODO: 跳转到评论详情页
xma.navigateTo({
url: '/pages/assistingAgriculture/album/index',
});
}
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
uni-page-body { uni-page-body {
...@@ -677,4 +698,12 @@ uni-page-body { ...@@ -677,4 +698,12 @@ uni-page-body {
} }
} }
} }
.back-img {
width: 56rpx;
height: 56rpx;
position: absolute;
z-index: 999;
margin-top: 40rpx;
margin-left: 40rpx;
}
</style> </style>
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
<view style="display: flex; flex-direction: row"> <view style="display: flex; flex-direction: row">
<view <view
class="borderClass" class="borderClass"
@tap="toBuilding" @click="toBuilding(index)"
v-for="(item, index) in sortList" v-for="(item, index) in sortList"
:key="index" :key="index"
> >
...@@ -212,17 +212,19 @@ const getStrictSelectionList = () => { ...@@ -212,17 +212,19 @@ const getStrictSelectionList = () => {
console.log(res, 333); console.log(res, 333);
}); });
}; };
function toBuilding() { function toBuilding(index) {
// TODO: 跳转到筑农严选 if (index === 0) {
xma.navigateTo({ // TODO: 跳转到筑农严选
url: '/pages/assistingAgriculture/index/building', xma.navigateTo({
}); url: '/pages/assistingAgriculture/index/building',
} });
function toRuralTravel() { } else if (index === 2) {
// TODO: 跳转到乡村旅居 // TODO: 跳转到乡村旅居
xma.navigateTo({ xma.navigateTo({
url: '/pages/assistingAgriculture/RuralTravel/RuralTravel', url: '/pages/assistingAgriculture/RuralTravel/RuralTravel',
}); });
}
console.log(index, 121);
} }
// 跳转详情页 // 跳转详情页
function toDetail() { function toDetail() {
......
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