Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -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 {
|
||||
|
||||
Reference in New Issue
Block a user