Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
Metabase
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Engineering Digital Service
Metabase
Commits
a1984f1a
Unverified
Commit
a1984f1a
authored
5 years ago
by
Maz Ameli
Committed by
GitHub
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
fix pulse creation dropdowns (#11920)
parent
5bfe5e8a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
frontend/src/metabase/components/SchedulePicker.jsx
+37
-33
37 additions, 33 deletions
frontend/src/metabase/components/SchedulePicker.jsx
with
37 additions
and
33 deletions
frontend/src/metabase/components/SchedulePicker.jsx
+
37
−
33
View file @
a1984f1a
...
...
@@ -125,7 +125,7 @@ export default class SchedulePicker extends Component {
DAY_OPTIONS
.
unshift
({
name
:
t
`Calendar Day`
,
value
:
null
});
return
(
<
span
className
=
"
mt1
"
>
<
span
className
=
"
flex align-center
"
>
<
span
className
=
"h4 text-bold mx1"
>
on the
</
span
>
<
Select
className
=
"h4 text-bold bg-white"
...
...
@@ -136,7 +136,7 @@ export default class SchedulePicker extends Component {
options
=
{
MONTH_DAY_OPTIONS
}
/>
{
schedule
.
schedule_frame
!==
"
mid
"
&&
(
<
span
className
=
"
mt1
mx1"
>
<
span
className
=
"mx1"
>
<
Select
className
=
"h4 text-bold bg-white"
value
=
{
schedule
.
schedule_day
}
...
...
@@ -155,7 +155,7 @@ export default class SchedulePicker extends Component {
const
{
schedule
}
=
this
.
props
;
return
(
<
span
className
=
"
mt1
"
>
<
span
className
=
"
flex align-center
"
>
<
span
className
=
"h4 text-bold mx1"
>
on
</
span
>
<
Select
className
=
"h4 text-bold bg-white"
...
...
@@ -180,23 +180,25 @@ export default class SchedulePicker extends Component {
const
timezone
=
Settings
.
get
(
"
report-timezone-short
"
);
return
(
<
div
className
=
"mt1"
>
<
span
className
=
"h4 text-bold mr1"
>
at
</
span
>
<
Select
className
=
"mr1 h4 text-bold bg-white"
value
=
{
hour
}
options
=
{
HOUR_OPTIONS
}
onChange
=
{
({
target
:
{
value
}
})
=>
this
.
handleChangeProperty
(
"
schedule_hour
"
,
value
+
amPm
*
12
)
}
/>
<
Select
className
=
"h4 text-bold bg-white"
value
=
{
amPm
}
onChange
=
{
({
target
:
{
value
}
})
=>
this
.
handleChangeProperty
(
"
schedule_hour
"
,
hour
+
value
*
12
)
}
options
=
{
AM_PM_OPTIONS
}
/>
<
div
className
=
"flex align-center"
>
<
span
className
=
"h4 text-bold mr1"
>
at
</
span
>
<
Select
className
=
"mr1 h4 text-bold bg-white"
value
=
{
hour
}
options
=
{
HOUR_OPTIONS
}
onChange
=
{
({
target
:
{
value
}
})
=>
this
.
handleChangeProperty
(
"
schedule_hour
"
,
value
+
amPm
*
12
)
}
/>
<
Select
className
=
"h4 text-bold bg-white"
value
=
{
amPm
}
onChange
=
{
({
target
:
{
value
}
})
=>
this
.
handleChangeProperty
(
"
schedule_hour
"
,
hour
+
value
*
12
)
}
options
=
{
AM_PM_OPTIONS
}
/>
</
div
>
{
textBeforeSendTime
&&
(
<
div
className
=
"mt2 h4 text-bold text-medium border-top pt2"
>
{
textBeforeSendTime
}
{
hour
===
0
?
12
:
hour
}
:00
{
"
"
}
...
...
@@ -214,19 +216,21 @@ export default class SchedulePicker extends Component {
return
(
<
div
className
=
"mt1"
>
<
span
className
=
"h4 text-bold mr1"
>
{
textBeforeInterval
}
</
span
>
<
Select
className
=
"h4 text-bold bg-white"
value
=
{
scheduleType
}
onChange
=
{
({
target
:
{
value
}
})
=>
this
.
handleChangeProperty
(
"
schedule_type
"
,
value
)
}
options
=
{
scheduleOptions
}
optionNameFn
=
{
o
=>
capitalize
(
o
)
}
optionValueFn
=
{
o
=>
o
}
/>
{
scheduleType
===
"
monthly
"
&&
this
.
renderMonthlyPicker
()
}
{
scheduleType
===
"
weekly
"
&&
this
.
renderDayPicker
()
}
<
div
className
=
"flex align-center"
>
<
span
className
=
"h4 text-bold mr1"
>
{
textBeforeInterval
}
</
span
>
<
Select
className
=
"h4 text-bold bg-white"
value
=
{
scheduleType
}
onChange
=
{
({
target
:
{
value
}
})
=>
this
.
handleChangeProperty
(
"
schedule_type
"
,
value
)
}
options
=
{
scheduleOptions
}
optionNameFn
=
{
o
=>
capitalize
(
o
)
}
optionValueFn
=
{
o
=>
o
}
/>
{
scheduleType
===
"
monthly
"
&&
this
.
renderMonthlyPicker
()
}
{
scheduleType
===
"
weekly
"
&&
this
.
renderDayPicker
()
}
</
div
>
{
(
scheduleType
===
"
daily
"
||
scheduleType
===
"
weekly
"
||
scheduleType
===
"
monthly
"
)
&&
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment