From 3cb58782934f4638b3a4b7894c30c492feca67a1 Mon Sep 17 00:00:00 2001 From: Aung Myo Date: Wed, 14 Jun 2017 10:18:48 +0630 Subject: [PATCH 1/3] update sale --- app/views/transactions/sales/show.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/transactions/sales/show.html.erb b/app/views/transactions/sales/show.html.erb index 484de762..b149ebe7 100644 --- a/app/views/transactions/sales/show.html.erb +++ b/app/views/transactions/sales/show.html.erb @@ -23,7 +23,7 @@ Receipt Date Receipt no Cashier - OSales status + Sales status Receipt generated at From f0fe589ec6b910e42349ba5647f942ed746710fa Mon Sep 17 00:00:00 2001 From: Phyo Date: Wed, 14 Jun 2017 10:43:19 +0630 Subject: [PATCH 2/3] Payment conflict in Del key --- app/views/origami/payments/show.html.erb | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/app/views/origami/payments/show.html.erb b/app/views/origami/payments/show.html.erb index 1eb547e6..490ec341 100644 --- a/app/views/origami/payments/show.html.erb +++ b/app/views/origami/payments/show.html.erb @@ -93,7 +93,7 @@
Cash
-
<%= @cash %>
+
<%= @cash %>

@@ -193,8 +193,11 @@ $(document).on('click', '.cashier_number', function(event){ update_balance(); break; case 'del' : - var cash=$('#amount').text(); - $('#cash').text(cash.substr(0,cash.length-1)); + var cash=$('#cash').text(); + if(cash.length == 1) + $('#cash').text("0.0"); + else + $('#cash').text(cash.substr(0,cash.length-1)); update_balance(); break; case 'clr': @@ -258,7 +261,7 @@ function update_balance(){ var card = $('#others').text(); var amount_due = $('#amount_due').text(); var total = parseFloat(cash) + parseFloat(credit) + parseFloat(card) - var result = amount_due - total + var result = amount_due - total; $('#balance').text(result.toFixed(2)); } From c155c86970d0279c79322b1f3802791c966ff026 Mon Sep 17 00:00:00 2001 From: Aung Myo Date: Wed, 14 Jun 2017 10:43:27 +0630 Subject: [PATCH 3/3] update checkbox in customer view --- app/views/crm/customers/index.html.erb | 2 ++ app/views/origami/customers/index.html.erb | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/views/crm/customers/index.html.erb b/app/views/crm/customers/index.html.erb index f3819466..bff00d82 100644 --- a/app/views/crm/customers/index.html.erb +++ b/app/views/crm/customers/index.html.erb @@ -138,6 +138,8 @@ $(function() { $(document).on('click',".customer_tr",function(){ // if(this.checked){ + $(this).closest('tr').find('.checkbox_check').prop( "checked", true ); + //$( "#checkbox_check" ).prop( "checked", true ); var sale_id = $("#sale_id").val() || 0; var customer_id = $(this).attr('data-ref'); diff --git a/app/views/origami/customers/index.html.erb b/app/views/origami/customers/index.html.erb index 1c6bebaa..b58ca35a 100644 --- a/app/views/origami/customers/index.html.erb +++ b/app/views/origami/customers/index.html.erb @@ -136,7 +136,7 @@ $(document).on('click',".customer_tr",function(){ // if(this.checked){ - + $(this).closest('tr').find('.checkbox_check').prop( "checked", true ); var sale_id = $("#sale_id").val() || 0; var customer_id = $(this).attr('data-ref');