Changeset 789 for trunk/Modules/Finance/Finance.php
- Timestamp:
- Jan 16, 2016, 4:58:06 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Modules/Finance/Finance.php
r786 r789 540 540 'File' => array('Type' => 'TFile', 'Caption' => 'Soubor', 'Default' => '', 'Null' => true), 541 541 ), 542 'BeforeInsert' => array($this, 'BeforeInsert FinanceOperation'),542 'BeforeInsert' => array($this, 'BeforeInsertContract'), 543 543 )); 544 544 $this->System->FormManager->RegisterFormType('TContract', array( … … 668 668 return($Form->Values); 669 669 } 670 671 function BeforeInsertContract($Form) 672 { 673 if(array_key_exists('Time', $Form->Values)) $Year = date("Y", $Form->Values['Time']); 674 else $Year = date("Y", $Form->Values['ValidFrom']); 675 $Form->Values['BillCode'] = $this->System->Modules['Finance']->GetNextDocumentLineNumberId($Form->Values['DocumentLine'], $Year); 676 return($Form->Values); 677 } 670 678 }
Note:
See TracChangeset
for help on using the changeset viewer.