Пример #1
0
 public static ObjectResult ReturnError(string exceptionMessage, string message = "")
 {
     dataResult dr = new dataResult { success = false, data = null, exceptionMessage = exceptionMessage, message = message };
     return new ObjectResult(dr);
 }
Пример #2
0
 public static ObjectResult ReturnSuccess(object data, string message = "")
 {
     dataResult dr = new dataResult { success = true, data = data, message = message };
     return new ObjectResult(dr);
 }