|
@@ -365,9 +365,10 @@ namespace OTSSysMgrApp
|
|
|
|
|
|
private void CopyConfigBySysType()
|
|
|
{
|
|
|
- DialogResult dialogResult= MessageBox.Show("操作有风险,将会采用默认系统配置初始化当前所有配置文件,是否继续?", "删除提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
|
|
+ DialogResult dialogResult= MessageBox.Show("操作有风险,将会采用默认系统配置初始化当前所有配置文件,是否继续?点击否仅切换系统", "删除提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Question);
|
|
|
if(dialogResult==DialogResult.Cancel)
|
|
|
{
|
|
|
+ WriteSysType();
|
|
|
return;
|
|
|
}
|
|
|
string sourceFilepath= Application.StartupPath + @"\Config\ConfigTemplate";
|
|
@@ -407,6 +408,7 @@ namespace OTSSysMgrApp
|
|
|
}
|
|
|
fileInfo.CopyTo(tagretFile +"\\"+ fileInfo.Name, true);
|
|
|
}
|
|
|
+ MessageBox.Show("Configure successful!", "Tip");
|
|
|
}
|
|
|
|
|
|
private void GetSEMAndEDSController()
|
|
@@ -614,23 +616,6 @@ namespace OTSSysMgrApp
|
|
|
SaveSEMAndEDSController();
|
|
|
}
|
|
|
|
|
|
- private void btnRemove_Click(object sender, EventArgs e)
|
|
|
- {
|
|
|
- string message11 = table["message11"].ToString();
|
|
|
- //1.删除License文件
|
|
|
- if (MessageBox.Show(message11, "Tip",MessageBoxButtons.YesNo,MessageBoxIcon.Information)== DialogResult.Yes)
|
|
|
- {
|
|
|
- //设置XML节点信息
|
|
|
- SaveSetting("ComupterName", "");
|
|
|
- SaveSetting("HardwareID", "");
|
|
|
- SaveSetting("OTSProduct", "");
|
|
|
- SaveSetting("PassType", "");
|
|
|
- SaveSetting("ExpireDate", "");
|
|
|
-
|
|
|
- tabHardwareSet.Parent = null;
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
|
|
|
|
|
|
//修改默认语言
|
|
@@ -660,5 +645,21 @@ namespace OTSSysMgrApp
|
|
|
|
|
|
btn_ok.Enabled = true;
|
|
|
}
|
|
|
+ private void WriteSysType()
|
|
|
+ {
|
|
|
+ string path = Application.StartupPath + @"\Config\SysData\OTSProgMgrParam.pmf";
|
|
|
+ string Type = "";
|
|
|
+ if (radioButton_IncA.Checked)
|
|
|
+ {
|
|
|
+ Type = "IncA";
|
|
|
+ }
|
|
|
+ else if (radioButton_CleannessA.Checked)
|
|
|
+ {
|
|
|
+ Type = "CleannessA";
|
|
|
+ }
|
|
|
+ bool result = XMLOperationClass.WriteSysType(path, "SysType", Type);
|
|
|
+ string path2 = Application.StartupPath + @"\Config\SysData\OTSReportMgrParam.rpf";
|
|
|
+ bool resultreport = XMLOperationClass.WriteSysType(path2, "systype", Type);
|
|
|
+ }
|
|
|
}
|
|
|
}
|