/**  
 * @author Van  
 * @constructor Van
 * @description SLA详细信息主函数.
 * @date 2011-02-25
 * @since version 1.0 
 */
$package('itsm.sla');
$import('itsm.sla.slaDetail_ruleGrid');
$import('itsm.sla.slaDetail_updateGrid');


itsm.sla.slaDetail=function(){
	
	
	this.slaDetailGrids=[];
	
	return{
		
		
		//列表伸展
		slaDetailPanelExpand:function(){
			
			 $(slaDetailGrids).each(function(i, g) {
			      setGridWidth(g, 'regCenter', 338);
			 });
		},
		
		//列表收缩
		slaDetailPanelCollapse:function(){
			
			 $(slaDetailGrids).each(function(i, g) {
			      setGridWidth(g, 'regCenter', 46);
			 });
		},
		
		//获取事件
		fitSLADetailsGrids:function(){
			
			$('#slaDetailWest').panel({
				onCollapse:itsm.sla.slaDetail.slaDetailPanelCollapse,
				onExpand:itsm.sla.slaDetail.slaDetailPanelExpand
			});
		},
		
		init:function(){
			
			$("#SLAServiceManage_loading").hide();
			$("#SLAServiceManage_content").show();
			
			//实例化SLA规则列表
			itsm.sla.slaDetail_ruleGrid.init();
			
			//实例化自动升级列表
			itsm.sla.slaDetail_updateGrid.init();
			
			setTimeout(itsm.sla.slaDetail.fitSLADetailsGrids,0);
		}
		
	};
	
	
	
 }();
 $(document).ready(itsm.sla.slaDetail.init);
