Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #461 +/- ##
==========================================
- Coverage 54.15% 54.06% -0.09%
==========================================
Files 169 169
Lines 3741 3747 +6
==========================================
Hits 2026 2026
- Misses 1715 1721 +6 ☔ View full report in Codecov by Sentry. |
> [!IMPORTANT] > We really need to release new versions **soon**, as we have not for several months and there's some time needed to test in alpha before prod. This goes hand in hand with the **major version bump** [for Hyperion](../../Hyperion/pull/642). Both PRs are ready, and _seemingly_ waiting for some more **breaking changes** to be merged, including (by likelihood): - [x] Support Flutter 3.27: #464 - [ ] Allow students from other Schools to have a MyECL account: #447 - [ ] MyECLPay: #72 (old PR but recent branch) - [ ] "_Centrale Mega Meme_" Meme module: #461 - [x] External Notifications: #448
| final isCMMAdminProvider = StateProvider<bool>((ref) { | ||
| final me = ref.watch(userProvider); | ||
| for (final group in me.groups) { | ||
| if (group.name == "CMM") { |
There was a problem hiding this comment.
You better have to check with the group.id instead of the name, because nothing is preventing another group to be named CMM, thus giving its members the visual of the admin panel, even if Hyperion will block their requests
| Future<List<CMM>> getCMM() async { | ||
| //return (await getList(suffix: '')).map((e) => CMM.fromJson(e)).toList(); | ||
| return [ | ||
| CMM( |
There was a problem hiding this comment.
Consider unmocking when going from Draft to PR and to test with the backend
| CMMScore(value: 1, user: user, position: 3), | ||
| ]; | ||
| // return List<CMMScore>.from( | ||
| // (await getList(suffix: "CMMScores")) |
| Future<List<CMM>> getMyCMM() async { | ||
| //return (await getList(suffix: '')).map((e) => CMM.fromJson(e)).toList(); | ||
| return [ | ||
| CMM( |
There was a problem hiding this comment.
Just to avoid missing one in the process
| path: add, | ||
| builder: () => const AddCMMPage(), | ||
| ), | ||
| ], |
There was a problem hiding this comment.
You should also use the DeferredLoadingMiddleware here, to further improve loading time
lib/CMM/ui/components/cmm_card.dart
Outdated
There was a problem hiding this comment.
Not sure about the relevance of the comments in this file
| decoration: BoxDecoration( | ||
| border: Border.all(color: Colors.black, width: 2), | ||
| borderRadius: const BorderRadius.only( | ||
| topLeft: Radius.circular(20), // Rounded top-left corner |
There was a problem hiding this comment.
I don't clearly see the purpose of the comment here, the code speaks for itself i my opinion
| style: (score.position == 1 || | ||
| score.position == 2 || | ||
| score.position == 3) | ||
| ? const TextStyle( |
There was a problem hiding this comment.
Can't score.position <= 3 can just sum all of this up ?
| FormField<File>( | ||
| validator: (e) { | ||
| if (poster.value == null) { | ||
| return "Choix poster"; |
There was a problem hiding this comment.
Maybe go for a more explicit message : "Aucun fichier choisis"
| child: posterFile.value != null | ||
| ? | ||
| // ? Container( | ||
| // decoration: BoxDecoration( |
There was a problem hiding this comment.
Just don't forget to delete it if you are certain not to use it anymore, it should not stay in the PR in the end
|
Back-end counterpart: Hyperion#665 |
No description provided.