B2013-153 fixed: fix getting Count of associated objects.

Cleanup for getting Counts of associated objects.
This commit is contained in:
Kathy Ruffing 2013-08-27 15:54:10 +00:00
parent 5d5533b232
commit 5a81462bf7
2 changed files with 7 additions and 0 deletions

View File

@ -254,6 +254,11 @@ namespace VEPROMS.CSLA.Library
get get
{ {
CanReadProperty("ContentEntryCount", true); CanReadProperty("ContentEntryCount", true);
if (_ContentEntryCount < 0)
{
_MyEntry = EntryInfo.Get(_ContentID);
_ContentEntryCount = MyEntry == null ? 0 : 1;
}
return _ContentEntryCount; return _ContentEntryCount;
} }
} }

View File

@ -348,6 +348,8 @@ namespace VEPROMS.CSLA.Library
get get
{ {
CanReadProperty("DocumentEntryCount", true); CanReadProperty("DocumentEntryCount", true);
if (_DocumentEntryCount < 0)
_DocumentEntryCount = DocumentEntries.Count;
return _DocumentEntryCount; return _DocumentEntryCount;
} }
} }