Skip to content

Commit

Permalink
Merge pull request #1094 from takeit/bug
Browse files Browse the repository at this point in the history
fixed bugs related to playlists
  • Loading branch information
Paweł Mikołajczuk committed Apr 16, 2015
2 parents 70e7193 + 9f919b1 commit 860e4bd
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ALTER TABLE `playlist` CHANGE `notes` `notes` VARCHAR( 1024 ) CHARACTER SET utf8 COLLATE utf8_unicode_ci NULL DEFAULT NULL;
ALTER TABLE `playlist` CHANGE `max_items` `max_items` INT( 11 ) NULL;
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<?php

$newscoopDir = realpath(dirname(__FILE__).'/../../../../../../').'/';

require_once $newscoopDir.'vendor/autoload.php';
require $newscoopDir.'conf/database_conf.php';

use Monolog\Logger;

$upgradeErrors = array();
$app = new Silex\Application();
$app->register(new Silex\Provider\MonologServiceProvider(), array(
'monolog.logfile' => $newscoopDir.'log/upgrade.log',
'monolog.level' => Logger::NOTICE,
'monolog.name' => 'upgrade',
));

$logger = $app['monolog'];

$app->register(new Silex\Provider\DoctrineServiceProvider(), array(
'db.options' => array(
'driver' => 'pdo_mysql',
'host' => $Campsite['db']['host'],
'dbname' => $Campsite['db']['name'],
'user' => $Campsite['db']['user'],
'password' => $Campsite['db']['pass'],
'port' => $Campsite['db']['port'],
'charset' => 'utf8',
),
));

try {
$app['db']->query('ALTER TABLE playlist ADD themes VARCHAR(255) DEFAULT NULL');
} catch (\Exception $e) {
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
system php ./playlist.php

0 comments on commit 860e4bd

Please sign in to comment.