예제 #1
0
        //****************************************

        /// <summary>
        ///     构造方法
        /// </summary>
        public TunnelHChuanManagement()
        {
            InitializeComponent();

            //分页委托
            dataPager1.FrmChild_EventHandler += FrmParent_EventHandler;

            //窗体属性设置
            FormDefaultPropertiesSetter.SetManagementFormDefaultProperties(this, Const_GM.TUNNEL_HCHUAN_MANAGEMENT);

            //Farpoint属性设置
            FarpointDefaultPropertiesSetter.SetFpDefaultProperties(fpDayReportHChuan,
                                                                   Const_GM.TUNNEL_HCHUAN_FARPOINT_TITLE, _rowDetailStartIndex);

            _filterColunmIdxs = new[]
            {
                1,
                2,
                3,
                4,
                5,
                6,
                7,
                8,
                9,
                11,
                12,
                13
            };
            //禁用选择颜色相关控件
            farpointFilter1.EnableChooseColorCtrls(false);
            //设置自动隐藏过滤条件
            FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(fpDayReportHChuan, _filterColunmIdxs);
        }
예제 #2
0
        /// <summary>
        ///     构造函数
        /// </summary>
        public PreWarningResultQuery()
        {
            InitializeComponent();
            summaryCells = _fpTunelInfo.ActiveSheet.Cells;
            infoCells    = _fpPreWarningDetials.ActiveSheet.Cells;

            //定义Farpoint列数
            _fpTunelInfo.ActiveSheet.ColumnCount = COLUMN_COUNT;
            //设置窗体格式和窗体名称
            FormDefaultPropertiesSetter.SetManagementFormDefaultProperties(this, Const_WM.PREWARNING_RESULT_QUERY);

            // 调用委托方法 (必须实装)
            dataPager1.FrmChild_EventHandler += FrmParent_EventHandler;

            #region Farpoint自动过滤功能

            //初始化需要过滤功能的列
            _filterColunmIdxs = new[]
            {
                0,
                1,
                2
            };
            //禁用选择颜色相关控件
            farpointFilter1.EnableChooseColorCtrls(false);
            //设置自动隐藏过滤条件
            FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(_fpTunelInfo, _filterColunmIdxs);

            #endregion
        }
예제 #3
0
        public UserInformationDetailsManagement()
        {
            InitializeComponent();
            //设置窗体、farpoint格式
            LibCommon.FormDefaultPropertiesSetter.SetMdiChildrenManagementFormDefaultProperties(this, LibCommon.LibFormTitles.USER_INFO_DETAILS_MANMAGEMENT);
            LibCommon.FarpointDefaultPropertiesSetter.SetFpDefaultProperties(fpUserInformationDetails, LibCommon.LibFarpintTiltes.USER_INFO_DETAILS, 2);
            //判断用户权限
            if (CurrentUser.CurLoginUserInfo.Permission != Permission.管理员.ToString())
            {
                tsBtnAdd.Visible    = false;
                tsBtnDel.Visible    = false;
                tsBtnModify.Visible = false;
            }

            #region Farpoint自动过滤功能
            //初始化需要过滤功能的列
            _filterColunmIdxs = new int[]
            {
                6,
            };
            //禁用选择颜色相关控件
            farpointFilter1.EnableChooseColorCtrls(false);
            //设置自动隐藏过滤条件
            FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(this.fpUserInformationDetails, _filterColunmIdxs);
            #endregion
        }
예제 #4
0
        public PreWarningRulesPanel()
        {
            InitializeComponent();
            toolStripFilter.Enabled = false;
            toolStripFilter.Visible = false;
            InitFilterCombo();

            FarpointDefaultPropertiesSetter.SetFpDefaultProperties(fpRules, "", 1);

            #region Farpoint自动过滤功能

            //初始化需要过滤功能的列
            _filterColunmIdxs = new[]
            {
                1,
                2,
                3,
                4,
                5,
                7,
                8
            };
            //禁用选择颜色相关控件
            farpointFilter1.EnableChooseColorCtrls(false);
            //设置自动隐藏过滤条件
            FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(fpRules, _filterColunmIdxs);

            #endregion
        }
예제 #5
0
        /// <summary>
        /// </summary>
        /// <param name="sOutTunnelId">Tunnel WirePointName</param>
        /// <param name="sOutWorkface">Work Face Name</param>
        /// <param name="sOutDate">Date</param>
        /// <param name="sOutShift">班次</param>
        /// <param name="sOutWarningResult">预警结果</param>
        /// <param name="sOutWarningType">预警类型</param>
        /// <param name="sOutWarningItem">预警项目:瓦斯/地质构造/煤层赋存/通风/管理</param>
        /// <param name="isHistory"></param>
        public PreWarningResultDetailsQuery(string sOutTunnelId,
                                            string sOutWorkface, string sOutDate, string sOutShift,
                                            string sOutWarningResult, string sOutWarningType,
                                            string sOutWarningItem, bool isHistory)
        {
            InitializeComponent();

            cells = _fpPreWarningResultDetials.ActiveSheet.Cells;

            this.isHistory = isHistory;

            #region Farpoint自动过滤功能

            //初始化需要过滤功能的列
            _filterColunmIdxs = new[]
            {
                3
            };
            //设置自动隐藏过滤条件
            FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(_fpPreWarningResultDetials, _filterColunmIdxs);

            #endregion

            //设置窗体的样式及显示名称
            FormDefaultPropertiesSetter.SetManagementFormDefaultProperties(this,
                                                                           Const_WM.PREWARNING_RESULT_DETAILS_QUERY);

            //定义Farpoint的行列数
            _fpPreWarningResultDetials.ActiveSheet.Rows.Count    = FROZEN_ROW_COUNT;
            _fpPreWarningResultDetials.ActiveSheet.Columns.Count = COULMN_COUNT;

            // 加载预警结果详细信息。
            //LoadWarningResultDetail(sOutTunnelId,
            //            sOutWorkface, sOutDate, sOutShift,
            //            sOutWarningResult, sOutWarningType, sOutWarningItem);
            LoadWarningResultDetail(sOutWorkface, sOutDate, sOutShift,
                                    sOutWarningResult, sOutWarningType, sOutWarningItem);


            _txtDateShift.Text   = sOutShift;    // 班次
            _txtDateTime.Text    = sOutDate;     // 日期时间
            _txtWorkingFace.Text = sOutWorkface; // 工作面

            _fpPreWarningResultDetials.Focus();
            _fpPreWarningResultDetials.SetCursor(CursorType.Normal, Cursors.Hand);

            // 隐藏下面的几列
            _fpPreWarningResultDetials.ActiveSheet.Columns[COLUMN_INDEX_HIDE_DATA_ID].Visible    = false;
            _fpPreWarningResultDetials.ActiveSheet.Columns[COLUMN_INDEX_HIDE_WARNING_ID].Visible = false;

            // 历史信息和实时信息都要显示在这一个页面中,因此需要设置某些空间的Enabled/Visible属性。
            btnDoIt.Visible       = !isHistory;
            _btnUploadImg.Visible = !isHistory;
            _btnDeleteImg.Visible = !isHistory;
            RefreshImgListFromDb();
        }
        /// <summary>
        /// 构造函数
        /// </summary>
        public UserLoginInformationManagement()
        {
            InitializeComponent();
            //设置窗体和farpoint格式
            LibCommon.FormDefaultPropertiesSetter.SetManagementFormDefaultProperties(this, LibCommon.LibFormTitles.USER_LOGIN_INFO_MANMAGEMENT);
            LibCommon.FarpointDefaultPropertiesSetter.SetFpDefaultProperties(fpUserLoginInformation, LibCommon.LibFarpintTiltes.USER_LOGIN_INFO, 2);

            #region Farpoint自动过滤功能
            //初始化需要过滤功能的列
            _filterColunmIdxs = new int[]
            {
                4,
            };
            //禁用选择颜色相关控件
            farpointFilter1.EnableChooseColorCtrls(false);
            //设置自动隐藏过滤条件
            FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(this.fpUserLoginInformation, _filterColunmIdxs);
            #endregion
        }
예제 #7
0
        private void farpointFilter1_OnCheckFilterChanged(object sender, EventArgs arg)
        {
            CheckBox chk = (CheckBox)sender;

            //当Checkbox选中时,筛选过程中则将不符合条件的数据隐藏
            if (chk.Checked == true)
            {
                //禁用选择颜色相关控件
                farpointFilter1.EnableChooseColorCtrls(false);
                //设置自动隐藏过滤条件
                FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(this.fpUserInformationDetails, _filterColunmIdxs);
            }
            else//未选中时,根据用户自定义的颜色进行分类显示
            {
                //启用选择颜色相关控件
                farpointFilter1.EnableChooseColorCtrls(true);
                //设置自定义过滤条件
                FarpointDefaultPropertiesSetter.SetFpCustomFilterProperties(this.fpUserInformationDetails, farpointFilter1.GetSelectedFitColor(), farpointFilter1.GetSelectedNotFitColor(), _filterColunmIdxs);
            }
        }
예제 #8
0
        /// <summary>
        ///     farpointFilter1的OnCheckFilterChanged方法
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="arg"></param>
        private void farpointFilter1_OnCheckFilterChanged(object sender, EventArgs arg)
        {
            var chk = (CheckBox)sender;

            //当Checkbox选中时,筛选过程中则将不符合条件的数据隐藏
            if (chk.Checked)
            {
                //禁用选择颜色相关控件
                farpointFilter1.EnableChooseColorCtrls(false);
                //设置自动隐藏过滤条件
                FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(fpGasConcentrationProbeDataInfo,
                                                                          _filterColunmIdxs);
            }
            //未选中时,根据用户自定义的颜色进行分类显示
            else
            {
                //启用选择颜色相关控件
                farpointFilter1.EnableChooseColorCtrls(true);
                //设置自定义过滤条件
                FarpointDefaultPropertiesSetter.SetFpCustomFilterProperties(fpGasConcentrationProbeDataInfo,
                                                                            farpointFilter1.GetSelectedFitColor(), farpointFilter1.GetSelectedNotFitColor(), _filterColunmIdxs);
            }
        }
예제 #9
0
        /** 处理标志位 **/

        public GasConcentrationProbeDataManamement()
        {
            InitializeComponent();

            //分配用户权限
            if (CurrentUser.CurLoginUserInfo.Permission != Permission.管理员.ToString())
            {
                btnAdd.Visible    = false;
                btnUpdate.Visible = false;
                btnDelete.Visible = false;
                selectTunnelUserControl1.SetButtonEnable(false);
            }

            // 设置窗体默认属性
            FormDefaultPropertiesSetter.SetManagementFormDefaultProperties(this,
                                                                           Const_GE.MANAGE_GAS_CONCENTRATION_PROBE_DATA);

            // 设置Farpoint默认属性
            FarpointDefaultPropertiesSetter.SetFpDefaultProperties(fpGasConcentrationProbeDataInfo,
                                                                   Const_GE.MANAGE_GAS_CONCENTRATION_PROBE_DATA, _iRowDetailStartIndex);

            // 设置日期控件格式
            _dateTimeStart.Format       = DateTimePickerFormat.Custom;
            _dateTimeStart.CustomFormat = Const.DATE_FORMART_YYYY_MM_DD;
            _dateTimeEnd.Format         = DateTimePickerFormat.Custom;
            _dateTimeEnd.CustomFormat   = Const.DATE_FORMART_YYYY_MM_DD;

            // 设置日期默认值(当天的0点到24点)
            var todayStart = DateTime.Now.ToString("yyyy/MM/dd") + " " + "00:00:00";
            var todayEnd   = DateTime.Now.ToString("yyyy/MM/dd") + " " + "23:59:59";

            _dateTimeStart.Value = Convert.ToDateTime(todayStart);
            _dateTimeEnd.Value   = Convert.ToDateTime(todayEnd);

            // 调用选择巷道控件时需要调用的方法
            selectTunnelUserControl1.LoadData();

            // 注册委托事件
            //selectTunnelUserControl1.TunnelNameChanged +=
            //    InheritTunnelNameChanged;

            // 调用委托方法 (必须实装)
            dataPager1.FrmChild_EventHandler += FrmParent_EventHandler;

            // 设置farpoint默认行数
            fpGasConcentrationProbeDataInfo.Sheets[0].Rows.Count = _iRowDetailStartIndex;

            #region Farpoint自动过滤功能

            //初始化需要过滤功能的列
            _filterColunmIdxs = new[]
            {
                2,
                5,
                6,
                7,
                12,
                13,
                14,
                15,
                16
            };
            //禁用选择颜色相关控件
            farpointFilter1.EnableChooseColorCtrls(false);
            //设置自动隐藏过滤条件
            FarpointDefaultPropertiesSetter.SetFpFilterHideProperties(fpGasConcentrationProbeDataInfo, _filterColunmIdxs);

            #endregion
        }