/**
 *
 * @author BOGON
 * @version 1.0
 */

var page = {
    submitFlag: 0,
    save: function (call) {
        if (!$('#form').form("validate")) {
            return;
        }
        var formData = $("#form").serializeJson();
        $.ajax({
            type: "POST", //请求方式
            data: {ids: ids,deductionRatio: formData.deductionRatio},
            url: g.ctx + "pc/finance/receipt/voucher/rest/updateRatio", //请求路径
            success: function (data) {
                layer.alert("修改成功", function () {
                    call();
                })
            },
            error: function (data) {
                layer.alert(data.responseJSON.message);
            }
        });
    },

    getData: function (call) {
        if (!$('#form').form("validate")) {
            return;
        }
        var formData = $("#form").serializeJson();
        call(formData.deductionRatio);
    }
}
$(function () {
})