CC-3732: NationTalk Database upgrade fail, from 2.0.3 to 2.1.0
-fixed
This commit is contained in:
parent
81d7e0c80f
commit
80898ec898
181 changed files with 72643 additions and 58 deletions
|
@ -64,7 +64,6 @@ class Config {
|
||||||
|
|
||||||
$CC_CONFIG['cache_ahead_hours'] = $values['general']['cache_ahead_hours'];
|
$CC_CONFIG['cache_ahead_hours'] = $values['general']['cache_ahead_hours'];
|
||||||
|
|
||||||
|
|
||||||
$CC_CONFIG['monit_user'] = $values['monit']['monit_user'];
|
$CC_CONFIG['monit_user'] = $values['monit']['monit_user'];
|
||||||
$CC_CONFIG['monit_password'] = $values['monit']['monit_password'];
|
$CC_CONFIG['monit_password'] = $values['monit']['monit_password'];
|
||||||
|
|
||||||
|
|
|
@ -236,7 +236,7 @@ class UpgradeCommon{
|
||||||
$con = Propel::getConnection();
|
$con = Propel::getConnection();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$result = $con->exec($p_sql);
|
$result = $con->query($p_sql);
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
echo "Error executing $p_sql. Exiting.";
|
echo "Error executing $p_sql. Exiting.";
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/application/models' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/application/models' . PATH_SEPARATOR . get_include_path());
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/application/configs' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/application/configs' . PATH_SEPARATOR . get_include_path());
|
||||||
require_once 'conf.php';
|
//require_once 'conf.php';
|
||||||
require_once 'propel/runtime/lib/Propel.php';
|
require_once 'propel/runtime/lib/Propel.php';
|
||||||
Propel::init(__DIR__."/propel/airtime-conf.php");
|
Propel::init(__DIR__."/propel/airtime-conf.php");
|
||||||
|
|
||||||
|
@ -70,8 +70,8 @@ class AirtimeDatabaseUpgrade {
|
||||||
|
|
||||||
$sql = "SELECT * FROM cc_playlist";
|
$sql = "SELECT * FROM cc_playlist";
|
||||||
$result = UpgradeCommon::queryDb($sql);
|
$result = UpgradeCommon::queryDb($sql);
|
||||||
|
|
||||||
while ($result->fetchInto($row, DB_FETCHMODE_ASSOC)){
|
foreach ($result as $row){
|
||||||
$dt = new DateTime($row['mtime'], new DateTimeZone(date_default_timezone_get()));
|
$dt = new DateTime($row['mtime'], new DateTimeZone(date_default_timezone_get()));
|
||||||
$dt->setTimezone(new DateTimeZone("UTC"));
|
$dt->setTimezone(new DateTimeZone("UTC"));
|
||||||
|
|
||||||
|
@ -79,13 +79,9 @@ class AirtimeDatabaseUpgrade {
|
||||||
$mtime = $dt->format("Y-m-d H:i:s");
|
$mtime = $dt->format("Y-m-d H:i:s");
|
||||||
|
|
||||||
$sql = "UPDATE cc_playlist SET mtime = '$mtime' WHERE id = $id";
|
$sql = "UPDATE cc_playlist SET mtime = '$mtime' WHERE id = $id";
|
||||||
UpgradeCommon::queryDb($sql);
|
UpgradeCommon::queryDb($sql);
|
||||||
//echo ".";
|
|
||||||
//flush();
|
|
||||||
//usleep(100000);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
echo " * Converting playlists to UTC".PHP_EOL;
|
echo " * Converting playlists to UTC".PHP_EOL;
|
||||||
// cc_playlist has a field that keeps track of when the playlist was last modified.
|
// cc_playlist has a field that keeps track of when the playlist was last modified.
|
||||||
|
@ -108,8 +104,8 @@ class AirtimeDatabaseUpgrade {
|
||||||
|
|
||||||
$sql = "SELECT * FROM cc_schedule";
|
$sql = "SELECT * FROM cc_schedule";
|
||||||
$result = UpgradeCommon::queryDb($sql);
|
$result = UpgradeCommon::queryDb($sql);
|
||||||
|
|
||||||
while ($result->fetchInto($row, DB_FETCHMODE_ASSOC)){
|
foreach ($result as $row){
|
||||||
$dtStarts = new DateTime($row['starts'], new DateTimeZone(date_default_timezone_get()));
|
$dtStarts = new DateTime($row['starts'], new DateTimeZone(date_default_timezone_get()));
|
||||||
$dtStarts->setTimezone(new DateTimeZone("UTC"));
|
$dtStarts->setTimezone(new DateTimeZone("UTC"));
|
||||||
|
|
||||||
|
@ -122,10 +118,8 @@ class AirtimeDatabaseUpgrade {
|
||||||
|
|
||||||
$sql = "UPDATE cc_schedule SET starts = '$starts', ends = '$ends' WHERE id = $id";
|
$sql = "UPDATE cc_schedule SET starts = '$starts', ends = '$ends' WHERE id = $id";
|
||||||
UpgradeCommon::queryDb($sql);
|
UpgradeCommon::queryDb($sql);
|
||||||
//echo ".";
|
|
||||||
//flush();
|
|
||||||
//usleep(100000);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
||||||
echo " * Converting schedule to UTC".PHP_EOL;
|
echo " * Converting schedule to UTC".PHP_EOL;
|
||||||
|
@ -153,17 +147,13 @@ class AirtimeDatabaseUpgrade {
|
||||||
|
|
||||||
$sql = "SELECT * FROM cc_show_days";
|
$sql = "SELECT * FROM cc_show_days";
|
||||||
$result = UpgradeCommon::queryDb($sql);
|
$result = UpgradeCommon::queryDb($sql);
|
||||||
|
|
||||||
while ($result->fetchInto($row, DB_FETCHMODE_ASSOC)){
|
foreach ($result as $row){
|
||||||
|
|
||||||
$id = $row['id'];
|
$id = $row['id'];
|
||||||
$timezone = date_default_timezone_get();
|
$timezone = date_default_timezone_get();
|
||||||
|
|
||||||
$sql = "UPDATE cc_show_days SET timezone = '$timezone' WHERE id = $id";
|
$sql = "UPDATE cc_show_days SET timezone = '$timezone' WHERE id = $id";
|
||||||
UpgradeCommon::queryDb($sql);
|
UpgradeCommon::queryDb($sql);
|
||||||
//echo ".";
|
|
||||||
//flush();
|
|
||||||
//usleep(100000);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -185,8 +175,8 @@ class AirtimeDatabaseUpgrade {
|
||||||
|
|
||||||
$sql = "SELECT * FROM cc_show_instances";
|
$sql = "SELECT * FROM cc_show_instances";
|
||||||
$result = UpgradeCommon::queryDb($sql);
|
$result = UpgradeCommon::queryDb($sql);
|
||||||
|
|
||||||
while ($result->fetchInto($row, DB_FETCHMODE_ASSOC)){
|
foreach ($result as $row){
|
||||||
$dtStarts = new DateTime($row['starts'], new DateTimeZone(date_default_timezone_get()));
|
$dtStarts = new DateTime($row['starts'], new DateTimeZone(date_default_timezone_get()));
|
||||||
$dtStarts->setTimezone(new DateTimeZone("UTC"));
|
$dtStarts->setTimezone(new DateTimeZone("UTC"));
|
||||||
|
|
||||||
|
@ -199,9 +189,6 @@ class AirtimeDatabaseUpgrade {
|
||||||
|
|
||||||
$sql = "UPDATE cc_show_instances SET starts = '$starts', ends = '$ends' WHERE id = $id";
|
$sql = "UPDATE cc_show_instances SET starts = '$starts', ends = '$ends' WHERE id = $id";
|
||||||
UpgradeCommon::queryDb($sql);
|
UpgradeCommon::queryDb($sql);
|
||||||
//echo ".";
|
|
||||||
//flush();
|
|
||||||
//usleep(100000);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -21,7 +21,7 @@ class UpgradeCommon{
|
||||||
$sql = "SELECT valstr from cc_pref WHERE keystr = 'timezone'";
|
$sql = "SELECT valstr from cc_pref WHERE keystr = 'timezone'";
|
||||||
|
|
||||||
$result = self::queryDb($sql);
|
$result = self::queryDb($sql);
|
||||||
$timezone = $result['valstr'];
|
$timezone = $result->fetchColumn();
|
||||||
|
|
||||||
date_default_timezone_set($timezone);
|
date_default_timezone_set($timezone);
|
||||||
}
|
}
|
||||||
|
@ -245,7 +245,7 @@ class UpgradeCommon{
|
||||||
$con = Propel::getConnection();
|
$con = Propel::getConnection();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$result = $con->exec($p_sql);
|
$result = $con->query($p_sql);
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
echo "Error executing $p_sql. Exiting.";
|
echo "Error executing $p_sql. Exiting.";
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/application/models' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/application/models' . PATH_SEPARATOR . get_include_path());
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/application/configs' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/application/configs' . PATH_SEPARATOR . get_include_path());
|
||||||
require_once 'conf.php';
|
//require_once 'conf.php';
|
||||||
require_once 'propel/runtime/lib/Propel.php';
|
require_once 'propel/runtime/lib/Propel.php';
|
||||||
Propel::init(__DIR__."/propel/airtime-conf.php");
|
Propel::init(__DIR__."/propel/airtime-conf.php");
|
||||||
|
|
||||||
|
@ -76,8 +76,6 @@ class AirtimeConfigFileUpgrade{
|
||||||
chgrp($filename, $user) &&
|
chgrp($filename, $user) &&
|
||||||
chmod($filename, 0640));
|
chmod($filename, 0640));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
UpgradeCommon::connectToDatabase();
|
UpgradeCommon::connectToDatabase();
|
||||||
|
|
|
@ -20,7 +20,7 @@ class UpgradeCommon{
|
||||||
$sql = "SELECT valstr from cc_pref WHERE keystr = 'timezone'";
|
$sql = "SELECT valstr from cc_pref WHERE keystr = 'timezone'";
|
||||||
|
|
||||||
$result = self::queryDb($sql);
|
$result = self::queryDb($sql);
|
||||||
$timezone = $result['valstr'];
|
$timezone = $result->fetchColumn();
|
||||||
|
|
||||||
date_default_timezone_set($timezone);
|
date_default_timezone_set($timezone);
|
||||||
}
|
}
|
||||||
|
@ -239,7 +239,7 @@ class UpgradeCommon{
|
||||||
$con = Propel::getConnection();
|
$con = Propel::getConnection();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$result = $con->exec($p_sql);
|
$result = $con->query($p_sql);
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
echo "Error executing $p_sql. Exiting.";
|
echo "Error executing $p_sql. Exiting.";
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/application/models' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/application/models' . PATH_SEPARATOR . get_include_path());
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/application/configs' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/application/configs' . PATH_SEPARATOR . get_include_path());
|
||||||
require_once 'conf.php';
|
//require_once 'conf.php';
|
||||||
require_once 'propel/runtime/lib/Propel.php';
|
require_once 'propel/runtime/lib/Propel.php';
|
||||||
Propel::init(__DIR__."/propel/airtime-conf.php");
|
Propel::init(__DIR__."/propel/airtime-conf.php");
|
||||||
|
|
||||||
|
|
|
@ -21,25 +21,7 @@ class AirtimeDatabaseUpgrade{
|
||||||
/*
|
/*
|
||||||
* set values for playout_status in cc_schedule
|
* set values for playout_status in cc_schedule
|
||||||
*/
|
*/
|
||||||
private static function task1() {
|
private static function task1() {
|
||||||
|
|
||||||
// Define path to application directory
|
|
||||||
defined('APPLICATION_PATH')
|
|
||||||
|| define('APPLICATION_PATH', realpath(__DIR__.'/../../../airtime_mvc/application'));
|
|
||||||
|
|
||||||
// Ensure library is on include_path
|
|
||||||
set_include_path(implode(PATH_SEPARATOR, array(
|
|
||||||
get_include_path(),
|
|
||||||
realpath(APPLICATION_PATH . '/../library')
|
|
||||||
)));
|
|
||||||
|
|
||||||
//Propel classes.
|
|
||||||
set_include_path(APPLICATION_PATH . '/models' . PATH_SEPARATOR . get_include_path());
|
|
||||||
|
|
||||||
//include_once APPLICATION_PATH."/configs/conf.php";
|
|
||||||
include_once 'propel/runtime/lib/Propel.php';
|
|
||||||
Propel::init(APPLICATION_PATH."/configs/airtime-conf-production.php");
|
|
||||||
|
|
||||||
$con = Propel::getConnection(CcSchedulePeer::DATABASE_NAME);
|
$con = Propel::getConnection(CcSchedulePeer::DATABASE_NAME);
|
||||||
|
|
||||||
$showInstances = CcShowInstancesQuery::create()
|
$showInstances = CcShowInstancesQuery::create()
|
||||||
|
|
|
@ -14,14 +14,32 @@
|
||||||
* with new versions.
|
* with new versions.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
function get_conf_location(){
|
function get_conf_location(){
|
||||||
$conf = parse_ini_file("/etc/airtime/airtime.conf", TRUE);
|
$conf = parse_ini_file("/etc/airtime/airtime.conf", TRUE);
|
||||||
$airtime_dir = $conf['general']['airtime_dir'];
|
$airtime_dir = $conf['general']['airtime_dir'];
|
||||||
return $airtime_dir."/"."application/configs/conf.php";
|
return $airtime_dir."/"."application/configs/conf.php";
|
||||||
}
|
}
|
||||||
|
* */
|
||||||
|
|
||||||
$conf_path = get_conf_location();
|
// Define path to application directory
|
||||||
require_once $conf_path;
|
defined('APPLICATION_PATH')
|
||||||
|
|| define('APPLICATION_PATH', realpath(__DIR__.'/../../../airtime_mvc/application'));
|
||||||
|
|
||||||
|
// Ensure library is on include_path
|
||||||
|
set_include_path(implode(PATH_SEPARATOR, array(
|
||||||
|
get_include_path(),
|
||||||
|
realpath(APPLICATION_PATH . '/../library')
|
||||||
|
)));
|
||||||
|
|
||||||
|
//Propel classes.
|
||||||
|
set_include_path(APPLICATION_PATH . '/models' . PATH_SEPARATOR . get_include_path());
|
||||||
|
|
||||||
|
include_once 'propel/runtime/lib/Propel.php';
|
||||||
|
Propel::init(__DIR__."/propel/airtime-conf.php");
|
||||||
|
|
||||||
|
//$conf_path = get_conf_location();
|
||||||
|
//require_once $conf_path;
|
||||||
|
|
||||||
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
set_include_path(__DIR__.'/../../../airtime_mvc/library' . PATH_SEPARATOR . get_include_path());
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,7 @@ class UpgradeCommon{
|
||||||
$sql = "SELECT valstr from cc_pref WHERE keystr = 'timezone'";
|
$sql = "SELECT valstr from cc_pref WHERE keystr = 'timezone'";
|
||||||
|
|
||||||
$result = self::queryDb($sql);
|
$result = self::queryDb($sql);
|
||||||
$timezone = $result['valstr'];
|
$timezone = $result->fetchColumn();
|
||||||
|
|
||||||
date_default_timezone_set($timezone);
|
date_default_timezone_set($timezone);
|
||||||
}
|
}
|
||||||
|
@ -238,7 +238,7 @@ class UpgradeCommon{
|
||||||
$con = Propel::getConnection();
|
$con = Propel::getConnection();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$result = $con->exec($p_sql);
|
$result = $con->query($p_sql);
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
echo "Error executing $p_sql. Exiting.";
|
echo "Error executing $p_sql. Exiting.";
|
||||||
exit(1);
|
exit(1);
|
||||||
|
|
|
@ -0,0 +1,28 @@
|
||||||
|
<?php
|
||||||
|
// This file generated by Propel 1.5.2 convert-conf target - with modifications by Martin
|
||||||
|
// from XML runtime conf file /home/naomiaro/dev-campcaster/campcaster/build/runtime-conf.xml
|
||||||
|
|
||||||
|
$ini = parse_ini_file('/etc/airtime/airtime.conf', true);
|
||||||
|
|
||||||
|
$dbhost = $ini['database']['host'];
|
||||||
|
$dbname = $ini['database']['dbname'];
|
||||||
|
$dbuser = $ini['database']['dbuser'];
|
||||||
|
$dbpass = $ini['database']['dbpass'];
|
||||||
|
|
||||||
|
$conf = array (
|
||||||
|
'datasources' =>
|
||||||
|
array (
|
||||||
|
'airtime' =>
|
||||||
|
array (
|
||||||
|
'adapter' => 'pgsql',
|
||||||
|
'connection' =>
|
||||||
|
array (
|
||||||
|
'dsn' => "pgsql:host=$dbhost;port=5432;dbname=$dbname;user=$dbuser;password=$dbpass",
|
||||||
|
),
|
||||||
|
),
|
||||||
|
'default' => 'airtime',
|
||||||
|
),
|
||||||
|
'generator_version' => '1.5.2',
|
||||||
|
);
|
||||||
|
$conf['classmap'] = include(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'classmap-airtime-conf.php');
|
||||||
|
return $conf;
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_access' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcAccess extends BaseCcAccess {
|
||||||
|
|
||||||
|
} // CcAccess
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_access' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcAccessPeer extends BaseCcAccessPeer {
|
||||||
|
|
||||||
|
} // CcAccessPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_access' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcAccessQuery extends BaseCcAccessQuery {
|
||||||
|
|
||||||
|
} // CcAccessQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_backup' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcBackup extends BaseCcBackup {
|
||||||
|
|
||||||
|
} // CcBackup
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_backup' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcBackupPeer extends BaseCcBackupPeer {
|
||||||
|
|
||||||
|
} // CcBackupPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_backup' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcBackupQuery extends BaseCcBackupQuery {
|
||||||
|
|
||||||
|
} // CcBackupQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_country' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcCountry extends BaseCcCountry {
|
||||||
|
|
||||||
|
} // CcCountry
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_country' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcCountryPeer extends BaseCcCountryPeer {
|
||||||
|
|
||||||
|
} // CcCountryPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_country' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcCountryQuery extends BaseCcCountryQuery {
|
||||||
|
|
||||||
|
} // CcCountryQuery
|
|
@ -0,0 +1,44 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_files' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.campcaster
|
||||||
|
*/
|
||||||
|
class CcFiles extends BaseCcFiles {
|
||||||
|
|
||||||
|
public function getDbLength($format = "H:i:s.u")
|
||||||
|
{
|
||||||
|
return parent::getDbLength($format);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setDbLength($v)
|
||||||
|
{
|
||||||
|
if ($v instanceof DateTime) {
|
||||||
|
$dt = $v;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
|
||||||
|
try {
|
||||||
|
|
||||||
|
$dt = new DateTime($v);
|
||||||
|
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException('Error parsing date/time value: ' . var_export($v, true), $x);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->length = $dt->format('H:i:s.u');
|
||||||
|
$this->modifiedColumns[] = CcFilesPeer::LENGTH;
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
} // CcFiles
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_files' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcFilesPeer extends BaseCcFilesPeer {
|
||||||
|
|
||||||
|
} // CcFilesPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_files' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcFilesQuery extends BaseCcFilesQuery {
|
||||||
|
|
||||||
|
} // CcFilesQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_login_attempts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcLoginAttempts extends BaseCcLoginAttempts {
|
||||||
|
|
||||||
|
} // CcLoginAttempts
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_login_attempts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcLoginAttemptsPeer extends BaseCcLoginAttemptsPeer {
|
||||||
|
|
||||||
|
} // CcLoginAttemptsPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_login_attempts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcLoginAttemptsQuery extends BaseCcLoginAttemptsQuery {
|
||||||
|
|
||||||
|
} // CcLoginAttemptsQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_music_dirs' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcMusicDirs extends BaseCcMusicDirs {
|
||||||
|
|
||||||
|
} // CcMusicDirs
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_music_dirs' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcMusicDirsPeer extends BaseCcMusicDirsPeer {
|
||||||
|
|
||||||
|
} // CcMusicDirsPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_music_dirs' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcMusicDirsQuery extends BaseCcMusicDirsQuery {
|
||||||
|
|
||||||
|
} // CcMusicDirsQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_perms' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPerms extends BaseCcPerms {
|
||||||
|
|
||||||
|
} // CcPerms
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_perms' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPermsPeer extends BaseCcPermsPeer {
|
||||||
|
|
||||||
|
} // CcPermsPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_perms' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPermsQuery extends BaseCcPermsQuery {
|
||||||
|
|
||||||
|
} // CcPermsQuery
|
|
@ -0,0 +1,102 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_playlist' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.campcaster
|
||||||
|
*/
|
||||||
|
class CcPlaylist extends BaseCcPlaylist {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [utime] column value.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||||
|
* If format is NULL, then the raw DateTime object will be returned.
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbUtime($format = 'Y-m-d H:i:s')
|
||||||
|
{
|
||||||
|
if ($this->utime === null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($this->utime, new DateTimeZone("UTC"));
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->utime, true), $x);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($format === null) {
|
||||||
|
// Because propel.useDateTimeClass is TRUE, we return a DateTime object.
|
||||||
|
return $dt;
|
||||||
|
} elseif (strpos($format, '%') !== false) {
|
||||||
|
return strftime($format, $dt->format('U'));
|
||||||
|
} else {
|
||||||
|
return $dt->format($format);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [mtime] column value.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||||
|
* If format is NULL, then the raw DateTime object will be returned.
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbMtime($format = 'Y-m-d H:i:s')
|
||||||
|
{
|
||||||
|
if ($this->mtime === null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($this->mtime, new DateTimeZone("UTC"));
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->mtime, true), $x);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($format === null) {
|
||||||
|
// Because propel.useDateTimeClass is TRUE, we return a DateTime object.
|
||||||
|
return $dt;
|
||||||
|
} elseif (strpos($format, '%') !== false) {
|
||||||
|
return strftime($format, $dt->format('U'));
|
||||||
|
} else {
|
||||||
|
return $dt->format($format);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Computes the value of the aggregate column length
|
||||||
|
* Overridden to provide a default of 00:00:00 if the playlist is empty.
|
||||||
|
*
|
||||||
|
* @param PropelPDO $con A connection object
|
||||||
|
*
|
||||||
|
* @return mixed The scalar result from the aggregate query
|
||||||
|
*/
|
||||||
|
public function computeDbLength(PropelPDO $con)
|
||||||
|
{
|
||||||
|
$stmt = $con->prepare('SELECT SUM(cliplength) FROM "cc_playlistcontents" WHERE cc_playlistcontents.PLAYLIST_ID = :p1');
|
||||||
|
$stmt->bindValue(':p1', $this->getDbId());
|
||||||
|
$stmt->execute();
|
||||||
|
$length = $stmt->fetchColumn();
|
||||||
|
|
||||||
|
if (is_null($length)) {
|
||||||
|
$length = "00:00:00";
|
||||||
|
}
|
||||||
|
|
||||||
|
return $length;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // CcPlaylist
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_playlist' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPlaylistPeer extends BaseCcPlaylistPeer {
|
||||||
|
|
||||||
|
} // CcPlaylistPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_playlist' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPlaylistQuery extends BaseCcPlaylistQuery {
|
||||||
|
|
||||||
|
} // CcPlaylistQuery
|
|
@ -0,0 +1,94 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_playlistcontents' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.campcaster
|
||||||
|
*/
|
||||||
|
class CcPlaylistcontents extends BaseCcPlaylistcontents {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [fadein] column value.
|
||||||
|
*
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbFadein($format = "s.u")
|
||||||
|
{
|
||||||
|
return parent::getDbFadein($format);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [fadein] column value.
|
||||||
|
*
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbFadeout($format = "s.u")
|
||||||
|
{
|
||||||
|
return parent::getDbFadeout($format);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param String in format SS.uuuuuu, Datetime, or DateTime accepted string.
|
||||||
|
*
|
||||||
|
* @return CcPlaylistcontents The current object (for fluent API support)
|
||||||
|
*/
|
||||||
|
public function setDbFadein($v)
|
||||||
|
{
|
||||||
|
if ($v instanceof DateTime) {
|
||||||
|
$dt = $v;
|
||||||
|
}
|
||||||
|
else if (preg_match('/^[0-9]{1,2}(\.\d{1,6})?$/', $v)) {
|
||||||
|
$dt = DateTime::createFromFormat("s.u", $v);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($v);
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException('Error parsing date/time value: ' . var_export($v, true), $x);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->fadein = $dt->format('H:i:s.u');
|
||||||
|
$this->modifiedColumns[] = CcPlaylistcontentsPeer::FADEIN;
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
} // setDbFadein()
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param String in format SS.uuuuuu, Datetime, or DateTime accepted string.
|
||||||
|
*
|
||||||
|
* @return CcPlaylistcontents The current object (for fluent API support)
|
||||||
|
*/
|
||||||
|
public function setDbFadeout($v)
|
||||||
|
{
|
||||||
|
if ($v instanceof DateTime) {
|
||||||
|
$dt = $v;
|
||||||
|
}
|
||||||
|
else if (preg_match('/^[0-9]{1,2}(\.\d{1,6})?$/', $v)) {
|
||||||
|
$dt = DateTime::createFromFormat("s.u", $v);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($v);
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException('Error parsing date/time value: ' . var_export($v, true), $x);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->fadeout = $dt->format('H:i:s.u');
|
||||||
|
$this->modifiedColumns[] = CcPlaylistcontentsPeer::FADEOUT;
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
} // setDbFadeout()
|
||||||
|
|
||||||
|
} // CcPlaylistcontents
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_playlistcontents' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPlaylistcontentsPeer extends BaseCcPlaylistcontentsPeer {
|
||||||
|
|
||||||
|
} // CcPlaylistcontentsPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_playlistcontents' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPlaylistcontentsQuery extends BaseCcPlaylistcontentsQuery {
|
||||||
|
|
||||||
|
} // CcPlaylistcontentsQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_pref' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPref extends BaseCcPref {
|
||||||
|
|
||||||
|
} // CcPref
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_pref' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPrefPeer extends BaseCcPrefPeer {
|
||||||
|
|
||||||
|
} // CcPrefPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_pref' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcPrefQuery extends BaseCcPrefQuery {
|
||||||
|
|
||||||
|
} // CcPrefQuery
|
|
@ -0,0 +1,242 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_schedule' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSchedule extends BaseCcSchedule {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [starts] column value.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||||
|
* If format is NULL, then the raw DateTime object will be returned.
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbStarts($format = 'Y-m-d H:i:s.u')
|
||||||
|
{
|
||||||
|
if ($this->starts === null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($this->starts, new DateTimeZone("UTC"));
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->starts, true), $x);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($format === null) {
|
||||||
|
// Because propel.useDateTimeClass is TRUE, we return a DateTime object.
|
||||||
|
return $dt;
|
||||||
|
} elseif (strpos($format, '%') !== false) {
|
||||||
|
return strftime($format, $dt->format('U'));
|
||||||
|
} else {
|
||||||
|
return $dt->format($format);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [ends] column value.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||||
|
* If format is NULL, then the raw DateTime object will be returned.
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbEnds($format = 'Y-m-d H:i:s.u')
|
||||||
|
{
|
||||||
|
if ($this->ends === null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($this->ends, new DateTimeZone("UTC"));
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->ends, true), $x);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($format === null) {
|
||||||
|
// Because propel.useDateTimeClass is TRUE, we return a DateTime object.
|
||||||
|
return $dt;
|
||||||
|
} elseif (strpos($format, '%') !== false) {
|
||||||
|
return strftime($format, $dt->format('U'));
|
||||||
|
} else {
|
||||||
|
return $dt->format($format);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [fadein] column value.
|
||||||
|
*
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbFadeIn($format = "s.u")
|
||||||
|
{
|
||||||
|
return parent::getDbFadein($format);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [fadein] column value.
|
||||||
|
*
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbFadeOut($format = "s.u")
|
||||||
|
{
|
||||||
|
return parent::getDbFadeout($format);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param String in format SS.uuuuuu, Datetime, or DateTime accepted string.
|
||||||
|
*
|
||||||
|
* @return CcPlaylistcontents The current object (for fluent API support)
|
||||||
|
*/
|
||||||
|
public function setDbFadeIn($v)
|
||||||
|
{
|
||||||
|
if ($v instanceof DateTime) {
|
||||||
|
$dt = $v;
|
||||||
|
}
|
||||||
|
else if (preg_match('/^[0-9]{1,2}(\.\d{1,6})?$/', $v)) {
|
||||||
|
$dt = DateTime::createFromFormat("s.u", $v);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($v);
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException('Error parsing date/time value: ' . var_export($v, true), $x);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$this->fade_in = $dt->format('H:i:s.u');
|
||||||
|
$this->modifiedColumns[] = CcSchedulePeer::FADE_IN;
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
} // setDbFadein()
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param String in format SS.uuuuuu, Datetime, or DateTime accepted string.
|
||||||
|
*
|
||||||
|
* @return CcPlaylistcontents The current object (for fluent API support)
|
||||||
|
*/
|
||||||
|
public function setDbFadeOut($v)
|
||||||
|
{
|
||||||
|
if ($v instanceof DateTime) {
|
||||||
|
$dt = $v;
|
||||||
|
}
|
||||||
|
else if (preg_match('/^[0-9]{1,2}(\.\d{1,6})?$/', $v)) {
|
||||||
|
$dt = DateTime::createFromFormat("s.u", $v);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($v);
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException('Error parsing date/time value: ' . var_export($v, true), $x);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->fade_out = $dt->format('H:i:s.u');
|
||||||
|
$this->modifiedColumns[] = CcSchedulePeer::FADE_OUT;
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
} // setDbFadeout()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the value of [starts] column to a normalized version of the date/time value specified.
|
||||||
|
*
|
||||||
|
* @param mixed $v string, integer (timestamp), or DateTime value. Empty string will
|
||||||
|
* be treated as NULL for temporal objects.
|
||||||
|
* @return CcSchedule The current object (for fluent API support)
|
||||||
|
*/
|
||||||
|
public function setDbStarts($v)
|
||||||
|
{
|
||||||
|
if ($v instanceof DateTime) {
|
||||||
|
$dt = $v;
|
||||||
|
} else {
|
||||||
|
// some string/numeric value passed; we normalize that so that we can
|
||||||
|
// validate it.
|
||||||
|
try {
|
||||||
|
if (is_numeric($v)) { // if it's a unix timestamp
|
||||||
|
$dt = new DateTime('@'.$v, new DateTimeZone('UTC'));
|
||||||
|
// We have to explicitly specify and then change the time zone because of a
|
||||||
|
// DateTime bug: http://bugs.php.net/bug.php?id=43003
|
||||||
|
$dt->setTimeZone(new DateTimeZone(date_default_timezone_get()));
|
||||||
|
} else {
|
||||||
|
$dt = new DateTime($v);
|
||||||
|
}
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException('Error parsing date/time value: ' . var_export($v, true), $x);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->starts = ($dt ? $dt->format('Y-m-d H:i:s.u') : null);
|
||||||
|
$this->modifiedColumns[] = CcSchedulePeer::STARTS;
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
} // setDbStarts()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the value of [ends] column to a normalized version of the date/time value specified.
|
||||||
|
*
|
||||||
|
* @param mixed $v string, integer (timestamp), or DateTime value. Empty string will
|
||||||
|
* be treated as NULL for temporal objects.
|
||||||
|
* @return CcSchedule The current object (for fluent API support)
|
||||||
|
*/
|
||||||
|
public function setDbEnds($v)
|
||||||
|
{
|
||||||
|
|
||||||
|
if ($v instanceof DateTime) {
|
||||||
|
$dt = $v;
|
||||||
|
} else {
|
||||||
|
// some string/numeric value passed; we normalize that so that we can
|
||||||
|
// validate it.
|
||||||
|
try {
|
||||||
|
if (is_numeric($v)) { // if it's a unix timestamp
|
||||||
|
$dt = new DateTime('@'.$v, new DateTimeZone('UTC'));
|
||||||
|
// We have to explicitly specify and then change the time zone because of a
|
||||||
|
// DateTime bug: http://bugs.php.net/bug.php?id=43003
|
||||||
|
$dt->setTimeZone(new DateTimeZone(date_default_timezone_get()));
|
||||||
|
} else {
|
||||||
|
$dt = new DateTime($v);
|
||||||
|
}
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException('Error parsing date/time value: ' . var_export($v, true), $x);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->ends = ($dt ? $dt->format('Y-m-d H:i:s.u') : null);
|
||||||
|
$this->modifiedColumns[] = CcSchedulePeer::ENDS;
|
||||||
|
|
||||||
|
return $this;
|
||||||
|
} // setDbEnds()
|
||||||
|
|
||||||
|
public function isCurrentItem($epochNow = null) {
|
||||||
|
|
||||||
|
if (is_null($epochNow)) {
|
||||||
|
$epochNow = microtime(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
$epochStart = floatval($this->getDbStarts('U.u'));
|
||||||
|
$epochEnd = floatval($this->getDbEnds('U.u'));
|
||||||
|
|
||||||
|
if ($epochStart < $epochNow && $epochEnd > $epochNow) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // CcSchedule
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_schedule' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSchedulePeer extends BaseCcSchedulePeer {
|
||||||
|
|
||||||
|
} // CcSchedulePeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_schedule' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcScheduleQuery extends BaseCcScheduleQuery {
|
||||||
|
|
||||||
|
} // CcScheduleQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_service_register' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcServiceRegister extends BaseCcServiceRegister {
|
||||||
|
|
||||||
|
} // CcServiceRegister
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_service_register' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcServiceRegisterPeer extends BaseCcServiceRegisterPeer {
|
||||||
|
|
||||||
|
} // CcServiceRegisterPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_service_register' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcServiceRegisterQuery extends BaseCcServiceRegisterQuery {
|
||||||
|
|
||||||
|
} // CcServiceRegisterQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_sess' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSess extends BaseCcSess {
|
||||||
|
|
||||||
|
} // CcSess
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_sess' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSessPeer extends BaseCcSessPeer {
|
||||||
|
|
||||||
|
} // CcSessPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_sess' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSessQuery extends BaseCcSessQuery {
|
||||||
|
|
||||||
|
} // CcSessQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_show' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShow extends BaseCcShow {
|
||||||
|
|
||||||
|
} // CcShow
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_show_days' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowDays extends BaseCcShowDays {
|
||||||
|
|
||||||
|
} // CcShowDays
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_days' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowDaysPeer extends BaseCcShowDaysPeer {
|
||||||
|
|
||||||
|
} // CcShowDaysPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_days' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowDaysQuery extends BaseCcShowDaysQuery {
|
||||||
|
|
||||||
|
} // CcShowDaysQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_show_hosts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowHosts extends BaseCcShowHosts {
|
||||||
|
|
||||||
|
} // CcShowHosts
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_hosts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowHostsPeer extends BaseCcShowHostsPeer {
|
||||||
|
|
||||||
|
} // CcShowHostsPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_hosts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowHostsQuery extends BaseCcShowHostsQuery {
|
||||||
|
|
||||||
|
} // CcShowHostsQuery
|
|
@ -0,0 +1,171 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_show_instances' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowInstances extends BaseCcShowInstances {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [starts] column value.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||||
|
* If format is NULL, then the raw DateTime object will be returned.
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbStarts($format = 'Y-m-d H:i:s')
|
||||||
|
{
|
||||||
|
if ($this->starts === null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($this->starts, new DateTimeZone("UTC"));
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->starts, true), $x);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($format === null) {
|
||||||
|
// Because propel.useDateTimeClass is TRUE, we return a DateTime object.
|
||||||
|
return $dt;
|
||||||
|
} elseif (strpos($format, '%') !== false) {
|
||||||
|
return strftime($format, $dt->format('U'));
|
||||||
|
} else {
|
||||||
|
return $dt->format($format);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [ends] column value.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||||
|
* If format is NULL, then the raw DateTime object will be returned.
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbEnds($format = 'Y-m-d H:i:s')
|
||||||
|
{
|
||||||
|
if ($this->ends === null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($this->ends, new DateTimeZone("UTC"));
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->ends, true), $x);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($format === null) {
|
||||||
|
// Because propel.useDateTimeClass is TRUE, we return a DateTime object.
|
||||||
|
return $dt;
|
||||||
|
} elseif (strpos($format, '%') !== false) {
|
||||||
|
return strftime($format, $dt->format('U'));
|
||||||
|
} else {
|
||||||
|
return $dt->format($format);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the [optionally formatted] temporal [last_scheduled] column value.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @param string $format The date/time format string (either date()-style or strftime()-style).
|
||||||
|
* If format is NULL, then the raw DateTime object will be returned.
|
||||||
|
* @return mixed Formatted date/time value as string or DateTime object (if format is NULL), NULL if column is NULL
|
||||||
|
* @throws PropelException - if unable to parse/validate the date/time value.
|
||||||
|
*/
|
||||||
|
public function getDbLastScheduled($format = 'Y-m-d H:i:s')
|
||||||
|
{
|
||||||
|
if ($this->last_scheduled === null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
$dt = new DateTime($this->last_scheduled, new DateTimeZone("UTC"));
|
||||||
|
} catch (Exception $x) {
|
||||||
|
throw new PropelException("Internally stored date/time/timestamp value could not be converted to DateTime: " . var_export($this->last_scheduled, true), $x);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($format === null) {
|
||||||
|
// Because propel.useDateTimeClass is TRUE, we return a DateTime object.
|
||||||
|
return $dt;
|
||||||
|
} elseif (strpos($format, '%') !== false) {
|
||||||
|
return strftime($format, $dt->format('U'));
|
||||||
|
} else {
|
||||||
|
return $dt->format($format);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//post save hook to update the cc_schedule status column for the tracks in the show.
|
||||||
|
public function updateScheduleStatus(PropelPDO $con) {
|
||||||
|
|
||||||
|
$this->updateDbTimeFilled($con);
|
||||||
|
|
||||||
|
//scheduled track is in the show
|
||||||
|
CcScheduleQuery::create()
|
||||||
|
->filterByDbInstanceId($this->id)
|
||||||
|
->filterByDbPlayoutStatus(0, Criteria::GREATER_EQUAL)
|
||||||
|
->filterByDbEnds($this->ends, Criteria::LESS_EQUAL)
|
||||||
|
->update(array('DbPlayoutStatus' => 1), $con);
|
||||||
|
|
||||||
|
//scheduled track is a boundary track
|
||||||
|
CcScheduleQuery::create()
|
||||||
|
->filterByDbInstanceId($this->id)
|
||||||
|
->filterByDbPlayoutStatus(0, Criteria::GREATER_EQUAL)
|
||||||
|
->filterByDbStarts($this->ends, Criteria::LESS_THAN)
|
||||||
|
->filterByDbEnds($this->ends, Criteria::GREATER_THAN)
|
||||||
|
->update(array('DbPlayoutStatus' => 2), $con);
|
||||||
|
|
||||||
|
//scheduled track is overbooked.
|
||||||
|
CcScheduleQuery::create()
|
||||||
|
->filterByDbInstanceId($this->id)
|
||||||
|
->filterByDbPlayoutStatus(0, Criteria::GREATER_EQUAL)
|
||||||
|
->filterByDbStarts($this->ends, Criteria::GREATER_THAN)
|
||||||
|
->update(array('DbPlayoutStatus' => 0), $con);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Computes the value of the aggregate column time_filled
|
||||||
|
*
|
||||||
|
* @param PropelPDO $con A connection object
|
||||||
|
*
|
||||||
|
* @return mixed The scalar result from the aggregate query
|
||||||
|
*/
|
||||||
|
public function computeDbTimeFilled(PropelPDO $con)
|
||||||
|
{
|
||||||
|
$stmt = $con->prepare('SELECT SUM(clip_length) FROM "cc_schedule" WHERE cc_schedule.INSTANCE_ID = :p1');
|
||||||
|
$stmt->bindValue(':p1', $this->getDbId());
|
||||||
|
$stmt->execute();
|
||||||
|
return $stmt->fetchColumn();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Updates the aggregate column time_filled
|
||||||
|
*
|
||||||
|
* @param PropelPDO $con A connection object
|
||||||
|
*/
|
||||||
|
public function updateDbTimeFilled(PropelPDO $con)
|
||||||
|
{
|
||||||
|
$this->setDbTimeFilled($this->computeDbTimeFilled($con));
|
||||||
|
$this->save($con);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function preInsert(PropelPDO $con = null) {
|
||||||
|
$now = new DateTime("now", new DateTimeZone("UTC"));
|
||||||
|
$this->setDbCreated($now);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
} // CcShowInstances
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_instances' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowInstancesPeer extends BaseCcShowInstancesPeer {
|
||||||
|
|
||||||
|
} // CcShowInstancesPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_instances' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowInstancesQuery extends BaseCcShowInstancesQuery {
|
||||||
|
|
||||||
|
} // CcShowInstancesQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowPeer extends BaseCcShowPeer {
|
||||||
|
|
||||||
|
} // CcShowPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowQuery extends BaseCcShowQuery {
|
||||||
|
|
||||||
|
} // CcShowQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_show_rebroadcast' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowRebroadcast extends BaseCcShowRebroadcast {
|
||||||
|
|
||||||
|
} // CcShowRebroadcast
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_rebroadcast' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowRebroadcastPeer extends BaseCcShowRebroadcastPeer {
|
||||||
|
|
||||||
|
} // CcShowRebroadcastPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_rebroadcast' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowRebroadcastQuery extends BaseCcShowRebroadcastQuery {
|
||||||
|
|
||||||
|
} // CcShowRebroadcastQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_show_schedule' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowSchedule extends BaseCcShowSchedule {
|
||||||
|
|
||||||
|
} // CcShowSchedule
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_schedule' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowSchedulePeer extends BaseCcShowSchedulePeer {
|
||||||
|
|
||||||
|
} // CcShowSchedulePeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_show_schedule' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcShowScheduleQuery extends BaseCcShowScheduleQuery {
|
||||||
|
|
||||||
|
} // CcShowScheduleQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_smemb' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSmemb extends BaseCcSmemb {
|
||||||
|
|
||||||
|
} // CcSmemb
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_smemb' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSmembPeer extends BaseCcSmembPeer {
|
||||||
|
|
||||||
|
} // CcSmembPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_smemb' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSmembQuery extends BaseCcSmembQuery {
|
||||||
|
|
||||||
|
} // CcSmembQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_stream_setting' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcStreamSetting extends BaseCcStreamSetting {
|
||||||
|
|
||||||
|
} // CcStreamSetting
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_stream_setting' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcStreamSettingPeer extends BaseCcStreamSettingPeer {
|
||||||
|
|
||||||
|
} // CcStreamSettingPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_stream_setting' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcStreamSettingQuery extends BaseCcStreamSettingQuery {
|
||||||
|
|
||||||
|
} // CcStreamSettingQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_subjs' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSubjs extends BaseCcSubjs {
|
||||||
|
|
||||||
|
} // CcSubjs
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_subjs' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSubjsPeer extends BaseCcSubjsPeer {
|
||||||
|
|
||||||
|
} // CcSubjsPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_subjs' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSubjsQuery extends BaseCcSubjsQuery {
|
||||||
|
|
||||||
|
} // CcSubjsQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_subjs_token' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSubjsToken extends BaseCcSubjsToken {
|
||||||
|
|
||||||
|
} // CcSubjsToken
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_subjs_token' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSubjsTokenPeer extends BaseCcSubjsTokenPeer {
|
||||||
|
|
||||||
|
} // CcSubjsTokenPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_subjs_token' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcSubjsTokenQuery extends BaseCcSubjsTokenQuery {
|
||||||
|
|
||||||
|
} // CcSubjsTokenQuery
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for representing a row from the 'cc_trans' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcTrans extends BaseCcTrans {
|
||||||
|
|
||||||
|
} // CcTrans
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_trans' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcTransPeer extends BaseCcTransPeer {
|
||||||
|
|
||||||
|
} // CcTransPeer
|
|
@ -0,0 +1,18 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Skeleton subclass for performing query and update operations on the 'cc_trans' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* You should add additional methods to this class to meet the
|
||||||
|
* application requirements. This class will only be generated as
|
||||||
|
* long as it does not already exist in the output directory.
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime
|
||||||
|
*/
|
||||||
|
class CcTransQuery extends BaseCcTransQuery {
|
||||||
|
|
||||||
|
} // CcTransQuery
|
|
@ -0,0 +1,19 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
class Common {
|
||||||
|
|
||||||
|
public static function setTimeInSub($row, $col, $time)
|
||||||
|
{
|
||||||
|
$class = get_class($row).'Peer';
|
||||||
|
|
||||||
|
$con = Propel::getConnection($class::DATABASE_NAME);
|
||||||
|
|
||||||
|
$sql = 'UPDATE '.$class::TABLE_NAME
|
||||||
|
. ' SET '.$col.' = :f1'
|
||||||
|
. ' WHERE ' .$class::ID. ' = :p1';
|
||||||
|
$stmt = $con->prepare($sql);
|
||||||
|
$stmt->bindValue(':f1', $time);
|
||||||
|
$stmt->bindValue(':p1', $row->getDbId());
|
||||||
|
$stmt->execute();
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,61 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_access' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcAccessTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcAccessTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_access');
|
||||||
|
$this->setPhpName('CcAccess');
|
||||||
|
$this->setClassname('CcAccess');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_access_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
|
||||||
|
$this->addColumn('GUNID', 'Gunid', 'CHAR', false, 32, null);
|
||||||
|
$this->addColumn('TOKEN', 'Token', 'BIGINT', false, null, null);
|
||||||
|
$this->addColumn('CHSUM', 'Chsum', 'CHAR', true, 32, '');
|
||||||
|
$this->addColumn('EXT', 'Ext', 'VARCHAR', true, 128, '');
|
||||||
|
$this->addColumn('TYPE', 'Type', 'VARCHAR', true, 20, '');
|
||||||
|
$this->addColumn('PARENT', 'Parent', 'BIGINT', false, null, null);
|
||||||
|
$this->addForeignKey('OWNER', 'Owner', 'INTEGER', 'cc_subjs', 'ID', false, null, null);
|
||||||
|
$this->addColumn('TS', 'Ts', 'TIMESTAMP', false, null, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcSubjs', 'CcSubjs', RelationMap::MANY_TO_ONE, array('owner' => 'id', ), null, null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcAccessTableMap
|
|
@ -0,0 +1,55 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_backup' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcBackupTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcBackupTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_backup');
|
||||||
|
$this->setPhpName('CcBackup');
|
||||||
|
$this->setClassname('CcBackup');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(false);
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('TOKEN', 'Token', 'VARCHAR', true, 64, null);
|
||||||
|
$this->addColumn('SESSIONID', 'Sessionid', 'VARCHAR', true, 64, null);
|
||||||
|
$this->addColumn('STATUS', 'Status', 'VARCHAR', true, 32, null);
|
||||||
|
$this->addColumn('FROMTIME', 'Fromtime', 'TIMESTAMP', true, null, null);
|
||||||
|
$this->addColumn('TOTIME', 'Totime', 'TIMESTAMP', true, null, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcBackupTableMap
|
|
@ -0,0 +1,52 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_country' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcCountryTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcCountryTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_country');
|
||||||
|
$this->setPhpName('CcCountry');
|
||||||
|
$this->setClassname('CcCountry');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(false);
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ISOCODE', 'DbIsoCode', 'CHAR', true, 3, null);
|
||||||
|
$this->addColumn('NAME', 'DbName', 'VARCHAR', true, 255, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcCountryTableMap
|
|
@ -0,0 +1,118 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_files' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcFilesTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcFilesTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_files');
|
||||||
|
$this->setPhpName('CcFiles');
|
||||||
|
$this->setClassname('CcFiles');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_files_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'DbId', 'INTEGER', true, null, null);
|
||||||
|
$this->addColumn('GUNID', 'DbGunid', 'CHAR', true, 32, null);
|
||||||
|
$this->addColumn('NAME', 'DbName', 'VARCHAR', true, 255, '');
|
||||||
|
$this->addColumn('MIME', 'DbMime', 'VARCHAR', true, 255, '');
|
||||||
|
$this->addColumn('FTYPE', 'DbFtype', 'VARCHAR', true, 128, '');
|
||||||
|
$this->addForeignKey('DIRECTORY', 'DbDirectory', 'INTEGER', 'cc_music_dirs', 'ID', false, null, null);
|
||||||
|
$this->addColumn('FILEPATH', 'DbFilepath', 'LONGVARCHAR', false, null, '');
|
||||||
|
$this->addColumn('STATE', 'DbState', 'VARCHAR', true, 128, 'empty');
|
||||||
|
$this->addColumn('CURRENTLYACCESSING', 'DbCurrentlyaccessing', 'INTEGER', true, null, 0);
|
||||||
|
$this->addForeignKey('EDITEDBY', 'DbEditedby', 'INTEGER', 'cc_subjs', 'ID', false, null, null);
|
||||||
|
$this->addColumn('MTIME', 'DbMtime', 'TIMESTAMP', false, 6, null);
|
||||||
|
$this->addColumn('UTIME', 'DbUtime', 'TIMESTAMP', false, 6, null);
|
||||||
|
$this->addColumn('LPTIME', 'DbLPtime', 'TIMESTAMP', false, 6, null);
|
||||||
|
$this->addColumn('MD5', 'DbMd5', 'CHAR', false, 32, null);
|
||||||
|
$this->addColumn('TRACK_TITLE', 'DbTrackTitle', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('ARTIST_NAME', 'DbArtistName', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('BIT_RATE', 'DbBitRate', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('SAMPLE_RATE', 'DbSampleRate', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('FORMAT', 'DbFormat', 'VARCHAR', false, 128, null);
|
||||||
|
$this->addColumn('LENGTH', 'DbLength', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('ALBUM_TITLE', 'DbAlbumTitle', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('GENRE', 'DbGenre', 'VARCHAR', false, 64, null);
|
||||||
|
$this->addColumn('COMMENTS', 'DbComments', 'LONGVARCHAR', false, null, null);
|
||||||
|
$this->addColumn('YEAR', 'DbYear', 'VARCHAR', false, 16, null);
|
||||||
|
$this->addColumn('TRACK_NUMBER', 'DbTrackNumber', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('CHANNELS', 'DbChannels', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('URL', 'DbUrl', 'VARCHAR', false, 1024, null);
|
||||||
|
$this->addColumn('BPM', 'DbBpm', 'VARCHAR', false, 8, null);
|
||||||
|
$this->addColumn('RATING', 'DbRating', 'VARCHAR', false, 8, null);
|
||||||
|
$this->addColumn('ENCODED_BY', 'DbEncodedBy', 'VARCHAR', false, 255, null);
|
||||||
|
$this->addColumn('DISC_NUMBER', 'DbDiscNumber', 'VARCHAR', false, 8, null);
|
||||||
|
$this->addColumn('MOOD', 'DbMood', 'VARCHAR', false, 64, null);
|
||||||
|
$this->addColumn('LABEL', 'DbLabel', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('COMPOSER', 'DbComposer', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('ENCODER', 'DbEncoder', 'VARCHAR', false, 64, null);
|
||||||
|
$this->addColumn('CHECKSUM', 'DbChecksum', 'VARCHAR', false, 256, null);
|
||||||
|
$this->addColumn('LYRICS', 'DbLyrics', 'LONGVARCHAR', false, null, null);
|
||||||
|
$this->addColumn('ORCHESTRA', 'DbOrchestra', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('CONDUCTOR', 'DbConductor', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('LYRICIST', 'DbLyricist', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('ORIGINAL_LYRICIST', 'DbOriginalLyricist', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('RADIO_STATION_NAME', 'DbRadioStationName', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('INFO_URL', 'DbInfoUrl', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('ARTIST_URL', 'DbArtistUrl', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('AUDIO_SOURCE_URL', 'DbAudioSourceUrl', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('RADIO_STATION_URL', 'DbRadioStationUrl', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('BUY_THIS_URL', 'DbBuyThisUrl', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('ISRC_NUMBER', 'DbIsrcNumber', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('CATALOG_NUMBER', 'DbCatalogNumber', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('ORIGINAL_ARTIST', 'DbOriginalArtist', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('COPYRIGHT', 'DbCopyright', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('REPORT_DATETIME', 'DbReportDatetime', 'VARCHAR', false, 32, null);
|
||||||
|
$this->addColumn('REPORT_LOCATION', 'DbReportLocation', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('REPORT_ORGANIZATION', 'DbReportOrganization', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('SUBJECT', 'DbSubject', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('CONTRIBUTOR', 'DbContributor', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('LANGUAGE', 'DbLanguage', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('FILE_EXISTS', 'DbFileExists', 'BOOLEAN', false, null, true);
|
||||||
|
$this->addColumn('SOUNDCLOUD_ID', 'DbSoundcloudId', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('SOUNDCLOUD_ERROR_CODE', 'DbSoundcloudErrorCode', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('SOUNDCLOUD_ERROR_MSG', 'DbSoundcloudErrorMsg', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('SOUNDCLOUD_LINK_TO_FILE', 'DbSoundcloudLinkToFile', 'VARCHAR', false, 4096, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcSubjs', 'CcSubjs', RelationMap::MANY_TO_ONE, array('editedby' => 'id', ), null, null);
|
||||||
|
$this->addRelation('CcMusicDirs', 'CcMusicDirs', RelationMap::MANY_TO_ONE, array('directory' => 'id', ), null, null);
|
||||||
|
$this->addRelation('CcShowInstances', 'CcShowInstances', RelationMap::ONE_TO_MANY, array('id' => 'file_id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcPlaylistcontents', 'CcPlaylistcontents', RelationMap::ONE_TO_MANY, array('id' => 'file_id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcSchedule', 'CcSchedule', RelationMap::ONE_TO_MANY, array('id' => 'file_id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcFilesTableMap
|
|
@ -0,0 +1,52 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_login_attempts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcLoginAttemptsTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcLoginAttemptsTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_login_attempts');
|
||||||
|
$this->setPhpName('CcLoginAttempts');
|
||||||
|
$this->setClassname('CcLoginAttempts');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(false);
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('IP', 'DbIP', 'VARCHAR', true, 32, null);
|
||||||
|
$this->addColumn('ATTEMPTS', 'DbAttempts', 'INTEGER', false, null, 0);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcLoginAttemptsTableMap
|
|
@ -0,0 +1,57 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_music_dirs' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcMusicDirsTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcMusicDirsTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_music_dirs');
|
||||||
|
$this->setPhpName('CcMusicDirs');
|
||||||
|
$this->setClassname('CcMusicDirs');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_music_dirs_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
|
||||||
|
$this->addColumn('DIRECTORY', 'Directory', 'LONGVARCHAR', false, null, null);
|
||||||
|
$this->addColumn('TYPE', 'Type', 'VARCHAR', false, 255, null);
|
||||||
|
$this->addColumn('EXISTS', 'Exists', 'BOOLEAN', false, null, true);
|
||||||
|
$this->addColumn('WATCHED', 'Watched', 'BOOLEAN', false, null, true);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcFiles', 'CcFiles', RelationMap::ONE_TO_MANY, array('id' => 'directory', ), null, null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcMusicDirsTableMap
|
|
@ -0,0 +1,56 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_perms' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcPermsTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcPermsTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_perms');
|
||||||
|
$this->setPhpName('CcPerms');
|
||||||
|
$this->setClassname('CcPerms');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(false);
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('PERMID', 'Permid', 'INTEGER', true, null, null);
|
||||||
|
$this->addForeignKey('SUBJ', 'Subj', 'INTEGER', 'cc_subjs', 'ID', false, null, null);
|
||||||
|
$this->addColumn('ACTION', 'Action', 'VARCHAR', false, 20, null);
|
||||||
|
$this->addColumn('OBJ', 'Obj', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('TYPE', 'Type', 'CHAR', false, 1, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcSubjs', 'CcSubjs', RelationMap::MANY_TO_ONE, array('subj' => 'id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcPermsTableMap
|
|
@ -0,0 +1,73 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_playlist' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcPlaylistTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcPlaylistTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_playlist');
|
||||||
|
$this->setPhpName('CcPlaylist');
|
||||||
|
$this->setClassname('CcPlaylist');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_playlist_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'DbId', 'INTEGER', true, null, null);
|
||||||
|
$this->addColumn('NAME', 'DbName', 'VARCHAR', true, 255, '');
|
||||||
|
$this->addColumn('MTIME', 'DbMtime', 'TIMESTAMP', false, 6, null);
|
||||||
|
$this->addColumn('UTIME', 'DbUtime', 'TIMESTAMP', false, 6, null);
|
||||||
|
$this->addForeignKey('CREATOR_ID', 'DbCreatorId', 'INTEGER', 'cc_subjs', 'ID', false, null, null);
|
||||||
|
$this->addColumn('DESCRIPTION', 'DbDescription', 'VARCHAR', false, 512, null);
|
||||||
|
$this->addColumn('LENGTH', 'DbLength', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcSubjs', 'CcSubjs', RelationMap::MANY_TO_ONE, array('creator_id' => 'id', ), null, null);
|
||||||
|
$this->addRelation('CcPlaylistcontents', 'CcPlaylistcontents', RelationMap::ONE_TO_MANY, array('id' => 'playlist_id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Gets the list of behaviors registered for this table
|
||||||
|
*
|
||||||
|
* @return array Associative array (name => parameters) of behaviors
|
||||||
|
*/
|
||||||
|
public function getBehaviors()
|
||||||
|
{
|
||||||
|
return array(
|
||||||
|
'aggregate_column' => array('name' => 'length', 'expression' => 'SUM(cliplength)', 'foreign_table' => 'cc_playlistcontents', ),
|
||||||
|
);
|
||||||
|
} // getBehaviors()
|
||||||
|
|
||||||
|
} // CcPlaylistTableMap
|
|
@ -0,0 +1,75 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_playlistcontents' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcPlaylistcontentsTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcPlaylistcontentsTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_playlistcontents');
|
||||||
|
$this->setPhpName('CcPlaylistcontents');
|
||||||
|
$this->setClassname('CcPlaylistcontents');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_playlistcontents_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'DbId', 'INTEGER', true, null, null);
|
||||||
|
$this->addForeignKey('PLAYLIST_ID', 'DbPlaylistId', 'INTEGER', 'cc_playlist', 'ID', false, null, null);
|
||||||
|
$this->addForeignKey('FILE_ID', 'DbFileId', 'INTEGER', 'cc_files', 'ID', false, null, null);
|
||||||
|
$this->addColumn('POSITION', 'DbPosition', 'INTEGER', false, null, null);
|
||||||
|
$this->addColumn('CLIPLENGTH', 'DbCliplength', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('CUEIN', 'DbCuein', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('CUEOUT', 'DbCueout', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('FADEIN', 'DbFadein', 'TIME', false, null, '00:00:00');
|
||||||
|
$this->addColumn('FADEOUT', 'DbFadeout', 'TIME', false, null, '00:00:00');
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcFiles', 'CcFiles', RelationMap::MANY_TO_ONE, array('file_id' => 'id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcPlaylist', 'CcPlaylist', RelationMap::MANY_TO_ONE, array('playlist_id' => 'id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* Gets the list of behaviors registered for this table
|
||||||
|
*
|
||||||
|
* @return array Associative array (name => parameters) of behaviors
|
||||||
|
*/
|
||||||
|
public function getBehaviors()
|
||||||
|
{
|
||||||
|
return array(
|
||||||
|
'aggregate_column_relation' => array('foreign_table' => 'cc_playlist', 'update_method' => 'updateDbLength', ),
|
||||||
|
);
|
||||||
|
} // getBehaviors()
|
||||||
|
|
||||||
|
} // CcPlaylistcontentsTableMap
|
|
@ -0,0 +1,56 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_pref' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcPrefTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcPrefTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_pref');
|
||||||
|
$this->setPhpName('CcPref');
|
||||||
|
$this->setClassname('CcPref');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_pref_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'Id', 'INTEGER', true, null, null);
|
||||||
|
$this->addForeignKey('SUBJID', 'Subjid', 'INTEGER', 'cc_subjs', 'ID', false, null, null);
|
||||||
|
$this->addColumn('KEYSTR', 'Keystr', 'VARCHAR', false, 255, null);
|
||||||
|
$this->addColumn('VALSTR', 'Valstr', 'LONGVARCHAR', false, null, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcSubjs', 'CcSubjs', RelationMap::MANY_TO_ONE, array('subjid' => 'id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcPrefTableMap
|
|
@ -0,0 +1,65 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_schedule' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcScheduleTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcScheduleTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_schedule');
|
||||||
|
$this->setPhpName('CcSchedule');
|
||||||
|
$this->setClassname('CcSchedule');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_schedule_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'DbId', 'INTEGER', true, null, null);
|
||||||
|
$this->addColumn('STARTS', 'DbStarts', 'TIMESTAMP', true, null, null);
|
||||||
|
$this->addColumn('ENDS', 'DbEnds', 'TIMESTAMP', true, null, null);
|
||||||
|
$this->addForeignKey('FILE_ID', 'DbFileId', 'INTEGER', 'cc_files', 'ID', false, null, null);
|
||||||
|
$this->addColumn('CLIP_LENGTH', 'DbClipLength', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('FADE_IN', 'DbFadeIn', 'TIME', false, null, '00:00:00');
|
||||||
|
$this->addColumn('FADE_OUT', 'DbFadeOut', 'TIME', false, null, '00:00:00');
|
||||||
|
$this->addColumn('CUE_IN', 'DbCueIn', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('CUE_OUT', 'DbCueOut', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('MEDIA_ITEM_PLAYED', 'DbMediaItemPlayed', 'BOOLEAN', false, null, false);
|
||||||
|
$this->addForeignKey('INSTANCE_ID', 'DbInstanceId', 'INTEGER', 'cc_show_instances', 'ID', true, null, null);
|
||||||
|
$this->addColumn('PLAYOUT_STATUS', 'DbPlayoutStatus', 'SMALLINT', true, null, 1);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcShowInstances', 'CcShowInstances', RelationMap::MANY_TO_ONE, array('instance_id' => 'id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcFiles', 'CcFiles', RelationMap::MANY_TO_ONE, array('file_id' => 'id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcScheduleTableMap
|
|
@ -0,0 +1,52 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_service_register' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcServiceRegisterTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcServiceRegisterTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_service_register');
|
||||||
|
$this->setPhpName('CcServiceRegister');
|
||||||
|
$this->setClassname('CcServiceRegister');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(false);
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('NAME', 'DbName', 'VARCHAR', true, 32, null);
|
||||||
|
$this->addColumn('IP', 'DbIp', 'VARCHAR', true, 18, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcServiceRegisterTableMap
|
|
@ -0,0 +1,55 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_sess' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcSessTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcSessTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_sess');
|
||||||
|
$this->setPhpName('CcSess');
|
||||||
|
$this->setClassname('CcSess');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(false);
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('SESSID', 'Sessid', 'CHAR', true, 32, null);
|
||||||
|
$this->addForeignKey('USERID', 'Userid', 'INTEGER', 'cc_subjs', 'ID', false, null, null);
|
||||||
|
$this->addColumn('LOGIN', 'Login', 'VARCHAR', false, 255, null);
|
||||||
|
$this->addColumn('TS', 'Ts', 'TIMESTAMP', false, null, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcSubjs', 'CcSubjs', RelationMap::MANY_TO_ONE, array('userid' => 'id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcSessTableMap
|
|
@ -0,0 +1,63 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_show_days' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcShowDaysTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcShowDaysTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_show_days');
|
||||||
|
$this->setPhpName('CcShowDays');
|
||||||
|
$this->setClassname('CcShowDays');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_show_days_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'DbId', 'INTEGER', true, null, null);
|
||||||
|
$this->addColumn('FIRST_SHOW', 'DbFirstShow', 'DATE', true, null, null);
|
||||||
|
$this->addColumn('LAST_SHOW', 'DbLastShow', 'DATE', false, null, null);
|
||||||
|
$this->addColumn('START_TIME', 'DbStartTime', 'TIME', true, null, null);
|
||||||
|
$this->addColumn('TIMEZONE', 'DbTimezone', 'VARCHAR', true, 255, null);
|
||||||
|
$this->addColumn('DURATION', 'DbDuration', 'VARCHAR', true, 255, null);
|
||||||
|
$this->addColumn('DAY', 'DbDay', 'TINYINT', false, null, null);
|
||||||
|
$this->addColumn('REPEAT_TYPE', 'DbRepeatType', 'TINYINT', true, null, null);
|
||||||
|
$this->addColumn('NEXT_POP_DATE', 'DbNextPopDate', 'DATE', false, null, null);
|
||||||
|
$this->addForeignKey('SHOW_ID', 'DbShowId', 'INTEGER', 'cc_show', 'ID', true, null, null);
|
||||||
|
$this->addColumn('RECORD', 'DbRecord', 'TINYINT', false, null, 0);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcShow', 'CcShow', RelationMap::MANY_TO_ONE, array('show_id' => 'id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcShowDaysTableMap
|
|
@ -0,0 +1,56 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_show_hosts' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcShowHostsTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcShowHostsTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_show_hosts');
|
||||||
|
$this->setPhpName('CcShowHosts');
|
||||||
|
$this->setClassname('CcShowHosts');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_show_hosts_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'DbId', 'INTEGER', true, null, null);
|
||||||
|
$this->addForeignKey('SHOW_ID', 'DbShow', 'INTEGER', 'cc_show', 'ID', true, null, null);
|
||||||
|
$this->addForeignKey('SUBJS_ID', 'DbHost', 'INTEGER', 'cc_subjs', 'ID', true, null, null);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcShow', 'CcShow', RelationMap::MANY_TO_ONE, array('show_id' => 'id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcSubjs', 'CcSubjs', RelationMap::MANY_TO_ONE, array('subjs_id' => 'id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcShowHostsTableMap
|
|
@ -0,0 +1,68 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class defines the structure of the 'cc_show_instances' table.
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* This map class is used by Propel to do runtime db structure discovery.
|
||||||
|
* For example, the createSelectSql() method checks the type of a given column used in an
|
||||||
|
* ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
|
||||||
|
* (i.e. if it's a text column type).
|
||||||
|
*
|
||||||
|
* @package propel.generator.airtime.map
|
||||||
|
*/
|
||||||
|
class CcShowInstancesTableMap extends TableMap {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The (dot-path) name of this class
|
||||||
|
*/
|
||||||
|
const CLASS_NAME = 'airtime.map.CcShowInstancesTableMap';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Initialize the table attributes, columns and validators
|
||||||
|
* Relations are not initialized by this method since they are lazy loaded
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
|
* @throws PropelException
|
||||||
|
*/
|
||||||
|
public function initialize()
|
||||||
|
{
|
||||||
|
// attributes
|
||||||
|
$this->setName('cc_show_instances');
|
||||||
|
$this->setPhpName('CcShowInstances');
|
||||||
|
$this->setClassname('CcShowInstances');
|
||||||
|
$this->setPackage('airtime');
|
||||||
|
$this->setUseIdGenerator(true);
|
||||||
|
$this->setPrimaryKeyMethodInfo('cc_show_instances_id_seq');
|
||||||
|
// columns
|
||||||
|
$this->addPrimaryKey('ID', 'DbId', 'INTEGER', true, null, null);
|
||||||
|
$this->addColumn('STARTS', 'DbStarts', 'TIMESTAMP', true, null, null);
|
||||||
|
$this->addColumn('ENDS', 'DbEnds', 'TIMESTAMP', true, null, null);
|
||||||
|
$this->addForeignKey('SHOW_ID', 'DbShowId', 'INTEGER', 'cc_show', 'ID', true, null, null);
|
||||||
|
$this->addColumn('RECORD', 'DbRecord', 'TINYINT', false, null, 0);
|
||||||
|
$this->addColumn('REBROADCAST', 'DbRebroadcast', 'TINYINT', false, null, 0);
|
||||||
|
$this->addForeignKey('INSTANCE_ID', 'DbOriginalShow', 'INTEGER', 'cc_show_instances', 'ID', false, null, null);
|
||||||
|
$this->addForeignKey('FILE_ID', 'DbRecordedFile', 'INTEGER', 'cc_files', 'ID', false, null, null);
|
||||||
|
$this->addColumn('TIME_FILLED', 'DbTimeFilled', 'VARCHAR', false, null, '00:00:00');
|
||||||
|
$this->addColumn('CREATED', 'DbCreated', 'TIMESTAMP', true, null, null);
|
||||||
|
$this->addColumn('LAST_SCHEDULED', 'DbLastScheduled', 'TIMESTAMP', false, null, null);
|
||||||
|
$this->addColumn('MODIFIED_INSTANCE', 'DbModifiedInstance', 'BOOLEAN', true, null, false);
|
||||||
|
// validators
|
||||||
|
} // initialize()
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Build the RelationMap objects for this table relationships
|
||||||
|
*/
|
||||||
|
public function buildRelations()
|
||||||
|
{
|
||||||
|
$this->addRelation('CcShow', 'CcShow', RelationMap::MANY_TO_ONE, array('show_id' => 'id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcShowInstancesRelatedByDbOriginalShow', 'CcShowInstances', RelationMap::MANY_TO_ONE, array('instance_id' => 'id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcFiles', 'CcFiles', RelationMap::MANY_TO_ONE, array('file_id' => 'id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcShowInstancesRelatedByDbId', 'CcShowInstances', RelationMap::ONE_TO_MANY, array('id' => 'instance_id', ), 'CASCADE', null);
|
||||||
|
$this->addRelation('CcSchedule', 'CcSchedule', RelationMap::ONE_TO_MANY, array('id' => 'instance_id', ), 'CASCADE', null);
|
||||||
|
} // buildRelations()
|
||||||
|
|
||||||
|
} // CcShowInstancesTableMap
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue