VoucherEditWindow_Out_EditGridPanel = function(fundAllocation, project, store) {

    // 复选框
    this._selections = new Ext.grid.CheckboxSelectionModel({ handleMouseDown: Ext.emptyFn });
    this._selections.grid = this;
   
    this._columnModel = new  VoucherEditWindow_Out_EditGridPanel_ColumnModel(this._fundAllocation);
    this._tbar = new VoucherEditWindow_Out_EditGridPanel_ToolBar(this, this._store, this._selections);
    VoucherEditWindow_Out_EditGridPanel.superclass.constructor.call(this, {
        store: this._store,
        cm: this._columnModel,
        tbar: this._tbar,
        height: 170,
        deferredRender: true,
        sm: this._selections,
        clicksToEdit: 1,
        loadMask: true,
        disabled: projectCanAllocationOutAmount == 0,
        stateful: false,
        region: 'center',
        autoScroll: true,
        viewConfig: {
            autoFill: true,
            forceFit: true
        }
    });
   
    // 只有复选框选中,才能够被编辑
    this.beforeedit = function(e) {
    switch (e.column) {   // e.column可以判定激活了那一列的编辑器
    case 5:
    {
    if (!this.getSelectionModel().isIdSelected(e.row + 1)) {
    e.cancel = true; // 取消用户编辑操作
    }

                    break;
    }
    default:
    break;
    }
    }

    this.on('validateedit', this.validateedit);
}
Ext.extend(VoucherEditWindow_Out_EditGridPanel, Ext.grid.EditorGridPanel, {});