Description of problem: When running a custom button the dynamic dialog fields should be passed the target object of the button. Version-Release number of selected component (if applicable): 5.7.3 How reproducible: Always Steps to Reproduce: 1. Create new Service Dialog with dynamic dialog field (point to /System/Request/InspectMe instance) 2. Attach dialog to custom button for a VM or Service 3. Run the dialog and view automation.log Actual results: Logging shows that the target object (vmdb_object_type) is not passed. INFO -- : <AEMethod checkbox> Root:<$evm.root> Attributes - Begin INFO -- : <AEMethod checkbox> Attribute - miq_group: #<MiqAeMethodService::MiqAeServiceMiqGroup:0x007f8395252a68> INFO -- : <AEMethod checkbox> Attribute - miq_server: #<MiqAeMethodService::MiqAeServiceMiqServer:0x007f83989dcab0> INFO -- : <AEMethod checkbox> Attribute - miq_server_id: 14 INFO -- : <AEMethod checkbox> Attribute - object_name: checkbox INFO -- : <AEMethod checkbox> Attribute - tenant: #<MiqAeMethodService::MiqAeServiceTenant:0x007f83aeec5840> INFO -- : <AEMethod checkbox> Attribute - user: #<MiqAeMethodService::MiqAeServiceUser:0x007f83955c6168> INFO -- : <AEMethod checkbox> Attribute - user_id: 1 INFO -- : <AEMethod checkbox> Root:<$evm.root> Attributes - End Expected results: Target object (vmdb_object_type) is passed with a handle to the object: INFO -- : <AEMethod checkbox> Root:<$evm.root> Attributes - Begin INFO -- : <AEMethod checkbox> Attribute - miq_group: #<MiqAeMethodService::MiqAeServiceMiqGroup:0x007fede4a31400> INFO -- : <AEMethod checkbox> Attribute - miq_server: #<MiqAeMethodService::MiqAeServiceMiqServer:0x007fee026c4150> INFO -- : <AEMethod checkbox> Attribute - miq_server_id: 14 INFO -- : <AEMethod checkbox> Attribute - object_name: checkbox INFO -- : <AEMethod checkbox> Attribute - service: #<MiqAeMethodService::MiqAeServiceService:0x007fee025cc1d0> INFO -- : <AEMethod checkbox> Attribute - service_id: 412 INFO -- : <AEMethod checkbox> Attribute - tenant: #<MiqAeMethodService::MiqAeServiceTenant:0x007fee02b62ce8> INFO -- : <AEMethod checkbox> Attribute - user: #<MiqAeMethodService::MiqAeServiceUser:0x007fee02c32470> INFO -- : <AEMethod checkbox> Attribute - user_id: 1 INFO -- : <AEMethod checkbox> Attribute - vmdb_object_type: service INFO -- : <AEMethod checkbox> Root:<$evm.root> Attributes - End Additional info:
https://github.com/ManageIQ/manageiq/pull/15810
Digging into this issue further it appear the code has been this way for a while (years) and has only now been identified. The fields exposed to this issue are not common fields for dynamic use, or do not need to target object when they are dynamic. (I dropped the severity of the BZ based on this.) Effected fields: check_box, date_control, date_time_control, text_box and text_box_area QE(Milan) - Is this something you could create an integration tests for?
New commit detected on ManageIQ/manageiq/master: https://github.com/ManageIQ/manageiq/commit/f8f29e8424cfce157e9129b5dbb38826f6f61116 commit f8f29e8424cfce157e9129b5dbb38826f6f61116 Author: Erik Clarizio <eclarizi> AuthorDate: Mon Aug 14 11:05:36 2017 -0700 Commit: Erik Clarizio <eclarizi> CommitDate: Mon Aug 14 12:34:45 2017 -0700 Ensure dialog is set before calling `.value` https://bugzilla.redhat.com/show_bug.cgi?id=1481380 app/models/dialog.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Discovered this issue while working on PR https://github.com/ManageIQ/manageiq-content/pull/170.
Verified in 5.9.0.1