Esempio n. 1
0
 private void InitializeComponent()
 {
     systemModule                 = new SystemModule();
     systemAspNetModule           = new SystemAspNetModule();
     webModule                    = new WebModule();
     sqlConnection1               = new SqlConnection();
     cloneObjectModule1           = new CloneObjectModule();
     reportsModule1               = new ReportsModule();
     validationModule1            = new ValidationModule();
     conditionalAppearanceModule1 = new ConditionalAppearanceModule();
     stateMachineModule1          = new StateMachineModule();
     coreModule1                  = new CoreModule();
     securityStrategyComplex1     = new SecurityStrategyComplex();
     securityModule1              = new SecurityModule();
     CoreAuthenticationApp1       = new CoreAuthentication();
     ((ISupportInitialize)this).BeginInit();
     //
     // sqlConnection1
     //
     sqlConnection1.FireInfoMessageEventOnUserErrors = false;
     //
     // reportsModule1
     //
     reportsModule1.EnableInplaceReports = true;
     reportsModule1.ReportDataType       = typeof(ReportData);
     //
     // stateMachineModule1
     //
     stateMachineModule1.StateMachineStorageType = typeof(XpoStateMachine);
     //
     // securityStrategyComplex1
     //
     securityStrategyComplex1.Authentication = CoreAuthenticationApp1;
     securityStrategyComplex1.RoleType       = typeof(Rol);
     securityStrategyComplex1.UserType       = typeof(Usuario);
     //
     // CoreAspNetApplication
     //
     ApplicationName = "CORE";
     LinkNewObjectToParentImmediately = false;
     CheckCompatibilityType           = CheckCompatibilityType.DatabaseSchema;
     Connection = sqlConnection1;
     Modules.Add(systemModule);
     Modules.Add(systemAspNetModule);
     Modules.Add(coreModule1);
     Modules.Add(cloneObjectModule1);
     Modules.Add(reportsModule1);
     Modules.Add(validationModule1);
     Modules.Add(conditionalAppearanceModule1);
     Modules.Add(stateMachineModule1);
     Modules.Add(webModule);
     Modules.Add(securityModule1);
     // TODO: migrate
     // CollectionsEditMode = ViewEditMode.Edit;
     Security = securityStrategyComplex1;
     DatabaseVersionMismatch += CoreAspNetApplication_DatabaseVersionMismatch;
     ((ISupportInitialize)this).EndInit();
 }
Esempio n. 2
0
        void LoadReport(DashboardReportViewItem dashboardReportViewItem)
        {
            var model          = dashboardReportViewItem.Model;
            var reportDataType = ReportsModule.FindReportsModule(dashboardReportViewItem.Application.Modules).ReportDataType;
            var reportData     = (IReportData)dashboardReportViewItem.View.ObjectSpace.FindObject(reportDataType, CriteriaOperator.Parse("ReportName=?", model.ReportName));

            if (reportData == null)
            {
                throw new NullReferenceException($"Report {model.ReportName} not found");
            }
            dashboardReportViewItem.Report     = reportData.LoadReport(dashboardReportViewItem.View.ObjectSpace);
            dashboardReportViewItem.ReportData = reportData;
        }
        protected override object CreateControlCore()
        {
            PrintControl = new PrintControl {
                Dock = DockStyle.Fill
            };
            PrintControl.ParentChanged += OnControlParentChanged;
            Type reportDataType = ReportsModule.FindReportsModule(_application.Modules).ReportDataType;
            var  reportData     = (IReportData)View.ObjectSpace.FindObject(reportDataType, CriteriaOperator.Parse("ReportName=?", Model.ReportName));

            if (reportData == null)
            {
                throw new NullReferenceException(string.Format("Report {0} not found", Model.ReportName));
            }
            _report = (XafReport)reportData.LoadReport(View.ObjectSpace);
            View.ControlsCreated       += ViewOnControlsCreated;
            PrintControl.PrintingSystem = Report.PrintingSystem;
            return(PrintControl);
        }
 public override void Setup()
 {
     base.Setup();
     Module = new ReportsModule(ReportStorage, GlobalStatisticStorage);
     PutInitialiData().Wait();
 }
Esempio n. 5
0
        /// <summary>
        ///     Required method for Designer support - do not modify
        ///     the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.module1                      = new DevExpress.ExpressApp.SystemModule.SystemModule();
            this.module2                      = new DevExpress.ExpressApp.Win.SystemModule.SystemWindowsFormsModule();
            this.module4                      = new FDIT.Core.Module.Win.WinModule();
            this.sqlConnection1               = new System.Data.SqlClient.SqlConnection();
            this.cloneObjectModule1           = new DevExpress.ExpressApp.CloneObject.CloneObjectModule();
            this.reportsModule1               = new DevExpress.ExpressApp.Reports.ReportsModule();
            this.validationModule1            = new DevExpress.ExpressApp.Validation.ValidationModule();
            this.conditionalAppearanceModule1 =
                new DevExpress.ExpressApp.ConditionalAppearance.ConditionalAppearanceModule();
            this.stateMachineModule1      = new DevExpress.ExpressApp.StateMachine.StateMachineModule();
            this.securityStrategyComplex1 = new DevExpress.ExpressApp.Security.SecurityStrategyComplex();
            this.CoreAuthenticationApp1   = new FDIT.Core.Seguridad.CoreAuthentication();
            this.securityModule1          = new DevExpress.ExpressApp.Security.SecurityModule();
            this.coreModule1       = new FDIT.Core.CoreModule();
            this.afipModule1       = new FDIT.Core.AFIP.AFIPModule();
            this.afipWsMtxcaModule = new FDIT.Core.AFIP.AFIPWsMtxcaModule();
            this.segurosModule1    = new FDIT.Core.Seguros.SegurosModule();
            this.segurosWinModule1 = new FDIT.Core.Seguros.Win.SegurosWinModule();
            this.fileAttachmentsWindowsFormsModule1 =
                new DevExpress.ExpressApp.FileAttachments.Win.FileAttachmentsWindowsFormsModule();
            this.reportsWindowsFormsModule1 = new DevExpress.ExpressApp.Reports.Win.ReportsWindowsFormsModule();
            this.viewVariantsModule1        = new DevExpress.ExpressApp.ViewVariantsModule.ViewVariantsModule();
            this.auditTrailModule1          = new DevExpress.ExpressApp.AuditTrail.AuditTrailModule();
            this.pivotGridModule1           = new DevExpress.ExpressApp.PivotGrid.PivotGridModule();
            this.treeListEditorsModuleBase1 = new DevExpress.ExpressApp.TreeListEditors.TreeListEditorsModuleBase();
            this.chartModule1 = new DevExpress.ExpressApp.Chart.ChartModule();
            this.kpiModule1   = new DevExpress.ExpressApp.Kpi.KpiModule();
            this.validationWindowsFormsModule1         = new DevExpress.ExpressApp.Validation.Win.ValidationWindowsFormsModule();
            this.htmlPropertyEditorWindowsFormsModule1 =
                new DevExpress.ExpressApp.HtmlPropertyEditor.Win.HtmlPropertyEditorWindowsFormsModule();
            this.treeListEditorsWindowsFormsModule1 =
                new DevExpress.ExpressApp.TreeListEditors.Win.TreeListEditorsWindowsFormsModule();
            this.chartWindowsFormsModule1 = new DevExpress.ExpressApp.Chart.Win.ChartWindowsFormsModule();
            ((System.ComponentModel.ISupportInitialize)(this)).BeginInit();
            //
            // sqlConnection1
            //
            this.sqlConnection1.FireInfoMessageEventOnUserErrors = false;
            //
            // reportsModule1
            //
            this.reportsModule1.EnableInplaceReports = true;
            this.reportsModule1.ReportDataType       = typeof(DevExpress.Persistent.BaseImpl.ReportData);
            //
            // validationModule1
            //
            this.validationModule1.AllowValidationDetailsAccess = true;
            //
            // stateMachineModule1
            //
            this.stateMachineModule1.StateMachineStorageType =
                typeof(DevExpress.ExpressApp.StateMachine.Xpo.XpoStateMachine);
            //
            // securityStrategyComplex1
            //
            this.securityStrategyComplex1.Authentication = this.CoreAuthenticationApp1;
            this.securityStrategyComplex1.RoleType       = typeof(FDIT.Core.Seguridad.Rol);
            this.securityStrategyComplex1.UserType       = typeof(FDIT.Core.Seguridad.Usuario);
            //
            // coreModule1
            //
            this.coreModule1.FileAttachmentsBasePath = "";
            //
            // viewVariantsModule1
            //
            this.viewVariantsModule1.GenerateVariantsNode     = true;
            this.viewVariantsModule1.ShowAdditionalNavigation = false;
            //
            // auditTrailModule1
            //
            this.auditTrailModule1.AuditDataItemPersistentType =
                typeof(DevExpress.Persistent.BaseImpl.AuditDataItemPersistent);
            //
            // WinApplication
            //
            this.ApplicationName = "CORE";
            this.Connection      = this.sqlConnection1;
            this.Modules.Add(this.module1);
            this.Modules.Add(this.module2);
            this.Modules.Add(this.cloneObjectModule1);
            this.Modules.Add(this.reportsModule1);
            this.Modules.Add(this.validationModule1);
            this.Modules.Add(this.conditionalAppearanceModule1);
            this.Modules.Add(this.stateMachineModule1);
            this.Modules.Add(this.viewVariantsModule1);
            this.Modules.Add(this.auditTrailModule1);
            this.Modules.Add(this.pivotGridModule1);
            this.Modules.Add(this.treeListEditorsModuleBase1);
            this.Modules.Add(this.chartModule1);
            this.Modules.Add(this.kpiModule1);
            this.Modules.Add(this.coreModule1);
            this.Modules.Add(this.fileAttachmentsWindowsFormsModule1);
            this.Modules.Add(this.reportsWindowsFormsModule1);
            this.Modules.Add(this.validationWindowsFormsModule1);
            this.Modules.Add(this.securityModule1);
            this.Modules.Add(this.htmlPropertyEditorWindowsFormsModule1);
            this.Modules.Add(this.treeListEditorsWindowsFormsModule1);
            this.Modules.Add(this.chartWindowsFormsModule1);
            this.Modules.Add(this.module4);
            this.Modules.Add(this.afipModule1);
            this.Modules.Add(this.afipWsMtxcaModule);
            this.Modules.Add(this.segurosModule1);
            this.Modules.Add(this.segurosWinModule1);
            this.Security = this.securityStrategyComplex1;

            this.DatabaseVersionMismatch +=
                new System.EventHandler <DevExpress.ExpressApp.DatabaseVersionMismatchEventArgs>(
                    this.CoreWindowsFormsApplication_DatabaseVersionMismatch);
            this.CustomizeLanguagesList +=
                new System.EventHandler <DevExpress.ExpressApp.CustomizeLanguagesListEventArgs>(
                    this.CoreWindowsFormsApplication_CustomizeLanguagesList);

            ((System.ComponentModel.ISupportInitialize)(this)).EndInit();
        }