Bug 1685266 - Service Dialog Date/DateTime Picker dynamic dialog values not displayed.
Summary: Service Dialog Date/DateTime Picker dynamic dialog values not displayed.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.10.1
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: GA
: 5.11.0
Assignee: Harpreet Kataria
QA Contact: Niyaz Akhtar Ansari
Red Hat CloudForms Documentation
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-03-04 20:07 UTC by William Fitzgerald
Modified: 2019-12-12 13:36 UTC (History)
10 users (show)

Fixed In Version: 5.11.0.1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-12-12 13:36:02 UTC
Category: Bug
Cloudforms Team: CFME Core
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Date Picker and DateTime Picker not returning proper values (88.48 KB, image/png)
2019-03-04 20:08 UTC, William Fitzgerald
no flags Details
screenshot timepicker (83.70 KB, image/png)
2019-07-09 11:44 UTC, Niyaz Akhtar Ansari
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:4199 0 None None None 2019-12-12 13:36:15 UTC

Description William Fitzgerald 2019-03-04 20:07:03 UTC
Description of problem: Date Picker and DateTime Picker not returning proper values 


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

How reproducible:
100%

Steps to Reproduce:
1. Create a dialog with a Date Picker/DateTmie picker
2. Make the dialog field dynamic
3. Create a service and add your dialog
4. Order your service

Actual results:
Notice the date is tomorrow

Expected results:
Date should be today

Additional info:
Reproducer: 10.8.196.234
Order service vmware65_item1

Comment 2 William Fitzgerald 2019-03-04 20:08:15 UTC
Created attachment 1540719 [details]
Date Picker and DateTime Picker not returning proper values

Comment 4 drew uhlmann 2019-03-05 19:22:52 UTC
So I disagree with the premise of this ticket because it makes no sense to have a datetime picker that picks today, actually. That was initially set to tomorrow because in something like a retirement context, it makes no sense whatsoever to provision a vm that gets immediately retired. So the stated intended behavior of this please had better not be loading with today's date. That's just kinda idiotic. 

Actual results:
Notice the date is tomorrow

Expected results:
Date should be today
 
I hope not. Can I get someone to reevaluate that for me please? 

What I do think is wrong is that the date time picker and date picker, when dynamic, don't get the values set correctly by automate. But that's a far different thing than the stated reason this ticket was opened. 

I see the automate_values_hash method on the dialog running eight times for a single dynamic field, and that seems bad. 

Also this is pretty clearly a backend issue and probably shouldn't be assigned to Zita.

Comment 5 Loic Avenel 2019-03-05 20:31:34 UTC
it is a date Picker with Day + hours and minutes or just Day?

Comment 6 drew uhlmann 2019-03-05 20:37:07 UTC
The default, acting as designed behavior of _both_ types of fields, datetimepicker and datepicker, is for the default to be a day ahead of today.

Comment 7 drew uhlmann 2019-03-05 21:18:52 UTC
https://github.com/ManageIQ/manageiq/pull/18523

Comment 8 Niyaz Akhtar Ansari 2019-07-09 11:43:29 UTC
The issue is still reproducible with Timepicker.

tested in Version 5.11.0.13.20190705140324_b74c283

Hence failing this BZ

Automate method
...............

new_date = Time.utc(2019, 07, 02)
$evm.object['value'] = new_date

Comment 9 Niyaz Akhtar Ansari 2019-07-09 11:44:04 UTC
Created attachment 1588691 [details]
screenshot timepicker

Comment 10 drew uhlmann 2019-07-09 14:00:08 UTC
Unfortunately I'm logging that the automation on this is working as intended now which means this failed QE for a reason that I believe is more a UI issue. 

The log shows the correct value being set inside the engine:
<AEMethod inspectme> herehere: 2019-07-02 00:00:00 UTC 

The api call on a field refresh correctly returns this: 
dialog_fields: {date_control_1: "07/02/2019", date_time_control_1: "07/02/2019 00:00"}
date_control_1: "07/02/2019"
date_time_control_1: "07/02/2019 00:00"


Assigning to Harpreet.

Comment 11 drew uhlmann 2019-07-09 14:19:00 UTC
Although, I think this ticket should be verified, since the issue was fixed, it's just that we also have a different issue which requires a different ticket.

Comment 12 Niyaz Akhtar Ansari 2019-07-11 06:43:51 UTC
I have rasied as a different issue https://bugzilla.redhat.com/show_bug.cgi?id=1728964

Comment 13 Niyaz Akhtar Ansari 2019-07-11 06:44:36 UTC
Verified in Version 5.11.0.13.20190705140324_b74c283

Comment 15 errata-xmlrpc 2019-12-12 13:36:02 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-2019:4199


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