示例#1
0
 public async Task <IActionResult> GetFoodDataById(long id)
 {
     try
     {
         return(Ok(new { data = await _foodDataBL.GetFoodDataByID(id) }));
     }
     catch (Exception e)
     {
         return(BadRequest(new { message = MessageConstant.UNHANDLE_ERROR, error = e.StackTrace }));
     }
 }
示例#2
0
 public async Task <Models.FoodData.FoodData> GetFoodDetail(long foodId)
 {
     return(await _foodDataBL.GetFoodDataByID(foodId));
 }
示例#3
0
 public async Task <FoodData> GetFoodDataById(long id)
 {
     return(await _foodDataBL.GetFoodDataByID(id));
 }