Skip to content

Conversation

@sanjacornelius
Copy link
Contributor

@sanjacornelius sanjacornelius commented Apr 20, 2023

Issue & Reproduction Steps

Ticket: FOUR-8109

This PR addresses several issues related to process creation and management. The main issue was that processes created with a previously edited process template were not appearing in the list of processes. The root cause of this problem was found to be the 'is_template' property, which was being set as true.

Additionally, a few other related issues were discovered during testing.

  1. The process being converted to a template was being overwritten and hidden when the template was edited.
  2. When creating a process from a template multiple times, the previous process created was being overwritten.

This PR includes fixes for all the issues listed above, ensuring that processes are properly created and displayed in the processes list, templates are managed correctly without overwriting process data, and multiple processes can be created from a template without data loss.

How to Test

  1. Test for process created with a previously edited template

    • Create a process template and edit it
    • Create a new process using the edited template
    • Check if the new process is listed under processes
    • Check that the previous process is displayed correctly in the processes list
  2. Test for process converted to a template being overwritten

    • Convert an existing process to a template
    • Edit the template
    • Create a new process from the edited template
    • Check if the converted process is still listed and editable
    • Ensure that the new process is created as a new instance and doesn't overwrite any previous data
    • Ensure that the process history for the converted process and the new process is maintained separately
  3. Test for creating multiple processes from a template without overwriting previous data

    • Create a process template
    • Create a new process from the template
    • Create a second process from the template
    • Ensure that the data for each process is saved separately and can be accessed independently
    • Assert that both processes are displayed correctly in the processes list

Code Review Checklist

  • I have pulled this code locally and tested it on my instance, along with any associated packages.
  • This code adheres to ProcessMaker Coding Guidelines.
  • This code includes a unit test or an E2E test that tests its functionality, or is covered by an existing test.
  • This solution fixes the bug reported in the original ticket.
  • This solution does not alter the expected output of a component in a way that would break existing Processes.
  • This solution does not implement any breaking changes that would invalidate documentation or cause existing Processes to fail.
  • This solution has been tested with enterprise packages that rely on its functionality and does not introduce bugs in those packages.
  • This code does not duplicate functionality that already exists in the framework or in ProcessMaker.
  • This ticket conforms to the PRD associated with this part of ProcessMaker.

@sanjacornelius sanjacornelius merged commit dc009f2 into feature/FOUR-7375-c Apr 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants