s-material-react 0.1.1 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (86) hide show
  1. package/css/common/coupon.scss +73 -0
  2. package/css/common/index.scss +2 -0
  3. package/css/common/stepNum.scss +20 -0
  4. package/css/pages/cart.scss +130 -0
  5. package/css/pages/couponList.scss +204 -0
  6. package/css/pages/goodsDetail.scss +262 -2
  7. package/css/pages/index.scss +8 -3
  8. package/css/pages/mine.scss +96 -0
  9. package/css/pages/orderEntry.scss +3 -0
  10. package/css/pages/placeOrder.scss +104 -0
  11. package/css/pages/placeOrderResult.scss +100 -0
  12. package/dist/common/coupon/index.d.ts +2 -0
  13. package/dist/common/coupon/index.js +9 -0
  14. package/dist/common/mock/index.d.ts +283 -0
  15. package/dist/common/mock/index.js +571 -1
  16. package/dist/common/stepNum/index.d.ts +5 -0
  17. package/dist/common/stepNum/index.js +9 -0
  18. package/dist/components/AddressDetail/index.js +31 -16
  19. package/dist/components/AddressDetail/option.d.ts +2 -17
  20. package/dist/components/AddressDetail/option.js +31 -147
  21. package/dist/components/AddressList/index.js +2 -2
  22. package/dist/components/Cart/index.d.ts +2 -0
  23. package/dist/components/Cart/index.js +29 -0
  24. package/dist/components/Cart/useNumStep.d.ts +1 -0
  25. package/dist/components/Cart/useNumStep.js +7 -0
  26. package/dist/components/CouponList/index.d.ts +2 -0
  27. package/dist/components/CouponList/index.js +29 -0
  28. package/dist/components/Cube/index.js +2 -2
  29. package/dist/components/GoodsClassify/components/classifyFloor.js +4 -3
  30. package/dist/components/GoodsClassify/index.js +13 -5
  31. package/dist/components/GoodsDetail/components/goodsDetailCollection.d.ts +2 -0
  32. package/dist/components/GoodsDetail/components/goodsDetailCollection.js +60 -0
  33. package/dist/components/GoodsDetail/components/goodsDetailCoupon.js +5 -5
  34. package/dist/components/GoodsDetail/components/goodsDetailEvaluate.js +3 -2
  35. package/dist/components/GoodsDetail/components/goodsDetailHandleBar.d.ts +2 -0
  36. package/dist/components/GoodsDetail/components/goodsDetailHandleBar.js +7 -0
  37. package/dist/components/GoodsDetail/components/goodsDetailInfo.d.ts +1 -1
  38. package/dist/components/GoodsDetail/components/goodsDetailInfo.js +2 -2
  39. package/dist/components/GoodsDetail/components/goodsDetailPopup.d.ts +2 -0
  40. package/dist/components/GoodsDetail/components/goodsDetailPopup.js +27 -0
  41. package/dist/components/GoodsDetail/components/goodsDetailPromotion.d.ts +1 -1
  42. package/dist/components/GoodsDetail/components/goodsDetailPromotion.js +3 -3
  43. package/dist/components/GoodsDetail/components/goodsDetailSize.d.ts +1 -1
  44. package/dist/components/GoodsDetail/components/goodsDetailSize.js +6 -6
  45. package/dist/components/GoodsDetail/index.js +54 -14
  46. package/dist/components/GoodsGroup/index.js +2 -1
  47. package/dist/components/GoodsList/components/filter.d.ts +1 -0
  48. package/dist/components/GoodsList/components/filter.js +31 -0
  49. package/dist/components/GoodsList/hooks/useGoodsList.d.ts +5 -0
  50. package/dist/components/GoodsList/hooks/useGoodsList.js +49 -0
  51. package/dist/components/GoodsList/index.js +9 -60
  52. package/dist/components/Mine/components/menuList.d.ts +1 -0
  53. package/dist/components/Mine/components/menuList.js +21 -0
  54. package/dist/components/Mine/components/orderEntry.d.ts +1 -0
  55. package/dist/components/Mine/components/orderEntry.js +41 -0
  56. package/dist/components/Mine/index.d.ts +7 -0
  57. package/dist/components/Mine/index.js +14 -0
  58. package/dist/components/Notice/index.js +7 -11
  59. package/dist/components/OrderDetail/index.js +2 -2
  60. package/dist/components/OrderList/components/OrderListItem.js +0 -1
  61. package/dist/components/OrderList/components/orderItem.js +2 -2
  62. package/dist/components/OrderList/index.js +3 -2
  63. package/dist/components/PlaceOrder/index.d.ts +2 -0
  64. package/dist/components/PlaceOrder/index.js +12 -0
  65. package/dist/components/PlaceOrderResult/index.d.ts +2 -0
  66. package/dist/components/PlaceOrderResult/index.js +12 -0
  67. package/dist/components/SearchPage/index.d.ts +7 -1
  68. package/dist/components/SearchPage/index.js +5 -6
  69. package/dist/components/Slider/index.d.ts +10 -10
  70. package/dist/components/index.d.ts +5 -1
  71. package/dist/components/index.js +5 -1
  72. package/dist/options/index.js +1 -0
  73. package/dist/routerMap/index.d.ts +5 -0
  74. package/dist/routerMap/index.js +5 -0
  75. package/dist/utils/checkImgUrl.d.ts +1 -0
  76. package/dist/utils/checkImgUrl.js +9 -0
  77. package/dist/utils/index.d.ts +0 -0
  78. package/dist/utils/index.js +1 -0
  79. package/package.json +3 -5
  80. package/css/pages.zip +0 -0
  81. package/dist/components/AddressDetail/a.d.ts +0 -2
  82. package/dist/components/AddressDetail/a.js +0 -40
  83. package/dist/components/OrderEntry/index.d.ts +0 -2
  84. package/dist/components/OrderEntry/index.js +0 -9
  85. package/dist/components/Stamp/index.d.ts +0 -2
  86. package/dist/components/Stamp/index.js +0 -9
@@ -7,32 +7,72 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
7
7
  step((generator = generator.apply(thisArg, _arguments || [])).next());
8
8
  });
9
9
  };
10
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
10
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
11
11
  import { memo, useEffect, useState } from 'react';
12
12
  import { useComponent } from '@brushes/qj-simulate-component';
13
- import { SEARCH } from '../../static';
14
- import { Skeleton } from 'antd-mobile';
15
- import { getResourceGoodsInfoBySkuCode } from '@brushes/api';
13
+ import { queryPromotionListByGoodsCode } from '@brushes/api';
16
14
  import { _ } from '@brushes/tools';
15
+ import { getEnv } from '@brushes/api';
17
16
  import GoodsDetailPromotion from './components/goodsDetailPromotion';
18
17
  import GoodsDetailCoupon from './components/goodsDetailCoupon';
19
- const { isEmpty } = _;
18
+ import { goodsDetailFake } from '../../common/mock';
19
+ import GoodsDetailCollection from './components/goodsDetailCollection';
20
+ import GoodsDetailHandleBar from './components/goodsDetailHandleBar';
21
+ import { Slider } from '../Slider';
22
+ import GoodsDetailInfo from './components/goodsDetailInfo';
23
+ import GoodsDetailEvaluate from './components/goodsDetailEvaluate';
24
+ import GoodsDetailSize from './components/goodsDetailSize';
25
+ const flag = getEnv();
26
+ const { isEmpty, get } = _;
20
27
  const GoodsDetailJsx = () => {
21
- const { View, Text } = useComponent();
28
+ var _a;
22
29
  const [goods, setGoods] = useState({});
30
+ const { View, Text, Skeleton } = useComponent();
31
+ const [promotionArr, setPromotionArr] = useState([]);
32
+ const [checkCollectionObj, setCheckCollectionObj] = useState({});
33
+ const [sliderArr, setSliderArr] = useState([]);
34
+ const [tabActive, setTabActive] = useState(1);
35
+ const [popupVisible, setPopupVisible] = useState(false);
23
36
  useEffect(() => {
24
- getData();
37
+ getGoodsDetailData();
25
38
  }, []);
26
- const getData = () => __awaiter(void 0, void 0, void 0, function* () {
27
- const result = yield getResourceGoodsInfoBySkuCode({
28
- skuCode: '574562232464371754'
39
+ const getGoodsDetailData = () => __awaiter(void 0, void 0, void 0, function* () {
40
+ // const result = await getResourceGoodsInfoBySkuCode({
41
+ // skuCode: '639978727769698312'
42
+ // });
43
+ const goodsDetailResult = goodsDetailFake;
44
+ const promotionListParams = {
45
+ skuNo: goodsDetailResult.skuNo || '',
46
+ skuCode: goodsDetailResult.rsSkuDomainList[0].skuCode || '',
47
+ classtreeCode: goodsDetailResult.classtreeCode || '',
48
+ brandCode: goodsDetailResult.brandCode || '',
49
+ pntreeCode: goodsDetailResult.pntreeCode || '',
50
+ memberCode: goodsDetailResult.memberCode || ''
51
+ };
52
+ console.log(22, goodsDetailResult.rsGoodsFileDomainList);
53
+ const arr = get(goodsDetailResult, 'rsGoodsFileDomainList', []);
54
+ if (isEmpty(arr))
55
+ return;
56
+ const sliderData = arr.map((item) => {
57
+ return {
58
+ imgUrl: item.goodsFileUrl,
59
+ link: ''
60
+ };
29
61
  });
30
- console.log(22, result);
31
- setGoods(result);
62
+ setSliderArr(sliderData);
63
+ setGoods(goodsDetailResult);
64
+ getPromotionData(promotionListParams);
32
65
  });
33
- return (_jsx(View, Object.assign({ className: 'GoodsDetailWrap' }, { children: isEmpty(goods) ? (_jsxs(_Fragment, { children: [_jsx(Skeleton, { animated: true, style: {
66
+ const getPromotionData = (params) => __awaiter(void 0, void 0, void 0, function* () {
67
+ const result = yield queryPromotionListByGoodsCode(params);
68
+ setPromotionArr(result);
69
+ });
70
+ return (_jsx(View, Object.assign({ className: 'GoodsDetailWrap', style: {
71
+ height: flag ? '100vh' : '600px',
72
+ paddingBottom: flag ? '100vh' : '60px'
73
+ } }, { children: isEmpty(goods) ? (_jsxs(View, Object.assign({ className: 'skeleton' }, { children: [_jsx(Skeleton, { animated: true, style: {
34
74
  '--width': '100%',
35
75
  '--height': '300px'
36
- } }), _jsx(Skeleton.Title, { animated: true }), _jsx(Skeleton.Paragraph, { lineCount: 10, animated: true })] })) : (_jsxs(_Fragment, { children: [_jsxs(View, Object.assign({ className: 'goodsDetail-topInfo' }, { children: [_jsxs(View, { children: [_jsx(Text, Object.assign({ className: 'name' }, { children: goods === null || goods === void 0 ? void 0 : goods.goodsName })), _jsxs(Text, Object.assign({ className: 'price' }, { children: ["\uFFE5", goods === null || goods === void 0 ? void 0 : goods.pricesetNprice.toFixed(2)] }))] }), _jsxs(View, Object.assign({ className: 'rPart' }, { children: [_jsx("img", { src: SEARCH, alt: "", className: 'icon' }), _jsx(Text, Object.assign({ className: 'txt' }, { children: "\u5DF2\u6536\u85CF" }))] }))] })), _jsx(GoodsDetailPromotion, {}), _jsx(GoodsDetailCoupon, {})] })) })));
76
+ } }), _jsx(Skeleton.Title, { animated: true }), _jsx(Skeleton.Paragraph, { lineCount: 10, animated: true })] }))) : (_jsxs(_Fragment, { children: [_jsx(View, Object.assign({ className: 'topSlider' }, { children: _jsx(Slider, { selectImg: sliderArr }) })), _jsxs(View, Object.assign({ className: 'goodsDetail-topInfo' }, { children: [_jsxs(View, { children: [_jsx(Text, Object.assign({ className: 'name' }, { children: goods === null || goods === void 0 ? void 0 : goods.goodsName })), _jsxs(Text, Object.assign({ className: 'price' }, { children: ["\uFFE5", (_a = goods === null || goods === void 0 ? void 0 : goods.pricesetNprice) === null || _a === void 0 ? void 0 : _a.toFixed(2)] }))] }), _jsx(View, Object.assign({ className: 'rPart' }, { children: _jsx(GoodsDetailCollection, { goods: goods, checkCollectionObj: checkCollectionObj, setCheckCollectionObj: setCheckCollectionObj }) }))] })), _jsx(GoodsDetailSize, { goods: goods, popupVisible: popupVisible, setPopupVisible: setPopupVisible }), _jsx(GoodsDetailPromotion, { promotionList: promotionArr }), _jsx(GoodsDetailCoupon, {}), _jsxs(View, Object.assign({ className: 'goodsDetailTab' }, { children: [_jsxs(View, Object.assign({ className: 'tabs' }, { children: [_jsxs(Text, Object.assign({ className: `tabsItem ${tabActive === 1 ? 'active' : ''}`, onClick: () => setTabActive(1) }, { children: ["\u5546\u54C1\u8BE6\u60C5", _jsx(Text, { className: 'line' })] })), _jsxs(Text, Object.assign({ className: `tabsItem ${tabActive === 2 ? 'active' : ''}`, onClick: () => setTabActive(2) }, { children: ["\u8BC4\u4EF7", _jsx(Text, { className: 'line' })] }))] })), _jsx(View, Object.assign({ className: 'group' }, { children: tabActive === 1 ? _jsx(GoodsDetailInfo, { goods: goods }) : _jsx(GoodsDetailEvaluate, {}) }))] })), _jsx(GoodsDetailHandleBar, {})] })) })));
37
77
  };
38
78
  export const GoodsDetail = memo(GoodsDetailJsx);
@@ -1,8 +1,9 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { memo, useEffect, useState } from 'react';
3
- import { JumboTabs } from 'antd-mobile';
3
+ import { antdMobile } from '@brushes/qj-simulate-component';
4
4
  import { _ } from '@brushes/tools';
5
5
  import { Goods } from '../Goods';
6
+ const { JumboTabs } = antdMobile;
6
7
  const { isUndefined, isEmpty } = _;
7
8
  const GoodsGroupJsx = ({ defaultValue = [], type, selectGoodsGroup = [], marginTop, marginBottom, borderRadius }) => {
8
9
  const [list, setList] = useState(defaultValue);
@@ -0,0 +1 @@
1
+ export declare const Filter: () => JSX.Element;
@@ -0,0 +1,31 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { useState } from 'react';
3
+ import { useComponent } from '@brushes/qj-simulate-component';
4
+ const dataConfig = [
5
+ {
6
+ name: '默认',
7
+ code: 'pricesetNprice'
8
+ },
9
+ {
10
+ name: '新品',
11
+ code: ''
12
+ },
13
+ {
14
+ name: '销量',
15
+ code: 'goodsSalesvolume'
16
+ },
17
+ {
18
+ name: '价格',
19
+ code: 'pricesetNprice'
20
+ }
21
+ ];
22
+ export const Filter = () => {
23
+ const { View } = useComponent();
24
+ const [active, setActive] = useState(0);
25
+ const handleSort = (e) => {
26
+ const { index, type } = e.target.dataset;
27
+ setActive(index);
28
+ console.log(30, type);
29
+ };
30
+ return (_jsx(View, Object.assign({ className: 'sortWrap' }, { children: dataConfig.map((item, index) => (_jsx(View, Object.assign({ "data-index": index, "data-type": item.code, className: `sortItem ${active === index ? 'active' : ''}`, onClick: handleSort }, { children: item.name }), index))) })));
31
+ };
@@ -0,0 +1,5 @@
1
+ export declare function useGoodsList(classtreeCode: string): {
2
+ loading: boolean;
3
+ getData: (sortField?: string, order?: string) => Promise<void>;
4
+ list: never[];
5
+ };
@@ -0,0 +1,49 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ import { useEffect, useRef, useState } from 'react';
11
+ import { find } from '@brushes/api';
12
+ import { _ } from '@brushes/tools';
13
+ const { isEmpty } = _;
14
+ export function useGoodsList(classtreeCode) {
15
+ const isCanScroll = useRef(true);
16
+ const num = useRef(0);
17
+ const [list, setList] = useState([]);
18
+ // const sortField = useRef('pricesetNprice');
19
+ // const order = useRef('asc');
20
+ const [loading, setLoading] = useState(false);
21
+ useEffect(() => {
22
+ getData();
23
+ }, []);
24
+ const getData = (sortField = 'pricesetNprice', order = 'asc') => __awaiter(this, void 0, void 0, function* () {
25
+ if (!isCanScroll.current)
26
+ return;
27
+ ++num.current;
28
+ setLoading(true);
29
+ const response = yield find({
30
+ distinctField: 'goodsNo',
31
+ sortField: sortField,
32
+ order: order,
33
+ goodsType: '00,50',
34
+ page: num.current,
35
+ rows: 10
36
+ // classtreeCode,
37
+ });
38
+ if (isEmpty(response.list)) {
39
+ isCanScroll.current = false;
40
+ }
41
+ setLoading(false);
42
+ setList((prevState) => prevState.concat(response.list));
43
+ });
44
+ return {
45
+ loading,
46
+ getData,
47
+ list
48
+ };
49
+ }
@@ -1,66 +1,15 @@
1
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
- return new (P || (P = Promise))(function (resolve, reject) {
4
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
- step((generator = generator.apply(thisArg, _arguments || [])).next());
8
- });
9
- };
10
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
11
- import { memo, useEffect, useRef, useState } from 'react';
12
- import { Loading, ScrollView, useComponent } from '@brushes/qj-simulate-component';
13
- import { find } from '@brushes/api';
2
+ import { memo } from 'react';
3
+ import { Loading, navigatorImpl, ScrollView, useComponent } from '@brushes/qj-simulate-component';
14
4
  import { QjMobileIcon } from '../../common/icon';
15
- const GoodsListJsx = () => {
5
+ import { Filter } from './components/filter';
6
+ import { useGoodsList } from './hooks/useGoodsList';
7
+ import { routerMap } from '../../routerMap';
8
+ const GoodsListJsx = ({ classtreeCode = '' }) => {
16
9
  const { View, Text } = useComponent();
17
- const [list, setList] = useState([]);
18
- const [active, setActive] = useState('1');
19
- const sortField = useRef('pricesetNprice');
20
- const order = useRef('asc');
21
- const [loading, setLoading] = useState(false);
22
- useEffect(() => {
23
- getData();
24
- }, []);
25
- const getData = (sortField = 'pricesetNprice', order = 'asc') => __awaiter(void 0, void 0, void 0, function* () {
26
- setLoading(true);
27
- const response = yield find({
28
- distinctField: 'goodsNo',
29
- sortField: sortField,
30
- order: order,
31
- goodsType: '00,50',
32
- page: 1,
33
- rows: 10
34
- });
35
- setLoading(false);
36
- setList((prevState) => prevState.concat(response.list));
37
- });
38
- const handleSort = (e) => {
39
- const type = e.target.dataset.type;
40
- setActive(type);
41
- console.log(30, sortField, order, type);
42
- // switch (type) {
43
- // case '1':
44
- // sortField.current = 'pricesetNprice';
45
- // order.current = 'asc';
46
- // break
47
- // case '2':
48
- // sortField.current = '';
49
- // order.current = 'desc';
50
- // break;
51
- // case '3':
52
- // sortField.current = 'pricesetNprice';
53
- // order.current = type === '3' && order.current === 'asc' ? 'desc' : 'asc'
54
- // break
55
- // case '4':
56
- // sortField.current = 'pricesetNprice';
57
- // order.current = type === '4' && order.current === 'asc' ? 'desc' : 'asc'
58
- // break
59
- // }
60
- getData(sortField.current, order.current);
61
- };
62
- return (_jsxs(View, Object.assign({ className: 'goodsList' }, { children: [_jsxs(View, Object.assign({ className: 'topInfo' }, { children: [_jsxs(View, Object.assign({ className: 'search' }, { children: [_jsx(QjMobileIcon, { value: "fenxiang" }), _jsx(Text, Object.assign({ className: 'title' }, { children: "\u641C\u7D22\u5546\u54C1" }))] })), _jsxs(View, Object.assign({ className: 'sortWrap' }, { children: [_jsx(View, Object.assign({ className: `sortItem ${active === '1' ? 'active' : ''}`, onClick: handleSort }, { children: "\u9ED8\u8BA4" })), _jsx(View, Object.assign({ "data-type": 'pricesetNprice', className: `sortItem ${active === '2' ? 'active' : ''}`, onClick: handleSort }, { children: "\u65B0\u54C1" })), _jsx(View, Object.assign({ "data-order": order.current === 'asc' ? 'desc' : 'asc', className: `sortItem ${active === '3' ? 'active' : ''}`, onClick: handleSort }, { children: "\u9500\u91CF" })), _jsx(View, Object.assign({ "data-order": order.current === 'asc' ? 'desc' : 'asc', className: `sortItem ${active === '4' ? 'active' : ''}`, onClick: handleSort }, { children: "\u4EF7\u683C" }))] }))] })), _jsx(View, Object.assign({ className: 'listWrap' }, { children: _jsxs(ScrollView, Object.assign({ onScroll: getData, style: { height: '100vh' } }, { children: [_jsx(View, Object.assign({ className: 'list' }, { children: list.map((item) => {
63
- return (_jsxs(View, Object.assign({ className: 'listItem' }, { children: [_jsx(View, { className: 'img', style: { backgroundImage: `url(${item.dataPic})` } }), _jsx(Text, Object.assign({ className: 'name' }, { children: item.goodsName })), _jsxs(Text, Object.assign({ className: 'price' }, { children: ["\uFFE5 ", item.pricesetNprice.toFixed(2)] }))] }), item.skuCode));
10
+ const { loading, getData, list } = useGoodsList(classtreeCode);
11
+ return (_jsxs(View, Object.assign({ className: 'goodsList' }, { children: [_jsxs(View, Object.assign({ className: 'topInfo' }, { children: [_jsxs(View, Object.assign({ className: 'search' }, { children: [_jsx(QjMobileIcon, { value: "fenxiang" }), _jsx(Text, Object.assign({ className: 'title' }, { children: "\u641C\u7D22\u5546\u54C1" }))] })), _jsx(Filter, {})] })), _jsx(View, Object.assign({ className: 'listWrap' }, { children: _jsxs(ScrollView, Object.assign({ onScroll: () => getData(), style: { height: '100vh' } }, { children: [_jsx(View, Object.assign({ className: 'list' }, { children: list.map((item) => {
12
+ return (_jsxs(View, Object.assign({ onClick: () => navigatorImpl(routerMap.goodDetail), className: 'listItem' }, { children: [_jsx(View, { className: 'img', style: { backgroundImage: `url(${item.dataPic})` } }), _jsx(Text, Object.assign({ className: 'name' }, { children: item.goodsName })), _jsxs(Text, Object.assign({ className: 'price' }, { children: ["\uFFE5 ", item.pricesetNprice.toFixed(2)] }))] }), item.skuCode));
64
13
  }) })), loading ? _jsx(Loading, {}) : null] })) }))] })));
65
14
  };
66
15
  export const GoodsList = memo(GoodsListJsx);
@@ -0,0 +1 @@
1
+ export declare const MenuList: () => JSX.Element;
@@ -0,0 +1,21 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useRef } from 'react';
3
+ import { useComponent } from '@brushes/qj-simulate-component';
4
+ export const MenuList = () => {
5
+ const { View, Text } = useComponent();
6
+ const config = useRef([
7
+ {
8
+ icon: '',
9
+ label: '优惠券',
10
+ link: ''
11
+ },
12
+ {
13
+ icon: '',
14
+ label: '地址管理',
15
+ link: ''
16
+ }
17
+ ]);
18
+ return (_jsx(View, Object.assign({ className: 'menuList' }, { children: config.current.map((item, idx) => {
19
+ return (_jsxs(View, Object.assign({ className: 'menuListItem' }, { children: [_jsxs(View, Object.assign({ className: 'lPart' }, { children: [_jsx(Text, { className: 'icon' }), _jsx(Text, Object.assign({ className: 'label' }, { children: item.label }))] })), _jsx(Text, { className: 'tag' })] }), idx));
20
+ }) })));
21
+ };
@@ -0,0 +1 @@
1
+ export declare const OrderEntry: () => JSX.Element;
@@ -0,0 +1,41 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { navigatorImpl, useComponent } from '@brushes/qj-simulate-component';
3
+ import { AFTERSALE, FINISH, OBLIGATION, ORDERTOPAY, ORDERTORECEIVE } from '../../../static';
4
+ import { useRef } from 'react';
5
+ import { routerMap } from '../../../routerMap';
6
+ export const OrderEntry = () => {
7
+ const { View, Text, Badge, Image } = useComponent();
8
+ const config = useRef([
9
+ {
10
+ badge: 5,
11
+ label: '待付款',
12
+ icon: OBLIGATION,
13
+ link: ''
14
+ },
15
+ {
16
+ badge: 0,
17
+ label: '待发货',
18
+ icon: ORDERTOPAY,
19
+ link: ''
20
+ },
21
+ {
22
+ badge: 0,
23
+ label: '待收货',
24
+ icon: ORDERTORECEIVE,
25
+ link: ''
26
+ },
27
+ {
28
+ badge: 0,
29
+ label: '已完成',
30
+ icon: FINISH,
31
+ link: ''
32
+ },
33
+ {
34
+ badge: 0,
35
+ label: '退换/售后',
36
+ icon: AFTERSALE,
37
+ link: ''
38
+ }
39
+ ]);
40
+ return (_jsxs(View, Object.assign({ className: 'orderEntry' }, { children: [_jsxs(View, Object.assign({ className: 'title' }, { children: [_jsx(View, Object.assign({ className: 'name' }, { children: "\u6211\u7684\u8BA2\u5355" })), _jsx(View, Object.assign({ className: 'more', onClick: () => navigatorImpl(routerMap.order) }, { children: "\u67E5\u770B\u5168\u90E8" }))] })), _jsx(View, Object.assign({ className: 'content' }, { children: config.current.map((item, index) => (_jsxs(View, Object.assign({ onClick: () => navigatorImpl(`${routerMap.order}?id=${index + 1}`), className: 'contentItem' }, { children: [item.badge ? (_jsx(Badge, Object.assign({ content: item.badge, color: '#000', style: { color: '#fff', fontSize: 12 } }, { children: _jsx(Image, { src: item.icon, mode: 'widthFix', className: 'icon' }) }))) : (_jsx(Image, { src: item.icon, mode: 'widthFix', className: 'icon' })), _jsx(Text, Object.assign({ className: 'subTitle' }, { children: item.label }))] }), index))) }))] })));
41
+ };
@@ -0,0 +1,7 @@
1
+ /// <reference types="react" />
2
+ interface MineType {
3
+ avatarStyle: number;
4
+ banner: number;
5
+ }
6
+ export declare const Mine: import("react").NamedExoticComponent<MineType>;
7
+ export {};
@@ -0,0 +1,14 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { memo } from 'react';
3
+ import { useComponent } from '@brushes/qj-simulate-component';
4
+ import { getEnv } from '@brushes/api';
5
+ import { OrderEntry } from './components/orderEntry';
6
+ import { MenuList } from './components/menuList';
7
+ const MineJsx = ({ avatarStyle, banner }) => {
8
+ const { View, Text } = useComponent();
9
+ const flag = getEnv();
10
+ return (_jsxs(View, Object.assign({ className: 'mine', style: {
11
+ height: flag ? '100vh' : '600px'
12
+ } }, { children: [_jsxs(View, Object.assign({ className: 'topBoard' }, { children: [_jsx(View, { className: 'icon' }), _jsx(View, { className: 'icon' })] })), _jsxs(View, Object.assign({ className: 'userSetting' }, { children: [_jsxs(View, Object.assign({ className: 'lPart' }, { children: [_jsx(Text, Object.assign({ className: 'name' }, { children: "\u5F20\u4E09" })), _jsx(View, Object.assign({ className: 'link' }, { children: '编辑个人资料 >' }))] })), _jsx("img", { src: "", alt: "", className: 'avatar', style: { borderRadius: avatarStyle ? '50%' : '2px' } })] })), _jsx(OrderEntry, {}), _jsx(MenuList, {}), banner ? _jsx("img", { className: 'banner', src: "", alt: "" }) : null] })));
13
+ };
14
+ export const Mine = memo(MineJsx);
@@ -1,4 +1,4 @@
1
- import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { useComponent } from '@brushes/qj-simulate-component';
3
3
  import { getEnv } from '@brushes/api';
4
4
  export const Notice = ({ text, backgroundColor, color, fontSize, marginBottom, borderColor }) => {
@@ -7,14 +7,10 @@ export const Notice = ({ text, backgroundColor, color, fontSize, marginBottom, b
7
7
  console.log(22, flag);
8
8
  if (!View)
9
9
  return null;
10
- return (_jsx(_Fragment, { children: flag ? (_jsx("div", { children: "12312312" })) : (
11
- // <AtNoticebar marquee icon='volume-plus'>
12
- // { text }
13
- // </AtNoticebar>
14
- _jsx(View, Object.assign({ style: { marginBottom } }, { children: _jsx(NoticeBar, { speed: 50, style: {
15
- '--border-color': borderColor,
16
- '--font-size': fontSize + 'px',
17
- '--background-color': backgroundColor,
18
- '--text-color': color
19
- }, content: text, color: "alert" }) }))) }));
10
+ return (_jsx(View, Object.assign({ style: { marginBottom } }, { children: _jsx(NoticeBar, { speed: 50, style: {
11
+ '--border-color': borderColor,
12
+ '--font-size': fontSize + 'px',
13
+ '--background-color': backgroundColor,
14
+ '--text-color': color
15
+ }, content: text, color: "alert" }) })));
20
16
  };
@@ -1,10 +1,10 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { memo } from 'react';
3
- import { useComponent } from '@brushes/qj-simulate-component';
3
+ import { useComponent, antdMobile } from '@brushes/qj-simulate-component';
4
4
  import { ORDERTOPAY } from '../../static';
5
5
  import { CardJsx } from '../../common/card';
6
- import { Button } from 'antd-mobile';
7
6
  import { result } from '../OrderList/components/mock';
7
+ const { Button } = antdMobile;
8
8
  const OrderDetailJsx = () => {
9
9
  const { View, Text } = useComponent();
10
10
  return (_jsxs(View, Object.assign({ className: 'orderDetail' }, { children: [_jsx(View, Object.assign({ className: 'orderDetailTopTitle' }, { children: _jsxs(View, Object.assign({ className: 'orderDetailTopTitleContent' }, { children: [_jsx(Text, Object.assign({ className: 'title' }, { children: "\u8BA2\u5355\u8BE6\u60C5" })), _jsxs(View, Object.assign({ className: 'subTitleWrap' }, { children: [_jsx("img", { src: ORDERTOPAY, alt: "", className: 'subTitleIcon' }), _jsx(Text, Object.assign({ className: 'subTitle' }, { children: "\u5DF2\u5B8C\u6210" }))] }))] })) })), _jsx(View, Object.assign({ className: 'orderDetailContent' }, { children: _jsxs(View, Object.assign({ style: { position: 'relative', top: -26 } }, { children: [_jsxs(View, Object.assign({ className: 'addressInfo' }, { children: [_jsx(View, Object.assign({ className: 'lPart' }, { children: _jsx("img", { src: ORDERTOPAY, alt: "", className: 'icon' }) })), _jsxs(View, Object.assign({ className: 'mPart' }, { children: [_jsxs(View, Object.assign({ className: 'personInfo' }, { children: [_jsx(Text, Object.assign({ className: 'personName' }, { children: "\u674E\u660E\u771F" })), _jsx(Text, Object.assign({ className: 'personPhone' }, { children: "13679126756" }))] })), _jsx(View, Object.assign({ className: 'address' }, { children: "\u4E0A\u6D77\u5E02\u95F5\u884C\u533A\u53E4\u7F8E\u8DEF\u534E\u4E00\u65B0\u57CE18-201" }))] })), _jsx(View, Object.assign({ className: 'rPart' }, { children: _jsx("img", { src: ORDERTOPAY, alt: "", className: 'icon' }) }))] })), _jsxs(View, Object.assign({ className: 'orderDetailGoodsWrap' }, { children: [result.rows[0].goodsList.map((item) => (_jsx(CardJsx, Object.assign({}, item), item.contractGoodsId))), _jsxs(View, Object.assign({ className: 'btnGroup' }, { children: [_jsx(Button, Object.assign({ shape: "rounded", className: 'btn white' }, { children: "\u67E5\u770B\u7269\u6D41" })), _jsx(Button, Object.assign({ shape: "rounded", className: 'btn black' }, { children: "\u786E\u8BA4\u6536\u8D27" }))] })), _jsxs(View, Object.assign({ className: 'priceInfo' }, { children: [_jsxs(View, Object.assign({ className: 'priceInfoFloor top' }, { children: [_jsx(View, Object.assign({ className: 'totalNum' }, { children: "\u51712\u4EF6\u5546\u54C1" })), _jsx(View, Object.assign({ className: 'totalPrice' }, { children: "\u5408\u8BA1 \uFFE51960.00" }))] })), _jsxs(View, Object.assign({ className: 'priceInfoFloor' }, { children: [_jsx(View, Object.assign({ className: 'totalNum' }, { children: "\u5546\u54C1\u603B\u989D" })), _jsx(View, Object.assign({ className: 'totalPrice' }, { children: "\u5408\u8BA1 \uFFE51960.00" }))] })), _jsxs(View, Object.assign({ className: 'priceInfoFloor' }, { children: [_jsx(View, Object.assign({ className: 'totalNum' }, { children: "\u4F18\u60E0" })), _jsx(View, Object.assign({ className: 'totalPrice' }, { children: "\u5408\u8BA1 \uFFE51960.00" }))] }))] }))] })), _jsxs(View, Object.assign({ className: 'express' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u914D\u9001\u65B9\u5F0F" })), _jsx(View, Object.assign({ className: 'name' }, { children: "\u5FEB\u9012" }))] })), _jsxs(View, Object.assign({ className: 'orderInfo' }, { children: [_jsx(View, Object.assign({ className: 'orderInfoItem' }, { children: _jsx(View, Object.assign({ className: 'label' }, { children: "\u8BA2\u5355\u4FE1\u606F" })) })), _jsxs(View, Object.assign({ className: 'orderInfoItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u4E70\u5BB6\u7559\u8A00" })), _jsx(View, Object.assign({ className: 'name' }, { children: "\u5FEB\u70B9\u53D1\u8D27\u54DF" }))] })), _jsxs(View, Object.assign({ className: 'orderInfoItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u8BA2\u5355\u7F16\u53F7" })), _jsx(View, Object.assign({ className: 'name' }, { children: "243728743824782" }))] })), _jsxs(View, Object.assign({ className: 'orderInfoItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u7CFB\u7EDF\u7F16\u53F7" })), _jsx(View, Object.assign({ className: 'name' }, { children: "243728743824782" }))] })), _jsxs(View, Object.assign({ className: 'orderInfoItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u4E0B\u5355\u65F6\u95F4" })), _jsx(View, Object.assign({ className: 'name' }, { children: "2022-10-01 10:00:00" }))] }))] })), _jsxs(View, Object.assign({ className: 'btnGroupFooter' }, { children: [_jsx(Button, Object.assign({ shape: "rounded" }, { children: "\u7533\u8BF7\u9000\u6B3E" })), _jsx(Button, Object.assign({ shape: "rounded" }, { children: "\u7533\u8BF7\u552E\u540E" }))] }))] })) }))] })));
@@ -27,7 +27,6 @@ function OrderListItemJsx({ item }) {
27
27
  // console.log(17, e.detail);
28
28
  try {
29
29
  const data = yield queryContractPageC({ page: 1, rows: 10 });
30
- console.log(19, data);
31
30
  setData((val) => [...val, ...result.rows]);
32
31
  setLoading(false);
33
32
  }
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { useComponent } from '@brushes/qj-simulate-component';
2
+ import { useComponent, antdMobile } from '@brushes/qj-simulate-component';
3
3
  import { CardJsx } from '../../../common/card';
4
- import { Button } from 'antd-mobile';
4
+ const { Button } = antdMobile;
5
5
  export function Item({ contractBillcode, dataBmoney, dataBnum, goodsList }) {
6
6
  const { View } = useComponent();
7
7
  return (_jsxs(View, Object.assign({ className: 'orderListItem' }, { children: [_jsxs(View, Object.assign({ className: 'topInfo' }, { children: [_jsxs(View, Object.assign({ className: 'orderNo' }, { children: ["\u8BA2\u5355\u53F7: ", contractBillcode, _jsx(Button, Object.assign({ className: 'copy', size: "mini", fill: 'outline' }, { children: "\u590D\u5236" }))] })), _jsx(View, Object.assign({ className: 'status' }, { children: "\u5F85\u652F\u4ED8" }))] })), _jsxs(View, Object.assign({ className: 'goodsItemWrap' }, { children: [goodsList.map((item) => (_jsx(CardJsx, Object.assign({}, item), item.contractGoodsId))), _jsxs(View, Object.assign({ className: 'allInfo' }, { children: [_jsxs(View, Object.assign({ className: 'totalNum' }, { children: ["\u5171", dataBnum, "\u4EF6\u5546\u54C1"] })), _jsxs(View, Object.assign({ className: 'totalPrice' }, { children: ["\u5408\u8BA1 \uFFE5", dataBmoney] }))] }))] })), _jsxs(View, Object.assign({ className: 'btnGroup' }, { children: [_jsx(Button, Object.assign({ shape: "rounded", className: 'btn white' }, { children: "\u67E5\u770B\u7269\u6D41" })), _jsx(Button, Object.assign({ shape: "rounded", className: 'btn black' }, { children: "\u786E\u8BA4\u6536\u8D27" }))] }))] })));
@@ -2,7 +2,8 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { memo, useRef } from 'react';
3
3
  import { useComponent, Tabs } from '@brushes/qj-simulate-component';
4
4
  import { OrderListItem } from './components/OrderListItem';
5
- const OrderListJsx = () => {
5
+ const OrderListJsx = ({ defaultIndex = 0 }) => {
6
+ console.log('location', defaultIndex);
6
7
  const { View } = useComponent();
7
8
  const tabs = useRef([
8
9
  { name: '全部', code: 'all' },
@@ -11,6 +12,6 @@ const OrderListJsx = () => {
11
12
  { name: '待收货', code: 'receive' },
12
13
  { name: '已完成', code: 'done' }
13
14
  ]);
14
- return (_jsx(View, Object.assign({ className: 'order-container' }, { children: _jsx(Tabs, { tabs: tabs.current, render: (item) => (_jsx(View, Object.assign({ className: 'orderList' }, { children: _jsx(OrderListItem, { item: item }) }))) }) })));
15
+ return (_jsx(View, Object.assign({ className: 'order-container' }, { children: _jsx(Tabs, { defaultIndex: defaultIndex, tabs: tabs.current, render: (item) => (_jsx(View, Object.assign({ className: 'orderList' }, { children: _jsx(OrderListItem, { item: item }) }))) }) })));
15
16
  };
16
17
  export const OrderList = memo(OrderListJsx);
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export declare const PlaceOrder: import("react").MemoExoticComponent<() => JSX.Element>;
@@ -0,0 +1,12 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { memo } from 'react';
3
+ import { useComponent } from '@brushes/qj-simulate-component';
4
+ import { getEnv } from '@brushes/api';
5
+ const flag = getEnv();
6
+ const PlaceOrderJsx = () => {
7
+ const { View, Text } = useComponent();
8
+ return (_jsxs(View, Object.assign({ className: 'placeOrder', style: {
9
+ height: flag ? '100vh' : '600px'
10
+ } }, { children: [_jsxs(View, Object.assign({ className: 'chooseAddress' }, { children: [_jsxs(View, Object.assign({ className: 'group' }, { children: [_jsx(Text, { className: 'local' }), _jsx(Text, Object.assign({ className: 'address' }, { children: "\u9009\u62E9\u6536\u8D27\u5730\u5740" }))] })), _jsx(Text, { className: 'arrow' })] })), _jsxs(View, Object.assign({ className: 'info blcWrap' }, { children: [_jsxs(View, Object.assign({ className: 'express blcItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u914D\u9001\u65B9\u5F0F" })), _jsx(View, Object.assign({ className: 'value' }, { children: "\u5FEB\u9012" }))] })), _jsxs(View, Object.assign({ className: 'coupon blcItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u4F7F\u7528\u4F18\u60E0" })), _jsxs(View, Object.assign({ className: 'value' }, { children: ["\u53EF\u9009\u62E9\u4F7F\u7528\u4F18\u60E0\u7801/\u4F18\u60E0\u7801", _jsx(Text, { className: 'icon' })] }))] }))] })), _jsxs(View, Object.assign({ className: 'price blcWrap' }, { children: [_jsx(View, Object.assign({ className: 'title' }, { children: "\u4EF7\u683C\u660E\u7EC6" })), _jsxs(View, Object.assign({ className: 'express blcItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u5546\u54C1\u603B\u91D1\u989D" })), _jsx(View, Object.assign({ className: 'value' }, { children: "\uFFE5 890" }))] })), _jsxs(View, Object.assign({ className: 'coupon blcItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u4F18\u60E0\u91D1\u989D" })), _jsx(View, Object.assign({ className: 'value' }, { children: "\u4E0D\u4F7F\u7528\u4F18\u60E0" }))] })), _jsxs(View, Object.assign({ className: 'express blcItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u8FD0\u8D39" })), _jsx(View, Object.assign({ className: 'value' }, { children: "\uFFE5 9000" }))] })), _jsxs(View, Object.assign({ className: 'all blcItem' }, { children: [_jsx(View, Object.assign({ className: 'label' }, { children: "\u603B\u8BA1" })), _jsx(View, Object.assign({ className: 'value', style: { color: '#000' } }, { children: "\uFFE5 9000" }))] }))] })), _jsxs(View, Object.assign({ className: 'placeOrderFooter' }, { children: [_jsx(Text, Object.assign({ className: 'price' }, { children: "\u5408\u8BA1: \uFFE517782.00" })), _jsx(View, Object.assign({ className: 'btn' }, { children: "\u63D0\u4EA4\u8BA2\u5355" }))] }))] })));
11
+ };
12
+ export const PlaceOrder = memo(PlaceOrderJsx);
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export declare const PlaceOrderResult: import("react").MemoExoticComponent<() => JSX.Element>;
@@ -0,0 +1,12 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { memo } from 'react';
3
+ import { useComponent } from '@brushes/qj-simulate-component';
4
+ import { getEnv } from '@brushes/api';
5
+ const flag = getEnv();
6
+ const PlaceOrderResultJsx = () => {
7
+ const { View, Text } = useComponent();
8
+ return (_jsx(View, Object.assign({ className: 'placeOrderResult', style: {
9
+ height: flag ? '100vh' : '600px'
10
+ } }, { children: _jsxs(View, Object.assign({ className: 'placeOrderResultContent' }, { children: [_jsx(Text, { className: 'icon' }), _jsxs(View, Object.assign({ className: 'tips' }, { children: [_jsx(Text, Object.assign({ className: 'title' }, { children: "\u8BA2\u5355\u652F\u4ED8\u6210\u529F" })), _jsx(Text, Object.assign({ className: 'tip' }, { children: "\u60A8\u7684\u8BA2\u5355\u5C06\u4FDD\u755915\u5206\u949F\uFF0C\u53EF\u70B9\u51FB\u4E0B\u65B9\u201C\u53BB\u652F\u4ED8\u201D\u5B8C\u6210\u8BA2\u5355" }))] })), _jsxs(View, Object.assign({ className: 'placeOrderResultWrap' }, { children: [_jsxs(View, Object.assign({ className: 'placeOrderResultItem' }, { children: [_jsx(Text, Object.assign({ className: 'label' }, { children: "\u8BA2\u5355\u53F7\uFF1A" })), _jsx(Text, Object.assign({ className: 'value' }, { children: "324324823748237" }))] })), _jsxs(View, Object.assign({ className: 'placeOrderResultItem' }, { children: [_jsx(Text, Object.assign({ className: 'label' }, { children: "\u5546\u54C1\u6570\u91CF\uFF1A" })), _jsx(Text, Object.assign({ className: 'value' }, { children: "1" }))] })), _jsxs(View, Object.assign({ className: 'placeOrderResultItem' }, { children: [_jsx(Text, Object.assign({ className: 'label' }, { children: "\u652F\u4ED8\u65B9\u5F0F\uFF1A" })), _jsx(Text, Object.assign({ className: 'value' }, { children: "\u5FAE\u4FE1\u652F\u4ED8" }))] })), _jsxs(View, Object.assign({ className: 'placeOrderResultItem' }, { children: [_jsx(Text, Object.assign({ className: 'label' }, { children: "\u652F\u4ED8\u91D1\u989D\uFF1A" })), _jsx(Text, Object.assign({ className: 'value' }, { children: "\uFFE5 9999.00" }))] }))] })), _jsxs(View, Object.assign({ className: 'btnGroup' }, { children: [_jsx(View, Object.assign({ className: 'btn black' }, { children: "\u67E5\u770B\u8BA2\u5355" })), _jsx(View, Object.assign({ className: 'btn white' }, { children: "\u7EE7\u7EED\u8D2D\u7269" }))] }))] })) })));
11
+ };
12
+ export const PlaceOrderResult = memo(PlaceOrderResultJsx);
@@ -1,2 +1,8 @@
1
1
  /// <reference types="react" />
2
- export declare const SearchPage: import("react").MemoExoticComponent<() => JSX.Element>;
2
+ interface SearchPageType {
3
+ placeholder: number;
4
+ placeholderText: string;
5
+ history: 1;
6
+ }
7
+ export declare const SearchPage: import("react").NamedExoticComponent<SearchPageType>;
8
+ export {};
@@ -2,14 +2,13 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { memo } from 'react';
3
3
  import { useComponent } from '@brushes/qj-simulate-component';
4
4
  import { SEARCH } from '../../static';
5
+ import { getEnv } from '@brushes/api';
6
+ const flag = getEnv();
5
7
  const fake = ['衣服', '裤子'];
6
- const SearchPageJsx = () => {
8
+ const SearchPageJsx = ({ placeholder, placeholderText, history }) => {
7
9
  const { View, Text } = useComponent();
8
- const handle = () => {
9
- console.log(123);
10
- };
11
- return (_jsxs(View, Object.assign({ className: 'searchPage' }, { children: [_jsxs(View, Object.assign({ className: 'search-title' }, { children: [_jsx("img", { src: SEARCH, alt: "" }), _jsx("input", { type: "text", className: 'content' }), _jsx(Text, Object.assign({ className: 'btn' }, { children: "\u53D6\u6D88" }))] })), _jsxs(View, Object.assign({ className: 'historyWrap' }, { children: [_jsxs(View, Object.assign({ className: 'title' }, { children: [_jsxs(View, Object.assign({ className: 'label' }, { children: [_jsx(View, { className: 'icon' }), "\u5386\u53F2\u641C\u7D22\u8BB0\u5F55"] })), _jsx(Text, Object.assign({ className: 'clear' }, { children: "\u6E05\u9664" }))] })), _jsx(View, Object.assign({ className: 'content' }, { children: fake.map((item, index) => {
10
+ return (_jsxs(View, Object.assign({ className: 'searchPage', style: { height: flag ? '100vh' : '600px' } }, { children: [_jsxs(View, Object.assign({ className: 'search-title' }, { children: [_jsx("img", { src: SEARCH, alt: "" }), _jsx("input", Object.assign({ type: "text", className: 'content' }, (placeholder ? { placeholder: placeholderText } : {}))), _jsx(Text, Object.assign({ className: 'btn' }, { children: "\u53D6\u6D88" }))] })), history ? (_jsxs(View, Object.assign({ className: 'historyWrap' }, { children: [_jsxs(View, Object.assign({ className: 'title' }, { children: [_jsxs(View, Object.assign({ className: 'label' }, { children: [_jsx(View, { className: 'icon' }), "\u5386\u53F2\u641C\u7D22\u8BB0\u5F55"] })), _jsx(Text, Object.assign({ className: 'clear' }, { children: "\u6E05\u9664" }))] })), _jsx(View, Object.assign({ className: 'content' }, { children: fake.map((item, index) => {
12
11
  return (_jsx(View, Object.assign({ className: 'historyItem' }, { children: item }), index));
13
- }) }))] }))] })));
12
+ }) }))] }))) : null] })));
14
13
  };
15
14
  export const SearchPage = memo(SearchPageJsx);
@@ -4,16 +4,16 @@ export interface itemType {
4
4
  link: string;
5
5
  }
6
6
  interface SwiperType {
7
- defaultValue: Array<itemType>;
8
- type: number;
9
- autoplay: boolean;
10
- autoplayInterval: number;
11
- direction: 'horizontal' | 'vertical';
12
- loop: boolean;
13
- marginTop: number;
14
- marginBottom: number;
15
- selectImg: Array<itemType>;
16
- imgHeight: {
7
+ defaultValue?: Array<itemType>;
8
+ type?: number;
9
+ autoplay?: boolean;
10
+ autoplayInterval?: number;
11
+ direction?: 'horizontal' | 'vertical';
12
+ loop?: boolean;
13
+ marginTop?: number;
14
+ marginBottom?: number;
15
+ selectImg?: Array<itemType>;
16
+ imgHeight?: {
17
17
  height: number;
18
18
  width: number;
19
19
  };
@@ -8,7 +8,6 @@ export * from './Service';
8
8
  export * from './Search';
9
9
  export * from './Slider';
10
10
  export * from './GoodsGroup';
11
- export * from './OrderEntry';
12
11
  export * from './OrderList';
13
12
  export * from './OrderDetail';
14
13
  export * from './ClassifyNav';
@@ -22,3 +21,8 @@ export * from './GoodsDetailPromotion';
22
21
  export * from './EvaluateList';
23
22
  export * from './AddressList';
24
23
  export * from './AddressDetail';
24
+ export * from './PlaceOrder';
25
+ export * from './PlaceOrderResult';
26
+ export * from './CouponList';
27
+ export * from './Cart';
28
+ export * from './Mine';
@@ -8,7 +8,6 @@ export * from './Service';
8
8
  export * from './Search';
9
9
  export * from './Slider';
10
10
  export * from './GoodsGroup';
11
- export * from './OrderEntry';
12
11
  export * from './OrderList';
13
12
  export * from './OrderDetail';
14
13
  export * from './ClassifyNav';
@@ -22,3 +21,8 @@ export * from './GoodsDetailPromotion';
22
21
  export * from './EvaluateList';
23
22
  export * from './AddressList';
24
23
  export * from './AddressDetail';
24
+ export * from './PlaceOrder';
25
+ export * from './PlaceOrderResult';
26
+ export * from './CouponList';
27
+ export * from './Cart';
28
+ export * from './Mine';
@@ -1,6 +1,7 @@
1
1
  import provinces from 'china-division/dist/provinces.json';
2
2
  import cities from 'china-division/dist/cities.json';
3
3
  import areas from 'china-division/dist/areas.json';
4
+ console.log(5, provinces);
4
5
  areas.forEach((area) => {
5
6
  const matchCity = cities.filter((city) => city.code === area.cityCode)[0];
6
7
  if (matchCity) {