Added transaction model writeOff function, and a new statement_entry WRITEOFF type. Not a big deal, but it makes presentation a bit more straightforward.
git-svn-id: file:///svn-source/pmgr/branches/yafr_20090716@508 97e9348a-65ac-dc4b-aefc-98561f571b83
This commit is contained in:
@@ -35,7 +35,7 @@ class StatementEntry extends AppModel {
|
||||
}
|
||||
|
||||
function creditTypes() {
|
||||
return array('DISBURSEMENT', 'WAIVER', 'REVERSAL', 'SURPLUS');
|
||||
return array('DISBURSEMENT', 'WAIVER', 'REVERSAL', 'WRITEOFF', 'SURPLUS');
|
||||
}
|
||||
|
||||
function voidTypes() {
|
||||
@@ -125,14 +125,14 @@ class StatementEntry extends AppModel {
|
||||
|
||||
$ret = array();
|
||||
if (!$this->verifyStatementEntry($entry))
|
||||
return array('error' => true, 'verify_data' => $entry) + $ret;
|
||||
return $this->prReturn(array('error' => true, 'verify_data' => $entry) + $ret);
|
||||
|
||||
$this->pr(20, array('checkpoint' => 'Pre-Save')
|
||||
+ compact('entry'));
|
||||
|
||||
$this->create();
|
||||
if (!$this->save($entry))
|
||||
return array('error' => true, 'save_data' => $entry) + $ret;
|
||||
return $this->prReturn(array('error' => true, 'save_data' => $entry) + $ret);
|
||||
|
||||
$ret['statement_entry_id'] = $this->id;
|
||||
return $this->prReturn($ret + array('error' => false));
|
||||
|
||||
Reference in New Issue
Block a user