Exemplo n.º 1
0
        public OrderSystemServiceProxy()
        {
            var baseUrl        = ConfigurationManager.AppSettings["BaseServiceUrl"];
            var channelFactory = new ChannelFactory <IOrderSystemService>(
                new WebHttpBinding(WebHttpSecurityMode.None),
                new EndpointAddress(baseUrl));

            channelFactory.Endpoint.EndpointBehaviors.Add(new WebHttpBehavior());
            this.orderSystemService = channelFactory.CreateChannel();
        }
Exemplo n.º 2
0
        public OrderSystemDashboardViewModel(IOrderSystemService orderSystemService, IApplicationService applicationService, IUserInteractionService userInteractionService)
        {
            this.orderSystemService     = orderSystemService;
            this.applicationService     = applicationService;
            this.userInteractionService = userInteractionService;

            this.Serach = new DelegateCommand <string>(InitializeSearch);
            this.Reset  = new DelegateCommand(InitializeReset);
            this.Close  = new DelegateCommand <string>(InitializeClose);

            if (this.applicationService != default(IApplicationService))
            {
                this.UserName = this.applicationService.UserName;
            }
        }