|
@@ -17,9 +17,21 @@ namespace OTSCommon.Model
|
|
|
private const string m_TriTempFile = "DefaultTriTemplateFile.tpf";
|
|
|
|
|
|
public static string m_ReportMgrParamFile = "\\Config\\SysData\\OTSReportMgrParam.rpf"; //报告对应使用的参数文件名
|
|
|
- public RptConfigFile(string pathe)
|
|
|
+ static RptConfigFile m_config=null;
|
|
|
+ public static RptConfigFile GetRptConfig()
|
|
|
{
|
|
|
- path = pathe;
|
|
|
+ if (m_config == null)
|
|
|
+ {
|
|
|
+ m_config = new RptConfigFile();
|
|
|
+ }
|
|
|
+ return m_config;
|
|
|
+ }
|
|
|
+ private RptConfigFile()
|
|
|
+ {
|
|
|
+
|
|
|
+ path = Application.StartupPath + RptConfigFile.m_ReportMgrParamFile; //报表程序的配置文件
|
|
|
+
|
|
|
+ LoadDataFromFile();
|
|
|
}
|
|
|
public void LoadDataFromFile()
|
|
|
{
|
|
@@ -41,13 +53,7 @@ namespace OTSCommon.Model
|
|
|
}
|
|
|
|
|
|
|
|
|
- public OTS_SysType_ID GetSysType()
|
|
|
- {
|
|
|
- DataSet ds = XMLoperate.GetXmlData(Application.StartupPath + m_ReportMgrParamFile, "XMLData");
|
|
|
- DataTable dt = ds.Tables["Member"];
|
|
|
-
|
|
|
- return OTS_SysType_ID.CleannessA;
|
|
|
- }
|
|
|
+
|
|
|
|
|
|
public string GetDataFromDataSetXml(DataSet dataSrc, string propertyName,string memberName="XMLData")//the particular schema of OTS system.such as "<XMLData p1="aa" p2="bb"><Member RegName="cc" p1="dd"/>...</XMLData>
|
|
|
{
|