修改导入程序配置

This commit is contained in:
admin
2021-01-18 09:24:45 +08:00
parent 5bc32e4b82
commit 2b7346b4b1
4 changed files with 18 additions and 7 deletions

View File

@@ -20,7 +20,7 @@ namespace U8AppMain
InitializeComponent(); InitializeComponent();
} }
private NX.ERP.U8.U8LoginContext u8LoginContext = null;
private void PrintLog(ResultEnity.ufinterface info) private void PrintLog(ResultEnity.ufinterface info)
{ {
@@ -53,7 +53,7 @@ namespace U8AppMain
try try
{ {
var response = HttpHelper.HttpPost(url, body); var response = HttpHelper.HttpPost(U8LoginContext.Instance.EAIUrl, body);
return XmlHelper.XmlDeserialize<ResultEnity.ufinterface>(response, Encoding.UTF8); return XmlHelper.XmlDeserialize<ResultEnity.ufinterface>(response, Encoding.UTF8);
// var strResult = $"单据:{result.requestroottag} 操作:{result.proc} \r\n"; // var strResult = $"单据:{result.requestroottag} 操作:{result.proc} \r\n";
//foreach (var item in result.Items) //foreach (var item in result.Items)
@@ -72,7 +72,7 @@ namespace U8AppMain
} }
private string url = ConfigurationManager.AppSettings.Get("url"); //private string url = ConfigurationManager.AppSettings.Get("url");
// private string connStr = ConfigurationManager.AppSettings.Get("connStr"); // private string connStr = ConfigurationManager.AppSettings.Get("connStr");
private DataTable dataTable; private DataTable dataTable;
@@ -259,7 +259,7 @@ namespace U8AppMain
} }
foreach (var item in bomLookup.Values) foreach (var item in bomLookup.Values)
{ {
var a = new Voucher.VoucherDAL(this.u8LoginContext.Constr4Net); var a = new Voucher.VoucherDAL(U8LoginContext.Instance.Constr4Net);
if (a.Add(item)) if (a.Add(item))
{ {
this.richTextBox1.SelectionColor = Color.Green; this.richTextBox1.SelectionColor = Color.Green;
@@ -412,7 +412,7 @@ namespace U8AppMain
InvCode="902112", InvCode="902112",
Position="", Position="",
Quantity=1, Quantity=1,
SourceDetailId=2921, SourceDetailId=2921
} }

View File

@@ -126,6 +126,18 @@ namespace NX.ERP.U8
} }
public string Serial { get; set; } public string Serial { get; set; }
public string EAIUrl
{
get
{
return $"http://{this.ClsLogin.cServer}/U8EAI/import.asp";
}
}
/// <summary> /// <summary>
/// ADO.NET 链接字符串 /// ADO.NET 链接字符串
/// </summary> /// </summary>

View File

@@ -11,7 +11,6 @@ namespace NX.ERP.WebAPi.Controllers
public ActionResult Index() public ActionResult Index()
{ {
ViewBag.Title = "Home Page"; ViewBag.Title = "Home Page";
return View(); return View();
} }
} }

View File

@@ -9,7 +9,7 @@ using System.Web.Http.Filters;
namespace NX.ERP.WebAPi.Filters namespace NX.ERP.WebAPi.Filters
{ {
public class ExceptionFilter : System.Web.Http.Filters.IExceptionFilter public class ExceptionFilter : IExceptionFilter
{ {
public bool AllowMultiple => throw new NotImplementedException(); public bool AllowMultiple => throw new NotImplementedException();