B2012-315 – fixed problem approving a new procedure
added a null reference check
This commit is contained in:
parent
6b959e09cb
commit
61fcf17624
@ -641,7 +641,11 @@ namespace VEPROMS
|
||||
RevNumber = proc.ProcedureConfig.Print_Rev == string.Empty ? "0" : proc.ProcedureConfig.Print_Rev;
|
||||
//AppRevDate Change
|
||||
//DateTime revdate;
|
||||
RevDate = DateTime.Parse(proc.ProcedureConfig.Print_RevDate);
|
||||
string sRevDate = proc.ProcedureConfig.Print_RevDate;
|
||||
if (sRevDate == string.Empty)
|
||||
sRevDate = DateTime.Now.ToString("M/d/y");
|
||||
RevDate = DateTime.Parse(sRevDate);
|
||||
//RevDate = DateTime.Parse(proc.ProcedureConfig.Print_RevDate);
|
||||
//if (print_revdate == string.Empty && DateTime.TryParse(RevNumber, out revdate))
|
||||
// ;
|
||||
//else
|
||||
|
@ -658,7 +658,7 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.RevisionVersions.Count == 0) return null;
|
||||
if (this.RevisionVersions == null || this.RevisionVersions.Count == 0) return null;
|
||||
VersionInfo latest = this.RevisionVersions[0];
|
||||
foreach (VersionInfo vi in this.RevisionVersions)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user