input->cookie; $tmpl = VikRequest::getVar('tmpl'); $view = VikRequest::getVar('view'); if ($tmpl == 'component') { return; } if (VBOPlatformDetection::isWordPress()) { /** * @wponly Hide menu for Pro-update views */ if (in_array($view, ['getpro'])) { return; } } // JS lang def JText::script('VBOGUESTREVSVCMREQ'); JText::script('VBO_QUICK_ACTIONS'); $session = JFactory::getSession(); $admin_user = JFactory::getUser(); $has_vcm = is_file(VCM_SITE_PATH.DIRECTORY_SEPARATOR.'helpers'.DIRECTORY_SEPARATOR.'lib.vikchannelmanager.php'); $backlogo = VikBooking::getBackendLogo(); $vbo_auth_admin = $admin_user->authorise('core.admin', 'com_vikbooking'); $vbo_auth_global = $admin_user->authorise('core.vbo.global', 'com_vikbooking'); $vbo_auth_rateplans = $admin_user->authorise('core.vbo.rateplans', 'com_vikbooking'); $vbo_auth_rooms = $admin_user->authorise('core.vbo.rooms', 'com_vikbooking'); $vbo_auth_pricing = $admin_user->authorise('core.vbo.pricing', 'com_vikbooking'); $vbo_auth_bookings = $admin_user->authorise('core.vbo.bookings', 'com_vikbooking'); $vbo_auth_availability = $admin_user->authorise('core.vbo.availability', 'com_vikbooking'); $vbo_auth_management = $admin_user->authorise('core.vbo.management', 'com_vikbooking'); $vbo_auth_pms = $admin_user->authorise('core.vbo.pms', 'com_vikbooking'); $vbo_auth_reports = $admin_user->authorise('core.vbo.pmsreports', 'com_vikbooking'); $vbo_auth_tm = $admin_user->authorise('core.vbo.tm', 'com_vikbooking'); $reviews_dld = 0; // check for stored quick actions only once $admin_menu_actions_checked = $session->get('admin_menu.actions.check', null, 'vikbooking'); if (!$admin_menu_actions_checked) { $session->set('admin_menu.actions.check', 1, 'vikbooking'); } /** * Check VCM subscription status. * * @since 1.15.0 (J) - 1.5.0 (WP) */ $vcm_expiration_reminder = VikBooking::getVCMSubscriptionStatus(); /** * New back-end menu structure would support sub-titles for menu entries. * * * Entry Title * I am the entry sub-text. * * * @since 1.16.0 (J) - 1.6.0 (WP) */ ?>
VikBooking Logo
triggerEvent('onUpdaterSupported'); if (count($callable) && $callable[0]) { //Plugin enabled $params = new stdClass; $params->version = E4J_SOFTWARE_VERSION; $params->alias = 'com_vikbooking'; $upd_btn_text = strrev('setadpU kcehC'); $ready_jsfun = ''; $result = $app->triggerEvent('onGetVersionContents', array(&$params)); if (count($result) && $result[0]) { $upd_btn_text = $result[0]->response->shortTitle; } else { $ready_jsfun = 'jQuery("#vik-update-btn").trigger("click");'; } ?> getenv('HTTP_HOST'), 'sn' => getenv('SERVER_NAME'), 'app' => CREATIVIKAPP, 'ver' => VIKBOOKING_SOFTWARE_VERSION, ]; $vikupdater_url = 'https://extensionsforjoomla.com/vikcheck/vikupdater.php?' . http_build_query($data); echo JHtml::fetch( 'bootstrap.renderModal', 'jmodal-version-check', array( 'title' => 'Install VikUpdater', 'closeButton' => true, 'keyboard' => true, 'bodyHeight' => 80, 'url' => $vikupdater_url, 'footer' => '', ) ); ?> getJmodalScript(); ?> shouldRequestOpportunities()) { $opp->downloadOpportunities(); } // count opportunities $opp_filters = array( 'status' => 0, 'action' => 0, ); $new_opp_count = count($opp->loadOpportunities($opp_filters, null, null)); if ($new_opp_count > 0) { ?> getUri()->admin('index.php?option=com_vikchannelmanager&task=reviews', false); if ($highlight == '18') { ?> (empty($view) ? VikRequest::getString('task', '') : $view), 'btn_trigger' => '.vbo-multitasking-apps', ]; // render the multitasking layout echo JLayoutHelper::render('sidepanel.multitasking', $layout_data); ?> readOldNotifications(); // check if notifications should be downloaded $ncInstance->downloadNotifications(); // count unread notifications $unreadNotifs = $ncInstance->countUnread(); $unreadNotifsRead = $unreadNotifs > 99 ? '99+' : $unreadNotifs; $unreadNotifsRead = !$unreadNotifsRead ? '' : $unreadNotifsRead; ?>
(empty($view) ? VikRequest::getString('task', '') : $view), 'btn_trigger' => '.vbo-notifications-center-handler', 'badge_c_attr' => 'data-badge-count', 'badge_r_attr' => 'data-badge-read', 'badge_count' => $unreadNotifs, ]; // render the notificationscenter layout echo JLayoutHelper::render('sidepanel.notificationscenter', $layout_data); ?>
= 0) { // subscription is expiring, but it's not expired yet, display a modal-reminder ?>

getUri()->ajax('index.php?option=com_vikbooking'); JHtml::fetch('script', VBO_ADMIN_URI . 'resources/helpwizard.js', ['version' => VIKBOOKING_SOFTWARE_VERSION]); JText::script('VBSAVE'); JText::script('VBDISMISS'); JFactory::getDocument()->addScriptDeclaration( <<' . '
' . JText::sprintf('VBFOOTER', VIKBOOKING_SOFTWARE_VERSION) . ' VikWP - vikwp.com
'; } public static function pUpdateProgram($version) { /** * @wponly do nothing */ } /** * Method to add parameters to the update extra query. * * @joomlaonly this class is automatically loaded by Joomla * to invoke this method when updating the component. * * @param Update &$update An update definition * @param JTable &$table The update instance from the database * * @return void * * @since 1.16.0 (J) - 1.6.0 (WP) */ public static function prepareUpdate(&$update, &$table) { // get current domain $server = JFactory::getApplication()->input->server; // build query array $query = [ 'domain' => base64_encode($server->getString('HTTP_HOST')), 'ip' => $server->getString('REMOTE_ADDR'), ]; // get license key $license_key = VBOFactory::getConfig()->get('licensekey'); if ($license_key) { $query['key'] = $license_key; } // always refresh the extra query before an update $update->set('extra_query', http_build_query($query, '', '&')); } /** * Returns the information about the first setup metrics and minimum requirements. * * @return array associative list of metrics. * * @since 1.16.4 (J) - 1.6.4 (WP) */ public static function getFirstSetupMetrics() { $dbo = JFactory::getDbo(); $q = "SELECT COUNT(*) FROM `#__vikbooking_prices`;"; $dbo->setQuery($q); $totprices = $dbo->loadResult(); $q = "SELECT COUNT(*) FROM `#__vikbooking_rooms`;"; $dbo->setQuery($q); $totrooms = $dbo->loadResult(); $q = "SELECT COUNT(*) FROM `#__vikbooking_dispcost`;"; $dbo->setQuery($q); $totdailyfares = $dbo->loadResult(); $metrics = [ 'totprices' => $totprices, 'totrooms' => $totrooms, 'totdailyfares' => $totdailyfares, 'completed' => ($totprices && $totrooms && $totdailyfares), ]; // shortcodes (if platform-supported) if (VBOPlatformDetection::isWordPress()) { /** * @wponly - check if some shortcodes have been defined before showing the Dashboard */ $model = JModel::getInstance('vikbooking', 'shortcodes'); $metrics['shortcodes'] = $model->all('post_id'); // calculate again the completed status $metrics['completed'] = ($metrics['completed'] && $metrics['shortcodes']); } return $metrics; } }