Forums

Covering OroCommerce, OroCRM, OroPlatform topics, including community updates and company announcements.

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

Forum Replies Created

Viewing 15 replies - 16 through 30 (of 495 total)
  • Author
    Replies

  • Yevhen Shyshkin
    Participant

    Hello Matthew.

    All following recommendations are provided for OroCommerce 1.6.

    1) The easiest way to override this file it to put it to app/Resources directory at the application level – see documentation https://symfony.com/doc/2.8/templating/overriding.html.

    2) You may use bundle inheritance (i.e. set OroProductBundle as parent) and then put file at the same place in the directory structure.

    3) You may create event listener to kernel.controller event and override there _template attribute which is responsible for the path to template file.

    4) You may override whole controller together with all annotations including @Template.

    Of course there are other less trivial ways, but the first one is the most commonly used during the customization of an application.

    Please let me know if that helps.

    in reply to: Generate API WSS-Header for Kotlin #37936

    Yevhen Shyshkin
    Participant

    Here I have traced nonce generation step by step – you can do the same and hopefully it may give you a clue of what was done wrong.

    Please let me know if it helped you with your issue.

    in reply to: Generate API WSS-Header for Kotlin #37935

    Yevhen Shyshkin
    Participant

    Hello SkaiBoa.

    I’ve used following script to generate headers and it works fine (inspired by this post):

    And as a result I got following headers:

    I can guess that either something is with the way you are extracting a substring or SHA-1 hash is generated in binary form instead of hexadecimal.

    in reply to: Filters for dynamic columns DataGrid #37934

    Yevhen Shyshkin
    Participant

    Hello Shomeis.

    If you want to add column and filter it is better to use onBuildBefore event. There is another issue though – filters (and sorters) work on the main datagrid query only. In other words, it is not enough to mix your data using onResultAfter event to allow filter work with it – you have to make sure that this data is presented in the DB query.

    Usually it’s done using additional join to a required entity and added required parts to select, columns, filters and sorter sections of the datagrid. Here is an example: https://github.com/oroinc/orocommerce/blob/3.1.0-rc/src/Oro/Bundle/TaxBundle/EventListener/TaxCodeGridListener.php#L38-L47

    Please let me know if you still have some questions.

    in reply to: How to change only font-family in existing style.css file #37933

    Yevhen Shyshkin
    Participant

    Hello Avinash.

    You may start from $base-font variable. Have a look how it’s modified at CustomThemeBundle: https://github.com/oroinc/orocommerce/blob/master/src/Oro/Bundle/CustomThemeBundle/Resources/public/FrontendBundle/scss/settings/main/_typography.scss#L21-L23

    in reply to: Sorter For Dynamic DataGrid #37931

    Yevhen Shyshkin
    Participant

    Hello Aryana.

    It does not work because main datagrid query is not aware about these columns, so you have no result.

    Standard grid uses one main query to get data, filter data and sort data – so, default filters and sorter work on this query. In your case main query remained untouched – it doesn’t have columns for group names as group name in your case is just a label, not a field in the query.

    When you are working with grid you are not using main query – instead you have created new additional query ($qb = $this->em->getRepository(“WebSysVisitBundle:Visit”)…) to get groups and manually applied filters. That is why main query is not aware about your groups and sorters do not work.

    If you want to fix it you may add new join for each found group and then set required query column to each sorter.

    in reply to: OnlyOffice links #37922

    Yevhen Shyshkin
    Participant

    Hello Jay Weldy.

    You may create new column(s) in the required entity (Contact or Account) as string or text – probably you should allow modification using standard form, but you should customize the way they rendered at view and datagrid.

    To render your field as link at view page you should mix your property to view page either by overriding main template at application level (e.g. Oro/Bundle/ContactBundle/Resources/views/Contact/widget/info.html.twig) or using listener (see example at Oro\Bundle\TaxBundle\EventListener\ProductFormViewListener::onView).

    To render your field as link at datagrid you should add new column and render your value there using twig template – see example in https://github.com/oroinc/crm/blob/3.1.0-rc/src/Oro/Bundle/ContactBundle/Resources/config/oro/datagrids.yml#L33-L37.

    Please let me know if that’s what you needed.

    in reply to: How to edit message.en.yml file #37921

    Yevhen Shyshkin
    Participant

    Hello, Avinash.

    You can that from UI only. You have to:
    1) go to System > Localization > Translations
    2) find required translation by key – e.g. oro.auth.description.main
    3) change content of the Translated Value column
    4) click Update Cache button

    Then you can logout and ensure that your translation was applied.

    Let me know if it solve your issue.


    Yevhen Shyshkin
    Participant

    You have to create a bundle (see https://oroinc.com/b2b-ecommerce/doc/current/dev-guide/extend-and-customize/how-to-create-new-bundle) and add there file Resources/config/oro/datagrids.yml (see https://oroinc.com/b2b-ecommerce/doc/1.6/dev-guide/entities/datagrids) with the following content:

    This code adds a new column, a filter and a sorter to the main tasks grid. Here is how it should look like:

    Let me know if you still have some questions.

    in reply to: Handling Discountinued Products #37916

    Yevhen Shyshkin
    Participant

    No, slugs are unique as application has to distinguish products. Instead you may create redirects and redirect user from old slug to new slug. See OroRedirectBundle for more details.


    Yevhen Shyshkin
    Participant

    Hello Tom Van Overbeke.

    1. Not really. If you check Task entity you’ll see that it has two fields – owner (this is Assigned To field) field and createdBy (this is a User who actually created this task). So, you may use these fields separately. Unfortunately, createdBy field is not rendered in grid, but you may changed that in customization.

    2. Probably, you have some customization that send such email. In general you may use notification rules or processes to organize such logic.

    in reply to: Cannot download email attachment (export) #37913

    Yevhen Shyshkin
    Participant

    Hello.

    Could you, please, share a screenshot with the action you’re trying to do and share the error text you have?

    in reply to: ORO setup, help needed well payed. #37912

    Yevhen Shyshkin
    Participant

    Hello.

    1. Yes, you may have duplicated Contacts and Accounts. To fix that you may merge them together using Merge mass action on a grid – https://oroinc.com/orocrm/blog/merge-account-records-orocrm

    2. Import in Oro uses CSV files where each column is mapped to a specific field of a main or related entity. You may have a look at the Contacts import – just download export template (click Import File and then Export Template) and see what kind of data can be imported – https://oroinc.com/orocrm/doc/2.3/user-guide/import-export/import-contacts

    3. Accounts and Contacts can be merged (see answer 1). Almost all entities can be removed either one by one using Delete grid action or via Delete mass action (similar to merge mass action).

    4. You have to create a channel for it first – https://oroinc.com/orocrm/doc/2.3/user-guide-sales-tools/b2b-sales/business-customers. You may also be interested in a way Oro works with any type of customer – https://oroinc.com/orocrm/doc/2.3/user-guide-sales-tools/customer-management/customer-management-overview

    5. There are two options here.

    First – you may use Opportunity entity to track your sales. You may either use board view and just drag and drop them, or enable workflow and reopen your Opportunity every iteration – https://oroinc.com/orocrm/doc/2.3/user-guide-sales-tools/b2b-sales/opportunities

    Second – you may build custom workflow around any entity you like (most probably Business Customer). Using this workflow you may implement pretty much any business process you have in your company – https://oroinc.com/orocrm/doc/2.3/admin-guide/workflows

    6. You should use Processes for that. Their main purpose is to sync data between different types of entities. OroCRM already has 2-way sync in Magento integration for Magento related entities, so you may just e.g. sync Leads with Magento Customers and vice versa. By default Magento Customers are synchronized with Accounts and Contacts – see processes Create Account and Contact for Magento Customer and Export Magento Customer to Magento. You may follow this scenario and use your own set of processes – https://oroinc.com/orocrm/doc/2.3/admin-guide/monitoring/processes

    Please, let me know if you still have some questions.

    in reply to: Handling Discountinued Products #37911

    Yevhen Shyshkin
    Participant

    Hello, Michael.

    You may set inventory status Discontinued for the discontinued products and by default these products will not be visible.

    As for search replacement – you may mention old product SKU and name at the description of a new product, so every time user enter old SKU or name in the global search new product will be found. If you don’t like an idea of saving these products in description you may create new text product attribute for substituted products, make it searchable and put there all information about the old products – it will work exactly the same.

    This solution can be done using out of the box features.

    But if you’re developer and want to make it more convenient then you may add product selector instead of textarea, use it everywhere at front office (not only in search), organize redirects from old product URL to new one etc.

    Please, let me know if one of the proposed solutions works for you.

    in reply to: Basic Extension of standard layout #37901

    Yevhen Shyshkin
    Participant

    Hello Christian.

    I see two issues here.

    First – you should just add one block using @add function instead of @addTree, here is example: https://github.com/oroinc/orocommerce/blob/3.1.0-rc/src/Oro/Bundle/OrderBundle/Resources/views/layouts/default/oro_order_frontend_index/layout.yml#L23-L26

    Second – block name in the template should have name _my_random_thing_widget – feel free to check an example here: https://github.com/oroinc/orocommerce/blob/3.1.0-rc/src/Oro/Bundle/OrderBundle/Resources/views/layouts/default/oro_order_frontend_index/layout.html.twig

    And make sure that application is able to see your layout update – i.e. it has to be in Resources/views/layouts/<theme_name>/page or Resources/views/layouts/<theme_name>/<route_name> directory.

    Please let me know if this solution works for you.

Viewing 15 replies - 16 through 30 (of 495 total)

You will be redirected to [title]. Would you like to continue?

Yes No