oak-pay-business 2.2.0 → 2.2.2
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.
- package/es/aspects/withdraw.d.ts +4 -4
- package/es/checkers/order.js +39 -0
- package/es/components/account/detail/web.d.ts +1 -1
- package/es/components/account/detail/web.js +2 -2
- package/es/components/account/detail/web.pc.d.ts +1 -1
- package/es/components/account/detail/web.pc.js +2 -2
- package/es/components/account/detail/web.pc.module.less +68 -68
- package/es/components/accountOper/list/index.js +118 -6
- package/es/components/accountOper/list/index.json +10 -1
- package/es/components/accountOper/list/index.less +125 -0
- package/es/components/accountOper/list/index.xml +56 -0
- package/es/components/accountOper/list/locales/zh-CN.json +9 -1
- package/es/components/accountOper/list/mobile.module.less +48 -0
- package/es/components/accountOper/list/web.d.ts +12 -1
- package/es/components/accountOper/list/web.js +58 -24
- package/es/components/accountOper/list/web.module.less +27 -0
- package/es/components/accountOper/list/web.pc.d.ts +14 -2
- package/es/components/accountOper/list/web.pc.js +43 -8
- package/es/components/order/pay/index.js +1 -1
- package/es/components/order/pay/info.js +6 -6
- package/es/components/order/pay/info.module.less +24 -24
- package/es/components/order/pay/web.mobile.module.less +35 -35
- package/es/components/order/pay/web.pc.module.less +35 -35
- package/es/components/pay/detail/index.js +11 -0
- package/es/components/pay/detail/index.xml +10 -0
- package/es/components/pay/detail/locales/zh-CN.json +5 -1
- package/es/components/pay/detail/web.d.ts +1 -0
- package/es/components/pay/detail/web.js +12 -5
- package/es/components/pay/detail/web.pc.d.ts +1 -0
- package/es/components/pay/detail/web.pc.js +15 -5
- package/es/components/pay/list/web.pc.js +2 -0
- package/es/components/payConfig/upsert/offline/web.pc.module.less +4 -4
- package/es/components/payConfig/upsert/web.pc.module.less +10 -10
- package/es/components/withdraw/create/index.d.ts +1 -0
- package/es/components/withdraw/create/index.js +4 -0
- package/es/components/withdraw/create/index.xml +4 -0
- package/es/components/withdraw/create/locales/zh-CN.json +2 -1
- package/es/components/withdraw/create/web.d.ts +1 -0
- package/es/components/withdraw/create/web.js +6 -2
- package/es/components/withdraw/create/web.pc.d.ts +1 -0
- package/es/components/withdraw/create/web.pc.js +4 -1
- package/es/components/withdraw/display/web.pc.module.less +4 -2
- package/es/components/withdrawAccount/list/index.less +8 -0
- package/es/components/withdrawAccount/list/index.xml +6 -1
- package/es/configuration/attrUpdateMatrix.js +6 -1
- package/es/context/BackendRuntimeContext.d.ts +1 -1
- package/es/data/i18n.js +21 -3
- package/es/entities/Order.d.ts +4 -3
- package/es/entities/Order.js +1 -0
- package/es/locales/common/zh_CN.json +1 -0
- package/es/locales/error/zh-CN.json +4 -0
- package/es/oak-app-domain/AccountOper/locales/zh_CN.json +1 -1
- package/es/oak-app-domain/Order/Schema.d.ts +11 -5
- package/es/oak-app-domain/Order/Storage.js +4 -5
- package/es/oak-app-domain/Order/locales/zh_CN.json +1 -1
- package/es/oak-app-domain/System/Storage.js +1 -2
- package/es/utils/application.d.ts +1 -1
- package/es/utils/wpProductFrontend.js +1 -1
- package/lib/aspects/withdraw.d.ts +4 -4
- package/lib/checkers/order.js +39 -0
- package/lib/components/pay/detail/index.js +11 -0
- package/lib/configuration/attrUpdateMatrix.js +6 -1
- package/lib/context/BackendRuntimeContext.d.ts +1 -1
- package/lib/data/i18n.js +21 -3
- package/lib/entities/Order.d.ts +4 -3
- package/lib/entities/Order.js +1 -0
- package/lib/locales/common/zh_CN.json +1 -0
- package/lib/locales/error/zh-CN.json +4 -0
- package/lib/oak-app-domain/AccountOper/locales/zh_CN.json +1 -1
- package/lib/oak-app-domain/Order/Schema.d.ts +11 -5
- package/lib/oak-app-domain/Order/Storage.js +4 -5
- package/lib/oak-app-domain/Order/locales/zh_CN.json +1 -1
- package/lib/oak-app-domain/System/Storage.js +1 -2
- package/lib/utils/application.d.ts +1 -1
- package/lib/utils/wpProductFrontend.js +1 -1
- package/package.json +171 -200
- package/src/entities/Order.ts +4 -2
|
@@ -4,4 +4,52 @@
|
|
|
4
4
|
min-height: 100%;
|
|
5
5
|
flex-direction: column;
|
|
6
6
|
align-items: stretch;
|
|
7
|
+
|
|
8
|
+
.control {
|
|
9
|
+
padding: 4px;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.item {
|
|
13
|
+
padding-bottom: 10px;
|
|
14
|
+
|
|
15
|
+
.symbol {
|
|
16
|
+
width: 50px;
|
|
17
|
+
height: 50px;
|
|
18
|
+
display: flex;
|
|
19
|
+
align-items: center;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
border-radius: 25px;
|
|
22
|
+
margin: 10px;
|
|
23
|
+
font-size: large;
|
|
24
|
+
font-weight: bold;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.main {
|
|
28
|
+
margin-top: 5px;
|
|
29
|
+
width: 100%;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.sub {
|
|
33
|
+
width: 100%;
|
|
34
|
+
|
|
35
|
+
.type {
|
|
36
|
+
font-weight: bold;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.types {
|
|
44
|
+
padding: 20px;
|
|
45
|
+
width: 100%;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.empty {
|
|
49
|
+
display: flex;
|
|
50
|
+
width: 100%;
|
|
51
|
+
flex: 1;
|
|
52
|
+
background-color: white;
|
|
53
|
+
align-items: center;
|
|
54
|
+
justify-content: center;
|
|
7
55
|
}
|
|
@@ -8,6 +8,17 @@ export default function Render(props: WebComponentProps<EntityDict, 'accountOper
|
|
|
8
8
|
type: string;
|
|
9
9
|
symbol: string;
|
|
10
10
|
avail: string;
|
|
11
|
+
bgColor: string;
|
|
11
12
|
}>;
|
|
12
13
|
hasMore: boolean;
|
|
13
|
-
|
|
14
|
+
month?: Date;
|
|
15
|
+
monthStr: string;
|
|
16
|
+
type: 'in' | 'out' | 'both';
|
|
17
|
+
chooseMonth: boolean;
|
|
18
|
+
chooseType: boolean;
|
|
19
|
+
}, {
|
|
20
|
+
setMonth: (month?: number | Date) => void;
|
|
21
|
+
setType: (type: 'in' | 'out' | 'both') => void;
|
|
22
|
+
setChooseMonth: (cm: boolean) => void;
|
|
23
|
+
setChooseType: (ct: boolean) => void;
|
|
24
|
+
}>): React.JSX.Element;
|
|
@@ -1,29 +1,63 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { List, InfiniteScroll, Space } from 'antd-mobile';
|
|
2
|
+
import { List, InfiniteScroll, Space, DatePicker, Button, Popup, Radio, Result } from 'antd-mobile';
|
|
3
|
+
import { DownOutline, SearchOutline, UndoOutline } from 'antd-mobile-icons';
|
|
3
4
|
import Styles from './mobile.module.less';
|
|
4
5
|
export default function Render(props) {
|
|
5
|
-
const { accountOpers, hasMore } = props.data;
|
|
6
|
-
const { t, loadMore } = props.methods;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
<
|
|
10
|
-
{
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
6
|
+
const { accountOpers, hasMore, month, type, chooseMonth, chooseType, monthStr } = props.data;
|
|
7
|
+
const { t, loadMore, setType, setMonth, setChooseMonth, setChooseType, navigateBack } = props.methods;
|
|
8
|
+
return (<div className={Styles.container}>
|
|
9
|
+
<Space justify="between" className={Styles.control}>
|
|
10
|
+
<Button size="small" fill="none" onClick={() => setChooseMonth(true)}>
|
|
11
|
+
{monthStr || t('chooseMonth')}
|
|
12
|
+
<DownOutline />
|
|
13
|
+
</Button>
|
|
14
|
+
<Button size="small" fill="none" onClick={() => setChooseType(true)}>
|
|
15
|
+
<SearchOutline />
|
|
16
|
+
{t(`type.${type}`)}
|
|
17
|
+
</Button>
|
|
18
|
+
</Space>
|
|
19
|
+
<DatePicker visible={chooseMonth} value={month || null} onClose={() => setChooseMonth(false)} max={new Date()} precision="month" onConfirm={(value) => {
|
|
20
|
+
setMonth(value);
|
|
21
|
+
setChooseMonth(false);
|
|
22
|
+
}}/>
|
|
23
|
+
<Popup visible={chooseType} onMaskClick={() => setChooseType(false)} onClose={() => setChooseType(false)}>
|
|
24
|
+
<Radio.Group onChange={(type) => {
|
|
25
|
+
setType(type);
|
|
26
|
+
setChooseType(false);
|
|
27
|
+
}} value={type}>
|
|
28
|
+
<Space className={Styles.types} justify="around">
|
|
29
|
+
<Radio value="both">{t('type.both')}</Radio>
|
|
30
|
+
<Radio value="in">{t('type.in')}</Radio>
|
|
31
|
+
<Radio value="out">{t('type.out')}</Radio>
|
|
32
|
+
</Space>
|
|
33
|
+
</Radio.Group>
|
|
34
|
+
</Popup>
|
|
35
|
+
{accountOpers?.length ? <div style={{ flex: 1 }}>
|
|
36
|
+
<List>
|
|
37
|
+
{accountOpers.map((oper, idx) => {
|
|
38
|
+
const { value, time, type, symbol, avail, bgColor } = oper;
|
|
39
|
+
return (<List.Item className={Styles.item} key={idx} prefix={<div className={Styles.symbol} style={{
|
|
40
|
+
backgroundColor: bgColor,
|
|
41
|
+
}}>
|
|
42
|
+
{symbol}
|
|
43
|
+
</div>} description={<Space direction="horizontal" justify="between" className={Styles.main}>
|
|
44
|
+
<span>{time}</span>
|
|
45
|
+
<span>{t('account:attr.avail')}:{avail}</span>
|
|
46
|
+
</Space>}>
|
|
47
|
+
<Space direction="horizontal" justify="between" className={Styles.sub}>
|
|
48
|
+
<span className={Styles.type}>{type}</span>
|
|
49
|
+
<span style={{
|
|
50
|
+
color: bgColor,
|
|
51
|
+
}}>{value}</span>
|
|
52
|
+
</Space>
|
|
53
|
+
</List.Item>);
|
|
23
54
|
})}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
55
|
+
</List>
|
|
56
|
+
<InfiniteScroll hasMore={hasMore} loadMore={loadMore}/>
|
|
57
|
+
</div> : (<div className={Styles.empty}>
|
|
58
|
+
<Result icon={<UndoOutline />} status='success' title={t('common::noData')} description={<Button onClick={() => navigateBack()}>
|
|
59
|
+
{t('common::back')}
|
|
60
|
+
</Button>}/>
|
|
61
|
+
</div>)}
|
|
62
|
+
</div>);
|
|
29
63
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
|
|
2
|
+
.control {
|
|
3
|
+
padding: 4px;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
.value {
|
|
7
|
+
font-size: x-large;
|
|
8
|
+
font-weight: bold;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.list {
|
|
12
|
+
min-height: 620px;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.types {
|
|
16
|
+
padding: 20px;
|
|
17
|
+
width: 100%;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.empty {
|
|
21
|
+
display: flex;
|
|
22
|
+
width: 100%;
|
|
23
|
+
flex: 1;
|
|
24
|
+
background-color: white;
|
|
25
|
+
align-items: center;
|
|
26
|
+
justify-content: center;
|
|
27
|
+
}
|
|
@@ -1,12 +1,24 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { WebComponentProps } from 'oak-frontend-base';
|
|
3
3
|
import { EntityDict } from '../../../oak-app-domain';
|
|
4
|
-
export default function Render(props: WebComponentProps<EntityDict, 'accountOper',
|
|
4
|
+
export default function Render(props: WebComponentProps<EntityDict, 'accountOper', true, {
|
|
5
5
|
accountOpers?: Array<{
|
|
6
6
|
value: string;
|
|
7
7
|
time: string;
|
|
8
8
|
type: string;
|
|
9
9
|
symbol: string;
|
|
10
10
|
avail: string;
|
|
11
|
+
bgColor: string;
|
|
11
12
|
}>;
|
|
12
|
-
|
|
13
|
+
hasMore: boolean;
|
|
14
|
+
month?: Date;
|
|
15
|
+
monthStr: string;
|
|
16
|
+
type: 'in' | 'out' | 'both';
|
|
17
|
+
chooseMonth: boolean;
|
|
18
|
+
chooseType: boolean;
|
|
19
|
+
}, {
|
|
20
|
+
setMonth: (month?: Date) => void;
|
|
21
|
+
setType: (type: 'in' | 'out' | 'both') => void;
|
|
22
|
+
setChooseMonth: (cm: boolean) => void;
|
|
23
|
+
setChooseType: (ct: boolean) => void;
|
|
24
|
+
}>): React.JSX.Element;
|
|
@@ -1,11 +1,46 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { List, Flex } from 'antd';
|
|
2
|
+
import { Avatar, List, Select, Flex, Button, Card, Result, DatePicker } from 'antd';
|
|
3
|
+
import Styles from './web.module.less';
|
|
4
|
+
import dayJs from 'dayjs';
|
|
3
5
|
export default function Render(props) {
|
|
4
|
-
const { accountOpers } = props.data;
|
|
5
|
-
const { t } = props.methods;
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
const { accountOpers, hasMore, month, type, chooseMonth, chooseType, monthStr, oakLoading, oakLoadingMore } = props.data;
|
|
7
|
+
const { t, loadMore, setType, setMonth, setChooseMonth, setChooseType, navigateBack } = props.methods;
|
|
8
|
+
return (<>
|
|
9
|
+
<Card title={t('history')} extra={<Flex gap="middle" className={Styles.control}>
|
|
10
|
+
<DatePicker picker="month" onChange={(value) => {
|
|
11
|
+
setMonth(value.toDate());
|
|
12
|
+
}} maxDate={dayJs()}/>
|
|
13
|
+
<Select style={{ width: 120 }} onChange={(value) => {
|
|
14
|
+
setType(value);
|
|
15
|
+
}} value={type} options={[
|
|
16
|
+
{ value: 'both', label: t('type.both') },
|
|
17
|
+
{ value: 'in', label: t('type.in') },
|
|
18
|
+
{ value: 'out', label: t('type.out') },
|
|
19
|
+
]}/>
|
|
20
|
+
</Flex>}>
|
|
21
|
+
{accountOpers?.length ?
|
|
22
|
+
<List className={Styles.list} loading={oakLoading || oakLoadingMore} dataSource={accountOpers} renderItem={(item, idx) => (<List.Item key={idx}>
|
|
23
|
+
<List.Item.Meta avatar={<Avatar style={{ backgroundColor: item.bgColor }}>{item.symbol}</Avatar>} title={<span className={Styles.type}>{item.type}</span>} description={<Flex justify="between" className={Styles.main} gap="large">
|
|
24
|
+
<span>{item.time}</span>
|
|
25
|
+
<span>{t('account:attr.avail')}:{item.avail}</span>
|
|
26
|
+
</Flex>}/>
|
|
27
|
+
<div className={Styles.value} style={{
|
|
28
|
+
color: item.bgColor,
|
|
29
|
+
}}>
|
|
30
|
+
{item.value}
|
|
31
|
+
</div>
|
|
32
|
+
</List.Item>)} loadMore={!oakLoading && !oakLoadingMore && hasMore ? (<div style={{
|
|
33
|
+
textAlign: 'center',
|
|
34
|
+
marginTop: 12,
|
|
35
|
+
height: 32,
|
|
36
|
+
lineHeight: '32px',
|
|
37
|
+
}}>
|
|
38
|
+
<Button onClick={loadMore}>
|
|
39
|
+
{t('common::loadMore')}
|
|
40
|
+
</Button>
|
|
41
|
+
</div>) : null}/> : (<Result status="404" title={t('common::noData')} extra={<Button onClick={() => navigateBack()}>
|
|
42
|
+
{t('common::back')}
|
|
43
|
+
</Button>}/>)}
|
|
44
|
+
</Card>
|
|
45
|
+
</>);
|
|
11
46
|
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import Styles from './info.module.less';
|
|
2
2
|
export default function Info(props) {
|
|
3
3
|
const { price, t } = props;
|
|
4
|
-
return (<div className={Styles.info}>
|
|
5
|
-
<div className={Styles.should}>{t('price')}</div>
|
|
6
|
-
<div className={Styles.price}>
|
|
7
|
-
<div>{t('common::pay.symbol')}</div>
|
|
8
|
-
<div>{price}</div>
|
|
9
|
-
</div>
|
|
4
|
+
return (<div className={Styles.info}>
|
|
5
|
+
<div className={Styles.should}>{t('price')}</div>
|
|
6
|
+
<div className={Styles.price}>
|
|
7
|
+
<div>{t('common::pay.symbol')}</div>
|
|
8
|
+
<div>{price}</div>
|
|
9
|
+
</div>
|
|
10
10
|
</div>);
|
|
11
11
|
}
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
|
|
2
|
-
.info {
|
|
3
|
-
margin: 8px;
|
|
4
|
-
height: 140px;
|
|
5
|
-
display: flex;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
justify-content: center;
|
|
9
|
-
background-color: var(--oak-color-info);
|
|
10
|
-
|
|
11
|
-
.should {
|
|
12
|
-
font-size: large;
|
|
13
|
-
font-weight: bold;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.price {
|
|
17
|
-
display: flex;
|
|
18
|
-
flex-direction: row;
|
|
19
|
-
padding: 3px;
|
|
20
|
-
font-size: xx-large;
|
|
21
|
-
font-weight: bolder;
|
|
22
|
-
color: var(--oak-color-primary);
|
|
23
|
-
align-items: baseline;
|
|
24
|
-
}
|
|
1
|
+
|
|
2
|
+
.info {
|
|
3
|
+
margin: 8px;
|
|
4
|
+
height: 140px;
|
|
5
|
+
display: flex;
|
|
6
|
+
flex-direction: column;
|
|
7
|
+
align-items: center;
|
|
8
|
+
justify-content: center;
|
|
9
|
+
background-color: var(--oak-color-info);
|
|
10
|
+
|
|
11
|
+
.should {
|
|
12
|
+
font-size: large;
|
|
13
|
+
font-weight: bold;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.price {
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: row;
|
|
19
|
+
padding: 3px;
|
|
20
|
+
font-size: xx-large;
|
|
21
|
+
font-weight: bolder;
|
|
22
|
+
color: var(--oak-color-primary);
|
|
23
|
+
align-items: baseline;
|
|
24
|
+
}
|
|
25
25
|
}
|
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
.container {
|
|
2
|
-
width: 100%;
|
|
3
|
-
height: 100%;
|
|
4
|
-
display: flex;
|
|
5
|
-
flex-direction: column;
|
|
6
|
-
align-items: stretch;
|
|
7
|
-
background-color: var(--oak-bg-color-page);
|
|
8
|
-
// min-height: 500px;
|
|
9
|
-
|
|
10
|
-
.ctrl {
|
|
11
|
-
margin: 8px;
|
|
12
|
-
margin-top: 10px;
|
|
13
|
-
flex: 1;
|
|
14
|
-
|
|
15
|
-
.pc1 {
|
|
16
|
-
width: 100%;
|
|
17
|
-
height: 100%;
|
|
18
|
-
display: flex;
|
|
19
|
-
flex-direction: column;
|
|
20
|
-
margin-top: 4px;
|
|
21
|
-
|
|
22
|
-
.content {
|
|
23
|
-
background-color: var(--oak-bg-color-container);
|
|
24
|
-
padding: 4px;
|
|
25
|
-
border-radius: 2px;
|
|
26
|
-
padding: 16px;
|
|
27
|
-
|
|
28
|
-
.tips {
|
|
29
|
-
color: var(--oak-color-warning);
|
|
30
|
-
font-size: small;
|
|
31
|
-
margin-top: 3px;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
1
|
+
.container {
|
|
2
|
+
width: 100%;
|
|
3
|
+
height: 100%;
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
align-items: stretch;
|
|
7
|
+
background-color: var(--oak-bg-color-page);
|
|
8
|
+
// min-height: 500px;
|
|
9
|
+
|
|
10
|
+
.ctrl {
|
|
11
|
+
margin: 8px;
|
|
12
|
+
margin-top: 10px;
|
|
13
|
+
flex: 1;
|
|
14
|
+
|
|
15
|
+
.pc1 {
|
|
16
|
+
width: 100%;
|
|
17
|
+
height: 100%;
|
|
18
|
+
display: flex;
|
|
19
|
+
flex-direction: column;
|
|
20
|
+
margin-top: 4px;
|
|
21
|
+
|
|
22
|
+
.content {
|
|
23
|
+
background-color: var(--oak-bg-color-container);
|
|
24
|
+
padding: 4px;
|
|
25
|
+
border-radius: 2px;
|
|
26
|
+
padding: 16px;
|
|
27
|
+
|
|
28
|
+
.tips {
|
|
29
|
+
color: var(--oak-color-warning);
|
|
30
|
+
font-size: small;
|
|
31
|
+
margin-top: 3px;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
36
|
}
|
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
.container {
|
|
2
|
-
width: 100%;
|
|
3
|
-
height: 100%;
|
|
4
|
-
display: flex;
|
|
5
|
-
flex-direction: column;
|
|
6
|
-
align-items: stretch;
|
|
7
|
-
background-color: var(--oak-bg-color-page);
|
|
8
|
-
// min-height: 500px;
|
|
9
|
-
|
|
10
|
-
.ctrl {
|
|
11
|
-
margin: 8px;
|
|
12
|
-
margin-top: 10px;
|
|
13
|
-
flex: 1;
|
|
14
|
-
|
|
15
|
-
.pc1 {
|
|
16
|
-
width: 100%;
|
|
17
|
-
height: 100%;
|
|
18
|
-
display: flex;
|
|
19
|
-
flex-direction: column;
|
|
20
|
-
margin-top: 4px;
|
|
21
|
-
|
|
22
|
-
.content {
|
|
23
|
-
background-color: var(--oak-bg-color-container);
|
|
24
|
-
padding: 4px;
|
|
25
|
-
border-radius: 2px;
|
|
26
|
-
padding: 16px;
|
|
27
|
-
|
|
28
|
-
.tips {
|
|
29
|
-
color: var(--oak-color-warning);
|
|
30
|
-
font-size: small;
|
|
31
|
-
margin-left: 10px;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
1
|
+
.container {
|
|
2
|
+
width: 100%;
|
|
3
|
+
height: 100%;
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
align-items: stretch;
|
|
7
|
+
background-color: var(--oak-bg-color-page);
|
|
8
|
+
// min-height: 500px;
|
|
9
|
+
|
|
10
|
+
.ctrl {
|
|
11
|
+
margin: 8px;
|
|
12
|
+
margin-top: 10px;
|
|
13
|
+
flex: 1;
|
|
14
|
+
|
|
15
|
+
.pc1 {
|
|
16
|
+
width: 100%;
|
|
17
|
+
height: 100%;
|
|
18
|
+
display: flex;
|
|
19
|
+
flex-direction: column;
|
|
20
|
+
margin-top: 4px;
|
|
21
|
+
|
|
22
|
+
.content {
|
|
23
|
+
background-color: var(--oak-bg-color-container);
|
|
24
|
+
padding: 4px;
|
|
25
|
+
border-radius: 2px;
|
|
26
|
+
padding: 16px;
|
|
27
|
+
|
|
28
|
+
.tips {
|
|
29
|
+
color: var(--oak-color-warning);
|
|
30
|
+
font-size: small;
|
|
31
|
+
margin-left: 10px;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
36
|
}
|
|
@@ -264,6 +264,17 @@ export default OakComponent({
|
|
|
264
264
|
});
|
|
265
265
|
}
|
|
266
266
|
},
|
|
267
|
+
updateExternalIdMp(input) {
|
|
268
|
+
const { detail } = input;
|
|
269
|
+
this.update({
|
|
270
|
+
externalId: detail.value,
|
|
271
|
+
});
|
|
272
|
+
},
|
|
273
|
+
clearExternalIdMp() {
|
|
274
|
+
this.update({
|
|
275
|
+
externalId: null,
|
|
276
|
+
});
|
|
277
|
+
}
|
|
267
278
|
},
|
|
268
279
|
lifetimes: {
|
|
269
280
|
ready() {
|
|
@@ -48,6 +48,16 @@
|
|
|
48
48
|
<l-form-item label-width="240rpx" label="{{t('code.label')}}">
|
|
49
49
|
<l-tag bg-color="#d9363e">{{pay.phantom3}}</l-tag>
|
|
50
50
|
</l-form-item>
|
|
51
|
+
<l-form-item label-width="240rpx" label="{{t('externalId.label')}}">
|
|
52
|
+
<l-input
|
|
53
|
+
hide-label="{{true}}"
|
|
54
|
+
clear="{{true}}"
|
|
55
|
+
disabled="{{pay.iState !== 'paying'}}"
|
|
56
|
+
placeholder="{{t('externalId.help')}}"
|
|
57
|
+
bind:lininput="updateExternalIdMp"
|
|
58
|
+
bind:linclear="clearExternalIdMp"
|
|
59
|
+
/>
|
|
60
|
+
</l-form-item>
|
|
51
61
|
<block wx:if="{{offline.type === 'bank'}}">
|
|
52
62
|
<l-form-item label-width="240rpx" label="{{t('offlineAccount::label.channel.bank')}}">
|
|
53
63
|
<view>{{offline.channel}}</view>
|
|
@@ -25,10 +25,14 @@
|
|
|
25
25
|
},
|
|
26
26
|
"code": {
|
|
27
27
|
"label": "转帐凭证号",
|
|
28
|
-
"help": "
|
|
28
|
+
"help": "请在转帐时于留言中附上转帐凭证号,便于人工核对。若转账时忘记附上,则请准确填写转账流水号。"
|
|
29
29
|
},
|
|
30
30
|
"channel": {
|
|
31
31
|
"change": "更换",
|
|
32
32
|
"prefix": "渠道"
|
|
33
|
+
},
|
|
34
|
+
"externalId": {
|
|
35
|
+
"label": "转账流水号",
|
|
36
|
+
"help": "转账成功后有唯一流水号,将之正确填入可减少财务人员核对时的错误概率,给您带来更大便利"
|
|
33
37
|
}
|
|
34
38
|
}
|
|
@@ -10,6 +10,7 @@ export declare function RenderOffline(props: {
|
|
|
10
10
|
offlines: ColoredOffline[];
|
|
11
11
|
offline: ColoredOffline;
|
|
12
12
|
updateOfflineId: (entityId: string) => void;
|
|
13
|
+
updateExternalId: (externalId: string) => void;
|
|
13
14
|
}): React.JSX.Element;
|
|
14
15
|
export default function Render(props: WebComponentProps<EntityDict, 'pay', false, {
|
|
15
16
|
pay?: RowWithActions<EntityDict, 'pay'>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useEffect, useState } from 'react';
|
|
2
|
-
import { Card, Tag, List, Button, Modal, Form, Selector, Popup } from 'antd-mobile';
|
|
2
|
+
import { Card, Tag, List, Button, Modal, Form, Selector, Input, Popup } from 'antd-mobile';
|
|
3
3
|
import { QRCode, Alert } from 'antd';
|
|
4
4
|
import Styles from './web.mobile.module.less';
|
|
5
5
|
import * as dayJs from 'dayjs';
|
|
@@ -9,8 +9,8 @@ import { CentToString } from 'oak-domain/lib/utils/money';
|
|
|
9
9
|
import { PayCircleOutline, GlobalOutline, InformationCircleOutline, CheckCircleOutline } from 'antd-mobile-icons';
|
|
10
10
|
import { generateNewIdAsync } from 'oak-domain/lib/utils/uuid';
|
|
11
11
|
export function RenderOffline(props) {
|
|
12
|
-
const { pay, t, offline, offlines, updateOfflineId } = props;
|
|
13
|
-
const { meta, iState, phantom3 } = pay;
|
|
12
|
+
const { pay, t, offline, offlines, updateOfflineId, updateExternalId } = props;
|
|
13
|
+
const { meta, iState, phantom3, externalId } = pay;
|
|
14
14
|
const { type, channel, name, qrCode, color } = offline || {};
|
|
15
15
|
const [show, setShow] = useState(false);
|
|
16
16
|
const items2 = [
|
|
@@ -23,6 +23,11 @@ export function RenderOffline(props) {
|
|
|
23
23
|
<Tag color="red">
|
|
24
24
|
<span style={{ fontSize: 'large' }}>{phantom3}</span>
|
|
25
25
|
</Tag>
|
|
26
|
+
</Form.Item>,
|
|
27
|
+
<Form.Item key="externalId" label={<span className={Styles.bold}>{t('externalId.label')}</span>}>
|
|
28
|
+
<Input autoFocus value={externalId || ''} onChange={(value) => {
|
|
29
|
+
updateExternalId(value);
|
|
30
|
+
}} placeholder={t('externalId.help')} disabled={iState !== 'paying'}/>
|
|
26
31
|
</Form.Item>
|
|
27
32
|
];
|
|
28
33
|
if (type === 'bank') {
|
|
@@ -121,7 +126,7 @@ function RenderWechatPay(props) {
|
|
|
121
126
|
return null;
|
|
122
127
|
}
|
|
123
128
|
function RenderPayMeta(props) {
|
|
124
|
-
const { pay, notSameApp, t, offlines, offline, updateOfflineId } = props;
|
|
129
|
+
const { pay, notSameApp, t, offlines, offline, updateOfflineId, updateExternalId } = props;
|
|
125
130
|
const { iState, entity } = pay;
|
|
126
131
|
if (entity !== 'offlineAccount' && notSameApp) {
|
|
127
132
|
return <Alert type='warning' message={t('notSameApp')}/>;
|
|
@@ -131,7 +136,7 @@ function RenderPayMeta(props) {
|
|
|
131
136
|
if (offline && offlines) {
|
|
132
137
|
return (<>
|
|
133
138
|
{iState === 'paying' && <Alert type='info' message={t('code.help')} style={{ marginBottom: 10 }}/>}
|
|
134
|
-
<RenderOffline t={t} pay={pay} offline={offline} offlines={offlines} updateOfflineId={updateOfflineId}/>
|
|
139
|
+
<RenderOffline t={t} pay={pay} offline={offline} offlines={offlines} updateOfflineId={updateOfflineId} updateExternalId={updateExternalId}/>
|
|
135
140
|
</>);
|
|
136
141
|
}
|
|
137
142
|
return null;
|
|
@@ -208,6 +213,8 @@ export default function Render(props) {
|
|
|
208
213
|
}
|
|
209
214
|
}
|
|
210
215
|
]);
|
|
216
|
+
}} updateExternalId={(externalId) => {
|
|
217
|
+
update({ externalId });
|
|
211
218
|
}}/>
|
|
212
219
|
</div>
|
|
213
220
|
<div className={Styles.padding}/>
|
|
@@ -10,6 +10,7 @@ export declare function RenderOffline(props: {
|
|
|
10
10
|
offlines: ColoredOffline[];
|
|
11
11
|
offline: ColoredOffline;
|
|
12
12
|
updateOfflineId: (entityId: string) => void;
|
|
13
|
+
updateExternalId: (externalId: string) => void;
|
|
13
14
|
}): React.JSX.Element | null;
|
|
14
15
|
export default function Render(props: WebComponentProps<EntityDict, 'pay', false, {
|
|
15
16
|
pay?: RowWithActions<EntityDict, 'pay'>;
|