This commit is contained in:
@@ -42,7 +42,7 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("AnnotationID",true);
|
||||
CanReadProperty("AnnotationID", true);
|
||||
if (_MyAnnotation != null) _AnnotationID = _MyAnnotation.AnnotationID;
|
||||
return _AnnotationID;
|
||||
}
|
||||
@@ -54,7 +54,7 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("MyAnnotation",true);
|
||||
CanReadProperty("MyAnnotation", true);
|
||||
if (_MyAnnotation == null && _AnnotationID != 0) _MyAnnotation = Annotation.Get(_AnnotationID);
|
||||
return _MyAnnotation;
|
||||
}
|
||||
@@ -65,7 +65,7 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("TypeID",true);
|
||||
CanReadProperty("TypeID", true);
|
||||
if (_MyAnnotationType != null) _TypeID = _MyAnnotationType.TypeID;
|
||||
return _TypeID;
|
||||
}
|
||||
@@ -76,14 +76,14 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("MyAnnotationType",true);
|
||||
CanReadProperty("MyAnnotationType", true);
|
||||
if (_MyAnnotationType == null && _TypeID != 0) _MyAnnotationType = AnnotationType.Get(_TypeID);
|
||||
return _MyAnnotationType;
|
||||
}
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
set
|
||||
{
|
||||
CanWriteProperty("MyAnnotationType",true);
|
||||
CanWriteProperty("MyAnnotationType", true);
|
||||
if (_MyAnnotationType != value)
|
||||
{
|
||||
_MyAnnotationType = value;
|
||||
@@ -97,13 +97,13 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("RtfText",true);
|
||||
CanReadProperty("RtfText", true);
|
||||
return _RtfText;
|
||||
}
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
set
|
||||
{
|
||||
CanWriteProperty("RtfText",true);
|
||||
CanWriteProperty("RtfText", true);
|
||||
if (value == null) value = string.Empty;
|
||||
if (_RtfText != value)
|
||||
{
|
||||
@@ -118,13 +118,13 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("SearchText",true);
|
||||
CanReadProperty("SearchText", true);
|
||||
return _SearchText;
|
||||
}
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
set
|
||||
{
|
||||
CanWriteProperty("SearchText",true);
|
||||
CanWriteProperty("SearchText", true);
|
||||
if (value == null) value = string.Empty;
|
||||
if (_SearchText != value)
|
||||
{
|
||||
@@ -139,13 +139,13 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("Config",true);
|
||||
CanReadProperty("Config", true);
|
||||
return _Config;
|
||||
}
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
set
|
||||
{
|
||||
CanWriteProperty("Config",true);
|
||||
CanWriteProperty("Config", true);
|
||||
if (value == null) value = string.Empty;
|
||||
if (_Config != value)
|
||||
{
|
||||
@@ -160,13 +160,13 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("DTS",true);
|
||||
CanReadProperty("DTS", true);
|
||||
return _DTS;
|
||||
}
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
set
|
||||
{
|
||||
CanWriteProperty("DTS",true);
|
||||
CanWriteProperty("DTS", true);
|
||||
if (_DTS != value)
|
||||
{
|
||||
_DTS = value;
|
||||
@@ -180,13 +180,13 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("UserID",true);
|
||||
CanReadProperty("UserID", true);
|
||||
return _UserID;
|
||||
}
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
set
|
||||
{
|
||||
CanWriteProperty("UserID",true);
|
||||
CanWriteProperty("UserID", true);
|
||||
if (value == null) value = string.Empty;
|
||||
if (_UserID != value)
|
||||
{
|
||||
@@ -202,7 +202,7 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("AnnotationType_Name",true);
|
||||
CanReadProperty("AnnotationType_Name", true);
|
||||
return _AnnotationType_Name;
|
||||
}
|
||||
}
|
||||
@@ -212,7 +212,7 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("AnnotationType_Config",true);
|
||||
CanReadProperty("AnnotationType_Config", true);
|
||||
return _AnnotationType_Config;
|
||||
}
|
||||
}
|
||||
@@ -222,7 +222,7 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("AnnotationType_DTS",true);
|
||||
CanReadProperty("AnnotationType_DTS", true);
|
||||
return _AnnotationType_DTS;
|
||||
}
|
||||
}
|
||||
@@ -232,7 +232,7 @@ namespace VEPROMS.CSLA.Library
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get
|
||||
{
|
||||
CanReadProperty("AnnotationType_UserID",true);
|
||||
CanReadProperty("AnnotationType_UserID", true);
|
||||
return _AnnotationType_UserID;
|
||||
}
|
||||
}
|
||||
@@ -265,23 +265,23 @@ namespace VEPROMS.CSLA.Library
|
||||
#endregion
|
||||
#region ValidationRules
|
||||
[NonSerialized]
|
||||
private bool _CheckingBrokenRules=false;
|
||||
private bool _CheckingBrokenRules = false;
|
||||
public IVEHasBrokenRules HasBrokenRules
|
||||
{
|
||||
get
|
||||
{
|
||||
if(_CheckingBrokenRules)return null;
|
||||
if (_CheckingBrokenRules) return null;
|
||||
if (BrokenRulesCollection.Count > 0) return this;
|
||||
try
|
||||
{
|
||||
_CheckingBrokenRules=true;
|
||||
IVEHasBrokenRules hasBrokenRules = null;
|
||||
if (_MyAnnotationType != null && (hasBrokenRules = _MyAnnotationType.HasBrokenRules) != null) return hasBrokenRules;
|
||||
return hasBrokenRules;
|
||||
_CheckingBrokenRules = true;
|
||||
IVEHasBrokenRules hasBrokenRules = null;
|
||||
if (_MyAnnotationType != null && (hasBrokenRules = _MyAnnotationType.HasBrokenRules) != null) return hasBrokenRules;
|
||||
return hasBrokenRules;
|
||||
}
|
||||
finally
|
||||
{
|
||||
_CheckingBrokenRules=false;
|
||||
_CheckingBrokenRules = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -404,7 +404,7 @@ namespace VEPROMS.CSLA.Library
|
||||
// TODO: Add any initialization & defaults
|
||||
_DTS = _ItemAnnotationExtension.DefaultDTS;
|
||||
_UserID = _ItemAnnotationExtension.DefaultUserID;
|
||||
_MyAnnotationType = myAnnotationType;
|
||||
_MyAnnotationType = myAnnotationType;
|
||||
ValidationRules.CheckRules();
|
||||
}
|
||||
internal ItemAnnotation(SafeDataReader dr)
|
||||
@@ -416,7 +416,7 @@ namespace VEPROMS.CSLA.Library
|
||||
#region Data Access Portal
|
||||
private void Fetch(SafeDataReader dr)
|
||||
{
|
||||
if(_MyLog.IsDebugEnabled)_MyLog.DebugFormat("[{0}] ItemAnnotation.FetchDR", GetHashCode());
|
||||
if (_MyLog.IsDebugEnabled) _MyLog.DebugFormat("[{0}] ItemAnnotation.FetchDR", GetHashCode());
|
||||
try
|
||||
{
|
||||
_AnnotationID = dr.GetInt32("AnnotationID");
|
||||
@@ -434,7 +434,7 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
catch (Exception ex) // FKItem Fetch
|
||||
{
|
||||
if(_MyLog.IsErrorEnabled)_MyLog.Error("ItemAnnotation.FetchDR", ex);
|
||||
if (_MyLog.IsErrorEnabled) _MyLog.Error("ItemAnnotation.FetchDR", ex);
|
||||
throw new DbCslaException("ItemAnnotation.Fetch", ex);
|
||||
}
|
||||
MarkOld();
|
||||
|
Reference in New Issue
Block a user