Passa al contenuto
Odoo Menu
  • Accedi
  • Provalo gratis
  • App
    Finanze
    • Contabilità
    • Fatturazione
    • Note spese
    • Fogli di calcolo (BI)
    • Documenti
    • Firma
    Vendite
    • CRM
    • Vendite
    • Punto vendita Negozio
    • Punto vendita Ristorante
    • Abbonamenti
    • Noleggi
    Siti web
    • Configuratore sito web
    • E-commerce
    • Blog
    • Forum
    • Live chat
    • E-learning
    Supply chain
    • Magazzino
    • Produzione
    • PLM
    • Acquisti
    • Manutenzione
    • Qualità
    Risorse umane
    • Dipendenti
    • Assunzioni
    • Ferie
    • Valutazioni
    • Referral dipendenti
    • Parco veicoli
    Marketing
    • Social marketing
    • E-mail marketing
    • SMS marketing
    • Eventi
    • Marketing automation
    • Sondaggi
    Servizi
    • Progetti
    • Fogli ore
    • Assistenza sul campo
    • Helpdesk
    • Pianificazione
    • Appuntamenti
    Produttività
    • Comunicazioni
    • Approvazioni
    • IoT
    • VoIP
    • Knowledge
    • WhatsApp
    App di terze parti Odoo Studio Piattaforma cloud Odoo
  • Settori
    Retail
    • Libreria
    • Negozio di abbigliamento
    • Negozio di arredamento
    • Alimentari
    • Ferramenta
    • Negozio di giocattoli
    Cibo e ospitalità
    • Bar e pub
    • Ristorante
    • Fast food
    • Pensione
    • Grossista di bevande
    • Hotel
    Agenzia immobiliare
    • Agenzia immobiliare
    • Studio di architettura
    • Edilizia
    • Gestione immobiliare
    • Impresa di giardinaggio
    • Associazione di proprietari immobiliari
    Consulenza
    • Società di contabilità
    • Partner Odoo
    • Agenzia di marketing
    • Studio legale
    • Selezione del personale
    • Audit e certificazione
    Produzione
    • Tessile
    • Metallo
    • Arredamenti
    • Alimentare
    • Birrificio
    • Ditta di regalistica aziendale
    Benessere e sport
    • Club sportivo
    • Negozio di ottica
    • Centro fitness
    • Centro benessere
    • Farmacia
    • Parrucchiere
    Commercio
    • Tuttofare
    • Hardware e assistenza IT
    • Ditta di installazione di pannelli solari
    • Calzolaio
    • Servizi di pulizia
    • Servizi di climatizzazione
    Altro
    • Organizzazione non profit
    • Ente per la tutela ambientale
    • Agenzia di cartellonistica pubblicitaria
    • Studio fotografico
    • Punto noleggio di biciclette
    • Rivenditore di software
    Carica tutti i settori
  • Community
    Apprendimento
    • Tutorial
    • Documentazione
    • Certificazioni 
    • Formazione
    • Blog
    • Podcast
    Potenzia la tua formazione
    • Programma educativo
    • Scale Up! Business Game
    • Visita Odoo
    Ottieni il software
    • Scarica
    • Versioni a confronto
    • Note di versione
    Collabora
    • Github
    • Forum
    • Eventi
    • Traduzioni
    • Diventa nostro partner
    • Servizi per partner
    • Registra la tua società di contabilità
    Ottieni servizi
    • Trova un partner
    • Trova un contabile
    • Incontra un esperto
    • Servizi di implementazione
    • Testimonianze dei clienti
    • Supporto
    • Aggiornamenti
    GitHub Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Richiedi una demo
  • Prezzi
  • Aiuto

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Contabilità
  • Magazzino
  • PoS
  • Progetti
  • MRP
All apps
È necessario essere registrati per interagire con la community.
Tutti gli articoli Persone Badge
Etichette (Mostra tutto)
odoo accounting v14 pos v15
Sul forum
È necessario essere registrati per interagire con la community.
Tutti gli articoli Persone Badge
Etichette (Mostra tutto)
odoo accounting v14 pos v15
Sul forum
Assistenza

Send different Worksheet Report in Field Service

Iscriviti

Ricevi una notifica quando c'è un'attività per questo post

La domanda è stata contrassegnata
reportstasksStudio
1 Rispondi
3068 Visualizzazioni
Avatar
Dave

Hi, 

I have several custom worksheets created in Studio for different maintenance tasks in Field Services. Which all work well apart from when I want to send the field service to the client as it will not include the multi line sections, it just replaces them with :-

Door Units                x_project_task_worksheet_template_16_line_fe9aa(2, 3, 4) 

Inside Units              x_project_task_worksheet_template_16_line_cd368(2, 3, 4)


I have the worksheets in the print option when they are open, but when going to the task I am unable to add them as they are not in the task.project model.

How can I add these  worksheets to the task report.


Many thanks  




2
Avatar
Abbandona
Avatar
LandLogic IT s.n.c.
Risposta migliore

Solution for Including Multiline Sections in Custom Worksheets in Field Services Reports

If you’ve created custom worksheets in Studio for maintenance tasks in Field Services and the multiline sections aren't displaying correctly in reports (replaced with something like x_project_task_worksheet_template_16_line_fe9aa(2, 3, 4)), here's how you can resolve the issue.

Issue

The custom worksheets created in Studio display correctly in the Odoo interface, but when printing or generating reports, the One2many fields (multiline sections) are not rendered properly. Instead, they appear as technical references, e.g., x_project_task_worksheet_template_16_line_cd368(2, 3, 4).

This happens because the automatically generated templates from Studio don't handle One2many fields directly in the QWeb report.

Solution: Customize the QWeb Template

To fix this issue, you need to manually customize the QWeb template that renders the report for the worksheet. Follow these steps:

  1. Identify the QWeb Template:
    • The automatically generated QWeb template for the worksheet can be found under Settings > Technical > User Interface > Views (enable developer mode if needed).
    • Locate the template by its external ID. In this case, it might look like industry_fsm_report.report_custom_x_project_task_worksheet_template_16.
  2. Modify the Template to Handle One2many Fields:
    • Edit the template and replace the default rendering for the One2many field with a loop to display its data.
    • Here's an example of how you can update the template:
      <div t-att-class="('col-5' if report_type == 'pdf' else 'col-lg-3 col-12') + ' fw-bold'">
          Door Units
      </div>
      <div nolabel="1" colspan="2" t-att-class="'col-7' if report_type == 'pdf' else 'col-lg-9 col-12'">
          <table class="table table-sm">
              <thead>
                  <tr>
                      <th>Quantity</th>
                      <th>Sequence</th>
                      <th>Description</th>
                  </tr>
              </thead>
              <tbody>
                  <t t-foreach="worksheet.x_studio_one2many_field" t-as="line">
                      <tr>
                          <td><t t-esc="line.x_studio_qty"/></td>
                          <td><t t-esc="line.x_studio_sequence"/></td>
                          <td><t t-esc="line.x_name"/></td>
                      </tr>
                  </t>
              </tbody>
          </table>
      </div>
      
      Replace x_studio_one2many_field, x_studio_qty, x_studio_sequence, and x_name with the actual technical names of your One2many field and its subfields.
  3. Test the Report:
    • Save the changes and regenerate the report.
    • Check that the multiline sections now display correctly with the expected data.

Explanation

The solution involves manually iterating through the records of the One2many field in the QWeb template using t-foreach. Each row is rendered dynamically based on the values stored in the One2many field, ensuring the data is displayed properly in the report.

Additional Notes

  • If the worksheet isn't linked to the project.task model directly, you might need to add a Many2one relation in Studio or via code to associate the worksheet with the task.
  • This solution is applicable for any module or report in Odoo where Studio-generated One2many fields aren't displaying correctly.
  • For advanced customizations, consider developing a custom Odoo module instead of relying entirely on Studio.

This approach ensures that your custom worksheets will display all multiline sections properly in the reports generated from Field Services tasks. 😊

0
Avatar
Abbandona
Ti stai godendo la conversazione? Non leggere soltanto, partecipa anche tu!

Crea un account oggi per scoprire funzionalità esclusive ed entrare a far parte della nostra fantastica community!

Registrati
Post correlati Risposte Visualizzazioni Attività
Odoo Studio Issue: Trying to Modify Existing Reports
reports Studio
Avatar
Avatar
1
gen 22
5708
Create new Report in Module Employee / Fields not available
employee reports Studio
Avatar
0
nov 23
1818
Access rights for report update and creation.
reports access rights Studio
Avatar
Avatar
1
ago 25
1777
How to add a page break on your pdf report using Studio ? Risolto
reports customization quickstart Studio
Avatar
Avatar
Avatar
Avatar
Avatar
5
feb 24
10443
Snippets of reports in odoo enterprise studio (ODOO15)
designer reports Enterprise Studio
Avatar
0
ott 22
3040
Community
  • Tutorial
  • Documentazione
  • Forum
Open source
  • Scarica
  • Github
  • Runbot
  • Traduzioni
Servizi
  • Hosting Odoo.sh
  • Supporto
  • Aggiornamenti
  • Sviluppi personalizzati
  • Formazione
  • Trova un contabile
  • Trova un partner
  • Diventa nostro partner
Chi siamo
  • La nostra azienda
  • Branding
  • Contattaci
  • Lavora con noi
  • Eventi
  • Podcast
  • Blog
  • Clienti
  • Note legali • Privacy
  • Sicurezza
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo è un gestionale di applicazioni aziendali open source pensato per coprire tutte le esigenze della tua azienda: CRM, Vendite, E-commerce, Magazzino, Produzione, Fatturazione elettronica, Project Management e molto altro.

Il punto di forza di Odoo è quello di offrire un ecosistema unico di app facili da usare, intuitive e completamente integrate tra loro.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now