function exportPDF() { $app = JFactory::getApplication(); $input = $app->input; AImporter::helper('pdf', 'date'); AImporter::model('transportreports'); $model = new BookproModelTransportReports(); $depart_date = DateHelper::createFromFormatYmd($input->get('filter_depart_date')); $state = $model->getState(); $state->set('list.limit', NULL); $state->set('list.start', 0); $state->set('list.ordering', 'pickup'); $state->set('list.direction', 'ASC'); if ($app->isAdmin()) { $ticket_view = $this->getView('Transportreports', 'html', 'BookProView'); } else { $ticket_view = $this->getView('AgentTransportreports', 'html', 'BookProView'); $ticket_view->is_admin = 1; } $ticket_view->setModel($model, true); $ticket_view->setLayout('report'); ob_start(); $ticket_view->display(); $pdf = ob_get_contents(); ob_end_clean(); //get flight name $order = new JObject(); $order->name = "transport_report" . $input->get('filter_depart_date') . '_' . JHtml::_('date', 'now', 'YmdHis'); $order->fontsize = 9; PrintPdfHelper::printTicket($pdf, $order, 'P'); return; }
protected function populateState($ordering = null, $direction = null) { AImporter::helper('date'); parent::populateState(); $app = JFactory::getApplication(); $id = JRequest::getVar('id', 0, '', 'int'); $this->setState('passengerlist.id', $id); // Load the filter state. $search = $this->getUserStateFromRequest($this->context . '.filter.search', 'filter_search'); $this->setState('filter.search', $search); $order_id = $this->getUserStateFromRequest($this->context . '.filter.order_id', 'filter_order_id', null, 'int'); $this->setState('filter.order_id', $order_id); $tour_id = $this->getUserStateFromRequest($this->context . '.filter.tour_id', 'filter_tour_id', null, 'int'); $this->setState('filter.tour_id', $tour_id); $depart_date = $this->getUserStateFromRequest($this->context . '.filter.depart_date', 'filter_depart_date', null); $depart_date = DateHelper::createFromFormatYmd($depart_date); $this->setState('filter.depart_date', $depart_date); $order_status = $this->getUserStateFromRequest($this->context . '.filter.order_status', 'filter_order_status', null, 'string'); $this->setState('filter.order_status', $order_status); $value = $app->getUserStateFromRequest($this->context . '.ordercol', 'filter_order', $ordering); $this->setState('list.ordering', $value); $value = $app->getUserStateFromRequest($this->context . '.orderdirn', 'filter_order_Dir', $direction); $this->setState('list.direction', $value); $fromdate = $this->getUserStateFromRequest($this->context . '.filter.from_date', 'filter_from_date', null, 'string'); $fromdate = DateHelper::createFromFormatYmd($fromdate); $this->setState('filter.from_date', $fromdate); $todate = $this->getUserStateFromRequest($this->context . '.filter.to_date', 'filter_to_date', null, 'string'); $todate = DateHelper::createFromFormatYmd($todate); $this->setState('filter.to_date', $todate); }
public function book() { AImporter::classes('order/order', 'order/tour'); AImporter::helper('tour', 'currency', 'math'); $this->cart = $this->getCart(); $app = JFactory::getApplication(); $input = $app->input; $tour = new BookproTourOrder(); $tour->rate_id = $input->getInt('tour'); $tour->setTourRate(); if (!$tour->setTour()) { JError::raiseError(4012, JText::_('COM_BOOKPRO_SESSION_EXPIRED')); } $tour->cart = $this->cart; $tour->data['tax'] = $this->cart->tax; $this->cart->total = $tour->setPrice(); $this->cart->subtotal = MathHelper::removeVat($this->cart->total, $this->cart->tax); $this->cart->rate = $tour->rate; $this->cart->tour = $tour->tour; $this->cart->saveToSession(); $session = JFactory::getSession(); $session->set('tour_order', $tour); $view = $this->getView('TourBook', 'html', 'BookProView'); $view->assign('cart', $this->cart); $view->assign('tour', $tour); $view->display(); return; }
/** * Print passenger manifest to pdf */ function exportpdf() { AImporter::model('passengers'); $app = JFactory::getApplication(); $input = $app->input; AImporter::helper('pdf', 'date'); $model = new BookproModelpassengers(array('ignore_request' => 0)); if ($app->isAdmin()) { $ticket_view = $this->getView('passengers', 'html', 'BookProView'); } else { $ticket_view = $this->getView('AgentPassengers', 'html', 'BookProView'); $ticket_view->is_admin = 1; } $ticket_view->setModel($model, true); $ticket_view->setLayout('report'); ob_start(); $ticket_view->display(); $pdf = ob_get_contents(); ob_end_clean(); $order = new JObject(); $order->name = 'Tour_report' . '_export_time_' . JHtml::date('now', 'Y-m-d-H-i-s'); $order->fontsize = 7; PrintPdfHelper::printTicket($pdf, $order, 'P'); return; }
public function getType() { AImporter::helper('transport'); $type = TransportHelper::getType(); $options = array(); $options[] = JHTML::_('select.option', '', JText::_('COM_BOOKPRO_TYPE'), 'value', 'text'); $options = array_merge($options, $type); return JHTML::_('select.genericlist', $options, 'filter_type', ' class="inputbox" ', 'value', 'text', $this->state->get('filter.type'), 'filter_type'); }
protected function saveOrderInfo() { //save order info AImporter::table('orderinfo'); AImporter::helper('date'); $this->orderinfo['params']['start'] = DateHelper::createFromFormatYmd($this->orderinfo['params']['start']); $this->orderinfo['params']['end'] = DateHelper::createFromFormatYmd($this->orderinfo['params']['end']); $orderinfo = $this->orderinfo; $orderinfo['order_id'] = $this->table->id; $orderinfo['params'] = json_encode($this->orderinfo['params']); $orderinfo['start'] = $this->orderinfo['params']['start']; $TableOrderinfo = new TableOrderInfo($this->_db); return $TableOrderinfo->save($orderinfo); }
static function getDayWeek($name) { AImporter::helper('date'); $days = DateHelper::dayofweek(); $daysweek = array(); foreach ($days as $key => $value) { $object = new stdClass(); $object->key = $key; $object->value = $value; $daysweek[] = $object; } $selected = array_keys($days); return AHtml::checkBoxList($daysweek, $name, '', $selected, 'key', 'value'); }
protected function getOptions() { AImporter::helper('vehicle'); $db = JFactory::getDBO(); $query = $db->getQuery(true); $query->select('id AS value, title AS text'); $query->from('#__bookpro_vehicle'); $query->where('state = 1'); $db->setQuery($query); $options = array(); $options = $db->loadObjectList(); $options = array_merge(parent::getOptions(), $options); return $options; }
public function save() { try { $this->_db->transactionStart(); //save customer $customer_id = $this->saveCustomer(); if (!$customer_id) { $this->writeLog('Save customer failed'); return false; } //save order AImporter::helper('orderstatus'); OrderStatus::init(); $order_status = OrderStatus::$PENDING->getValue(); $this->data = array('type' => 'TOUR', 'user_id' => $customer_id, 'pay_method' => '', 'promo_code' => $this->customer['promo_code'], 'order_status' => $order_status, 'pay_status' => 'PENDING', 'notes' => $this->customer['notes'], 'tax' => $this->cart->tax, 'service_fee' => $this->cart->service_fee); $this->setPrice(); $this->addCoupon(); if (!$this->store()) { $this->writeLog('Save order failed'); return false; } if (!$this->saveOrderInfo()) { $this->writeLog('Save orderinfo failed'); return false; } if (!$this->saveAddon()) { $this->writeLog('Save addon failed'); return false; } if (!$this->savePassenger()) { $this->writeLog('Save passenger failed'); return false; } $this->table->order_number = 'TR' . $this->table->order_number; $this->table->store(); $this->_db->transactionCommit(); } catch (Exception $e) { $this->writeLog($e->getMessage()); $this->_db->transactionRollback(); return false; } return true; }
public function postRequest() { $token = JSession::checkToken(); if (!$token) { die('Invail request'); } $app = jfactory::getApplication(); AImporter::helper('email'); AImporter::classes('order/custom'); $order = new BookproCustomOrder(); $order->orderinfo = $this->input->get('orderinfo', array(), 'array'); $order->customer = $_POST; $db = JFactory::getDbo(); if ($order->save()) { $mail = new EmailHelper($order->table->id); $mail->sendMail(); $app->enqueueMessage(JText::_('COM_BOOKPRO_CUSTOM_THANKS_FOR_BOOKING')); } $app->redirect('index.php?option=com_bookpro&view=customservice'); return; }
public function __construct($id = false, $typeChart = false, $option = false, $title = false) { if (!class_exists('BookProHelper')) { AImporter::helper('bookpro'); } //Check is backend or frontend if (JFactory::getApplication()->isAdmin()) { $this->isBackend = true; } else { $this->isBackend = false; } $this->isAgent = BookProHelper::isAgent(); if ($id) { $this->id = $id; } if ($typeChart) { $this->typeChart = $typeChart; } else { $this->typeChart = 'LineChart'; } $this->optionChart = $option; $this->titleChart = $title; }
private function getPlugins() { $dispatcher = JDispatcher::getInstance(); AImporter::helper('plugin'); $payment_plugins = PluginHelper::getPluginsWithEvent('onBookproGetPaymentPlugins'); $plugins = array(); if ($payment_plugins) { foreach ($payment_plugins as $plugin) { $results = $dispatcher->trigger("onBookproGetPaymentOptions", array($plugin->element, '')); if (in_array(true, $results, true)) { $plugins[] = $plugin; } } } if (count($plugins) == 1) { $plugins[0]->checked = true; ob_start(); $this->getPaymentForm($plugins[0]->element); $html = json_decode(ob_get_contents()); ob_end_clean(); $this->assign('payment_form_div', $html->msg); } $this->assign('plugins', $plugins); }
public function addLanguage() { AImporter::helper('xml', 'params'); $clone_lang = JFactory::getApplication()->input->getString('lang'); $config = ParamesHelper::getLanguageConfig(); // $en_admin_list = preg_filter('/^/', $config['main_lang'].'.', $adminArray); // $en_site_list = preg_filter('/^/', $config['main_lang'].'.', $siteArray); // // $clone_admin_list = preg_filter('/^/', $clone_lang.'.', $adminArray); // $clone_site_list = preg_filter('/^/', $clone_lang.'.', $siteArray); //copy file $addmin_path_main = $config['folder_admin'] . DS . $config['main_lang'] . DS . $config['main_lang']; $addmin_path_clone = $config['folder_admin'] . DS . $clone_lang . DS . $clone_lang; foreach ($config['file_admin'] as $value) { $check = JFile::copy($addmin_path_main . '.' . $value, $addmin_path_clone . '.' . $value); } $site_path_main = $config['folder_site'] . DS . $config['main_lang'] . DS . $config['main_lang']; $site_path_clone = $config['folder_site'] . DS . $clone_lang . DS . $clone_lang; foreach ($config['file_site'] as $value) { $check = JFile::copy($site_path_main . '.' . $value, $site_path_clone . '.' . $value); } $this->setRedirect('index.php?option=com_bookpro&view=languages&layout=list&language=' . $clone_lang, $check ? 'Add language success' : 'Add language false', $check ? null : 'error'); return; }
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: view.html.php 32 2012-07-10 16:53:30Z quannv $ **/ // No direct access to this file defined('_JEXEC') or die('Restricted access'); AImporter::helper('image'); AImporter::model('tours'); class BookProViewDestinations extends JViewLegacy { // Overwriting JView display method var $pagination; var $lists; protected $tour_itemid = null; function display($tpl = null) { $app = JFactory::getApplication(); $document = JFactory::getDocument(); $menu =& JSite::getMenu(); $active = $menu->getActive(); if ($active) { $this->products_per_row = $active->params->get('products_per_row', 2); $this->count = $active->params->get('count', 4); $this->width = $active->params->get('des_width', 130); $this->height = $active->params->get('des_height', 90);
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id$ **/ defined('_JEXEC') or die('Restricted access'); AImporter::model('passengers', 'order'); AImporter::helper('date', 'currency', 'flight', 'paystatus'); $config = JComponentHelper::getParams('com_bookpro'); $company_name = $config->get('company_name'); $logo = $config->get('company_logo'); $address = $config->get('company_address'); JToolBarHelper::cancel(); ?> <div> <div style="width:768px;border: 1px solid #ccc;margin: 0 auto;"> <?php if (JRequest::getCmd('task') != 'exportpdf') { ?> <a style="float:left; margin:5px 0 0 10px;" href="<?php echo JUri::root() . 'index.php?option=com_bookpro&controller=order&task=exportpdf&layout=ticket&order_number=' . $this->order->order_number; ?> "
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: form.php 105 2012-08-30 13:20:09Z quannv $ **/ defined('_JEXEC') or die('Restricted access'); JHtml::_('behavior.formvalidation'); AImporter::helper('flight'); ?> <form action="<?php echo JRoute::_('index.php?option=com_bookpro&layout=edit&id=' . (int) $this->item->id); ?> " method="post" name="adminForm" id="adminForm" class="form-validate"> <div class="btn-toolbar"><?php echo $this->getToolbar(); ?> </div> <div class="form-horizontal row-fluid"> <div class="span6"> <div class="lead"> <span><?php echo JText::_('COM_BOOKPRO_ORDER'); ?>
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: view.html.php 26 2012-07-08 16:07:54Z quannv $ **/ defined('_JEXEC') or die('Restricted access'); //import needed Joomla! libraries jimport('joomla.application.component.view'); //import needed JoomLIB helpers AImporter::helper('route', 'bookpro', 'request'); AImporter::model('tours', 'tourratelogs'); //import custom icons AHtml::importIcons(); class BookProViewTourRateLogs extends JViewLegacy { /** * Array containing browse table filters properties. * * @var array */ var $lists; /** * Array containig browse table subjects items to display. * * @var array */
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id$ **/ // No direct access to this file defined('_JEXEC') or die('Restricted access'); AImporter::model('tour'); AImporter::helper('image', 'bookpro', 'currency', 'form', 'tour', 'date'); class BookProViewTour extends JViewLegacy { // Overwriting JViewLegacy display method var $document; function display($tpl = null) { $this->config = JBFactory::getConfig(); $input = JFactory::getApplication()->input; AImporter::model('tour'); $cart = JModelLegacy::getInstance('TourCart', 'bookpro'); $cart->load(); $cart->clear(); $model = new BookProModelTour(); $id = $input->getInt('id'); $this->tour = $model->getComplexItem($id); $this->itineraries = TourHelper::buildItinerary($id); //$this->packages = $packages;
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: flight.php 105 2012-08-30 13:20:09Z quannv $ **/ defined('_JEXEC') or die('Restricted access'); AImporter::model('bustrips', 'bustrip', 'passengers'); AImporter::helper('date'); $passModel = new BookProModelPassengers(); $lists = array('order_id' => $this->order->id); $passModel->init($lists); $passengers = $passModel->getData(); $config = AFactory::getConfig(); ?> <fieldset class="adminform"> <legend> <?php echo JText::_('Trip Information'); ?> </legend> <table class="table"> <thead> <tr>
<?php defined('_JEXEC') or die('Restricted access'); AImporter::helper('date', 'js', 'html'); Aimporter::model('application'); class BookproViewCustomService extends JViewLegacy { function display($tpl = null) { $model = new BookProModelApplication(); $this->content = $model->getItemByCode('CUSTOMIZE_SERVICES'); parent::display($tpl); } function getServices() { $options = array((object) array('value' => '', 'title' => JText::_('COM_BOOKPRO_CUSTOMIZE_SELECT')), (object) array('value' => 'TOUR', 'title' => JText::_('COM_BOOKPRO_CUSTOMIZE_TOUR')), (object) array('value' => 'EXECUTIVE_CAR', 'title' => JText::_('COM_BOOKPRO_CUSTOMIZE_EXECUTIVE_CAR')), (object) array('value' => 'LIMO', 'title' => JText::_('COM_BOOKPRO_CUSTOMIZE_LIMO')), (object) array('value' => 'OTHER', 'title' => JText::_('COM_BOOKPRO_CUSTOMIZE_OTHER'))); return JHTML::_('select.genericlist', $options, 'orderinfo[type]', 'required class="inputbox required" ', 'value', 'title', null, 'orderinfo_type'); } }
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: default.php 23-06-2012 23:33:14 **/ // No direct access to this file defined('_JEXEC') or die('Restricted access'); JHtmlBehavior::modal('a.amodal'); AImporter::helper('form', 'currency'); AImporter::css('common'); $config = JComponentHelper::getParams('com_bookpro'); ?> <form name="frontForm" method="post" action="index.php" id="paymentForm"> <div class="row-fluid"> <div class="span7"> <div class="well well-small"> <div class="well well-small" style="background-color: white; "> <?php echo $this->loadTemplate(strtolower($this->order->type)); ?> <?php echo $this->loadTemplate('cart'); ?> </div> </div>
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id$ **/ defined('_JEXEC') or die('Restricted access'); AImporter::helper('date', 'currency', 'paystatus', 'orderstatus'); $this->orders = $displayData->orders; $customer = $displayData->customer; $total = 0; ?> <table cellpadding="5" class="table table-bordered"> <tbody> <tr> <td style="font-weight: bold; border: 1px #ccc solid;"><?php echo JText::_('#'); ?> </td> <td style="font-weight: bold; border: 1px #ccc solid;"><?php echo JText::_('COM_BOOKPRO_ORDER_NUMBER'); ?> </td> <td style="font-weight: bold; border: 1px #ccc solid;"><?php echo JText::_('COM_BOOKPRO_ORDER_PAYMENT_STATUS'); ?>
/** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: view.html.php 26 2012-07-08 16:07:54Z quannv $ **/ defined('_JEXEC') or die('Restricted access'); //import needed Joomla! libraries jimport('joomla.application.component.view'); AImporter::model('countries'); require_once JPATH_COMPONENT . '/helpers/airport.php'; //import needed JoomLIB helpers AImporter::helper('route', 'bookpro'); class BookProViewAirports extends JViewLegacy { /** * Array containing browse table filters properties. * * @var array */ var $lists; /** * Array containig browse table subjects items to display. * * @var array */ var $items; /**
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: view.html.php 26 2012-07-08 16:07:54Z quannv $ **/ // No direct access to this file defined('_JEXEC') or die('Restricted Access'); AImporter::helper('currency'); $listOrder = $this->escape($this->state->get('list.ordering')); $listDirn = $this->escape($this->state->get('list.direction')); $itemsCount = count($this->items); $pagination = $this->pagination; ?> <script type="text/javascript"> jQuery(document).ready(function($) { var olddata; $(".td_paystatus").on('focus', function () { olddata = $(this).val() }).change(function(){ var value=$(this).val(); //get name or id of a control var id= $(this).attr('id').substring(9); var id_all= $(this).attr('id'); //Ask user for continue
<?php defined('_JEXEC') or die('Restricted access'); AImporter::model('addons'); AImporter::helper('bookpro'); $service_depart = json_decode($this->trips['depart']->params); $check = false; foreach ($service_depart as $service) { if (!empty($service)) { $check = true; } } if ($this->cart->filter['roundtrip']) { $service_return = json_decode($this->trips['return']->params); foreach ($service_return as $service) { if (!empty($service)) { $check = true; } } } if (!$check) { return; } $model = new BookProModeladdons(); ?> <script type="text/javascript"> jQuery(document).ready(function($){ jQuery(".addonClick").click(function(){ var addon= new Array(); $('.addonClick').each(function(){
/** * Link js or css file into html head. * * @param string $type source type, available values are 'js' or 'css' * @param array $names files names without extension and path */ static function link($type, $names) { $absMask = SITE_ROOT . DS . 'assets' . DS . $type . DS . '%s.' . $type; $langMask = SITE_ROOT . DS . 'assets' . DS . 'language' . DS . '%s.php'; $realMask = JURI::root() . 'components/' . OPTION . '/assets/' . $type . '/%s.' . $type; foreach ($names as $name) { $abs = sprintf($absMask, $name); $real = sprintf($realMask, $name); if (file_exists($abs)) { $document = JFactory::getDocument(); switch ($type) { case 'js': $document->addScript($real); AImporter::importFile(sprintf($langMask, $name), false); break; case 'css': AImporter::helper('document'); $document->addStyleSheet($real); break; } } else { JError::raiseError(500, 'File ' . $name . ' not found'); } } }
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: view.html.php 26 2012-07-08 16:07:54Z quannv $ **/ defined('_JEXEC') or die; AImporter::helper('tour'); class BookProViewItineraries extends JViewLegacy { protected $items; protected $state; protected $pagination; //protected $lists; public function display($tpl = null) { $this->tour_id = JFactory::getApplication()->input->get('tour_id'); $this->items = $this->get('Items'); $this->state = $this->get('State'); if ($this->tour_id) { $this->state->set('filter.tour_id', $this->tour_id); } else { $this->tour_id = $this->state->get('filter.tour_id'); } $this->pagination = $this->get('Pagination'); $this->tours_filter = TourHelper::getToursFilter('tour_id', $this->tour_id); if (count($errors = $this->get('Errors'))) {
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: view.html.php 23-06-2012 23:33:14 **/ // No direct access to this file defined('_JEXEC') or die('Restricted access'); AImporter::model('customer', 'order', 'passengers', 'orders'); //import needed JoomLIB helpers AImporter::helper('bookpro', 'request', 'paystatus', 'ordertype', 'orderstatus', 'currency', 'flight'); class BookproViewAgentorder extends JViewLegacy { /* * passenger of agent */ protected $item; protected $form; public function display($tpl = null) { $this->item = $this->get('Item'); $this->form = $this->get('Form'); $this->order = $this->item; if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode("\n", $errors)); return false; }
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id$ **/ defined('_JEXEC') or die('Restricted access'); AImporter::helper('transport'); ?> <?php echo JLayoutHelper::render('transport_process_bar', 5, JPATH_ROOT . '/components/com_bookpro/layouts'); ?> <?php echo BookProHelper::renderLayout('transport_info', $this->orderComplex); echo BookProHelper::renderLayout('passengers', $this->orderComplex->passengers); echo BookProHelper::renderLayout('addons', $this->orderComplex->addons); ?>
<?php /** * @package Bookpro * @author Ngo Van Quan * @link http://joombooking.com * @copyright Copyright (C) 2011 - 2012 Ngo Van Quan * @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html * @version $Id: controller.php 104 2012-08-29 18:01:09Z quannv $ **/ // Check to ensure this file is included in Joomla! defined('_JEXEC') or die; AImporter::helper('route'); class AdminUIHelper { static function startAdminArea($backEnd = true) { $doc = JFactory::getDocument(); $doc->addStyleSheet('components/com_bookpro/assets/css/jbtransport.css'); $uri = (string) JUri::getInstance(); $return = urlencode(base64_encode($uri)); $configRoute['route'] = 'index.php?option=com_config&view=component&component=' . OPTION . '&return=' . $return; $configRoute['params'] = array(); echo '<div id="j-sidebar-container" class="span2">'; JHtmlSidebar::addEntry(JText::_('COM_BOOKPRO_CPANEL'), 'index.php?option=com_bookpro'); echo JHtmlSidebar::render(); echo ' <div class="sidebar-nav">'; echo ' <ul class="nav nav-list" style="margin:0px;">'; echo self::listLink(JText::_('COM_BOOKPRO_BOOKINGS'), JRoute::_(ARoute::view('orders'))); echo self::listLink(JText::_('COM_BOOKPRO_TRANSPORT_ROUTE'), JRoute::_(ARoute::view('transports'))); echo '</ul>';