Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
smart_date-3443532
Manage
Activity
Members
Labels
Plan
Custom issue tracker
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review 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
Issue forks
smart_date-3443532
Commits
090c725d
Commit
090c725d
authored
8 months ago
by
Matthieu Scarset
Committed by
Martin Anderson-Clutz
8 months ago
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#3433267
by matthieuscarset: Smart date value custom format tokens empty
parent
d850e48f
No related branches found
Branches containing commit
Tags
4.1.0-rc7
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
smart_date.module
+16
-0
16 additions, 0 deletions
smart_date.module
with
16 additions
and
0 deletions
smart_date.module
+
16
−
0
View file @
090c725d
...
...
@@ -191,3 +191,19 @@ function smart_date_config_schema_info_alter(&$definitions) {
function
smart_date_views_plugins_argument_alter
(
array
&
$plugins
)
{
$plugins
[
'date'
][
'class'
]
=
'Drupal\smart_date\Plugin\views\argument\Date'
;
}
/**
* Implements hook_module_implements_alter().
*
* Move smart_date hook_tokens() implementation to the end of the list to avoid
* conflict with the Tokens module's remplacement for custom date format/values.
*/
function
smart_date_module_implements_alter
(
&
$implementations
,
$hook
)
{
switch
(
$hook
)
{
case
'tokens'
:
$group
=
$implementations
[
'smart_date'
];
unset
(
$implementations
[
'smart_date'
]);
$implementations
[
'smart_date'
]
=
$group
;
break
;
}
}
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