Commit f56d62b1 authored by 彭佳妮(贵阳日报)'s avatar 彭佳妮(贵阳日报)
parents 901c9d5a 74a8f05d
......@@ -37,6 +37,10 @@ const props = defineProps({
},
});
const reset = () => {
selectedItem.value = null;
};
defineExpose({ reset });
onMounted(async () => {
getStartDateList();
});
......
......@@ -5,7 +5,7 @@
v-for="(item, index) in items"
:key="index"
:class="{ active: selectedItem === index }"
@tap="selectItem(index, item)"
@click="selectItem(index, item)"
>
{{ item.name }}
</li>
......@@ -14,7 +14,7 @@
</template>
<script setup>
import { defineProps } from 'vue';
import { ref } from 'vue';
const items = ref([
{ name: '距离优先', sortMode: 1 },
{ name: '好评优先', sortMode: 2 },
......@@ -31,8 +31,13 @@ const props = defineProps({
},
});
const selectItem = (index, item) => {
selectedItem.value = index;
emit('sortParams', item);
if (selectedItem.value === index) {
selectedItem.value = null;
emit('sortParams', null);
} else {
selectedItem.value = index;
emit('sortParams', item);
}
};
const reset = () => {
selectedItem.value = null;
......@@ -44,8 +49,6 @@ defineExpose({ reset });
.sort {
position: absolute;
top: 100%;
// width: 100%;
// min-height: 212rpx;
border-radius: 0rpx 0rpx 16rpx 16rpx;
background: #ffffff;
box-shadow: 0rpx 16rpx 16rpx 0rpx rgba(73, 73, 73, 0.14);
......@@ -55,12 +58,13 @@ defineExpose({ reset });
padding-bottom: 20rpx;
box-sizing: border-box;
.ul {
padding-left: 60rpx;
padding-left: 30rpx;
li {
list-style-type: none;
font-size: 22rpx;
color: #3d3d3d;
margin-top: 20rpx;
cursor: pointer;
}
.active {
color: #fa5151;
......
......@@ -8,3 +8,12 @@ export function getPhoto(data) {
data,
});
}
// 点赞
export function likeOrDislike(data) {
return request({
url: `/sgyrdd/evaluation/likeOrDislike`,
method: 'POST',
data,
});
}
......@@ -62,7 +62,8 @@ onLoad(() => {
// console.log('右边界坐标', res.right); // 右边界坐标,单位:px
// console.log('下边界坐标', res.bottom); // 下边界坐标,单位:px
// console.log('左边界坐标', res.left);
contentHeight.value = res.bottom * 2 + 10 + 'rpx'; // 左边界坐标,单位:px
contentHeight.value = (res.top + res.bottom) / 2 + 25 + 'px';
// contentHeight.value = res.bottom * 2 + 10 + 'rpx'; // 左边界坐标,单位:px
},
});
});
......@@ -81,7 +82,7 @@ const back = () => {
top: 0;
z-index: 999999;
transition: background-color 0.5s;
box-sizing: border-box;
// box-sizing: border-box;
.search {
position: absolute;
bottom: 10rpx;
......@@ -90,7 +91,7 @@ const back = () => {
width: 710rpx;
height: 80rpx;
// background: rgba(255, 255, 255, 0.8);
// border-radius: 16rpx 16rpx 16rpx 16rpx;
border-radius: 16rpx 16rpx 16rpx 16rpx;
opacity: 0.8;
margin: 0 auto;
// margin-top: 44rpx;
......
<template>
<view class="container">
<Search
:showTitle="true"
:title="newAddressFlag ? '新增收货地址' : '编辑收货地址'"
backgroundBox="white"
></Search>
<template v-if="showNavBar">
<Search
:showTitle="true"
:title="newAddressFlag ? '新增收货地址' : '编辑收货地址'"
backgroundBox="white"
></Search>
</template>
<view class="content">
<wd-form ref="reForm" :model="forMData" id="form">
<wd-cell-group>
......@@ -83,6 +86,7 @@ const forMData = ref({
commonAddr: false,
});
const content = ref([]);
const showNavBar = ref(true);
onLoad((options) => {
newAddressFlag.value = options.new;
content.value = JSON.parse(options.content);
......@@ -140,6 +144,7 @@ function handleSubmit() {
// 重新定位收货地址
async function changeLocation() {
showNavBar.value = false;
uni.chooseLocation({
success: function (res) {
// forMData.value.city = res.address;
......@@ -162,6 +167,9 @@ async function changeLocation() {
},
});
},
complete: (res) => {
showNavBar.value = true;
},
});
}
</script>
......@@ -170,7 +178,26 @@ async function changeLocation() {
page {
background: #f9f9f9;
}
:deep(#u-a-c .uni-system-choose-location .nav) {
top: 20px !important;
background-image: none;
}
:deep(#u-a-c .uni-system-choose-location .nav-btn) {
background-color: #007aff;
border-radius: 10px;
}
:deep(#u-a-c .uni-system-choose-location .nav-btn.back) {
background-color: #007aff;
border-radius: 10px;
top: 50px;
left: 10px;
}
:deep(#u-a-c .uni-system-choose-location .nav-btn.confirm) {
background-color: #007aff;
border-radius: 10px;
top: 50px;
right: 10px;
}
.container {
width: 375 * 2rpx;
margin: 0 auto;
......
......@@ -48,7 +48,7 @@
/>
</view>
<view class="right-offer">
<text class="left-title">日游直播</text>
<text class="left-title">日游播放</text>
<img
class="special-icon"
src="/static/assistingAgriculture/rural/dayTOur.png"
......@@ -178,11 +178,11 @@
</view>
<view class="all-info">
<view class="detail-score">
<text class="score">{{ item.score }}</text>
<text class="score" v-if="item.score !== null">{{ item.score }}</text>
<text class="num">月销{{ item.monthSoldNum }}</text>
</view>
<view class="venue">
<text class="place">{{ item.tripArea }}出发</text>
<text class="place" v-if="item.tripArea !== null">{{ item.tripArea }}出发</text>
<text class="price">{{ item.price }}</text>
</view>
</view>
......@@ -373,6 +373,9 @@ const toSearch = () => {
const currentPage = ref(1);
// 查询列表
const getProd = (searchKeyword = '') => {
xma.showLoading({
title: '加载中',
});
const params = {
current: currentPage.value,
size: 3,
......@@ -394,6 +397,7 @@ const getProd = (searchKeyword = '') => {
...(searchKeyword && { keyword: searchKeyword }),
};
getProdList(params).then((res) => {
xma.hideLoading();
res.data.records.forEach((item) => {
item.img = import.meta.env.VITE_APP_IMG_URL + item.pic;
item.serveList = item.serviceList.slice(0, 3);
......
......@@ -86,10 +86,10 @@
<wd-icon size="24rpx" class="icons"></wd-icon>
</view>
</view>
<Sort v-show="rotate" @sortParams="sortParams" />
<DepartureDate v-show="rotate2" @dataParams="dataParams" />
<ScenicSpots v-show="rotate3" @placeParams="placeParams" />
<Screen v-show="rotate4" @screenParams="screenParams" />
<Sort v-show="rotate" ref="sortRef" @sortParams="sortParams" />
<DepartureDate v-show="rotate2" ref="departureDateRef" @dataParams="dataParams" />
<ScenicSpots v-show="rotate3" ref="scenicSpotsRef" @placeParams="placeParams" />
<Screen v-show="rotate4" ref="screenRef" @screenParams="screenParams" />
</view>
<view class="list">
<view @click="jumpPage(item)" class="item" v-for="(item, index) in cardData" :key="index">
......@@ -142,6 +142,10 @@ const textColor = ref('#ffffff');
const backIconColor = ref('white');
const current = ref(0);
const isLoadReachBottom = ref(null);
const sortRef = ref(null);
const departureDateRef = ref(null);
const scenicSpotsRef = ref(null);
const screenRef = ref(null);
const params = ref({
current: 1,
size: 15,
......@@ -237,6 +241,12 @@ const screenParams = (item, type) => {
});
};
const resetParams = () => {
if (sortRef.value || departureDateRef.value || scenicSpotsRef.value || screenRef.value) {
sortRef.value.reset();
departureDateRef.value.reset();
scenicSpotsRef.value.reset();
screenRef.value.reset();
}
params.value = {
size: 15,
current: 1,
......
......@@ -3,7 +3,7 @@
<!-- 点评详情页面 -->
<search style="z-index: 99; width: 100%" :type="2" backgroundBox="#fff">
<view style="width: 100%; text-align: center; font-size: 36rpx; font-weight: bold">
点评详情
景点详情
</view>
</search>
<view class="review-details-pages">
......
......@@ -10,8 +10,8 @@ import { getTokenUser } from '../../api/index';
import { getToken } from '../../utils/auth';
onLoad(async (options) => {
// await signIn();
if (!getToken()) await signIn2();
await signIn();
// if (!getToken()) await signIn2();
const { type } = options;
switch (type) {
case '0':
......@@ -21,11 +21,11 @@ onLoad(async (options) => {
xma.reLaunch({ url: '/pages/index/index' });
break;
case '2':
xma.reLaunch({ url: '/pages/assistingAgriculture/index/building?categoryId=3266' });
xma.reLaunch({ url: '/pages/assistingAgriculture/RuralTravel/RuralTravel?categoryId=3268' });
break;
case '3':
xma.reLaunch({
url: '/pages/assistingAgriculture/RuralTravel/RuralTravel?categoryId=3268',
url: '/pages/assistingAgriculture/index/building?categoryId=3266',
});
break;
default:
......
<template>
<view class="container">
<Search :showTitle="true" title="商家入驻" backgroundBox="white"></Search>
<template v-if="showNavBar">
<Search :showTitle="true" title="商家入驻" backgroundBox="white"></Search>
</template>
<view class="content">
<view class="formmain">
......@@ -237,6 +239,7 @@ const token = getToken();
const action = ref(import.meta.env.VITE_APP_BASE_URL + '/sgyrdd/file/update');
const headers = ref('');
const fileDomain = import.meta.env.VITE_APP_IMG_URL;
const showNavBar = ref(true);
// 店铺logo图片组
const fileListShopLogo = ref([]);
// 身份证正面图片组
......@@ -706,6 +709,7 @@ const submitData = () => {
// 重新定位收货地址
async function changeLocation() {
showNavBar.value = false;
uni.chooseLocation({
success: function (res) {
// forMData.value.city = res.address;
......@@ -728,10 +732,14 @@ async function changeLocation() {
formData.area = res.data.result.address_component.district;
ssq.value = formData.province + formData.city + formData.area;
// showNavBar.value = true;
}
},
});
},
complete: (res) => {
showNavBar.value = true;
},
});
}
</script>
......@@ -740,7 +748,26 @@ async function changeLocation() {
page {
background: #fff;
}
:deep(#u-a-c .uni-system-choose-location .nav) {
top: 20px !important;
background-image: none;
}
:deep(#u-a-c .uni-system-choose-location .nav-btn) {
background-color: #007aff;
border-radius: 10px;
}
:deep(#u-a-c .uni-system-choose-location .nav-btn.back) {
background-color: #007aff;
border-radius: 10px;
top: 50px;
left: 10px;
}
:deep(#u-a-c .uni-system-choose-location .nav-btn.confirm) {
background-color: #007aff;
border-radius: 10px;
top: 50px;
right: 10px;
}
.uni-textarea-placeholder,
.uni-textarea-line,
.uni-textarea-compute,
......
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