public function installAction()
 {
     Model_Extensions_Install::install('facebook');
     if (!Model_Extensions_Install::tableExists('oauth_facebook')) {
         Helper_Db::query("CREATE TABLE IF NOT EXISTS oauth_facebook (\r\n\t\t\t\tid BIGINT(20) AUTO_INCREMENT,\r\n\t\t\t\temail VARCHAR(120),\r\n\t\t\t\toauth_uid BIGINT(20),\r\n\t\t\t\tuser_id BIGINT(20),\r\n\t\t\t\taccess_token VARCHAR(200),\r\n\t\t\t\ttimeline TINYINT(1),\r\n\t\t\t\tPRIMARY KEY (`id`),\r\n\t\t\t\tKEY `oauth_uid` (`oauth_uid`),\r\n\t\t\t\tKEY `user_id` (`user_id`)\r\n\t\t\t\t) ENGINE=InnoDB;");
     }
     if (!Model_Extensions_Install::tableExists('invate_facebook')) {
         Helper_Db::query("CREATE TABLE IF NOT EXISTS `invate_facebook` (\r\n\t\t\t  `if_id` bigint(20) NOT NULL AUTO_INCREMENT,\r\n\t\t\t  `user_id` bigint(20) NOT NULL,\r\n\t\t\t  `code` varchar(32) COLLATE utf8_unicode_ci NOT NULL,\r\n\t\t\t  `facebook_id` bigint(20) NOT NULL,\r\n\t\t\t  PRIMARY KEY (`if_id`),\r\n\t\t\t  KEY `user_id` (`user_id`,`code`)\r\n\t\t\t) ENGINE=InnoDB;");
     }
     $this->redirect($this->getRequest()->getBaseUrl() . $this->getRequest()->getModule() . '/modules_oauth_facebook');
 }
 public function installAction()
 {
     Model_Extensions_Install::install('rackspace');
     $this->redirect($this->getRequest()->getBaseUrl() . $this->getRequest()->getModule() . '/modules_storage_rackspace');
 }
示例#3
0
 public function installAction()
 {
     Model_Extensions_Install::install('twitter');
     if (!Model_Extensions_Install::tableExists('oauth_twitter')) {
         Helper_Db::query("CREATE TABLE IF NOT EXISTS oauth_twitter (\r\n\t\t\t\tid BIGINT(20) AUTO_INCREMENT,\r\n\t\t\t\toauth_uid BIGINT(20),\r\n\t\t\t\tuser_id BIGINT(20),\r\n\t\t\t\tusername VARCHAR(100),\r\n\t\t\t\ttwitter_oauth_token VARCHAR(200),\r\n\t\t\t\ttwitter_oauth_token_secret VARCHAR(200),\r\n\t\t\t\ttwit TINYINT(1),\r\n\t\t\t\tPRIMARY KEY (`id`),\r\n\t\t\t\tKEY `oauth_uid` (`oauth_uid`),\r\n\t\t\t\tKEY `user_id` (`user_id`)\r\n\t\t\t\t) ENGINE=InnoDB;");
     }
     $this->redirect($this->getRequest()->getBaseUrl() . $this->getRequest()->getModule() . '/modules_oauth_twitter');
 }
 public function installAction()
 {
     Model_Extensions_Install::install('instagram');
     if (!Model_Extensions_Install::tableExists('oauth_instagram')) {
         Helper_Db::query("CREATE TABLE IF NOT EXISTS oauth_instagram (\r\n\t\t\t\tid BIGINT(20) AUTO_INCREMENT,\r\n\t\t\t\toauth_uid BIGINT(20),\r\n\t\t\t\tuser_id BIGINT(20),\r\n\t\t\t\tusername VARCHAR(100),\r\n\t\t\t\taccess_token VARCHAR(200),\r\n\t\t\t\tPRIMARY KEY (`id`),\r\n\t\t\t\tKEY `oauth_uid` (`oauth_uid`),\r\n\t\t\t\tKEY `user_id` (`user_id`)\r\n\t\t\t\t) ENGINE=InnoDB;");
     }
     if (!Model_Extensions_Install::tableExists('instagram_media')) {
         Helper_Db::query("CREATE TABLE IF NOT EXISTS `instagram_media` (\r\n\t\t\t  `media_id` bigint(20) NOT NULL AUTO_INCREMENT,\r\n\t\t\t  `user_id` bigint(20) NOT NULL,\r\n\t\t\t  `pin_id` bigint(20) NOT NULL,\r\n\t\t\t  `instagram_media_id` bigint(20) NOT NULL,\r\n\t\t\t  `width` bigint(20) NOT NULL,\r\n\t\t\t  `height` bigint(20) NOT NULL,\r\n\t\t\t  `media` varchar(1024) COLLATE utf8_unicode_ci NOT NULL,\r\n\t\t\t  `instagram_profile_id` bigint(20) NOT NULL,\r\n\t\t\t  `md5key` varchar(32) COLLATE utf8_unicode_ci NOT NULL,\r\n\t\t\t  `title` varchar(500) COLLATE utf8_unicode_ci NOT NULL,\r\n\t\t\t  `from` varchar(1024) COLLATE utf8_unicode_ci NOT NULL,\r\n\t\t\t  PRIMARY KEY (`media_id`),\r\n\t\t\t  KEY `user_id` (`user_id`),\r\n\t\t\t  KEY `instagram_media_id` (`instagram_media_id`),\r\n\t\t\t  KEY `md5key` (`md5key`),\r\n\t\t\t  KEY `instagram_profile_id` (`instagram_profile_id`),\r\n\t\t\t  KEY `pin_id` (`pin_id`)\r\n\t\t\t) ENGINE=InnoDB;");
     }
     $this->redirect($this->getRequest()->getBaseUrl() . $this->getRequest()->getModule() . '/modules_oauth_instagram');
 }