Bug 1073473

Summary: When new for is created with the same name as some existing form, it overwrites the existing form
Product: [Retired] JBoss BPMS Platform 6 Reporter: Jan Hrcek <jhrcek>
Component: Form ModelerAssignee: Pere Fernàndez <pere.fernandez>
Status: CLOSED CURRENTRELEASE QA Contact: Jan Hrcek <jhrcek>
Severity: high Docs Contact:
Priority: unspecified    
Version: 6.0.1CC: mbiarnes, rrajasek
Target Milestone: CR1   
Target Release: 6.0.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-06 20:03:49 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Hrcek 2014-03-06 13:44:38 UTC
Description of problem:
This worked correctly up to BPMS 6.0.1 ER1, but is now broken in ER2.
The correct (and expected) behavior in ER1 was: when you try to create new form named X in some package, that already contains form with that name X, you got modal dialog with error: "Sorry, an item of that name already exists in the repository. Please choose another."

Now in ER2 it does the following: it opens new, empty form, which overwrites all the data in the existing form. If you check the underlying git repository, you can see, that the existing form was overwritten by new, empty form with the same name.

Version-Release number of selected component (if applicable):
BPMS 6.0.1 ER2

How reproducible:
Always

Steps to Reproduce:
1. Create some form, make some edits and save it
2. Create new form with exactly the same name as you created in 1

Actual results:
New form is created, overwriting all the content you had in the previous form

Expected results:
It should behave as it did in ER1 and prior versions (user should get a modal with warning and no new form should be created)

Comment 1 Jan Hrcek 2014-03-06 13:45:44 UTC
Additional info: the correct behavior which was in ER1 was implemented as a fix for previously reported bug 996425.

Comment 3 Michael 2014-03-17 09:53:57 UTC
Ticket cherry-picked into 6.0.1.CR1. 
Commits: 2763979ad5fffd6ab5a6d76c0ebdaff576a10f76

Comment 4 Jan Hrcek 2014-03-24 07:31:42 UTC
Ok, now it works correctly as it did in 6.0.1 ER1. Verified with BPMS 6.0.1 CR1