Пример #1
0
 public function oldaddAction()
 {
     if ($this->getRequest()->isPost()) {
         $_data = $this->getRequest()->getPost();
         //print_r($_data);exit();
         try {
             $_dbmodel = new Application_Model_DbTable_DbPayout();
             $_dbmodel->addPayout($_data);
             Application_Form_FrmMessage::Sucessfull('ការ​បញ្ចូល​​ជោគ​ជ័យ', "/loan/payout/index");
         } catch (Exception $e) {
             echo $e->getMessage();
             exit;
             $this->view->msg = 'ការ​បញ្ចូល​មិន​ជោគ​ជ័យ';
         }
     }
     $this->view->invoice_no = Application_Model_GlobalClass::getInvoiceWithdraw(6);
     $sender = new Application_Model_DbTable_DbSender();
     $this->view->senderlist = $sender->getAllSenderBorrow();
     $db_keycode = new Application_Model_DbTable_DbKeycode();
     $this->view->keycode = $db_keycode->getKeyCodeMiniInv();
     $session_user = new Zend_Session_Namespace('auth');
     $this->view->user_name = $session_user->last_name . ' ' . $session_user->first_name;
     $cur = new Application_Model_DbTable_DbCurrencies();
     $currency = $cur->getCurrencyList();
     $this->view->currency = $this->_helpfilteroption($currency);
     $curr = $this->_helpfilteroption($currency);
     array_unshift($curr, array('id' => '-1', "name" => "សងប្រភេទប្រាក់ផ្សេង", 'symbol' => 'other'));
     $this->view->pay_currencytype = $curr;
     $db_rate = new Application_Model_DbTable_DbPayment();
     $this->view->rate = $db_rate->getRateAll();
 }