Siirry sisältöön
Menu
Sinun on rekisteröidyttävä, jotta voit olla vuorovaikutuksessa yhteisön kanssa.
Tämä kysymys on merkitty
2457 Näkymät

Hello Guys ! please i need help ! how can i pass the search Panel in this action js . In XML we can do it with search_view_id params in action but with js how can i do it  ?? Thanks 


/** @odoo-module */
import { ListController } from "@web/views/list/list_controller";
import { registry } from '@web/core/registry';
import { listView } from '@web/views/list/list_view';



export class ProductListController extends ListController {
setup() {
super.setup();
}

redirect_to_product_pack() {
this.actionService.doAction({
type: 'ir.actions.act_window',
name: 'Forfaits',
res_model: 'product.template',
views: [[false, 'tree'], [false, 'form']],
domain: [['pack_ok', '=', true]],
target: 'current',
context: {
default_pack_ok: true,
default_pack_type: 'detailed',
default_pack_component_price: 'detailed',
default_pack_modifiable: false,
},
});
}

}

registry.category("views").add("button_in_tree1", {
...listView,
Controller: ProductListController,
buttonTemplate: "idpa_pack.ListButtons",
});

Avatar
Hylkää
Aiheeseen liittyviä artikkeleita Vastaukset Näkymät Toimenpide
1
huhtik. 25
1387
Odoo App Ratkaistu
1
marrask. 23
1960
0
toukok. 24
1687
0
syysk. 23
2645
0
syysk. 23
2257