lg
2024-08-16 87f516dbb2e9a10d0e6bb1cb15587c82c709e130
MES.Service/DB/Repository.cs
@@ -1,14 +1,14 @@
using SqlSugar;
using MES.Service.util;
using SqlSugar;
namespace MES.Service.DB;
public class Repository<T> : SimpleClient<T> where T : class, new()
{
    public static SqlSugarScope Db = new(new ConnectionConfig
    protected static SqlSugarScope Db = new(new ConnectionConfig
        {
            DbType = DbType.Oracle,
            ConnectionString =
                @"Data Source = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.11.251)(PORT = 1521))(CONNECT_DATA = (SERVICE_NAME = ORCL))); Persist Security Info=True;User ID = sg_prd; Password=sgprd",
            ConnectionString = AppsettingsUtility.Settings.DataBaseConn,
            IsAutoCloseConnection = true
        },
        db =>
@@ -25,7 +25,7 @@
        if (context == null) Context = Db;
    }
    public int UseTransaction(Func<SqlSugarScope, int> action)
    protected int UseTransaction(Func<SqlSugarScope, int> action)
    {
        try
        {