[성현모] AuthApi 분리
This commit is contained in:
@ -4,6 +4,7 @@ using HubX.Library.Http.Packet;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Identity.Client.Extensions.Msal;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Xml;
|
||||
using SystemX.Core.DB;
|
||||
@ -116,6 +117,33 @@ namespace HubX.Server.Services
|
||||
return response;
|
||||
}
|
||||
|
||||
public async Task<List<TStorage>> Request_SelectUniqueKeyAll(string guid = "")
|
||||
{
|
||||
List<TStorage> result = new List<TStorage>();
|
||||
using (var scope = _scopeFactory.CreateScope())
|
||||
{
|
||||
var context = scope.ServiceProvider.GetRequiredService<HubXContext>();
|
||||
if (context != null)
|
||||
{
|
||||
try
|
||||
{
|
||||
using (var transaction = await context.CreateTransactionAsync(IsolationLevel.ReadUncommitted))
|
||||
{
|
||||
result = await context.TStorages.AsNoTracking().ToListAsync();
|
||||
await context.CloseTransactionAsync(transaction);
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
Log4net.WriteLine($"Select Unique Key Transaction Error::{guid}", LogType.Error);
|
||||
Log4net.WriteLine(e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
public async Task<Response_UpdateUniqueKy> Request_UpdateUniqueKey(Request_UpdateUniqueKey request, string guid = "")
|
||||
{
|
||||
Response_UpdateUniqueKy response = new Response_UpdateUniqueKy();
|
||||
|
||||
Reference in New Issue
Block a user