mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-02-21 15:54:22 +01:00
The invoices list displays the operator in case of offline payment
This commit is contained in:
parent
2592844ad0
commit
881cc97e8d
@ -1,5 +1,7 @@
|
|||||||
# Changelog Fab-manager
|
# Changelog Fab-manager
|
||||||
|
|
||||||
|
- Manager: a new role between the member and the administrator
|
||||||
|
- The invoices list displays the operator in case of offline payment
|
||||||
- Interface to manage partners
|
- Interface to manage partners
|
||||||
- Ability to define, per availability, a custom duration for the reservation slots
|
- Ability to define, per availability, a custom duration for the reservation slots
|
||||||
- Corrected the documentation about BOOK_SLOT_AT_SAME_TIME
|
- Corrected the documentation about BOOK_SLOT_AT_SAME_TIME
|
||||||
|
@ -575,6 +575,15 @@ Application.Controllers.controller('InvoicesController', ['$scope', '$state', 'I
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return the name of the operator that creates the invoice
|
||||||
|
*/
|
||||||
|
$scope.operatorName = function(invoice) {
|
||||||
|
if (!invoice.operator) return '';
|
||||||
|
|
||||||
|
return `${invoice.operator.first_name} ${invoice.operator.last_name}`;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Setup the feature-tour for the admin/invoices page.
|
* Setup the feature-tour for the admin/invoices page.
|
||||||
* This is intended as a contextual help (when pressing F1)
|
* This is intended as a contextual help (when pressing F1)
|
||||||
|
@ -36,12 +36,12 @@
|
|||||||
<table class="table invoices-list" ng-if="invoices.length > 0">
|
<table class="table invoices-list" ng-if="invoices.length > 0">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th style="width:5%"></th>
|
<th style="width:8%"></th>
|
||||||
<th style="width:15%"><a href="" ng-click="setOrderInvoice('reference')">{{ 'app.admin.invoices.invoice_num' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-numeric-asc': orderInvoice=='reference', 'fa fa-sort-numeric-desc': orderInvoice=='-reference', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
<th style="width:14%"><a href="" ng-click="setOrderInvoice('reference')">{{ 'app.admin.invoices.invoice_num' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-numeric-asc': orderInvoice=='reference', 'fa fa-sort-numeric-desc': orderInvoice=='-reference', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
||||||
|
|
||||||
<th style="width:20%"><a href="" ng-click="setOrderInvoice('date')">{{ 'app.admin.invoices.date' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-numeric-asc': orderInvoice=='date', 'fa fa-sort-numeric-desc': orderInvoice=='-date', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
<th style="width:19%"><a href="" ng-click="setOrderInvoice('date')">{{ 'app.admin.invoices.date' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-numeric-asc': orderInvoice=='date', 'fa fa-sort-numeric-desc': orderInvoice=='-date', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
||||||
|
|
||||||
<th style="width:10%"><a href="" ng-click="setOrderInvoice('total')"> {{ 'app.admin.invoices.price' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-numeric-asc': orderInvoice=='total', 'fa fa-sort-numeric-desc': orderInvoice=='-total', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
<th style="width:9%"><a href="" ng-click="setOrderInvoice('total')"> {{ 'app.admin.invoices.price' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-numeric-asc': orderInvoice=='total', 'fa fa-sort-numeric-desc': orderInvoice=='-total', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
||||||
|
|
||||||
<th style="width:20%"><a href="" ng-click="setOrderInvoice('name')">{{ 'app.admin.invoices.customer' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-alpha-asc': orderInvoice=='name', 'fa fa-sort-alpha-desc': orderInvoice=='-name', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
<th style="width:20%"><a href="" ng-click="setOrderInvoice('name')">{{ 'app.admin.invoices.customer' | translate }} <i class="fa fa-arrows-v" ng-class="{'fa fa-sort-alpha-asc': orderInvoice=='name', 'fa fa-sort-alpha-desc': orderInvoice=='-name', 'fa fa-arrows-v': orderInvoice }"></i></a></th>
|
||||||
|
|
||||||
@ -50,9 +50,14 @@
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr ng-repeat="invoice in invoices">
|
<tr ng-repeat="invoice in invoices">
|
||||||
<td class="chained-indicator">
|
<td>
|
||||||
<i class="fa fa-link chained" ng-show="invoice.chained_footprint"/>
|
<span class="chained-indicator">
|
||||||
<i class="fa fa-chain-broken broken" ng-hide="invoice.chained_footprint"/>
|
<i class="fa fa-link chained" ng-show="invoice.chained_footprint"></i>
|
||||||
|
<i class="fa fa-chain-broken broken" ng-hide="invoice.chained_footprint"></i>
|
||||||
|
</span>
|
||||||
|
<span class="operator help-cursor m-l-sm" ng-show="invoice.operator && invoice.operator.id !== invoice.user_id">
|
||||||
|
<i class="fa fa-user-circle" title="{{ 'app.admin.invoices.operator_' | translate }} {{operatorName(invoice)}}"></i>
|
||||||
|
</span>
|
||||||
</td>
|
</td>
|
||||||
<td>{{ invoice.reference }}</td>
|
<td>{{ invoice.reference }}</td>
|
||||||
<td ng-if="!invoice.is_avoir">{{ invoice.date | amDateFormat:'L LTS' }}</td>
|
<td ng-if="!invoice.is_avoir">{{ invoice.date | amDateFormat:'L LTS' }}</td>
|
||||||
|
@ -16,4 +16,10 @@ json.array!(@invoices) do |invoice|
|
|||||||
json.date invoice.is_a?(Avoir) ? invoice.avoir_date : invoice.created_at
|
json.date invoice.is_a?(Avoir) ? invoice.avoir_date : invoice.created_at
|
||||||
json.prevent_refund invoice.prevent_refund?
|
json.prevent_refund invoice.prevent_refund?
|
||||||
json.chained_footprint invoice.check_footprint
|
json.chained_footprint invoice.check_footprint
|
||||||
|
if invoice.operator_profile
|
||||||
|
json.operator do
|
||||||
|
json.id invoice.operator_profile.user_id
|
||||||
|
json.extract! invoice.operator_profile, :first_name, :last_name
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
@ -374,6 +374,7 @@ en:
|
|||||||
accounting_periods: "Accounting periods"
|
accounting_periods: "Accounting periods"
|
||||||
invoices_list: "Invoices list"
|
invoices_list: "Invoices list"
|
||||||
filter_invoices: "Filter invoices"
|
filter_invoices: "Filter invoices"
|
||||||
|
operator_: "Operator:"
|
||||||
invoice_num_: "Invoice #:"
|
invoice_num_: "Invoice #:"
|
||||||
customer_: "Customer:"
|
customer_: "Customer:"
|
||||||
date_: "Date:"
|
date_: "Date:"
|
||||||
|
@ -374,6 +374,7 @@ fr:
|
|||||||
accounting_periods: "Périodes comptables"
|
accounting_periods: "Périodes comptables"
|
||||||
invoices_list: "Liste des factures"
|
invoices_list: "Liste des factures"
|
||||||
filter_invoices: "Filtrer les factures"
|
filter_invoices: "Filtrer les factures"
|
||||||
|
operator_: "Opérateur :"
|
||||||
invoice_num_: "Facture n° :"
|
invoice_num_: "Facture n° :"
|
||||||
customer_: "Client :"
|
customer_: "Client :"
|
||||||
date_: "Date :"
|
date_: "Date :"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user