Updated Generated Code to Use IDs rather than Objects for internal Updates

This commit is contained in:
Rich
2010-12-13 15:47:02 +00:00
parent c8d47d9c64
commit db051f8ff8
50 changed files with 112 additions and 112 deletions

View File

@@ -943,12 +943,12 @@ namespace VEPROMS.CSLA.Library
if (IsNew)
_LastChanged = Figure.Add(cn, ref _FigureID, _MyROFst, _MyROImage, _Config, _DTS, _UserID);
else
_LastChanged = Figure.Update(cn, ref _FigureID, _MyROFst, _MyROImage, _Config, _DTS, _UserID, ref _LastChanged);
_LastChanged = Figure.Update(cn, ref _FigureID, _ROFstID, _ImageID, _Config, _DTS, _UserID, ref _LastChanged);
MarkOld();
}
}
[Transactional(TransactionalTypes.TransactionScope)]
public static byte[] Update(SqlConnection cn, ref int figureID, ROFst myROFst, ROImage myROImage, string config, DateTime dts, string userID, ref byte[] lastChanged)
public static byte[] Update(SqlConnection cn, ref int figureID, int rOFstID, int imageID, string config, DateTime dts, string userID, ref byte[] lastChanged)
{
if (_MyLog.IsDebugEnabled) _MyLog.DebugFormat("[{0}] Figure.Update", 0);
try
@@ -959,8 +959,8 @@ namespace VEPROMS.CSLA.Library
cm.CommandText = "updateFigure";
// Input All Fields - Except Calculated Columns
cm.Parameters.AddWithValue("@FigureID", figureID);
cm.Parameters.AddWithValue("@ROFstID", myROFst.ROFstID);
cm.Parameters.AddWithValue("@ImageID", myROImage.ImageID);
cm.Parameters.AddWithValue("@ROFstID", rOFstID);
cm.Parameters.AddWithValue("@ImageID", imageID);
cm.Parameters.AddWithValue("@Config", config);
if (dts.Year >= 1753 && dts.Year <= 9999) cm.Parameters.AddWithValue("@DTS", dts);
cm.Parameters.AddWithValue("@UserID", userID);