Example #1
0
        public async Task <IActionResult> Get(string key)
        {
            if (!await _permissionService.Authorize(PermissionSystemName.Vendors))
            {
                return(Forbid());
            }

            var vendor = await _customerApiService.GetVendorById(key);

            if (vendor == null)
            {
                return(NotFound());
            }

            return(Ok(vendor));
        }