Remove code attribute from OrderElementTemplate entity and from DB.

FEA: ItEr76S26RemoveExternalCodeFromTemplates
This commit is contained in:
Jacobo Aragunde Pérez 2012-04-28 13:08:28 +02:00
parent 88bc3f3f77
commit 801ffc456e
4 changed files with 13 additions and 10 deletions

View file

@ -354,14 +354,6 @@ public abstract class OrderElementTemplate extends BaseEntity implements
this.deadlineAsDaysFromBeginning = days;
}
public String getCode() {
return getInfoComponent().getCode();
}
public void setCode(String code) {
getInfoComponent().setCode(code);
}
public String getDescription() {
return getInfoComponent().getDescription();
}
@ -384,7 +376,6 @@ public abstract class OrderElementTemplate extends BaseEntity implements
}
protected void copyTo(OrderElementTemplate result) {
result.setCode(getCode());
result.setName(getName());
result.setDescription(getDescription());
result.setDeadlineAsDaysFromBeginning(getDeadlineAsDaysFromBeginning());

View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd">
<changeSet id="remove-code-from-order_element_template" author="jaragunde">
<comment>Remove column code in order_element_template table</comment>
<dropColumn tableName="order_element_template" columnName="code" />
</changeSet>
</databaseChangeLog>

View file

@ -10,5 +10,6 @@
<include file="src/main/resources/db.changelog-1.0.xml"/>
<include file="src/main/resources/db.changelog-1.1.xml"/>
<include file="src/main/resources/db.changelog-1.2.xml"/>
<include file="src/main/resources/db.changelog-1.3.xml"/>
</databaseChangeLog>

View file

@ -12,7 +12,6 @@
<component name="infoComponent" class="org.libreplan.business.orders.entities.InfoComponent">
<property name="name" access="field" />
<property name="description" access="field" type="text" />
<property name="code" access="field"/>
</component>
<property name="startAsDaysFromBeginning"
column="start_as_days_from_beginning" />