Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0024577Openbravo ERPB. User interfacepublic2013-08-25 00:442015-02-04 20:33
johnfandl 
AugustoMauch 
immediatemajoralways
closedfixed 
5
 
3.0PR15Q2 
alostale
Core
No
0024577: "Direct link url which contains explicit criteria" does not work in case of "implicit filter" or "default view" on the window
This is follow up to 23333, which is mostly fixed, thanks!

The remaining defect is that in the case of an implicit filter defined on the window (for examples Sales Orers), a "direct link url which contains explicit criteria" still does not work. The same is true if a default view exists.

From the user perspective, a "direct link url which contains EXPLICIT criteria" must always override an "implicit filter" or "default view". Otherwise, sharing is not consistent--I email the same link to 2 people and it works for the first guy, but not the second guy (who happens to have a default view defined). This is clearly not the intended behavior, and is a bug.
For example, I want to share with someone a link to "All Sales Orders for Sleep Well Hotels, Co.". So I do this:

1. Access Sales Orders
2. Notice there is an implicit filter, so click funnel icon to clear it
3. Filter to Sleep Well Hotels, Co.
4. Click the Direct Link button and copy the link which is

http://localhost/openbravo/?tabId=186&criteria=%7B%22operator%22%3A%22and%22%2C%22_constructor%22%3A%22AdvancedCriteria%22%2C%22criteria%22%3A%5B%7B%22fieldName%22%3A%22businessPartner%24_identifier%22%2C%22operator%22%3A%22iContains%22%2C%22value%22%3A%22Sleep%20Well%20Hotels%2C%20Co.%22%2C%22_constructor%22%3A%22AdvancedCriteria%22%7D%5D%7D [^]


5. Close the Sales Order Tab
6. Paste above link in Quicklaunch. Alternatively, paste the URL in the browser URL bar.
7. Expect to see Sales Orders for Sleep Well Hotels, Co. Instead, the implicit filter has again been applied and my filter criterion is ignored.

Follow similiar steps on Product Window (no implicit filter), just define a default view. Notice that the default view is used instead of the explicit filter criteria on the url, when you paste the URL in QuickLaunch. However, note that it does work correctly in this case if you paste the URL in the browser URL bar!
When a url is parsed and is found to contain explicit filter criteria, that filter criteria must always override any explicit filter or default view. In this case, if a default view exists for the user, the Standard View should simply be used instead.
No tags attached.
related to defect 0023333 closed shankarb Direct link to view does not work when a filter is active 
related to defect 00273033.0PR14Q4 closed AugustoMauch direct link filtered by FK column doesn't work 
related to defect 0028471 acknowledged platform inhomogenous behavior between when removing filters using icon and keyboard shortcut 
related to defect 0028499 closed AugustoMauch Opening a link using the QuickView does not fetch properly the link parameters 
? issue24577.export (3,393) 2014-12-29 18:42
https://issues.openbravo.com/file_download.php?file_id=7645&type=bug
Issue History
2013-08-25 00:44johnfandlNew Issue
2013-08-25 00:44johnfandlAssigned To => dbaz
2013-08-25 00:44johnfandlModules => Core
2013-08-25 00:44johnfandlTriggers an Emergency Pack => No
2013-08-25 05:07dbazAssigned Todbaz => AugustoMauch
2013-08-26 07:24shankarbAssigned ToAugustoMauch => shankarb
2013-08-26 07:25shankarbRelationship addedrelated to 0023333
2014-09-03 08:14shankarbAssigned Toshankarb => AugustoMauch
2014-12-29 12:49jonalegriaesartePrioritynormal => immediate
2014-12-29 13:01AugustoMauchRelationship addedrelated to 0027303
2014-12-29 13:01AugustoMauchRelationship addedrelated to 0028471
2014-12-29 17:15AugustoMauchRelationship addedrelated to 0028499
2014-12-29 18:42AugustoMauchFile Added: issue24577.export
2014-12-29 18:42AugustoMauchNote Added: 0072860
2014-12-29 18:42AugustoMauchStatusnew => scheduled
2014-12-29 18:42AugustoMauchfix_in_branch => pi
2015-01-05 13:38AugustoMauchIssue Monitored: alostale
2015-01-05 13:39AugustoMauchReview Assigned To => alostale
2015-01-05 13:39AugustoMauchfix_in_branchpi =>
2015-01-05 16:03hgbotCheckin
2015-01-05 16:03hgbotNote Added: 0073309
2015-01-05 16:03hgbotStatusscheduled => resolved
2015-01-05 16:03hgbotResolutionopen => fixed
2015-01-05 16:03hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/675fc7b4fbac501edbdf942b6700a153e98d1582 [^]
2015-01-08 11:45alostaleNote Added: 0073350
2015-01-08 11:45alostaleStatusresolved => closed
2015-01-08 11:45alostaleFixed in Version => 3.0PR15Q2
2015-02-04 20:33hudsonbotCheckin
2015-02-04 20:33hudsonbotNote Added: 0074108

Notes
(0072860)
AugustoMauch   
2014-12-29 18:42   
A fix has been attached to the issue. It will not be pushed to pi until it is open for changesets targeting PR15Q2.
(0073309)
hgbot   
2015-01-05 16:03   
Repository: erp/devel/pi
Changeset: 675fc7b4fbac501edbdf942b6700a153e98d1582
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Mon Dec 29 18:34:58 2014 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/675fc7b4fbac501edbdf942b6700a153e98d1582 [^]

Fixes issue 24577: Direct link works properly in grids with implicit filters

When a view was open by pasting a URL link (either in the address bar or in the quick view), the implicit filter of the header grid was always applied, even if the filters had been clea
red before obtaining the link.

This has been fixed by storing in the URL info about the grid filter clause state when the link is obtained. Then, when opening a view from that link, if there were no filter clauses wh
en the link was obtained, the grid will be initialized without them.

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-view-grid.js
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/main/ob-standard-view.js
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/utilities/ob-utilities.js
---
(0073350)
alostale   
2015-01-08 11:45   
code reviewed

tested:

In all cases applying link both in URL and quick launch.

1.1 Open Sales Order window
1.2 With implicit filter get link
-> implicit filter remains when link is opened

2.1 Open Sales Order window
2.2 Filter BP Alimentos y Supermercados (keeping implicit filter) and get link
-> implicit filter remains when link is opened and BP is properly filtered

3.1 Open Sales Order window
3.2 Clear implicit filter and get link
-> no filter is applied when link is opened

4.1 Open Sales Order window
4.2 Clear implicit filter
4.3 Filter BP Alimentos y Supermercados (keeping implicit filter) and get link
-> no implicit filter is applied and BP is correctly filtered when link is opened
(0074108)
hudsonbot   
2015-02-04 20:33   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/f36c91d0ad63 [^]
Maturity status: Test