B2017-130 after interrupting the update ROs, PROMS thought that the RO.FST was older than that in the database. That logic is no longer needed with the new Update RO Values design.

This commit is contained in:
John Jenko 2017-06-27 17:51:50 +00:00
parent c7a520b4d1
commit 559c01f22a
2 changed files with 28 additions and 26 deletions

View File

@ -1101,19 +1101,20 @@ namespace VEPROMS
MessageBox.Show("No existing ro.fst in path " + rdi.FolderPath + ". Check for invalid path", "No existing RO.FST"); //B2017-125 added title to messagebox MessageBox.Show("No existing ro.fst in path " + rdi.FolderPath + ". Check for invalid path", "No existing RO.FST"); //B2017-125 added title to messagebox
break; break;
} }
FileInfo fiRofst = new FileInfo(rofstPath); // B2017-130 code no longer needed. Was checking the DTS but always was different by miliseconds
if (SelectedROFst.DTS == fiRofst.LastWriteTimeUtc) //FileInfo fiRofst = new FileInfo(rofstPath);
{ //if (SelectedROFst.DTS == fiRofst.LastWriteTimeUtc)
FinalProgressBarMessage = "RO.FST up to date"; //{
MessageBox.Show("ro.fst files are same for path " + rdi.FolderPath + ", import of that ro.fst will not be done", "RO.FST up to date"); //B2017-125 added title to messagebox // FinalProgressBarMessage = "RO.FST up to date";
break; // MessageBox.Show("ro.fst files are same for path " + rdi.FolderPath + ", import of that ro.fst will not be done", "RO.FST up to date"); //B2017-125 added title to messagebox
} // break;
if (SelectedROFst.DTS > fiRofst.LastWriteTimeUtc) //}
{ //if (SelectedROFst.DTS > fiRofst.LastWriteTimeUtc)
FinalProgressBarMessage = "RO.FST is older"; //{
MessageBox.Show("Cannot copy older ro.fst from " + rdi.FolderPath + ", import of that ro.fst will not be done", "RO.FST is older"); //B2017-125 added title to messagebox // FinalProgressBarMessage = "RO.FST is older";
break; // MessageBox.Show("Cannot copy older ro.fst from " + rdi.FolderPath + ", import of that ro.fst will not be done", "RO.FST is older"); //B2017-125 added title to messagebox
} // break;
//}
Cursor = Cursors.WaitCursor; Cursor = Cursors.WaitCursor;
swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(_DocVersionConfig.MyDocVersion.MyDocVersionInfo)); // RO changes placed in file in the Documents\VEPROMS folder swROUpdate = new System.IO.StreamWriter(ROFstInfo.ROUpdateResultsPath(_DocVersionConfig.MyDocVersion.MyDocVersionInfo)); // RO changes placed in file in the Documents\VEPROMS folder
ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file ContentInfo.StaticContentInfoChange += ContentInfo_StaticContentInfoChange; // write changes to a text file

View File

@ -2927,19 +2927,20 @@ namespace Volian.Controls.Library
MessageBox.Show("No existing ro.fst in path " + roFstInfo.MyRODb.FolderPath + ". Check for invalid path", "No existing RO.FST"); //B2017-125 added title to messagebox MessageBox.Show("No existing ro.fst in path " + roFstInfo.MyRODb.FolderPath + ". Check for invalid path", "No existing RO.FST"); //B2017-125 added title to messagebox
return; return;
} }
FileInfo fiRofst = new FileInfo(rofstPath); // B2017-130 code no longer needed. Was checking the DTS but always was different by miliseconds
if (roFstInfo.DTS == fiRofst.LastWriteTimeUtc) //FileInfo fiRofst = new FileInfo(rofstPath);
{ //if (roFstInfo.DTS == fiRofst.LastWriteTimeUtc)
FinalProgressBarMessage = "RO.FST up to date"; //{
MessageBox.Show("ro.fst files are same for path " + roFstInfo.MyRODb.FolderPath + ", import of that ro.fst will not be done", "RO.FST up to date"); //B2017-125 added title to messagebox // FinalProgressBarMessage = "RO.FST up to date";
return; // MessageBox.Show("ro.fst files are same for path " + roFstInfo.MyRODb.FolderPath + ", import of that ro.fst will not be done", "RO.FST up to date"); //B2017-125 added title to messagebox
} // return;
if (roFstInfo.DTS > fiRofst.LastWriteTimeUtc) //}
{ //if (roFstInfo.DTS > fiRofst.LastWriteTimeUtc)
FinalProgressBarMessage = "RO.FST is older"; //{
MessageBox.Show("Cannot copy older ro.fst from " + roFstInfo.MyRODb.FolderPath + ", import of that ro.fst will not be done", "RO.FST is older"); //B2017-125 added title to messagebox // FinalProgressBarMessage = "RO.FST is older";
return; // MessageBox.Show("Cannot copy older ro.fst from " + roFstInfo.MyRODb.FolderPath + ", import of that ro.fst will not be done", "RO.FST is older"); //B2017-125 added title to messagebox
} // return;
//}
Cursor = Cursors.WaitCursor; Cursor = Cursors.WaitCursor;
using (DocVersion dv = DocVersion.Get(Mydvi.VersionID)) using (DocVersion dv = DocVersion.Get(Mydvi.VersionID))