Пример #1
0
 public ProductionController(UserManager <ApplicationUser> userManager, IIsolatorService isolatorService, IProductionService productionService, ILookupService lookupService, IBusinessService _businessService) : base(userManager, _businessService)
 {
     _isolatorService   = isolatorService;
     _productionService = productionService;
     this.lookupService = lookupService;
     businessService    = _businessService;
 }
Пример #2
0
 public ProductionController(
     IProductionService service
     , IServiceBusService serviceBusService)
 {
     _service           = service;
     _serviceBusService = serviceBusService;
 }
        public InventoryServiceFactory(
            IWarehouseOrderService warehouseOrderService,
            IIntraWarehouseOrderService intraWarehouseOrderService,
            ITreatmentOrderService treatmentOrderService,
            IProductionService productionService)
        {
            if (warehouseOrderService == null)
            {
                throw new ArgumentNullException("warehouseOrderService");
            }
            _warehouseOrderService = warehouseOrderService;

            if (intraWarehouseOrderService == null)
            {
                throw new ArgumentNullException("intraWarehouseOrderService");
            }
            _intraWarehouseOrderService = intraWarehouseOrderService;

            if (treatmentOrderService == null)
            {
                throw new ArgumentNullException("treatmentOrderService");
            }
            _treatmentOrderService = treatmentOrderService;

            if (productionService == null)
            {
                throw new ArgumentNullException("productionService");
            }
            _productionService = productionService;
        }
Пример #4
0
 public SalesController(ILogger <SalesController> logger, IHumanResourcesService humanResourcesBusinessObject, IProductionService productionBusinessObject, ISalesService salesBusinessObject)
 {
     Logger = logger;
     HumanResourcesBusinessObject = humanResourcesBusinessObject;
     ProductionBusinessObject     = productionBusinessObject;
     SalesBusinessObject          = salesBusinessObject;
 }
 public ProductionPlanController(IMapper mapper,
                                 ILogger <ProductionPlanController> logger,
                                 IProductionService productionService)
 {
     _productionService = productionService;
     _mapper            = mapper;
     _logger            = logger;
 }
Пример #6
0
 public ProductionBatchInstructionsController(IProductionService productionService)
 {
     if (productionService == null)
     {
         throw new ArgumentNullException("productionService");
     }
     _productionService = productionService;
 }
Пример #7
0
 public WorkModesController(IProductionService productionService)
 {
     if (productionService == null)
     {
         throw new ArgumentNullException("productionService");
     }
     _productionService = productionService;
 }
 /*Section="Constructor"*/
 public ProductionContentController(
     ILoggerFactory loggerFactory,
     IProductionContentService productionContentService,
     IProductionService productionService)
     : base(loggerFactory, productionContentService)
 {
     _productionService = productionService;
 }
Пример #9
0
 public ProductionServiceController(IWebSession webSession, ILog log, IRecipeRepository recipeRepository,
                                    IProductionService productionService, IRecipeService recipeService, IMaterialRepository materialRepository) : base(webSession, log)
 {
     m_recipeRepository   = recipeRepository;
     m_productionService  = productionService;
     m_recipeService      = recipeService;
     m_materialRepository = materialRepository;
 }
 public PackScheduleReportingService(IProductionService productionService)
 {
     if (productionService == null)
     {
         throw new ArgumentNullException("productionService");
     }
     _productionService = productionService;
 }
Пример #11
0
 public DailyScrapRateController(
     IScrapService scrapService,
     IProductionService productionService
     )
 {
     _scrapService      = scrapService ?? throw new ArgumentNullException(nameof(scrapService));
     _productionService =
         productionService ?? throw new ArgumentNullException(nameof(productionService));
 }
Пример #12
0
        public ProductionLessPage(IProductionService productionService, IOptions <AppSettings> settings, IMapper mapper)
        {
            _productionService = productionService;
            _mapper            = mapper;
            _settings          = settings.Value;
            InitializeComponent();

            UpdateDataGrid();
        }
Пример #13
0
 public GoodsOwnPage(IGoodsOwnService goodsOwnService, ICategoryService categoryService,
                     IOptions <AppSettings> settings, IMapper mapper, IProductionService productionService)
 {
     _goodsOwnService   = goodsOwnService;
     _categoryService   = categoryService;
     _settings          = settings.Value;
     _mapper            = mapper;
     _productionService = productionService;
     InitializeComponent();
 }
Пример #14
0
 public ProductionWindow(IProductionContentsService productionContentsService,
                         IProductionService productionService, IGoodsInMarketService goodsInMarketService, IMapper mapper,
                         IOptions <AppSettings> settings)
 {
     _productionContentsService = productionContentsService;
     _productionService         = productionService;
     _goodsInMarketService      = goodsInMarketService;
     _mapper   = mapper;
     _settings = settings.Value;
     InitializeComponent();
 }
        public PackSchedulesController(IProductionService productionService, IUserIdentityProvider userIdentityProvider)
        {
            if (productionService == null)
            {
                throw new ArgumentNullException("productionService");
            }
            _productionService = productionService;

            if (userIdentityProvider == null)
            {
                throw new ArgumentNullException("userIdentityProvider");
            }
            _userIdentityProvider = userIdentityProvider;
        }
 public LogisticsService(
     SapContext context,
     Fmsb2Context fmsb2Context,
     IMapper mapper,
     IConfiguration configuration,
     IProductionService productionService
     ) : base(context, fmsb2Context)
 {
     _mapper        = mapper ?? throw new ArgumentNullException(nameof(mapper));
     _configuration =
         configuration ?? throw new ArgumentNullException(nameof(configuration));
     _productionService =
         productionService ?? throw new ArgumentNullException(nameof(productionService));
 }
Пример #17
0
 public OeeService(
     IProductionService productionService,
     IScrapService scrapService,
     IDowntimeRepository downtimeRepository,
     FmsbOeeContext fmsbOeeContext
     )
 {
     _productionService =
         productionService ?? throw new ArgumentNullException(nameof(productionService));
     _scrapService       = scrapService ?? throw new ArgumentNullException(nameof(scrapService));
     _downtimeRepository =
         downtimeRepository ?? throw new ArgumentNullException(nameof(downtimeRepository));
     _fmsbOeeContext =
         fmsbOeeContext ?? throw new ArgumentNullException(nameof(fmsbOeeContext));
 }
Пример #18
0
 public MovieController(
     IMovieService movieService,
     IActorService actorService,
     ICategoryService categoryService,
     IGenreService genreService,
     IProducerService producerService,
     IProductionService productionService,
     ILogger <MovieController> logger)
 {
     _movieService      = movieService;
     _actorService      = actorService;
     _categoryService   = categoryService;
     _genreService      = genreService;
     _producerService   = producerService;
     _productionService = productionService;
     _logger            = logger;
 }
        public ProductionPage(IProductionService productionService, IEmployeeService employeeService,
                              IGoodsOwnService goodsOwnService, IOptions <AppSettings> settings, IMapper mapper,
                              SimpleNavigationService navigationService, IProductionContentsService productionContentsService,
                              ICategoryService categoryService, IGoodsInMarketOwnService goodsInMarketOwnService, IGoodsWriteOffOwnService goodsWriteOffOwnService)
        {
            _productionService         = productionService;
            _employeeService           = employeeService;
            _goodsOwnService           = goodsOwnService;
            _mapper                    = mapper;
            _navigationService         = navigationService;
            _productionContentsService = productionContentsService;
            _settings                  = settings.Value;
            _categoryService           = categoryService;
            _goodsInMarketOwnService   = goodsInMarketOwnService;
            _goodsWriteOffOwnService   = goodsWriteOffOwnService;
            InitializeComponent();

            UpdateDataGrid();
        }
        public GoodsInMarketOwnPage(IGoodsInMarketOwnService goodsInMarketOwnService, IMarketService marketService,
                                    IProductionService productionService, IOptions <AppSettings> settings, IMapper mapper,
                                    IGoodsOwnService goodsOwnService, IBasketOwnService basketOwnService,
                                    IGoodsWriteOffOwnService goodsWriteOffOwnService, ICategoryService categoryService)
        {
            _goodsInMarketOwnService = goodsInMarketOwnService;
            _marketService           = marketService;
            _productionService       = productionService;
            _settings                = settings.Value;
            _mapper                  = mapper;
            _goodsOwnService         = goodsOwnService;
            _basketOwnService        = basketOwnService;
            _goodsWriteOffOwnService = goodsWriteOffOwnService;
            _categoryService         = categoryService;

            InitializeComponent();

            ProductionComboBox.IsEnabled = false;
        }
 public ProductController(IProductionService _productionService)
 {
     productionService = _productionService;
 }
Пример #22
0
 public ProductionController(IProductionService service, IProductionIndexViewModelBinder modelBinder)
 {
     _service     = service;
     _modelBinder = modelBinder;
 }
        public async Task <List <DailyScrapByShiftDateDto> > GetDailyScrapRate(
            DateTime start,
            DateTime end,
            string area,
            IProductionService productionService,
            bool isPurchasedScrap = false
            )
        {
            if (productionService == null)
            {
                throw new ArgumentNullException(nameof(productionService));
            }

            var productionQry = productionService.GetProductionQueryable(
                new ProductionResourceParameter {
                StartDate = start, EndDate = end, Area = area
            }
                );
            var production = await productionQry
                             .GroupBy(x => new { x.ShiftDate })
                             .Select(x => new { x.Key.ShiftDate, TotalProd = x.Sum(s => s.QtyProd) })
                             .ToListAsync()
                             .ConfigureAwait(false);

            //var finScrap = new List<string> { "anodize", "skirt coat" };
            var scrapQry = GetScrap2Queryable(
                new ScrapResourceParameter
            {
                StartDate        = start,
                EndDate          = end,
                IsPurchasedScrap = isPurchasedScrap
            }
                );

            //scrapQry = scrapQry.Where(x => area.ToLower() == "skirt coat"
            //                            ? (finScrap.Contains(x.ScrapAreaName.ToLower()))
            //                            : x.ScrapAreaName == _utilityService.MapAreaToDepartment(area));

            var scrapData = await scrapQry
                            .Where(x => x.Area == area)
                            .GroupBy(x => new { x.ShiftDate })
                            .Select(x => new { x.Key.ShiftDate, TotalScrap = x.Sum(s => s.Qty) })
                            .OrderBy(x => x.ShiftDate)
                            .ToListAsync()
                            .ConfigureAwait(false);

            var distinctShiftDates      = production.Select(x => x.ShiftDate).Distinct().ToList();
            var distinctShiftDatesScrap = scrapData.Select(x => x.ShiftDate).Distinct().ToList();

            distinctShiftDates.AddRange(distinctShiftDatesScrap);
            var shiftDates = distinctShiftDates.Select(x => x).Distinct().OrderBy(x => x).ToList();

            var data = shiftDates
                       .Select(
                x =>
            {
                var shiftDate = x.ToDateTime();
                var scrap     = scrapData.Where(q => q.ShiftDate == shiftDate);
                var prod      = production.Where(q => q.ShiftDate == shiftDate);

                var totalScrap = scrap.Sum(q => q.TotalScrap ?? 0);
                var sapNet     = prod.Sum(p => p.TotalProd ?? 0);
                var sapGross   = sapNet + totalScrap;
                var scrapRate  = sapNet == 0 ? null : (decimal?)totalScrap / sapGross;

                return(new DailyScrapByShiftDateDto
                {
                    ShiftDate = shiftDate,
                    TotalScrap = totalScrap,
                    SapNet = sapNet,
                    SapGross = sapGross,
                    ScrapRate = scrapRate
                });
            }
                )
                       .OrderBy(x => x.ShiftDate)
                       .ToList();

            return(data);
        }
Пример #24
0
 public ProductionHub(IProductionService productionService)
 {
     _productionService = productionService;
 }
Пример #25
0
 public ProductionLossDICController(IProductionService productionService)
 {
     _productionService = productionService;
 }
Пример #26
0
 public ProductionController(IProductionService productionService)
 {
     this.productionService = productionService;
 }
Пример #27
0
 public ProductionController(IProductionService service)
 {
     this._service = service;
 }
 public ProductionsControllerTest()
 {
     _service    = new ProductionServiceFake();
     _controller = new ProductionsController(_service);
 }
 public ProductionsController(IProductionService service)
 {
     _service = service;
 }
Пример #30
0
 public ProductionController(ILogger <ProductionController> logger, IProductionService productionBusinessObject)
 {
     Logger = logger;
     ProductionBusinessObject = productionBusinessObject;
 }