Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Issue DetailsJump to Notes ] Issue History ] Print ]
ID
0037451
TypeCategorySeverityReproducibilityDate SubmittedLast Update
defect[Openbravo ERP] A. Platformmajoralways2017-12-11 16:052018-02-22 18:19
Reportersamuel_nicuesaView Statuspublic 
Assigned ToAugustoMauch 
PriorityhighResolutionfixedFixed in Version3.0PR18Q2
StatusclosedFix in branchFixed in SCM revision8725b521c897
ProjectionnoneETAnoneTarget Version
OSAnyDatabaseAnyJava version
OS VersionDatabase versionAnt version
Product VersionSCM revision 
Review Assigned Tocaristu
Web browser
ModulesCore
Regression level
Regression date
Regression introduced in release
Regression introduced by commit
Triggers an Emergency PackNo
Summary

0037451: Adaptive filtering is not applying the Country.Language filter properly

DescriptionLanguage filter is not working properly when there are other filters applied.
In this case we are using currency and language fields to apply the filter.
Steps To ReproduceLogin in the ERP using F&B International group admin role.
- Open country and region window.
- Select AED in currency filter. Only one country uses that currency. The result fit in the first page, so if more filters are applied, adaptive filtering will be used.
- Select Arabic in language filter. It shows the message "The applied filter resulted in 0 result" but there is actually one record to show. This is wrong.
- Click on the Refresh toolbar button to force the criteria to be evaluated on the back end. It will return one record as expected.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]
duplicate of defect 0037097 closedplatform Adaptive Filter by ID not working properly with table references using a not ID column as key column 
has duplicate defect 0037452 closedplatform Language filter is not working properly when there are few records on the grid. 

-  Notes
(0102226)
hgbot (developer)
2018-02-06 19:19

Repository: erp/devel/pi
Changeset: 8725b521c897ab3b2ae18bd09adeefadc7c993c1
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Tue Feb 06 19:08:50 2018 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/8725b521c897ab3b2ae18bd09adeefadc7c993c1 [^]

Fixes issue 37451: Fixes filtering of fks that dont use ids as key

The problem was that the foreign keys that did not use and id column as key (i.e. ad_country.ad_language) were not being properly
filtered locally in smartclient, because the criteria used the id of the referenced record, that was not available in the browser (it
was available in the query done in the back end, that is why only the client-side filtering was not working).

For instance, if the ad_language foreign key reference uses as key ad_language.ad_language instead of ad_language.ad_language_id, the criteria
will no longer be:

{
  fieldName: 'language',
  operator: 'equals',
  value: '192'
}

Now it will be:

{
  fieldName: 'language',
  operator: 'equals',
  value: 'en_US'
}

The AdvancedQueryBuilder has been adapted to support the new type of criteria.

There are also changes on ob-grid.js and ob-formitem-fk-filter to ensure that the criteria is properly displayed in the filter input.

---
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/form/formitem/ob-formitem-fk-filter.js
M modules/org.openbravo.client.application/web/org.openbravo.client.application/js/grid/ob-grid.js
M modules/org.openbravo.client.kernel/src/org/openbravo/client/kernel/reference/ForeignKeyUIDefinition.java
M modules/org.openbravo.service.json/src/org/openbravo/service/json/AdvancedQueryBuilder.java
---
(0102227)
hgbot (developer)
2018-02-06 19:19

Repository: erp/devel/pi
Changeset: e15a97093931f2d1d52e7225643a63db53baef79
Author: Augusto Mauch <augusto.mauch <at> openbravo.com>
Date: Tue Feb 06 19:10:21 2018 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/e15a97093931f2d1d52e7225643a63db53baef79 [^]

Related with issue 37451: Adds tests

Tests have been added to check that the datasource returns properly the results using the updated criteria.

Selenium tests with the current infrastructure are not possible, since when they filter the grid, they do not
select the checkboxes of the foreign key combo boxes, they just enter the text in the filter input, and if done
that way the issue is not reproducible.

---
M src-test/src/org/openbravo/test/AllWebserviceTests.java
A src-test/src/org/openbravo/test/datasource/NonIdForeignKeyFilters.java
---
(0102334)
caristu (developer)
2018-02-12 14:19

Code reviewed + tested OK.
(0102725)
hudsonbot (developer)
2018-02-22 18:19

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/980a6ad5bbf5 [^]
Maturity status: Test
(0102726)
hudsonbot (developer)
2018-02-22 18:19

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/980a6ad5bbf5 [^]
Maturity status: Test

- Issue History
Date Modified Username Field Change
2017-12-11 16:05 samuel_nicuesa New Issue
2017-12-11 16:05 samuel_nicuesa Assigned To => platform
2017-12-11 16:05 samuel_nicuesa Modules => Core
2017-12-11 16:05 samuel_nicuesa Resolution time => 1514761200
2017-12-11 16:05 samuel_nicuesa Triggers an Emergency Pack => No
2017-12-11 16:21 samuel_nicuesa Relationship added related to 0037452
2017-12-12 10:14 inigosanchez Status new => scheduled
2017-12-12 10:14 inigosanchez Assigned To platform => inigosanchez
2018-02-01 19:54 inigosanchez Assigned To inigosanchez => platform
2018-02-01 19:54 inigosanchez Status scheduled => acknowledged
2018-02-05 09:42 AugustoMauch Assigned To platform => AugustoMauch
2018-02-05 09:51 AugustoMauch Summary Language filter is not working properly when there are other filters applied. => Adaptive filtering is not applying the Country.Language filter properly
2018-02-05 09:51 AugustoMauch Steps to Reproduce Updated View Revisions
2018-02-05 09:51 AugustoMauch Status acknowledged => scheduled
2018-02-06 19:10 AugustoMauch Review Assigned To => caristu
2018-02-06 19:19 hgbot Checkin
2018-02-06 19:19 hgbot Note Added: 0102226
2018-02-06 19:19 hgbot Status scheduled => resolved
2018-02-06 19:19 hgbot Resolution open => fixed
2018-02-06 19:19 hgbot Fixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/8725b521c897ab3b2ae18bd09adeefadc7c993c1 [^]
2018-02-06 19:19 hgbot Checkin
2018-02-06 19:19 hgbot Note Added: 0102227
2018-02-07 13:03 AugustoMauch Relationship replaced has duplicate 0037452
2018-02-07 14:12 caristu Relationship added duplicate of 0037097
2018-02-12 14:19 caristu Note Added: 0102334
2018-02-12 14:19 caristu Status resolved => closed
2018-02-12 14:19 caristu Fixed in Version => 3.0PR18Q2
2018-02-22 18:19 hudsonbot Checkin
2018-02-22 18:19 hudsonbot Note Added: 0102725
2018-02-22 18:19 hudsonbot Checkin
2018-02-22 18:19 hudsonbot Note Added: 0102726


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker