Skip to Content
Odoo Menú
  • Registra entrada
  • Prova-ho gratis
  • Aplicacions
    Finances
    • Comptabilitat
    • Facturació
    • Despeses
    • Full de càlcul (IA)
    • Documents
    • Signatura
    Vendes
    • CRM
    • Vendes
    • Punt de venda per a botigues
    • Punt de venda per a restaurants
    • Subscripcions
    • Lloguer
    Imatges de llocs web
    • Creació de llocs web
    • Comerç electrònic
    • Blog
    • Fòrum
    • Xat en directe
    • Aprenentatge en línia
    Cadena de subministrament
    • Inventari
    • Fabricació
    • PLM
    • Compres
    • Manteniment
    • Qualitat
    Recursos humans
    • Empleats
    • Reclutament
    • Absències
    • Avaluacions
    • Recomanacions
    • Flota
    Màrqueting
    • Màrqueting Social
    • Màrqueting per correu electrònic
    • Màrqueting per SMS
    • Esdeveniments
    • Automatització del màrqueting
    • Enquestes
    Serveis
    • Projectes
    • Fulls d'hores
    • Servei de camp
    • Suport
    • Planificació
    • Cites
    Productivitat
    • Converses
    • Validacions
    • IoT
    • VoIP
    • Coneixements
    • WhatsApp
    Aplicacions de tercers Odoo Studio Plataforma d'Odoo al núvol
  • Sectors
    Comerç al detall
    • Llibreria
    • Botiga de roba
    • Botiga de mobles
    • Botiga d'ultramarins
    • Ferreteria
    • Botiga de joguines
    Food & Hospitality
    • Bar i pub
    • Restaurant
    • Menjar ràpid
    • Guest House
    • Distribuïdor de begudes
    • Hotel
    Immobiliari
    • Agència immobiliària
    • Estudi d'arquitectura
    • Construcció
    • Property Management
    • Jardineria
    • Associació de propietaris de béns immobles
    Consultoria
    • Empresa comptable
    • Partner d'Odoo
    • Agència de màrqueting
    • Bufet d'advocats
    • Captació de talent
    • Auditoria i certificació
    Fabricació
    • Textile
    • Metal
    • Mobles
    • Menjar
    • Brewery
    • Regals corporatius
    Salut i fitness
    • Club d'esport
    • Òptica
    • Centre de fitness
    • Especialistes en benestar
    • Farmàcia
    • Perruqueria
    Trades
    • Servei de manteniment
    • Hardware i suport informàtic
    • Sistemes d'energia solar
    • Shoe Maker
    • Serveis de neteja
    • Instal·lacions HVAC
    Altres
    • Nonprofit Organization
    • Agència del medi ambient
    • Lloguer de panells publicitaris
    • Fotografia
    • Lloguer de bicicletes
    • Distribuïdors de programari
    Browse all Industries
  • Comunitat
    Aprèn
    • Tutorials
    • Documentació
    • Certificacions
    • Formació
    • Blog
    • Pòdcast
    Potenciar l'educació
    • Programa educatiu
    • Scale-Up! El joc empresarial
    • Visita Odoo
    Obtindre el programari
    • Descarregar
    • Comparar edicions
    • Novetats de les versions
    Col·laborar
    • GitHub
    • Fòrum
    • Esdeveniments
    • Traduccions
    • Converteix-te en partner
    • Services for Partners
    • Registra la teva empresa comptable
    Obtindre els serveis
    • Troba un partner
    • Troba un comptable
    • Contacta amb un expert
    • Serveis d'implementació
    • Referències del client
    • Suport
    • Actualitzacions
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Programar una demo
  • Preus
  • Ajuda
You need to be registered to interact with the community.
All Posts People Badges
Etiquetes (View all)
odoo accounting v14 pos v15
About this forum
You need to be registered to interact with the community.
All Posts People Badges
Etiquetes (View all)
odoo accounting v14 pos v15
About this forum
Ajuda

Problem with excel report

Subscriure's

Get notified when there's activity on this post

This question has been flagged
enterpriseodoo.shv14
4257 Vistes
Avatar
eforsaapp, Rafael Angel Ramirez Estrada

I'm trying to generate an XML report but I'm getting the following error:

Traceback (most recent call last): File "/home/odoo/src/odoo/odoo/addons/base/models/ir_http.py", line 237, in _dispatch result = request.dispatch() File "/home/odoo/src/odoo/odoo/http.py", line 813, in dispatch r = self._call_function(**self.params) File "/home/odoo/src/odoo/odoo/http.py", line 370, in call_function return checked_call(self.db, *args, **kwargs) File "/home/odoo/src/odoo/odoo/service/model.py", line 94, in wrapper return f(dbname, *args, **kwargs) File "/home/odoo/src/odoo/odoo/http.py", line 358, in checked_call result = self.endpoint(*a, **kw) File "/home/odoo/src/odoo/odoo/http.py", line 919, in call return self.method(*args, **kw) File "/home/odoo/src/odoo/odoo/http.py", line 544, in response_wrap response = f(*args, **kw) File "/home/odoo/src/user/report_xlsx/controllers/main.py", line 31, in report_routes xlsx = report.with_context(context).render_xlsx(docids, data=data)[0] File "/home/odoo/src/user/report_xlsx/models/ir_report.py", line 18, in render_xlsx raise UserError(("%s model was not found") % report_model_name) Exception

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/odoo/src/odoo/odoo/addons/base/models/ir_http.py", line 237, in _dispatch result = request.dispatch() File "/home/odoo/src/odoo/odoo/http.py", line 813, in dispatch r = self._call_function(**self.params) File "/home/odoo/src/odoo/odoo/http.py", line 370, in call_function return checked_call(self.db, *args, **kwargs) File "/home/odoo/src/odoo/odoo/service/model.py", line 94, in wrapper return f(dbname, *args, **kwargs) File "/home/odoo/src/odoo/odoo/http.py", line 358, in checked_call result = self.endpoint(*a, **kw) File "/home/odoo/src/odoo/odoo/http.py", line 919, in call return self.method(*args, **kw) File "/home/odoo/src/odoo/odoo/http.py", line 544, in response_wrap response = f(*args, **kw) File "/home/odoo/src/user/report_xlsx/controllers/main.py", line 31, in report_routes xlsx = report.with_context(context).render_xlsx(docids, data=data)[0] File "/home/odoo/src/user/report_xlsx/models/ir_report.py", line 18, in render_xlsx raise UserError(("%s model was not found") % report_model_name) odoo.exceptions.UserError: report.False model was not found



This is the action I created:

xmlCopy codeid="action_report_saldos_y_movimientos_wizard" model="ir.actions.report">
    name="name">MATRIMAR | Reporte saldos y movimientos
    name="model">reporte_saldos_y_movimientos_wizard
    name="report_type">xlsx
    name="report_name">
        report.matrimar_reporte_de_saldos_y_movimientos.plantilla_excel
    name="report_file">
        report.matrimar_reporte_de_saldos_y_movimientos.plantilla_excel
    name="binding_type">report

This is the model to generate the report:

pythonCopy codeclass ReporteDeSaldosYMovimientosExcel(models.AbstractModel):
    _name = 'report.matrimar_reporte_de_saldos_y_movimientos.plantilla_excel'
    _description = 'MATRIMAR | Reporte excel de saldos y movimientos'
    _inherit = 'report.report_xlsx.abstract'

    def generate_xlsx_report(self, workbook, data, partners):
        _logger.info(f'{data=} {partners=}')
        pass

And this is the model of the wizard where I call the report:

pythonCopy codeclass ReporteDeSaldosYMovimientosWizard(models.TransientModel):
    _name = 'reporte_saldos_y_movimientos_wizard'
    _description = 'MATRIMAR | Saldos y movimientos - Reporte'

    partner_id = fields.Many2one(
        'res.partner',
        string='Cliente',
    )

    fecha = fields.Date()

    def generar_reporte_pdf(self):
        _logger.info('No definido')

    def generar_reporte_excel(self):
        _logger.info('Generando archivo de excel')
        data = {
            'form_data': self.read()[0]
        }
        return self.env.ref('matrimar_reporte_de_saldos_y_movimientos.action_report_saldos_y_movimientos_wizard').report_ac



0
Avatar
Descartar
Cybrosys Techno Solutions Pvt.Ltd

Hi,

There is a little confusion in your question. In the heading, you are saying that issue is in the Excel report. But in the beginning of the paragraph, you are saying that issue is with generating XML files.
Anyway you can refer the below links for both
For XML report : https://www.cybrosys.com/blog/how-to-create-and-export-xml-reports-in-odoo
For Excel reports: https://www.cybrosys.com/blog/how-to-create-excel-report-using-controller-in-odoo-15
I hope this will help you.

Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Registrar-se
Related Posts Respostes Vistes Activitat
Unable to upgrade or uninstall custom module on odoo.sh, odoo 14 enterprise version.
enterprise odoo.sh v14
Avatar
0
de juny 21
4249
odoo.sh getting error on commit any changes
enterprise odoo.sh v14 Odoo.sh
Avatar
0
de març 22
3750
Validating invoice - Failed to load the document 'SiiTypes_v10.xsd'
invoice enterprise odoo.sh v14
Avatar
0
de jul. 21
3871
Multi language Invoice documents
odoo.sh v14
Avatar
Avatar
1
d’ag. 24
4414
Odoo 14 credit notes return invoiced products in sale order
enterprise v14
Avatar
Avatar
Avatar
Avatar
Avatar
4
de jul. 24
5784
Community
  • Tutorials
  • Documentació
  • Fòrum
Codi obert
  • Descarregar
  • GitHub
  • Runbot
  • Traduccions
Serveis
  • Allotjament a Odoo.sh
  • Suport
  • Actualització
  • Desenvolupaments personalitzats
  • Educació
  • Troba un comptable
  • Troba un partner
  • Converteix-te en partner
Sobre nosaltres
  • La nostra empresa
  • Actius de marca
  • Contacta amb nosaltres
  • Llocs de treball
  • Esdeveniments
  • Pòdcast
  • Blog
  • Clients
  • Informació legal • Privacitat
  • Seguretat
الْعَرَبيّة 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 Svenska ภาษาไทย Türkçe українська Tiếng Việt

Odoo és un conjunt d'aplicacions empresarials de codi obert que cobreix totes les necessitats de la teva empresa: CRM, comerç electrònic, comptabilitat, inventari, punt de venda, gestió de projectes, etc.

La proposta única de valor d'Odoo és ser molt fàcil d'utilitzar i estar totalment integrat, ambdues alhora.

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