@@ -325,9 +325,10 @@
var customer_name = '';
var membership_id = '';
var membership_type = '';
+ var receipt_no = $("#receipt_no").text() || 0;
setTimeout(function(){
- code=getQRCode();
- if(sale_id != 0 && code != ""){
+ code=getQRCode();
+ if(sale_id != 0 && code != ""){
$.ajax({
type: "POST",
url: "/origami/"+sale_id+"/send_account" ,
@@ -343,6 +344,7 @@
url: "<%=origami_payment_paymal_path%>",
data: {payment_amount:payment_amount,membership_id:0,sale_id:sale_id,transaction_ref:data.transaction_ref,account_no:code},
success: function(result){
+
if(result.status == true){
swal({
title: "Information!",
diff --git a/app/views/origami/paymal/index.html.erb b/app/views/origami/paymal/index.html.erb
index 5594eb13..6818fbad 100644
--- a/app/views/origami/paymal/index.html.erb
+++ b/app/views/origami/paymal/index.html.erb
@@ -328,6 +328,7 @@
var payment_amount = parseFloat($("#used_amount").text());
setTimeout(function(){
code=getQRCode();
+ alert(code)
if(sale_id != 0 && code != ""){
$.ajax({
type: "POST",
@@ -344,6 +345,7 @@
url: "<%=origami_payment_paymal_path%>",
data: {payment_amount:payment_amount,membership_id:0,sale_id:sale_id,transaction_ref:data.transaction_ref,account_no:code},
success: function(result){
+ alert(result)
if(result.status == true){
swal({
title: "Information!",
diff --git a/config/secrets.yml b/config/secrets.yml
index 6e8b73d4..b0d7c5c8 100755
--- a/config/secrets.yml
+++ b/config/secrets.yml
@@ -24,7 +24,7 @@ test:
# instead read values from the environment.
production:
secret_key_base: c4bc81065013f9a3506d385bcbd49586c42e586488144b0de90c7da36867de9fa880f46b5c4f86f0ce9b7c783bb5a73bdb0e5605a47716567294390e726d3e22
- sx_provision_url: connect.smartsales.asia/api #192.168.1.147:3002/api
+ sx_provision_url: https://connect.pos-myanmar.com/api #192.168.1.147:3002/api
server_mode: application
cipher_type: AES-256-CBC
sx_key: Wh@t1$C2L
diff --git a/db/migrate/20170626191519_create_shift_sales.rb b/db/migrate/20170626191519_create_shift_sales.rb
index f18a2c1c..bd19a8cf 100755
--- a/db/migrate/20170626191519_create_shift_sales.rb
+++ b/db/migrate/20170626191519_create_shift_sales.rb
@@ -21,7 +21,7 @@ class CreateShiftSales < ActiveRecord::Migration[5.1]
t.integer :dining_count, :default => 0
t.integer :takeaway_count, :default => 0
t.integer :member_count, :default => 0
- t.decimal :total_rounding,, :precision => 10, :scale => 2, :null => false, :default => 0.00
+ t.decimal :total_rounding, :precision => 10, :scale => 2, :null => false, :default => 0.00
t.integer :total_receipt, :default => 0
t.decimal :total_void, :default => 0
t.timestamps