Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0035760 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] 00. Application dictionary | major | always | 2017-04-12 00:18 | 2017-05-29 17:43 | |||
Reporter | letcharren | View Status | public | |||||
Assigned To | inigosanchez | |||||||
Priority | normal | Resolution | fixed | Fixed in Version | 3.0PR17Q3 | |||
Status | closed | Fix in branch | Fixed in SCM revision | 3d40af5ffd28 | ||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | 3.0PR17Q1 | SCM revision | ||||||
Merge Request Status | ||||||||
Review Assigned To | alostale | |||||||
OBNetwork customer | OBPS | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Support ticket | 46271 | |||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0035760: Can not create computed columns in ad_org or ad_client tables | |||||||
Description | Can not create computed columns in ad_org or ad_client tables. When you want to export the changes (generate.entities), the attached error is shown. | |||||||
Steps To Reproduce | 1- Create a computed column in table ad_org or in ad_client. 2- Create a field in the organization/client corresponding to the created column. 3- Execute "ant export.database" in order to export changes. 4- The attached error is displayed. | |||||||
Tags | No tags attached. | |||||||
Attached Files | ![]() | |||||||
![]() |
|
![]() |
|
(0096506) inigosanchez (viewer) 2017-05-10 12:27 |
Manual tests: 1º.- Normal case > Create computed column for Assets table + Field for the created computed column > ant export.database > Check that ./src-gen/org/openbravo/model/financialmgmt/assetmgmt/Asset_ComputedColumns.java is generated as expects (implements both interfaces). 2º.- Case Org > Create computed column for Organization table + Field for the created computed column > ant export.database > Check that ./src-gen/org/openbravo/model/common/enterprise/Organization_ComputedColumns.java is generated as expects (only implements ClientEnabled). 3º.- Case Client > Create computed column for Client table + Field for the created computed column > ant export.database > Check that ./src-gen/org/openbravo/model/ad/system/Client_ComputedColumns.java is generated as expects (only implements OrganizationEnabled). |
(0096546) hgbot (developer) 2017-05-12 10:14 |
Repository: erp/devel/pi Changeset: 3d40af5ffd2811557afcefb8791f3de9e9e6e1bc Author: Inigo Sanchez <inigo.sanchez <at> openbravo.com> Date: Fri May 12 10:13:57 2017 +0200 URL: http://code.openbravo.com/erp/devel/pi/rev/3d40af5ffd2811557afcefb8791f3de9e9e6e1bc [^] Fixed issue 35760:Can not create computed columns in ad_org or ad_client tables The problem was that it was not possible to create and export a computed column in ad_org and ad_client tables. This problem was because computed columns of organization entity should have not organization as a property and it should have not implement OrganizationEnabled. At the same time, computed columns of client entity should have not client as a property and it should have not implement ClientEnabled. In order to fix this problem two changes have been done: - Now generate entities task is take into account when a computed column is created for Organization or Client entities. Besides, when the computed column class is created, entityComputedColumns.ftl has the needed logic to decided if implements ClientEnabled, OrganizationEnabled or both. - When the Hibernate mapping for the tables and entities are created (DalMappingGenerator), generateComputedColumnsClassMapping method is take into account when the computed column is for Organization entity or Client entity. It is now possible to create a computed column in the ad_org and ad_client tables. --- M src/org/openbravo/base/gen/GenerateEntitiesTask.java M src/org/openbravo/base/gen/entityComputedColumns.ftl M src/org/openbravo/dal/core/DalMappingGenerator.java --- |
(0096591) hgbot (developer) 2017-05-15 13:17 |
Repository: erp/devel/pi Changeset: 658d65dc2006ea6c0c043694c7c2d76714b9183e Author: Asier Lostalé <asier.lostale <at> openbravo.com> Date: Mon May 15 13:17:01 2017 +0200 URL: http://code.openbravo.com/erp/devel/pi/rev/658d65dc2006ea6c0c043694c7c2d76714b9183e [^] related to bug 35760: can't create computed columns in ad_org or ad_client Be more specific when checking whether client/org property should be added to computed column mapping. --- M src/org/openbravo/dal/core/DalMappingGenerator.java --- |
(0096592) alostale (viewer) 2017-05-15 13:18 |
reviewed + tested |
(0096962) hudsonbot (viewer) 2017-05-29 17:43 |
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/1ee70113bdc4 [^] Maturity status: Test |
(0096967) hudsonbot (viewer) 2017-05-29 17:43 |
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/1ee70113bdc4 [^] Maturity status: Test |
![]() |
|||
Date Modified | Username | Field | Change |
2017-04-12 00:18 | letcharren | New Issue | |
2017-04-12 00:18 | letcharren | Assigned To | => platform |
2017-04-12 00:18 | letcharren | File Added: log | |
2017-04-12 00:18 | letcharren | OBNetwork customer | => No |
2017-04-12 00:18 | letcharren | Modules | => Core |
2017-04-12 00:18 | letcharren | Support ticket | => 46271 |
2017-04-12 00:18 | letcharren | Resolution time | => 1493676000 |
2017-04-12 00:18 | letcharren | Triggers an Emergency Pack | => No |
2017-04-24 12:36 | maite | OBNetwork customer | No => Yes |
2017-05-09 11:33 | inigosanchez | Assigned To | platform => inigosanchez |
2017-05-09 11:33 | inigosanchez | Status | new => acknowledged |
2017-05-10 12:27 | inigosanchez | Status | acknowledged => scheduled |
2017-05-10 12:27 | inigosanchez | Note Added: 0096506 | |
2017-05-10 12:30 | inigosanchez | Summary | Can not create computed columns in ad_org table => Can not create computed columns in ad_org or ad_client tables |
2017-05-10 12:30 | inigosanchez | Description Updated | View Revisions |
2017-05-10 12:30 | inigosanchez | Steps to Reproduce Updated | View Revisions |
2017-05-10 12:32 | inigosanchez | Review Assigned To | => alostale |
2017-05-12 10:14 | hgbot | Checkin | |
2017-05-12 10:14 | hgbot | Note Added: 0096546 | |
2017-05-12 10:14 | hgbot | Status | scheduled => resolved |
2017-05-12 10:14 | hgbot | Resolution | open => fixed |
2017-05-12 10:14 | hgbot | Fixed in SCM revision | => http://code.openbravo.com/erp/devel/pi/rev/3d40af5ffd2811557afcefb8791f3de9e9e6e1bc [^] |
2017-05-12 10:16 | inigosanchez | Fixed in Version | => 3.0PR17Q3 |
2017-05-15 13:17 | hgbot | Checkin | |
2017-05-15 13:17 | hgbot | Note Added: 0096591 | |
2017-05-15 13:18 | alostale | Note Added: 0096592 | |
2017-05-15 13:18 | alostale | Status | resolved => closed |
2017-05-29 17:43 | hudsonbot | Checkin | |
2017-05-29 17:43 | hudsonbot | Note Added: 0096962 | |
2017-05-29 17:43 | hudsonbot | Checkin | |
2017-05-29 17:43 | hudsonbot | Note Added: 0096967 |
Copyright © 2000 - 2009 MantisBT Group |