示例#1
0
        private void BrowseReport()
        {
            int _selectReportIndex = this.gridView1.FocusedRowHandle;

            if (_selectReportIndex >= 0)
            {
                MD_ReportItem _ritem = this.gridView1.GetRow(_selectReportIndex) as MD_ReportItem;

                switch (this.reportType)
                {
                case "RS报表":
                    frmShowHTMLReport _htmlForm = new frmShowHTMLReport(_ritem, reportType);
                    _application.AddForm(Guid.NewGuid().ToString(), _htmlForm);
                    break;

                case "自定义报表":
                default:
                    ShowExcelReport excelReport = new ShowExcelReport(_ritem, reportType);
                    _application.AddForm(Guid.NewGuid().ToString(), excelReport);
                    break;
                }
            }
            else
            {
                XtraMessageBox.Show("请选择要浏览的报表", "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
            }
        }
 /// <summary>
 /// 以图表方式展示
 /// </summary>
 private void ShowAsChart()
 {
     if (_currentGrid is SinoSZUC_GridControlEx)
     {
         SinoSZUC_GridControlEx _gridEx = _currentGrid as SinoSZUC_GridControlEx;
         DataTable _dt = _gridEx.CurrentData();
         Dictionary <string, string> _fieldsDict = _gridEx.CurrentFieldsDict();
         frmChartShow _f = new frmChartShow(_dt, _fieldsDict);
         _application.AddForm(Guid.NewGuid().ToString(), _f);
     }
 }
示例#3
0
        private void treeList1_MouseDoubleClick(object sender, MouseEventArgs e)
        {
            TreeListNode _node = this.treeList1.FocusedNode;

            if (_node != null)
            {
                if (_node.Tag != null)
                {
                    MDModel_Table         _table = _node.Tag as MDModel_Table;
                    frmSinoSZ_ChildDetail _form  = new frmSinoSZ_ChildDetail(this.QueryModel, _table, this.MainKeyID);
                    _application.AddForm(_table.TableName + this.MainKeyID, _form);
                }
            }
        }
示例#4
0
        static public bool DoCommand(string _menuID, string _commandName, string _commandTitle, string _param, IApplication _application)
        {
            switch (_commandName)
            {
            case "CreateReport":                      //报表生成
                frmCreateReport _form = new frmCreateReport(_commandTitle, _param);
                _application.AddForm(Guid.NewGuid().ToString(), _form);
                break;

            case "BrowseReport":                     //报表浏览
                frmBrowseReport _bf = new frmBrowseReport(_commandTitle, _param);
                _application.AddForm(Guid.NewGuid().ToString(), _bf);
                break;

            case "ReportGuideLineQuery":
                string _title = StrUtils.GetMetaByName2("标题", _param);
                frmReportGuideLineQuery _frm = MenuFunctions.AddPage <frmReportGuideLineQuery>(_title, _application);
                if (_frm != null)
                {
                    _frm.Init(_title, "报表指标查询", _param);
                }

                break;

            case "DataCheck":                      //数据审核
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmCheckSearch _frm_DataCheck = MenuFunctions.AddPage <frmCheckSearch>(_title, _application);
                if (_frm_DataCheck != null)
                {
                    _frm_DataCheck.Init(_title, "数据审核", _param);
                }
                break;

            case "DataCheckBoard":                    //审核公告
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmDataCheckBoard _frmBoard = MenuFunctions.AddPage <frmDataCheckBoard>(_title, _application);
                if (_frmBoard != null)
                {
                    _frmBoard.Init(_title, "审核公告", _param);
                }
                break;
            }
            return(true);
        }
示例#5
0
        static public bool DoCommand(string _menuID, string _commandName, string _commandTitle, string _param, IApplication _application)
        {
            string _title;

            switch (_commandName)
            {
            case "RoleManager":                      //角色管理
                frmRoleDefine _rdf = new frmRoleDefine(_param);
                _application.AddForm("角色管理", _rdf);
                break;

            case "PostManager":                     //岗位管理
                frmPostDefine _pdf = new frmPostDefine();
                _application.AddForm("岗位管理", _pdf);
                break;

            case "UserManager":                     //用户管理
                string        _canAdd = StrUtils.GetMetaByName2("可添加", _param);
                frmUserDefine _f      = new frmUserDefine(_commandTitle, _canAdd);
                _application.AddForm("用户管理", _f);
                break;

            case "UserMobileManager":                     //用户手机管理
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmUserMobile _frmUserMobile = MenuFunctions.AddPage <frmUserMobile>(_title, _application);
                if (_frmUserMobile != null)
                {
                    _frmUserMobile.Init(_title, "企业涉案", _param);
                }
                break;

            case "UserMappingCUPAA":     //三统一用户映射
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmUserMapping_CUPAA _f_UM_CUPAA = MenuFunctions.AddPage <frmUserMapping_CUPAA>(_title, _application);
                if (_f_UM_CUPAA != null)
                {
                    _f_UM_CUPAA.Init(_title, "三统一用户映射", _param);
                }
                break;
            }
            return(true);
        }
示例#6
0
 public static void AddPage(string _frmName, IApplication _application, Form _frm)
 {
     if (_application.IsExistForm(_frmName))
     {
         _application.SetFormActive(_frmName);
     }
     else
     {
         _application.AddForm(_frmName, _frm);
     }
 }
        public static void ShowDetail(ShowDetailDataArgs _showArgs, IApplication _application)
        {
            if (_showArgs.Type == "GuideLine")
            {
                frmGuideLineQueryWithoutInput _f = new frmGuideLineQueryWithoutInput(_showArgs.GuideLine, _showArgs.QueryParams);
                _application.AddForm(Guid.NewGuid().ToString(), _f);
            }

            if (_showArgs.Type == "QueryModel")
            {
                using (MetaDataQueryServiceClient _msc = new MetaDataQueryServiceClient())
                {
                    string _mainKey = _msc.GetMainTableKeyByColumnCondition(_showArgs.QueryModelName,
                                                                            _showArgs.QueryColumnName,
                                                                            _showArgs.QueryDataValue);
                    MDModel_QueryModel   _model = MetaDataCache.GetQueryModelDefine(_showArgs.QueryModelName);
                    frmSinoSZ_DataDetail _f     = new frmSinoSZ_DataDetail(_model, _mainKey);
                    _application.AddForm(Guid.NewGuid().ToString(), _f);
                }
            }
        }
示例#8
0
 /// <summary>
 /// 显示查询结果
 /// </summary>
 private bool ShowResult()
 {
     if (this.CurrentTask != null)
     {
         frmSinoSZ_QueryResult _qr = new frmSinoSZ_QueryResult(this.CurrentTask);
         _application.AddForm(Guid.NewGuid().ToString(), _qr);
         return(true);
     }
     else
     {
         return(false);
     }
 }
示例#9
0
 /// <summary>
 /// 采用泛型的加页
 /// </summary>
 /// <typeparam name="T"></typeparam>
 /// <param name="_frmName"></param>
 public static T AddPage <T>(string _frmName, IApplication _application) where T : new()
 {
     if (_application.IsExistForm(_frmName))
     {
         _application.SetFormActive(_frmName);
         return(default(T));
     }
     else
     {
         T _frm = new T();
         _application.AddForm(_frmName, _frm as Form);
         return(_frm);
     }
 }
示例#10
0
        /// <summary>
        /// 查询数据
        /// </summary>
        virtual protected void QueryData(IApplication _application)
        {
            if (_application == null)
            {
                return;
            }

            string _errorMsg = "";

            if (!this.sinoSZUC_MD_Model_FieldList1.CheckItems(ref _errorMsg))
            {
                XtraMessageBox.Show(string.Format("选择查询结果不正确:{0}", _errorMsg), "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;
            }
            if (!this.sinoSZUC_ConditionPanel1.CheckInput(ref _errorMsg))
            {
                XtraMessageBox.Show(string.Format("查询条件不正确:{0}", _errorMsg), "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;
            }
            MC_QueryRequsetFactory _rf = new MC_QueryRequsetFactory();

            _rf.QueryModelName = this.QueryModelName;
            this.sinoSZUC_ConditionPanel1.InsertConditions2QueryRequest(_rf);
            this.sinoSZUC_MD_Model_FieldList1.InsertResultFields2QueryRequest(_rf);
            MDQuery_Request _queryRequest = _rf.GetQueryRequest();

            if (_queryRequest.MainResultTable.Columns == null || _queryRequest.MainResultTable.Columns.Count < 1)
            {
                XtraMessageBox.Show("主表必须至少选择一个结果字段!", "系统提示", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return;
            }
            frmSinoSZ_QueryResult _qr = new frmSinoSZ_QueryResult(_queryModel, _queryRequest);

            AddExtMenu(_qr);
            _application.AddForm(Guid.NewGuid().ToString(), _qr);
            //XtraMessageBox.Show(string.Format("查询请求包占用存{0}Byte", CalcMemory.CalcInstanceMemory(_rf.GetQueryRequest())));
        }
示例#11
0
        static public bool DoCommand(string _menuID, string _commandName, string _commandTitle, string _param, IApplication _application)
        {
            string _title;

            switch (_commandName)
            {
            case "IISRecycle":
                frmResetIISApp _frmIIS = MenuFunctions.AddPage <frmResetIISApp>("内存回收", _application);
                if (_frmIIS != null)
                {
                    _frmIIS.Init("内存回收", "内存回收", _param);
                }
                break;

            case "WinServiceWatch":
                frmResetWindowsService _frmWinService = MenuFunctions.AddPage <frmResetWindowsService>("服务查看", _application);
                if (_frmWinService != null)
                {
                    _frmWinService.Init("服务查看", "服务查看", _param);
                }
                break;

            case "OrganizeExtInfo":
                frmOrganizeExtInfo _frmOrgExt = MenuFunctions.AddPage <frmOrganizeExtInfo>("组织机构信息维护", _application);
                if (_frmOrgExt != null)
                {
                    _frmOrgExt.Init("组织机构信息维护", "机构信息维护", _param);
                }
                break;

            case "UserLog":
                frmUserLog _rdf = new frmUserLog();
                _application.AddForm("用户操作日志", _rdf);
                break;

            case "QueryLog":
                frmQueryLog _fql = new frmQueryLog();
                _application.AddForm("数据查询日志", _fql);
                break;

            case "SystemLog":
                frmSystemLog _syslog = new frmSystemLog();
                _application.AddForm("系统处理日志", _syslog);
                break;

            case "Notify":
                frmNotifyInfo _frm = MenuFunctions.AddPage <frmNotifyInfo>("通知通告", _application);
                if (_frm != null)
                {
                    _frm.Init("通知通告", "通知通告", "");
                }
                break;

            case "InterfaceManager_SJJH":
                frmIM_SJJH _frmIM_SJJH = MenuFunctions.AddPage <frmIM_SJJH>("数据交换接口管理", _application);
                if (_frmIM_SJJH != null)
                {
                    _frmIM_SJJH.Init("数据交换接口管理", "数据交换接口管理", "");
                }
                break;

            case "FSDataLoadAlertMailSet":      //数据加载监控提示邮件设置
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmFsAlertMainSet _frmFsAlert = MenuFunctions.AddPage <frmFsAlertMainSet>(_title, _application);
                if (_frmFsAlert != null)
                {
                    _frmFsAlert.Init(_title, "邮件设置", _param);
                }
                break;

            case "TaskManager":     //后台任务管理器
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmTaskManager _frmTaskManager = MenuFunctions.AddPage <frmTaskManager>(_title, _application);
                if (_frmTaskManager != null)
                {
                    _frmTaskManager.Init(_title, "任务管理", _param);
                }
                break;

            case "WorkCalendar":    //工作日历
                _title = "工作日历";
                WorkCalenderForm _frmWorkCalenderForm = MenuFunctions.AddPage <WorkCalenderForm>(_title, _application);
                if (_frmWorkCalenderForm != null)
                {
                    _frmWorkCalenderForm.Init(_title, "工作日历", _param);
                }
                break;

            case "GDSManager":
                _title = "通用接口管理";
                frmGDSManager _frmGDSManager = MenuFunctions.AddPage <frmGDSManager>(_title, _application);
                if (_frmGDSManager != null)
                {
                    _frmGDSManager.Init(_title, _title, _param);
                }
                break;
            }
            return(true);
        }
示例#12
0
        public void ShowAsChart(IApplication _application)
        {
            frmChartShow _f = new frmChartShow(_ResultTable, FieldsDict);

            _application.AddForm(Guid.NewGuid().ToString(), _f);
        }
示例#13
0
        static public bool DoCommand(string _menuID, string _commandName, string _commandTitle, string _param, IApplication _application)
        {
            string _modelName;
            string _guidLines;
            string _glqTitle;
            string _title;

            switch (_commandName)
            {
            case "RelationQuery":
                _modelName = StrUtils.GetMetaByName("查询模型", _param);
                frmSinoSZ_RelationQuery _f = new frmSinoSZ_RelationQuery(_modelName, _param);
                _f.Tag = _menuID;
                _application.AddForm(Guid.NewGuid().ToString(), _f);
                break;

            case "FixQuery":
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmFixQuery _frmFixQuery = MenuFunctions.AddPage <frmFixQuery>(_title, _application);
                if (_frmFixQuery != null)
                {
                    _frmFixQuery.Init(_title, _title, _param);
                }
                break;

            case "SingleGuideLineQuery":
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmGuideLineQuery_Single _frmSingleGuideLine = MenuFunctions.AddPage <frmGuideLineQuery_Single>(_title, _application);
                if (_frmSingleGuideLine != null)
                {
                    _frmSingleGuideLine.Init(_title, _title, _param);
                }
                break;

            case "DataCompare":

                frmDataCompare _f2 = new frmDataCompare(_param);
                _application.AddForm(Guid.NewGuid().ToString(), _f2);
                break;

            case "DataSearch":
                _modelName = StrUtils.GetMetaByName("查询模型", _param);
                frmDataSearch _f3 = new frmDataSearch(_modelName);
                _application.AddForm(Guid.NewGuid().ToString(), _f3);
                break;

            case "GuideLineQuery":
                _guidLines = StrUtils.GetMetaByName("指标ID", _param);
                _glqTitle  = StrUtils.GetMetaByName("标题", _param);
                frmGuideLineQuery _f4 = new frmGuideLineQuery((_glqTitle == "") ? _commandTitle : _glqTitle, _guidLines);
                _application.AddForm(Guid.NewGuid().ToString(), _f4);
                break;

            case "GuideLineQueryEx":
                _guidLines = StrUtils.GetMetaByName("指标ID", _param);
                _glqTitle  = StrUtils.GetMetaByName("标题", _param);
                frmGuideLineQueryEx _f4ex = new frmGuideLineQueryEx((_glqTitle == "") ? _commandTitle : _glqTitle, _guidLines);
                _application.AddForm(Guid.NewGuid().ToString(), _f4ex);
                break;

            case "GuideLineShow":
                string _guidLineID = StrUtils.GetMetaByName2("指标ID", _param);
                string _params     = StrUtils.GetMetaByName2("参数", _param);
                bool   _canGroup   = (StrUtils.GetMetaByName2("可分组", _param).ToUpper() == "TRUE");
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmGuideLineQueryWithoutInput _f5 = new frmGuideLineQueryWithoutInput(_title, _guidLineID, _params, _canGroup);
                _application.AddForm(_title, _f5);
                break;

            case "GuideLineGroupShow":
                frmGuideLineGroupShow _f6 = new frmGuideLineGroupShow(_param);
                _application.AddForm(_commandTitle, _f6);
                break;

            case "GuideLineGroupShow2":
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmGuideLineGroupShow2 _f7 = new frmGuideLineGroupShow2(_param);
                _application.AddForm(_title, _f7);
                break;

            case "PortalShow":
                frmPortal _fPortal = new frmPortal(_param, _application);
                _application.AddForm(_commandTitle, _fPortal);
                break;

            case "RelationQueryTask":
                _modelName = StrUtils.GetMetaByName("查询模型", _param);
                frmSinoSZ_RelationQuery_Task _f8 = new frmSinoSZ_RelationQuery_Task(_modelName, _param);
                _application.AddForm(Guid.NewGuid().ToString(), _f8);
                break;

            case "QueryTaskList":
                frmSinoSZ_TaskList _f9 = new frmSinoSZ_TaskList();
                _application.AddForm(_commandTitle, _f9);
                break;

            case "TreeComboPortalShow":
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmTreeComboPortal _frm = MenuFunctions.AddPage <frmTreeComboPortal>(_title, _application);
                if (_frm != null)
                {
                    _frm.Init(_title, _title, _param);
                }
                break;

            case "AlertMonitor":
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmAlertMonitor _frmAert = MenuFunctions.AddPage <frmAlertMonitor>(_title, _application);
                if (_frmAert != null)
                {
                    _frmAert.Init(_title, _title, _param);
                }
                break;

            case "ParameterSetting":
                _title = StrUtils.GetMetaByName2("标题", _param);
                frmGuideLineSetting _frmSetting = MenuFunctions.AddPage <frmGuideLineSetting>(_title, _application);
                if (_frmSetting != null)
                {
                    _frmSetting.Init(_title, _title, _param);
                }
                break;
            }
            return(true);
        }