Beispiel #1
0
        public async Task <IActionResult> GetAnyBranchAsync([FromQuery] BranchMinRequestModel requestModel, [FromRoute] string token)
        {
            if (token != Consts.StaticToken)
            {
                return(new ContentResult {
                    StatusCode = 403
                });
            }

            try
            {
                var branchMinModel = await _branchManager.GetAnyBranchAsync(requestModel);

                return(Ok(branchMinModel));
            }
            catch (KeyNotFoundException ex)
            {
                return(NotFound(ex.Message));
            }
        }