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

[IMP] portal: add street2 to user details page #162355

Conversation

khpa-odoo
Copy link
Contributor

@khpa-odoo khpa-odoo commented Apr 18, 2024

This PR adds the field Street 2 in the view of user details which is rendered by the route /my/account.
(My Account -> Addresses)

It also reorganizes some fields in portal_my_details_fields to make them more organized as in below structure:

- Street                    - City
- Street 2                  - State / Province
- Zip / Postal Code         - Country

Additional:
This PR replaces the style attribute used in option tag to set property display: none, with the bootstrap class d-none.

Task-3875163

@robodoo
Copy link
Contributor

robodoo commented Apr 18, 2024

@C3POdoo C3POdoo added the RD research & development, internal work label Apr 18, 2024
@khpa-odoo khpa-odoo force-pushed the master-imp-portal-add-street2-details-page-khpa branch from 65e2af5 to 799ebb3 Compare April 19, 2024 06:00
@spe-odoo
Copy link
Contributor

Hey @khpa-odoo,

LGTM 😃

Just a small change. You can update the description of the pr

It also reorganizes some fields in `portal_my_details_fields` to make them
more organized as the below structure

- Street                    - City
- Street 2                  - State / Province
- Zip / Postal Code         - Country

<select name="state_id" t-attf-class="form-select #{error.get('state_id') and 'is-invalid' or ''}">
<option value="">select...</option>
<t t-foreach="states or []" t-as="state">
<option t-att-value="state.id" style="display:none;" t-att-data-country_id="state.country_id.id" t-att-selected="state.id == int(state_id) if state_id else state.id == partner.state_id.id">
Copy link
Contributor

Choose a reason for hiding this comment

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

Hello @khpa-odoo 😄
As we're updating those lines anyway, we could probably use the opportunity to change the ugly style="display:none;" to a d-none class ? 🙂
Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hello @amdi-odoo 😊
Sure! Updated the code 👍

Copy link
Contributor

@amdi-odoo amdi-odoo Apr 24, 2024

Choose a reason for hiding this comment

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

Hello again 😄
d-none isn't dynamic (no use of variables) so simply a class instead of the t-att-class should do it 😄
Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done : )

@khpa-odoo khpa-odoo force-pushed the master-imp-portal-add-street2-details-page-khpa branch from 799ebb3 to 86078b0 Compare April 24, 2024 14:06
This commit adds the field `Street 2` in  the view of user details
which is rendered by the route '/my/account' (My Account -> Addresses).

It also reorganizes some fields in `portal_my_details_fields` to make them
more organized.

Additional:
This commit replaces the style attribute used in `option` tag to
set property `display: none`, with the bootstrap class `d-none`.

Task-3875163
@khpa-odoo khpa-odoo force-pushed the master-imp-portal-add-street2-details-page-khpa branch from 86078b0 to 49c6790 Compare April 25, 2024 04:59
@tde-banana-odoo tde-banana-odoo marked this pull request as ready for review April 25, 2024 10:38
@tde-banana-odoo
Copy link
Contributor

@robodoo r+

@C3POdoo C3POdoo requested a review from a team April 25, 2024 10:40
robodoo pushed a commit that referenced this pull request Apr 25, 2024
This commit adds the field `Street 2` in  the view of user details
which is rendered by the route '/my/account' (My Account -> Addresses).

It also reorganizes some fields in `portal_my_details_fields` to make them
more organized.

Additional:
This commit replaces the style attribute used in `option` tag to
set property `display: none`, with the bootstrap class `d-none`.

Task-3875163

closes #162355

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
robodoo pushed a commit that referenced this pull request Apr 25, 2024
This commit adds the field `Street 2` in  the view of user details
which is rendered by the route '/my/account' (My Account -> Addresses).

It also reorganizes some fields in `portal_my_details_fields` to make them
more organized.

Additional:
This commit replaces the style attribute used in `option` tag to
set property `display: none`, with the bootstrap class `d-none`.

Task-3875163

closes #162355

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
robodoo pushed a commit that referenced this pull request Apr 25, 2024
This commit adds the field `Street 2` in  the view of user details
which is rendered by the route '/my/account' (My Account -> Addresses).

It also reorganizes some fields in `portal_my_details_fields` to make them
more organized.

Additional:
This commit replaces the style attribute used in `option` tag to
set property `display: none`, with the bootstrap class `d-none`.

Task-3875163

closes #162355

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
@robodoo robodoo closed this Apr 25, 2024
@robodoo robodoo added the 17.3 label Apr 25, 2024
zel-odoo pushed a commit to odoo-dev/odoo that referenced this pull request Apr 29, 2024
This commit adds the field `Street 2` in  the view of user details
which is rendered by the route '/my/account' (My Account -> Addresses).

It also reorganizes some fields in `portal_my_details_fields` to make them
more organized.

Additional:
This commit replaces the style attribute used in `option` tag to
set property `display: none`, with the bootstrap class `d-none`.

Task-3875163

closes odoo#162355

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
17.3 RD research & development, internal work
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants