Пример #1
0
 public static ObjectResult ADSBadRequest(this ControllerBase services, string message, object data, int code)
 {
     try
     {
         return(services.BadRequest(new ResultModel
         {
             Error = code,
             Msg = message,
             Data = data
         }));
     }
     catch (Exception e)
     {
         return(services.ADSInternalError(e.Message));
     }
 }
Пример #2
0
 public static ObjectResult ADSInternalError(this ControllerBase services, string message, object data)
 {
     return(services.ADSInternalError(message, data, 500));
 }
Пример #3
0
 public static ObjectResult ADSInternalError(this ControllerBase services, string message, int code)
 {
     return(services.ADSInternalError(message, null, code));
 }
Пример #4
0
 public static ObjectResult ADSInternalError(this ControllerBase services)
 {
     return(services.ADSInternalError(ResponseMessages.INTERNAL_ERROR));
 }