-
Notifications
You must be signed in to change notification settings - Fork 56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[EZP-32397] Removed logic from ezdate.html.twig #1729
Conversation
547e1ce
to
c328b74
Compare
{% set action_type = | ||
app.request.attributes.get('_route') is same as('ez_content_draft_edit') or | ||
app.request.attributes.get('_route') is same as('ezplatform.content.translate') ? 'edit' : 'create' | ||
%} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can use in
operator here:
app.request.attributes.get('_route') in ['ez_content_draft_edit', 'ezplatform.content.translate']
but TBH this logic should be placed in form value mapper or / Form type buildView
method rather then in Twig template
Moved logic from template: ezsystems/repository-forms#344 |
QA approved. |
@mateuszbieniek could you merge it up? |
Merged up to |
|
and |
* Added condition for content.translate in edit/ezdate.html.twig * Changes after CR#1 * Dropped merging attr * Revert removing attrbiutes mergin from the view
This PR requires: ezsystems/repository-forms#344
This PR removes logic from the template https://github.com/ezsystems/ezplatform-admin-ui/blob/v1.5.17/src/bundle/Resources/views/fieldtypes/edit/ezdate.html.twig#L10 as it is no longer needed (see ezsystems/repository-forms#344)
Checklist:
$ composer fix-cs
)