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
d5b10351
Commit
d5b10351
authored
9 years ago
by
Tom Robinson
Browse files
Options
Downloads
Plain Diff
Merge branch 'pulses' of github.com:metabase/metabase into pulses
parents
ebd662db
338c1a30
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/metabase/api/pulse.clj
+10
-0
10 additions, 0 deletions
src/metabase/api/pulse.clj
src/metabase/models/pulse_channel.clj
+16
-2
16 additions, 2 deletions
src/metabase/models/pulse_channel.clj
with
26 additions
and
2 deletions
src/metabase/api/pulse.clj
+
10
−
0
View file @
d5b10351
...
...
@@ -55,6 +55,16 @@
[
id
]
(
db/cascade-delete
Pulse
:id
id
))
(
defendpoint
GET
"/form_input"
""
[]
(
let
[
card
(
Card
id
)]
(
read-check
Database
(
:database
(
:dataset_query
card
)))
(
let
[
data
(
:data
(
driver/dataset-query
(
:dataset_query
card
)
{
:executed_by
*current-user-id*
}))]
{
:status
200
:body
(
html
[
:html
[
:body
{
:style
""
}
(
p/render-pulse-card
card
data
)]])})))
(
defendpoint
GET
"/preview_card/:id"
"Get HTML rendering of a `Card` with ID."
[
id
]
...
...
This diff is collapsed.
Click to expand it.
src/metabase/models/pulse_channel.clj
+
16
−
2
View file @
d5b10351
...
...
@@ -17,8 +17,22 @@
{:email {:name \"Email\", :recipients? true}
:slack {:name \"Slack\", :recipients? false}}"
{
:email
{
:recipients?
true
}
:slack
{
:recipients?
false
}})
{
:email
{
:displayName
"Email"
:recipients?
true
:fields
[{
:name
"recipients"
:displayName
"Send to"
:multi
:
true
:type
:
"email"
:placeholder
"Enter email address these questions should be sent to"
:required
true
}]}
:slack
{
:displayName
"Slack"
:recipients?
false
:fields
[{
:name
"channel"
:displayName
"Send to"
:multi
:
false
:type
:
"select"
:options
[
"#general"
,
"#random"
,
"#ios"
]
:required
true
}]}})
(
defn
channel-type?
"Predicate function which returns `true` if the given argument is a valid value as a channel-type, `false` otherwise."
...
...
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