修改XML保存路径
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -339,3 +339,4 @@ ASALocalRun/
|
||||
# BeatPulse healthcheck temp database
|
||||
healthchecksdb
|
||||
/NX.ERP.WebAPi/binXMLDOM
|
||||
/NX.ERP.WebAPi/XMLDOM
|
||||
|
||||
@@ -60,7 +60,7 @@ namespace NX.ERP.U8.Store
|
||||
|
||||
private string GetHeadTemplate()
|
||||
{
|
||||
var strTemlate = FileHelp.ReadFile(AppDomain.CurrentDomain.RelativeSearchPath + $"XMLDOM\\XMLDomHead{this.voucherID}.xml");
|
||||
var strTemlate = FileHelp.ReadFile(AppDomain.CurrentDomain.BaseDirectory + $"XMLDOM\\XMLDomHead{this.voucherID}.xml");
|
||||
if (strTemlate == string.Empty)
|
||||
{
|
||||
this.LoadTemplate();
|
||||
@@ -71,7 +71,7 @@ namespace NX.ERP.U8.Store
|
||||
|
||||
private string GetBodyTemplate()
|
||||
{
|
||||
var strTemlate = FileHelp.ReadFile(AppDomain.CurrentDomain.RelativeSearchPath + $"XMLDOM\\XMLDomBody{this.voucherID}.xml");
|
||||
var strTemlate = FileHelp.ReadFile(AppDomain.CurrentDomain.BaseDirectory + $"XMLDOM\\XMLDomBody{this.voucherID}.xml");
|
||||
if (strTemlate == string.Empty)
|
||||
{
|
||||
this.LoadTemplate();
|
||||
@@ -86,7 +86,7 @@ namespace NX.ERP.U8.Store
|
||||
VoucherParameter rdVoucherParameter = null;
|
||||
try
|
||||
{
|
||||
if (!Directory.Exists(AppDomain.CurrentDomain.RelativeSearchPath + "XMLDOM"))
|
||||
if (!Directory.Exists(AppDomain.CurrentDomain.BaseDirectory + "XMLDOM"))
|
||||
{
|
||||
Directory.CreateDirectory(AppDomain.CurrentDomain.RelativeSearchPath + "XMLDOM");
|
||||
}
|
||||
@@ -96,8 +96,8 @@ namespace NX.ERP.U8.Store
|
||||
U8LoginContext.Instance.LoadRdVoucher(this.LoadUrl, rdVoucherParameter);
|
||||
if (rdVoucherParameter.ReturnValue)
|
||||
{
|
||||
FileHelp.WriteFile(rdVoucherParameter.DomHead.xml, AppDomain.CurrentDomain.RelativeSearchPath + $"XMLDOM\\XMLDomHead{this.voucherID}.xml");
|
||||
FileHelp.WriteFile(rdVoucherParameter.DomBody.xml, AppDomain.CurrentDomain.RelativeSearchPath + $"XMLDOM\\XMLDomBody{this.voucherID}.xml");
|
||||
FileHelp.WriteFile(rdVoucherParameter.DomHead.xml, AppDomain.CurrentDomain.BaseDirectory + $"XMLDOM\\XMLDomHead{this.voucherID}.xml");
|
||||
FileHelp.WriteFile(rdVoucherParameter.DomBody.xml, AppDomain.CurrentDomain.BaseDirectory + $"XMLDOM\\XMLDomBody{this.voucherID}.xml");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user