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

[17.0][IMP] crm_lead_code: space get removed when other view changes name field #601

Merged
merged 1 commit into from
Oct 25, 2024

Conversation

CRogos
Copy link

@CRogos CRogos commented Oct 11, 2024

I have another module which extends the same view like this:

    <record id="crm_case_kanban_view_leads" model="ir.ui.view">
        <field name="name">crm.show.fields</field>
        <field name="model">crm.lead</field>
        <field name="inherit_id" ref="crm.crm_case_kanban_view_leads" />
        <field name="arch" type="xml">
            <field name="name" position="attributes">
                <attribute name="invisible">1</attribute>
            </field>
            <field name="name" position="after">
                <field name="display_name" />
            </field>
        </field>
    </record>

This causes that the space (&nbsp;) after the code field is somehow removed.
image
image

This change prevents this side effect.

@CRogos CRogos changed the title [IMP] crm_lead_code: space get removed when other view changes name field [17.0][IMP] crm_lead_code: space get removed when other view changes name field Oct 11, 2024
Copy link

@MohamedOsman7 MohamedOsman7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@@ -48,7 +48,7 @@
<field name="inherit_id" ref="crm.crm_case_kanban_view_leads" />
<field name="arch" type="xml">
<field name="name" position="before">
<field name="code" />&amp;nbsp;
<field name="code" /><span> </span>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, thanks for this PR.
IMHO <span/> should be better

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

<span/> does not add the extra SPACE.
Or is there a css class which we could apply?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok found a solution: <span class="p-1" />
thank you for your feedback.

@CRogos CRogos force-pushed the 17.0-fix-crm_lead_code-spacing branch from b687605 to 448b9f5 Compare October 25, 2024 07:44
Copy link
Member

@flotho flotho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi,
Thanks, much better!

@CRogos
Copy link
Author

CRogos commented Oct 25, 2024

@pedrobaeza would you merge?

@OCA-git-bot
Copy link
Contributor

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

@pedrobaeza pedrobaeza added this to the 17.0 milestone Oct 25, 2024
@pedrobaeza
Copy link
Member

/ocabot merge minor

@OCA-git-bot
Copy link
Contributor

This PR looks fantastic, let's merge it!
Prepared branch 17.0-ocabot-merge-pr-601-by-pedrobaeza-bump-minor, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 0ca71ef into OCA:17.0 Oct 25, 2024
7 checks passed
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at 5aca41d. Thanks a lot for contributing to OCA. ❤️

@CRogos CRogos deleted the 17.0-fix-crm_lead_code-spacing branch October 28, 2024 07:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants