Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odpovědět
2723 Zobrazení

Hello odooers,

I want to  Create a wizard that can select single/multiple products and dates then it will produce a pdf report that contains its product move.
The report should contain Date, Reference(WH/in or out or inventory adjustment), sale price, cost price, customer/vendor name, stock in, out, balance.
The sample report format is given below.

        Any one has any idea how doing this?


Avatar
Zrušit
Nejlepší odpověď

Hello alfik,


you can put below code inside save method of your wizard to print report..

Find code in comment.

If you want us to customise this report please don't hesitated to contact us.

Thanks & Regards,
Email: odoo@aktivsoftware.com
Skype: kalpeshmaheshwari

Avatar
Zrušit

class MyWizard(models.Model):
_name = 'my.wizard'

@api.multi
def action_confirm(self):
context = {
'lang': 'en_US',
'active_ids': [self.id],
'tz': False,
'uid': 1
}
return {
'context': context,
'data': None,
'type': 'ir.actions.report.xml',
'report_name': 'module_name.report_template_id',
'report_type': 'qweb-pdf',
'report_file': 'module_name.report_template_id',
'name': 'product_report',
}

class MyWizard(models.Model):
_name = 'my.wizard'

@api.multi
def action_confirm(self):
context = {
'lang': 'en_US',
'active_ids': [self.id],
'tz': False,
'uid': 1
}
return {
'context': context,
'data': None,
'type': 'ir.actions.report.xml',
'report_name': 'module_name.report_template_id',
'report_type': 'qweb-pdf',
'report_file': 'module_name.report_template_id',
'name': 'product_report',
}

Autor

Hello jainesh ,
Thanks for Your help.
can you explain this codes?

Related Posts Odpovědi Zobrazení Aktivita
2
čvc 24
7719
2
kvě 23
6011
2
kvě 23
7337
0
bře 22
101
2
úno 22
3701