Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
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
linweijiong
jinfa-platform
Commits
5199f69d
Commit
5199f69d
authored
Dec 20, 2021
by
XieZhiXiong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
chore: 替换时间选择器
parent
60f0b1ec
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
24 deletions
+4
-24
index.tsx
...merchantCouponUnsubmitted/components/CouponForm/index.tsx
+2
-0
schema.tsx
...erchantCouponUnsubmitted/components/CouponForm/schema.tsx
+2
-24
No files found.
src/pages/transaction/marketingAbility/merchantCoupon/merchantCouponUnsubmitted/components/CouponForm/index.tsx
View file @
5199f69d
...
...
@@ -21,6 +21,7 @@ import {
}
from
'@/constants/marketing'
;
import
AnchorPage
from
'@/components/AnchorPage'
;
import
NiceForm
from
'@/components/NiceForm'
;
import
FormilyRangeTime
from
'@/components/RangeTime/FormilyRangeTime'
;
import
schema
from
'./schema'
;
import
{
createEffects
}
from
'./effects'
;
import
{
ProductItemType
}
from
'../GoodsDrawer'
;
...
...
@@ -419,6 +420,7 @@ const CouponForm: React.FC<IProps> = (props) => {
CategoriesList
,
CascaderFormItem
,
ApplicableGoodsFormItem
,
FormilyRangeTime
,
}
}
expressionScope=
{
{
renderTableItemRemove
,
...
...
src/pages/transaction/marketingAbility/merchantCoupon/merchantCouponUnsubmitted/components/CouponForm/schema.tsx
View file @
5199f69d
...
...
@@ -103,21 +103,10 @@ const schema: ISchema = {
title
:
intl
.
formatMessage
({
id
:
'merchantCoupon.giveCouponTime'
}),
type
:
'string'
,
required
:
true
,
'x-component'
:
'
RangePicker
'
,
'x-component'
:
'
FormilyRangeTime
'
,
'x-component-props'
:
{
placeholder
:
[
intl
.
formatMessage
({
id
:
'merchantCoupon.giveCouponStartTime'
}),
intl
.
formatMessage
({
id
:
'merchantCoupon.giveCouponEndTime'
})],
showTime
:
true
,
disabledDate
:
(
current
)
=>
current
&&
current
<
moment
().
startOf
(
'day'
),
disabledTime
:
(
current
,
type
)
=>
{
if
((
type
===
'start'
||
type
===
'end'
)
&&
moment
().
isSame
(
current
,
'day'
))
{
return
{
disabledHours
:
()
=>
range
(
0
,
24
).
splice
(
0
,
moment
().
get
(
'hour'
)),
disabledMinutes
:
()
=>
range
(
0
,
60
).
splice
(
0
,
moment
().
get
(
'minute'
)),
disabledSeconds
:
()
=>
range
(
0
,
60
).
splice
(
0
,
moment
().
get
(
'second'
)),
};
}
return
{};
},
},
},
},
...
...
@@ -300,21 +289,10 @@ const schema: ISchema = {
'[effectiveTimeStart, effectiveTimeEnd]'
:
{
title
:
' '
,
type
:
'string'
,
'x-component'
:
'
RangePicker
'
,
'x-component'
:
'
FormilyRangeTime
'
,
'x-component-props'
:
{
placeholder
:
[
`
${
intl
.
formatMessage
({
id
:
'merchantCoupon.effectiveTimeEnd'
})}
`
,
`
${
intl
.
formatMessage
({
id
:
'merchantCoupon.劵Validperioddeadline'
})}
`
],
showTime
:
true
,
disabledDate
:
(
current
)
=>
current
&&
current
<
moment
().
startOf
(
'day'
),
disabledTime
:
(
current
,
type
)
=>
{
if
((
type
===
'start'
||
type
===
'end'
)
&&
moment
().
isSame
(
current
,
'day'
))
{
return
{
disabledHours
:
()
=>
range
(
0
,
24
).
splice
(
0
,
moment
().
get
(
'hour'
)),
disabledMinutes
:
()
=>
range
(
0
,
60
).
splice
(
0
,
moment
().
get
(
'minute'
)),
disabledSeconds
:
()
=>
range
(
0
,
60
).
splice
(
0
,
moment
().
get
(
'second'
)),
};
}
return
{};
},
},
},
invalidDay
:
{
...
...
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