protected function populateState() { $input = JFactory::getApplication()->input; $return = $input->get('return', null, 'default', 'base64'); $this->setState('return_page', base64_decode($return)); $this->setState($this->getName() . '.addon', $this->addon); $this->setState($this->getName() . '.article', $this->article); $params = null; if ($this->addon) { if (is_string($this->addon->params)) { $params = new Registry($this->addon->params); } else { $params = $this->addon->params; } $this->addon->params = $params; } $this->setState($this->getName() . '.addon', $this->addon); if ($trigger_params = $this->trigger_params) { if (is_string($trigger_params)) { $trigger_params = new Registry($trigger_params); } if ($params) { $params->merge($trigger_params); } else { $params = $trigger_params; } } $this->setState('params', clone $params); parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * * to be called on the first call to the getState() method unless the model * * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * * @since 11.1 */ protected function populateState() { // Get the message id $id = isset($_GET['form_id']) ? (int) $_GET['form_id'] : 0; $this->setState('form.id', $id); parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * to be called on the first call to the getState() method unless the model * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * @since 1.6 */ protected function populateState() { $app = JFactory::getApplication('site'); // Load state from the request. $pk = $app->input->getInt('id'); $this->setState('article.id', $pk); parent::populateState(); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @since 1.6 * * @return void */ protected function populateState() { $this->app = JFactory::getApplication(); $this->input = $this->app->input; // Get the item main id $id = $this->input->getInt('id', null); $this->setState('companyresults.id', $id); // Load the parameters. parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * to be called on the first call to the getState() method unless the model * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * @since 2.5 */ protected function populateState() { $app = JFactory::getApplication(); // Get the message id $id = JRequest::getInt('id'); $this->setState('message.id', $id); // Load the parameters. $params = $app->getParams(); $this->setState('params', $params); parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * to be called on the first call to the getState() method unless the model * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * @since 2.5 */ protected function populateState() { // Get the message id $jinput = JFactory::getApplication()->input; $id = $jinput->get('id', 1, 'INT'); $this->setState('message.id', $id); // Load the parameters. $this->setState('params', JFactory::getApplication()->getParams()); parent::populateState(); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @since 1.6 */ protected function populateState() { parent::populateState(); $app = JFactory::getApplication(); /** @var $app JApplicationSite */ // Get the pk of the record from the request. $itemId = $app->input->getInt('id'); $this->setState($this->getName() . '.id', $itemId); // Load the parameters. $value = $app->getParams($this->option); $this->setState('params', $value); }
/** * Method to auto-populate the model state. * * Note. Calling getState in this method will result in recursion. * * @since 1.6 * * @return void */ protected function populateState() { $this->app = JFactory::getApplication(); $this->input = $this->app->input; // Get the itme main id $id = $this->input->getInt('id', null); $this->setState('publicresults.id', $id); // Load the parameters. $params = $this->app->getParams(); $this->setState('params', $params); parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * to be called on the first call to the getState() method unless the model * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * @since 1.6 */ protected function populateState() { $app = JFactory::getApplication(); $id = JRequest::getInt($this->pk_name); $this->setState(strtolower($this->model_key) . '.' . $this->pk_name, $id); $cmd = JRequest::getCmd('cmd', ''); $this->setState(strtolower($this->model_key) . '.cmd', $cmd); // Load the parameters. $params = $app->getParams(); $this->setState('params', $params); parent::populateState(); }
protected function populateState() { $app = JFactory::getApplication(); // Load state from the request. $pk = JRequest::getInt('title'); //echo $pk; $this->setState('gallery.id', $pk); // Load the parameters. $params = $app->getParams(); //$this->setState('params.id', $params->get('id')); $this->setState('params', $params); parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * to be called on the first call to the getState() method unless the model * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * @since 1.6 */ protected function populateState() { echo "in populate state"; $app = JFactory::getApplication(); $id = JRequest::getInt('id'); $this->setState('weight.id', $id); $cmd = JRequest::getCmd('cmd', ''); $this->setState('driver.cmd', $cmd); // Load the parameters. $params = $app->getParams(); $this->setState('params', $params); parent::populateState(); }
/** * Метод для авто-заполнения состояния модели. * * Заметка. Вызов метода getState в этом методе приведет к рекурсии. * * @return void */ protected function populateState() { $app = JFactory::getApplication(); // Получаем Id сообщения из Запроса. $id = $app->input->getInt('id', 0); // Добавляем Id сообщения в состояние модели. $this->setState('message.id', $id); // Загружаем глобальные параметры. $params = $app->getParams(); // Добавляем параметры в состояние модели. $this->setState('params', $params); parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * to be called on the first call to the getState() method unless the model * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * @since 1.6 */ protected function populateState() { $app = JFactory::getApplication(); // Get the map id $id = JRequest::getInt('id'); $this->setState('map.id', $id); $placemarklistid = JRequest::getVar('placemarklistid'); $this->setState('map.placemarklistid', $placemarklistid); $externalmarkerlink = JRequest::getVar('externalmarkerlink'); $this->setState('map.externalmarkerlink', $externalmarkerlink); // Load the parameters. $params = $app->getParams(); $this->setState('params', $params); parent::populateState(); }
protected function populateState() { $resourceId = JRequest::getInt('resourceId'); $defaultRequest = array('resourceId' => JRequest::getInt('resourceId'), 'state' => BFCHelper::getStayParam('state')); //echo var_dump($defaultRequest);die(); $this->setState('params', $defaultRequest); return parent::populateState(); }
protected function populateState() { $crewlistNumber = JRequest::getInt('crewslist', 0); $birdDate = explode('/', JRequest::getVar('birthDate', '//')); $customerData = array('crewId' => JRequest::getInt('crewId'), 'orderId' => JRequest::getInt('orderId'), 'merchantId' => JRequest::getInt('merchantId'), 'nation' => FormHelper::getOptionsFromSelect($_POST, 'nation'), 'culture' => FormHelper::getOptionsFromSelect($_POST, 'culture'), 'documentId' => FormHelper::getOptionsFromSelect($_POST, 'documentId'), 'crewslist' => $crewlistNumber, 'firstName' => JRequest::getVar('firstName'), 'lastName' => JRequest::getVar('lastName'), 'email' => JRequest::getVar('email'), 'gender' => FormHelper::getOptionsFromSelect($_POST, 'gender'), 'birthDate' => $birdDate[2] . '-' . $birdDate[1] . '-' . $birdDate[0], 'birthLocation' => JRequest::getVar('birthLocation'), 'address' => JRequest::getVar('address'), 'city' => JRequest::getVar('city'), 'province' => JRequest::getVar('province'), 'postalCode' => JRequest::getVar('postalCode'), 'phone' => JRequest::getVar('phone'), 'documentNumber' => JRequest::getVar('documentNumber'), 'documentRelease' => JRequest::getVar('documentRelease')); $customerDatas = array($customerData); for ($i = 0; $i < $crewlistNumber; $i++) { $birdDate = explode('/', JRequest::getVar('birthDate' . $i, '//')); $customerData1 = array('crewId' => JRequest::getInt('crewId' . $i), 'parentCrewId' => JRequest::getInt('parentCrewId' . $i), 'orderId' => JRequest::getInt('orderId' . $i), 'merchantId' => JRequest::getInt('merchantId' . $i), 'nation' => FormHelper::getOptionsFromSelect($_POST, 'nation' . $i), 'firstName' => JRequest::getVar('firstName' . $i), 'lastName' => JRequest::getVar('lastName' . $i), 'gender' => FormHelper::getOptionsFromSelect($_POST, 'gender' . $i), 'birthDate' => $birdDate[2] . '-' . $birdDate[1] . '-' . $birdDate[0], 'birthLocation' => JRequest::getVar('birthLocation' . $i)); $customerDatas[] = $customerData1; } $vars['crewId' . $i] = JRequest::getInt('crewId' . $i); $this->setState('params', array('orderId' => JRequest::getInt('orderId'), 'merchantId' => JRequest::getInt('merchantId'), 'crewId' => JRequest::getInt('crewId'), 'customerData' => $customerDatas)); return parent::populateState(); }
/** * Method to auto-populate the model state. * * This method should only be called once per instantiation and is designed * to be called on the first call to the getState() method unless the model * configuration flag to ignore the request is set. * * Note. Calling getState in this method will result in recursion. * * @return void * @since 1.6 */ protected function populateState() { $app = JFactory::getApplication(); // Get the category id $id = JRequest::getInt('id'); $this->setState('category.id', $id); //$message = "category ID : ".$id."<br />"; // Load the parameters. $params = $app->getParams(); $this->setState('params', $params); //$app->enqueueMessage('Populate State: '.$message, 'error'); parent::populateState(); }
protected function populateState() { $crewlistNumber = JRequest::getInt('crewslist', 0); $birdDate = explode('/', JRequest::getVar('birthDate', '//')); $nation = ''; $culture = ''; $documentId = ''; $gender = ''; if (isset($_POST['form'])) { $nation = FormHelper::getOptionsFromSelect($_POST, 'nation'); $culture = FormHelper::getOptionsFromSelect($_POST, 'culture'); $documentId = FormHelper::getOptionsFromSelect($_POST, 'documentId'); $gender = FormHelper::getOptionsFromSelect($_POST, 'gender'); } $customerData = array('CrewId' => JRequest::getInt('crewId'), 'OrderId' => JRequest::getInt('orderId'), 'MerchantId' => JRequest::getInt('merchantId'), 'Nation' => $nation, 'Culture' => $culture, 'DocumentId' => $documentId, 'crewslist' => $crewlistNumber, 'FirstName' => JRequest::getVar('firstName'), 'LastName' => JRequest::getVar('lastName'), 'Email' => JRequest::getVar('email'), 'Gender' => $gender, 'BirthDate' => $birdDate[2] . '-' . $birdDate[1] . '-' . $birdDate[0], 'BirthLocation' => JRequest::getVar('birthLocation'), 'Address' => JRequest::getVar('address'), 'City' => JRequest::getVar('city'), 'Province' => JRequest::getVar('province'), 'PostalCode' => JRequest::getVar('postalCode'), 'Phone' => JRequest::getVar('phone'), 'DocumentNumber' => JRequest::getVar('documentNumber'), 'DocumentReleaseDate' => JRequest::getVar('documentRelease')); $customerDatas = array($customerData); for ($i = 0; $i < $crewlistNumber; $i++) { $birdDate = explode('/', JRequest::getVar('birthDate' . $i, '//')); $nation = ''; $gender = ''; if (isset($_POST['form'])) { $nation = FormHelper::getOptionsFromSelect($_POST, 'nation' . $i); $gender = FormHelper::getOptionsFromSelect($_POST, 'gender' . $i); } $customerData1 = array('CrewId' => JRequest::getInt('crewId' . $i), 'ParentCrewId' => JRequest::getInt('parentCrewId' . $i), 'OrderId' => JRequest::getInt('orderId' . $i), 'MerchantId' => JRequest::getInt('merchantId' . $i), 'Nation' => $nation, 'FirstName' => JRequest::getVar('firstName' . $i), 'LastName' => JRequest::getVar('lastName' . $i), 'Gender' => $gender, 'BirthDate' => $birdDate[2] . '-' . $birdDate[1] . '-' . $birdDate[0], 'BirthLocation' => JRequest::getVar('birthLocation' . $i)); $customerDatas[] = $customerData1; } $vars['crewId' . $i] = JRequest::getInt('crewId' . $i); $this->setState('params', array('orderId' => JRequest::getInt('orderId'), 'merchantId' => JRequest::getInt('merchantId'), 'crewId' => JRequest::getInt('crewId'), 'customerData' => $customerDatas)); return parent::populateState(); }
/** * Method to auto-populate the model state. * * @return void * * @note Calling getState in this method will result in recursion. * * @see JModel::populateState * * @since 2.0.0 */ protected function populateState() { $id = JFactory::getApplication()->input->get('server'); $this->setState('server.id', $id); parent::populateState(); }
protected function populateState($ordering = null, $direction = null) { parent::populateState('default_column_name', 'ASC'); }
protected function populateState() { //echo var_dump($defaultRequest);die(); $actionmode = JRequest::getVar('actionmode', ''); $orderId = JRequest::getVar('orderId'); if (!isset($orderId)) { $orderId = JRequest::getVar('payedOrderId'); } $this->setState('params', array('actionmode' => $actionmode, 'orderId' => $orderId)); return parent::populateState(); }