本文整理汇总了C#中IInventoryService类的典型用法代码示例。如果您正苦于以下问题:C# IInventoryService类的具体用法?C# IInventoryService怎么用?C# IInventoryService使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IInventoryService类属于命名空间,在下文中一共展示了IInventoryService类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OrdersController
public OrdersController(
IQuartetClientFactory clientFactory,
IMappingService<Order, OrderViewModel> orderMapping,
IMappingService<Customer, HCardViewModel> hcardMapping,
IMappingService<Address, AddressViewModel> addressMapping,
IMailingService mailingService,
IInvoicingService invoicingService,
IFeaturesConfigService featuresConfigService,
IAppSettings appSettings,
IConsultantContext consultantContext,
IConsultantDataServiceClientFactory consultantDataServiceClientFactory,
IPromotionService promotionService,
IProductCatalogClientFactory productCatalogClientFactory,
IInventoryService inventoryService,
ISubsidiaryAccessor subsidiaryAccessor
)
{
_clientFactory = clientFactory;
_orderMapping = orderMapping;
_hcardMapping = hcardMapping;
_addressMapping = addressMapping;
_mailingService = mailingService;
_invoicingService = invoicingService;
_featuresConfigService = featuresConfigService;
_appSettings = appSettings;
_consultantContext = consultantContext;
_consultantDataServiceClientFactory = consultantDataServiceClientFactory;
_promotionService = promotionService;
_productCatalogClientFactory = productCatalogClientFactory;
_inventoryService = inventoryService;
_subsidiaryAccessor = subsidiaryAccessor;
}
示例2: SalesService
public SalesService(IFinancialService financialService,
IInventoryService inventoryService,
IRepository<SalesOrderHeader> salesOrderRepo,
IRepository<SalesInvoiceHeader> salesInvoiceRepo,
IRepository<SalesReceiptHeader> salesReceiptRepo,
IRepository<Customer> customerRepo,
IRepository<Account> accountRepo,
IRepository<Item> itemRepo,
IRepository<Measurement> measurementRepo,
IRepository<SequenceNumber> sequenceNumberRepo,
IRepository<PaymentTerm> paymentTermRepo,
IRepository<SalesDeliveryHeader> salesDeliveryRepo,
IRepository<Bank> bankRepo,
IRepository<GeneralLedgerSetting> generalLedgerSetting,
IRepository<Contact> contactRepo)
: base(sequenceNumberRepo, generalLedgerSetting, paymentTermRepo, bankRepo)
{
_financialService = financialService;
_inventoryService = inventoryService;
_salesOrderRepo = salesOrderRepo;
_salesInvoiceRepo = salesInvoiceRepo;
_salesReceiptRepo = salesReceiptRepo;
_customerRepo = customerRepo;
_accountRepo = accountRepo;
_itemRepo = itemRepo;
_measurementRepo = measurementRepo;
_sequenceNumberRepo = sequenceNumberRepo;
_paymentTermRepo = paymentTermRepo;
_salesDeliveryRepo = salesDeliveryRepo;
_bankRepo = bankRepo;
_genetalLedgerSetting = generalLedgerSetting;
_contactRepo = contactRepo;
}
示例3: WebFetchInvDescServerConnector
public WebFetchInvDescServerConnector(IConfigSource config, IHttpServer server, string configName) :
base(config, server, configName)
{
if (configName != String.Empty)
m_ConfigName = configName;
IConfig serverConfig = config.Configs[m_ConfigName];
if (serverConfig == null)
throw new Exception(String.Format("No section '{0}' in config file", m_ConfigName));
string invService = serverConfig.GetString("InventoryService", String.Empty);
if (invService == String.Empty)
throw new Exception("No InventoryService in config file");
Object[] args = new Object[] { config };
m_InventoryService =
ServerUtils.LoadPlugin<IInventoryService>(invService, args);
if (m_InventoryService == null)
throw new Exception(String.Format("Failed to load InventoryService from {0}; config is {1}", invService, m_ConfigName));
string libService = serverConfig.GetString("LibraryService", String.Empty);
m_LibraryService =
ServerUtils.LoadPlugin<ILibraryService>(libService, args);
WebFetchInvDescHandler webFetchHandler = new WebFetchInvDescHandler(m_InventoryService, m_LibraryService);
IRequestHandler reqHandler = new RestStreamHandler("POST", "/CAPS/WebFetchInvDesc/" /*+ UUID.Random()*/, webFetchHandler.FetchInventoryDescendentsRequest);
server.AddStreamHandler(reqHandler);
}
示例4: FetchInventory2ServerConnector
public FetchInventory2ServerConnector(IConfigSource config, IHttpServer server, string configName)
: base(config, server, configName)
{
if (configName != String.Empty)
m_ConfigName = configName;
IConfig serverConfig = config.Configs[m_ConfigName];
if (serverConfig == null)
throw new Exception(String.Format("No section '{0}' in config file", m_ConfigName));
string invService = serverConfig.GetString("InventoryService", String.Empty);
if (invService == String.Empty)
throw new Exception("No InventoryService in config file");
Object[] args = new Object[] { config };
m_InventoryService = ServerUtils.LoadPlugin<IInventoryService>(invService, args);
if (m_InventoryService == null)
throw new Exception(String.Format("Failed to load InventoryService from {0}; config is {1}", invService, m_ConfigName));
FetchInventory2Handler fiHandler = new FetchInventory2Handler(m_InventoryService);
IRequestHandler reqHandler
= new RestStreamHandler("POST", "/CAPS/FetchInventory/", fiHandler.FetchInventoryRequest);
server.AddStreamHandler(reqHandler);
}
示例5: XInventoryInConnector
public XInventoryInConnector(IConfigSource config, IHttpServer server, string configName) :
base(config, server, configName)
{
if (configName != String.Empty)
m_ConfigName = configName;
m_log.DebugFormat("[XInventoryInConnector]: Starting with config name {0}", m_ConfigName);
IConfig serverConfig = config.Configs[m_ConfigName];
if (serverConfig == null)
throw new Exception(String.Format("No section '{0}' in config file", m_ConfigName));
string inventoryService = serverConfig.GetString("LocalServiceModule",
String.Empty);
if (inventoryService == String.Empty)
throw new Exception("No InventoryService in config file");
Object[] args = new Object[] { config, m_ConfigName };
m_InventoryService =
ServerUtils.LoadPlugin<IInventoryService>(inventoryService, args);
IServiceAuth auth = ServiceAuth.Create(config, m_ConfigName);
server.AddStreamHandler(new XInventoryConnectorPostHandler(m_InventoryService, auth));
}
示例6: ConnectToServices
private void ConnectToServices(Action onConnectionCallback)
{
if (_retryCount < 4)
{
try
{
_corporateInventoryService =
new ChannelFactory<IInventoryService>("CorporateOfficeInventoryService").CreateChannel();
_webSiteInventoryChannel =
new ChannelFactory<IInventoryService>("WebSiteInventoryService");
_storeInventoryService = _webSiteInventoryChannel.CreateChannel();
_retryCount = 0;
if (onConnectionCallback != null)
onConnectionCallback();
}
catch
{
_retryCount += 1;
Thread.Sleep(2000);
}
}
}
示例7: FinancialService
public FinancialService(IInventoryService inventoryService,
IRepository<GeneralLedgerHeader> generalLedgerRepository,
IRepository<GeneralLedgerLine> generalLedgerLineRepository,
IRepository<Account> accountRepo,
IRepository<Tax> taxRepo,
IRepository<JournalEntryHeader> journalEntryRepo,
IRepository<FiscalYear> fiscalYearRepo,
IRepository<TaxGroup> taxGroupRepo,
IRepository<ItemTaxGroup> itemTaxGroupRepo,
IRepository<PaymentTerm> paymentTermRepo,
IRepository<Bank> bankRepo,
IRepository<Item> itemRepo,
IRepository<GeneralLedgerSetting> glSettingRepo
)
:base(null, null, paymentTermRepo, bankRepo)
{
_inventoryService = inventoryService;
_generalLedgerRepository = generalLedgerRepository;
_accountRepo = accountRepo;
_taxRepo = taxRepo;
_journalEntryRepo = journalEntryRepo;
_generalLedgerLineRepository = generalLedgerLineRepository;
_fiscalYearRepo = fiscalYearRepo;
_taxGroupRepo = taxGroupRepo;
_itemTaxGroupRepo = itemTaxGroupRepo;
_paymentTermRepo = paymentTermRepo;
_bankRepo = bankRepo;
_itemRepo = itemRepo;
_glSettingRepo = glSettingRepo;
}
示例8: BasicReportModule
public BasicReportModule(IRegionManager regionManager, BasicReportView basicReportView,
IWorkPeriodService workPeriodService, IPrinterService printerService, ICacheService cacheService,
IInventoryService inventoryService, IUserService userService, IAutomationService automationService,
IApplicationState applicationState, ILogService logService, ISettingService settingService)
: base(regionManager, AppScreens.ReportView)
{
ReportContext.PrinterService = printerService;
ReportContext.WorkPeriodService = workPeriodService;
ReportContext.InventoryService = inventoryService;
ReportContext.UserService = userService;
ReportContext.ApplicationState = applicationState;
ReportContext.CacheService = cacheService;
ReportContext.LogService = logService;
ReportContext.SettingService = settingService;
_userService = userService;
_regionManager = regionManager;
_basicReportView = basicReportView;
SetNavigationCommand(Resources.Reports, Resources.Common, "Images/Ppt.png", 60);
PermissionRegistry.RegisterPermission(PermissionNames.OpenReports, PermissionCategories.Navigation, Resources.CanDisplayReports);
PermissionRegistry.RegisterPermission(PermissionNames.ChangeReportDate, PermissionCategories.Report, Resources.CanChangeReportFilter);
//todo refactor
automationService.RegisterParameterSource("ReportName", () => ReportContext.Reports.Select(x => x.Header));
}
示例9: PurchasingService
public PurchasingService(IFinancialService financialService,
IInventoryService inventoryService,
IRepository<PurchaseOrderHeader> purchaseOrderRepo,
IRepository<PurchaseInvoiceHeader> purchaseInvoiceRepo,
IRepository<PurchaseReceiptHeader> purchaseReceiptRepo,
IRepository<Vendor> vendorRepo,
IRepository<Account> accountRepo,
IRepository<Item> itemRepo,
IRepository<Measurement> measurementRepo,
IRepository<SequenceNumber> sequenceNumberRepo,
IRepository<VendorPayment> vendorPaymentRepo,
IRepository<GeneralLedgerSetting> generalLedgerSettingRepo,
IRepository<PaymentTerm> paymentTermRepo,
IRepository<Bank> bankRepo
)
: base(sequenceNumberRepo, generalLedgerSettingRepo, paymentTermRepo, bankRepo)
{
_financialService = financialService;
_inventoryService = inventoryService;
_purchaseOrderRepo = purchaseOrderRepo;
_purchaseInvoiceRepo = purchaseInvoiceRepo;
_purchaseReceiptRepo = purchaseReceiptRepo;
_vendorRepo = vendorRepo;
_accountRepo = accountRepo;
_itemRepo = itemRepo;
_measurementRepo = measurementRepo;
_sequenceNumberRepo = sequenceNumberRepo;
_vendorPaymentRepo = vendorPaymentRepo;
_generalLedgerSettingRepo = generalLedgerSettingRepo;
_paymentTermRepo = paymentTermRepo;
_bankRepo = bankRepo;
}
示例10: InventoryModule
public InventoryModule(IRegionManager regionManager, ICacheService cacheService, IUserService userService, IInventoryService inventoryService,
WarehouseInventoryView resourceInventoryView, WarehouseInventoryViewModel resourceInventoryViewModel, ILogService logService)
: base(regionManager, AppScreens.InventoryView)
{
_regionManager = regionManager;
_cacheService = cacheService;
_userService = userService;
_inventoryService = inventoryService;
_warehouseInventoryView = resourceInventoryView;
_warehouseInventoryViewModel = resourceInventoryViewModel;
_logService = logService;
AddDashboardCommand<EntityCollectionViewModelBase<WarehouseTypeViewModel, WarehouseType>>(Resources.WarehouseType.ToPlural(), Resources.Inventory, 35);
AddDashboardCommand<EntityCollectionViewModelBase<WarehouseViewModel, Warehouse>>(Resources.Warehouse.ToPlural(), Resources.Inventory, 35);
AddDashboardCommand<EntityCollectionViewModelBase<TransactionTypeViewModel, InventoryTransactionType>>(Resources.TransactionType.ToPlural(), Resources.Inventory, 35);
AddDashboardCommand<EntityCollectionViewModelBase<TransactionDocumentTypeViewModel, InventoryTransactionDocumentType>>(Resources.DocumentType.ToPlural(), Resources.Inventory, 35);
AddDashboardCommand<TransactionDocumentListViewModel>(Resources.Transaction.ToPlural(), Resources.Inventory, 35);
AddDashboardCommand<EntityCollectionViewModelBase<InventoryItemViewModel, InventoryItem>>(Resources.InventoryItems, Resources.Inventory, 35);
AddDashboardCommand<RecipeListViewModel>(Resources.Recipes, Resources.Inventory, 35);
AddDashboardCommand<PeriodicConsumptionListViewModel>(Resources.EndOfDayRecords, Resources.Inventory, 36);
SetNavigationCommand(Resources.Warehouses, Resources.Common, "Images/box.png", 40);
EventServiceFactory.EventService.GetEvent<GenericEvent<Entity>>().Subscribe(OnResourceEvent);
EventServiceFactory.EventService.GetEvent<GenericEvent<Warehouse>>().Subscribe(OnWarehouseEvent);
PermissionRegistry.RegisterPermission(PermissionNames.OpenInventory, PermissionCategories.Navigation, string.Format(Resources.CanNavigate_f, Resources.Inventory));
}
示例11: InventoryServiceInConnector
public InventoryServiceInConnector(IConfigSource config, IHttpServer server, string configName) :
base(config, server, configName)
{
if (configName != string.Empty)
m_ConfigName = configName;
IConfig serverConfig = config.Configs[m_ConfigName];
if (serverConfig == null)
throw new Exception(String.Format("No section '{0}' in config file", m_ConfigName));
string inventoryService = serverConfig.GetString("LocalServiceModule",
String.Empty);
if (inventoryService == String.Empty)
throw new Exception("No LocalServiceModule in config file");
Object[] args = new Object[] { config };
m_InventoryService =
ServerUtils.LoadPlugin<IInventoryService>(inventoryService, args);
m_userserver_url = serverConfig.GetString("UserServerURI", String.Empty);
m_doLookup = serverConfig.GetBoolean("SessionAuthentication", false);
AddHttpHandlers(server);
m_log.Debug("[INVENTORY HANDLER]: handlers initialized");
}
示例12: BasicReportModule
public BasicReportModule(IRegionManager regionManager, BasicReportView basicReportView,
IWorkPeriodService workPeriodService, IPrinterService printerService,
IInventoryService inventoryService, IUserService userService,
IApplicationState applicationState, IAutomationService automationService, ILogService logService)
: base(regionManager, AppScreens.ReportView)
{
ReportContext.PrinterService = printerService;
ReportContext.WorkPeriodService = workPeriodService;
ReportContext.InventoryService = inventoryService;
ReportContext.UserService = userService;
ReportContext.ApplicationState = applicationState;
ReportContext.LogService = logService;
_userService = userService;
_regionManager = regionManager;
_basicReportView = basicReportView;
SetNavigationCommand(Resources.Reports, Resources.Common, "Images/Ppt.png", 60);
PermissionRegistry.RegisterPermission(PermissionNames.OpenReports, PermissionCategories.Navigation, Resources.CanDisplayReports);
PermissionRegistry.RegisterPermission(PermissionNames.ChangeReportDate, PermissionCategories.Report, Resources.CanChangeReportFilter);
automationService.RegisterActionType("SaveReportToFile", Resources.SaveReportToFile, new { ReportName = "", FileName = "" });
automationService.RegisterActionType(ActionNames.PrintReport, Resources.PrintReport, new { ReportName = "" });
automationService.RegisterParameterSoruce("ReportName", () => ReportContext.Reports.Select(x => x.Header));
EventServiceFactory.EventService.GetEvent<GenericEvent<IActionData>>().Subscribe(x =>
{
if (x.Value.Action.ActionType == "SaveReportToFile")
{
var reportName = x.Value.GetAsString("ReportName");
var fileName = x.Value.GetAsString("FileName");
if (!string.IsNullOrEmpty(reportName))
{
var report = ReportContext.Reports.FirstOrDefault(y => y.Header == reportName);
if (report != null)
{
ReportContext.CurrentWorkPeriod = ReportContext.ApplicationState.CurrentWorkPeriod;
var document = report.GetReportDocument();
ReportViewModelBase.SaveAsXps(fileName, document);
}
}
}
if (x.Value.Action.ActionType == ActionNames.PrintReport)
{
var reportName = x.Value.GetAsString("ReportName");
if (!string.IsNullOrEmpty(reportName))
{
var report = ReportContext.Reports.FirstOrDefault(y => y.Header == reportName);
if (report != null)
{
ReportContext.CurrentWorkPeriod = ReportContext.ApplicationState.CurrentWorkPeriod;
var document = report.GetReportDocument();
ReportContext.PrinterService.PrintReport(document, ReportContext.ApplicationState.CurrentTerminal.ReportPrinter);
}
}
}
});
}
示例13: WarehouseInventoryViewModel
public WarehouseInventoryViewModel(IInventoryService inventoryService, ICacheService cacheService, IApplicationState applicationState)
{
_inventoryService = inventoryService;
_cacheService = cacheService;
_applicationState = applicationState;
WarehouseButtonSelectedCommand = new CaptionCommand<Warehouse>("", OnWarehouseSelected);
}
示例14: Setup
public void Setup()
{
MefBootstrapper.ComposeParts();
WorkPeriodService = MefBootstrapper.Resolve<IWorkPeriodService>();
InventoryService = MefBootstrapper.Resolve<IInventoryService>();
ApplicationState = MefBootstrapper.Resolve<IApplicationState>();
}
示例15: ReportsController
public ReportsController(ISalesService salesService,
IInventoryService inventoryService,
IFinancialService financialService)
{
_salesService = salesService;
_inventoryService = inventoryService;
_financialService = financialService;
}