feat(data-access): add SqlObjects constants and update references
Add centralized SqlObjects class with constants for stored procedure and function names using usp_/fn_ prefixes. Update LotFinderRepository and MisQueryBuilder to use the new naming convention.
This commit is contained in:
@@ -122,7 +122,7 @@ public partial class LotFinderRepository
|
||||
search.SubmitDt = DateTime.UtcNow;
|
||||
|
||||
await using var connection = await _connectionFactory.CreateLotFinderConnectionAsync(ct);
|
||||
await using var command = new SqlCommand("SubmitSearch", connection)
|
||||
await using var command = new SqlCommand(SqlObjects.SubmitSearch, connection)
|
||||
{
|
||||
CommandType = CommandType.StoredProcedure,
|
||||
CommandTimeout = _options.Value.DefaultTimeoutSeconds
|
||||
@@ -147,7 +147,7 @@ public partial class LotFinderRepository
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
LogAndThrow(ex, operation, "SubmitSearch");
|
||||
LogAndThrow(ex, operation, SqlObjects.SubmitSearch);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user