This commit is contained in:
liu
2026-09-04 14:10:33 +08:00
parent 1701169c9d
commit e2926b0c70
13 changed files with 17 additions and 14 deletions
@@ -1,8 +1,6 @@
import {useEffect, useState} from 'react' import {useEffect, useState} from 'react'
import Taro from '@tarojs/taro' import Taro from '@tarojs/taro'
import {View, Text, Image} from '@tarojs/components' import {View, Text, Image} from '@tarojs/components'
import useAuthStore from '@/stores/auth/useAuthStore'
import useCartStore from '@/stores/cart/useCartStore'
import IndexImage from '@/static/images/nav/index.png'; import IndexImage from '@/static/images/nav/index.png';
import IndexActiveImage from '@/static/images/nav/index_active.png'; import IndexActiveImage from '@/static/images/nav/index_active.png';
import CartImage from '@/static/images/nav/cart.png'; import CartImage from '@/static/images/nav/cart.png';
-2
View File
@@ -1,5 +1,4 @@
import { View, Text, ScrollView } from '@tarojs/components' import { View, Text, ScrollView } from '@tarojs/components'
import CustomNavBar from '@/components/NavBar'
import './index.less' import './index.less'
/** /**
@@ -9,7 +8,6 @@ import './index.less'
export default function AgreementPage() { export default function AgreementPage() {
return ( return (
<View className='agreement-page'> <View className='agreement-page'>
<CustomNavBar title='用户服务协议' />
<ScrollView scrollY className='agreement-scroll'> <ScrollView scrollY className='agreement-scroll'>
<View className='agreement-content'> <View className='agreement-content'>
<Text className='doc-title'></Text> <Text className='doc-title'></Text>
+3
View File
@@ -10,6 +10,7 @@ import {formatRetailPrice, formatSpec} from '@/utils/format'
import type { CartItem } from '@/types/cart' import type { CartItem } from '@/types/cart'
import type { StoreDetail } from '@/types/store' import type { StoreDetail } from '@/types/store'
import './index.less' import './index.less'
import CustomTabBar from "@/components/CustomTabBar";
export default function CartPage() { export default function CartPage() {
const token = useAuthStore(s => s.token) const token = useAuthStore(s => s.token)
@@ -351,6 +352,8 @@ export default function CartPage() {
</View> </View>
</View> </View>
</Popup> </Popup>
{process.env.TARO_ENV === 'h5' && <CustomTabBar />}
</View> </View>
) )
} }
+2
View File
@@ -13,6 +13,7 @@ import CartBall from '@/components/CartBall'
import CartStepper from '@/components/CartStepper' import CartStepper from '@/components/CartStepper'
import {formatRetailPrice, formatSpec} from '@/utils/format' import {formatRetailPrice, formatSpec} from '@/utils/format'
import './index.less' import './index.less'
import CustomTabBar from "@/components/CustomTabBar";
/** 首页 → 商品页的本地存储传参 key(switchTab 无法带参) */ /** 首页 → 商品页的本地存储传参 key(switchTab 无法带参) */
const PENDING_CATEGORY_KEY = 'product_category_id' const PENDING_CATEGORY_KEY = 'product_category_id'
@@ -362,6 +363,7 @@ export default function IndexPage() {
{/* ========== 购物车悬浮球 ========== */} {/* ========== 购物车悬浮球 ========== */}
<CartBall /> <CartBall />
{process.env.TARO_ENV === 'h5' && <CustomTabBar />}
</View> </View>
) )
} }
+2
View File
@@ -132,6 +132,8 @@
height: 100%; height: 100%;
font-size: 30px; font-size: 30px;
color: #323233; color: #323233;
display: flex;
align-items: center;
} }
.form-input-placeholder { .form-input-placeholder {
-3
View File
@@ -1,7 +1,6 @@
import { useCallback, useState } from 'react' import { useCallback, useState } from 'react'
import Taro from '@tarojs/taro' import Taro from '@tarojs/taro'
import { View, Text, Button, Input } from '@tarojs/components' import { View, Text, Button, Input } from '@tarojs/components'
import CustomNavBar from '@/components/NavBar'
import useAuthStore from '@/stores/auth/useAuthStore' import useAuthStore from '@/stores/auth/useAuthStore'
import './index.less' import './index.less'
@@ -76,8 +75,6 @@ export default function LoginPage() {
return ( return (
<View className='login-page'> <View className='login-page'>
{/* ========== 导航栏 ========== */}
<CustomNavBar title='登录' />
{/* ========== 内容区域 ========== */} {/* ========== 内容区域 ========== */}
<View className='login-content'> <View className='login-content'>
+3
View File
@@ -8,6 +8,7 @@ import { formatTime } from '@/utils/format'
import { NOTICE_TYPE_MAP } from '@/types/notice' import { NOTICE_TYPE_MAP } from '@/types/notice'
import type { Notice, NoticeType } from '@/types/notice' import type { Notice, NoticeType } from '@/types/notice'
import './index.less' import './index.less'
import CustomTabBar from "@/components/CustomTabBar";
const PAGE_SIZE = 10 const PAGE_SIZE = 10
@@ -123,6 +124,8 @@ export default function MessagePage() {
{loggedIn && finished && notices.length > 0 && ( {loggedIn && finished && notices.length > 0 && (
<View className='message-loading'><Text></Text></View> <View className='message-loading'><Text></Text></View>
)} )}
{process.env.TARO_ENV === 'h5' && <CustomTabBar />}
</View> </View>
) )
} }
-2
View File
@@ -1,5 +1,4 @@
import { View, Text, ScrollView } from '@tarojs/components' import { View, Text, ScrollView } from '@tarojs/components'
import CustomNavBar from '@/components/NavBar'
import './index.less' import './index.less'
/** /**
@@ -9,7 +8,6 @@ import './index.less'
export default function PrivacyPage() { export default function PrivacyPage() {
return ( return (
<View className='privacy-page'> <View className='privacy-page'>
<CustomNavBar title='隐私政策' />
<ScrollView scrollY className='privacy-scroll'> <ScrollView scrollY className='privacy-scroll'>
<View className='privacy-content'> <View className='privacy-content'>
<Text className='doc-title'></Text> <Text className='doc-title'></Text>
-3
View File
@@ -3,9 +3,6 @@
display: flex; display: flex;
flex-direction: column; flex-direction: column;
background: #f7f8fa; background: #f7f8fa;
// 底部预留给自定义 tabBar(110rpx + 安全区),避免列表被遮挡
padding-bottom: calc(110rpx + env(safe-area-inset-bottom));
box-sizing: border-box;
.product-search { .product-search {
flex-shrink: 0; flex-shrink: 0;
+2
View File
@@ -11,6 +11,7 @@ import CartBall from '@/components/CartBall'
import CartStepper from '@/components/CartStepper' import CartStepper from '@/components/CartStepper'
import {formatRetailPrice, formatSpec} from '@/utils/format' import {formatRetailPrice, formatSpec} from '@/utils/format'
import './index.less' import './index.less'
import CustomTabBar from "@/components/CustomTabBar";
const PAGE_SIZE = 10 const PAGE_SIZE = 10
/** 存储 key:首页点击分类/搜索跳转时经本地存储传参(switchTab 无法带参) */ /** 存储 key:首页点击分类/搜索跳转时经本地存储传参(switchTab 无法带参) */
@@ -331,6 +332,7 @@ export default function ProductPage() {
{/* ========== 购物车悬浮球 ========== */} {/* ========== 购物车悬浮球 ========== */}
<CartBall /> <CartBall />
{process.env.TARO_ENV === 'h5' && <CustomTabBar />}
</View> </View>
) )
} }
+3
View File
@@ -9,6 +9,7 @@ import type { BillSummary } from '@/services/bill'
import { ORDER_NAV_ITEMS } from '@/types/order' import { ORDER_NAV_ITEMS } from '@/types/order'
import { resolveAvatarUrl } from '@/utils/format' import { resolveAvatarUrl } from '@/utils/format'
import './index.less' import './index.less'
import CustomTabBar from "@/components/CustomTabBar";
/** 菜单项(订单/账单入口已由上方专区承载,后续单独页面开发时在此追加) */ /** 菜单项(订单/账单入口已由上方专区承载,后续单独页面开发时在此追加) */
const MENU_ITEMS = [ const MENU_ITEMS = [
@@ -229,6 +230,8 @@ export default function ProfilePage() {
<Text>退</Text> <Text>退</Text>
</View> </View>
)} )}
{process.env.TARO_ENV === 'h5' && <CustomTabBar />}
</View> </View>
) )
} }
+2 -2
View File
@@ -10,8 +10,8 @@ const LOGIN_PATH = '/pages/login/index'
/** 默认请求超时(ms */ /** 默认请求超时(ms */
const DEFAULT_TIMEOUT = 15000 const DEFAULT_TIMEOUT = 15000
/** 接口根地址(uploadFile 等原生请求同样使用) */ /** 接口根地址(uploadFile 等原生请求同样使用) */
export const BASE_URL = "http://localhost:8000/index.php" // export const BASE_URL = "http://localhost:8000/index.php"
// export const BASE_URL = "https://purchase.henanklkj.com/index.php" export const BASE_URL = "https://purchase.henanklkj.com/index.php"
/** /**
* HTTP 状态码 → 错误提示映射 * HTTP 状态码 → 错误提示映射