Added MyFolderInfo to Folder

Removed GetChildren from editable object
Removed HasChildren from editable object
Removed ActiveParent from editable object
Removed ActiveFormat from editable object
Removed LocalFormat from editable object
This commit is contained in:
Rich 2009-10-08 14:32:02 +00:00
parent f20cc96212
commit 119c428ae4

View File

@ -53,41 +53,41 @@ namespace VEPROMS.CSLA.Library
return _Title; return _Title;
} }
#region IVEReadOnlyItem #region IVEReadOnlyItem
public System.Collections.IList GetChildren() //public System.Collections.IList GetChildren()
{ //{
if (FolderDocVersionCount != 0) return FolderDocVersions; // if (FolderDocVersionCount != 0) return FolderDocVersions;
if (ChildFolderCount != 0) return ChildFolders; // if (ChildFolderCount != 0) return ChildFolders;
return null; // return null;
} //}
public bool HasChildren //public bool HasChildren
{ //{
get { return _FolderDocVersionCount > 0 || _ChildFolderCount > 0; } // get { return _FolderDocVersionCount > 0 || _ChildFolderCount > 0; }
} //}
public IVEDrillDown ActiveParent //public IVEDrillDown ActiveParent
{ //{
get // get
{ // {
return MyParent; // return MyParent;
} // }
} //}
private Format _ActiveFormat = null; //private Format _ActiveFormat = null;
public Format ActiveFormat //public Format ActiveFormat
{ //{
get // get
{ // {
if (_ActiveFormat == null) // if (_ActiveFormat == null)
_ActiveFormat = (LocalFormat != null ? LocalFormat : ActiveParent != null ? ActiveParent.ActiveFormat : null); // _ActiveFormat = (LocalFormat != null ? LocalFormat : ActiveParent != null ? ActiveParent.ActiveFormat : null);
return _ActiveFormat; // return _ActiveFormat;
} // }
set // set
{ // {
_ActiveFormat = null; // Reset // _ActiveFormat = null; // Reset
} // }
} //}
public Format LocalFormat //public Format LocalFormat
{ //{
get { return MyFormat; } // get { return MyFormat; }
} //}
public ConfigDynamicTypeDescriptor MyConfig public ConfigDynamicTypeDescriptor MyConfig
{ {
get { return FolderConfig; } get { return FolderConfig; }
@ -103,6 +103,8 @@ namespace VEPROMS.CSLA.Library
return MakeFolder(myParent, myConnection, name, title, shortName, myFormat, null, config); return MakeFolder(myParent, myConnection, name, title, shortName, myFormat, null, config);
} }
#endregion #endregion
public FolderInfo MyFolderInfo
{ get { return FolderInfo.Get(FolderID); } }
} }
public partial class FolderInfo:IVEDrillDownReadOnly public partial class FolderInfo:IVEDrillDownReadOnly
{ {