[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [11964] property: Add one-to-many relation on documen
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [11964] property: Add one-to-many relation on documents |
Date: |
Mon, 12 May 2014 13:02:59 +0000 |
Revision: 11964
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=11964
Author: sigurdne
Date: 2014-05-12 13:02:59 +0000 (Mon, 12 May 2014)
Log Message:
-----------
property: Add one-to-many relation on documents
Modified Paths:
--------------
trunk/property/setup/setup.inc.php
trunk/property/setup/tables_current.inc.php
trunk/property/setup/tables_update.inc.php
Modified: trunk/property/setup/setup.inc.php
===================================================================
--- trunk/property/setup/setup.inc.php 2014-05-12 09:21:59 UTC (rev 11963)
+++ trunk/property/setup/setup.inc.php 2014-05-12 13:02:59 UTC (rev 11964)
@@ -168,6 +168,7 @@
'fm_event_receipt',
'fm_idgenerator',
'fm_document',
+ 'fm_document_relation',
'fm_document_history',
'fm_document_status',
'fm_standard_unit',
Modified: trunk/property/setup/tables_current.inc.php
===================================================================
--- trunk/property/setup/tables_current.inc.php 2014-05-12 09:21:59 UTC (rev
11963)
+++ trunk/property/setup/tables_current.inc.php 2014-05-12 13:02:59 UTC (rev
11964)
@@ -1725,6 +1725,19 @@
'ix' => array('location_code'),
'uc' => array()
),
+ 'fm_document_relation' => array(
+ 'fd' => array(
+ 'id' => array('type' => 'auto','precision' =>
'4','nullable' => False),
+ 'document_id' => array('type' =>
'int','precision' => '4','nullable' => True),
+ 'location_id' => array('type' =>
'int','precision' => '4','nullable' => True),
+ 'location_item_id' => array('type' =>
'int','precision' => '4','nullable' => True),
+ 'entry_date' => array('type' =>
'int','precision' => '4','nullable' => True),
+ ),
+ 'pk' => array('id'),
+ 'fk' => array('fm_document' => array('document_id' =>
'id')),
+ 'ix' => array(),
+ 'uc' => array()
+ ),
'fm_document_status' => array(
'fd' => array(
'id' => array('type' => 'varchar','precision'
=> '20','nullable' => False),
Modified: trunk/property/setup/tables_update.inc.php
===================================================================
--- trunk/property/setup/tables_update.inc.php 2014-05-12 09:21:59 UTC (rev
11963)
+++ trunk/property/setup/tables_update.inc.php 2014-05-12 13:02:59 UTC (rev
11964)
@@ -8032,3 +8032,35 @@
}
}
+
+ /**
+ * Update property version from 0.9.17.681 to 0.9.17.682
+ * Add one-to-many relation on documents
+ */
+ $test[] = '0.9.17.681';
+ function property_upgrade0_9_17_681()
+ {
+ $GLOBALS['phpgw_setup']->oProc->m_odb->transaction_begin();
+
+ $GLOBALS['phpgw_setup']->oProc->CreateTable(
+ 'fm_document_relation', array(
+ 'fd' => array(
+ 'id' => array('type' =>
'auto','precision' => '4','nullable' => False),
+ 'document_id' => array('type' =>
'int','precision' => '4','nullable' => True),
+ 'location_id' => array('type' =>
'int','precision' => '4','nullable' => True),
+ 'location_item_id' => array('type' =>
'int','precision' => '4','nullable' => True),
+ 'entry_date' => array('type' =>
'int','precision' => '4','nullable' => True),
+ ),
+ 'pk' => array('id'),
+ 'fk' => array('fm_document' =>
array('document_id' => 'id')),
+ 'ix' => array(),
+ 'uc' => array()
+ )
+ );
+
+ if($GLOBALS['phpgw_setup']->oProc->m_odb->transaction_commit())
+ {
+ $GLOBALS['setup_info']['property']['currentver'] =
'0.9.17.682';
+ return $GLOBALS['setup_info']['property']['currentver'];
+ }
+ }
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [11964] property: Add one-to-many relation on documents,
Sigurd Nes <=