mumuki / mumuki-domain

💡 Mumuki's domain model
GNU Affero General Public License v3.0
1 stars 0 forks source link

Use only lesson exercises in user_stats activity #205

Closed luchotc closed 3 years ago

luchotc commented 3 years ago

:dart: Goal

Only take into account lesson related exercises

:memo: Details

There is a problem with the current implementation of user_stats activity. It's using organization.exercises which is the fastest way of accessing organization exercises but it has the problem that it's taking into account exams and complements as well, because it's being joined through usages.

There are two alternatives:

What do you think @julian-berbel @felipecalvo?

:back: Backwards compatibility

100%

felipecalvo commented 3 years ago

Well, you made it pretty clear... I guess the second one is the "right" solution (as long as no current use of Organization::exercises requires complements and exams), but I don't know if it demands much extra work.

This is the kind of situation where it's very unlikely that we change it or improve it at a later point, I think.

luchotc commented 3 years ago

Great :smile: