update feedback testing
This commit is contained in:
@@ -155,7 +155,7 @@
|
||||
$('#mpu_pay').on('click',function(){
|
||||
var amount = $('#amount').text();
|
||||
var sale_id = "<%= @sale_id %>";
|
||||
if(parseFloat(amount) <= parseFloat($("#validamount").attr("value")) ){
|
||||
if(parseFloat(amount) <= parseFloat($("#validamount").attr("value")) && amount > 0){
|
||||
//start member discount 5% by pay card
|
||||
var sub_total = $('#sub-total').text();
|
||||
var member_id = $('#membership_id').text();
|
||||
@@ -177,7 +177,7 @@
|
||||
success:function(result){
|
||||
if(result){
|
||||
swal({
|
||||
title: "Infomation!",
|
||||
title: "Information!",
|
||||
text: "Payment Successfully",
|
||||
}, function () {
|
||||
window.location.href = '/origami/sale/'+ sale_id + "/payment";
|
||||
@@ -186,7 +186,11 @@
|
||||
}
|
||||
});
|
||||
}else{
|
||||
swal ( "Oops" , "Paid Amount is over!" , "error" );
|
||||
if (amount>0) {
|
||||
swal ( "Oops" , "Paid Amount is over!" , "error" );
|
||||
}else{
|
||||
swal ( "Oops" , "Enter Amount!" , "error" );
|
||||
}
|
||||
}
|
||||
})
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user