This commit is contained in:
parent
9456cc7214
commit
0f98b74c9a
@ -327,7 +327,7 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
return sb.ToString();
|
||||
}
|
||||
private static void UpdateROValuesText(ROFstInfo origROFstInfo, ROFst newROFst)
|
||||
private static void UpdateROValuesText(ROFstInfo origROFstInfo, ROFst newROFst)
|
||||
{
|
||||
ROFSTLookup origLU = new ROFSTLookup(origROFstInfo);
|
||||
ROFSTLookup newLU = new ROFSTLookup(newROFst);
|
||||
@ -350,13 +350,17 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
using (Content content = Content.Get(roUsg.MyContent.ContentID))
|
||||
{
|
||||
content.FixContentText(roUsg, roch, origROFstInfo);
|
||||
if (content.IsDirty)
|
||||
foreach (ItemInfo ii in roUsg.MyContent.ContentItems)
|
||||
{
|
||||
// Update UserID and DTS when RO Value is updated.
|
||||
content.UserID = Volian.Base.Library.VlnSettings.UserID;
|
||||
content.DTS = DateTime.Now;
|
||||
content.Save();
|
||||
string val = newLU.GetTranslatedRoValue(padroid, ii.ActiveFormat.PlantFormat.FormatData.SectData.ConvertCaretToDelta);
|
||||
content.FixContentText(roUsg, val, roch.type, origROFstInfo);
|
||||
if (content.IsDirty)
|
||||
{
|
||||
// Update UserID and DTS when RO Value is updated.
|
||||
content.UserID = Volian.Base.Library.VlnSettings.UserID;
|
||||
content.DTS = DateTime.Now;
|
||||
content.Save();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -386,8 +390,30 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
string desc = string.Format("Deleted RO: Value = {0}", origLU.GetRoValue(del));
|
||||
string padroiddel = del.Length <= 12 ? del + "0000" : del;
|
||||
using (RoUsageInfoList affected = RoUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, padroiddel, desc, "Deleted")) ;
|
||||
using (DROUsageInfoList Daffected = DROUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, padroiddel, desc, "Deleted")) ;
|
||||
using (RoUsageInfoList affected = RoUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, padroiddel, desc, "Deleted"))
|
||||
{
|
||||
foreach (RoUsageInfo roUsg in affected)
|
||||
{
|
||||
using (Content content = Content.Get(roUsg.MyContent.ContentID))
|
||||
{
|
||||
content.FixContentText(roUsg, "?", 0, origROFstInfo);
|
||||
if (content.IsDirty)
|
||||
{
|
||||
// Update UserID and DTS when RO Value is updated.
|
||||
content.UserID = Volian.Base.Library.VlnSettings.UserID;
|
||||
content.DTS = DateTime.Now;
|
||||
content.Save();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
using (DROUsageInfoList Daffected = DROUsageInfoList.GetAffected(origROFstInfo.MyRODb.RODbID, del.Substring(0,12), desc, "Deleted"))
|
||||
{
|
||||
foreach (DROUsageInfo droUsg in Daffected)
|
||||
{
|
||||
Pdf.DeleteAll(droUsg.DocID);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
private static List<string> BuildActiveROIDsForRoUsages(string RoidList)
|
||||
|
Loading…
x
Reference in New Issue
Block a user