/** * @Author: ANH DUNG Feb 03, 2015 * @Todo: update tenancy * @Param: $id * @sample link: /admin/tenancy/update/add_property/1/id/555/type/1/listing_id/0/user_id/266 */ public function actionUpdate($id) { try { $mTransactions = $this->loadModel($id); ProTransactions::CanUpdateTrans($mTransactions); if (isset($_GET['user_id'])) { // Jan 02, 2014 For backend // $this->ValidateLinkRecord($add_property, $listing_id); // OPEN IT $add_property = isset($_GET['add_property']) ? $_GET['add_property'] : $mTransactions->add_property; // ProTransactions::GetSomeInfoRecord($mTransactions, $add_property); ProTransactions::GetSomeInfoRecordWithNoOverideModel($mTransactions, $add_property); ProTransactions::HandlePost($mTransactions); } $this->render('update/record_existing_tenancy', array('mTransactions' => $mTransactions, 'actions' => $this->listActionsCanAccess)); } catch (Exception $e) { Yii::log("Exception " . print_r($e, true), 'error'); throw new CHttpException("Exception " . print_r($e, true)); } }