mirror of
https://github.com/bringout/oca-ocb-vertical-industry.git
synced 2026-04-23 20:32:04 +02:00
19.0 vanilla
This commit is contained in:
parent
4607ccbd2e
commit
825ff6514e
487 changed files with 184979 additions and 195262 deletions
|
|
@ -1,17 +1,15 @@
|
|||
/** @odoo-module */
|
||||
|
||||
import { patch } from '@web/core/utils/patch';
|
||||
import { registry } from '@web/core/registry';
|
||||
|
||||
import { kanbanView } from '@web/views/kanban/kanban_view';
|
||||
import { KanbanRecord } from '@web/views/kanban/kanban_record';
|
||||
import { KanbanRenderer } from '@web/views/kanban/kanban_renderer';
|
||||
import { KanbanController } from '@web/views/kanban/kanban_controller';
|
||||
|
||||
import { LunchDashboard } from '../components/lunch_dashboard';
|
||||
import { LunchRendererMixin } from '../mixins/lunch_renderer_mixin';
|
||||
|
||||
import { LunchSearchModel } from './search_model';
|
||||
|
||||
import { LunchSearchPanel } from './search_panel';
|
||||
|
||||
export class LunchKanbanRecord extends KanbanRecord {
|
||||
onGlobalClick(ev) {
|
||||
|
|
@ -19,9 +17,16 @@ export class LunchKanbanRecord extends KanbanRecord {
|
|||
}
|
||||
}
|
||||
|
||||
export class LunchKanbanRenderer extends KanbanRenderer {
|
||||
export class LunchKanbanRenderer extends LunchRendererMixin(KanbanRenderer) {
|
||||
static template = "lunch.KanbanRenderer";
|
||||
static components = {
|
||||
...LunchKanbanRenderer.components,
|
||||
LunchDashboard,
|
||||
KanbanRecord: LunchKanbanRecord,
|
||||
};
|
||||
|
||||
getGroupsOrRecords() {
|
||||
const {locationId} = this.env.searchModel.lunchState;
|
||||
const { locationId } = this.env.searchModel.lunchState;
|
||||
if (!locationId) {
|
||||
return [];
|
||||
} else {
|
||||
|
|
@ -30,17 +35,19 @@ export class LunchKanbanRenderer extends KanbanRenderer {
|
|||
}
|
||||
}
|
||||
|
||||
patch(LunchKanbanRenderer.prototype, 'lunch_kanban_renderer_mixin', LunchRendererMixin);
|
||||
|
||||
LunchKanbanRenderer.template = 'lunch.KanbanRenderer';
|
||||
LunchKanbanRenderer.components = {
|
||||
...LunchKanbanRenderer.components,
|
||||
LunchDashboard,
|
||||
KanbanRecord: LunchKanbanRecord,
|
||||
class LunchKanbanController extends KanbanController {
|
||||
get modelOptions() {
|
||||
return {
|
||||
...super.modelOptions,
|
||||
lazy: false,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
registry.category('views').add('lunch_kanban', {
|
||||
...kanbanView,
|
||||
Controller: LunchKanbanController,
|
||||
Renderer: LunchKanbanRenderer,
|
||||
SearchModel: LunchSearchModel,
|
||||
SearchPanel: LunchSearchPanel,
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue