Commit 29d6e053 authored by 石建新(贵阳日报)'s avatar 石建新(贵阳日报)
parents 17587c1c 700a3e67
...@@ -9,15 +9,7 @@ ...@@ -9,15 +9,7 @@
:style="{ color: backIcon }" :style="{ color: backIcon }"
></wd-icon> ></wd-icon>
<slot></slot> <slot></slot>
<view class="searchBox" :style="{ border }" v-if="type === 1"> <text class="title" :style="{ color: textColor }" v-if="showTitle">{{ title }}</text>
<image
class="magnifyingGlass"
src="../../static/index/magnifyingGlass.png"
mode="aspectFit|aspectFill|widthFix"
/>
<input type="text" :value="test" class="text" @confirm="search" confirm-type="搜索" />
</view>
<text class="title" :style="{ color: textColor }" v-else>{{ title }}</text>
</view> </view>
</view> </view>
</template> </template>
...@@ -42,13 +34,9 @@ const props = defineProps({ ...@@ -42,13 +34,9 @@ const props = defineProps({
type: String, type: String,
default: '', default: '',
}, },
border: { showTitle: {
type: String, type: Boolean,
default: '', default: false,
},
type: {
type: Number,
default: 1,
}, },
textColor: { textColor: {
type: String, type: String,
...@@ -63,7 +51,6 @@ const contentHeight = ref('100rpx'); ...@@ -63,7 +51,6 @@ const contentHeight = ref('100rpx');
const emit = defineEmits(['toSearch']); const emit = defineEmits(['toSearch']);
// const title = ref('小程序平台'); // const title = ref('小程序平台');
const { countInfo, addCount } = useCountStore(); const { countInfo, addCount } = useCountStore();
const test = ref('');
onLoad(() => { onLoad(() => {
xma.xh.getSystemInfo({ xma.xh.getSystemInfo({
success(res) { success(res) {
...@@ -72,12 +59,12 @@ onLoad(() => { ...@@ -72,12 +59,12 @@ onLoad(() => {
}); });
xma.xh.getMenuButtonBoundingClientRect({ xma.xh.getMenuButtonBoundingClientRect({
success(res) { success(res) {
console.log('宽度', res.width); // 宽度,单位:px // console.log('宽度', res.width); // 宽度,单位:px
console.log('高度', res.height); // 高度,单位:px // console.log('高度', res.height); // 高度,单位:px
console.log('上边界坐标', res.top); // 上边界坐标,单位:px // console.log('上边界坐标', res.top); // 上边界坐标,单位:px
console.log('右边界坐标', res.right); // 右边界坐标,单位:px // console.log('右边界坐标', res.right); // 右边界坐标,单位:px
console.log('下边界坐标', res.bottom); // 下边界坐标,单位:px // console.log('下边界坐标', res.bottom); // 下边界坐标,单位:px
console.log('左边界坐标', res.left); // console.log('左边界坐标', res.left);
contentHeight.value = res.bottom * 2 + 10 + 'rpx'; // 左边界坐标,单位:px contentHeight.value = res.bottom * 2 + 10 + 'rpx'; // 左边界坐标,单位:px
}, },
}); });
...@@ -135,25 +122,7 @@ function onHandleClick() { ...@@ -135,25 +122,7 @@ function onHandleClick() {
// left: 10rpx; // left: 10rpx;
position: absolute; position: absolute;
} }
.searchBox {
opacity: 1;
width: 256rpx;
height: 56rpx;
background: #ffffff;
border-radius: 28rpx 28rpx 28rpx 28rpx;
display: flex;
align-items: center;
padding-left: 20rpx;
margin-left: 20rpx;
.magnifyingGlass {
width: 26rpx;
height: 26rpx;
}
.text {
margin-left: 10rpx;
font-size: 24rpx;
}
}
.title { .title {
width: 100%; width: 100%;
font-size: 36rpx; font-size: 36rpx;
......
...@@ -113,10 +113,12 @@ const hdSubmit = async () => { ...@@ -113,10 +113,12 @@ const hdSubmit = async () => {
uni.showToast({ uni.showToast({
title: '提交成功', title: '提交成功',
duration: 2000, duration: 2000,
icon: 'success',
success: () => {
uni.navigateBack();
},
}); });
uni.navigateTo({
url: '/pages/address/addressList',
});
} catch (error) { } catch (error) {
console.log(error, 'error'); console.log(error, 'error');
} }
......
...@@ -7,7 +7,14 @@ ...@@ -7,7 +7,14 @@
:border="border" :border="border"
> >
<text class="title-icon" :style="{ color: textColor }">{{ categoryNames }}</text> <text class="title-icon" :style="{ color: textColor }">{{ categoryNames }}</text>
<!-- <image class="food" :src="pics" mode="widthFix" /> --> <view class="searchBox" :style="{ border }">
<image
class="magnifyingGlass"
src="../../static/index/magnifyingGlass.png"
mode="aspectFit|aspectFill|widthFix"
/>
<input type="text" class="text" @confirm="toSearch" confirm-type="搜索" />
</view>
</Search> </Search>
<view class="container" style="padding-bottom: 10rpx"> <view class="container" style="padding-bottom: 10rpx">
<view class="bg-img"></view> <view class="bg-img"></view>
...@@ -379,6 +386,26 @@ page { ...@@ -379,6 +386,26 @@ page {
margin-left: 50rpx; margin-left: 50rpx;
margin-right: 10rpx; margin-right: 10rpx;
} }
.searchBox {
opacity: 1;
width: 256rpx;
height: 56rpx;
background: #ffffff;
border-radius: 28rpx 28rpx 28rpx 28rpx;
display: flex;
align-items: center;
padding-left: 20rpx;
margin-left: 20rpx;
text-align: start;
.magnifyingGlass {
width: 26rpx;
height: 26rpx;
}
.text {
margin-left: 10rpx;
font-size: 24rpx;
}
}
.container { .container {
.bg-img { .bg-img {
width: 100%; width: 100%;
......
<template> <template>
<!-- 搜索 --> <!-- 搜索 -->
<Search <Search :backgroundBox="backgroundBox" background="rgba(255, 255, 255, 0.8)" :show="false">
:backgroundBox="backgroundBox"
background="rgba(255, 255, 255, 0.8)"
@toSearch="toSearch"
:show="false"
>
<image class="food" src="../../static/index/food.png" mode="widthFix" /> <image class="food" src="../../static/index/food.png" mode="widthFix" />
<view class="searchBox">
<image
class="magnifyingGlass"
src="../../static/index/magnifyingGlass.png"
mode="aspectFit|aspectFill|widthFix"
/>
<input type="text" class="text" @confirm="toSearch" confirm-type="搜索" />
</view>
</Search> </Search>
<view class="container"> <view class="container">
<view class="top"> <view class="top">
...@@ -537,6 +540,26 @@ page { ...@@ -537,6 +540,26 @@ page {
height: 45rpx; height: 45rpx;
margin-left: 25rpx; margin-left: 25rpx;
} }
.searchBox {
opacity: 1;
width: 256rpx;
height: 56rpx;
background: #ffffff;
border-radius: 28rpx 28rpx 28rpx 28rpx;
display: flex;
align-items: center;
padding-left: 20rpx;
margin-left: 20rpx;
text-align: start;
.magnifyingGlass {
width: 26rpx;
height: 26rpx;
}
.text {
margin-left: 10rpx;
font-size: 24rpx;
}
}
.container { .container {
.top { .top {
width: 100%; width: 100%;
......
...@@ -222,9 +222,22 @@ const hdSubmit = async () => { ...@@ -222,9 +222,22 @@ const hdSubmit = async () => {
...formdata, ...formdata,
images: proImage(), images: proImage(),
}); });
uToast.success('评价成功'); xma.showToast({
xma.redirectTo({ title: '发布中',
url: `/pages/order/order?status=not_eval`, icon: 'none',
duration: 2000,
success: () => {
xma.redirectTo({
url: `/pages/order/order?status=not_eval`,
complete: () => {
xma.showToast({
title: '评价成功',
icon: 'none',
duration: 2000,
});
},
});
},
}); });
}; };
......
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