public MachinesController(MachineServiceClient client, IAuthorizationService authService, IHttpContextAccessor httpContextAccessor, IMapper mapper)
        {
            _client      = client;
            _mapper      = mapper;
            _authService = authService;
            // in case we need the user here we can retrieve the claimsprincipal
            var user = httpContextAccessor.HttpContext.User.FindFirst(ClaimTypes.NameIdentifier);

            Debug.WriteLine(user, "** USER");
        }
Example #2
0
        public MainForm()
        {
            InitializeComponent();

            this.serviceClient = new MachineServiceClient();

            var boissons = this.serviceClient.GetListBoisson();

            this.comboBoxTypeBoisson.Items.AddRange(boissons);
        }