Merged PR 350: 割り当て可能ライセンスを取得する検索条件が誤っている
## 概要 [Task2468: 割り当て可能ライセンスを取得する検索条件が誤っている](https://paruru.nds-tyo.co.jp:8443/tfs/ReciproCollection/fa4924a4-d079-4fab-9fb5-a9a11eb205f0/_workitems/edit/2468) - 元PBI or タスクへのリンク(内容・目的などはそちらにあるはず) - 何をどう変更したか、追加したライブラリなど - 割り当て可能ライセンスを取得する際の条件について、or条件が独立していた。 WHERE `license`.`account_id` = ? AND `license`.`status` IN (?, ?) AND `license`.`expiry_date` >= ? OR `license`.`expiry_date` IS NULL このため、「`license`.`expiry_date` IS NULL」に合致するレコードが他の条件に関係なく取得されていた。 - このPull Requestでの対象/対象外 - 影響範囲(他の機能にも影響があるか) ## レビューポイント - 特にレビューしてほしい箇所 - 軽微なものや自明なものは記載不要 - 修正範囲が大きい場合などに記載 - 全体的にや仕様を満たしているか等は本当に必要な時のみ記載 - 特にありません ## UIの変更 - 変更なし ## 動作確認状況 - ユニットテスト ## 補足 - 相談、参考資料などがあれば
This commit is contained in:
parent
249689a40e
commit
5eabfdb1a4
@ -420,7 +420,7 @@ export class LicensesRepositoryService {
|
|||||||
],
|
],
|
||||||
})
|
})
|
||||||
.andWhere(
|
.andWhere(
|
||||||
'license.expiry_date >= :nowDate OR license.expiry_date IS NULL',
|
'(license.expiry_date >= :nowDate OR license.expiry_date IS NULL)',
|
||||||
{ nowDate },
|
{ nowDate },
|
||||||
)
|
)
|
||||||
.orderBy('license.expiry_date IS NULL', 'DESC')
|
.orderBy('license.expiry_date IS NULL', 'DESC')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user