Exemple #1
0
 // GET: api/Country/
 public dynamic Get(string code)
 {
     try
     {
         return(DiscountLoadingMdl.get_discountloading(code));
     }
     catch (Exception e)
     {
         return(new { state = false, message = "Server Error", exception = e });
     }
 }
Exemple #2
0
 public object Check(string code)
 {
     try
     {
         var result = DiscountLoadingMdl.get_discountloading(code);
         return(result != null ? (object)new { state = true, name = result.LDI_NAME } : new { state = false });
     }
     catch (Exception e)
     {
         return(new { state = false, message = "Server Error", exception = e });
     }
 }