Merge pull request 'debug-etudiant' (#27) from debug-etudiant into master
All checks were successful
Build and Push Docker Image / build (push) Successful in 2m2s

Reviewed-on: #27
This commit is contained in:
2025-04-15 15:24:31 +00:00
3 changed files with 14 additions and 8 deletions

View File

@@ -3,5 +3,5 @@ database = django_prod
user = django_usr user = django_usr
password = YwVHV36ovBTXWugb password = YwVHV36ovBTXWugb
default-character-set = utf8 default-character-set = utf8
host =33.15.0.2 host =33.15.0.1
port =3306 port =3306

View File

@@ -119,12 +119,18 @@ class cl_Student_eval(models.Model):
if eval.ID == self.ID: if eval.ID == self.ID:
to_be_set = True to_be_set = True
else: else:
#print(f"check eval {eval} {eval.nEval_Type} ({eval.nEval_Type == 1}) ? {eval.sRef} == {self.sRef} => {eval.sRef == self.sRef} {self}") print("check eval")
print(eval)
print(self)
if eval.nEval_Type == "1" and eval.sRef == self.sRef: if eval.nEval_Type == "1" and eval.sRef == self.sRef:
print(f"Eval mirror found {eval} / {self}") print(f"Eval mirror found type 1 {eval} / {self}")
to_be_set = True to_be_set = True
elif eval.nEval_Type == "2" and eval.dtDate == self.dtDate: elif eval.nEval_Type == "2" and eval.sRef == self.sRef:
print(f"Eval mirror found {eval} / {self}") print(f"Eval mirror found type 2 {eval} / {self}")
to_be_set = True
if eval.nEval_Type == "3" and eval.sRef == self.sRef:
print(f"Eval mirror found type 3 {eval} / {self}")
to_be_set = True to_be_set = True
if to_be_set: if to_be_set:
@@ -137,7 +143,7 @@ class cl_Student_eval(models.Model):
if self.o_Encadrant_eval is not None and self.o_Auto_eval is not None: if self.o_Encadrant_eval is not None and self.o_Auto_eval is not None:
self.mirrored = True self.mirrored = True
#print(f" auto = {self.o_Auto_eval} / encadrant = {self.o_Encadrant_eval}") print(f" auto = {self.o_Auto_eval} / encadrant = {self.o_Encadrant_eval}")
def get_all_evals_for_student(self,sStudent=None): def get_all_evals_for_student(self,sStudent=None):

View File

@@ -103,14 +103,14 @@
<table class="w-full"> <table class="w-full">
<tbody> <tbody>
<tr class="border-b"> <tr class="border-b">
<th class="py-2 px-4 text-left font-semibold">Avis Global</th> <th class="py-2 px-4 text-left font-semibold">Avis Global {{object.o_Encadrant_eval.ID}}</th>
</tr> </tr>
<tr class="border-b"> <tr class="border-b">
<td class="py-2 px-4">{{ object.o_Encadrant_eval.sDesc_global | safe }}</td> <td class="py-2 px-4">{{ object.o_Encadrant_eval.sDesc_global | safe }}</td>
</tr> </tr>
<tr class="border-b"> <tr class="border-b">
<th class="py-2 px-4 text-left font-semibold">Avis Global (auto)</th> <th class="py-2 px-4 text-left font-semibold">Avis Global (auto) {{object.o_Auto_eval.ID}}</th>
</tr> </tr>
<tr class="border-b"> <tr class="border-b">