mirror of
https://github.com/OCA/reporting-engine.git
synced 2025-02-16 16:30:38 +02:00
Fix report_xlsx for printing from wizards
This commit is contained in:
committed by
Alex Cuellar
parent
498fd57c87
commit
fcc3c36c56
@@ -14,9 +14,14 @@ ActionManager.include({
|
||||
if (cloned_action.report_type === 'xlsx') {
|
||||
framework.blockUI();
|
||||
var report_xlsx_url = 'report/xlsx/' + cloned_action.report_name;
|
||||
if(cloned_action.context.active_ids){
|
||||
report_xlsx_url += '/' + cloned_action.context.active_ids.join(',');
|
||||
}else{
|
||||
if (_.isUndefined(cloned_action.data) ||
|
||||
_.isNull(cloned_action.data) ||
|
||||
(_.isObject(cloned_action.data) && _.isEmpty(cloned_action.data)))
|
||||
{
|
||||
if(cloned_action.context.active_ids) {
|
||||
report_xlsx_url += '/' + cloned_action.context.active_ids.join(',');
|
||||
}
|
||||
} else {
|
||||
report_xlsx_url += '?options=' + encodeURIComponent(JSON.stringify(cloned_action.data));
|
||||
report_xlsx_url += '&context=' + encodeURIComponent(JSON.stringify(cloned_action.context));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user