jQuery(document).ready(function($){
	(function($){
		$.fn.getWalletBalance = function() {
			$.ajax({
				type: "post",
				url: "contents/plugins/payment_module/ajax.php",
				data: {"action": "get_wallet_balance"}
			}).done(function(data){
				try {
					data = JSON.parse(data);
					$(".available-wallet-balance").html("Your current wallet balance is "+data);
				}
				catch(err) {
					console.log(err);
				}
				finally{}
			}).fail(function(){

			})
		}
	})(jQuery);

	$(document).getWalletBalance();
})