115 lines
4.2 KiB
HTML
115 lines
4.2 KiB
HTML
<!-- vim: set tw=80 ts=2 sw=2 sts=2: -->
|
|
<!--
|
|
This file is part of Accountant.
|
|
|
|
Accountant is free software: you can redistribute it and/or modify
|
|
it under the terms of the GNU Affero General Public License as published by
|
|
the Free Software Foundation, either version 3 of the License, or
|
|
(at your option) any later version.
|
|
|
|
Accountant is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU Affero General Public License for more details.
|
|
|
|
You should have received a copy of the GNU Affero General Public License
|
|
along with Accountant. If not, see <http://www.gnu.org/licenses/>.
|
|
-->
|
|
<div>
|
|
<div class="row">
|
|
<div class="col-md-9">
|
|
<balance-chart on-update="operationsCtrl.onUpdate(minDate, maxDate)"/>
|
|
</div>
|
|
<div class="col-md-3">
|
|
<category-chart
|
|
min-date="operationsCtrl.minDate"
|
|
max-date="operationsCtrl.maxDate"/>
|
|
</div>
|
|
</div>
|
|
|
|
<div class="row">
|
|
<table class="table table-striped table-condensed table-hover">
|
|
<thead>
|
|
<tr>
|
|
<th class="col-md-1">Date d'op.</th>
|
|
<th>Libellé de l'opération</th>
|
|
<th class="col-md-1">Montant</th>
|
|
<th class="col-md-1">Solde</th>
|
|
<th class="col-md-2">Catégorie</th>
|
|
<th class="col-md-2">Actions</th>
|
|
</tr>
|
|
</thead>
|
|
|
|
<tbody>
|
|
<tr>
|
|
<td colspan="6">
|
|
<button class="btn btn-success" ng-click="operationsCtrl.add()">
|
|
Ajouter
|
|
</button>
|
|
</td>
|
|
</tr>
|
|
|
|
<tr id="{{ operation.id }}" class="form-inline"
|
|
ng-class="{stroke: operation.canceled, italic: !operation.confirmed,
|
|
warning: operation.balance < 0, danger: operation.balance < operationsCtrl.account.authorized_overdraft}"
|
|
ng-repeat="operation in operationsCtrl.operations | orderBy:'+':true">
|
|
<td>
|
|
{{ operation.operation_date | date:"yyyy-MM-dd" }}
|
|
</td>
|
|
|
|
<td>
|
|
{{ operation.label }}
|
|
</td>
|
|
|
|
<td>
|
|
{{ operation.value | currency:"€" }}
|
|
</td>
|
|
|
|
<td ng-class="{'text-warning': operation.balance < 0, 'text-danger':
|
|
operation.balance < operationsCtrl.account.authorized_overdraft}">
|
|
{{ operation.balance | currency:"€" }}
|
|
</td>
|
|
|
|
<td>
|
|
{{ operation.category }}
|
|
</td>
|
|
|
|
<td>
|
|
<div class="btn-group btn-group-xs">
|
|
<!-- Edit operation, for non-canceled operation. -->
|
|
<button type="button" class="btn btn-default"
|
|
ng-if="!operation.canceled"
|
|
ng-click="operationsCtrl.modify(operation)" title="edit">
|
|
<span class="fa fa-pencil-square-o"></span>
|
|
</button>
|
|
|
|
<!-- Toggle pointed operation, for non-canceled operations. -->
|
|
<button type="button" class="btn btn-default"
|
|
ng-if="!operation.canceled"
|
|
ng-click="operationsCtrl.togglePointed(operation)"
|
|
ng-class="{active: operation.pointed}" title="point">
|
|
<span ng-class="{'fa fa-check-square-o': operation.pointed, 'fa fa-square-o': !operation.pointed}"></span>
|
|
</button>
|
|
|
|
<!-- Toggle canceled operation. -->
|
|
<button type="button" class="btn btn-default"
|
|
ng-click="operationsCtrl.toggleCanceled(operation)"
|
|
ng-if="operation.scheduled_operation_id && !rowform.$visible"
|
|
ng-class="{active: operation.canceled}" title="cancel">
|
|
<span class="fa fa-remove"></span>
|
|
</button>
|
|
|
|
<!-- Delete operation, with confirm. -->
|
|
<button type="button" class="btn btn-default"
|
|
ng-if="operation.id && !operation.scheduled_operation_id"
|
|
ng-click="operationsCtrl.delete(operation)">
|
|
<span class="fa fa-trash-o"></span>
|
|
</button>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|