Changeset 966 for trunk


Ignore:
Timestamp:
Feb 10, 2024, 11:30:10 PM (11 months ago)
Author:
chronos
Message:
  • Added: Show how much money is missing from treasury check.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Modules/Finance/Finance.php

    r960 r966  
    300300          '`Value20` * 20 + `Value50` * 50 + `Value100` * 100 + `Value200` * 200 + '.
    301301          '`Value500` * 500 + `Value1000` * 1000 + `Value2000` * 2000 + `Value5000` * 5000)'),
     302        'Missing' => array('Type' => 'Integer', 'Caption' => 'Chybí', 'Default' => '0', 'Suffix' => 'Kč', 'ReadOnly' => true,
     303          'SQL' => '(`Value1` * 1 + `Value2` * 2 + `Value5` * 5 + `Value10` * 10 + '.
     304          '`Value20` * 20 + `Value50` * 50 + `Value100` * 100 + `Value200` * 200 + '.
     305          '`Value500` * 500 + `Value1000` * 1000 + `Value2000` * 2000 + `Value5000` * 5000) - '.
     306          '(SELECT (T2.`Value1` * 1 + T2.`Value2` * 2 + T2.`Value5` * 5 + T2.`Value10` * 10 + '.
     307          'T2.`Value20` * 20 + T2.`Value50` * 50 + T2.`Value100` * 100 + T2.`Value200` * 200 + '.
     308          'T2.`Value500` * 500 + T2.`Value1000` * 1000 + T2.`Value2000` * 2000 + T2.`Value5000` * 5000) + '.
     309          '(SELECT SUM(T3.Value) FROM FinanceOperation AS T3 WHERE (T3.Time < TX.Time) AND (T3.Time > T2.Time) AND (T3.Treasury=TX.Treasury))'.
     310          ' FROM FinanceTreasuryCheck AS T2 WHERE (T2.Time < TX.Time) ORDER BY T2.Time DESC LIMIT 1)'),
    302311      ),
    303312    ));
Note: See TracChangeset for help on using the changeset viewer.