C2019-036 View Only mode work with Checked Out Procedures
This commit is contained in:
@@ -7984,12 +7984,20 @@ namespace VEPROMS.CSLA.Library
|
||||
public ProcedureInfo(SafeDataReader dr) : base(dr) { }
|
||||
#endif
|
||||
private ProcedureInfo() : base() { ;}
|
||||
public new static ProcedureInfo Get(int itemID)
|
||||
public new static ProcedureInfo Get(int itemID, bool forcerefresh = false)
|
||||
{
|
||||
//if (!CanGetObject())
|
||||
// throw new System.Security.SecurityException("User not authorized to view a Item");
|
||||
try
|
||||
{
|
||||
//C2019-036 View Only mode work with Checked Out Procedures
|
||||
// fixes caching issue
|
||||
// so this forces a refresh of the cache
|
||||
if (forcerefresh)
|
||||
{
|
||||
_CacheByPrimaryKey.Remove(itemID.ToString());
|
||||
}
|
||||
|
||||
ProcedureInfo tmp = GetCachedByPrimaryKey(itemID);
|
||||
if (tmp == null)
|
||||
{
|
||||
|
||||
@@ -186,7 +186,7 @@ namespace VEPROMS.CSLA.Library
|
||||
if (string.IsNullOrEmpty(name))
|
||||
{ name = tmpproc.DisplayText; }
|
||||
|
||||
message = string.Format("The procedure {0} is already checked out to {1}", name, si.UserID);
|
||||
message = string.Format("The procedure {0} is already checked out to {1}.\r\nWould You like to open the procedure in View Only Mode?", name, si.UserID);
|
||||
rv = rv && false;
|
||||
}
|
||||
else if (si.ProcessID != this.ProcessID && objectType == CheckOutType.Document)
|
||||
|
||||
Reference in New Issue
Block a user