-
Notifications
You must be signed in to change notification settings - Fork 74
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
修了したプラクティスを重複して計算してしまう不具合を修正 #7809
Conversation
90c2ede
to
aa54e38
Compare
4d499b2
to
380c78f
Compare
@komagata |
380c78f
to
7e8ea47
Compare
@komagata こちらのPRはクローズしたほうが良いでしょうか。それとも、マージまで行った方がよいでしょうか。 |
@kyokucho1989 潜在する問題はなおっていないので、最後までおねがいします~ |
@komagata @naokinaokiboo |
practices_include_progress.joins(:learnings) | ||
.merge(Learning.complete.where(user_id: id)) | ||
.merge(Learning.complete.where(user_id: id)).pluck(:id).uniq.size |
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.
.pluck(:id).uniq.size
を追加することで、プラクティスの重複をなくしています。
@kyokucho1989 |
@naokinaokiboo 問題ないですー |
7e8ea47
to
8397ace
Compare
@naokinaokiboo |
@kyokucho1989 |
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.
レビュー遅くなり申し訳ありません🙏
質問とコメント入れさせて頂きました〜。ご確認お願い致します。
あと、誤記ですが、本PRのプラクティスの説明
にある複数カテゴリに所属するプラクティス
の必修or必修ではない
の説明が逆ではないかと思います。
db/fixtures/learnings.yml
Outdated
|
||
learning25: | ||
user: harikirio | ||
practice: practice62 |
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.
こちら、practice111ではないでしょうか?
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.
すみません、修正しました!
db/fixtures/learnings.yml
Outdated
|
||
learning26: | ||
user: harikirio | ||
practice: practice63 |
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.
こちら、practice112ではないでしょうか?
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.
こちらも修正しました!
courses_category27: | ||
course: course1 | ||
category: category23 | ||
position: 19 |
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.
category23
を追加した目的は何でしょうか?
(categories_practices.yml
からはcategory23
は参照されておらず、現状、特に必要ではないように思っています。)
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.
すみません。忘れていました! categories_practices.yml
でcategory23
を参照するようにしています。
こちらは複数のカテゴリに所属するプラクティスを設定する上で必要なカテゴリです。
@naokinaokiboo |
db/fixtureデータのconflictを解消
conflictに対応する際に修正をしていなかった
8397ace
to
4e46230
Compare
@naokinaokiboo
こちらも修正しています。 |
@kyokucho1989 |
@naokinaokiboo @komagata |
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.
確認させていただきました。OKです~👌
@komagata bootcampアプリ側で「Ruby on Rails (Rails 6版)」のカテゴリとRailsコースの紐付けを一時的に復活していただけませんか。 このPRによって、複数カテゴリに所属するプラクティスについても修了数が正しく表示されてされるようになりました。 以前FBCのカリキュラムに載っていた上記のカテゴリがそれにあてはまります。 紐付けが復活してもプラクティスの修了数が問題なく表示されていれば、本Issueをクローズできます。 |
復活させました~ |
@komagata 確認できました!問題ないことがわかりました。クローズします |
Issue
概要
以前 #7635 のIssueを解消するため下記のPRを作成しました。
#7699
その後本番環境に反映されましたが、修了した数が正しい状態になりませんでした。
それを解消するPRです。
変更確認方法
bug/mismatch_complete_practice_size
をローカルに取り込む(
http://localhost:3000/users/527754862
)プラクティスの説明
Screenshot
変更前
変更後