Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
1 Ответить
2728 Представления

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?


Аватар
Отменить
Лучший ответ

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

Аватар
Отменить

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',
}

Автор

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

Related Posts Ответы Просмотры Активность
2
июл. 24
7727
2
мая 23
6016
2
мая 23
7339
0
мар. 22
101
2
февр. 22
3703