OroCommerce Forums

Covering OroCommerce topics, including community updates and company announcements.

Forums Forums OroCommerce unable to create reusable theme

This topic contains 9 replies, has 2 voices, and was last updated by  Amin 7 years, 1 month ago.

Starting from March 1, 2020 the forum has been switched to the read-only mode. Please head to StackOverflow for support.

  • Creator
    Topic
  • #31477

    Amin
    Participant

    Hello,

    I followed this tutorial:

    https://www.orocrm.com/documentation/2.0/book/layout#book-themes-reusable-themes

    And I still get acme-theme not found:

    I’m using OroCRM 2.0 and PHP 7.0 on Ubuntu 16.

    With the following PHP extensions:

    Is there an open source Bundle with a theme I can just modify.
    Thank you in advance for your help.

Viewing 9 replies - 1 through 9 (of 9 total)
  • Author
    Replies
  • #31478

    Alex Puscas
    Participant

    Hey Amin!

    Please post the steps or the part of the tutorial you followed in order to configure the acme-theme theme.

    This post might give you some useful information. Also, this issue might help you.

    In order to get best help for ORO CRM application, please post questions about ORO CRM on ORO CRM Forum. We are more familiar with ORO Commerce application, but we will try to help you out.

    Thanks,
    Alex Puscas

    #31479

    Amin
    Participant

    So I created the settings file with the following content

    name of my bundle:
    AcmeNewBundle

    settings.yml path:
    src/Acme/Bundle/NewBundle/Resources/public/themes/acme-theme/settings.yml

    Then, changed

    And whenever I run theme list, i get the following:

    #31480

    Amin
    Participant

    Note I am now using OroCommerce but I tried the same steps with OroCRM, since the documentation is identical and they are both built on top of OroPlatform.

    #31481

    Alex Puscas
    Participant

    Hey Amin!

    Try replacing - character with _ in the theme name. E.g: Use acme_theme instead of acme-theme. This should fix your issue.

    There seams to be a bug related to theme naming.

    Thanks for reporting it!
    Alex Puscas

    #31482

    Amin
    Participant

    awesome man! works like a charm :D I freaking luv ya.

    Just one more question, I followed this readme file as well

    https://github.com/orocrm/platform/blob/master/src/Oro/Bundle/LayoutBundle/Resources/doc/theme_definition.md#route-related-updates

    Basically created this file:

    DemoBundle/Resources/views/layouts/first_theme/theme.yml

    and had
    label: My Theme

    It seems oro scans those directories and complains if I add something invalid, but whenever I do oro:theme:list it hangs, what’s the difference here, I am using OroCommerce but the readme is for OroCRM.

    Thanks and feel free to mark this issue as resolved.

    #31483

    Alex Puscas
    Participant

    Hey Amin!

    Please explain with more details what issue you experience.
    If the issue is that oro:theme:list command runs slower when you modify theme configuration file, that is expected. You can disable xdebug or use latest PHP version in order to speed up things.
    You can also run cache:clear command before oro:theme:list in order to speed up oro:theme:list command.

    Thanks!
    Alex Puscas

    #31484

    Amin
    Participant

    No issue I was just wondering, what’s the difference between creating a theme in:

    src/Acme/Bundle/NewBundle/Resources/public/themes/acme_theme/settings.yml

    and

    DemoBundle/Resources/views/layouts/first_theme/theme.yml

    Both approaches are found in the documentation.

    #31485

    Alex Puscas
    Participant

    ORO Commerce uses Layout Bundle and Layout Component for the store (front) part of the application. Layout defines the structure of the user interface and easy and powerful ways to configure and manipulate page structure. Configuration file DemoBundle/Resources/views/layouts/first_theme/theme.yml is used by Layout Bundle.

    The other configuration file, src/Acme/Bundle/NewBundle/Resources/public/themes/acme_theme/settings.yml defines a theme used by Theme Bundle and is used for styling the management (back-office) part of the application.

    #31486

    Amin
    Participant

    got it. thank you

Viewing 9 replies - 1 through 9 (of 9 total)

The forum ‘OroCommerce’ is closed to new topics and replies.

Back to top