aboutsummaryrefslogtreecommitdiffstats
path: root/install
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2014-08-26 20:51:59 -0700
committerfriendica <info@friendica.com>2014-08-26 20:51:59 -0700
commit8c6067b411ee7f69b3df1341a8696ec1e5811601 (patch)
tree427917de8503a8c226276c77b24610bda4198a01 /install
parent6a42d6fe3b1e50af16942d0f22e8cfa01abfde39 (diff)
downloadvolse-hubzilla-8c6067b411ee7f69b3df1341a8696ec1e5811601.tar.gz
volse-hubzilla-8c6067b411ee7f69b3df1341a8696ec1e5811601.tar.bz2
volse-hubzilla-8c6067b411ee7f69b3df1341a8696ec1e5811601.zip
more hard work
Diffstat (limited to 'install')
-rw-r--r--install/database.sql26
-rw-r--r--install/update.php34
2 files changed, 59 insertions, 1 deletions
diff --git a/install/database.sql b/install/database.sql
index 104f145e5..953f4aba1 100644
--- a/install/database.sql
+++ b/install/database.sql
@@ -311,6 +311,20 @@ CREATE TABLE IF NOT EXISTS `config` (
UNIQUE KEY `access` (`cat`,`k`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+CREATE TABLE IF NOT EXISTS `conv` (
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+ `guid` char(255) NOT NULL,
+ `recips` mediumtext NOT NULL,
+ `uid` int(11) NOT NULL,
+ `creator` char(255) NOT NULL,
+ `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+ `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+ `subject` mediumtext NOT NULL,
+ PRIMARY KEY (`id`),
+ KEY `created` (`created`),
+ KEY `updated` (`updated`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
CREATE TABLE IF NOT EXISTS `event` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`aid` int(10) unsigned NOT NULL DEFAULT '0',
@@ -936,6 +950,18 @@ CREATE TABLE IF NOT EXISTS `shares` (
KEY `share_xchan` (`share_xchan`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+CREATE TABLE IF NOT EXISTS `sign` (
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+ `iid` int(10) unsigned NOT NULL DEFAULT '0',
+ `retract_iid` int(10) unsigned NOT NULL DEFAULT '0',
+ `signed_text` mediumtext NOT NULL,
+ `signature` text NOT NULL,
+ `signer` char(255) NOT NULL,
+ PRIMARY KEY (`id`),
+ KEY `iid` (`iid`),
+ KEY `retract_iid` (`retract_iid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
CREATE TABLE IF NOT EXISTS `site` (
`site_url` char(255) NOT NULL,
`site_access` int(11) NOT NULL DEFAULT '0',
diff --git a/install/update.php b/install/update.php
index 9e184428e..d7a10e11b 100644
--- a/install/update.php
+++ b/install/update.php
@@ -1,6 +1,6 @@
<?php
-define( 'UPDATE_VERSION' , 1124 );
+define( 'UPDATE_VERSION' , 1125 );
/**
*
@@ -1388,4 +1388,36 @@ ADD INDEX ( `hubloc_network` )");
return UPDATE_FAILED;
}
+function update_r1124() {
+ $r1 = q("CREATE TABLE IF NOT EXISTS `sign` (
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+ `iid` int(10) unsigned NOT NULL DEFAULT '0',
+ `retract_iid` int(10) unsigned NOT NULL DEFAULT '0',
+ `signed_text` mediumtext NOT NULL,
+ `signature` text NOT NULL,
+ `signer` char(255) NOT NULL,
+ PRIMARY KEY (`id`),
+ KEY `iid` (`iid`),
+ KEY `retract_iid` (`retract_iid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 ");
+
+ $r2 = q("CREATE TABLE IF NOT EXISTS `conv` (
+ `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+ `guid` char(255) NOT NULL,
+ `recips` mediumtext NOT NULL,
+ `uid` int(11) NOT NULL,
+ `creator` char(255) NOT NULL,
+ `created` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+ `updated` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+ `subject` mediumtext NOT NULL,
+ PRIMARY KEY (`id`),
+ KEY `created` (`created`),
+ KEY `updated` (`updated`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 ");
+ if($r1 && $r2)
+ return UPDATE_SUCCESS;
+ return UPDATE_FAILED;
+
+
+}