Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Darren Clark 53 posts 250 karma points
    Sep 05, 2024 @ 10:35
    Darren Clark
    0

    Umbraco Forms 13.2.1 Issue with custom workflow

    Hi,

    I have recently upgraded my umbraco site from v12.1.1 to latest v13 and upgraded forms etc alongside.

    I have one custom workflow which calculates scores on record fields and adds a total to existing field , after upgrading the form would submit on front end and i could debug the custom workflow without any errors, but the form submission was never saved.

    I even added a new custom workflow from the docs page here >

    https://docs.umbraco.com/umbraco-forms/v/13.forms.latest-lts/developer/extending/adding-a-workflowtype

    and the same issue happened, form not saved.

    I then added a out the box Save as XML workflow and the the form saved that time. So something was not right with custom workflows, it seemed they blocked the form from saving in the database.

    Line by line i stripped back the code in the workflow to find out the following line was causing the issue.

    context.Record.State = FormState.Approved;
    

    Once i removed this line the form record saved to the db and the workflow ran.

    Can anyone shed any light on this?

    Has anyone else experienced this issue and can it be replicated on a fresh 13.4.1 install

    Cheers

  • Adam Kronquist 1 post 21 karma points
    Sep 11, 2024 @ 07:23
    Adam Kronquist
    0

    A customer brought this to our attention last week. We upgraded their site to v13 four months ago and it worked. The latest Entries I can find with this workflow is from August 12. I don't know what might have happened after that. But your solution of removing those lines works.

    I did a little more research and have created a issue here, https://github.com/umbraco/Umbraco.Forms.Issues/issues/1293.

    I got this answer from Umbracos support by comment that line out:

    "If they comment out that line, it'll mean that the form will just go through it's normal approval process (either being approved automatically, or manually, depending on how the form is configured)."

Please Sign in or register to post replies

Write your reply to:

Draft