[Python] How to display additional count near progress bar in Enquiry Screen?

Discussão em 'Python' iniciado por Stack, Fevereiro 8, 2025.

  1. Stack

    Stack Membro Participativo

    I am working on Odoo 18 and need to modify the Enquiry Screen to display additional counts near the progress bar. The current progress bar already shows the Expected Revenue, but I want to add more details for better visibility.

    Requirements


    CHECK THIS IMAGES

    Current view [​IMG]

    Expected View [​IMG]

    For the "NEW" Stage: The display format should be:

    525K - 12 (10)

    525K → Expected Revenue (already displayed)

    12 → Total Enquiries for the Year

    (10) → Count of enquiries currently in this stage

    For all other stages: The display format should be:

    525K - 6

    6 → Count of enquiries currently in this stage

    My Questions

    1. Where should I modify the code to achieve this?
    2. Should it be done in a custom module, or can it be handled via the XML views?
    3. How can I fetch and display these counts dynamically for each stage in Odoo 18?
    4. If it needs changes in OWL JS, how should I approach updating the progress bar component?
    What I Have Tried


    I checked the model (crm.lead or similar) but didn’t find an existing field that directly provides the total count of enquiries per year.

    I explored the OWL JS components but am unsure how to modify the display logic near the progress bar.

    Continue reading...

Compartilhe esta Página