Merge remote-tracking branch 'origin/master'

This commit is contained in:
M_Kececi
2026-06-24 19:47:09 +03:00
parent 62bf272f17
commit 10fd77bece
19 changed files with 141 additions and 141 deletions

View File

@@ -900,7 +900,7 @@ FROM (
PARTITION BY LTRIM(RTRIM(PriceGroupCode)), LTRIM(RTRIM(DocCurrencyCode))
ORDER BY ValidDate DESC, ValidTime DESC, LastUpdatedDate DESC
) AS rn
FROM dbo.trPriceListLine WITH(NOLOCK)
FROM dbo.trPriceListLine
WHERE ItemTypeCode = 1
AND LTRIM(RTRIM(ItemCode)) = @ItemCode
AND ISNULL(IsDisabled, 0) = 0
@@ -970,7 +970,7 @@ WHERE rn = 1;
var latestPrice sql.NullFloat64
_ = msTx.QueryRowContext(ctx, `
SELECT TOP (1) CAST(Price AS FLOAT)
FROM dbo.trPriceListLine WITH(NOLOCK)
FROM dbo.trPriceListLine
WHERE ItemTypeCode = 1
AND LTRIM(RTRIM(ItemCode)) = @p1
AND LTRIM(RTRIM(DocCurrencyCode)) = @p2
@@ -988,7 +988,7 @@ ORDER BY ValidDate DESC, ValidTime DESC, LastUpdatedDate DESC;
if nextSort <= 0 {
_ = msTx.QueryRowContext(ctx, `
SELECT ISNULL(MAX(SortOrder), 0) + 1
FROM dbo.trPriceListLine WITH(NOLOCK)
FROM dbo.trPriceListLine
WHERE PriceListHeaderID = CONVERT(UNIQUEIDENTIFIER, @p1);
`, sql.Named("p1", headerID)).Scan(&nextSort)
if nextSort <= 0 {