Skip to content
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

Add update page with headers #41

Merged
merged 1 commit into from
Sep 18, 2024
Merged

Add update page with headers #41

merged 1 commit into from
Sep 18, 2024

Conversation

loic425
Copy link
Member

@loic425 loic425 commented Sep 18, 2024

image

@@ -2,9 +2,14 @@

{% set configuration = hookable_metadata.context.configuration %}

{% set index_url = sylius_generate_redirect_path(app.request.headers.get('referer')|default(path(
{#{% set index_url = sylius_generate_redirect_path(app.request.headers.get('referer')|default(path(#}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't have the sylius_generate_redirect_path that should be added to Twig Extra.

@@ -0,0 +1,34 @@
{% from '@SyliusBootstrapAdminUi/shared/helper/breadcrumbs.html.twig' import breadcrumbs %}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

General thought, many templates are almost identical between create/update pages, maybe some of them can be moved to /shared/crud/common/content/header/breadcrumbs and re-used by defining few variables

@@ -0,0 +1,18 @@
{% import '@SyliusBootstrapAdminUi/shared/helper/header.html.twig' as header %}

{% if hookable_metadata.context.metadata is defined and hookable_metadata.context.configuration is defined %}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Once most of the UI will be done. we should review templates for repeatable boilerplace code and make some DX improvements to TwigHooks and other packages to cleanup templates

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants