/// <summary>构造函数 /// /// </summary> public FrmCacheTablesSimpleQuery() { InitializeComponent(); grdData.ShowCellToolTips = false; grdData.AutoGenerateColumns = false; m_CacheTablesDAL = GlobalHelp.GetResolve <IBseDAL <CacheTables> >(); grdData.RowsAdded += this.grdData_RowsAdded; grdData.RowPostPaint += grdData_RowPostPaint; grdData.CellMouseEnter += this.grdData_CellMouseEnter; grdData.CellMouseLeave += this.grdData_CellMouseLeave; grdData.CellDoubleClick += this.grdData_CellDoubleClick; toolTip.Draw += this.toolTip_Draw; DoInitData(); }
/// <summary>构造函数 /// /// </summary> /// <param name=model" CacheSetting">对象</param> /// <param name="lstCacheSetting">对象集合</param> public FrmCacheSettingSimpleDialog(CacheSetting modelCacheSetting, List <CacheSetting> lstCacheSetting) { InitializeComponent(); DoInitData(); m_lstCacheSetting = lstCacheSetting ?? new List <CacheSetting>(); m_CacheSettingDAL = GlobalHelp.GetResolve <IBseDAL <CacheSetting> >(); this.dataNavigator.Visible = false; if (modelCacheSetting != null) { this.dataNavigator.Visible = true; m_CacheSetting = modelCacheSetting; this.dataNavigator.ListInfo = lstCacheSetting.Select(t => t.Id.ToString()).ToList(); m_strIndex = lstCacheSetting.FindIndex(t => t.Id == m_CacheSetting.Id).ToString(); this.dataNavigator.CurrentIndex = int.Parse(m_strIndex); } }
/// <summary>构造函数 /// /// </summary> /// <param name=model" CacheTables">对象</param> /// <param name="lstCacheTables">对象集合</param> public FrmCacheTablesSimpleDialog(CacheTables modelCacheTables, List <CacheTables> lstCacheTables) { InitializeComponent(); DoInitData(); m_lstCacheTables = lstCacheTables ?? new List <CacheTables>(); m_CacheTablesDAL = GlobalHelp.GetResolve <IBseDAL <CacheTables> >(); this.dataNavigator.Visible = false; if (modelCacheTables != null) { this.dataNavigator.Visible = true; m_CacheTables = modelCacheTables; this.dataNavigator.ListInfo = lstCacheTables.Select(t => t.Id.ToString()).ToList(); m_strIndex = lstCacheTables.FindIndex(t => t.Id == m_CacheTables.Id).ToString(); this.dataNavigator.CurrentIndex = int.Parse(m_strIndex); } }
/// <summary>获取缓存表配置 /// /// </summary> /// <returns></returns> internal static List <CacheConfig> GetCacheStoreConfig() { IBseDAL <CacheConfig> cacheDal = GlobalHelp.GetResolve <IBseDAL <CacheConfig> >(); return(cacheDal.GetListArray("")); }