-
Type:
Bug
-
Status: Closed
-
Resolution: Fixed
-
Affects Version/s: 6.2.10 EE GA1, 6.2.X EE, 7.0.0 M3
-
Fix Version/s: 6.2.4 CE GA5, 6.2.X EE, 7.0.0 M5
-
Component/s: Legacy, Legacy > Administration UI
-
Labels:
-
Branch Version/s:6.2.x
-
Backported to Branch:Committed
-
Story Points:12
-
Fix Priority:4
-
Git Pull Request:
The specific bug causes two different behaviors.
Reproduction steps:
- Start the server.
- Go to actual user's "My Account" panel and set timezone property to a time zone one hour later in the future in relation to the browser's time zone.
- For example, if your browser's time zone offset at the moment is UTC+2, your user's time zone should have offset of UTC+3 at the moment.
- One of the combinations we use was Europe/Lisbon for browser's time and Europe/Madrid for user's time.
- Pay attention to daylight saving times - if they are in effect in one of the time zones, the difference between the time zones can be different than 1 hour.
- Go to Admin/Pages, Export, Choose Content, Change Date Range. In the popup window choose date Range.
- Set the start date to today then set the start time to one hour before the end time.
- Click in "Ok"
Expected results
- The operation would be accepted.
Actual results
- "End date must be greater than start date." message will be shown on ui despite starTime lower that endTime.
This error is caused by validating dates without time-zone information.
Reproduction steps:
With the same setup above
- Close popup if it is opened and reload SitePages.
- Go to Export/Choose Content and click on Change in Date Range section.
- If you modify endDate only for example: if startDate is 10/01/2014 03:58 PM then modify endDate to 10/01/2014 03:00 PM and the actual time is 02:58 PM.
- Click on OK button.
Expected results
- The "End date must be greater than start date" should appear
Actual results
- In this case you will get the following exception:
16:01:10,528 ERROR [http-bio-8080-exec-9][IncludeTag:129] Current URL /group/control_panel/manage?p_auth=yyW8KRRO&p_p_auth=uw
05dagu&p_p_id=156&p_p_lifecycle=1&p_p_state=maximized&p_p_mode=view&doAsGroupId=10182&refererPlid=10185&controlPanelCategory=
current_site.pages&_156_exportLAR=true&_156_struts_action=%2Fgroup_pages%2Fexport_layouts generates exception: com.liferay.po
rtal.kernel.lar.PortletDataException
com.liferay.portal.kernel.lar.PortletDataException
at com.liferay.portal.lar.PortletDataContextFactoryImpl.validateDateRange(PortletDataContextFactoryImpl.java:257)
at com.liferay.portal.lar.PortletDataContextFactoryImpl.createPreparePortletDataContext(PortletDataContextFactoryImpl
.java:139)
at com.liferay.portal.kernel.lar.PortletDataContextFactoryUtil.createPreparePortletDataContext(PortletDataContextFact
oryUtil.java:62)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at com.liferay.portal.servlet.DirectRequestDispatcher.include(DirectRequestDispatcher.java:57)
at com.liferay.portal.servlet.ClassLoaderRequestDispatcherWrapper.doDispatch(ClassLoaderRequestDispatcherWrapper.java
:78)
at com.liferay.portal.servlet.ClassLoaderRequestDispatcherWrapper.include(ClassLoaderRequestDispatcherWrapper.java:53
)
at com.liferay.taglib.util.IncludeTag.include(IncludeTag.java:312)
at com.liferay.taglib.util.IncludeTag.doInclude(IncludeTag.java:193)
at com.liferay.taglib.util.IncludeTag.doEndTag(IncludeTag.java:84)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:728)
at com.liferay.portal.servlet.DirectRequestDispatcher.include(DirectRequestDispatcher.java:57)
at com.liferay.portal.servlet.ClassLoaderRequestDispatcherWrapper.doDispatch(ClassLoaderRequestDispatcherWrapper.java
:78)
at com.liferay.portal.servlet.ClassLoaderRequestDispatcherWrapper.include(ClassLoaderRequestDispatcherWrapper.java:53
)
at com.liferay.taglib.util.IncludeTag.include(IncludeTag.java:312)
at com.liferay.taglib.util.IncludeTag.doInclude(IncludeTag.java:193)
at com.liferay.taglib.util.IncludeTag.doEndTag(IncludeTag.java:84)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
Keep in mind that this issue is depends on browser's actual date and timezone and user's timezone.