SparkDevNetwork / Rock

An open source CMS, Relationship Management System (RMS) and Church Management System (ChMS) all rolled into one.
http://www.rockrms.com
577 stars 348 forks source link

Workflows cannot be copied in certain scenario #5934

Closed ElimAdmin closed 2 months ago

ElimAdmin commented 2 months ago

Description

I am unable to copy workflows on my site (v16.5). These are the steps to recreate the same situation on rockrmlatest.

  1. Open Workflow Configuration (Home > Settings > General > Workflow Configuration).

  2. Expand Samples.

  3. Open Landing Page workflow.

  4. Copy workflow.

  5. Save new workflow.

  6. Open Landing Page workflow.

  7. Copy workflow.

  8. Save new workflow. Note error: "Please correct the following: Workflow Number Prefix is already being used by another workflow type. Please use a unique prefix." The new workflow cannot be saved.

  9. Open Position Approval workflow.

  10. Copy workflow.

  11. Save new workflow - note same error.

  12. Delete 'Landing Page - Copy' workflow created above.

  13. Run the SQL to confirm that there are no new workflow types: SELECT * FROM [ WorkflowType] ORDER BY Id DESC

  14. Open Landing Page workflow.

  15. Copy workflow and save new workflow - can now save.

  16. Edit the 'Landing Page - Copy' workflow and change its name to anything.

  17. Open Landing Page workflow.

  18. Copy and Save. Note error. The name of the workflow does not make any difference.

  19. Open Position Approval workflow.

  20. Copy and Save. Note error.

  21. Delete the copied and renamed workflow, so now there are no new workflows.

  22. Open Position Approval workflow.

  23. Copy and Save. Copy is successful.

  24. Open the Landing Page workflow and try to copy. Note error.

Actual Behavior

It seems that if a workflow prior to the LAST workflow is copied, and is then copied again, that no new workflow copies can then be saved. This might not be the right description.

Expected Behavior

Copying a workflow should be entirely independent of any prior copying actions.

Steps to Reproduce

See above.

Issue Confirmation

Rock Version

Version 16.5 16.5 (1.16.5.4), and rockrmslatest

Client Culture Setting

Client Culture Setting: en-NZ, Browser settings Language = English (New Zealand).

ghost commented 2 months ago

Is this issue resolved by the following commit made yesterday? We've seen this too when versioning our workflows (starting with a copy). It would be convenient to not have to worry about the Number Prefix step on copy.

Added a fix for the Workflow Type copying process

chead4 commented 2 months ago

@nlBayside Hi Noah - Yes, development on this ticket is in progress and is nearing completion. As soon as it is complete the commit link and Fixed in Version will be updated here in GitHub.