public RecipeActionsController(IRecipeManager recipeManager, UserManager <User> userManager, IEnumerable <IActionDescriptor> actionDescriptors) { _recipeManager = recipeManager; _userManager = userManager; _actionDescriptors = actionDescriptors; }
public AdminController( IEnumerable<IExtensionDisplayEventHandler> extensionDisplayEventHandlers, IOrchardServices services, IModuleService moduleService, IDataMigrationManager dataMigrationManager, IReportsCoordinator reportsCoordinator, IExtensionManager extensionManager, IFeatureManager featureManager, IRecipeHarvester recipeHarvester, IRecipeManager recipeManager, ShellDescriptor shellDescriptor, ShellSettings shellSettings, IShapeFactory shapeFactory) { Services = services; _extensionDisplayEventHandler = extensionDisplayEventHandlers.FirstOrDefault(); _moduleService = moduleService; _dataMigrationManager = dataMigrationManager; _reportsCoordinator = reportsCoordinator; _extensionManager = extensionManager; _featureManager = featureManager; _recipeHarvester = recipeHarvester; _recipeManager = recipeManager; _shellDescriptor = shellDescriptor; _shellSettings = shellSettings; Shape = shapeFactory; T = NullLocalizer.Instance; Logger = NullLogger.Instance; }
public CheckExchangeBalanceController(IRecipeManager recipeManager, UserManager <User> userManager, IMemoryCache memoryCache, IExternalServiceManager externalServiceManager) : base(recipeManager, userManager, memoryCache, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public static PagedList <RecipeSearchModel> SearchRecipes(this IRecipeManager recipeManager, int page, int pageSize, RecipeSortType sortType, ViewModels.Filter filter) { if (pageSize < 1) { pageSize = 1; } ICollection <RecipeSearchModel> data = Mapper.Map <IEnumerable <Entities.Recipe>, IEnumerable <RecipeSearchModel> >( recipeManager.FindByName(filter.SearchKeyword ?? string.Empty)).ToList(); var orderedData = RecipeHelper.SortRecipes(recipeManager.FilterProducts(data, filter), sortType); int pages = (data.Count + pageSize - 1) / pageSize; if (page > pages) { page = pages; } if (page < 1) { page = 1; } return(new PagedList <RecipeSearchModel>(orderedData, page, pageSize)); }
public ReceiveWebRequestController(IRecipeManager recipeManager, UserManager <User> userManager, IMemoryCache memoryCache, ITriggerDispatcher triggerDispatcher, IExternalServiceManager externalServiceManager) : base(recipeManager, userManager, memoryCache, externalServiceManager) { _triggerDispatcher = triggerDispatcher; }
public ShowRecipeByName(IRecipeManager recipeManager, IInputProvider inputProvider, IModelDrawer <Recipe> recipeDrawer) : base(title: "Show recipe by name") { this.inputProvider = inputProvider; this.recipeDrawer = recipeDrawer; this.recipeManager = recipeManager; }
public CatalogViewModel( ICategoryManager categoryManager, IRecipeManager recipeManager) { _categoryManager = categoryManager; _recipeManager = recipeManager; }
public GetExchangeRateController(IMemoryCache memoryCache, UserManager <User> userManager, IRecipeManager recipeManager, IExternalServiceManager externalServiceManager) : base(memoryCache, userManager, recipeManager, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public ActionDispatcher(IEnumerable <IActionHandler> handlers, IRecipeManager recipeManager, ILogger <ActionDispatcher> logger) { _handlers = handlers; _recipeManager = recipeManager; _logger = logger; }
public RecipeTriggersController(IRecipeManager recipeManager, UserManager <User> userManager, IEnumerable <ITriggerDescriptor> triggerDescriptors) { _recipeManager = recipeManager; _userManager = userManager; _triggerDescriptors = triggerDescriptors; }
public AdminController( IEnumerable <IExtensionDisplayEventHandler> extensionDisplayEventHandlers, IBoyingServices services, IModuleService moduleService, IDataMigrationManager dataMigrationManager, IExtensionManager extensionManager, IFeatureManager featureManager, IRecipeHarvester recipeHarvester, IRecipeManager recipeManager, ShellDescriptor shellDescriptor, ShellSettings shellSettings, IShapeFactory shapeFactory) { Services = services; _extensionDisplayEventHandler = extensionDisplayEventHandlers.FirstOrDefault(); _moduleService = moduleService; _dataMigrationManager = dataMigrationManager; _extensionManager = extensionManager; _featureManager = featureManager; _recipeHarvester = recipeHarvester; _recipeManager = recipeManager; _shellDescriptor = shellDescriptor; _shellSettings = shellSettings; Shape = shapeFactory; T = NullLocalizer.Instance; Logger = NullLogger.Instance; }
public TriggerDispatcher(IEnumerable <ITriggerHandler> handlers, IRecipeManager recipeManager, IActionDispatcher actionDispatcher) { _handlers = handlers; _recipeManager = recipeManager; _actionDispatcher = actionDispatcher; }
public PlaceOrderController(IMemoryCache memoryCache, UserManager <User> userManager, IRecipeManager recipeManager, IExternalServiceManager externalServiceManager) : base(memoryCache, userManager, recipeManager, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public RecipeExecutor( IRecipeParser recipeParser, IRecipeManager recipeManager, IShellDescriptorManager shellDescriptorManager) { _recipeManager = recipeManager; _shellDescriptorManager = shellDescriptorManager; }
public NBXplorerNewTransactionController(IRecipeManager recipeManager, UserManager <User> userManager, IMemoryCache memoryCache, IExternalServiceManager externalServiceManager) : base(recipeManager, userManager, memoryCache, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public DynamicServiceService(ExternalServiceData data, IRecipeManager recipeManager, IActionDispatcher actionDispatcher, IExternalServiceManager externalServiceManager) : base(data) { _data = data; _recipeManager = recipeManager; _actionDispatcher = actionDispatcher; _externalServiceManager = externalServiceManager; }
public RecipeActionFooterViewComponent(IEnumerable <ITriggerDescriptor> triggerDescriptors, IEnumerable <IActionDescriptor> actionDescriptors, IRecipeManager recipeManager) { _triggerDescriptors = triggerDescriptors; _actionDescriptors = actionDescriptors; _recipeManager = recipeManager; }
MainWindowViewModel(IRecipeManager recipeManager) { recipes = new List <RecipeModel>(); foreach (RecipeModel recipe in recipes) { recipes.Add(new RecipeModel(recipe)); } }
public override void Init() { base.Init(); _recipeManager = _container.Resolve <IRecipeManager>(); _recipeParser = _container.Resolve <IRecipeParser>(); _recipeHarvester = _container.Resolve <IRecipeHarvester>(); }
public MenuController(IMapper mapper, IMenuManager menuManager, IRecipeManager recipeManager, IDayManager dayManager) { _mapper = mapper; _menuManager = menuManager; _recipeManager = recipeManager; _dayManager = dayManager; }
public GenerateNextAddressController(IMemoryCache memoryCache, UserManager <User> userManager, IRecipeManager recipeManager, IExternalServiceManager externalServiceManager) : base( memoryCache, userManager, recipeManager, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public MainWindowViewModel(IRecipeManager recipeManager) { this.recipeManager = recipeManager; recipes = new ObservableCollection <RecipeModel>(); foreach (var recipe in recipeManager.GetRecipes()) { recipes.Add(new RecipeModel(recipe)); } }
public NBXplorerGetBalanceController(IMemoryCache memoryCache, UserManager <User> userManager, IRecipeManager recipeManager, IExternalServiceManager externalServiceManager) : base( memoryCache, userManager, recipeManager, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public GetPaymentsFromInvoiceController(IMemoryCache memoryCache, UserManager <User> userManager, IRecipeManager recipeManager, IExternalServiceManager externalServiceManager) : base( memoryCache, userManager, recipeManager, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public BTCPayEmailReceiptsController( IExternalServiceManager externalServiceManager, UserManager <User> userManager, IRecipeManager recipeManager) { _externalServiceManager = externalServiceManager; _userManager = userManager; _recipeManager = recipeManager; }
public TimerController( IRecipeManager recipeManager, UserManager <User> userManager, IMemoryCache memoryCache) { _recipeManager = recipeManager; _userManager = userManager; _memoryCache = memoryCache; }
public SendTransactionController(IMemoryCache memoryCache, UserManager <User> userManager, IExternalServiceManager externalServiceManager, IRecipeManager recipeManager) : base( memoryCache, userManager, recipeManager, externalServiceManager) { _externalServiceManager = externalServiceManager; }
public FiatExchangeConversionController( IExternalServiceManager externalServiceManager, UserManager <User> userManager, IRecipeManager recipeManager) { _externalServiceManager = externalServiceManager; _userManager = userManager; _recipeManager = recipeManager; }
public DCAController( IExternalServiceManager externalServiceManager, UserManager <User> userManager, IRecipeManager recipeManager) { _externalServiceManager = externalServiceManager; _userManager = userManager; _recipeManager = recipeManager; }
public RecipesCommands( IRecipeHarvester recipeHarvester, IRecipeManager recipeManager, IExtensionManager extensionManager, IRecipeResultAccessor recipeResultAccessor) { _recipeHarvester = recipeHarvester; _recipeManager = recipeManager; _extensionManager = extensionManager; _recipeResultAccessor = recipeResultAccessor; }
protected BaseActionController(IMemoryCache memoryCache, UserManager <User> userManager, IRecipeManager recipeManager, IExternalServiceManager externalServiceManager) { _memoryCache = memoryCache; _userManager = userManager; _recipeManager = recipeManager; _externalServiceManager = externalServiceManager; }
public void Initialize() { this.ingredientRepository = new IngredientRepositoryMock(); this.recipeRepository = new RecipeRepositoryMock(); this.recipeIngredientRepository = new RecipeIngredientRepositoryMock(); this.recipeManager = new RecipeManager( this.ingredientRepository, this.recipeRepository, this.recipeIngredientRepository ); }
public AdminController( IEnumerable<Orchard.Modules.Events.IExtensionDisplayEventHandler> extensionDisplayEventHandlers, IOrchardServices services, IModuleService moduleService, IDataMigrationManager dataMigrationManager, IReportsCoordinator reportsCoordinator, IExtensionManager extensionManager, IFeatureManager featureManager, IRecipeHarvester recipeHarvester, IRecipeManager recipeManager, ShellDescriptor shellDescriptor, ShellSettings shellSettings, IShapeFactory shapeFactory, IPackageService packageService, IMimeTypeProvider mimeTypeProvider, ISiteThemeService siteThemeService, IThemeService themeService) { Services = services; _extensionDisplayEventHandler = extensionDisplayEventHandlers.FirstOrDefault(); _moduleService = moduleService; _dataMigrationManager = dataMigrationManager; _reportsCoordinator = reportsCoordinator; _extensionManager = extensionManager; _featureManager = featureManager; _recipeHarvester = recipeHarvester; _recipeManager = recipeManager; _shellDescriptor = shellDescriptor; _shellSettings = shellSettings; Shape = shapeFactory; _packageService = packageService; _mimeTypeProvider = mimeTypeProvider; _siteThemeService = siteThemeService; _themeService = themeService; T = NullLocalizer.Instance; Logger = NullLogger.Instance; _tempPackageStoragePath = new Lazy<string>(() => { var path = HostingEnvironment.MapPath("~/App_Data/Packages"); if (!Directory.Exists(path)) { Directory.CreateDirectory(path); } return path; }); }
public ImportExportService( IOrchardServices orchardServices, IContentDefinitionManager contentDefinitionManager, IContentDefinitionWriter contentDefinitionWriter, IAppDataFolder appDataFolder, IRecipeParser recipeParser, IRecipeManager recipeManager, IShellDescriptorManager shellDescriptorManager) { _orchardServices = orchardServices; _contentDefinitionManager = contentDefinitionManager; _contentDefinitionWriter = contentDefinitionWriter; _appDataFolder = appDataFolder; _recipeParser = recipeParser; _recipeManager = recipeManager; _shellDescriptorManager = shellDescriptorManager; Logger = NullLogger.Instance; T = NullLocalizer.Instance; }
public ImportExportService( IOrchardServices orchardServices, IContentDefinitionManager contentDefinitionManager, IContentDefinitionWriter contentDefinitionWriter, IAppDataFolder appDataFolder, IRecipeParser recipeParser, IRecipeManager recipeManager, IShellDescriptorManager shellDescriptorManager, IClock clock, IEnumerable<IExportEventHandler> exportEventHandlers) { _orchardServices = orchardServices; _contentDefinitionManager = contentDefinitionManager; _contentDefinitionWriter = contentDefinitionWriter; _appDataFolder = appDataFolder; _recipeParser = recipeParser; _recipeManager = recipeManager; _shellDescriptorManager = shellDescriptorManager; _clock = clock; _exportEventHandlers = exportEventHandlers; Logger = NullLogger.Instance; T = NullLocalizer.Instance; }
public PackagingServicesController( ShellSettings shellSettings, IPackageManager packageManager, IPackagingSourceManager packagingSourceManager, IAppDataFolderRoot appDataFolderRoot, IOrchardServices services, IModuleService moduleService, IRecipeHarvester recipeHarvester, IRecipeManager recipeManager) { _shellSettings = shellSettings; _packageManager = packageManager; _appDataFolderRoot = appDataFolderRoot; _moduleService = moduleService; _recipeHarvester = recipeHarvester; _recipeManager = recipeManager; _packagingSourceManager = packagingSourceManager; Services = services; T = NullLocalizer.Instance; Logger = Logging.NullLogger.Instance; }
public void Setup() { kernel = new StandardKernel(new NinjectAPIModule()); recipeManager = kernel.Get<RecipeManager>(); }
public RecipeController(IRecipeManager recipeManager, IProductManager productManager) { RecipeManager = recipeManager; ProductManager = productManager; }
public void Init() { _tempFolderName = Path.GetTempFileName(); File.Delete(_tempFolderName); var assembly = GetType().Assembly; foreach (var name in assembly.GetManifestResourceNames()) { if (name.StartsWith(DataPrefix)) { string text; using (var stream = assembly.GetManifestResourceStream(name)) { using (var reader = new StreamReader(stream)) text = reader.ReadToEnd(); } // Pro filtering var relativePath = name .Substring(DataPrefix.Length) .Replace(".txt", ":txt") .Replace(".recipe.xml", ":recipe:xml") .Replace('.', Path.DirectorySeparatorChar) .Replace(":txt", ".txt") .Replace(":recipe:xml", ".recipe.xml"); var targetPath = Path.Combine(_tempFolderName, relativePath); Directory.CreateDirectory(Path.GetDirectoryName(targetPath)); using (var stream = new FileStream(targetPath, FileMode.Create)) { using (var writer = new StreamWriter(stream)) { writer.Write(text); } } } } var builder = new ContainerBuilder(); var harvester = new ExtensionHarvester(new StubCacheManager(), new StubWebSiteFolder(), new Mock<ICriticalErrorProvider>().Object); _folders = new ModuleFolders(new[] { _tempFolderName }, harvester); builder.RegisterType<RecipeManager>().As<IRecipeManager>(); builder.RegisterType<RecipeHarvester>().As<IRecipeHarvester>(); builder.RegisterType<RecipeStepExecutor>().As<IRecipeStepExecutor>(); builder.RegisterType<StubStepQueue>().As<IRecipeStepQueue>().InstancePerLifetimeScope(); builder.RegisterType<StubRecipeJournal>().As<IRecipeJournal>(); builder.RegisterType<StubRecipeScheduler>().As<IRecipeScheduler>(); builder.RegisterType<ExtensionManager>().As<IExtensionManager>(); builder.RegisterType<StubAppDataFolder>().As<IAppDataFolder>(); builder.RegisterType<StubClock>().As<IClock>(); builder.RegisterType<StubCacheManager>().As<ICacheManager>(); builder.RegisterType<StubParallelCacheContext>().As<IParallelCacheContext>(); builder.RegisterType<StubAsyncTokenProvider>().As<IAsyncTokenProvider>(); builder.RegisterInstance(_folders).As<IExtensionFolders>(); builder.RegisterInstance(new Mock<IRecipeExecuteEventHandler>().Object); builder.RegisterType<Environment.Extensions.ExtensionManagerTests.StubLoaders>().As<IExtensionLoader>(); builder.RegisterType<RecipeParser>().As<IRecipeParser>(); builder.RegisterType<StubWebSiteFolder>().As<IWebSiteFolder>(); builder.RegisterType<CustomRecipeHandler>().As<IRecipeHandler>(); _container = builder.Build(); _recipeManager = _container.Resolve<IRecipeManager>(); _recipeParser = _container.Resolve<IRecipeParser>(); _recipeHarvester = _container.Resolve<IRecipeHarvester>(); }
public override void Init() { base.Init(); _recipeManager = _container.Resolve<IRecipeManager>(); _recipeParser = _container.Resolve<IRecipeParser>(); _recipeHarvester = _container.Resolve<IRecipeHarvester>(); }
public RecipesCommands(IRecipeHarvester recipeHarvester, IRecipeManager recipeManager, IExtensionManager extensionManager) { _recipeHarvester = recipeHarvester; _recipeManager = recipeManager; _extensionManager = extensionManager; }