Bug 1753388 - Sporadic 404 Error when deleting custom button on generic object class
Summary: Sporadic 404 Error when deleting custom button on generic object class
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.11.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: GA
: 5.12.0
Assignee: Zita Nemeckova
QA Contact: Tasos Papaioannou
Red Hat CloudForms Documentation
URL:
Whiteboard:
Depends On:
Blocks: 1768576
TreeView+ depends on / blocked
 
Reported: 2019-09-18 19:02 UTC by John Dupuy
Modified: 2020-10-26 16:13 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1768576 (view as bug list)
Environment:
Last Closed: 2020-10-26 16:13:43 UTC
Category: Bug
Cloudforms Team: CFME Core
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
404 not found error (360.22 KB, image/gif)
2019-09-18 19:02 UTC, John Dupuy
no flags Details

Description John Dupuy 2019-09-18 19:02:27 UTC
Created attachment 1616382 [details]
404 not found error

Description of problem:
Sometimes when a custom button is deleted after it has been edited it results in a brief 404 error that disappears after a second. 

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

How reproducible:
70%

Steps to Reproduce:
1. Navigate to Automation > Automate > Generic Objects
2. Create a generic object class
3. Create a custom button under the class
4. Edit the custom button
5. Delete the custom button

Actual results:
Sometimes a 404 message appears with the message 
"Couldn't find CustomButton"

Expected results:
The custom button should be deleted without error

Additional info:
See gif attached

The custom button is deleted from the UI but if you try to add a custom button of the same name as the one just deleted you hit a "Server Error" and cannot add it. If you click "Add" again it results in a "Name already taken" flash message. If you then hit "Cancel", the button is still created!

Note 
bug 1753289, bug 1753281, and bug 1753237 are all related to this bug

Comment 3 Zita Nemeckova 2019-09-19 13:33:59 UTC
Note to self:

So far it happens for CustomButtons under CustomButonSet.

Comment 5 CFME Bot 2019-10-23 12:47:13 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/8f94aa7f8cae7237575e138d681848be1349f7ac
commit 8f94aa7f8cae7237575e138d681848be1349f7ac
Author:     Zita Nemeckova <znemecko>
AuthorDate: Mon Oct  7 10:05:42 2019 -0400
Commit:     Zita Nemeckova <znemecko>
CommitDate: Mon Oct  7 10:05:42 2019 -0400

    Toolbar delete button for Button/Button Group goes via generic API delete code not via genericObjectDefinitionToolbarController

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1753388

 app/helpers/application_helper/button/basic.rb | 4 +
 app/helpers/application_helper/button/generic_object_definition_button_button_group_delete.rb | 19 +-
 app/helpers/application_helper/toolbar/generic_object_definition_button_center.rb | 7 +-
 app/helpers/application_helper/toolbar/generic_object_definition_button_group_center.rb | 8 +-
 app/helpers/application_helper/toolbar_builder.rb | 2 +-
 app/javascript/toolbar-actions/delete.js | 11 +-
 6 files changed, 37 insertions(+), 14 deletions(-)

Comment 7 CFME Bot 2019-11-18 16:51:30 UTC
New commit detected on ManageIQ/manageiq-ui-classic/ivanchuk:

https://github.com/ManageIQ/manageiq-ui-classic/commit/4a9d4842824fb5e4a97f1234065bb73637f6cfa1
commit 4a9d4842824fb5e4a97f1234065bb73637f6cfa1
Author:     Zita Nemeckova <znemecko>
AuthorDate: Mon Oct  7 10:05:42 2019 -0400
Commit:     Zita Nemeckova <znemecko>
CommitDate: Mon Oct  7 10:05:42 2019 -0400

    Toolbar delete button for Button/Button Group goes via generic API delete code not via genericObjectDefinitionToolbarController

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1753388

 app/helpers/application_helper/button/basic.rb | 4 +
 app/helpers/application_helper/button/generic_object_definition_button_button_delete.rb | 18 +
 app/helpers/application_helper/button/generic_object_definition_button_button_group_delete.rb | 17 +
 app/helpers/application_helper/toolbar/generic_object_definition_button_center.rb | 7 +-
 app/helpers/application_helper/toolbar/generic_object_definition_button_group_center.rb | 8 +-
 app/helpers/application_helper/toolbar_builder.rb | 2 +-
 app/javascript/toolbar-actions/delete.js | 11 +-
 7 files changed, 54 insertions(+), 13 deletions(-)


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