public function __construct(Application $app) { parent::__construct($app, __CLASS__); $this->watchdog = \Config::get('watchdog_timeout') * 2; $this->userFields[] = "((UNIX_TIMESTAMP() - UNIX_TIMESTAMP(`keep_alive`)) <= {$this->watchdog}) as state"; $this->allStatus = array(array('id' => 1, 'title' => $this->setlocalization('on')), array('id' => 2, 'title' => $this->setlocalization('off'))); if (empty($this->app['reseller'])) { $this->userFields[] = "reseller.name as reseller_name"; } }
public function __construct(Application $app) { parent::__construct($app, __CLASS__); $this->watchdog = \Config::get('watchdog_timeout') * 2; $this->userFields[] = "((UNIX_TIMESTAMP() - UNIX_TIMESTAMP(`keep_alive`)) <= {$this->watchdog}) as `state`"; $this->allStatus = array(array('id' => 1, 'title' => $this->setlocalization('on')), array('id' => 2, 'title' => $this->setlocalization('off'))); $this->formEvent = array(array("id" => "send_msg", "title" => $this->setlocalization('Sending a message')), array("id" => "reboot", "title" => $this->setlocalization('Reboot')), array("id" => "reload_portal", "title" => $this->setlocalization('Restart the portal')), array("id" => "update_channels", "title" => $this->setlocalization('Update channel list')), array("id" => "play_channel", "title" => $this->setlocalization('Playback channel')), array("id" => "play_radio_channel", "title" => $this->setlocalization('Playback radio channel')), array("id" => "mount_all_storages", "title" => $this->setlocalization('Mount all storages')), array("id" => "cut_off", "title" => $this->setlocalization('Turn off')), array("id" => "update_image", "title" => $this->setlocalization('Image update'))); $this->hiddenEvent = array(array("id" => "update_epg", "title" => $this->setlocalization('EPG update')), array("id" => "update_subscription", "title" => $this->setlocalization('Subscribe update')), array("id" => "update_modules", "title" => $this->setlocalization('Modules update')), array("id" => "cut_on", "title" => $this->setlocalization('Turn on')), array("id" => "show_menu", "title" => $this->setlocalization('Show menu')), array("id" => "additional_services_status", "title" => $this->setlocalization('Status additional service'))); if (empty($this->app['reseller'])) { $this->userFields[] = "reseller.name as `reseller_name`"; } }
public function __construct(Application $app) { parent::__construct($app, __CLASS__); $this->formEvent = array(array("id" => "send_msg", "title" => $this->setlocalization('Sending a message')), array("id" => "reboot", "title" => $this->setlocalization('Reboot')), array("id" => "reload_portal", "title" => $this->setlocalization('Restart the portal')), array("id" => "update_channels", "title" => $this->setlocalization('Update channel list')), array("id" => "play_channel", "title" => $this->setlocalization('Playback channel')), array("id" => "play_radio_channel", "title" => $this->setlocalization('Playback radio channel')), array("id" => "mount_all_storages", "title" => $this->setlocalization('Mount all storages')), array("id" => "cut_off", "title" => $this->setlocalization('Turn off')), array("id" => "update_image", "title" => $this->setlocalization('Image update'))); $this->hiddenEvent = array(array("id" => "update_epg", "title" => $this->setlocalization('EPG update')), array("id" => "update_subscription", "title" => $this->setlocalization('Subscribe update')), array("id" => "update_modules", "title" => $this->setlocalization('Modules update')), array("id" => "cut_on", "title" => $this->setlocalization('Turn on')), array("id" => "show_menu", "title" => $this->setlocalization('Show menu')), array("id" => "additional_services_status", "title" => $this->setlocalization('Status additional service'))); $this->sendedStatus = array(array("id" => 1, "title" => $this->setlocalization('Not delivered')), array("id" => 2, "title" => $this->setlocalization('Delivered'))); $this->receivingStatus = array(array("id" => 1, "title" => $this->setlocalization('Not received')), array("id" => 2, "title" => $this->setlocalization('Received'))); $this->scheduleType = array(array("id" => 1, "title" => $this->setlocalization('One-time event')), array("id" => 2, "title" => $this->setlocalization('For a period'))); $this->scheduleState = array(array("id" => 2, "title" => $this->setlocalization('Scheduled')), array("id" => 1, "title" => $this->setlocalization('Stopped'))); $this->repeatingInterval = array(array("id" => 1, "title" => $this->setlocalization('Year')), array("id" => 2, "title" => $this->setlocalization('Month')), array("id" => 3, "title" => $this->setlocalization('Week')), array("id" => 4, "title" => $this->setlocalization('Day'))); $this->monthNames = array(array("id" => 1, "title" => $this->setlocalization('January')), array("id" => 2, "title" => $this->setlocalization('February')), array("id" => 3, "title" => $this->setlocalization('March')), array("id" => 4, "title" => $this->setlocalization('April')), array("id" => 5, "title" => $this->setlocalization('May')), array("id" => 6, "title" => $this->setlocalization('June')), array("id" => 7, "title" => $this->setlocalization('July')), array("id" => 8, "title" => $this->setlocalization('August')), array("id" => 9, "title" => $this->setlocalization('September')), array("id" => 10, "title" => $this->setlocalization('October')), array("id" => 11, "title" => $this->setlocalization('November')), array("id" => 12, "title" => $this->setlocalization('December'))); $this->dayNames = array(array("id" => 1, "title" => $this->setlocalization('Mon')), array("id" => 2, "title" => $this->setlocalization('Tue')), array("id" => 3, "title" => $this->setlocalization('Wed')), array("id" => 4, "title" => $this->setlocalization('Thu')), array("id" => 5, "title" => $this->setlocalization('Fri')), array("id" => 6, "title" => $this->setlocalization('Sat')), array("id" => 7, "title" => $this->setlocalization('Sun'))); $this->app['defTTL'] = array('send_msg' => 7 * 24 * 3600, 'send_msg_with_video' => 7 * 24 * 3600, 'other' => \Config::get('watchdog_timeout') * 2); }
private function getLogoUriById($id = FALSE, $row = FALSE, $resolution = 320) { $channel = $row === FALSE ? $this->db->getChannelById($id) : $row; if (empty($channel['logo'])) { return ""; } return \Config::get('portal_url') . 'misc/logos/' . $resolution . '/' . $channel['logo']; }