|
|
@ -21,7 +21,6 @@ namespace CK.SCP.Controller |
|
|
|
|
|
|
|
public static void Get_V_TB_ASK_List(V_TB_ASK p_entity, Action<ResultObject<IQueryable<V_TB_ASK>>> p_action) |
|
|
|
{ |
|
|
|
|
|
|
|
ResultObject<IQueryable<V_TB_ASK>> _ret = new ResultObject<IQueryable<V_TB_ASK>>(); |
|
|
|
try |
|
|
|
{ |
|
|
@ -121,6 +120,8 @@ namespace CK.SCP.Controller |
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(dbEx); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List", sb.ToString()); |
|
|
|
if (dbEx.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List(DbEntityValidationException)", LogHelper.GetExceptionMessage(dbEx).Message); |
|
|
|
throw new ScpException(ResultCode.DbEntityValidationException, sb.ToString(), "字段验证失败" + sb.ToString()); |
|
|
|
} |
|
|
|
catch (OptimisticConcurrencyException ex)//并发冲突异常
|
|
|
@ -130,9 +131,8 @@ namespace CK.SCP.Controller |
|
|
|
_ret.ErrorList.Add(ex); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List", ex.Message.ToString()); |
|
|
|
if (ex.InnerException != null) |
|
|
|
{ |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List(*)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
} |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List(OptimisticConcurrencyException)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
|
|
|
|
throw new ScpException(ResultCode.Exception, "9999", ex.ToString()); |
|
|
|
} |
|
|
|
catch (ScpException ex) |
|
|
@ -140,20 +140,19 @@ namespace CK.SCP.Controller |
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(ex); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List", ex.Message.ToString()); |
|
|
|
if (ex.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List(ScpException)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
|
|
|
|
if (ex.InnerException != null && ex.InnerException.GetType() == typeof(UpdateException)) |
|
|
|
{ |
|
|
|
var inner = (UpdateException)ex.InnerException; |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List", inner.Message.ToString()); |
|
|
|
|
|
|
|
|
|
|
|
throw new ScpException(ResultCode.Exception, "0000", ex.ToString()); |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
if (ex.InnerException != null) { |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List", ex.InnerException.Message); |
|
|
|
|
|
|
|
throw ex.InnerException; |
|
|
|
} |
|
|
|
} |
|
|
@ -163,6 +162,9 @@ namespace CK.SCP.Controller |
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(e); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List", e.Message); |
|
|
|
if (e.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_List(Exception)", LogHelper.GetExceptionMessage(e).Message); |
|
|
|
|
|
|
|
throw e; |
|
|
|
} |
|
|
|
} |
|
|
@ -468,6 +470,9 @@ namespace CK.SCP.Controller |
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(dbEx); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_ASN_View_List", sb.ToString()); |
|
|
|
if (dbEx.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASN_CONTROLLER), "Get_V_TB_ASK_ASN_View_List(DbEntityValidationException)", LogHelper.GetExceptionMessage(dbEx).Message); |
|
|
|
|
|
|
|
throw new ScpException(ResultCode.DbEntityValidationException, sb.ToString(), "字段验证失败" + sb.ToString()); |
|
|
|
} |
|
|
|
catch (OptimisticConcurrencyException ex)//并发冲突异常
|
|
|
@ -477,9 +482,8 @@ namespace CK.SCP.Controller |
|
|
|
_ret.ErrorList.Add(ex); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_ASN_View_List", ex.ToString()); |
|
|
|
if (ex.InnerException != null) |
|
|
|
{ |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASN_CONTROLLER), "Get_V_TB_ASK_ASN_View_List(*)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
} |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASN_CONTROLLER), "Get_V_TB_ASK_ASN_View_List(OptimisticConcurrencyException)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
|
|
|
|
throw new ScpException(ResultCode.Exception, "9999", ex.ToString()); |
|
|
|
} |
|
|
|
catch (ScpException ex) |
|
|
@ -487,6 +491,8 @@ namespace CK.SCP.Controller |
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(ex); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_ASN_View_List", ex.ToString()); |
|
|
|
if (ex.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASN_CONTROLLER), "Get_V_TB_ASK_ASN_View_List(ScpException)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
|
|
|
|
if (ex.InnerException != null && ex.InnerException.GetType() == typeof(UpdateException)) |
|
|
|
{ |
|
|
@ -505,6 +511,9 @@ namespace CK.SCP.Controller |
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(e); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_ASN_View_List", e.Message); |
|
|
|
if (e.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASN_CONTROLLER), "Get_V_TB_ASK_ASN_View_List(ScpException)", LogHelper.GetExceptionMessage(e).Message); |
|
|
|
|
|
|
|
throw e; |
|
|
|
} |
|
|
|
|
|
|
@ -1643,36 +1652,33 @@ namespace CK.SCP.Controller |
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(dbEx); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List", sb.ToString()); |
|
|
|
|
|
|
|
if (dbEx.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_TB_PRICE_CONTROLLER), "Get_V_TB_ASK_DETAIL_List(DbEntityValidationException)", LogHelper.GetExceptionMessage(dbEx).Message); |
|
|
|
|
|
|
|
throw new ScpException(ResultCode.DbEntityValidationException, sb.ToString(), "字段验证失败" + sb.ToString()); |
|
|
|
} |
|
|
|
catch (OptimisticConcurrencyException ex)//并发冲突异常
|
|
|
|
{ |
|
|
|
|
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(ex); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List", ex.ToString()); |
|
|
|
|
|
|
|
if (ex.InnerException != null) |
|
|
|
{ |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List(*)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
} |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List(OptimisticConcurrencyException)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
|
|
|
|
throw new ScpException(ResultCode.Exception, "9999", ex.ToString()); |
|
|
|
} |
|
|
|
catch (ScpException ex) |
|
|
|
{ |
|
|
|
|
|
|
|
|
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(ex); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List", ex.ToString()); |
|
|
|
if (ex.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List(ScpException)", LogHelper.GetExceptionMessage(ex).Message); |
|
|
|
|
|
|
|
if (ex.InnerException != null && ex.InnerException.GetType() == typeof(UpdateException)) |
|
|
|
{ |
|
|
|
var inner = (UpdateException)ex.InnerException; |
|
|
|
|
|
|
|
|
|
|
|
throw new ScpException(ResultCode.Exception, "0000", ex.ToString()); |
|
|
|
} |
|
|
|
else |
|
|
@ -1682,11 +1688,12 @@ namespace CK.SCP.Controller |
|
|
|
} |
|
|
|
catch (Exception e) |
|
|
|
{ |
|
|
|
|
|
|
|
|
|
|
|
_ret.State = ReturnStatus.Failed; |
|
|
|
_ret.ErrorList.Add(e); |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List", e.Message); |
|
|
|
if (e.InnerException != null) |
|
|
|
LogHelper.Writlog(LogHelper.LogType.Error, typeof(SCP_ASK_CONTROLLER), "Get_V_TB_ASK_DETAIL_List(Exception)", LogHelper.GetExceptionMessage(e).Message); |
|
|
|
|
|
|
|
throw e; |
|
|
|
} |
|
|
|
} |
|
|
|