- Timestamp:
- Apr 16, 2008, 8:23:03 PM (17 years ago)
- Location:
- www/finance
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
www/finance/clenove.php
r74 r75 21 21 $Operations = array(); 22 22 $DbResult = $Database->query('(SELECT Time, Value, Text, Bill FROM FinanceCashFlow WHERE Subject='.$_GET['id'].') UNION ALL '. 23 '(SELECT TimeCreation as Time, (-Value) as Value, Text, Bill FROM FinanceClaimsLiabilities WHERE Subject='.$_GET['id'].') ORDER BY Time ');23 '(SELECT TimeCreation as Time, (-Value) as Value, Text, Bill FROM FinanceClaimsLiabilities WHERE Subject='.$_GET['id'].') ORDER BY Time DESC'); 24 24 while($DbRow = $DbResult->fetch_array()) 25 25 $Operations[] = $DbRow; -
www/finance/manage.php
r70 r75 182 182 { 183 183 //$Database->insert('FinanceSmallAsset', array()); 184 $Items[] = array('description' => $Device['name'], 'quantity' => $Device['count'], 'price' => $Device['price']);184 $Items[] = array('description' => $Device['name'], 'quantity' => $Device['count'], 'price' => 0); //$Device['price']); 185 185 $LastId = $Device['id']; 186 186 $TotalPrice += $Device['price'] * $Device['count']; … … 204 204 { 205 205 //$Database->insert('FinanceSmallAsset', array()); 206 $Items[] = array('description' => $Device['name'], 'quantity' => $Device['count'], 'price' => $Device['price']);206 $Items[] = array('description' => $Device['name'], 'quantity' => $Device['count'], 'price' => 0); //$Device['price']); 207 207 $TotalPrice += $Device['price'] * $Device['count']; 208 208 } 209 209 //print_r($Items); 210 $ InvoiceGenerator->CreateBill($Subject, $Items, $Time, $Time);210 $BillId = $InvoiceGenerator->CreateBill($Subject, $Items, $Time, $Time); 211 211 $DbResult = $Database->query('UPDATE network_devices SET TimeEnlistment = "'.TimeToMysqlDateTime($Time).'" WHERE used <> 0 AND date < "'.TimeToMysqlDateTime($Time).'" AND (id > '.$LastId.')'); 212 212 InsertLiability($Subject, 0, $Time, $BillId, 'Nákup infrastruktury', $Time);
Note:
See TracChangeset
for help on using the changeset viewer.