Esempio n. 1
0
 public async Task <int> AddSubcategory(SubCategoryBodyModel subCategoryBodyModel)
 {
     try
     {
         return(await _connection.GetConnection.ExecuteAsync(
                    sql : @"[Menu].[Usp_InsertSucategory]",
                    param : subCategoryBodyModel,
                    commandType : CommandType.StoredProcedure
                    ));
     }
     catch (Exception exception)
     {
         throw exception;
     }
     finally
     {
         _connection.Dispose();
     }
 }
Esempio n. 2
0
 public async Task <int> AddSubcategory(SubCategoryBodyModel subCategoryBodyModel)
 {
     return(await _menuItemReporitory.AddSubcategory(subCategoryBodyModel));
 }
 public async Task <IHttpActionResult> AddSubCategory([FromBody] SubCategoryBodyModel subCategoryBodyModel)
 {
     return(Ok(await _menuItemService.AddSubcategory(subCategoryBodyModel)));
 }