public async Task> ListAsync(AssetCategory category, CancellationToken cancellationToken = default)
{
var parameters = new DynamicParameters();
parameters.Add("@category", category);
return await _context.Connection.QueryAsync<Tag>(
_databaseSettings.StoredProcedures.TagCategoryListRead,
param: parameters,
commandType: CommandType.StoredProcedure,
transaction: _context.Transaction
);
}
System.NotSupportedException : Unsupported expression: conn => conn.QueryAsync(It.IsAny(), It.IsAny(), null, null, (CommandType?)CommandType.StoredProcedure)
Extension methods (here: SqlMapper.QueryAsync) may not be used in setup / verification expressions.
Top comments (0)