sunshibo 1 месяц назад
Родитель
Сommit
38c651ea48
3 измененных файлов с 32 добавлено и 8 удалено
  1. 24 6
      pages/orderFood/index.vue
  2. 1 1
      pages/orderInfo/index.vue
  3. 7 1
      pages/personal/index.vue

+ 24 - 6
pages/orderFood/index.vue

@@ -4,7 +4,10 @@
     <view class="top-fixed">
       <NavBar :title="navTitle" only-home />
       <view class="top-info">桌号:{{ displayTableNumber }}</view>
-      <input type="text" placeholder="请输入菜品名称" class="search-input" />
+      <view class="search-box">
+        <image :src="getFileUrl('img/personal/search.png')" mode="widthFix" class="search-icon"></image>
+        <input type="text" placeholder="请输入菜品名称" class="search-input" />
+      </view>
     </view>
     <view class="content">
     <!-- 内容 -->
@@ -58,6 +61,7 @@ import CouponModal from "./components/CouponModal.vue";
 import CartModal from "./components/CartModal.vue";
 import SelectCouponModal from "./components/SelectCouponModal.vue";
 import { go } from "@/utils/utils.js";
+import { getFileUrl } from "@/utils/file.js";
 import { DiningOrderFood, GetStoreCategories, GetStoreCuisines, GetStoreDetail, getOrderSseConfig, GetOrderCart, PostOrderCartAdd, PostOrderCartUpdate, PostOrderCartClear, PutOrderCartUpdateTableware, GetUserOwnedCouponList } from "@/api/dining.js";
 import { createSSEConnection } from "@/utils/sse.js";
 
@@ -833,17 +837,31 @@ onUnload(() => {
   background-color: #fff;
 }
 
-.search-input {
+.search-box {
   width: 90%;
   margin-left: 5%;
   height: 80rpx;
-  background-color: #fff;
+  background-color: #f5f5f5;
   border-radius: 40rpx;
-  padding: 0 20rpx;
   margin-top: 20rpx;
+  display: flex;
+  align-items: center;
+  padding: 0 30rpx;
   box-sizing: border-box;
-  font-size: 28rpx;
-  text-align: center;
+
+  .search-icon {
+    width: 34rpx;
+    height: 34rpx;
+    margin-right: 16rpx;
+  }
+
+  .search-input {
+    flex: 1;
+    font-size: 28rpx;
+    color: #333;
+    background: transparent;
+    border: none;
+  }
 }
 
 .content-box {

+ 1 - 1
pages/orderInfo/index.vue

@@ -5,7 +5,7 @@
     <view class="search-container">
       <view class="search-box">
         <image :src="getFileUrl('img/personal/search.png')" mode="widthFix" class="search-icon"></image>
-        <input type="text" placeholder="搜索订单编号或菜品名称" class="search-input" v-model="searchKeyword"
+        <input type="text" placeholder="搜索" class="search-input" v-model="searchKeyword"
           maxlength="15" @confirm="doSearch" />
       </view>
     </view>

+ 7 - 1
pages/personal/index.vue

@@ -60,7 +60,7 @@
 							</image>
 						</view>
 					</view>
-					<view class="card-list" hover-class="hover-active">
+					<view class="card-list" hover-class="hover-active" @click="handlePrivacyPolicy">
 						<view class='left'>
 							<image :src="getFileUrl('img/personal/ysxy.png')" mode="widthFix" class="card-icon"></image>
 							<view class="title">隐私政策</view>
@@ -159,6 +159,12 @@ const handleLoginCancel = () => {
 	console.log('用户取消登录');
 };
 
+// 隐私政策:跳转 webview 打开
+const PRIVACY_URL = 'https://ossfile.ailien.shop/privacy/U店在哪-隐私协议946827.htm';
+const handlePrivacyPolicy = () => {
+	go(`/pages/webview/index?url=${encodeURIComponent(PRIVACY_URL)}`);
+};
+
 </script>
 
 <style scoped lang="scss">