Commit 57be95bc by François C.

Add MonA total_eligible

parent 2a9fa667
# Copyright (C) 2020 - Today: GRAP (http://www.grap.coop) # Copyright (C) 2020 - Today: GRAP (http://www.grap.coop)
# @author: Sylvain LE GAL (https://twitter.com/legalsylvain) # @author: Sylvain LE GAL (https://twitter.com/legalsylvain)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
# TODO: Rendre l'affichage MonA paramétrable
{ {
"name": "Point Of Sale - Meal Voucher", "name": "Point Of Sale - Meal Voucher",
"summary": "Handle meal vouchers in Point of Sale" "summary": "Handle meal vouchers in Point of Sale"
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
background: rgba(255,255,255,0.4); background: rgba(255,255,255,0.4);
} }
.payment-screen div.meal-voucher-summary{ .payment-screen div.meal-voucher-summary, .payment-screen div.monA-summary{
border-top: dashed 1px gainsboro; border-top: dashed 1px gainsboro;
} }
...@@ -45,20 +45,20 @@ ...@@ -45,20 +45,20 @@
color: red; color: red;
} }
.payment-screen div.meal-voucher-summary table{ .payment-screen div.meal-voucher-summary table, .payment-screen div.monA-summary table{
width: 100%; width: 100%;
} }
.payment-screen div.meal-voucher-summary tbody{ .payment-screen div.meal-voucher-summary tbody, .payment-screen div.monA-summary tbody{
background: white; background: white;
} }
.payment-screen div.meal-voucher-summary th { .payment-screen div.meal-voucher-summary th , .payment-screen div.monA-summary th{
font-size: 16px; font-size: 16px;
padding: 8px; padding: 8px;
text-align: center; text-align: center;
} }
.payment-screen div.meal-voucher-summary td { .payment-screen div.meal-voucher-summary td, .payment-screen div.monA-summary td{
font-size: 22px; font-size: 22px;
padding: 8px 12px; padding: 8px 12px;
} }
......
...@@ -424,6 +424,9 @@ odoo.define("pos_meal_voucher.screens", function (require) { ...@@ -424,6 +424,9 @@ odoo.define("pos_meal_voucher.screens", function (require) {
this.$(".meal-voucher-summary").addClass("oe_hidden"); this.$(".meal-voucher-summary").addClass("oe_hidden");
} }
// Update MonA summary
this.el.querySelector("#monA-eligible-amount").textContent = this.format_currency(total_eligible)
}, },
order_is_valid: function(force_validation) { order_is_valid: function(force_validation) {
......
...@@ -56,6 +56,23 @@ ...@@ -56,6 +56,23 @@
</tbody> </tbody>
</table> </table>
</div> </div>
<div class="monA-summary">
<table class="monA-summary">
<thead>
<tr>
<th colspan="2">MonA</th>
</tr>
</thead>
<tbody>
<tr>
<td>Total Eligible</td>
<td>
<span id="monA-eligible-amount">0.00 €</span>
</td>
</tr>
</tbody>
</table>
</div>
</t> </t>
</t> </t>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment