Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0035430Openbravo ERPA. Platformpublic2017-03-06 08:482022-02-01 08:09
caristu 
Triage Platform Base 
highminorN/A
acknowledgedopen 
5
 
 
Core
No
0035430: Is not possible to define a valid criteria for a date using openDirectTab utility function
Is not possible to define a valid criteria for a date using openDirectTab utility function
1) Execute the following function using dev. console:

OB.Utilities.Action.execute("openDirectTab", { tabId: "263", newTabPosition: OB.MainView.TabSet.paneContainer.members.length, criteria: isc.JSON.encode ({_constructor: "AdvancedCriteria", operator: "and", criteria: [{
    fieldName: "invoiceDate", operator: "lessOrEqual", value: OB.Utilities.Date.OBToJS('01-01-2016', OB.Format.date)
}]})})

Note that it is defining a criteria for the "Invoice Date" field. But it is not being set properly: the filter text says "Before null"
The problem is that when invoking openDirectTab, it is only allowed to pass the criteria as a string, when the criteria is sent as string the date is then not recovered properly when applying it into the filter.
No tags attached.
Issue History
2017-03-06 08:48caristuNew Issue
2017-03-06 08:48caristuAssigned To => platform
2017-03-06 08:48caristuModules => Core
2017-03-06 08:48caristuTriggers an Emergency Pack => No
2017-04-07 08:51alostaleStatusnew => acknowledged
2017-04-07 08:51alostaleTypedefect => design defect
2022-02-01 08:09alostaleAssigned Toplatform => Triage Platform Base

There are no notes attached to this issue.