Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0035489Openbravo ERPE. Translationpublic2017-03-10 21:162017-03-17 10:38
rbianchini 
inigosanchez 
normalmajoralways
closedfixed 
5
3.0PR16Q3.2 
3.0PR17Q2 
alostale
Core
No
0035489: Wrong priority between different possible translations
When you have an especific translation for a static text in a repport (registered in ad_textinterfaces with the filename column pointing to the repport) and there is a general translation for the same static text, the query that returns the possible translations prioritizes the general translation over the specific translation
1 - Install the Localization pack Spain (EspaƱa) - 3.5.0 - English (USA) Module
2 - Install org.openbravo.bugTraslation module (attached)
3 - Execute the following update query in database:
       update ad_textinterfaces_trl set text = 'Nombre2', istranslated='Y' where ad_textinterfaces_id in (select ti.ad_textinterfaces_id from ad_textinterfaces ti where filename='/org/openbravo/bugTranslation/ad_reports/EXAM_example2.jrxml' and text='Name');
4 - Log in ERP and select Spanish language
5 - open product list menu entry and click "aceptar" button
6 - Open the created report and realizes that the column "Nombre" should be "Nombre2"
Edit the query in file TextInterfacesData.java, function selectText(ConnectionProvider connectionProvider, String htmlFile, String language) and prioritizes the first select in the union
No tags attached.
? org.openbravo.bugTranslation-1.0.0.obx (13,850) 2017-03-10 21:16
https://issues.openbravo.com/file_download.php?file_id=10554&type=bug
Issue History
2017-03-10 21:16rbianchiniNew Issue
2017-03-10 21:16rbianchiniAssigned To => platform
2017-03-10 21:16rbianchiniFile Added: org.openbravo.bugTranslation-1.0.0.obx
2017-03-10 21:16rbianchiniModules => Core
2017-03-10 21:16rbianchiniResolution time => 1490929200
2017-03-10 21:16rbianchiniTriggers an Emergency Pack => No
2017-03-13 09:39inigosanchezAssigned Toplatform => inigosanchez
2017-03-13 13:45inigosanchezStatusnew => scheduled
2017-03-14 13:02hgbotCheckin
2017-03-14 13:02hgbotNote Added: 0094997
2017-03-14 13:02hgbotStatusscheduled => resolved
2017-03-14 13:02hgbotResolutionopen => fixed
2017-03-14 13:02hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/e625fac3bb60025cd96988dfbf76f48e457a11d6 [^]
2017-03-14 13:03inigosanchezReview Assigned To => alostale
2017-03-14 13:03inigosanchezResolution time1490929200 => 1490911200
2017-03-15 20:22hudsonbotCheckin
2017-03-15 20:22hudsonbotNote Added: 0095298
2017-03-17 10:38alostaleNote Added: 0095359
2017-03-17 10:38alostaleStatusresolved => closed
2017-03-17 10:38alostaleFixed in Version => 3.0PR17Q2

Notes
(0094997)
hgbot   
2017-03-14 13:02   
Repository: erp/devel/pi
Changeset: e625fac3bb60025cd96988dfbf76f48e457a11d6
Author: Inigo Sanchez <inigo.sanchez <at> openbravo.com>
Date: Mon Mar 13 14:22:51 2017 +0100
URL: http://code.openbravo.com/erp/devel/pi/rev/e625fac3bb60025cd96988dfbf76f48e457a11d6 [^]

Fixed issue 35489: Wrong priority between different possible translations

The problem was when you have an especific translation for a static text in a report (registered
in ad_textinterfaces with the filename column pointing to the repport) and there was a general
translation for the same static text. In this situation, the query that returns the possible
translations prioritizes the general translation over the specific translation.

The problem has been fixed by edit the query and prioritizes a especific translation for a static
text in a report instead of the general translation. Besides it have been removed some unnecessary
lines of code.

---
M src-core/src/org/openbravo/uiTranslation/TextInterfacesData.java
---
(0095298)
hudsonbot   
2017-03-15 20:22   
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/54e102bef53e [^]
Maturity status: Test
(0095359)
alostale   
2017-03-17 10:38   
code reviewed + tested