İçereği Atla
Menü
Bu soru işaretlendi

Hello everyone,


I need to create a custom module via Studio for managing Talents within a sports agency, namely basketball players and coaches. I'd like some advice in terms of good design practices.


So I have several options:


- Create a Talent model that groups all Talent information → Pros: The model is isolated and doesn't impact the rest of the Odoo structure, so will facilitate migrations. Cons: Some fields are redundant with the `res.partner` model (Contacts), and we don't benefit from the functionalities linked to this module (which could evolve in the future).


- Create a Talent model that groups only Talent-specific fields, linked to the `res.partner` model, so that contact fields are those of the `res.partner` model and Talent-specific fields remain in the Talent model. Pros: you benefit from the functionalities of the Contact model, while retaining an independent model. Cons: You can't edit contact fields from a Talent view, even with linked fields, unless you use automations (not recommended to avoid overloading custom developments). So, the user will have to use two different views to edit a Talent.


- Extend the `res.partner` template to add a tab for Talent management in the Contacts view, which must be displayed in the Talent module, and which is only displayed in the Contacts module if the boolean is_talent is set to 1 (or talent_score > 0, if the current structure is used). Pros: simplify the structure by starting from an existing model, and benefit from all current and future Contacts functionalities. Cons: Weighing down one of Odoo's central models, and making it support numerous customizations, so that if one day one of these customizations falls, it's the res.partner model that risks falling, and thus blocking the entire database.



For the time being, I'd still go for the last option, thinking that if we do our customizations properly and document them correctly, maintainability remains good, and it's the best solution in terms of functionality. Do you see anything extra?

Avatar
Vazgeç
En İyi Yanıt

I'd always go with a separte models. Odoo's contact is like a trash bin and everything is thrown into there. I'd love my talents to give them a proper place.

Can I still use contacts, off course. A talent can still have contact like a company or a vendor. But it can be much more complicated. The talent may have a respresentative company, which has several contacts. the talent may represent several brands which are several contacts. The talent can attract several potential brands which are contacts. The talents can have several WaGs which we can leverage during the recruitment process which are contacts as well. But odoo contacts are poorly maintain and guarded. We don't want our potential talents to be accessible by others because leaking out that information may make our work harder. And by having it's own model, we can make the module much more useful.

Avatar
Vazgeç
İlgili Gönderiler Cevaplar Görünümler Aktivite
0
Eyl 24
1391
0
Oca 24
1022
1
Haz 22
3493
0
Mar 22
3042
1
Tem 25
1441