refactor:将AddBathAsync改为AddAsync
This commit is contained in:
@@ -65,7 +65,7 @@ public class TriggerVariableAppService : ITriggerVariableAppService
|
||||
/// </summary>
|
||||
public async Task<List<TriggerVariable>> AddTriggerVariablesAsync(List<TriggerVariable> triggerVariables)
|
||||
{
|
||||
return await _repositoryManager.TriggerVariables.AddBatchAsync(triggerVariables);
|
||||
return await _repositoryManager.TriggerVariables.AddAsync(triggerVariables);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -224,7 +224,7 @@ public class VariableAppService : IVariableAppService
|
||||
try
|
||||
{
|
||||
var variableModels = _mapper.Map<List<Variable>>(variables);
|
||||
var addedVariables = await _repoManager.Variables.AddBatchAsync(variableModels);
|
||||
var addedVariables = await _repoManager.Variables.AddAsync(variableModels);
|
||||
return _mapper.Map<List<Variable>>(addedVariables);
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
@@ -94,7 +94,7 @@ public class HistoryProcessor : IVariableProcessor, IDisposable
|
||||
{
|
||||
try
|
||||
{
|
||||
await _repositoryManager.VariableHistories.AddBatchAsync(itemsToProcess);
|
||||
await _repositoryManager.VariableHistories.AddAsync(itemsToProcess);
|
||||
_logger.LogInformation("成功插入 {Count} 条变量历史记录到数据库", itemsToProcess.Count);
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
Reference in New Issue
Block a user