Skip to content

[施設予約] 「重複予約を許可しない」設定にしていても、予約の終了時間を「24:00」にすると重複して予約ができてしまう不具合対応 #2202

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 29, 2025

Conversation

akagane99
Copy link
Contributor

@akagane99 akagane99 commented May 28, 2025

概要

施設予約で「重複予約を許可しない」設定にしていても、予約の終了時間を「24:00」にすると重複して予約ができてしまう不具合がありましたので、重複予約チェックを修正しました。

不具合詳細

  • 施設管理
    • 「重複予約を許可しない」設定にする
  • 施設予約
    • 2025-05-30 14:00-17:00予定あり
    • 2025-05-30 12:00-24:00予定を登録すると、登録できてしまう

※ 終了時間の24:00表示は、施設予約特有の表示で、変換して表示しています。
 システム上では2025-05-30 24:00はイレギュラーな値で、CarbonやDBのdatetime型ですと、正しい値は 翌日の0時 2025-05-31 00:00 になります。
 2025-05-30 24:00のイレギュラーな値で、予約重複チェックを行ったため、うまくチェックが働きませんでした。

対応

  • 重複チェックで2025-05-30 24:00等の24:00がきた場合、正しい値の 翌日の0時 2025-05-31 00:00 に変換してチェックするよう対応しました。

レビュー完了希望日

5/30(金)

修正後画面

(参考) 施設管理>施設変更(重複予約=許可しない)

image

(参考) 施設予約>初期表示(05-30 14:00-17:00予定あり)

image

施設予約>予約(05-30 12:00-24:00予定を登録で、重複予約エラーが出ることを確認しました)

image

簡易テスト

関連Pull requests/Issues

なし

参考

なし

DB変更の有無

無し

チェックリスト

@akagane99 akagane99 added the bug バグ・不具合連絡 label May 28, 2025
@akagane99 akagane99 marked this pull request as ready for review May 28, 2025 22:32
@akagane99 akagane99 requested a review from masaton0216 May 28, 2025 22:38
Copy link
Contributor

@masaton0216 masaton0216 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@akagane99 ご対応ありがとうございます。
そもそも、24時に丸めてしまう処理を除去してしまえば?と考えたのですが、この処理を入れたのにもきっと何か経緯があるんですよね?
3f498e6

24時丸め処理が必要なのであれば、本修正も問題ないとは思いますが、丸め処理が入った経緯ご存知だったらお伺いしてもよいでしょうか?

@akagane99
Copy link
Contributor Author

@masaton0216
24時表示は、不具合のご連絡頂いたお客様要望で入れたんです。
なので、削るに削れなくて。

Copy link
Contributor

@masaton0216 masaton0216 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@akagane99 説明ありがとうございます。
そうしたら仕方ないですね。本修正も妥当なものと思います。
マージさせて頂きます。

@masaton0216 masaton0216 merged commit 2211831 into master May 29, 2025
4 checks passed
@masaton0216 masaton0216 deleted the OW-2577 branch May 29, 2025 02:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug バグ・不具合連絡
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants