OroPlatform Forums

Covering OroPlatform topics, including community updates and company announcements.

Forums Forums OroPlatform OroPlatform – How do I? Questions How to manually render workflow transition buttons?

This topic contains 6 replies, has 3 voices, and was last updated by  Mike Kudelya 7 years, 4 months ago.

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

  • Creator
    Topic
  • #36287

    Stepan Yudin
    Participant

    Hi everyone!

    Yesterday i faced a problem. I have an entity template. In this template i render a list of some related entities.
    For each of these entities i want to render available workflow transition buttons.

    I do it like that:

    So, buttons renders successfully. But when i click to any transition button – im redirected to corresponding workflow api url. And entity workflowStep is not changed.
    If i open this entity in separate template (where the transition buttons rendered in the head of the page, by default) – all transition handled correctly.

    So, how to render these buttons in any place and make em work?
    Thanks!


    Docker environment for Symfony2/OroCRM/OroBAP development on Windows platform
    https://github.com/stepansib/sf-oro-docker

Viewing 6 replies - 1 through 6 (of 6 total)
  • Author
    Replies
  • #36288

    Mike Kudelya
    Participant

    Hi,

    The easies approach is wrap oro_widget_render into

    #36289

    Stepan Yudin
    Participant

    Hi, Mike.

    Thank you, that works! Maybe you can help me with ‘workflow_widget_steps’ rendering too?
    Im trying to render this widget for every child entity, but it renders in the page header (not in specified template div and overrides parent entity’s steps widget)


    Docker environment for Symfony2/OroCRM/OroBAP development on Windows platform
    https://github.com/stepansib/sf-oro-docker

    #36290

    Mike Kudelya
    Participant

    I have made example for you, of course it needed to some modifications and checks, but it works. Put this code to your view page:

    and replace this file with following code:

    #36291

    Stepan Yudin
    Participant

    Thank you Mike, you saved me)
    Im not so familiar with JS but i understand your modifications to widget placeholder
    Many many thanks to you man!


    Docker environment for Symfony2/OroCRM/OroBAP development on Windows platform
    https://github.com/stepansib/sf-oro-docker

    #36292

    Bhavesh Tailor
    Participant

    Hello Mike ,

    I am trying to merge sales and opportunity process . I did created on save opportunity sales process automatically created with work and step id . now i want to add workflow transition button on opportunity view page .

    Thank You in advance .


    Bhavesh

    #36293

    Mike Kudelya
    Participant

    Hi

    You can add buttons via ‘/workflowdefinition’ page or just add/modify workflow by adding it to config. See workflow examples.

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

The forum ‘OroPlatform – How do I? Questions’ is closed to new topics and replies.

Back to top