Exemple #1
0
        public async Task <Test> AssignDeterminationsAsync(AssignDeterminationRequestArgs request)
        {
            var data = await DbContext.ExecuteReaderAsync(DataConstants.PR_SAVE_TEST_MATERIAL_DETERMINATION, CommandType.StoredProcedure, args =>
            {
                //args.Add("@UserID", userContext.GetContext().FullName);
                args.Add("@TestTypeID", request.TestTypeID);
                args.Add("@TestID", request.TestID);
                args.Add("@Columns", request.ToColumnsString());
                args.Add("@Filter", request.ToFilterString());
                args.Add("@TVPM", request.ToTVPTestMaterialDetermation());
                args.Add("@Determinations", request.ToTVPDeterminations());
            },
                                                          reader => new Test
            {
                TestID     = reader.Get <int>(0),
                StatusCode = reader.Get <int>(1)
            });

            return(data.FirstOrDefault());
            //return true;
        }
Exemple #2
0
        public async Task <IHttpActionResult> AssignDeterminations([FromBody] AssignDeterminationRequestArgs args)
        {
            var success = await determinationService.AssignDeterminationsAsync(args);

            return(Ok(success));
        }
Exemple #3
0
 public async Task <Test> AssignDeterminationsAsync(AssignDeterminationRequestArgs request)
 {
     return(await repository.AssignDeterminationsAsync(request));
 }