[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [15062] Syncromind: Merge 14936:15027 from trunk
From: |
sigurdne |
Subject: |
[Fmsystem-commits] [15062] Syncromind: Merge 14936:15027 from trunk |
Date: |
Fri, 13 May 2016 12:05:50 +0000 (UTC) |
Revision: 15062
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=15062
Author: sigurdne
Date: 2016-05-13 12:05:50 +0000 (Fri, 13 May 2016)
Log Message:
-----------
Syncromind: Merge 14936:15027 from trunk
Modified Paths:
--------------
branches/dev-syncromind-2/phpgwapi/setup/tables_update.inc.php
Modified: branches/dev-syncromind-2/phpgwapi/setup/tables_update.inc.php
===================================================================
--- branches/dev-syncromind-2/phpgwapi/setup/tables_update.inc.php
2016-05-13 12:05:47 UTC (rev 15061)
+++ branches/dev-syncromind-2/phpgwapi/setup/tables_update.inc.php
2016-05-13 12:05:50 UTC (rev 15062)
@@ -3359,3 +3359,42 @@
return $GLOBALS['setup_info']['phpgwapi']['currentver'];
}
}
+
+ $test[] = '0.9.17.550';
+ /**
+ * Add table for file relation to multiple items
+ * @return string the new version number
+ */
+ function phpgwapi_upgrade0_9_17_550()
+ {
+ $GLOBALS['phpgw_setup']->oProc->m_odb->transaction_begin();
+
+ $metadata =
$GLOBALS['phpgw_setup']->oProc->m_odb->metadata('phpgw_vfs_filedata');
+ if(isset($metadata['location_id']))
+ {
+
$GLOBALS['phpgw_setup']->oProc->DropColumn('phpgw_vfs_filedata',null,'location_id');
+
$GLOBALS['phpgw_setup']->oProc->DropColumn('phpgw_vfs_filedata',null,'metadata');
+
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_vfs_filedata', 'metadata',
array(
+ 'type' => 'jsonb',
+ 'nullable' => true
+ )
+ );
+
+ $GLOBALS['phpgw_setup']->oProc->query("CREATE SEQUENCE
public.seq_phpgw_vfs_file_relation"
+ . " INCREMENT 1"
+ . " MINVALUE 1"
+ . " MAXVALUE 9223372036854775807"
+ . " START 1"
+ . " CACHE 1",__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->query("ALTER TABLE
public.phpgw_vfs_file_relation"
+ . " ALTER COLUMN relation_id SET DEFAULT
nextval('seq_phpgw_vfs_file_relation'::regclass)",__LINE__,__FILE__);
+
+ }
+
+ if($GLOBALS['phpgw_setup']->oProc->m_odb->transaction_commit())
+ {
+ $GLOBALS['setup_info']['phpgwapi']['currentver'] =
'0.9.17.551';
+ return $GLOBALS['setup_info']['phpgwapi']['currentver'];
+ }
+ }
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [15062] Syncromind: Merge 14936:15027 from trunk,
sigurdne <=