Ext.define('make.view.money.billOutAP.BenchQueryModel', { extend: 'saas.view.core.bench.QueryModel', alias: 'viewmodel.money-billoutap-benchquery', constructor:function(config){ this.bindings = {}; var billsource= Ext.getCmp('mainView').getViewModel().get('BillOutAPSource'); var showProdBill= true,showCheckBill=true ; if('PRODIO'==billsource){ showProdBill= false ; }else if('CHECK'==billsource){ showCheckBill= false ; } config.stores={ menus: { model: 'saas.model.core.benchMenu', data: [ {desc: '货款待收票',isCount: 1,hidden:showProdBill},//出入库 {desc: '外协待收票',isCount: 1,hidden:showProdBill},//出入库 {desc: '货款待收票',isCount: 1,hidden:showCheckBill},//对账单 {desc: '外协待收票',isCount: 1,hidden:showCheckBill},//对账单 {desc: '待确认',isCount: 1}, {desc: '已收票',isCount: 0} ] } } ; this.initConfig(config); } });