修改批量导入变量返回实体,防止Io为0的问题
This commit is contained in:
@@ -221,13 +221,13 @@ public class VariableAppService : IVariableAppService
|
||||
}
|
||||
}
|
||||
|
||||
public async Task<bool> BatchImportVariablesAsync(List<VariableDto> variables)
|
||||
public async Task<List<VariableDto>> BatchImportVariablesAsync(List<VariableDto> variables)
|
||||
{
|
||||
try
|
||||
{
|
||||
var variableModels = _mapper.Map<List<Variable>>(variables);
|
||||
var result = await _repoManager.Variables.AddBatchAsync(variableModels);
|
||||
return result;
|
||||
var addedVariables = await _repoManager.Variables.AddBatchAsync(variableModels);
|
||||
return _mapper.Map<List<VariableDto>>(addedVariables);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user