Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-admin
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
shenshaokai
jinfa-admin
Commits
b6868fdb
Commit
b6868fdb
authored
Jan 12, 2022
by
Bill
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 修改积分结算通联支付
parent
ca3d5564
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
159 additions
and
84 deletions
+159
-84
index.tsx
.../settlementManage/platformSettlement/score/list/index.tsx
+7
-2
index.tsx
...anage/ruleSettingManage/components/SettleMethod/index.tsx
+24
-75
settleMethod.tsx
...uleSettingManage/components/SettleMethod/settleMethod.tsx
+113
-0
index.tsx
...leSettingManage/platformSettlementStrategy/info/index.tsx
+15
-7
No files found.
src/pages/settlementManage/platformSettlement/score/list/index.tsx
View file @
b6868fdb
...
...
@@ -11,7 +11,12 @@ import { Moment } from 'moment';
import
moment
from
'moment'
;
import
UploadVoucherModal
from
'../../components/UploadVoucherModal'
;
import
Voucher
from
'../../components/Voucher'
;
import
{
getSettleAccountsPlatformScoreSettlementGetPayablePayProve
,
getSettleAccountsPlatformScoreSettlementPagePayableSettlement
,
postSettleAccountsPlatformScoreSettlementPay
,
postSettleAccountsPlatformSettlementCommunicationPay
}
from
'@/services/SettleV2Api'
;
import
{
getSettleAccountsPlatformScoreSettlementGetPayablePayProve
,
getSettleAccountsPlatformScoreSettlementPagePayableSettlement
,
postSettleAccountsPlatformScoreSettlementAllInPay
,
postSettleAccountsPlatformScoreSettlementPay
}
from
'@/services/SettleV2Api'
;
import
{
postReportSettlementScoreManualSettlement
}
from
'@/services/ReportV2Api'
;
import
OtherPayModal
from
'../../components/OtherPayModal'
;
import
useHandleSettlementList
from
'./useHandleSettlementList'
;
...
...
@@ -74,7 +79,7 @@ const SettlementList = () => {
console
.
log
(
itemInfo
);
try
{
setConfirmUniversalPayLoading
(
true
)
const
{
code
}
=
await
postSettleAccountsPlatformS
ettlementCommunicatio
nPay
({
id
:
itemInfo
?.
id
!
})
const
{
code
}
=
await
postSettleAccountsPlatformS
coreSettlementAllI
nPay
({
id
:
itemInfo
?.
id
!
})
if
(
code
===
1000
)
{
handleClose
(
'universalPay'
)
...
...
src/pages/systemManage/ruleSettingManage/components/SettleMethod/index.tsx
View file @
b6868fdb
...
...
@@ -5,13 +5,13 @@
*/
import
React
,
{
useEffect
,
useState
}
from
'react'
;
import
{
Radio
,
Input
,
Tooltip
}
from
'antd'
;
import
{
QuestionCircleOutlined
}
from
'@ant-design/icons'
;
import
styles
from
'./index.less'
;
import
{
registerValidationRules
}
from
'@formily/antd'
// 或者 @formily/next
import
SettleMethod
from
'./settleMethod'
;
const
DAY
=
1
;
const
MONTH
=
2
;
type
SettleMethodProps
=
React
.
ComponentProps
<
typeof
SettleMethod
>
;
registerValidationRules
({
settleMethodRule
:
value
=>
{
...
...
@@ -27,80 +27,25 @@ registerValidationRules({
}
})
const
SettleMethod
=
(
props
)
=>
{
const
{
active
=
DAY
,
otherValues
=
[
30
,
1
]
}
=
props
.
value
||
{};
const
{
daysVisible
,
monthVisible
}
=
props
;
const
handleChange
=
(
e
,
type
)
=>
{
if
(
active
==
type
)
{
return
;
}
const
previewValue
=
otherValues
// setActive(type)
props
.
onChange
({
active
:
type
,
otherValues
:
previewValue
})
}
type
XcomponenetProps
=
{
options
:
{
days
:
boolean
,
month
:
boolean
},
default
:
any
}
const
handleInputChange
=
(
value
,
type
)
=>
{
const
target
=
type
-
1
;
const
temp
=
[...
otherValues
];
temp
[
target
]
=
value
;
props
.
onChange
({
active
:
type
,
otherValues
:
temp
})
interface
Iprops
{
/** 编辑状态 */
editable
:
boolean
,
initialValue
?:
SettleMethodProps
[
'value'
],
value
:
SettleMethodProps
[
'value'
],
props
:
{
[
'x-component-props'
]:
XcomponenetProps
}
if
(
!
monthVisible
&&
!
daysVisible
)
{
return
null
mutators
:
{
change
:
(
value
:
any
)
=>
void
}
return
(
<
div
>
<
div
className=
{
styles
.
radiosContainer
}
>
<
div
className=
{
styles
.
dayRadio
}
>
<
Radio
name=
"method"
checked=
{
active
==
DAY
}
onChange=
{
(
e
)
=>
handleChange
(
e
,
DAY
)
}
>
账期(默认)
</
Radio
>
<
Tooltip
title=
"选择账期并设置账期天数后,即结算时间为T+账期天数,系统每天自动将支付时间达到账期天数的支付金额进行结算,如设置账期天数为30天,则系统每天结算支付时间达到30天的支付金额"
>
<
QuestionCircleOutlined
/>
</
Tooltip
>
</
div
>
<
div
>
<
Radio
name=
"method"
checked=
{
active
==
MONTH
}
onChange=
{
(
e
)
=>
handleChange
(
e
,
MONTH
)
}
>
月结
</
Radio
>
<
Tooltip
title=
"选择月结并设置每月结算日期后,系统将在每月结算日当天自动将上月发生的支付金额进行结算,如每月结算日期设置为每月1号,则每月1号系统自动结算上月所有已发生的支付金额"
>
<
QuestionCircleOutlined
/>
</
Tooltip
>
</
div
>
</
div
>
<
div
className=
{
styles
.
values
}
>
{
active
===
DAY
?
<
div
className=
{
styles
.
days
}
>
<
div
style=
{
{
margin
:
'0 20px 0 0px'
}
}
>
账期天数
</
div
>
<
div
>
<
Input
addonAfter=
{
"天"
}
value=
{
otherValues
[
DAY
-
1
]
}
onChange=
{
(
e
)
=>
handleInputChange
(
e
.
target
.
value
,
DAY
)
}
disabled=
{
active
!==
DAY
}
style=
{
{
width
:
'160px'
}
}
/></
div
>
</
div
>
:
<
div
className=
{
styles
.
days
}
>
<
div
style=
{
{
marginRight
:
'20px'
}
}
>
每月结算日期:每月
</
div
>
<
div
>
<
Input
addonAfter=
{
"号"
}
style=
{
{
width
:
'160px'
}
}
value=
{
otherValues
[
MONTH
-
1
]
}
onChange=
{
(
e
)
=>
handleInputChange
(
e
.
target
.
value
,
MONTH
)
}
disabled=
{
active
!==
MONTH
}
/>
</
div
>
</
div
>
}
</
div
>
</
div
>
)
}
...
...
@@ -127,7 +72,11 @@ const Index = (props) => {
props
.
mutators
.
change
(
value
);
}
if
(
!
editable
)
{
return
value
.
active
==
1
?
`账期(默认), 账期天数
${
value
.
otherValues
[
0
]}
天 `
:
`月结: 每月
${
value
.
otherValues
[
1
]}
号`
return
(
<
div
>
{
value
.
active
==
1
?
`账期(默认), 账期天数${value.otherValues[0]}天 `
:
`月结: 每月${value.otherValues[1]}号`
}
</
div
>
)
}
return
(
...
...
src/pages/systemManage/ruleSettingManage/components/SettleMethod/settleMethod.tsx
0 → 100644
View file @
b6868fdb
import
React
,
{
useEffect
,
useState
}
from
'react'
;
import
{
Radio
,
Input
,
Tooltip
}
from
'antd'
;
import
{
QuestionCircleOutlined
}
from
'@ant-design/icons'
;
import
styles
from
'./index.less'
;
const
DAY
=
1
;
const
MONTH
=
2
;
/** 1 => 账期,2 => 月结 */
export
type
SettleActiveType
=
1
|
2
;
interface
Iprops
{
value
:
{
active
:
SettleActiveType
,
/** 账期天数, 每月结算日 */
otherValues
:
[
number
,
number
]
},
onChange
:
(
params
:
{
active
:
1
|
2
,
otherValues
:
[
number
,
number
]})
=>
void
,
/** 是否显示账期结算 */
daysVisible
:
boolean
,
/** 是否显示月结 */
monthVisible
:
boolean
}
const
SettleMethod
:
React
.
FC
<
Iprops
>
=
(
props
:
Iprops
)
=>
{
const
{
value
,
daysVisible
,
monthVisible
,
onChange
}
=
props
;
const
{
active
=
DAY
,
otherValues
=
[
30
,
1
]
}
=
value
||
{};
const
handleChange
=
(
e
,
type
:
SettleActiveType
)
=>
{
if
(
active
==
type
)
{
return
;
}
const
previewValue
=
otherValues
// setActive(type)
onChange
({
active
:
type
,
otherValues
:
previewValue
})
}
const
handleInputChange
=
(
value
:
string
,
type
:
SettleActiveType
)
=>
{
const
target
=
type
-
1
;
const
temp
=
[...
otherValues
];
temp
[
target
]
=
value
as
unknown
as
number
;
props
.
onChange
({
active
:
type
,
otherValues
:
temp
as
[
number
,
number
]
})
}
if
(
!
monthVisible
&&
!
daysVisible
)
{
return
null
}
return
(
<
div
>
<
div
className=
{
styles
.
radiosContainer
}
>
{
daysVisible
&&
(
<
div
className=
{
styles
.
dayRadio
}
>
<
Radio
name=
"method"
checked=
{
active
==
DAY
}
onChange=
{
(
e
)
=>
handleChange
(
e
,
DAY
)
}
>
账期(默认)
</
Radio
>
<
Tooltip
title=
"选择账期并设置账期天数后,即结算时间为T+账期天数,系统每天自动将支付时间达到账期天数的支付金额进行结算,如设置账期天数为30天,则系统每天结算支付时间达到30天的支付金额"
>
<
QuestionCircleOutlined
/>
</
Tooltip
>
</
div
>
)
||
null
}
{
monthVisible
&&
(
<
div
>
<
Radio
name=
"method"
checked=
{
active
==
MONTH
}
onChange=
{
(
e
)
=>
handleChange
(
e
,
MONTH
)
}
>
月结
</
Radio
>
<
Tooltip
title=
"选择月结并设置每月结算日期后,系统将在每月结算日当天自动将上月发生的支付金额进行结算,如每月结算日期设置为每月1号,则每月1号系统自动结算上月所有已发生的支付金额"
>
<
QuestionCircleOutlined
/>
</
Tooltip
>
</
div
>
)
||
null
}
</
div
>
<
div
className=
{
styles
.
values
}
>
{
active
===
DAY
?
<
div
className=
{
styles
.
days
}
>
<
div
style=
{
{
margin
:
'0 20px 0 0px'
}
}
>
账期天数
</
div
>
<
div
>
<
Input
addonAfter=
{
"天"
}
value=
{
otherValues
[
DAY
-
1
]
}
onChange=
{
(
e
)
=>
handleInputChange
(
e
.
target
.
value
,
DAY
)
}
disabled=
{
active
!==
DAY
}
style=
{
{
width
:
'160px'
}
}
/></
div
>
</
div
>
:
<
div
className=
{
styles
.
days
}
>
<
div
style=
{
{
marginRight
:
'20px'
}
}
>
每月结算日期:每月
</
div
>
<
div
>
<
Input
addonAfter=
{
"号"
}
style=
{
{
width
:
'160px'
}
}
value=
{
otherValues
[
MONTH
-
1
]
}
onChange=
{
(
e
)
=>
handleInputChange
(
e
.
target
.
value
,
MONTH
)
}
disabled=
{
active
!==
MONTH
}
/>
</
div
>
</
div
>
}
</
div
>
</
div
>
)
}
export
default
SettleMethod
\ No newline at end of file
src/pages/systemManage/ruleSettingManage/platformSettlementStrategy/info/index.tsx
View file @
b6868fdb
...
...
@@ -26,7 +26,7 @@ import { useLinkageUtils } from '@/utils/formEffectUtils'
import
{
getMemberManageAllProviderPage
,
getMemberManagePageitems
}
from
'@/services/MemberV2Api'
;
import
{
getSettleAccountsCommonGetPlatformStrategySettlementOrderType
,
getSettleAccountsPlatformConfigGetPlatformSettlementStrategyDetail
,
postSettleAccountsPlatformConfigAddPlatformSettlementStrategy
,
postSettleAccountsPlatformConfigUpdatePlatformSettlementStrategy
}
from
'@/services/SettleV2Api'
;
import
{
getManageRuleConfigurationList
}
from
'@/services/ManageV2Api'
;
import
{
getOrderPlatformSettlementTypeList
}
from
'@/services/OrderNewV2Api'
;
import
{
getOrderPlatformSettlement
CategoryList
,
getOrderPlatformSettlement
TypeList
}
from
'@/services/OrderNewV2Api'
;
const
{
onFormInit$
,
onFieldValueChange$
}
=
FormEffectHooks
export
const
fetchOptions
=
(
service
)
=>
{
...
...
@@ -204,13 +204,21 @@ const MemberSettleAdd: React.FC = () => {
// 从PAAS平台--规则配置--平台规则配置取已勾选的结算方式决定是否显示结算方式
const
fetchBalancedMethods
=
async
()
=>
{
const
{
data
}
=
await
getManageRuleConfigurationList
({
platformType
:
'5'
});
const
length
=
data
.
length
return
{
days
:
length
>
0
&&
data
[
0
].
check
,
month
:
length
>
1
&&
data
[
1
].
check
const
{
data
,
code
}
=
await
getOrderPlatformSettlementCategoryList
();
// const length = data.length
let
config
=
{
days
:
false
,
month
:
false
,
}
};
if
(
code
!==
1000
)
{
return
config
}
const
codeToMap
=
[
""
,
"days"
,
"month"
]
data
.
forEach
((
_item
)
=>
{
config
[
codeToMap
[
_item
.
methodCode
]]
=
true
})
return
config
}
// 从PAAS平台--规则配置--平台规则配置取已勾选的结算方式决定是否显示结算方式
useEffect
(()
=>
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment