Bug 1338007 - Automate Method: Loosing value entered in data field when adding input parameters
Summary: Automate Method: Loosing value entered in data field when adding input parame...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.5.0
Hardware: Unspecified
OS: Unspecified
high
unspecified
Target Milestone: GA
: 5.6.0
Assignee: Harpreet Kataria
QA Contact: Matouš Mojžíš
URL:
Whiteboard:
Depends On:
Blocks: 1338817
TreeView+ depends on / blocked
 
Reported: 2016-05-20 16:58 UTC by Harpreet Kataria
Modified: 2018-06-20 13:34 UTC (History)
7 users (show)

Fixed In Version: 5.6.0.8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1338817 (view as bug list)
Environment:
Last Closed: 2016-06-29 16:04:57 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:


Attachments (Terms of Use)
entered data in method editor (39.68 KB, image/png)
2016-05-20 17:02 UTC, Harpreet Kataria
no flags Details
method lost in Data field (43.13 KB, image/png)
2016-05-20 17:04 UTC, Harpreet Kataria
no flags Details
value in data field lost after adding parameter (46.45 KB, image/png)
2016-05-20 17:15 UTC, Harpreet Kataria
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1348 0 normal SHIPPED_LIVE CFME 5.6.0 bug fixes and enhancement update 2016-06-29 18:50:04 UTC

Description Harpreet Kataria 2016-05-20 16:58:35 UTC
Description of problem: Automate Method: Loosing value entered in data field when adding input parameters


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


How reproducible:100%


Steps to Reproduce:
1. Go to Automate Explorer,try to Add a new method under a class
2. Add name, description, some data in Data field
3. Then expand "Show input parameters" box
4. Press + button to add Input parameters, notice Data entered previously is missing from Data field, then continue to add input parameters and save method, Value entered in Data field does not get saved.

Actual results: Value entered in Data field is lost


Expected results: Value entered in Data field should remain intact


Additional info: see attached screenshots

Comment 2 Harpreet Kataria 2016-05-20 17:02:51 UTC
Created attachment 1160015 [details]
entered data in method editor

Comment 3 Harpreet Kataria 2016-05-20 17:04:07 UTC
Created attachment 1160016 [details]
method lost in Data field

Comment 4 Harpreet Kataria 2016-05-20 17:15:31 UTC
Created attachment 1160017 [details]
value in data field lost after adding parameter

Comment 5 Harpreet Kataria 2016-05-20 17:23:27 UTC
In

Comment 6 Harpreet Kataria 2016-05-20 17:26:07 UTC
In order to save the value in Data fields as a workaround user can first save method with All the values entered in Name, Description, Data etc fields save the record, then Edit the same method again and add Input Parameters, Save the record.

Comment 9 CFME Bot 2016-05-23 19:51:54 UTC
New commit detected on ManageIQ/manageiq/master:
https://github.com/ManageIQ/manageiq/commit/bd0dcb2bec3510f85a815d7e0f372822026bcb03

commit bd0dcb2bec3510f85a815d7e0f372822026bcb03
Author:     Harpreet Kataria <hkataria@redhat.com>
AuthorDate: Fri May 20 14:50:01 2016 -0400
Commit:     Harpreet Kataria <hkataria@redhat.com>
CommitDate: Fri May 20 14:50:01 2016 -0400

    Split input parameters in method editor into it's own view.
    
    Replacing whole form when adding/removing input parameters in method editor was causing to loose value in Data field on the form due to the fact that data field does not get saved in @edit[:new] until add/save button is pressed due to the large amount of data that can be saved in that field and we don't send the large amount of data up to server every time value is changed in data field on the form. To resolve the issue splitting input_div into it's own view so page replace can be done on that specific div when adding/removing Input parameters to refresh the table in method editor.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1338007

 app/controllers/miq_ae_class_controller.rb    | 33 ++++--------
 app/views/miq_ae_class/_inputs.html.haml      | 77 +++++++++++++++++++++++++++
 app/views/miq_ae_class/_method_form.html.haml | 76 +-------------------------
 3 files changed, 87 insertions(+), 99 deletions(-)
 create mode 100644 app/views/miq_ae_class/_inputs.html.haml

Comment 10 Matouš Mojžíš 2016-05-27 10:08:17 UTC
Verified in 5.6.0.8-rc1.20160524155303_f2a5a50.
Data were not lost, when I added an input parameter and when I saved method then.

Comment 11 CFME Bot 2016-06-13 19:12:28 UTC
New commit detected on cfme/5.5.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=cf203a572b793e05215bf1a7ef7844d69fe14a69

commit cf203a572b793e05215bf1a7ef7844d69fe14a69
Author:     Harpreet Kataria <hkataria@redhat.com>
AuthorDate: Fri May 20 14:50:01 2016 -0400
Commit:     Harpreet Kataria <hkataria@redhat.com>
CommitDate: Mon Jun 13 13:40:02 2016 -0400

    Split input parameters in method editor into it's own view.
    
    Replacing whole form when adding/removing input parameters in method editor was causing to loose value in Data field on the form due to the fact that data field does not get saved in @edit[:new] until add/save button is pressed due to the large amount of data that can be saved in that field and we don't send the large amount of data up to server every time value is changed in data field on the form. To resolve the issue splitting input_div into it's own view so page replace can be done on that specific div when adding/removing Input parameters to refresh the table in method editor.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1338007
    https://bugzilla.redhat.com/show_bug.cgi?id=1338817

 app/controllers/miq_ae_class_controller.rb    | 37 ++++---------
 app/views/miq_ae_class/_inputs.html.haml      | 77 +++++++++++++++++++++++++++
 app/views/miq_ae_class/_method_form.html.haml | 73 +------------------------
 3 files changed, 89 insertions(+), 98 deletions(-)
 create mode 100644 app/views/miq_ae_class/_inputs.html.haml

Comment 12 CFME Bot 2016-06-13 19:12:36 UTC
New commit detected on cfme/5.5.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=a39de4d29cde758da8ee3cbda3ea784c89ec89ea

commit a39de4d29cde758da8ee3cbda3ea784c89ec89ea
Merge: 8269067 cf203a5
Author:     Dan Clarizio <dclarizi@redhat.com>
AuthorDate: Mon Jun 13 15:11:08 2016 -0400
Commit:     Dan Clarizio <dclarizi@redhat.com>
CommitDate: Mon Jun 13 15:11:08 2016 -0400

    Merge branch '55z_pr_8864' into '5.5.z'
    
    Split input parameters in method editor into it's own view.
    
    Replacing whole form when adding/removing input parameters in method editor was causing to loose value in Data field on the form due to the fact that data field does not get saved in @edit[:new] until add/save button is pressed due to the large amount of data that can be saved in that field and we don't send the large amount of data up to server every time value is changed in data field on the form. To resolve the issue splitting input_div into it's own view so page replace can be done on that specific div when adding/removing Input parameters to refresh the table in method editor.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1338007
    https://bugzilla.redhat.com/show_bug.cgi?id=1338817
    
    @dclarizi @chessbyte please review/merge. This is clean cherry-pick for https://github.com/ManageIQ/manageiq/pull/8864
    
    See merge request !948

 app/controllers/miq_ae_class_controller.rb    | 37 ++++---------
 app/views/miq_ae_class/_inputs.html.haml      | 77 +++++++++++++++++++++++++++
 app/views/miq_ae_class/_method_form.html.haml | 73 +------------------------
 3 files changed, 89 insertions(+), 98 deletions(-)

Comment 14 errata-xmlrpc 2016-06-29 16:04:57 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2016:1348

Comment 15 Matouš Mojžíš 2018-06-20 13:34:15 UTC
One time issue. Setting qe_test_coverage flag to -.


Note You need to log in before you can comment on or make changes to this bug.