2010-12-07 20:19:27 +01:00
|
|
|
<?php
|
2017-03-23 23:41:47 +01:00
|
|
|
/**
|
|
|
|
* Navigation container (config/array)
|
|
|
|
*
|
|
|
|
* Each element in the array will be passed to
|
|
|
|
* Zend_Navigation_Page::factory() when constructing
|
|
|
|
* the navigation container below.
|
|
|
|
*
|
|
|
|
* The class field is used to contain the icon rendered
|
|
|
|
* before the nav entry for i18n purposes. When this
|
|
|
|
* gets parsed the language is not yet set and the
|
|
|
|
* strings stay plain en for now. They get retranslated
|
|
|
|
* in the menu.phtml script when they are output.
|
|
|
|
*/
|
2017-02-23 12:03:25 +01:00
|
|
|
$pages = array();
|
|
|
|
$pages[] = array(
|
2017-03-23 23:41:47 +01:00
|
|
|
'label' => _('My Podcast'),
|
2017-02-23 12:03:25 +01:00
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'podcast',
|
|
|
|
'action' => 'station',
|
2017-03-23 23:41:47 +01:00
|
|
|
'resource' => 'podcast',
|
|
|
|
'class' => '<i class="icon-music icon-white"></i>'
|
2017-02-23 12:03:25 +01:00
|
|
|
);
|
|
|
|
$pages[] = array(
|
2017-03-23 23:41:47 +01:00
|
|
|
'label' => _('Radio Page'),
|
|
|
|
'uri' => '/',
|
|
|
|
'resource' => '',
|
|
|
|
'class' => '<i class="icon-globe icon-white"></i>',
|
2017-09-30 13:24:20 +02:00
|
|
|
'pages' => array(),
|
|
|
|
'visible' => false
|
2017-02-23 12:03:25 +01:00
|
|
|
);
|
|
|
|
$pages[] = array(
|
2017-03-23 23:41:47 +01:00
|
|
|
'label' => _('Calendar'),
|
2017-02-23 12:03:25 +01:00
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'schedule',
|
|
|
|
'action' => 'index',
|
2017-03-23 23:41:47 +01:00
|
|
|
'resource' => 'schedule',
|
|
|
|
'class' => '<i class="icon-calendar icon-white"></i>'
|
2017-02-23 12:03:25 +01:00
|
|
|
);
|
|
|
|
$pages[] = array(
|
2017-03-23 23:41:47 +01:00
|
|
|
'label' => _('Widgets'),
|
2017-02-23 12:03:25 +01:00
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'embeddablewidgets',
|
|
|
|
'action' => 'player',
|
|
|
|
'resource' => 'embeddablewidgets',
|
2017-03-23 23:41:47 +01:00
|
|
|
'class' => '<i class="icon-wrench icon-white"></i>',
|
2017-02-23 12:03:25 +01:00
|
|
|
'title' => 'Widgets',
|
|
|
|
'pages' => array(
|
|
|
|
array(
|
|
|
|
'label' => _('Player'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'embeddablewidgets',
|
|
|
|
'action' => 'player',
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('Weekly Schedule'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'embeddablewidgets',
|
|
|
|
'action' => 'schedule',
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('Facebook'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'embeddablewidgets',
|
|
|
|
'action' => 'facebook',
|
2015-08-17 18:46:32 +02:00
|
|
|
)
|
2017-02-23 12:03:25 +01:00
|
|
|
)
|
|
|
|
);
|
|
|
|
$pages[] = array(
|
2017-03-23 23:41:47 +01:00
|
|
|
'label' => _("Settings"),
|
2019-01-20 14:52:50 +01:00
|
|
|
'action' => 'edit-user',
|
2017-02-23 12:03:25 +01:00
|
|
|
'module' => 'default',
|
2019-01-20 14:52:50 +01:00
|
|
|
'controller' => 'user',
|
2017-03-23 23:41:47 +01:00
|
|
|
'class' => '<i class="icon-cog icon-white"></i>',
|
2017-02-23 12:03:25 +01:00
|
|
|
'title' => 'Settings',
|
|
|
|
'pages' => array(
|
|
|
|
array(
|
|
|
|
'label' => _('General'),
|
|
|
|
'module' => 'default',
|
2017-09-29 15:50:50 +02:00
|
|
|
'controller' => 'preference',
|
|
|
|
'resource' => 'preference'
|
2017-02-23 12:03:25 +01:00
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('My Profile'),
|
|
|
|
'controller' => 'user',
|
2019-01-20 14:52:50 +01:00
|
|
|
'action' => 'edit-user'
|
2017-02-23 12:03:25 +01:00
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('Users'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'user',
|
|
|
|
'action' => 'add-user',
|
2017-09-29 15:50:50 +02:00
|
|
|
'resource' => 'user'
|
2017-02-23 12:03:25 +01:00
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('Streams'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'preference',
|
2017-09-29 15:50:50 +02:00
|
|
|
'action' => 'stream-setting',
|
|
|
|
'resource' => 'preference'
|
2017-03-08 14:46:33 +01:00
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('Status'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'systemstatus',
|
|
|
|
'action' => 'index',
|
|
|
|
'resource' => 'systemstatus'
|
|
|
|
),
|
2017-02-23 12:03:25 +01:00
|
|
|
)
|
|
|
|
);
|
|
|
|
$pages[] = array(
|
2017-03-23 23:41:47 +01:00
|
|
|
'label' => _("Analytics"),
|
2017-02-23 12:03:25 +01:00
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'playouthistory',
|
|
|
|
'action' => 'index',
|
|
|
|
'resource' => 'playouthistory',
|
2017-03-23 23:41:47 +01:00
|
|
|
'class' => '<i class="icon-signal icon-white"></i>',
|
2017-02-23 12:03:25 +01:00
|
|
|
'title' => 'Analytics',
|
|
|
|
'pages' => array(
|
|
|
|
array(
|
|
|
|
'label' => _('Playout History'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'playouthistory',
|
|
|
|
'action' => 'index',
|
|
|
|
'resource' => 'playouthistory'
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('History Templates'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'playouthistorytemplate',
|
|
|
|
'action' => 'index',
|
|
|
|
'resource' => 'playouthistorytemplate'
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('Listener Stats'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'listenerstat',
|
|
|
|
'action' => 'index',
|
|
|
|
'resource' => 'listenerstat'
|
|
|
|
),
|
|
|
|
)
|
|
|
|
);
|
|
|
|
if (LIBRETIME_ENABLE_BILLING === true) {
|
|
|
|
$pages[] = array(
|
2015-10-27 20:01:34 +01:00
|
|
|
'label' => (Application_Model_Preference::GetPlanLevel()=="trial") ? "<i class='icon-star icon-orange'></i><span style='color: #ff5d1a'>"._('Upgrade')."</span>" : "<i class='icon-briefcase icon-white'></i>"._('Billing'),
|
2015-08-20 16:56:11 +02:00
|
|
|
'controller' => 'billing',
|
2015-08-26 15:16:06 +02:00
|
|
|
'action' => 'upgrade',
|
2015-08-20 16:56:11 +02:00
|
|
|
'resource' => 'billing',
|
|
|
|
'title' => 'Billing',
|
2015-08-17 22:15:26 +02:00
|
|
|
'pages' => array(
|
|
|
|
array(
|
2015-08-26 15:16:06 +02:00
|
|
|
'label' => _('Account Plans'),
|
2015-08-20 16:56:11 +02:00
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'billing',
|
2015-08-26 15:16:06 +02:00
|
|
|
'action' => 'upgrade',
|
2015-08-20 16:56:11 +02:00
|
|
|
'resource' => 'billing'
|
2015-08-17 22:15:26 +02:00
|
|
|
),
|
|
|
|
array(
|
2015-08-26 15:16:06 +02:00
|
|
|
'label' => _('Account Details'),
|
2015-08-20 16:56:11 +02:00
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'billing',
|
2015-08-26 15:16:06 +02:00
|
|
|
'action' => 'client',
|
2015-08-20 16:56:11 +02:00
|
|
|
'resource' => 'billing'
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('View Invoices'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'billing',
|
|
|
|
'action' => 'invoices',
|
|
|
|
'resource' => 'billing'
|
2015-08-17 22:15:26 +02:00
|
|
|
)
|
|
|
|
)
|
2017-02-23 12:03:25 +01:00
|
|
|
);
|
|
|
|
}
|
|
|
|
$pages[] = array(
|
2017-03-23 23:41:47 +01:00
|
|
|
'label' => _('Help'),
|
2017-02-23 12:03:25 +01:00
|
|
|
'controller' => 'dashboard',
|
|
|
|
'action' => 'help',
|
2017-03-23 23:41:47 +01:00
|
|
|
'resource' => 'dashboard',
|
|
|
|
'class' => '<i class="icon-question-sign icon-white"></i>',
|
|
|
|
'title' => 'Help',
|
2017-02-23 12:03:25 +01:00
|
|
|
'pages' => array(
|
|
|
|
array(
|
|
|
|
'label' => _('Getting Started'),
|
|
|
|
'module' => 'default',
|
|
|
|
'controller' => 'dashboard',
|
|
|
|
'action' => 'help',
|
|
|
|
'resource' => 'dashboard'
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('FAQ'),
|
|
|
|
'uri' => FAQ_URL,
|
|
|
|
'target' => "_blank"
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('User Manual'),
|
|
|
|
'uri' => USER_MANUAL_URL,
|
|
|
|
'target' => "_blank"
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('File a Support Ticket'),
|
|
|
|
'uri' => SUPPORT_TICKET_URL,
|
|
|
|
'target' => "_blank"
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _(sprintf("Help Translate %s", PRODUCT_NAME)),
|
|
|
|
'uri' => AIRTIME_TRANSIFEX_URL,
|
|
|
|
'target' => "_blank"
|
|
|
|
),
|
|
|
|
array(
|
|
|
|
'label' => _('What\'s New?'),
|
2017-03-08 16:26:18 +01:00
|
|
|
'uri' => LIBRETIME_WHATS_NEW_URL,
|
2017-02-23 12:03:25 +01:00
|
|
|
'target' => "_blank"
|
2011-08-31 00:00:03 +02:00
|
|
|
)
|
2017-02-23 12:03:25 +01:00
|
|
|
)
|
2010-12-07 20:19:27 +01:00
|
|
|
);
|
2011-02-04 01:17:52 +01:00
|
|
|
|
2011-03-24 20:05:49 +01:00
|
|
|
|
2010-12-07 20:19:27 +01:00
|
|
|
// Create container from array
|
|
|
|
$container = new Zend_Navigation($pages);
|
2011-01-27 00:31:59 +01:00
|
|
|
$container->id = "nav";
|
2011-03-24 20:05:49 +01:00
|
|
|
|
2010-12-07 20:19:27 +01:00
|
|
|
//store it in the registry:
|
2017-09-29 15:50:50 +02:00
|
|
|
Zend_Registry::set('Zend_Navigation', $container);
|