/** * 网站内容修改 */ public function editAction() { if ($this->_request->isPost()) { $aWebSite = $this->_checkData('update'); if (empty($aWebSite)) { return null; } $aWebSite['iWebSiteID'] = intval($this->getParam('iWebSiteID')); $aOldWebSite = Model_WebSite::getDetail($aWebSite['iWebSiteID']); if (empty($aOldWebSite)) { return $this->showMsg('网站内容不存在!', false); } if (1 == Model_WebSite::updData($aWebSite)) { return $this->showMsg('网站内容信息更新成功!', true); } else { return $this->showMsg('网站内容信息更新失败!', false); } } else { $iWebSiteID = intval($this->getParam('id')); $aWebSite = Model_WebSite::getDetail($iWebSiteID); $this->assign('aWebSite', $aWebSite); $parentWebsite = Model_WebSite::getList(array('iParentID' => 0, 'iStatus' => 1), $iPage); $this->assign('parentWebsite', $parentWebsite['aList']); $this->assign('iType', Model_WebSite::$iType); } }
/** * 案例中心 */ public function caseAction() { $sType = 'case'; if (intval($sType) > 0) { $aData = Model_WebSite::getDetail((int) $sType); } else { $aData = Model_WebSite::getRow(array('where' => array('sPage' => $sType))); } if (empty($aData)) { return $this->show404('内容不存在!'); } $this->assign('aData', $aData); $this->setMeta('help_page', $aData); $this->assign('sTopMenu', 'case'); }