Commit 87455aa2 authored by Bill's avatar Bill

fix: 修改结算付款接口,以及搜索时结束时间添加时分秒

parent 4619cf15
......@@ -32,6 +32,7 @@ interface SearchParams {
current: number,
pageSize: number,
}
const { RangePicker } = DatePicker;
const formActions = createFormActions();
const PLATFORM_PAYER = 4;
......@@ -137,7 +138,7 @@ const SettlementList = () => {
const handleSearch = (values: SearchParams) => {
const format = 'YYYY-MM-DD'
const startTime = values.startTime?.format(format);
const endTime = values.endTime?.format(format);
const endTime = values.endTime ? values.endTime.format(format) + " 23:59:59" : "";
ref.current.reload({...values, startTime, endTime});
}
return (
......@@ -152,7 +153,7 @@ const SettlementList = () => {
fetchTableData={(params: any) => fetchListData(params)}
controlRender={
<NiceForm
components={{DatePicker}}
components={{RangePicker}}
actions={formActions}
expressionScope={{}}
effects={($, actions) => {
......
......@@ -34,7 +34,7 @@ const columns = [
{title: '代收金额', dataIndex: 'collectAmount'},
{title: '支付时间', dataIndex: 'payTime'},
{
title: '佣金比率',
title: '佣金比率',
dataIndex: 'ratio',
render: (text,record) => {
return (record.ratio + '%');
......@@ -81,14 +81,14 @@ const logisticsDetail: React.FC = () => {
const { payTime, orderTime, ...rest } = values;
const payTimeRange = payTime ? timeRange(values.payTime): null;
const payStartTime = payTimeRange ? moment(payTimeRange.st * 1000).format(format) : null;
const payEndTime = payTimeRange ? moment(payTimeRange.et * 1000).format(format) : null;
const payEndTime = payTimeRange ? moment(payTimeRange.et * 1000).format(format) + " 23:59:59" : null;
const orderTimeRange = orderTime ? timeRange(values.orderTime) : null;
const orderStartTime = orderTimeRange ? moment(orderTimeRange.st * 1000).format(format) : null;
const orderEndTime = orderTimeRange ? moment(orderTimeRange.et * 1000).format(format) : null;
const orderEndTime = orderTimeRange ? moment(orderTimeRange.et * 1000).format(format) + " 23:59:59" : null;
ref.current.reload({...rest, payStartTime, payEndTime, orderStartTime, orderEndTime});
}
}
return (
<PageHeaderWrapper
......@@ -98,21 +98,21 @@ const logisticsDetail: React.FC = () => {
style={{ padding: '0' }}
onBack={() => history.goBack()}
title={
<AvatarWrap
<AvatarWrap
info={{
aloneTxt: '单',
name: "结算单号:"
}}
}}
extra={(
<span style={{ fontSize: 12, fontWeight: 'normal' }}>{infoDetail?.settlementNo}</span>
)}
/>
}
>
<Descriptions
column={3}
style={{
padding: '0 32px',
<Descriptions
column={3}
style={{
padding: '0 32px',
}}
>
<Descriptions.Item label="结算日期:">{infoDetail?.settlementDate}</Descriptions.Item>
......@@ -136,7 +136,7 @@ const logisticsDetail: React.FC = () => {
currentRef={ref}
fetchTableData={(params: any) => fetchListData(params)}
controlRender={
<NiceForm
<NiceForm
actions={formActions}
expressionScope={{
exportBtn: (
......@@ -163,4 +163,4 @@ const logisticsDetail: React.FC = () => {
)
}
export default logisticsDetail
\ No newline at end of file
export default logisticsDetail
......@@ -28,30 +28,40 @@ export const schema: ISchema = {
},
[FORM_FILTER_PATH]: {
type: 'object',
'x-component': 'mega-layout',
'x-component': 'flex-layout',
'x-component-props': {
grid: true,
full: true,
autoRow: true,
columns: 6,
rowStyle: {
justifyContent: 'flex-start'
},
colStyle: {
marginRight: "20px",
}
},
properties: {
startTime: {
type: 'string',
'x-component': 'DatePicker',
'x-component-props': {
allowClear: true,
placeholder: '结算日期(开始时间)'
}
},
endTime: {
type: 'string',
'x-component': 'DatePicker',
"[startTime, endTime]": {
type: "object",
"x-component": 'RangePicker',
'x-component-props': {
allowClear: true,
placeholder: '结算日期(结束时间)'
placeholder: ['结算日期(开始时间)', "结算日期(结束时间)"]
}
},
// startTime: {
// type: 'string',
// 'x-component': 'DatePicker',
// 'x-component-props': {
// allowClear: true,
// placeholder: '结算日期(开始时间)'
// }
// },
// endTime: {
// type: 'string',
// 'x-component': 'DatePicker',
// 'x-component-props': {
// allowClear: true,
// placeholder: '结算日期(结束时间)'
// }
// },
status: {
type: 'string',
enum: [
......
......@@ -48,10 +48,10 @@ const UploadPayVoucher: React.FC<Iprops> = (props) => {
useEffect(() => {
async function getAccountInfo() {
///settle/accounts/corporate/account/config
const { data, code } = await PublicApi.getSettleAccountsCorporateAccountConfig(
const { data, code } = await PublicApi.getSettleAccountsGetMemberAccountConfig(
{
memberId: props.id.toString(),
memberRoleId: props.roleId.toString()
roleId: props.roleId.toString()
});
if(code == 1000) {
setAccountInfo(data);
......
......@@ -33,6 +33,7 @@ interface SearchParams {
current: number,
pageSize: number,
}
const { RangePicker } = DatePicker
const formActions = createFormActions();
const SCORE_PAYER = 6;
......@@ -147,7 +148,7 @@ const SettlementList = () => {
const handleSearch = (values: SearchParams) => {
const format = 'YYYY-MM-DD'
const startTime = values.startTime && moment.isMoment(values.startTime) ? values.startTime.format(format) : '';
const endTime = values.endTime && moment.isMoment(values.endTime) ? values.endTime.format(format) : '';
const endTime = values.endTime && moment.isMoment(values.endTime) ? values.endTime.format(format) + " 23:59:59" : '';
ref.current.reload({...values, startTime, endTime});
}
return (
......@@ -162,7 +163,7 @@ const SettlementList = () => {
fetchTableData={(params: any) => fetchListData(params)}
controlRender={
<NiceForm
components={{DatePicker}}
components={{RangePicker}}
actions={formActions}
expressionScope={{}}
effects={($, actions) => {
......
......@@ -28,31 +28,41 @@ export const schema: ISchema = {
},
[FORM_FILTER_PATH]: {
type: 'object',
'x-component': 'mega-layout',
'x-component': 'flex-layout',
'x-component-props': {
grid: true,
full: true,
autoRow: true,
columns: 6,
rowStyle: {
justifyContent: 'flex-start'
},
colStyle: {
marginRight: "20px",
}
},
properties: {
startTime: {
type: 'string',
'x-component': 'DatePicker',
"[startTime, endTime]": {
type: "object",
"x-component": 'RangePicker',
'x-component-props': {
allowClear: true,
placeholder: '结算日期(开始时间)'
placeholder: ['结算日期(开始时间)', "结算日期(结束时间)"]
}
},
endTime: {
type: 'string',
'x-component': 'DatePicker',
'x-component-props': {
allowClear: true,
placeholder: '结算日期(结束时间)'
// startTime: {
// type: 'string',
// 'x-component': 'DatePicker',
// 'x-component-props': {
// allowClear: true,
// placeholder: '结算日期(开始时间)'
// }
// },
// endTime: {
// type: 'string',
// 'x-component': 'DatePicker',
// 'x-component-props': {
// allowClear: true,
// placeholder: '结算日期(结束时间)'
}
},
// }
// },
status: {
type: 'string',
enum: [
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment