update cloud and master

This commit is contained in:
Aung Myo
2018-01-15 15:08:52 +06:30
parent 4a5c5aff03
commit 9ab9f3b002
4 changed files with 78 additions and 28 deletions

View File

@@ -305,24 +305,28 @@
<script>
$(document).ready(function(){
/* start check first bill or not*/
var receipt_no = "";
var member_id = $('#membership_id').text();
var member_discount = $('#member_discount').text();
var receipt_no = "";
if(($("#receipt_no").html()!=undefined) && ($("#receipt_no").html()!="")){
receipt_no = ($("#receipt_no").html()).trim();
}
payment_type = checkReceiptNoInFirstBillData(receipt_no,"payment")
console.log(payment_type)
if ($("#server_mode").val() != "cloud") { // first bill not used in cloud
payment_type = checkReceiptNoInFirstBillData(receipt_no,"payment")
if (member_id && member_discount) {
if(parseInt(jQuery.inArray("Credit", payment_type)) == -1){
$("#credit_payment").hide();
} else{
$("#credit_payment").show();
}
if(parseInt(jQuery.inArray("Credit", payment_type)) == -1){
$("#credit_payment").hide();
} else{
$("#credit_payment").show();
}
if(parseInt(jQuery.inArray("MPU", payment_type)) > 0 || parseInt(jQuery.inArray("VISA", payment_type)) > 0 || parseInt(jQuery.inArray("JCB", payment_type)) > 0 || parseInt(jQuery.inArray("Master", payment_type)) > 0 || parseInt(jQuery.inArray("UNIONPAY", payment_type)) > 0 || parseInt(jQuery.inArray("Redeem", payment_type)) > 0){
$("#card_payment").show();
} else{
$("#card_payment").hide();
if(parseInt(jQuery.inArray("MPU", payment_type)) > 0 || parseInt(jQuery.inArray("VISA", payment_type)) > 0 || parseInt(jQuery.inArray("JCB", payment_type)) > 0 || parseInt(jQuery.inArray("Master", payment_type)) > 0 || parseInt(jQuery.inArray("UNIONPAY", payment_type)) > 0 || parseInt(jQuery.inArray("Redeem", payment_type)) > 0){
$("#card_payment").show();
} else{
$("#card_payment").hide();
}
}
}
/* end check first bill or not*/