Subversion Repositories SmartDukaan

Rev

Rev 18820 | Rev 18851 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 18820 Rev 18828
Line 461... Line 461...
461
    if($('span#CreditError').html()!=''){
461
    if($('span#CreditError').html()!=''){
462
    	localStorage.setItem('CreditError',$('span#CreditError').html());
462
    	localStorage.setItem('CreditError',$('span#CreditError').html());
463
    }	
463
    }	
464
    if(creditAvailable=='false'){
464
    if(creditAvailable=='false'){
465
    	$('button.confirmcredit').prop( "disabled", true );
465
    	$('button.confirmcredit').prop( "disabled", true );
466
    	$('button.confirmcredit').attr('style', 'background-color: #B4CAB4;');
466
    	$('button.confirmcredit').attr('style', 'margin: 10px 20px 0px 0px; background-color: #B4CAB4; color: #fff;');
467
    	$('span#CreditError').html('');
467
    	$('span#CreditError').html('');
468
    }else{
468
    }else{
469
    	var errorSpanText = localStorage.getItem('CreditError');
469
    	var errorSpanText = localStorage.getItem('CreditError');
470
    	if(cart_details == undefined || creditTicketSize>totalPayable || totalPayable>=creditLimit){
470
    	if(cart_details == undefined || creditTicketSize>totalPayable || totalPayable>=creditLimit){
471
    		$('button.confirmcredit').prop( "disabled", true );
471
    		$('button.confirmcredit').prop( "disabled", true );
472
        	$('button.confirmcredit').attr('style', 'background-color: #B4CAB4;');
472
        	$('button.confirmcredit').attr('style', 'margin: 10px 20px 0px 0px; background-color: #B4CAB4; color: #fff;');
473
        	$('span#CreditError').html(errorSpanText);
473
        	$('span#CreditError').html(errorSpanText);
474
    	}else{
474
    	}else{
475
    		$('button.confirmcredit').prop( "disabled", false );
475
    		$('button.confirmcredit').prop( "disabled", false );
476
        	$('button.confirmcredit').attr('style', 'background-color: #5cb85c;color: #fff');
476
        	$('button.confirmcredit').attr('style', 'margin: 10px 20px 0px 0px;background-color: #5cb85c;color: #fff;');
477
    	}
477
    	}
478
    }
478
    }
479
}); 
479
}); 
480
 
480
 
481
$(document).on('click','#showmore',function(){
481
$(document).on('click','#showmore',function(){