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
0dbe2761
Unverified
Commit
0dbe2761
authored
11 months ago
by
Braden Shepherdson
Committed by
GitHub
11 months ago
Browse files
Options
Downloads
Patches
Plain Diff
[Drills] Only show "Extract" and "Combine" actions on MBQL stages (#42424)
They don't work correctly on a native stage.
parent
2bac5512
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/lib/drill_thru/column_extract.cljc
+4
-1
4 additions, 1 deletion
src/metabase/lib/drill_thru/column_extract.cljc
src/metabase/lib/drill_thru/combine_columns.cljc
+3
-2
3 additions, 2 deletions
src/metabase/lib/drill_thru/combine_columns.cljc
with
7 additions
and
3 deletions
src/metabase/lib/drill_thru/column_extract.cljc
+
4
−
1
View file @
0dbe2761
...
...
@@ -11,6 +11,7 @@
Extra constraints:
- MBQL stages only
- Database must support `:regex` feature for the URL and Email extractions to work."
(
:require
[
medley.core
:as
m
]
...
...
@@ -40,7 +41,9 @@
[
query
:-
::lib.schema/query
stage-number
:-
:int
{
:keys
[
column
column-ref
value
]}
:-
::lib.schema.drill-thru/context
]
(
when
(
and
column
(
nil?
value
))
(
when
(
and
column
(
nil?
value
)
(
lib.drill-thru.common/mbql-stage?
query
stage-number
))
(
when-let
[
drill
(
column-extract-drill-for-column
query
column
)]
(
merge
drill
{
:lib/type
:metabase.lib.drill-thru/drill-thru
...
...
This diff is collapsed.
Click to expand it.
src/metabase/lib/drill_thru/combine_columns.cljc
+
3
−
2
View file @
0dbe2761
...
...
@@ -19,11 +19,12 @@
"Column clicks on string columns.
Might add a stage, like `:drill-thru/column-filter` does, if the current stage has aggregations."
[
_
query
:-
::lib.schema/query
_
stage-number
:-
:int
[
query
:-
::lib.schema/query
stage-number
:-
:int
{
:keys
[
column
value
]}
:-
::lib.schema.drill-thru/context
]
(
when
(
and
column
(
nil?
value
)
(
lib.drill-thru.common/mbql-stage?
query
stage-number
)
(
lib.types.isa/string?
column
))
{
:lib/type
:metabase.lib.drill-thru/drill-thru
:type
:drill-thru/combine-columns
...
...
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