Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0030459Openbravo ERPA. Platformpublic2015-07-30 10:522015-08-20 23:16
caristu 
caristu 
highminoralways
closedfixed 
5
 
3.0PR15Q43.0PR15Q4 
alostale
Core
No
0030459: Not possible to configure properly a modulescript to be executed twice or more times during install.source
Currently is not possible to configure a modulescript to be executed twice or more times during install.source with the functionalities added in [1].

For example, if we want to execute a modulescript added in Q3 on install.source and also in Q4, this can't be configured because the executeOnInstall() does not takes into account this case (it just take this into account when updating update.database and update.database.mod tasks)


[1] https://issues.openbravo.com/view.php?id=30286 [^]
In description
Adapt the usage of the executeOnInstall() to work with the install.source task also.
No tags attached.
related to feature request 0030286 closed caristu Add ability to determine if modulescripts should be executed depending on a particular module version 
Issue History
2015-07-30 10:52caristuNew Issue
2015-07-30 10:52caristuAssigned To => caristu
2015-07-30 10:52caristuModules => Core
2015-07-30 10:52caristuTriggers an Emergency Pack => No
2015-07-30 10:53caristuRelationship addedrelated to 0030286
2015-07-30 11:01hgbotCheckin
2015-07-30 11:01hgbotNote Added: 0079122
2015-07-30 11:08caristuReview Assigned To => alostale
2015-07-30 11:08caristuIssue Monitored: alostale
2015-07-30 11:09hgbotCheckin
2015-07-30 11:09hgbotNote Added: 0079124
2015-07-30 11:09hgbotStatusnew => resolved
2015-07-30 11:09hgbotResolutionopen => fixed
2015-07-30 11:09hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/142f0dbc4bc3cd1e7d9fc29ab8afe03fe94cc062 [^]
2015-07-30 11:14caristuNote Added: 0079125
2015-08-06 08:29alostaleNote Added: 0079209
2015-08-06 08:29alostaleStatusresolved => closed
2015-08-06 08:29alostaleFixed in Version => 3.0PR15Q4
2015-08-20 23:16hudsonbotCheckin
2015-08-20 23:16hudsonbotNote Added: 0079512

Notes
(0079122)
hgbot   
2015-07-30 11:01   
Repository: erp/devel/dbsm-main
Changeset: fae93badab51636857c16b36a36f1d9be2ff303d
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Thu Jul 30 10:59:34 2015 +0200
URL: http://code.openbravo.com/erp/devel/dbsm-main/rev/fae93badab51636857c16b36a36f1d9be2ff303d [^]

Related to issue 30459: Not send versions on install.source in DBSourceManager

---
M src/org/openbravo/ddlutils/task/ImportSampledata.java
---
(0079124)
hgbot   
2015-07-30 11:09   
Repository: erp/devel/pi
Changeset: 142f0dbc4bc3cd1e7d9fc29ab8afe03fe94cc062
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Thu Jul 30 11:07:20 2015 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/142f0dbc4bc3cd1e7d9fc29ab8afe03fe94cc062 [^]

fixes issue 30459: can execute modulescripts twice or more on install.source

It was not possible to configure modulescripts to be executed more than once during install.source of different versions. Now we send an empty hash map during install.source to the ModuleScriptHandler. This way we identify that we are executing the install.source task. Thus, in this case we will execute the modulescript depending on the value returned by its executeOnInstall() method

---
M src-core/src/org/openbravo/modulescript/ModuleScript.java
M src-db/database/lib/dbsourcemanager.jar
---
(0079125)
caristu   
2015-07-30 11:14   
The documentation has been updated properly: http://wiki.openbravo.com/wiki/How_to_create_build_validations_and_module_scripts#Execute_on_install [^]
(0079209)
alostale   
2015-08-06 08:29   
code reviewed + tested: now install.source considers modules as being installed
(0079512)
hudsonbot   
2015-08-20 23:16   
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/8c91718397a5 [^]
Maturity status: Test