correct config xml to upper case C
RevisionConfig property on Revision and RevisionInfo classes
This commit is contained in:
parent
1c2c28c625
commit
a57172f22f
@ -25,14 +25,14 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
_Document = document;
|
_Document = document;
|
||||||
string xml = _Document.Config;
|
string xml = _Document.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
public DocumentConfig(DocumentInfo documentInfo)
|
public DocumentConfig(DocumentInfo documentInfo)
|
||||||
{
|
{
|
||||||
_DocumentInfo = documentInfo;
|
_DocumentInfo = documentInfo;
|
||||||
string xml = _DocumentInfo.Config;
|
string xml = _DocumentInfo.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
internal string GetValue(string group, string item)
|
internal string GetValue(string group, string item)
|
||||||
|
@ -50,7 +50,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
_Folder = folder;
|
_Folder = folder;
|
||||||
string xml = _Folder.Config;
|
string xml = _Folder.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
if (folder.MyFolderInfo.MyParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
if (folder.MyFolderInfo.MyParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
||||||
}
|
}
|
||||||
@ -91,18 +91,18 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
_FolderInfo = folderInfo;
|
_FolderInfo = folderInfo;
|
||||||
string xml = _FolderInfo.Config;
|
string xml = _FolderInfo.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
if (_FolderInfo.MyParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
if (_FolderInfo.MyParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
||||||
}
|
}
|
||||||
public FolderConfig(string xml)
|
public FolderConfig(string xml)
|
||||||
{
|
{
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
public FolderConfig()
|
public FolderConfig()
|
||||||
{
|
{
|
||||||
_Xp = new XMLProperties("<config/>");
|
_Xp = new XMLProperties("<Config/>");
|
||||||
}
|
}
|
||||||
internal string GetValue(string group, string item)
|
internal string GetValue(string group, string item)
|
||||||
{
|
{
|
||||||
@ -181,7 +181,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
string s = _Xp.ToString();
|
string s = _Xp.ToString();
|
||||||
if (s == "<config/>" || s == "<config></config>") return string.Empty;
|
if (s == "<Config/>" || s == "<Config></Config>") return string.Empty;
|
||||||
return s;
|
return s;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
@ -47,7 +47,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
_Procedure = procedure;
|
_Procedure = procedure;
|
||||||
string xml = procedure.MyContent.Config;
|
string xml = procedure.MyContent.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
if (procedure.MyProcedureInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
if (procedure.MyProcedureInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
||||||
}
|
}
|
||||||
@ -96,14 +96,14 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
_ProcedureInfo = procedureInfo;
|
_ProcedureInfo = procedureInfo;
|
||||||
string xml = procedureInfo.MyContent.Config;
|
string xml = procedureInfo.MyContent.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
_Xp.AncestorLookup = true;
|
_Xp.AncestorLookup = true;
|
||||||
if (procedureInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
if (procedureInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
||||||
}
|
}
|
||||||
public ProcedureConfig(string xml)
|
public ProcedureConfig(string xml)
|
||||||
{
|
{
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
//public ProcedureConfig()
|
//public ProcedureConfig()
|
||||||
@ -196,7 +196,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
string s = _Xp.ToString();
|
string s = _Xp.ToString();
|
||||||
if (s == "<config/>" || s == "<config></config>") return string.Empty;
|
if (s == "<Config/>" || s == "<Config></Config>") return string.Empty;
|
||||||
return s;
|
return s;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
@ -43,18 +43,12 @@ namespace VEPROMS.CSLA.Library
|
|||||||
//}
|
//}
|
||||||
private Section _Section;
|
private Section _Section;
|
||||||
private SectionInfo _SectionInfo;
|
private SectionInfo _SectionInfo;
|
||||||
private static int _SectionConfigUnique = 0;
|
|
||||||
private static int SectionConfigUnique
|
|
||||||
{ get { return ++_SectionConfigUnique; } }
|
|
||||||
private int _MySectionConfigUnique = SectionConfigUnique;
|
|
||||||
public int MySectionConfigUnique // Absolutely Unique ID - Info
|
|
||||||
{ get { return _MySectionConfigUnique; } }
|
|
||||||
|
|
||||||
public SectionConfig(Section section)
|
public SectionConfig(Section section)
|
||||||
{
|
{
|
||||||
_Section = section;
|
_Section = section;
|
||||||
string xml = section.MyContent.Config;
|
string xml = section.MyContent.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
if (section.MySectionInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
if (section.MySectionInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
||||||
}
|
}
|
||||||
@ -96,13 +90,13 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
_SectionInfo = sectionInfo;
|
_SectionInfo = sectionInfo;
|
||||||
string xml = sectionInfo.MyContent.Config;
|
string xml = sectionInfo.MyContent.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
if (_SectionInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
if (_SectionInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder);
|
||||||
}
|
}
|
||||||
public SectionConfig(string xml)
|
public SectionConfig(string xml)
|
||||||
{
|
{
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
public SectionConfig()
|
public SectionConfig()
|
||||||
@ -260,7 +254,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
string s = _Xp.ToString();
|
string s = _Xp.ToString();
|
||||||
if (s == "<config/>" || s == "<config></config>") return string.Empty;
|
if (s == "<Config/>" || s == "<Config></Config>") return string.Empty;
|
||||||
return s;
|
return s;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
@ -285,20 +279,20 @@ namespace VEPROMS.CSLA.Library
|
|||||||
if (s == string.Empty)
|
if (s == string.Empty)
|
||||||
s = _Xp.ParentValue("Section", "Pagination"); // get the parent value
|
s = _Xp.ParentValue("Section", "Pagination"); // get the parent value
|
||||||
//If there is no parent value, then use the volian default
|
//If there is no parent value, then use the volian default
|
||||||
//if (s == string.Empty)
|
if (s == string.Empty)
|
||||||
//{
|
{
|
||||||
// if (MyFormat != null)
|
if (MyFormat != null)
|
||||||
// {
|
{
|
||||||
// bool rval = MyFormat.MyStepSectionLayoutData.BreakOnSections;
|
bool rval = MyFormat.MyStepSectionLayoutData.BreakOnSections;
|
||||||
// return (rval) ? SectionPagination.Separate : SectionPagination.Continuous;// default to volian default
|
return (rval) ? SectionPagination.Separate : SectionPagination.Continuous;// default to volian default
|
||||||
// }
|
}
|
||||||
// else
|
else
|
||||||
// {
|
{
|
||||||
// bool rval = MyDefaultFormat.MyStepSectionLayoutData.BreakOnSections;
|
bool rval = MyDefaultFormat.MyStepSectionLayoutData.BreakOnSections;
|
||||||
// return (rval) ? SectionPagination.Separate : SectionPagination.Continuous;// default to volian default
|
return (rval) ? SectionPagination.Separate : SectionPagination.Continuous;// default to volian default
|
||||||
// }
|
}
|
||||||
//}
|
}
|
||||||
if (s == string.Empty) return SectionPagination.Continuous;
|
|
||||||
return (SectionPagination)int.Parse(s);
|
return (SectionPagination)int.Parse(s);
|
||||||
}
|
}
|
||||||
set
|
set
|
||||||
@ -310,7 +304,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
|
|
||||||
if (parval.Equals(string.Empty)) // if the parent value is empty, then use the volian default
|
if (parval.Equals(string.Empty)) // if the parent value is empty, then use the volian default
|
||||||
{
|
{
|
||||||
bool rval = _Section.MySectionInfo.ActiveFormat.MyStepSectionLayoutData.BreakOnSections;
|
bool rval = MyFormat.MyStepSectionLayoutData.BreakOnSections;
|
||||||
parval = (rval) ? ((int)(SectionPagination.Separate)).ToString() : ((int)(SectionPagination.Continuous)).ToString();
|
parval = (rval) ? ((int)(SectionPagination.Separate)).ToString() : ((int)(SectionPagination.Continuous)).ToString();
|
||||||
//parval = ((int)(SectionPagination.Default)).ToString();
|
//parval = ((int)(SectionPagination.Default)).ToString();
|
||||||
}
|
}
|
||||||
@ -325,6 +319,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
[Category("View Settings")]
|
[Category("View Settings")]
|
||||||
//PROPGRID: Hide Include in Background/Deviation
|
//PROPGRID: Hide Include in Background/Deviation
|
||||||
|
[Browsable(false)]
|
||||||
[DisplayName("Include in Background/Deviation")]
|
[DisplayName("Include in Background/Deviation")]
|
||||||
[RefreshProperties(RefreshProperties.All)]
|
[RefreshProperties(RefreshProperties.All)]
|
||||||
[Description("Section LinkEnhanced")]
|
[Description("Section LinkEnhanced")]
|
||||||
@ -342,6 +337,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
[Category("General")]
|
[Category("General")]
|
||||||
//PROPGRID: Hide Include On Table Of Contents
|
//PROPGRID: Hide Include On Table Of Contents
|
||||||
|
[Browsable(false)]
|
||||||
[DisplayName("Include On Table Of Contents")]
|
[DisplayName("Include On Table Of Contents")]
|
||||||
[RefreshProperties(RefreshProperties.All)]
|
[RefreshProperties(RefreshProperties.All)]
|
||||||
[Description("Section TOC")]
|
[Description("Section TOC")]
|
||||||
@ -349,8 +345,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
string tmp = _Xp["Section", "TOC"];
|
return _Xp["Section", "TOC"];
|
||||||
return tmp == null || tmp == "" ? "N" : tmp;
|
|
||||||
}
|
}
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
@ -360,6 +355,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
[Category("Section")]
|
[Category("Section")]
|
||||||
//PROPGRID: Hide AutoGen
|
//PROPGRID: Hide AutoGen
|
||||||
|
[Browsable(false)]
|
||||||
[DisplayName("Section AutoGen")]
|
[DisplayName("Section AutoGen")]
|
||||||
[RefreshProperties(RefreshProperties.All)]
|
[RefreshProperties(RefreshProperties.All)]
|
||||||
[Description("Section AutoGen")]
|
[Description("Section AutoGen")]
|
||||||
@ -377,6 +373,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
[Category("Section")]
|
[Category("Section")]
|
||||||
//PROPGRID: Hide Subsection PH
|
//PROPGRID: Hide Subsection PH
|
||||||
|
[Browsable(false)]
|
||||||
[DisplayName("Section PrintHdr")]
|
[DisplayName("Section PrintHdr")]
|
||||||
[RefreshProperties(RefreshProperties.All)]
|
[RefreshProperties(RefreshProperties.All)]
|
||||||
[Description("Section PrintHdr")]
|
[Description("Section PrintHdr")]
|
||||||
@ -630,7 +627,6 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
[Category("Format")]
|
[Category("Format")]
|
||||||
[DisplayName("Checkoff Header Selection")]
|
[DisplayName("Checkoff Header Selection")]
|
||||||
[RefreshProperties(RefreshProperties.All)]
|
|
||||||
[Description("Checkoff Header Selection")]
|
[Description("Checkoff Header Selection")]
|
||||||
public int Section_CheckoffHeaderSelection
|
public int Section_CheckoffHeaderSelection
|
||||||
{
|
{
|
||||||
|
@ -47,19 +47,19 @@ namespace VEPROMS.CSLA.Library
|
|||||||
{
|
{
|
||||||
_Step = step;
|
_Step = step;
|
||||||
string xml = step.MyContent.Config;
|
string xml = step.MyContent.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
public StepConfig(StepInfo stepInfo)
|
public StepConfig(StepInfo stepInfo)
|
||||||
{
|
{
|
||||||
_StepInfo = stepInfo;
|
_StepInfo = stepInfo;
|
||||||
string xml = stepInfo.MyContent.Config;
|
string xml = stepInfo.MyContent.Config;
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
public StepConfig(string xml)
|
public StepConfig(string xml)
|
||||||
{
|
{
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
public StepConfig()
|
public StepConfig()
|
||||||
@ -78,7 +78,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
string s = _Xp.ToString();
|
string s = _Xp.ToString();
|
||||||
if (s == "<config/>" || s == "<config></config>") return string.Empty;
|
if (s == "<Config/>" || s == "<Config></Config>") return string.Empty;
|
||||||
return s;
|
return s;
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
@ -16,7 +16,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
public UserConfig(string xml)
|
public UserConfig(string xml)
|
||||||
{
|
{
|
||||||
if (xml == string.Empty) xml = "<config/>";
|
if (xml == string.Empty) xml = "<Config/>";
|
||||||
_Xp = new XMLProperties(xml);
|
_Xp = new XMLProperties(xml);
|
||||||
}
|
}
|
||||||
public UserConfig()
|
public UserConfig()
|
||||||
@ -26,7 +26,7 @@ namespace VEPROMS.CSLA.Library
|
|||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
string s = _Xp.ToString();
|
string s = _Xp.ToString();
|
||||||
if (s == "<config/>" || s == "<config></config>") return string.Empty;
|
if (s == "<Config/>" || s == "<Config></Config>") return string.Empty;
|
||||||
return s;
|
return s;
|
||||||
}
|
}
|
||||||
#region UserCategory // from user.cfg
|
#region UserCategory // from user.cfg
|
||||||
|
@ -338,6 +338,16 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
public partial class Revision
|
public partial class Revision
|
||||||
{
|
{
|
||||||
|
private RevisionConfig _MyConfig;
|
||||||
|
public RevisionConfig MyConfig
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (_MyConfig == null)
|
||||||
|
_MyConfig = new RevisionConfig(this);
|
||||||
|
return _MyConfig;
|
||||||
|
}
|
||||||
|
}
|
||||||
public static Revision GetByItemIDAndRevisionNumber(int itemID, string revisionNumber)
|
public static Revision GetByItemIDAndRevisionNumber(int itemID, string revisionNumber)
|
||||||
{
|
{
|
||||||
if (!CanGetObject())
|
if (!CanGetObject())
|
||||||
@ -482,6 +492,16 @@ namespace VEPROMS.CSLA.Library
|
|||||||
}
|
}
|
||||||
public partial class RevisionInfo
|
public partial class RevisionInfo
|
||||||
{
|
{
|
||||||
|
private RevisionConfig _MyConfig;
|
||||||
|
public RevisionConfig MyConfig
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
if (_MyConfig == null)
|
||||||
|
_MyConfig = new RevisionConfig(this);
|
||||||
|
return _MyConfig;
|
||||||
|
}
|
||||||
|
}
|
||||||
#region new bozo
|
#region new bozo
|
||||||
[Serializable()]
|
[Serializable()]
|
||||||
protected class ItemCriteria
|
protected class ItemCriteria
|
||||||
|
Loading…
x
Reference in New Issue
Block a user