/**
 * 支付方式 
 */
$(function(){
    $(".f-r span").each(function(k){
        $(this).bind('click',function(){
            $(".f-r span").removeClass('on');
            $(this).addClass('on');
            payment_id =$(this).find("#pay").val();
			$("#paytype").val(payment_id);
        });
    });
});

/**
 * 充值
 */
function go_recharge(){
	var money = $("#money").val();
	if(money<=0 || isNaN(money)){$.showErr('请填写正确数量',0,'hc');return false;}
	var query = new Object;
	query = $("form[name='form_money']").serialize();
	$.ajax({
		type:"POST",
		url:APP+"Shop/Account/go_recharge",
		data:query,
		success:function(data){
			if(data.status==1){
				$.showSuccess(data.info,0,'hc');
				window.location.href=data.url;
			}else{
				$.showErr(data.info,0,'hc');
			}
		}
	});
}