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

[MIG] website_event_snippet_calendar: Migration to 13.0 #191

Conversation

ajaniszewska-dev
Copy link

@ajaniszewska-dev ajaniszewska-dev commented Sep 28, 2020

current status:
image

elements marked in red doesn't work:
snippet

@ajaniszewska-dev ajaniszewska-dev mentioned this pull request Sep 28, 2020
29 tasks
@pedrobaeza
Copy link
Member

Please preserve commit history following technical method explained in https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-13.0.

If the jump is between several versions, you have to modify the source branch in the main command to accommodate it to this circumstance.

@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch from 65709f2 to 1653b00 Compare September 28, 2020 14:17
@pedrobaeza
Copy link
Member

Still without commit history and with red Travis. What doubts do you have?

@ajaniszewska-dev
Copy link
Author

Still without commit history and with red Travis. What doubts do you have?

will fix it today.

yajo and others added 12 commits September 29, 2020 10:59
…list (OCA#101)

Allows the user to display a calendar combined with a list of events.

Includes controllers for such information to be bundled into any page through an `<iframe>`.
Before this patch, the user was getting the Public User's TZ on the
calendar view.

After merged, only the event's timzeone will be used to display dates.

It is, however, affected by odoo/odoo#27179,
which means that there is a possible mismatch between the date used
to search and the one used to display, most likely to be hit when
events have very different timzeones. Added to Known Issues.
Co-Authored-By: Jairo Llopis <Yajo@users.noreply.github.com>
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: event-12.0/event-12.0-website_event_snippet_calendar
Translate-URL: https://translation.odoo-community.org/projects/event-12-0/event-12-0-website_event_snippet_calendar/
These controllers were ignoring the `website_lang` cookie because they were not enabled for website. Thus, event results were downloaded in default language instead of the current one.

@Tecnativa TT20711
Pretty obvious things missing from BS4 migration.

@Tecnativa TT17632
@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch 2 times, most recently from 15d47bf to c39ddf8 Compare September 29, 2020 09:16
@pedrobaeza pedrobaeza added this to the 13.0 milestone Sep 29, 2020
@pedrobaeza
Copy link
Member

Great, thanks. Let's see the Travis result.

@ajaniszewska-dev
Copy link
Author

Great, thanks. Let's see the Travis result.

@pedrobaeza failing, but that's fine, will fix it, test and switch PR to 'Ready for review' when work will be done, for now let's keep it in draft so it is ok to fail.
feel free to comment, any suggestions are welcome.

@pedrobaeza
Copy link
Member

OK, I can't say about the content itself, only the procedure.

@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch 4 times, most recently from f6260ee to 7518e3a Compare October 2, 2020 14:35
@ajaniszewska-dev ajaniszewska-dev marked this pull request as ready for review October 6, 2020 13:21
@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch from 7518e3a to ace063f Compare October 7, 2020 14:50
@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch from ace063f to cb38087 Compare October 8, 2020 09:43
var DATETIME_FORMAT = time.strftime_to_moment_format("%Y-%m-%d %H:%M:%S");
var DATETIME_FORMAT = time.strftime_to_moment_format("%Y-%M-%D %H:%m:%s");
Copy link
Member

Choose a reason for hiding this comment

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

I doubt very much this change is good.

element.date_begin = date_begin_located.format(this.date_format);
Element.date_begin = date_begin_located.format(this.date_format);
Copy link
Member

Choose a reason for hiding this comment

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

This should be a bug also.

Comment on lines +67 to +83
<template id="snippet_options" inherit_id="website.snippet_options">
<xpath expr=".">
<!-- Allow to add or remove events from the list -->
<div
data-js="website_event_snippet_calendar_list"
data-selector=".s_event_calendar_list:has(.js_amount)"
>
<li data-only="click" data-increase="1">
<a tabindex="-1"><i class="fa fa-plus" /> Add one event</a>
</li>
<li data-only="click" data-increase="-1">
<a tabindex="-1"><i class="fa fa-minus" /> Remove one event</a>
</li>
</div>
</xpath>
</template>
</odoo>
Copy link
Member

Choose a reason for hiding this comment

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

You need to fix this template and adapt it to the new format in v13 to make it work. It's broken as you said.

Copy link
Author

Choose a reason for hiding this comment

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

any hint where the problem lies with this template?

Copy link
Member

Choose a reason for hiding this comment

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

Well.. you'll have to take a look at how website snippets are added in upstream website for v13 and try to imitate that method here.

@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch 2 times, most recently from 0d4d8b8 to 4063493 Compare October 16, 2020 06:59
@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch from 4063493 to fd05d59 Compare October 22, 2020 13:48
@grindtildeath
Copy link

@ajaniszewska-dev Seems you still have to fix pre-commit here

@ajaniszewska-dev ajaniszewska-dev force-pushed the 13.0-mig-website_event_snippet_calendar branch from fd05d59 to 5f06028 Compare October 23, 2020 11:16
@pedrobaeza
Copy link
Member

Superseded by #213

@pedrobaeza pedrobaeza closed this May 11, 2021
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.

None yet

8 participants