增加账套数据库配置

This commit is contained in:
admin
2021-01-25 09:47:41 +08:00
parent 3141e8f9c6
commit 72c0e2e8c8
17 changed files with 46 additions and 23 deletions

View File

@@ -52,6 +52,16 @@ namespace NX.ERP.U8
}
public System.Data.IDbConnection Connection
{
get
{
return new System.Data.SqlClient.SqlConnection(this.Constr4Net);
}
}
//public int GetDefaultPoTaxRate()
//{
@@ -59,7 +69,7 @@ namespace NX.ERP.U8
// try
// {
// string strSQL = "Select cValue from AccInformation Where cSysID=N'PU' and cName=N'iDefaultZHBVRate'";
// using (var conn = new System.Data.SqlClient.SqlConnection(U8LoginContext.Instance.Constr4Net))
// using (var conn = U8LoginContext.Instance.Connection)
// {
// return conn.ExecuteScalar<int>(strSQL, null, null, 0, System.Data.CommandType.Text);
@@ -158,6 +168,7 @@ namespace NX.ERP.U8
}
private string _conStr4net;
/// <summary>
/// ADO.NET 链接字符串
@@ -166,7 +177,15 @@ namespace NX.ERP.U8
{
get
{
return this.ClsLogin.UFDataConnstringForNet;
if (string.IsNullOrEmpty(this._conStr4net))
{
this._conStr4net = this.ClsLogin.UFDataConnstringForNet;
}
return this._conStr4net;
}
set
{
this._conStr4net = value;
}
}
public string LoginUserName