/**
 *
 * @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,deductionStatus: formData.deductionStatus,note: formData.note},
            url: g.ctx + "pc/finance/invoiced/receipt/rest/updateDeductionStatus", //请求路径
            success: function (data) {
                layer.alert("修改成功", function () {
                    call();
                })
            },
            error: function (data) {
                layer.alert(data.responseJSON.message);
            }
        });
    }
}
$(function () {
    // 初始化抵扣状态下拉框
    $('#deductionStatus').combobox({
        valueField: 'value',
        textField: 'label',
        value: null,
        data: [
            {label: '待认证', value: '1'},
            {label: '已认证', value: '2'},
            {label: '红冲', value: '3'}
        ],
        editable: false,
        prompt: '-- 请选择 --',
        panelHeight: '150'
    });
})