Overview
Comment: | Fix: remove compare_year criteria when not useful |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk | stable |
Files: | files | file ages | folders |
SHA3-256: |
466fc7c89b92da85fa2f3a1726a7656b |
User & Date: | bohwaz on 2022-01-09 18:49:16 |
Other Links: | manifest | tags |
Context
2022-01-10
| ||
17:15 | Add SECURITY policy file for Github check-in: 61572f78dc user: bohwaz tags: trunk | |
12:43 | Merge with trunk check-in: ea0c0a5981 user: bohwaz tags: dev | |
2022-01-09
| ||
18:49 | Fix: remove compare_year criteria when not useful check-in: 466fc7c89b user: bohwaz tags: trunk, stable | |
2022-01-08
| ||
19:44 | Fix when there are no users selected check-in: d09963902c user: bohwaz tags: trunk, stable | |
Changes
Modified src/include/lib/Garradin/Accounting/Reports.php from [f4d459c763] to [4ecd1e93c2].
︙ | ︙ | |||
293 294 295 296 297 298 299 300 301 302 303 304 305 306 | } return $out; } static public function getTrialBalance(array $criterias): array { return self::getClosingSumsWithAccounts($criterias, null, false, false); } static public function getBalanceSheet(array $criterias): array { $accounts = ['asset' => [], 'liability' => []]; $sums = $sums2 = $change = ['asset' => 0, 'liability' => 0]; | > | 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 | } return $out; } static public function getTrialBalance(array $criterias): array { unset($criterias['compare_year']); return self::getClosingSumsWithAccounts($criterias, null, false, false); } static public function getBalanceSheet(array $criterias): array { $accounts = ['asset' => [], 'liability' => []]; $sums = $sums2 = $change = ['asset' => 0, 'liability' => 0]; |
︙ | ︙ |
Modified src/templates/acc/reports/_header.tpl from [9a64ef6667] to [b7e786c6bf].
1 2 3 4 5 6 7 8 | <div class="year-header"> <nav class="tabs noprint"> <ul> {if isset($analytical) || $current == 'analytical_ledger'} <li><strong><a href="{$admin_url}acc/reports/projects.php">Projets</a></strong></li> {/if} {if $current == 'analytical_ledger'} | | | | | | | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | <div class="year-header"> <nav class="tabs noprint"> <ul> {if isset($analytical) || $current == 'analytical_ledger'} <li><strong><a href="{$admin_url}acc/reports/projects.php">Projets</a></strong></li> {/if} {if $current == 'analytical_ledger'} <li class="current"><a href="{$admin_url}acc/reports/ledger.php?{$criterias_query_no_compare}">Grand livre analytique</a></li> {else} <li{if $current == "graphs"} class="current"{/if}><a href="{$admin_url}acc/reports/graphs.php?{$criterias_query_no_compare}">Graphiques</a></li> <li{if $current == "trial_balance"} class="current"{/if}><a href="{$admin_url}acc/reports/trial_balance.php?{$criterias_query_no_compare}">Balance générale</a></li> <li{if $current == "journal"} class="current"{/if}><a href="{$admin_url}acc/reports/journal.php?{$criterias_query_no_compare}">Journal général</a></li> <li{if $current == "ledger"} class="current"{/if}><a href="{$admin_url}acc/reports/ledger.php?{$criterias_query_no_compare}">Grand livre</a></li> <li{if $current == "statement"} class="current"{/if}><a href="{$admin_url}acc/reports/statement.php?{$criterias_query}">Compte de résultat</a></li> <li{if $current == "balance_sheet"} class="current"{/if}><a href="{$admin_url}acc/reports/balance_sheet.php?{$criterias_query}">Bilan</a></li> {/if} </ul> </nav> <h2>{$config.nom_asso} — {$title}</h2> |
︙ | ︙ |
Modified src/www/admin/acc/reports/_inc.php from [d05357fbdb] to [e27f27583d].
︙ | ︙ | |||
46 47 48 49 50 51 52 53 54 | } if ($y2 = Years::get((int)qg('compare_year'))) { $tpl->assign('year2', $y2); $criterias['compare_year'] = $y2->id; } $tpl->assign('criterias', $criterias); $tpl->assign('criterias_query', http_build_query($criterias)); | > > > > | 46 47 48 49 50 51 52 53 54 55 56 57 58 | } if ($y2 = Years::get((int)qg('compare_year'))) { $tpl->assign('year2', $y2); $criterias['compare_year'] = $y2->id; } $criterias_query = $criterias; unset($criterias_query['compare_year']); $tpl->assign('criterias', $criterias); $tpl->assign('criterias_query', http_build_query($criterias)); $tpl->assign('criterias_query_no_compare', http_build_query($criterias_query)); |