← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 17097: Fixed duplicate constraint/foreign key names

 

------------------------------------------------------------
revno: 17097
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2014-10-14 08:43:28 +0200
message:
  Fixed duplicate constraint/foreign key names
modified:
  dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml
  dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/interpretation/hibernate/InterpretationComment.hbm.xml
  dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/reporttable/hibernate/ReportTable.hbm.xml
  dhis-2/dhis-services/dhis-service-reporting/src/test/java/org/hisp/dhis/chart/ChartStoreTest.java
  dhis-2/dhis-services/dhis-service-tracker/src/main/resources/org/hisp/dhis/eventchart/EventChart.hbm.xml


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml	2014-10-08 21:49:29 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/chart/hibernate/Chart.hbm.xml	2014-10-14 06:43:28 +0000
@@ -101,7 +101,7 @@
     </list>
 
     <many-to-one name="relatives" unique="true" class="org.hisp.dhis.period.RelativePeriods" column="relativeperiodsid"
-      cascade="all-delete-orphan" foreign-key="fk_report_relativeperiodsid" />
+      cascade="all-delete-orphan" foreign-key="fk_chart_relativeperiodsid" />
 
     <list name="categoryDimensions" table="chart_categorydimensions" cascade="all-delete-orphan">
       <cache usage="read-write" />

=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/interpretation/hibernate/InterpretationComment.hbm.xml'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/interpretation/hibernate/InterpretationComment.hbm.xml	2013-08-29 18:09:46 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/interpretation/hibernate/InterpretationComment.hbm.xml	2014-10-14 06:43:28 +0000
@@ -16,7 +16,7 @@
     <property name="text" column="commenttext" type="text" />
 
     <many-to-one name="user" class="org.hisp.dhis.user.User" column="userid"
-		foreign-key="fk_interpretation_userid" not-null="true" />
+		foreign-key="fk_interpretationcomment_userid" not-null="true" />
 		
 	<property name="created" not-null="true" type="timestamp" />
 

=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/reporttable/hibernate/ReportTable.hbm.xml'
--- dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/reporttable/hibernate/ReportTable.hbm.xml	2014-10-07 10:08:29 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/main/resources/org/hisp/dhis/reporttable/hibernate/ReportTable.hbm.xml	2014-10-14 06:43:28 +0000
@@ -70,7 +70,7 @@
     </list>
 
     <many-to-one name="relatives" unique="true" class="org.hisp.dhis.period.RelativePeriods" column="relativeperiodsid"
-      cascade="all-delete-orphan" foreign-key="fk_report_relativeperiodsid" />
+      cascade="all-delete-orphan" foreign-key="fk_reporttable_relativeperiodsid" />
 
     <list name="categoryDimensions" table="reporttable_categorydimensions" cascade="all-delete-orphan">
       <cache usage="read-write" />

=== modified file 'dhis-2/dhis-services/dhis-service-reporting/src/test/java/org/hisp/dhis/chart/ChartStoreTest.java'
--- dhis-2/dhis-services/dhis-service-reporting/src/test/java/org/hisp/dhis/chart/ChartStoreTest.java	2014-10-07 13:46:29 +0000
+++ dhis-2/dhis-services/dhis-service-reporting/src/test/java/org/hisp/dhis/chart/ChartStoreTest.java	2014-10-14 06:43:28 +0000
@@ -169,7 +169,7 @@
         assertEquals( chartC, chartStore.get( idC ) );
 
         assertTrue( equals( chartStore.get( idA ).getIndicators(), indicatorA, indicatorB, indicatorC ) );
-        //assertTrue( equals( chartStore.get( idA ).getOrganisationUnits(), unitA, unitB, unitC ) );
+        assertTrue( equals( chartStore.get( idA ).getOrganisationUnits(), unitA, unitB ) );
         assertTrue( equals( chartStore.get( idA ).getOrganisationUnits(), unitA, unitB ) );
         assertTrue( equals( chartStore.get( idA ).getPeriods(), periodA, periodB, periodC ) );
     }

=== modified file 'dhis-2/dhis-services/dhis-service-tracker/src/main/resources/org/hisp/dhis/eventchart/EventChart.hbm.xml'
--- dhis-2/dhis-services/dhis-service-tracker/src/main/resources/org/hisp/dhis/eventchart/EventChart.hbm.xml	2014-10-09 07:58:13 +0000
+++ dhis-2/dhis-services/dhis-service-tracker/src/main/resources/org/hisp/dhis/eventchart/EventChart.hbm.xml	2014-10-14 06:43:28 +0000
@@ -34,7 +34,7 @@
     </list>
 
     <many-to-one name="relatives" unique="true" class="org.hisp.dhis.period.RelativePeriods" column="relativeperiodsid"
-      cascade="all-delete-orphan" foreign-key="fk_report_relativeperiodsid" />
+      cascade="all-delete-orphan" foreign-key="fk_eventchart_relativeperiodsid" />
 
     <list name="organisationUnitGroups" table="eventchart_orgunitgroups">
       <cache usage="read-write" />