public ActionResult UpdateLienItemTable(IEnumerable <LienTempTable> objLienTempTable) { try { var validate = _lienTempTable.UpdateLienTempClaimNumber(Mapper.Map <IEnumerable <LMGEDI.Core.Data.Model.LienTempTable> >(objLienTempTable)); if (validate.ErrorNumberLoop == null) { return(Json(GlobalConst.CommonValues.Complete)); } else if (validate.ErrorNumberLoop == 0) { return(Json(GlobalConst.CommonValues.CompleteUpdateOnly)); } else { string Message = validate.ErrorMessage; string StackTrace = "Error Occur at UploadedID = " + validate.ErrorNumberLoop + Environment.NewLine; StackTrace += "Error Occur at Stored Procedure [" + validate.ErrorProcedure + "] Line = " + validate.ErrorLine; _arCommonService.CreateErrorLog(Message, StackTrace); return(Json(GlobalConst.ObjectTypes.Error)); } } catch (Exception ex) { _arCommonService.CreateErrorLog(ex.Message, ex.StackTrace); return(Json(GlobalConst.ObjectTypes.Error)); } }
public void UpdateLienTempTable() { List <LMGEDI.Core.Data.Model.LienTempTable> s = new List <LMGEDI.Core.Data.Model.LienTempTable>(); LienTempTable b1 = new LienTempTable { UploadId = 31, Claim = "45286" }; LienTempTable b2 = new LienTempTable { UploadId = 32, Claim = "4563" }; LienTempTable b3 = new LienTempTable { UploadId = 33, Claim = "458" }; LienTempTable b4 = new LienTempTable { UploadId = 34, Claim = "456" }; LienTempTable b5 = new LienTempTable { UploadId = 35, Claim = "125" }; s.Add(b1); s.Add(b2); s.Add(b3); s.Add(b4); s.Add(b5); var result = _ILienTempBL.UpdateLienTempClaimNumber(s); Assert.IsTrue(true, "Unable to find"); }