Created attachment 1430992 [details]
Description of problem:
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Import the dialog and domain attached.
2. Create a custom button on service for the dialog attached.
3. Order service . Go to Myservice In SUI .
4. Select service and then custom button in service .
5. No dialog elements are shown .
6. Classic UI shows dialog elements.
Appliance : https://10.8.198.232/ui/service
Service - multi-20180503-162824
Created attachment 1430993 [details]
Created attachment 1430994 [details]
I have started to look at this. In looking at what is going on it appears as though the "values" for a dropdown are not coming back from the API request. I will work with someone on the API team to troubleshoot why it does not seem to appear. This has been the root cause of why the dropdown listed in this ticket is not showing up. Will update ticket when we have more information.
Here is a sample of the requests we make for dialogs.
Here is the request for a catalog item with a dialog
Here is a custom button dialog request
The first request returns the "values" as part of the response, but the second one returns everything in the dialog except the "values" object in the response.
After talking with QA , we cannot conclusively say whether this functionality had ever worked in SUI. It does work in OPS UI so for feature parity we need to ensure it works in SUI. I investigated this with a member of the API team and found that we couldn't conclude this had ever worked for SUI. I am reassigning this issue to the API to see if they can help get it working so we can retest this issue and get it to work
I'm not sure what you're saying in https://bugzilla.redhat.com/show_bug.cgi?id=1574774#c5. Can you let us know (with examples):
1. Which request does not give you the data you are asking for
2. The data you are asking for
3. The data which is not coming back
The Here the custom button dialog request
https://10.8.198.232/api/service_dialogs/2?expand=resources&attributes=content is the one that is not returning the data we are asking for.
2. The data that should be included is a key called "values" for a dialog field that is a drop down.
3. To save space in the comments, please take a look at the following two gists
This is a service dialog that is rendered as part of a catalog item request.
This is a dialog that is rendered as part of a custom button details request.
You will see that it is the exact same dialog but one is rendered with a "values" key and one does not. the Custom button details request is the one we are having issues with. The endpoint we hit for that request looks like https://10.8.198.232/api/service_dialogs/2?expand=resources&attributes=content
Is that the same dialog field? I'm seeing that it has the same ID but different data - e.g. the data_type and default_value are different in the two examples.
I believe it is. I pulled this example off the appliance IP listed in this ticket. You should be able to log into that appliance to reproduce this as well. Please let me know if you have any questions
It looks like you need to provide some additional params when querying a service dialog as a primary collection if you want the content serialized in the same way as when you request it as a subresource of its service template. The following should work for you:
Can you let me know if an another API team member has some time to answer some questions I have about Tim's proposed solution to this issue? I talked with him briefly at the end of last week and I think there was some miscommunication on functionality so I don't believe his solution proposed above will work for this scenario.
GH PR https://github.com/ManageIQ/manageiq-ui-service/pull/1433
Verified in 22.214.171.124.20180822200426_5f6e52b