public function displayPage() { $db =& $this->db; // Default options if (Kit::IsFilterPinned('mediamanager', 'Filter')) { $filter_pinned = 1; $filter_layout_name = Session::Get('mediamanager', 'filter_layout_name'); $filter_region_name = Session::Get('mediamanager', 'filter_region_name'); $filter_media_name = Session::Get('mediamanager', 'filter_media_name'); $filter_type = Session::Get('mediamanager', 'filter_type'); } else { $filter_pinned = 0; $filter_layout_name = NULL; $filter_region_name = NULL; $filter_media_name = NULL; $filter_type = 0; } $id = uniqid(); Theme::Set('id', $id); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); Theme::Set('form_meta', '<input type="hidden" name="p" value="mediamanager"><input type="hidden" name="q" value="MediaManagerGrid">'); $formFields = array(); $formFields[] = FormManager::AddText('filter_layout_name', __('Layout'), $filter_layout_name, NULL, 'l'); $formFields[] = FormManager::AddText('filter_region_name', __('Region'), $filter_region_name, NULL, 'r'); $formFields[] = FormManager::AddText('filter_media_name', __('Media'), $filter_media_name, NULL, 'm'); $types = $db->GetArray("SELECT moduleid AS moduleid, Name AS module FROM `module` WHERE Enabled = 1 ORDER BY 2"); array_unshift($types, array('moduleid' => 0, 'module' => 'All')); $formFields[] = FormManager::AddCombo('filter_type', __('Type'), $filter_type, $types, 'moduleid', 'module', NULL, 't'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $filter_pinned, NULL, 'k'); // Call to render the template Theme::Set('header_text', __('Media Manager')); Theme::Set('form_fields', $formFields); Theme::Render('grid_render'); }
public function displayPage() { $subpage = Kit::GetParam('sp', _GET, _WORD, ''); // Configure the theme $id = uniqid(); // Different pages for data entry and admin if ($subpage == 'DataEntry') { Theme::Set('id', 'DataEntryGrid'); $dataSetId = Kit::GetParam('datasetid', _GET, _INT); $dataSet = Kit::GetParam('dataset', _GET, _STRING); Theme::Set('form_meta', '<input type="hidden" name="p" value="dataset"><input type="hidden" name="q" value="DataSetDataForm"><input type="hidden" name="datasetid" value="' . $dataSetId . '"><input type="hidden" name="dataset" value="' . $dataSet . '">'); // Call to render the template Theme::Set('header_text', $dataSet); Theme::Set('form_fields', array()); Theme::Render('grid_render'); } else { $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="dataset"><input type="hidden" name="q" value="DataSetGrid">'); Theme::Set('pager', ResponseManager::Pager($id)); // Call to render the template Theme::Set('header_text', __('DataSets')); Theme::Set('form_fields', array()); Theme::Render('grid_render'); } }
/** * Display page logic */ function displayPage() { $db =& $this->db; // Default options if (Kit::IsFilterPinned('template', 'Filter')) { $pinned = 1; $name = Session::Get('template', 'filter_name'); $tags = Session::Get('template', 'filter_tags'); $showThumbnail = Session::Get('template', 'showThumbnail'); } else { $pinned = 0; $name = ''; $tags = ''; $showThumbnail = 1; } $id = uniqid(); Theme::Set('header_text', __('Templates')); Theme::Set('id', $id); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); Theme::Set('form_meta', '<input type="hidden" name="p" value="template"><input type="hidden" name="q" value="TemplateView">'); $formFields = array(); $formFields[] = FormManager::AddText('filter_name', __('Name'), $name, NULL, 'n'); $formFields[] = FormManager::AddText('filter_tags', __('Tags'), $tags, NULL, 't'); $formFields[] = FormManager::AddCheckbox('showThumbnail', __('Show Thumbnails'), $showThumbnail, NULL, 't'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $pinned, NULL, 'k'); Theme::Set('form_fields', $formFields); // Call to render the template Theme::Render('grid_render'); }
function displayPage() { $db =& $this->db; // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="sessions"><input type="hidden" name="q" value="Grid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); // Construct Filter Form if (Kit::IsFilterPinned('sessions', 'Filter')) { $filter_pinned = 1; $filter_type = Session::Get('sessions', 'filter_type'); $filter_fromdt = Session::Get('sessions', 'filter_fromdt'); } else { $filter_pinned = 0; $filter_type = '0'; $filter_fromdt = NULL; } $formFields = array(); $formFields[] = FormManager::AddDatePicker('filter_fromdt', __('From Date'), $filter_fromdt, NULL, 't'); $formFields[] = FormManager::AddCombo('filter_type', __('Type'), $filter_type, array(array('typeid' => '0', 'type' => 'All'), array('typeid' => 'active', 'type' => 'Active'), array('typeid' => 'guest', 'type' => 'Guest'), array('typeid' => 'expired', 'type' => 'Expired')), 'typeid', 'type', NULL, 'd'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $filter_pinned, NULL, 'k'); // Call to render the template Theme::Set('header_text', __('Sessions')); Theme::Set('form_fields', $formFields); Theme::Render('grid_render'); }
public function displayPage() { // Configure the theme Theme::Set('id', 'LogGridForRefresh'); Theme::Set('form_meta', '<input type="hidden" name="p" value="auditlog"><input type="hidden" name="q" value="Grid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager('LogGridForRefresh')); // Construct Filter Form if (Kit::IsFilterPinned('auditlog', 'Filter')) { $filter_pinned = 1; $filterFromDt = Session::Get('auditlog', 'filterFromDt'); $filterToDt = Session::Get('auditlog', 'filterToDt'); $filterUser = Session::Get('auditlog', 'filterUser'); $filterEntity = Session::Get('auditlog', 'filterEntity'); } else { $filter_pinned = 0; $filterFromDt = NULL; $filterToDt = NULL; $filterUser = NULL; $filterEntity = NULL; } // Fields $formFields = array(); $formFields[] = FormManager::AddDatePicker('filterFromDt', __('From Date'), $filterFromDt, NULL, 'f'); $formFields[] = FormManager::AddDatePicker('filterToDt', __('To Date'), $filterToDt, NULL, 't'); $formFields[] = FormManager::AddText('filterUser', __('User'), $filterUser, NULL, 'u'); $formFields[] = FormManager::AddText('filterEntity', __('Entity'), $filterEntity, NULL, 'e'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $filter_pinned, NULL, 'k'); // Call to render the template Theme::Set('header_text', __('Audit Trail')); Theme::Set('form_fields', $formFields); Theme::Render('grid_render'); }
/** * Controls which pages are to be displayed * @return */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('displaygroup_form_add_url', 'index.php?p=displaygroup&q=AddForm'); Theme::Set('form_meta', '<input type="hidden" name="p" value="user"><input type="hidden" name="q" value="UserGrid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); // Button URL's Theme::Set('user_form_add_url', 'index.php?p=user&q=DisplayForm'); Theme::Set('myapplications_form_add_url', 'index.php?p=user&q=MyApplications'); if (Kit::IsFilterPinned('user', 'Filter')) { Theme::Set('filter_pinned', 'checked'); Theme::Set('filter_username', Session::Get('user', 'filter_username')); Theme::Set('filter_usertypeid', Session::Get('user', 'filter_usertypeid')); } else { Theme::Set('filter_usertypeid', 0); } // List of Displays this user has permission for $usertypes = $this->db->GetArray("SELECT usertypeID, usertype FROM usertype ORDER BY usertype"); array_unshift($usertypes, array('usertypeID' => 0, 'usertype' => 'All')); Theme::Set('usertype_field_list', $usertypes); // Render the Theme and output Theme::Render('user_page'); }
/** * Controls which pages are to be displayed * @return */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('displaygroup_form_add_url', 'index.php?p=displaygroup&q=AddForm'); Theme::Set('form_meta', '<input type="hidden" name="p" value="user"><input type="hidden" name="q" value="UserGrid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); if (Kit::IsFilterPinned('user_admin', 'Filter')) { $filter_pinned = 1; $filter_username = Session::Get('user_admin', 'filter_username'); $filter_usertypeid = Session::Get('user_admin', 'filter_usertypeid'); $filterRetired = Session::Get('user_admin', 'filterRetired'); } else { $filter_pinned = 0; $filter_username = NULL; $filter_usertypeid = NULL; $filterRetired = 0; } $formFields = array(); $formFields[] = FormManager::AddText('filter_username', __('Name'), $filter_username, NULL, 'n'); $usertypes = $this->db->GetArray("SELECT usertypeID, usertype FROM usertype ORDER BY usertype"); array_unshift($usertypes, array('usertypeID' => 0, 'usertype' => 'All')); $formFields[] = FormManager::AddCombo('filter_usertypeid', __('User Type'), $filter_usertypeid, $usertypes, 'usertypeID', 'usertype', NULL, 't'); $formFields[] = FormManager::AddCombo('filterRetired', __('Retired?'), $filterRetired, array(array('retiredId' => -1, 'retired' => 'All'), array('retiredId' => 1, 'retired' => 'Yes'), array('retiredId' => 0, 'retired' => 'No')), 'retiredId', 'retired', NULL, 'r'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $filter_pinned, NULL, 'k'); // Call to render the template Theme::Set('header_text', __('Users')); Theme::Set('form_fields', $formFields); Theme::Render('grid_render'); }
/** * Display the module page * @return */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="module"><input type="hidden" name="q" value="Grid">'); Theme::Set('pager', ResponseManager::Pager($id)); // Render the Theme and output Theme::Render('module_page'); }
/** * No display page functionaility * @return */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('help_form_add_url', 'index.php?p=help&q=AddForm'); Theme::Set('form_meta', '<input type="hidden" name="p" value="help"><input type="hidden" name="q" value="Grid">'); Theme::Set('pager', ResponseManager::Pager($id)); // Render the Theme and output Theme::Render('help_page'); }
public function displayPage() { $db =& $this->db; // Configure the theme $id = uniqid(); Theme::Set('id', 'LogGridForRefresh'); Theme::Set('form_meta', '<input type="hidden" name="p" value="log"><input type="hidden" name="q" value="Grid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager('LogGridForRefresh')); // Construct Filter Form if (Kit::IsFilterPinned('log', 'Filter')) { $filter_pinned = 1; $filter_type = Session::Get('log', 'filter_type'); $filter_page = Session::Get('log', 'filter_page'); $filter_function = Session::Get('log', 'filter_function'); $filter_display = Session::Get('log', 'filter_display'); $filter_fromdt = Session::Get('log', 'filter_fromdt'); $filter_seconds = Session::Get('log', 'filter_seconds'); $filter_intervalTypeId = Session::Get('log', 'filter_intervalTypeId'); } else { $filter_pinned = 0; $filter_type = 0; $filter_page = NULL; $filter_function = NULL; $filter_display = 0; $filter_fromdt = NULL; $filter_seconds = 120; $filter_intervalTypeId = 1; } // Two tabs $tabs = array(); $tabs[] = FormManager::AddTab('general', __('General')); $tabs[] = FormManager::AddTab('advanced', __('Advanced')); $formFields = array(); $formFields['general'][] = FormManager::AddCombo('filter_type', __('Type'), $filter_type, array(array('typeid' => 0, 'type' => 'All'), array('typeid' => 2, 'type' => 'Audit'), array('typeid' => 1, 'type' => 'Error')), 'typeid', 'type', NULL, 't'); $formFields['general'][] = FormManager::AddCombo('filter_intervalTypeId', __('Interval'), $filter_intervalTypeId, array(array('intervalTypeid' => 1, 'intervalType' => __('Seconds')), array('intervalTypeid' => 60, 'intervalType' => __('Minutes')), array('intervalTypeid' => 3600, 'intervalType' => __('Hours'))), 'intervalTypeid', 'intervalType', NULL, 'i'); $formFields['general'][] = FormManager::AddText('filter_seconds', __('Duration back'), $filter_seconds, NULL, 's'); $formFields['general'][] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $filter_pinned, NULL, 'k'); // Advanced Tab $formFields['advanced'][] = FormManager::AddDatePicker('filter_fromdt', __('From Date'), $filter_fromdt, NULL, 't'); $formFields['advanced'][] = FormManager::AddText('filter_page', __('Page'), $filter_page, NULL, 'p'); $formFields['advanced'][] = FormManager::AddText('filter_function', __('Function'), $filter_function, NULL, 'f'); // Display $displays = $this->user->DisplayList(); array_unshift($displays, array('displayid' => 0, 'display' => 'All')); $formFields['advanced'][] = FormManager::AddCombo('filter_display', __('Display'), $filter_display, $displays, 'displayid', 'display', NULL, 't'); // Call to render the template Theme::Set('header_text', __('Logs')); Theme::Set('form_tabs', $tabs); Theme::Set('form_fields_general', $formFields['general']); Theme::Set('form_fields_advanced', $formFields['advanced']); Theme::Render('grid_render'); }
/** * Display Page */ public function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="oauth"><input type="hidden" name="q" value="Grid">'); Theme::Set('pager', ResponseManager::Pager($id)); // Call to render the template Theme::Set('header_text', __('Applications')); Theme::Set('form_fields', array()); Theme::Render('grid_render'); }
/** * Display Page */ public function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('application_form_add_url', 'index.php?p=oauth&q=RegisterForm'); Theme::Set('oauth_log_button_url', 'index.php?p=oauth&q=ViewLog'); Theme::Set('form_meta', '<input type="hidden" name="p" value="oauth"><input type="hidden" name="q" value="Grid">'); Theme::Set('pager', ResponseManager::Pager($id)); // Render the Theme and output Theme::Render('applications_page'); }
/** * Display the Resolution Page */ function displayPage() { $db =& $this->db; // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('resolution_form_add_url', 'index.php?p=resolution&q=AddForm'); Theme::Set('form_meta', '<input type="hidden" name="p" value="resolution"><input type="hidden" name="q" value="ResolutionGrid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); // Render the Theme and output Theme::Render('resolution_page'); }
/** * Include display page template page based on sub page selected * @return */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="displayprofile"><input type="hidden" name="q" value="Grid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); // Call to render the template Theme::Set('header_text', __('Display Setting Profiles')); Theme::Set('form_fields', array()); Theme::Render('grid_render'); }
/** * Display page logic */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('usergroup_form_add_url', 'index.php?p=group&q=GroupForm'); Theme::Set('form_meta', '<input type="hidden" name="p" value="group"><input type="hidden" name="q" value="Grid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); // Default options if (Kit::IsFilterPinned('usergroup', 'Filter')) { Theme::Set('filter_pinned', 'checked'); Theme::Set('filter_name', Session::Get('usergroup', 'filter_name')); } // Render the Theme and output Theme::Render('usergroup_page'); }
/** * Include display page template page based on sub page selected * @return */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="display"><input type="hidden" name="q" value="DisplayGrid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); // Default options if (Kit::IsFilterPinned('display', 'DisplayFilter')) { $filter_pinned = 1; $filter_displaygroup = Session::Get('display', 'filter_displaygroup'); $filter_display = Session::Get('display', 'filter_display'); $filterMacAddress = Session::Get('display', 'filterMacAddress'); $filter_showView = Session::Get('display', 'filter_showView'); $filterVersion = Session::Get('display', 'filterVersion'); $filter_autoRefresh = Session::Get('display', 'filter_autoRefresh'); } else { $filter_pinned = 0; $filter_displaygroup = NULL; $filter_display = NULL; $filterMacAddress = NULL; $filter_showView = 0; $filterVersion = NULL; $filter_autoRefresh = 0; } $formFields = array(); $formFields[] = FormManager::AddCombo('filter_showView', __('View'), $filter_showView, array(array('key' => 0, 'value' => __('Default')), array('key' => 4, 'value' => __('Default with Description')), array('key' => 1, 'value' => __('Screen shot thumbnails')), array('key' => 2, 'value' => __('Screen shot thumbnails when Logged In')), array('key' => 3, 'value' => __('Extended Display Status'))), 'key', 'value', NULL, 't'); $formFields[] = FormManager::AddText('filter_display', __('Name'), $filter_display, NULL, 'n'); $formFields[] = FormManager::AddText('filterMacAddress', __('Mac Address'), $filterMacAddress, NULL, 'm'); $displayGroups = $this->user->DisplayGroupList(0); array_unshift($displayGroups, array('displaygroupid' => '0', 'displaygroup' => 'All')); $formFields[] = FormManager::AddCombo('filter_displaygroup', __('Display Group'), $filter_displaygroup, $displayGroups, 'displaygroupid', 'displaygroup', NULL, 'd'); $formFields[] = FormManager::AddText('filterVersion', __('Version'), $filterVersion, NULL, 'v'); $formFields[] = FormManager::AddNumber('filter_autoRefresh', __('Auto Refresh'), $filter_autoRefresh, NULL, 'r'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $filter_pinned, NULL, 'k'); // Call to render the template Theme::Set('header_text', __('Displays')); Theme::Set('form_fields', $formFields); Theme::Render('grid_render'); }
public function displayPage() { $db =& $this->db; // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="log"><input type="hidden" name="q" value="Grid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); Theme::Set('truncate_url', 'index.php?p=log&q=TruncateForm'); // Construct Filter Form if (Kit::IsFilterPinned('log', 'Filter')) { Theme::Set('filter_pinned', 'checked'); Theme::Set('filter_type', Session::Get('user', 'filter_type')); Theme::Set('filter_page', Session::Get('user', 'filter_page')); Theme::Set('filter_function', Session::Get('user', 'filter_function')); Theme::Set('filter_display', Session::Get('user', 'filter_display')); Theme::Set('filter_fromdt', Session::Get('user', 'filter_fromdt')); Theme::Set('filter_seconds', Session::Get('user', 'filter_seconds')); } else { Theme::Set('filter_type', '0'); Theme::Set('filter_seconds', 120); Theme::Set('filter_page', '0'); Theme::Set('filter_function', '0'); Theme::Set('filter_display', 0); } // Lists $types = array(array('typeid' => '0', 'type' => 'All'), array('typeid' => 'audit', 'type' => 'Audit'), array('typeid' => 'error', 'type' => 'Error')); Theme::Set('type_field_list', $types); $pages = $db->GetArray("SELECT DISTINCT IFNULL(page, '-1') AS pageid, page FROM log ORDER BY 2"); array_unshift($pages, array('pageid' => '0', 'page' => 'All')); Theme::Set('page_field_list', $pages); $functions = $db->GetArray("SELECT DISTINCT IFNULL(function, '-1') AS functionid, function FROM log ORDER BY 2"); array_unshift($functions, array('functionid' => '0', 'function' => 'All')); Theme::Set('function_field_list', $functions); $displays = $db->GetArray('SELECT displayid, display FROM display WHERE licensed = 1 ORDER BY 2'); array_unshift($displays, array('displayid' => 0, 'display' => 'All')); Theme::Set('display_field_list', $displays); // Render the Theme and output Theme::Render('log_page'); }
/** * Display page logic */ function displayPage() { $db =& $this->db; // Default options if (Kit::IsFilterPinned('template', 'Filter')) { Theme::Set('filter_pinned', 'checked'); Theme::Set('filter_name', Session::Get('template', 'filter_name')); Theme::Set('filter_tags', Session::Get('template', 'filter_tags')); Theme::Set('filter_is_system', Session::Get('template', 'filter_is_system')); } else { Theme::Set('filter_is_system', -1); } $id = uniqid(); Theme::Set('id', $id); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); Theme::Set('form_meta', '<input type="hidden" name="p" value="template"><input type="hidden" name="q" value="TemplateView">'); // Field list for a "retired" dropdown list Theme::Set('is_system_field_list', array(array('is_systemid' => -1, 'is_system' => 'All'), array('is_systemid' => 1, 'is_system' => 'Yes'), array('is_systemid' => 0, 'is_system' => 'No'))); // Call to render the template Theme::Render('template_page'); }
public function displayPage() { $subpage = Kit::GetParam('sp', _GET, _WORD, ''); // Configure the theme $id = uniqid(); Theme::Set('id', $id); // Different pages for data entry and admin if ($subpage == 'DataEntry') { $dataSetId = Kit::GetParam('datasetid', _GET, _INT); $dataSet = Kit::GetParam('dataset', _GET, _STRING); Theme::Set('form_meta', '<input type="hidden" name="p" value="dataset"><input type="hidden" name="q" value="DataSetDataForm"><input type="hidden" name="datasetid" value="' . $dataSetId . '"><input type="hidden" name="dataset" value="' . $dataSet . '">'); Theme::Render('dataset_dataentry_page'); } else { $id = uniqid(); Theme::Set('id', $id); Theme::Set('dataset_form_add_url', 'index.php?p=dataset&q=AddDataSetForm'); Theme::Set('form_meta', '<input type="hidden" name="p" value="dataset"><input type="hidden" name="q" value="DataSetGrid">'); Theme::Set('pager', ResponseManager::Pager($id)); // Render the Theme and output Theme::Render('dataset_page'); } }
function displayPage() { $db =& $this->db; // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="sessions"><input type="hidden" name="q" value="Grid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); // Construct Filter Form if (Kit::IsFilterPinned('sessions', 'Filter')) { Theme::Set('filter_pinned', 'checked'); Theme::Set('filter_type', Session::Get('user', 'filter_type')); Theme::Set('filter_fromdt', Session::Get('user', 'filter_fromdt')); } else { Theme::Set('filter_type', 0); } // Lists $types = array(array('typeid' => 0, 'type' => 'All'), array('typeid' => 'active', 'type' => 'Active'), array('typeid' => 'guest', 'type' => 'Guest'), array('typeid' => 'expired', 'type' => 'Expired')); Theme::Set('type_field_list', $types); // Render the Theme and output Theme::Render('sessions_page'); }
public function displayPage() { $db =& $this->db; // Default options if (Kit::IsFilterPinned('mediamanager', 'Filter')) { Theme::Set('filter_pinned', 'checked'); Theme::Set('filter_layout_name', Session::Get('mediamanager', 'filter_layout_name')); Theme::Set('filter_region_name', Session::Get('mediamanager', 'filter_region_name')); Theme::Set('filter_media_name', Session::Get('mediamanager', 'filter_media_name')); Theme::Set('filter_type', Session::Get('mediamanager', 'filter_type')); } $id = uniqid(); Theme::Set('id', $id); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); Theme::Set('form_meta', '<input type="hidden" name="p" value="mediamanager"><input type="hidden" name="q" value="MediaManagerGrid">'); // Module types filter $types = $db->GetArray("SELECT Module AS moduleid, Name AS module FROM `module` WHERE Enabled = 1 ORDER BY 2"); array_unshift($types, array('moduleid' => '', 'module' => 'All')); Theme::Set('module_field_list', $types); // Call to render the template Theme::Render('homepage_mediamanager'); }
/** * Display the Resolution Page */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="resolution"><input type="hidden" name="q" value="ResolutionGrid">'); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); if (Kit::IsFilterPinned('resolution', 'ResolutionFilter')) { $pinned = 1; $enabled = Session::Get('resolution', 'filterEnabled'); } else { $enabled = 1; $pinned = 0; } $formFields = array(); $formFields[] = FormManager::AddCombo('filterEnabled', __('Enabled'), $enabled, array(array('enabledid' => 1, 'enabled' => 'Yes'), array('enabledid' => 0, 'enabled' => 'No')), 'enabledid', 'enabled', NULL, 'e'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $pinned, NULL, 'k'); // Call to render the template Theme::Set('header_text', __('Resolutions')); Theme::Set('form_fields', $formFields); Theme::Render('grid_render'); }
/** * Display the module page * @return */ function displayPage() { // Configure the theme $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="module"><input type="hidden" name="q" value="Grid">'); Theme::Set('pager', ResponseManager::Pager($id)); // Do we have any modules to install?! if (Config::GetSetting('MODULE_CONFIG_LOCKED_CHECKB') != 'Checked') { // Get a list of matching files in the modules folder $files = glob('modules/*.module.php'); // Get a list of all currently installed modules try { $dbh = PDOConnect::init(); $sth = $dbh->prepare("SELECT CONCAT('modules/', LOWER(Module), '.module.php') AS Module FROM `module`"); $sth->execute(); $rows = $sth->fetchAll(); $installed = array(); foreach ($rows as $row) { $installed[] = $row['Module']; } } catch (Exception $e) { trigger_error(__('Cannot get installed modules'), E_USER_ERROR); } // Compare the two $to_install = array_diff($files, $installed); if (count($to_install) > 0) { Theme::Set('module_install_url', 'index.php?p=module&q=Install&module='); Theme::Set('to_install', $to_install); Theme::Set('prepend', Theme::RenderReturn('module_page_install_modules')); } } // Call to render the template Theme::Set('header_text', __('Modules')); Theme::Set('form_fields', array()); Theme::Render('grid_render'); }
/** * Displays the Library Assign form * @return */ function LibraryAssignForm() { $db =& $this->db; $user =& $this->user; $response = new ResponseManager(); $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="content"><input type="hidden" name="q" value="LibraryAssignView">'); Theme::Set('pager', ResponseManager::Pager($id, 'grid_pager')); // Module types filter $modules = $this->user->ModuleAuth(0, '', 1); $types = array(); foreach ($modules as $module) { $type['moduleid'] = $module['Module']; $type['module'] = $module['Name']; $types[] = $type; } array_unshift($types, array('moduleid' => '', 'module' => 'All')); Theme::Set('module_field_list', $types); // Call to render the template $output = Theme::RenderReturn('library_form_assign'); // Input vars $layoutId = Kit::GetParam('layoutid', _REQUEST, _INT); $regionId = Kit::GetParam('regionid', _REQUEST, _STRING); // Construct the Response $response->html = $output; $response->success = true; $response->dialogSize = true; $response->dialogClass = 'modal-big'; $response->dialogWidth = '780px'; $response->dialogHeight = '580px'; $response->dialogTitle = __('Assign an item from the Library'); $response->AddButton(__('Help'), 'XiboHelpRender("' . HelpManager::Link('Library', 'Assign') . '")'); $response->AddButton(__('Cancel'), 'XiboSwapDialog("index.php?p=timeline&layoutid=' . $layoutId . '®ionid=' . $regionId . '&q=RegionOptions")'); $response->AddButton(__('Assign'), 'LibraryAssignSubmit("' . $layoutId . '","' . $regionId . '")'); $response->Respond(); }
/** * Displays the Layout Page */ function displayPage() { $db =& $this->db; switch ($this->sub_page) { case 'view': // Default options if (Kit::IsFilterPinned('layout', 'LayoutFilter')) { $layout = Session::Get('layout', 'filter_layout'); $tags = Session::Get('layout', 'filter_tags'); $retired = Session::Get('layout', 'filter_retired'); $owner = Session::Get('layout', 'filter_userid'); $filterLayoutStatusId = Session::Get('layout', 'filterLayoutStatusId'); $showDescriptionId = Session::Get('layout', 'showDescriptionId'); $showThumbnail = Session::Get('layout', 'showThumbnail'); $showTags = Session::Get('content', 'showTags'); $pinned = 1; } else { $layout = NULL; $tags = NULL; $retired = 0; $owner = NULL; $filterLayoutStatusId = 1; $showDescriptionId = 2; $pinned = 0; $showThumbnail = 1; $showTags = 0; } $id = uniqid(); Theme::Set('header_text', __('Layouts')); Theme::Set('id', $id); Theme::Set('filter_id', 'XiboFilterPinned' . uniqid('filter')); Theme::Set('pager', ResponseManager::Pager($id)); Theme::Set('form_meta', '<input type="hidden" name="p" value="layout"><input type="hidden" name="q" value="LayoutGrid">'); $formFields = array(); $formFields[] = FormManager::AddText('filter_layout', __('Name'), $layout, NULL, 'l'); $formFields[] = FormManager::AddText('filter_tags', __('Tags'), $tags, NULL, 't'); // Users we have permission to see $users = $this->user->userList(); array_unshift($users, array('userid' => '', 'username' => 'All')); $formFields[] = FormManager::AddCombo('filter_userid', __('Owner'), $owner, $users, 'userid', 'username', NULL, 'r'); $formFields[] = FormManager::AddCombo('filter_retired', __('Retired'), $retired, array(array('retiredid' => 1, 'retired' => 'Yes'), array('retiredid' => 0, 'retired' => 'No')), 'retiredid', 'retired', NULL, 'r'); $formFields[] = FormManager::AddCombo('filterLayoutStatusId', __('Show'), $filterLayoutStatusId, array(array('filterLayoutStatusId' => 1, 'filterLayoutStatus' => __('All')), array('filterLayoutStatusId' => 2, 'filterLayoutStatus' => __('Only Used')), array('filterLayoutStatusId' => 3, 'filterLayoutStatus' => __('Only Unused'))), 'filterLayoutStatusId', 'filterLayoutStatus', NULL, 's'); $formFields[] = FormManager::AddCombo('showDescriptionId', __('Description'), $showDescriptionId, array(array('showDescriptionId' => 1, 'showDescription' => __('All')), array('showDescriptionId' => 2, 'showDescription' => __('1st line')), array('showDescriptionId' => 3, 'showDescription' => __('None'))), 'showDescriptionId', 'showDescription', NULL, 'd'); $formFields[] = FormManager::AddCheckbox('showTags', __('Show Tags'), $showTags, NULL, 't'); $formFields[] = FormManager::AddCheckbox('showThumbnail', __('Show Thumbnails'), $showThumbnail, NULL, 'i'); $formFields[] = FormManager::AddCheckbox('XiboFilterPinned', __('Keep Open'), $pinned, NULL, 'k'); Theme::Set('form_fields', $formFields); // Call to render the template Theme::Render('grid_render'); break; case 'edit': Theme::Set('layout_form_edit_url', 'index.php?p=layout&q=displayForm&modify=true&layoutid=' . $this->layoutid); Theme::Set('layout_form_edit_background_url', 'index.php?p=layout&q=BackgroundForm&modify=true&layoutid=' . $this->layoutid); Theme::Set('layout_form_savetemplate_url', 'index.php?p=template&q=TemplateForm&layoutid=' . $this->layoutid); Theme::Set('layout_form_addregion_url', 'index.php?p=timeline&q=AddRegion&layoutid=' . $this->layoutid); Theme::Set('layout_form_preview_url', 'index.php?p=preview&q=render&ajax=true&layoutid=' . $this->layoutid); Theme::Set('layout', $this->layout); Kit::ClassLoader('campaign'); $campaign = new Campaign($db); $campaignId = $campaign->GetCampaignId($this->layoutid); Theme::Set('layout_form_schedulenow_url', 'index.php?p=schedule&q=ScheduleNowForm&CampaignID=' . $campaignId); Theme::Set('layout_designer_editor', $this->RenderDesigner()); // Set up the theme variables for the Layout Jump List Theme::Set('layoutId', $this->layoutid); Theme::Set('layouts', $this->user->LayoutList()); // Set up any JavaScript translations Theme::SetTranslation('save_position_button', __('Save Position')); Theme::SetTranslation('revert_position_button', __('Undo')); Theme::SetTranslation('savePositionsFirst', Theme::Translate('Please save the pending position changes first by clicking "Save Positions" or cancel by clicking "Undo".')); // Call the render the template Theme::Render('layout_designer'); break; default: break; } return false; }
/** * Displays the Library Assign form * @return */ function LayoutAssignForm() { $db =& $this->db; $user =& $this->user; $response = new ResponseManager(); // Input vars $campaignId = Kit::GetParam('CampaignID', _GET, _INT); $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="campaign"><input type="hidden" name="q" value="LayoutAssignView">'); Theme::Set('pager', ResponseManager::Pager($id)); // Get the currently assigned layouts and put them in the "well" // // Layouts in group $SQL = "SELECT layout.Layoutid, "; $SQL .= " layout.layout, "; $SQL .= " CONCAT('LayoutID_', layout.LayoutID) AS list_id "; $SQL .= "FROM layout "; $SQL .= " INNER JOIN lkcampaignlayout "; $SQL .= " ON lkcampaignlayout.LayoutID = layout.LayoutID "; $SQL .= sprintf("WHERE lkcampaignlayout.CampaignID = %d", $campaignId); $SQL .= " ORDER BY lkcampaignlayout.DisplayOrder "; $layoutsAssigned = $db->GetArray($SQL); if (!is_array($layoutsAssigned)) { trigger_error($db->error()); trigger_error(__('Error getting Layouts'), E_USER_ERROR); } Debug::LogEntry('audit', count($layoutsAssigned) . ' layouts assigned already'); // Set the layouts assigned Theme::Set('layouts_assigned', $layoutsAssigned); // Call to render the template $output = Theme::RenderReturn('campaign_form_layout_assign'); // Construct the Response $response->html = $output; $response->success = true; $response->dialogSize = true; $response->dialogWidth = '780px'; $response->dialogHeight = '580px'; $response->dialogTitle = __('Layouts on Campaign'); $response->AddButton(__('Help'), 'XiboHelpRender("' . HelpManager::Link('Campaign', 'Layouts') . '")'); $response->AddButton(__('Cancel'), 'XiboDialogClose()'); $response->AddButton(__('Save'), 'LayoutsSubmit("' . $campaignId . '")'); $response->Respond(); }
private function EventFormDisplayFilter($displayGroupIds) { $msgName = __('Display'); // Default values? if (Kit::IsFilterPinned('scheduleEvent', 'EventFormDisplayFilter')) { $filterPinned = 'checked'; $filterName = Session::Get('scheduleEvent', 'DisplayName'); } else { $filterPinned = ''; $filterName = ''; } // Serialize the list of display group ids $displayGroupIdsSerialized = ""; foreach ($displayGroupIds as $displayGroupId) { $displayGroupIdsSerialized .= '<input type="hidden" name="DisplayGroupIDs[]" value="' . $displayGroupId . '">'; } $form = <<<HTML <div class="XiboFilterInner"> <div class="scheduleFormCheckAll pull-right"><label for"checkAll"><input type="checkbox" name="checkAll">Check All</label></div> <form onsubmit="return false"> <input type="hidden" name="p" value="schedule"> <input type="hidden" name="q" value="EventFormDisplay"> {$displayGroupIdsSerialized} <table> <tr> <td>{$msgName}</td> <td><input type="text" name="name" value="{$filterName}"></td> <td> <label for="XiboFilterPinned">Pin?</label> <input id="XiboFilterPinned" name="XiboFilterPinned" type="checkbox" class="XiboFilter" {$filterPinned} /> </td> </tr> </table> </form> </div> HTML; $id = Kit::uniqueId(); $pager = ResponseManager::Pager($id); $xiboGrid = <<<HTML <div class="XiboGrid" id="{$id}"> <div class="XiboFilter"> {$form} </div> <div class="XiboData"></div> {$pager} </div> HTML; return $xiboGrid; }
public function FileAssociations() { $displayGroupId = Kit::GetParam('DisplayGroupID', _GET, _INT); // Auth $auth = $this->user->DisplayGroupAuth($displayGroupId, true); if (!$auth->edit) { trigger_error(__('You do not have permission to edit this display group'), E_USER_ERROR); } $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="displaygroup"><input type="hidden" name="q" value="FileAssociationsView"><input type="hidden" name="displaygroupid" value="' . $displayGroupId . '">'); Theme::Set('pager', ResponseManager::Pager($id)); // Module types filter $modules = $this->user->ModuleAuth(0, '', -1); $types = array(); foreach ($modules as $module) { $type['moduleid'] = $module['Module']; $type['module'] = $module['Name']; $types[] = $type; } array_unshift($types, array('moduleid' => '', 'module' => 'All')); Theme::Set('module_field_list', $types); // Get the currently associated media items and put them in the top bar $existing = array(); try { $dbh = PDOConnect::init(); $sth = $dbh->prepare(' SELECT media.MediaID, media.Name FROM `media` INNER JOIN `lkmediadisplaygroup` ON lkmediadisplaygroup.mediaid = media.mediaid WHERE lkmediadisplaygroup.displaygroupid = :displaygroupid '); $sth->execute(array('displaygroupid' => $displayGroupId)); $existing = $sth->fetchAll(); } catch (Exception $e) { Debug::LogEntry('error', $e->getMessage(), get_class(), __FUNCTION__); trigger_error(__('Unable to get existing assignments.'), E_USER_ERROR); } Theme::Set('existing_associations', $existing); // Call to render the template $output = Theme::RenderReturn('displaygroup_fileassociations_form_assign'); // Construct the Response $response = new ResponseManager(); $response->html = $output; $response->success = true; $response->dialogSize = true; $response->dialogClass = 'modal-big'; $response->dialogWidth = '780px'; $response->dialogHeight = '580px'; $response->dialogTitle = __('Associate an item from the Library'); $response->AddButton(__('Help'), 'XiboHelpRender("' . HelpManager::Link('DisplayGroup', 'FileAssociations') . '")'); $response->AddButton(__('Cancel'), 'XiboDialogClose()'); $response->AddButton(__('Assign'), 'FileAssociationsSubmit(' . $displayGroupId . ')'); $response->Respond(); }
/** * Displays the Library Assign form * @return */ function LayoutAssignForm() { $db =& $this->db; $user =& $this->user; $response = new ResponseManager(); // Input vars $campaignId = Kit::GetParam('CampaignID', _GET, _INT); $id = uniqid(); Theme::Set('id', $id); Theme::Set('form_meta', '<input type="hidden" name="p" value="campaign"><input type="hidden" name="q" value="LayoutAssignView">'); Theme::Set('pager', ResponseManager::Pager($id, 'grid_pager')); // Get the currently assigned layouts and put them in the "well" $layoutsAssigned = Layout::Entries(array('lkcl.DisplayOrder'), array('campaignId' => $campaignId)); if (!is_array($layoutsAssigned)) { trigger_error($db->error()); trigger_error(__('Error getting Layouts'), E_USER_ERROR); } Debug::LogEntry('audit', count($layoutsAssigned) . ' layouts assigned already'); $formFields = array(); $formFields[] = FormManager::AddText('filter_name', __('Name'), NULL, NULL, 'l'); $formFields[] = FormManager::AddText('filter_tags', __('Tags'), NULL, NULL, 't'); Theme::Set('form_fields', $formFields); // Set the layouts assigned Theme::Set('layouts_assigned', $layoutsAssigned); Theme::Set('append', Theme::RenderReturn('campaign_form_layout_assign')); // Call to render the template Theme::Set('header_text', __('Choose Layouts')); $output = Theme::RenderReturn('grid_render'); // Construct the Response $response->html = $output; $response->success = true; $response->dialogSize = true; $response->dialogWidth = '780px'; $response->dialogHeight = '580px'; $response->dialogTitle = __('Layouts on Campaign'); $response->AddButton(__('Help'), 'XiboHelpRender("' . HelpManager::Link('Campaign', 'Layouts') . '")'); $response->AddButton(__('Cancel'), 'XiboDialogClose()'); $response->AddButton(__('Save'), 'LayoutsSubmit("' . $campaignId . '")'); $response->Respond(); }
/** * Filter form for the layout jump list */ public function LayoutJumpListFilter() { // Default values? if (Kit::IsFilterPinned('layoutDesigner', 'JumpList')) { $filterPinned = 'checked'; $listPinned = 'block'; $arrowDirection = 'v'; $filterName = Session::Get('layoutDesigner', 'Name'); } else { $filterPinned = ''; $listPinned = 'none'; $arrowDirection = '^'; $filterName = ''; } $id = uniqid(); Theme::Set('jumplist_id', $id); Theme::Set('jumplist_pager', ResponseManager::Pager($id)); Theme::Set('jumplist_form_meta', '<input type="hidden" name="p" value="layout"><input type="hidden" name="q" value="LayoutJumpList">'); Theme::Set('jumplist_filter_pinned', $filterPinned); Theme::Set('jumplist_list_pinned', $listPinned); Theme::Set('jumplist_arrow_direction', $arrowDirection); Theme::Set('jumplist_filter_name', $filterName); }