diff --git a/src/common/constant.ts b/src/common/constant.ts index d19a317..7dedbec 100644 --- a/src/common/constant.ts +++ b/src/common/constant.ts @@ -34,6 +34,12 @@ export const CDN_UPLOAD_IMG = `${UPLOAD_CDN_URL || ''}` //appid export const WX_APPID = 'wx64fe67f111d52457' +export const LIST_EMPTY_IMAGE = IMG_CND_Prefix + '/list_empty.png' + +export const EMPTY_IMAGE = IMG_CND_Prefix + '/empty.png' + +export const SEARCH_EMPTY_IMAGE = IMG_CND_Prefix + '/search_empty.png' + //场景值 export const SCENE = { SearchScene: 0, //商城面料搜索 diff --git a/src/components/SegmentedControl/index.module.scss b/src/components/SegmentedControl/index.module.scss index 3a40726..5832dfe 100644 --- a/src/components/SegmentedControl/index.module.scss +++ b/src/components/SegmentedControl/index.module.scss @@ -3,7 +3,7 @@ flex-flow: row nowrap; background-color: #fff; font-size: $font_size; - color: #000; + color: #5c5c5c; // margin-top: 20px; .status_item { padding: 20px; diff --git a/src/components/SegmentedControl/index.tsx b/src/components/SegmentedControl/index.tsx index ac6015a..be2da6c 100644 --- a/src/components/SegmentedControl/index.tsx +++ b/src/components/SegmentedControl/index.tsx @@ -52,7 +52,6 @@ const segmentedControl: FC = (props) => { {list.map((item, index) => { - console.log('selected=+>', selectInfo.selected) return ( { const { picUrl = '', - fonst = '无搜索历史' + text = '无搜索历史' } = pros - console.log(pros,8888) + return ( - {fonst} + {text} ) -}) \ No newline at end of file +}) diff --git a/src/components/infiniteScroll/index.tsx b/src/components/infiniteScroll/index.tsx index 5da7475..8c6b59e 100644 --- a/src/components/infiniteScroll/index.tsx +++ b/src/components/infiniteScroll/index.tsx @@ -3,8 +3,8 @@ import React, { memo, ReactNode, useMemo, useState } from 'react' import style from './index.module.scss' import DotLoading from '@/components/dotLoading' import LoadingCard from '../loadingCard' -import { useCustomTabItemTap } from '@/use/useCommon' -import Taro from '@tarojs/taro' +import Empty from '@/components/empty' +import { EMPTY_IMAGE, SEARCH_EMPTY_IMAGE } from '@/common/constant' export type StatusParam = 0 | 1 | 2 | 3 @@ -27,6 +27,7 @@ type Params = { refresherTriggered?: boolean refresherEnabled?: boolean enableBackToTop?: boolean + emptySlot?: React.ReactNode } export default memo( ({ @@ -48,6 +49,7 @@ export default memo( moreStatus = true, statusMore = 0, enableBackToTop = true, + emptySlot }: Params) => { const scrollToLower = () => { selfonScrollToLower?.() @@ -105,7 +107,7 @@ export default memo( )} {statusMore == 0 && } - {statusMore == 1 && } + {statusMore == 1 && emptySlot ? emptySlot : } ) } diff --git a/src/components/loadingCard/index.tsx b/src/components/loadingCard/index.tsx index 9ca0b31..8983f78 100644 --- a/src/components/loadingCard/index.tsx +++ b/src/components/loadingCard/index.tsx @@ -2,6 +2,7 @@ import { View, Image } from '@tarojs/components' import Loading from '@/components/loading' import style from './index.module.scss' import { memo } from 'react' +import Empty from '@/components/empty' type Params = { title?: string diff --git a/src/pages/searchPage/index.tsx b/src/pages/searchPage/index.tsx index e546655..7a75df3 100644 --- a/src/pages/searchPage/index.tsx +++ b/src/pages/searchPage/index.tsx @@ -3,7 +3,7 @@ import React, { useCallback, memo, useEffect, useMemo, useRef, useState } from ' import Search from '@/components/search' import styles from "./index.module.scss" import classnames from "classnames"; -import Empty from './components/empty' +import Empty from '@/components/empty' import Taro, { useDidShow } from '@tarojs/taro'; import Goods from './components/goods' import { mpproductlist } from "@/api/search" @@ -376,7 +376,7 @@ export default memo(() => { } { - !histroyList.length && + !histroyList.length && } } @@ -396,7 +396,7 @@ export default memo(() => { }) } { - !searchList.length && + !searchList.length && } } diff --git a/src/pages/takeDelivery/components/ItemList/index.module.scss b/src/pages/takeDelivery/components/ItemList/index.module.scss index 754ee16..76db77d 100644 --- a/src/pages/takeDelivery/components/ItemList/index.module.scss +++ b/src/pages/takeDelivery/components/ItemList/index.module.scss @@ -1,5 +1,6 @@ .layoutBlock{ - margin: 24px; + margin: 20px; + padding: 24px; } .topBar { font-size: 28px; @@ -8,13 +9,16 @@ flex-flow: row nowrap; justify-content: space-between; color: $color_font_one; + .orderNo{ + font-weight: bold; + } } &__orderType { color: rgba($color: #000000, $alpha: 0.6); - font-weight: 550; + font-weight: bold; } &__orderStatus { - font-weight: 550; + font-weight: bold; &--finished{ color: $color_font_three; } diff --git a/src/pages/takeDelivery/components/ItemList/index.tsx b/src/pages/takeDelivery/components/ItemList/index.tsx index 1ffea1e..b189f13 100644 --- a/src/pages/takeDelivery/components/ItemList/index.tsx +++ b/src/pages/takeDelivery/components/ItemList/index.tsx @@ -52,7 +52,7 @@ const ItemList:FC = (props) => { - 单号:{itemData?.take_goods_order_no} + 单号:{itemData?.take_goods_order_no} {itemData?.take_goods_status === 0 && ( 提货中 )} @@ -60,18 +60,17 @@ const ItemList:FC = (props) => { {itemData?.take_goods_order_type_name} - + 货品信息: - {/* TODO: 面料字段、颜色字段 */} {itemData.delivery_product_nums}种面料,{itemData.delivery_product_color_nums}种颜色,共 {itemData?.sale_mode === EnumSaleMode.Bulk ? `${itemData?.take_roll}条` : `${formatMeterDiv(itemData?.take_meters)}米`} - + 供应信息: {itemData?.supplier_name || '空'} @@ -85,7 +84,7 @@ const ItemList:FC = (props) => { customClassName={styles.bottomBar__button} type='info' plain - customStyles={{ color: '#8e8e8e', borderColor: '#8e8e8e' }} + customStyles={{ color: '#636363', borderColor: '#c8c8c8' }} round onClick={() => handleDetail(itemData)}> 查看详情 diff --git a/src/pages/takeDelivery/index.module.scss b/src/pages/takeDelivery/index.module.scss index d31e751..c68e0d4 100644 --- a/src/pages/takeDelivery/index.module.scss +++ b/src/pages/takeDelivery/index.module.scss @@ -25,7 +25,7 @@ page { height: 100%; &--total { display: block; - margin-top: 24px; + margin-top: 20px; padding: 0 24px; font-size: 24px; color: #9d9d9d; diff --git a/src/pages/takeDelivery/index.tsx b/src/pages/takeDelivery/index.tsx index 97cdc3c..ad8ee95 100644 --- a/src/pages/takeDelivery/index.tsx +++ b/src/pages/takeDelivery/index.tsx @@ -14,6 +14,8 @@ import DeliveryStatusList from './components/DeliveryStatusList' import Popup from '@/components/popup' import DeliveryFilter, { SearchField } from './components/Filter' import TimePickerPopup from '@/components/timePickerPopup' +import Empty from '@/components/empty' +import { LIST_EMPTY_IMAGE } from '@/common/constant' type SearchData = { take_goods_order_no?: string // 提货单号 @@ -41,7 +43,7 @@ const Delivery: FC = () => { const { fetchData: FetchDeliveryOrderList, state: orderState } = TakeGoodsOrderList() //数据加载状态 const statusMore = useMemo(() => { - return dataLoadingStatus({ list: takeDeliveryOrderList.list, total: takeDeliveryOrderList.total, status: orderState.loading }) + return dataLoadingStatus({ list: takeDeliveryOrderList.list, total: takeDeliveryOrderList.total, status: orderState.loading! }) }, [takeDeliveryOrderList, orderState]) //输入搜索关键字 @@ -175,6 +177,7 @@ const Delivery: FC = () => { } statusMore={statusMore} selfonScrollToLower={getScrollToLower} refresherEnabled={true} diff --git a/src/pages/takeDeliveryDetail/index.module.scss b/src/pages/takeDeliveryDetail/index.module.scss index b848324..a7c1d5e 100644 --- a/src/pages/takeDeliveryDetail/index.module.scss +++ b/src/pages/takeDeliveryDetail/index.module.scss @@ -19,7 +19,7 @@ page { font-size: 28px; } .topBar__orderType { - color: rgba($color: #000000, $alpha: 0.6); + color: #6e6e6e; font-size: 28px; font-weight: 550; } @@ -44,6 +44,8 @@ page { justify-content: space-between; align-items: center; font-size: 28px; + font-weight: bold; + color: #424242; padding: 10px 0; } &--detail { @@ -53,6 +55,7 @@ page { align-items: center; padding: 10px 0; font-size: 28px; + color: #6e6e6e; } &--name { } @@ -71,20 +74,23 @@ page { .orderNo { font-size: 28px; + color: #424242; font-weight: 550; } .status { font-size: 28px; &--takingGoods { + font-weight: bold; color: $color_main; } &--finished { + font-weight: bold; color: $color_font_three; } } .divider { - margin: 24px 0; + margin: 20px 0 10px 0; } .total { margin-top: 24px; diff --git a/src/pages/takeDeliveryDetail/index.tsx b/src/pages/takeDeliveryDetail/index.tsx index aef8882..79a98a5 100644 --- a/src/pages/takeDeliveryDetail/index.tsx +++ b/src/pages/takeDeliveryDetail/index.tsx @@ -160,7 +160,7 @@ const TakeDeliveryDetail: FC = () => { return ( - + 提货单号:{detailInfo?.take_order_no} {detailInfo?.take_goods_status === 0 ? ( @@ -182,12 +182,12 @@ const TakeDeliveryDetail: FC = () => { {detailInfo?.take_goods_order_type !== 0 && ( <> - + 退货布匹附件 - + 退货物流附件 @@ -195,17 +195,17 @@ const TakeDeliveryDetail: FC = () => { )} - + 订单信息 - - - + + + {detailInfo?.take_goods_order_type !== 0 && ( - + 备注信息 {detailInfo?.remark}