-
Notifications
You must be signed in to change notification settings - Fork 661
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
受注編集画面にポイント付与率を追加 #5571
受注編集画面にポイント付与率を追加 #5571
Conversation
Codecov Report
@@ Coverage Diff @@
## 4.2 #5571 +/- ##
============================================
+ Coverage 78.75% 78.95% +0.20%
- Complexity 6251 6281 +30
============================================
Files 468 469 +1
Lines 21010 21092 +82
============================================
+ Hits 16547 16654 +107
+ Misses 4463 4438 -25
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
|
発送済みにしてから、ポイント付与率を変更しても会員に付与されるポイントを変更することはできないので、ポイント付与率のフォームは readonly にしてしまった方がよいかもしれません。 |
明細ごとにポイント付与率を変更されると、利用ポイントの控除分(200ポイント利用すると、加算ポイント -2 になる仕様)に不整合が発生する可能性が高いため、 hidden で保持するよう修正入れたいと思います |
明細ごとにポイント付与率を変更されると、利用ポイントの控除分(200ポイント利用すると、加算ポイント -2 になる仕様)に不整合が発生する可能性が高いため、 hidden で保持するよう修正
- 商品明細が取得できる場合は, 商品明細に設定されたポイント付与率を設定 - 商品明細が取得できない場合は, 店舗基本情報のポイント付与率を設定
利用ポイントの控除分(200ポイント利用すると、加算ポイント -2 になる仕様)のポイント付与率は、ポイント明細の付与率が使用されるため、商品明細のポイント付与率を設定するよう修正しました |
@nanasess
|
// 商品別ポイントは未実装なので, 商品明細のポイント付与率はすべて同じ値が設定されているはず | ||
$ProductOrderItem = $itemHolder->getItems()->getProductClasses()->current(); | ||
if ($ProductOrderItem instanceof OrderItem) { | ||
$pointRate = $ProductOrderItem->getPointRate(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nanasess
#5571 (comment) の通り、商品明細のポイント付与率がnullの場合もありうるので、商品明細の付与率 => 基本情報の付与率の順に判定したほうがよいかもしれません。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$ProductOrderItem instanceof OrderItem && $ProductOrderItem->getPointRate() !== null
という条件にしてみました
@chihiro-adachi point_rate が null の場合は店舗基本情報のポイント付与率が使われるようになっているかなと |
@chihiro-adachi |
で、ポイント明細の付与率が10で設定されるようです。 |
@chihiro-adachi このケースの場合、新しく追加した商品明細の付与率は 1 なのが正しい感じですよね🤔 |
@nanasess 値引き明細の新規追加時に、付与率がnullで登録されるようです。 |
@chihiro-adachi 対応しました |
@nanasess |
概要(Overview・Refs Issue)
#5529 へ管理画面側への対応
方針(Policy)
ポイント付与率が一律でbaseinfoに依存しているのでその点の対応
実装に関する補足(Appendix)
テスト(Test)
相談(Discussion)
マイナーバージョン互換性保持のための制限事項チェックリスト
レビュワー確認項目