Replace GetType().Name
This commit is contained in:
parent
f2764894ba
commit
7caa952bc3
@ -34,7 +34,7 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
// Walk up active parents until the parent is not an item
|
||||
Item tmp = this;
|
||||
while (tmp.ActiveParent.GetType().Name != "DocVersion") tmp = (Item)tmp.ActiveParent;
|
||||
while (tmp.ActiveParent.GetType() != typeof(DocVersion)) tmp = (Item)tmp.ActiveParent;
|
||||
return tmp;
|
||||
}
|
||||
} private IVEDrillDown _ActiveParent = null;
|
||||
@ -261,6 +261,30 @@ namespace VEPROMS.CSLA.Library
|
||||
return false;
|
||||
}
|
||||
}
|
||||
public bool IsSection
|
||||
{
|
||||
get
|
||||
{
|
||||
if ((MyContent.Type / 10000) == 1) return true;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
public bool IsProcedure
|
||||
{
|
||||
get
|
||||
{
|
||||
if ((MyContent.Type / 10000) == 0) return true;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
public bool IsStep
|
||||
{
|
||||
get
|
||||
{
|
||||
if ((MyContent.Type / 10000) == 2) return true;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
private E_FromType ItemType
|
||||
{
|
||||
get
|
||||
@ -497,7 +521,7 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
// Walk up active parents until the parent is not an item
|
||||
ItemInfo tmp = this;
|
||||
while (tmp.ActiveParent.GetType().Name != "DocVersionInfo") tmp = (ItemInfo)tmp.ActiveParent;
|
||||
while (tmp.ActiveParent.GetType() != typeof(DocVersionInfo)) tmp = (ItemInfo)tmp.ActiveParent;
|
||||
return tmp;
|
||||
}
|
||||
}
|
||||
|
@ -181,7 +181,7 @@ namespace VEPROMS.CSLA.Library
|
||||
DateTime tStart = DateTime.Now;
|
||||
OnLoadingChildrenSQL(this, new VETreeNodeEventArgs());
|
||||
IList ol;
|
||||
if(_VEObject.GetType().Name == "StepInfo" ||_VEObject.GetType().Name == "SectionInfo" ||_VEObject.GetType().Name == "ItemInfo" )
|
||||
if(_VEObject.GetType() == typeof(StepInfo) ||_VEObject.GetType() == typeof(SectionInfo) ||_VEObject.GetType() == typeof(ItemInfo) )
|
||||
ol = ((ItemInfo)_VEObject).GetChildren(allParts);
|
||||
else
|
||||
ol = _VEObject.GetChildren();
|
||||
|
Loading…
x
Reference in New Issue
Block a user