Skip to content
Extraits de code Groupes Projets
Valider 1feb5210 rédigé par Benjamin - Le Filament's avatar Benjamin - Le Filament
Parcourir les fichiers

[update] file naming + clean test domain

parent df8317fc
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -13,11 +13,7 @@ class ScopBordereau(models.Model): ...@@ -13,11 +13,7 @@ class ScopBordereau(models.Model):
# ------------------------------------------------------ # ------------------------------------------------------
def upload_contribution_file(self): def upload_contribution_file(self):
try: try:
name = "Appel de Cotisation " + str(self.year) + " - " + self.name name = "Appel de Cotisation " + str(self.year) + " - " + self.name + ".pdf"
if self.version > 1:
name += "-" + str(self.version) + ".pdf"
else:
name += ".pdf"
report_bdx = self.env.ref( report_bdx = self.env.ref(
'cgscop_cotisation_cg.cgscop_bordereau_report').render_qweb_pdf(self.id)[0] 'cgscop_cotisation_cg.cgscop_bordereau_report').render_qweb_pdf(self.id)[0]
...@@ -62,8 +58,7 @@ class ScopBordereau(models.Model): ...@@ -62,8 +58,7 @@ class ScopBordereau(models.Model):
if year: if year:
domain.append(('year', '=', year)) domain.append(('year', '=', year))
params += ' | ' + str(year) params += ' | ' + str(year)
# bdx_ids = self.search(domain) bdx_ids = self.search(domain)
bdx_ids = self.search([('partner_id', '=', 42353)])
# batch queue creation # batch queue creation
batch_name = "Chargement PDF cotisations " + params batch_name = "Chargement PDF cotisations " + params
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter