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

[update] move get_partner_contribution_type from cgscop_partner

parent 22853aa5
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -12,3 +12,19 @@ class ResPartner(models.Model):
inverse_name="partner_id",
string="Cotisations",
)
def get_partner_contribution_type(self):
"""
Returns list of contribution type for partner
"""
contribution_type = [self.env.ref("cgscop_partner.riga_14397")]
if self.ur_id in [
self.env.ref("cgscop_partner.riga_14232"),
self.env.ref("cgscop_partner.riga_14243"),
]:
contribution_type.append(self.env.ref("cgscop_partner.riga_14399"))
if self.is_federation_com:
contribution_type.append(self.env.ref("cgscop_partner.riga_14398"))
if self.is_federation_cae:
contribution_type.append(self.env.ref("cgscop_partner.cotiz_fede_cae"))
return contribution_type
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