Пример #1
0
 function _ProductDetail()
 {
     global $objDatabase, $_ARRAYLANG;
     if (isset($_POST['submitContactForm'])) {
         EgovManager::_saveOrder();
     }
     $this->objTemplate->loadTemplateFile('module_gov_product_insert.html');
     $this->_pageTitle = $_ARRAYLANG['TXT_EGOV_RESERVATION'];
     $this->objTemplate->setVariable(array('TXT_EGOV_RESERVATION' => $_ARRAYLANG['TXT_EGOV_RESERVATION']));
     if (empty($_REQUEST['id'])) {
         return false;
     }
     $product_id = $_REQUEST['id'];
     $query = "\n            SELECT product_id, product_name, product_desc, product_price " . "FROM " . DBPREFIX . "module_egov_products\n             WHERE product_id={$product_id}\n        ";
     $objResult = $objDatabase->Execute($query);
     if ($objResult && $objResult->RecordCount()) {
         $FormSource = $this->getSourceCodeBackend($product_id, false, true);
         $this->objTemplate->setVariable(array('EGOV_PRODUCT_TITLE' => $objResult->fields['product_name'], 'EGOV_PRODUCT_ID' => $objResult->fields['product_id'], 'EGOV_PRODUCT_DESC' => $objResult->fields['product_desc'], 'EGOV_FORM' => $FormSource));
     }
     return true;
 }