aboutsummaryrefslogtreecommitdiffstats
path: root/install/update.php
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2013-08-20 20:39:00 -0700
committerfriendica <info@friendica.com>2013-08-20 20:39:00 -0700
commit5d35d2110065dec9f984ad9028a5e8798f1faa37 (patch)
treed1ac0165e6ffba08eade52eeb04c052d665d5270 /install/update.php
parentc4f14312151dcbff3e5448c5e596f7ca6b317dbe (diff)
downloadvolse-hubzilla-5d35d2110065dec9f984ad9028a5e8798f1faa37.tar.gz
volse-hubzilla-5d35d2110065dec9f984ad9028a5e8798f1faa37.tar.bz2
volse-hubzilla-5d35d2110065dec9f984ad9028a5e8798f1faa37.zip
network-wide poll voting structure
Diffstat (limited to 'install/update.php')
-rw-r--r--install/update.php19
1 files changed, 18 insertions, 1 deletions
diff --git a/install/update.php b/install/update.php
index 682ee2aea..fa5afe8de 100644
--- a/install/update.php
+++ b/install/update.php
@@ -1,6 +1,6 @@
<?php
-define( 'UPDATE_VERSION' , 1060 );
+define( 'UPDATE_VERSION' , 1061 );
/**
*
@@ -689,3 +689,20 @@ function update_r1059() {
return UPDATE_SUCCESS;
return UPDATE_FAILED;
}
+
+function update_r1060() {
+
+ $r = q("CREATE TABLE IF NOT EXISTS `vote` (
+ `vote_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+ `vote_poll` int(11) NOT NULL DEFAULT '0',
+ `vote_element` int(11) NOT NULL DEFAULT '0',
+ `vote_result` text NOT NULL,
+ `vote_xchan` char(255) NOT NULL DEFAULT '',
+ PRIMARY KEY (`vote_id`),
+ UNIQUE KEY `vote_vote` (`vote_poll`,`vote_element`,`vote_xchan`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 ");
+
+ if($r)
+ return UPDATE_SUCCESS;
+ return UPDATE_FAILED;
+}