public function setNature($nature) { $this->__load(); return parent::setNature($nature); }
public function addTransactionTypeAction() { $form = new Form_Iadmin_TransactionTypeAdd(); if ($this->_request->isPost()) { if ($this->_request->getPost()) { $form_values = $this->_request->getPost(); $transaction_type = new TransactionTypes(); $transaction_type->setTransactionTypeName($form_values['transaction_type_name']); $transaction_type->setNature($form_values['nature']); $transaction_type->setIsAdjustment($form_values['is_adjustment']); $transaction_type->setStatus($form_values['status']); $created_by = $this->_em->find('Users', $this->_userid); $transaction_type->setCreatedBy($created_by); $transaction_type->setCreatedDate(App_Tools_Time::now()); $transaction_type->setModifiedBy($created_by); $transaction_type->setModifiedDate(App_Tools_Time::now()); $this->_em->persist($transaction_type); $this->_em->flush(); } } $this->_redirect("/iadmin/manage-products/transaction-type?success=1"); }