Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ADD] pos_receipt_usability : new module to improve the display of the receipt screen #1210

Open
wants to merge 1 commit into
base: 16.0
Choose a base branch
from

Conversation

legalsylvain
Copy link
Contributor

pos_receipt_usability

This module extends the functionality of point of sale module, improving the display of the receipt screen.

Without the module

without_module

With the module

with_module

@legalsylvain legalsylvain added this to the 16.0 milestone Jul 1, 2024
@legalsylvain legalsylvain marked this pull request as draft July 1, 2024 14:56
@legalsylvain legalsylvain force-pushed the 16.0-ADD-pos_receipt_usability branch from 6bfa30d to d0159be Compare July 1, 2024 14:59
@legalsylvain
Copy link
Contributor Author

Note :

Technically, I tried to use the not very documented position="move" instead of replacing and adding code, but it doesn't seems to work in such type of view. Any help welcome if you know how to do it. CC : @OCA/web-maintainers / @OCA/pos-maintainers

    <t
        t-name="ReceiptScreen"
        t-inherit="point_of_sale.ReceiptScreen"
        t-inherit-mode="extension"
        owl="1"
    >
        <xpath expr="//div[hasclass('notice')]" position="after">
            <div class="next-order-placeholder">
                <xpath
                    expr="//div[hasclass('next') and hasclass('validation')]"
                    position="move"
                />
            </div>
        </xpath>
    </t>

@legalsylvain
Copy link
Contributor Author

Answered : The problem was that position="move" only work with a direct child. So, that design works :

        <xpath expr="//div[hasclass('notice')]" position="after">
            <div class="next-order-placeholder" />
        </xpath>

        <xpath expr="//div[hasclass('next-order-placeholder')]" position="inside">
            <xpath
                expr="//div[hasclass('next') and hasclass('validation')]"
                position="move"
            />
        </xpath>

Ref : feature added here odoo/odoo#23877
documentation updated here : odoo/odoo@aabe35c

@legalsylvain legalsylvain force-pushed the 16.0-ADD-pos_receipt_usability branch 2 times, most recently from 327063d to 1b95af3 Compare July 2, 2024 07:38
@legalsylvain legalsylvain marked this pull request as ready for review July 2, 2024 09:26
@legalsylvain legalsylvain force-pushed the 16.0-ADD-pos_receipt_usability branch from 1b95af3 to 16e1fc7 Compare July 2, 2024 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants