Fix POS blank screen in order channel panel

This commit is contained in:
metatroncubeswdev 2026-05-06 14:01:40 -04:00
parent 10509df3fa
commit 215b5804e5
2 changed files with 2 additions and 4 deletions

View File

@ -2,7 +2,6 @@
import { Component, useState } from "@odoo/owl"; import { Component, useState } from "@odoo/owl";
import { usePos } from "@point_of_sale/app/store/pos_hook"; import { usePos } from "@point_of_sale/app/store/pos_hook";
import { useService } from "@web/core/utils/hooks";
import { jsonrpc } from "@web/core/network/rpc_service"; import { jsonrpc } from "@web/core/network/rpc_service";
/** /**
@ -17,7 +16,6 @@ export class ChannelPanel extends Component {
setup() { setup() {
this.pos = usePos(); this.pos = usePos();
this.dialog = useService("dialog");
this.SOURCE_LABELS = { this.SOURCE_LABELS = {
walk_in: 'Walk-In', walk_in: 'Walk-In',
@ -67,7 +65,7 @@ export class ChannelPanel extends Component {
} }
get showPanel() { get showPanel() {
return this.pos.config.show_channel_panel; return this.pos?.config?.show_channel_panel !== false;
} }
// --- Source Selector --- // --- Source Selector ---

View File

@ -140,7 +140,7 @@
</t> </t>
<!-- Inject ChannelPanel into the left pane of ProductScreen, above OrderWidget --> <!-- Inject ChannelPanel into the left pane of ProductScreen, above OrderWidget -->
<t t-name="point_of_sale.ProductScreen" <t t-name="dine360_order_channels.ProductScreenExtension"
t-inherit="point_of_sale.ProductScreen" t-inherit="point_of_sale.ProductScreen"
t-inherit-mode="extension" owl="1"> t-inherit-mode="extension" owl="1">
<xpath expr="//div[hasclass('leftpane')]//OrderWidget" position="before"> <xpath expr="//div[hasclass('leftpane')]//OrderWidget" position="before">