Ignore:
Timestamp:
Jul 15, 2014, 9:48:54 PM (10 years ago)
Author:
chronos
Message:
  • Přidáno: Přístup k RSS kanálům přes přístupový token.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Common/Setup/Updates.php

    r662 r668  
    781781  $IconId = $Manager->Database->insert_id;
    782782  $Manager->Execute('UPDATE `Action` SET `Icon` = '.$IconId.' WHERE `Title`="Kontakty"');
    783 
     783}
     784
     785function UpdateTo668($Manager)
     786{
     787  $Manager->Execute('CREATE TABLE IF NOT EXISTS `APIToken` (
     788  `Id` int(11) NOT NULL AUTO_INCREMENT,
     789  `User` int(11) NOT NULL,
     790  `Token` varchar(255) NOT NULL,
     791  PRIMARY KEY (`Id`),
     792  KEY `User` (`User`)
     793) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;');
     794
     795  $Manager->Execute('ALTER TABLE `APIToken`
     796  ADD CONSTRAINT `APIToken_ibfk_1` FOREIGN KEY (`User`) REFERENCES `User` (`Id`);');
     797  $Manager->Execute('INSERT INTO `Module` (`Id` ,`Name` ,`Title`)
     798VALUES (NULL , "RSS", "RSS kanály");');
    784799}
    785800
     
    826841      657 => array('Revision' => 661, 'Function' => 'UpdateTo661'),
    827842      661 => array('Revision' => 662, 'Function' => 'UpdateTo662'),
     843      662 => array('Revision' => 668, 'Function' => 'UpdateTo668'),
    828844    ));
    829845  }
Note: See TracChangeset for help on using the changeset viewer.