Example #1
0
        public void GetCustomerOnboard(Hyland.Unity.Application con, string customerDocument)
        {
            OnbaseSettings onbaseSettings = this.GetOnbaseSettings();
            var            logger         = new FileLogger("C:\\Temp\\OnbaseIntegration.log");

            var statusFilter = new string[]
            {
                "INREVISION"
            };

            try
            {
                var customerRepository         = new SimPaulOnbase.Infraestructure.ApiDataAccess.CustomerApiRepository(this.GetApiSettings());
                var onbaseConector             = new OnbaseInMemoryConector(con);
                var onbaseCustomerService      = new CustomerOnboardOnbaseService(onbaseSettings, onbaseConector, logger, customerRepository);
                var customerIntegrationUseCase = new CustomerOnboardIntegrationUseCase(customerRepository, onbaseCustomerService, logger);
                customerIntegrationUseCase.Handle(new CustomerIntegrationInput
                {
                    StatusFilter = statusFilter
                });
            }
            catch (System.Exception ex)
            {
                System.Diagnostics.Debug.Write(ex.ToString());
            }
        }
Example #2
0
        public void OnWorkflowScriptExecute(Hyland.Unity.Application app, Hyland.Unity.WorkflowEventArgs args)
        {
            OnbaseSettings onbaseSettings = GetOnbaseSettings();
            var            logger         = new FileLogger("C:\\Temp\\OnbaseIntegration.log");

            var statusFilter = new string[]
            {
                "INREVISION"
            };

            try
            {
                var customerRepository         = new CustomerApiRepository(this.GetApiSettings());
                var onbaseConector             = new OnbaseInMemoryConector(app);
                var onbaseCustomerService      = new CustomerOnboardOnbaseService(onbaseSettings, onbaseConector, logger, customerRepository);
                var customerIntegrationUseCase = new CustomerOnboardIntegrationUseCase(customerRepository, onbaseCustomerService, logger);
                customerIntegrationUseCase.Handle(new CustomerIntegrationInput
                {
                    StatusFilter = statusFilter
                });
            }
            catch (System.Exception ex)
            {
                throw ex;
            }
        }