Commit Graph
260 Commits
Author SHA1 Message Date
fja-odoo 424adb63e3 [IMP] gamification, *: remove KarmaError
* = stock, test_website, web, website_forum, website_slides, base

Replace KarmaError with AccessError and remove the related override made
on crash_manager and ir_http.

task-2069890

closes odoo/odoo#36655

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-09-12 13:49:02 +00:00
Lucas Lefevre 290341b455 [FIX] website_slides: still another fix of computed fields
This commit fixes 2 issues coming from the recent ORM changes: records are
new records in onchange and compute methods must assign a value for all records.

In an onchange method, self.ids is a list of integer (real records)
whereas self.id is a NewId (virtual record)

Here a result dict was built using the reals ids as keys but later NewIds
are used as keys. Solution is to use record._origin to access the real record.

Moreover, the two dicts `result` and `type_stats` are the same. Assigning one
into the other is useless.

Task 2067872 (eLearning internal testing)
PR #36756
2019-09-13 10:05:43 +00:00
Thibault Delavallée 0eec4d22a2 [FIX] website_slides: avoid admin being twice member of courses
Since admin is responsible of all created demo channels and then re-added
manually as member in demo data of slide.channel.partner he is actually
twice member of some channels. This commit fixes that by resetting its
membership status before adding membership demo data.

PR #36756
2019-09-13 10:05:43 +00:00
Thibault Delavallée 477b73ed31 [FIX] website_slides: make content stat button redirection match counters
Course content counters count only published content while content stat button
redirects to all contents. Solution to this mismatch is to apply a search
filter on button action to display published ontent by default.

Also remove unnecessary action. Using a type="edit" seems sufficient, no need
to define a python method just for that purpose.

Task 2067324 (counters / action on content mismatch)
PR #36756
2019-09-13 10:05:15 +00:00
mcm-odoo 3e4b0f3200 [IMP] website_slides: improve slides backend views
This commit improves a bit the existing backend views of the elearning
app (notably propagating content and course labeling instead of slide and
channel) and adds a pivot view for model slide.slide.

FP feedback

Task 2066646
2019-09-11 09:16:26 +00:00
Michaël Mattiello 8c9473fd78 [IMP] website_slides_{*}: improve backend UI, views and user actions
Purpose of this commit is to perform a back2basics on eLearning backend
views. It helps users in their daily use of eLearning and improve UI.

Containing

  * channel kanban view tweaking;
  * channel form view: some spacing and renaming improvements. Also set
    advanced field (new content email, share template) as group no one;

  * slide kanban view tweaking;
  * removed sections from kanban and list view for contents;
  * contents form view: various improvements, with notably

    * removed field website_url;
    * set publishded date is now readonly, tracked and in group_no_one as
      it is automatically set when publishing the lesson, and people should
      not update it manually;
    * removed the sum "Content" and replaced it by a stat button
    * reword quiz constraint error messages;

  * rating views improvements:
    * revamped the kanban view of rating that were a bit broken;
    * added a pivot view in Reporting/Reviews;
    * updated graph view in Reporting/Reviews;

This commit also provides some usability fixes

  * prevent sending email if new content is category;
  * email: Prevent displaying an image if there is no image;

LINKS

Task 2049640 (website slides back2basics and fiximp)
Task 2058595 (eLearning v13 testing)
2019-09-03 15:02:21 +00:00
laaandMichaël Mattiello c4eba6f5b1 [FIX] website_slides: correctly set sequence of newly added content
Purpose of this commit is to add new content at last position in frontend.
Indeed backend uses last position in embedded list view, frontend should
do the same. Moreover when having a lot of content, having everything at
the bottom of the screen at the same position of Add content / section
buttons makes sens.

Specifications

  * when adding a new category: add it as last category;
  * when adding a new slide in a category: add it as last slide of the
    category;

Specific case of slide without category

  * when adding a new slide without category: add it as last slide of the
    channel (display it as last) but keep it on top in backend view
    (display as first);

Improve content list display in frontend of eLearning

  * contents without section are now at the bottom;
  * fixed alignment of buttons icon (Add Content and Add Section)
  * fixed broken design because of title too long

Task 2049640 (website slides back2basics and fiximp)
Task 2061672 (new content bug report)

Co-Authored-By: Michaël Mattiello <mcm@odoo.com>
Co-Authored-By: Alexis Lacroix <laa@odoo.com>
2019-09-03 15:02:18 +00:00
Thibault Delavallée 3c95299018 [FIX] website_slides: always initialize computed fields
Creating channels and slides in backend was leading to warnings and/or crashes
because of computed fields not being always updated. With new computed fields
coming from 9920f20e4c this cannot be done anymore.

Task ID 2058595
PR #36281
2019-08-30 15:06:00 +00:00
Thibault Delavallée f93064606f [FIX] website_slides{_*}: fix completion computation, notably with certifications
PURPOSE

Test frontend and UI tools of eLearning.

SPECIFICATIONS

Since 9920f20e4c course completion when finishing a certification survey
is broken. Indeed channel completion is not correctly recomputed. A
certification course can therefore never be completed and awarded. This
commit fixes that and correctly update channel completion based on survey.

In this commit we also rename some methods

  * _compute_completion: renamed to _recompute_completion to avoid naming issue
    with computed field convention;
  * _post_completion_hook is not unnecessary as code in hr_skill can be done
    after calling super of _recompute_completion;
  * _completed_callback is renamed to _set_completed_callback to be coherent
    with slides naming;

LINKS

Task ID 1937768
2019-08-28 13:27:58 +00:00
mcm-odoo bc9c2aef16 [IMP] website_slides: improve and fix email templates
This commit improves the email that the members get when a new content
is published on the course and prevents the template to crash on preview.

task-1985511
2019-08-22 13:09:49 +00:00
mcm-odoo 453b9d5648 [IMP] website_slides: make member follower of a course
when a user subscribe to a course, the user is now automatically
follower of the course in order to be notified when a new content
is published

task-1985511
2019-08-22 11:51:58 +00:00
Sébastien Theys 1e8b9254f5 [IMP] website, website_slides: adapt get_base_url for website
On `website` itself there is no `website_id` so the domain has to be read from
`self` directly.

Also oversight of forward-port 039e6bae99:
On `slide.channel` the override that was done in an earlier version is doing the
same as the generic override that was introduced later, so it can be removed.

closes odoo/odoo#35839

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-08-20 10:45:54 +00:00
Raphael Collet 9920f20e4c [IMP] models: ORM speedup
This branch is the combination of several optimizations in the ORM:

* store field values once in the cache: the cache reflects more
faithfully the database, only fields that explicitly depend on the
context have an extra indirection in the cache;

* delay recomputations by default: use method `recompute` to explicitly
flush out pending recomputations;

* delay updates in method `write`: updates are stored in a data
structure that can be flushed efficiently to the database with method
`flush` (which also flush out recomputations);

* make method `modified` take advantage of inverse fields to inverse
dependencies;

* filter records by evaluating a domain on records in Python;

* a computed field with `readonly=False` behaves like a normal field
with an onchange method;

* computed fields are computed in superuser mode by default.

Work done by Toufik Ben Jaa, Raphael Collet, Denis Ledoux and Fabien
Pinckaers.

closes odoo/odoo#35659

Signed-off-by: Denis Ledoux <beledouxdenis@users.noreply.github.com>
2019-08-20 12:43:59 +00:00
Aurélien Warnon 5e4f37a1f8 [REF] website_slides: remove index_content field from slide.slide
The 'index_content' field was only filled when uploading from the frontend.
That would lead to inconsistent results when creating/updating 'presentation' slides from the slide.slide form view.
The field was also not cleaned if the slide content changed.

As it's usage was not very clear (only on a 'search', and not very intuitive), we simply removed the field.
2019-08-12 15:40:36 +00:00
Aurélien Warnon 5269d8c27f [REF] website_slides: improve duration computation of a slide/course
The completion time of a slide now has default values for slides of type

  * video (duration of the YouTube video);
  * PDF (number of pages * 5 minutes);

This computation is done when uploading a slide in frontend or by an onchange
in backend. Field can still be given / modified by elearning people as
result may not be reliable (pdf parsing is not accurate, and/or you may
estimate time differently from strict page-based computation).

The course will sum up all durations of its (active) slides. Display has been
changed from "x minutes" to "x hours y minutes".

Task ID 2007294
2019-08-12 15:40:36 +00:00
Jérémy Hennecart 2af9570c5b [IMP] website_slides: remove archived slides from completion / statistics
Task 2007294
2019-08-12 15:40:36 +00:00
ryv-odoo 9c1f2f87ef [IMP] website_slides: allow to remove attendees
PURPOSE

Improve attendees management by adding a button to remove them in backend
of eLearning.

SPECIFCIATIONS

In order to easily remove a attendee from a channel, we add a button in
the slide_channel_partner tree view, accessible from channels (attendees).
Remove a slide_channel_partner implies to remove the related slide_slide_partner.
Also code backtracking for the view of attendees of a course: we redirect
to the slide.channel.partner model instead of res.parter because
we want the possibility to create/remove/edit attendees for a
course and not making action on res.partner model itself.

Task ID 2045620
2019-08-12 15:40:36 +00:00
qmo-odoo 6e6b635557 [IMP] website_slides: improve slide.slide (lesson) code and view
PURPOSE

Improve daily use of slide, especially in backend.

SPECIFICATIONS

Make slide type editable in backend, notably at create. This commit makes it
possible for the user to manually define the type of the slide.

Slightly clean slide code about slide data.

LINKS

Task 1978731
PR #33255
2019-08-08 08:29:34 +00:00
qmo-odoo 340613d068 [REF] website_slides: revamp channel form view
PURPOSE

Like already done for sale order, invoice of survey, purpose of this commit
is to remove category model and replace by a flagged line (slide). It allows
to easily reorder slides in an embedded list view.

SPECIFICATIONS

This commit completely reworks the slide.channel form view

  * improve the content management from the form itself by adding a tree view
    with the possibility of drag and dropping slides from category to category.
    This tree view has buttons to quickly add content or certification. It
    also allow to add a category (slide with flag is_category) without opening
    a modal;
  * reorder tabs and fields, improve some labels;
  * add a custom float field widget to display ratings as stars;
  * add stat button for partners who completed/certified ;the course
  * add stat button that redirects to the forum posts;
  * add stat button that redirects to the channel reviews;

LINKS

Task 1978731
PR #33255
2019-08-08 08:29:34 +00:00
qmo-odoo b180c66a80 [REF] website_slides: replace slide.category by slide with is_category flag
PURPOSE

Like already done for sale order, invoice of survey, purpose of this commit
is to remove category model and replace by a flagged line (slide). It allows
to easily reorder slides in an embedded list view.

SPECIFICATIONS

Instead of having a fully fledged slide.category model, slide.slide will serve
that purpose with a is_category flag. This will allow to drag and drop slides
and sections in the channel form view.

This change had an impact on the way slides were added/sorted on the front-end.
In fact, whenever a slide is added from the front-end, a resequencing of all
the slides in the course has to be triggered.

Category of a slide is now a computed field based on the sequence. Order
of slides is based on sequence, with categories splitting the slide list based
on is_category flag.

In this commit tests are added. Some cleaning in tests is also performed to
speedup a bit tests (savepointcase) and some cleaning / renaming to ease
their understanding.

Future commit will add JS necessary to manage slides in the section list view.

LINKS

TaskID: 1978731
PR: #33255
2019-08-08 08:29:34 +00:00
qmo-odoo b37243b85f [FIX] website_slides: fix crashes on channel creation/edit
SPECIFICATIONS

Before this commit, creating a channel would crash because of NewID key
not existing in a dictionary for compute fields. A crash would also happen
when deleting a slide from the channel form view.

LINKS

Task 1978731
PR #33255
2019-08-08 08:26:08 +00:00
Christophe Simonis 886eca0131 [IMP] *: remove usage of oldname attribute
This attribute is misleading as it is insufficient to correctly upgrade
the database. It only renames the column in the database, but other
operations are needed, like updating the corresponding `ir.model.fields`
record (and its xmlid). The default values and the translations are also
lost during the upgrade.

Moreover, this feature was misused. It was:
 - left on fields during multiple versions.
 - used on reports (SQL views). This would be ok if the feature was
   complete, but, as is, it was useless.
 - kept unchanged after a second renaming of the field (which can happen
   versions later the first rename).
 - used, even when the meaning of the field changed. i.e. the field
   `archived` has been renamed to the classic `active`, but the value
   in the database should be switched.
2019-08-05 09:36:41 +00:00
fja-odoo 5dac8f8f29 [REF] website, *: remove hardcoded image urls
* = website_forum, website_profile, website_sale,
website_sale_comparison, website_slides, website_slides_survey

Some image links were hard coded in the xml views of website, now they
are replaced with website.image_url(model, field).

Part of https://github.com/odoo/odoo/pull/34149
task-2007400

closes odoo/odoo#34149

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-08-05 13:24:22 +00:00
Jérémy HennecartandThibault Delavallée aeb23b21d3 [IMP] website_slides(_*): improve demo data and remove dummy data
PURPOSE

eLearning should have its own application in manager. Indeed this is becoming
a big application and having it embedded inside Website application is not
enough anymore. It should also hold updated and easy-to-use menus,
navigation, actions and views in backend.

SPECIFICATIONS

Remove "Our Documentation" dummy default existing data. It makes no sense
to have void data. Instead just add a small explanation text in eLearning
front-end telling the user to create its first course if he has rights to
do so.

In order to better show the new backend add some demo data for missing
numbers, notably

  * sales: add confirmed sale orders in order to have revenues value;
  * forum: add some posts and answers;
  * quiz: update slide.slide.partner demo data to hold quiz attempts count;

LINKS

Task 1978729
PR #35061

Co-Authored-By: Thibault Delavallée <tde@odoo.com>
Co-Authored-By: Jérémy Hennecart <jeh@odoo.com>
2019-08-05 08:44:09 +00:00
Jérémy HennecartandThibault Delavallée 313a7d9eb2 [ADD] mass_mailing_slides: allow to mass mail course attendees
PURPOSE

eLearning should have its own application in manager. Indeed this is becoming
a big application and having it embedded inside Website application is not
enough anymore. It should also hold updated and easy-to-use menus,
navigation, actions and views in backend.

SPECIFICATIONS

Integrate a button on slide.channel form view allowing to perform a mass
mailing on course attendees. Do a flow similar to event.

Add menu entry in menu of slide.channel kanban card after invite
  * Mail Attendees (same as on the course card and depend of the setting)

Add menu entry inside Settings
  * Settings: add an option to install module mass_mailing_slide

LINKS

Task 1978729
PR #35061

Co-Authored-By: Thibault Delavallée <tde@odoo.com>
Co-Authored-By: Jérémy Hennecart <jeh@odoo.com>
2019-08-05 08:41:27 +00:00
Thibault DelavalléeandJérémy Hennecart 98bdb241de [IMP] website_slides: add an overview (kanban view) on course model
PURPOSE

eLearning should have its own application in manager. Indeed this is becoming
a big application and having it embedded inside Website application is not
enough anymore. It should also hold updated and easy-to-use menus,
navigation, actions and views in backend.

SPECIFICATIONS

Add course (slide.channel) kanban view. Each tile should contain

  * Title of the course (make it big, o_primary)
  * Tags below the title
  * Primary button "New Lesson"
  * Statistics :
    * Attendees
    * Running (progress != 100%)
    * (if one content is certificate) Certified or Finished
  * See
    * v1: https://drive.google.com/a/odoo.com/file/d/13K8FmkbwmBG4JQ5gH3Q5T8OlWPs3blcu/view?usp=drivesdk

With FP remarks https://drive.google.com/a/odoo.com/file/d/1mb7LUT0VUNs5fMcKB9c0Bfaqk2-XFFuu/view?usp=drivesdk
  * remove globe, type and visibility of course, lessen padding between rating
    views and watch time;
  * for rating, instead of 8.00 => 5 reviews (4.5/5);
  * replace "View Lesson" / "Invite" by "View Course" => Send to the front-end
  * In the menu of the card, add:
    * Invite (same behavior than before, when it was a primary btn)
  * click on x Contents:  land on the contents, group by category with sequence
  * re-order of the 3 infos/Stats at the bottom of the card: 1. Content,
    2. Attendee, 3. Certified
    * + number: font-weight: 500 + font-size 1.2em
    * + labels: remove text-uppercase, + text-color: #666666
    * + the "whole box" is clickable

LINKS

Task 1978729
PR #35061

Co-Authored-By: Thibault Delavallée <tde@odoo.com>
Co-Authored-By: Jérémy Hennecart <jeh@odoo.com>
2019-08-05 08:40:33 +00:00
Thibault Delavallée 54192e4648 [IMP] website_slides: add a new kanban view for ratings
PURPOSE

eLearning should have its own application in manager. Indeed this is becoming
a big application and having it embedded inside Website application is not
enough anymore. It should also hold updated and easy-to-use menus,
navigation, actions and views in backend.

SPECIFICATIONS

Add in menu Courses, a new entry Reviews
  * Kanban view, full width, no default group by
    * Order by date (most recent on top)
    * See: https://drive.google.com/a/odoo.com/file/d/1IYE1QBIJa26BLugRiafyBop-srkYwndC/view?usp=drivesdk
    * add a tag for unpublished comments
    * Add the pic of the user above the stars
    * Click on card, send to front-end and able to (un)publish the comment
    * Kind of what's on the front-end:  https://drive.google.com/a/odoo.com/file/d/1e9aQSWvUM2QOynRT08XSUzIjFiGnjsv8/view?usp=drivesdk

LINKS

Task 1978729
PR #35061
2019-08-05 08:40:33 +00:00
Jérémy HennecartandThibault Delavallée 4587e6a396 [REF] website_slides: make eLearning an application with its own menu structure
PURPOSE

eLearning should have its own application in manager. Indeed this is becoming
a big application and having it embedded inside Website application is not
enough anymore. It should also hold updated and easy-to-use menus,
navigation, actions and views in backend.

SPECIFICATIONS

Update manifest and make website_slides an application separated from
website embedded menus.

Implement new menu structure

  * Courses
    * Courses
      List view: Course Name, # Views, # Attendees, # Ratings, Revenues,
      Reviews
    * Contents

  * Reporting
    * Courses: list view on slide.channel model, ordered by # views.
        * add a graph view (group by content)
    * Contents: graph view on slide.slide model
        Area Graph: X month
        Y measure: # Views (others measures: Attendees, ...)
        Group by: course (color)
    * Reviews: see kanban of latest reviews;
    * Quiz: list view on slide.question model.
        List view: Add # Quizz Trials, # Quizz Passed, Avg Attempts

  * Configuration
    * Settings
      * Allow Forum on Courses (installs website_slides_forum)
      * Allow Certifications (installs website_slides_survey)
      * Allow Selling Courses (installs website_sale_slides)
    * Course Tags
      * See channel.tags.group with label Course Tags, form view allow to
        configure group tags
      * https://drive.google.com/a/odoo.com/file/d/1G0g2UnG5cZG55EXQ5icbgwe7T2eSZskT/view?usp=drivesdk
      * On click: open :https://drive.google.com/a/odoo.com/file/d/1I_PW3aZAbrslXadiYqmVF-_6dGXx8knd/view?usp=drivesdk
    * Content Tags

This structure will gain new items in sub-modules, notably bridge with
form and website_sale. Those will be implemented in next commits.

LINKS

Task 1978729
PR #35061

Co-Authored-By: Thibault Delavallée <tde@odoo.com>
Co-Authored-By: Jérémy Hennecart <jeh@odoo.com>
2019-08-05 08:40:33 +00:00
Romain Derie 7a90dedd25 [IMP] website*: use published mixin rather than own field
*website_crm_partner_assign, website_customer

Before this commit, some models would create their own `website_published`
field rather than using the `website.published.mixin` mixin which should be
used instead.

That was done to be able to override the default value of the boolean.

This commit simply adds the possibility to override the default value of the
mixin field.

Also, help and string could simply be added on xml views rather than overriding
the field.
2019-08-03 09:51:22 +00:00
Romain Derie cc1d78a80b [IMP] *: correctly read/write website_published
The `website_published` field from the website's mixins is basically a readonly
from `is_published` field.
On read, this field will simply read `is_published` and check if the record's
website_id is accessible (only for the multi mixin).
On write, it will always write on `is_published`.

This commit improves a few things:
- A lot of code was writting on website_published which was just then writting
  on is_published. Writting directly on is_published makes more sense.
- Some backend fields would still reference `website_published` instead of
  `is_published` which would just go through the related for no reason.
  Plus, using `is_published` will make the field tooltip more accurate as we
  are not in a website context ('Visible on current website' to 'Is Published')
- Filter and search on tree view were still using the `website_published`
  related field, which is just a readonly when we are not in a frontend
  context.
- Some create and write function would have security check on
  `website_published` value but that was wrong as the user could bypass that by
  simply writting on `is_published`. For the write method, check `is_published`
  is more accurate as it will cover both case since `website_published` will
  then call the write method on `is_published`
2019-08-03 09:51:22 +00:00
Sébastien Theys 58a2ffa26f [IMP] *: rename image fields
image_original => image_1920 (now resized to 1920)
image_big => image_1024
image_large => image_256
image_medium => image_128
image_small  => image_64
image replaced by image_1920 (when writing) or by image_1024 (when displaying
	what was previously the big size)

+ add new intermediate format:
image_512

PR: #34925
2019-08-02 16:47:58 +00:00
Patrick Hoste 81c7afb833 [IMP] eLearning: adds course and certification stat button on partner
Adds two stats button on res.partner form view :
- The first one will show all the courses that the partner is following.
- The second one will show all the certifications the partner has passed.
When the partner is a company :
- All the courses followed by all the partners are shown without duplicate.
- All the certifications passed by all the partners are shown.

PR : #34908
Task ID : 2034097

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-07-31 09:54:04 +00:00
qmo-odoo 9c5e4338fb [IMP] website_slides: Slide form view revamp
This commit improves the user experience in the slide.slide
form view by reorganizing fields, renaming fields and  hiding
unnecessary fields.

This commit also introduces two  new fields:
 - comment_count: computed field that gets the number of comments on the slide
 - channel_allow_comment: Related field to the channel_id.allow_coment.
                          This field is used to hide/show unnecessary fields

TaskID: 1978736
PR: #34232
2019-07-31 08:19:01 +00:00
Patrick Hoste 38b5a666c5 [IMP] website_slides: add a share button on the fullscreen view
A share button has been added to the fullscreen view to avoid
exiting the view to access the share tab on the full description
of the slide.

Task ID : 1984509

closes odoo/odoo#33418

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-07-19 08:31:20 +00:00
qmo-odoo c90d374800 [IMP] website_slides: removed rating mixin and access token on slide model
Indeed we don't rate slides, we rate courses. Therefore rating mixin is not
necessary as well as access token.

Access token field as we are using the _mail_post_access and a karma check.

Commit linked to task 1952064.
2019-07-18 14:19:19 +00:00
Adrian Torres 4b38cc6590 [REM] *: calls to @api.multi
Multi is the default api for methods, it is not necessary to explicitly
decorate methods with it, adds clutter and most people use it because
they see that the rest of the code uses it.

Done with `find . -type f -name '*.py' | xargs sed -i '/@api.multi/d'`
2019-07-17 14:13:12 +02:00
Martin Trigaux 5d57e1862f [MERGE] Forward port of saas-12.4 to master up to beba36416f
closes odoo/odoo#34924

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-07-16 15:45:24 +00:00
Martin Trigaux beba36416f [MERGE] Forward port of saas-12.3 to saas-12.4 up to 40421be73c 2019-07-16 16:36:40 +02:00
Martin Trigaux 1f5a4649a6 [MERGE] Forward port of saas-12.3 to saas-12.4 up to 87fc1554d6
closes odoo/odoo#34820

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-07-12 13:59:35 +00:00
Martin Trigaux fd15ca1918 [MERGE] Forward port of saas-12.4 to master up to 1f5a4649a6
closes odoo/odoo#34850

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-07-15 08:12:26 +00:00
Lucas Perais (lpe) 458472485f [FIX] website_slides: statistics recompute when toggle website published
As a portal user, complete some steps within a course
Completing all of them makes the course completion to 100 %

Now, in the backend, unpublish one of these steps

Before this commit, the completion was not taking into account
that a step did not "exist" anymore i.e. has been unpublished,
leading to a completion > 100%

After this commit, we search only for steps that are published
The completion cannot exceed 100%

OPW 2033553

closes odoo/odoo#34800

Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
2019-07-11 13:40:09 +00:00
Christophe Simonis cf51b5f25d [MERGE] forward port branch saas-12.3 up to 793933a128 2019-06-25 14:23:48 +02:00
Raphael Collet c552fb7a61 [IMP] api: remove deprecated decorators 2019-07-08 13:51:35 +00:00
Raphael Collet 368e9530f4 [REF] *: record.env.user._is_XXX() -> record.env.is_XXX()
Superuser mode implies `record.env.is_XXX()`.
2019-07-04 11:32:22 +00:00
Christophe Simonis 355ef10a82 [FIX] website_slides: correctly forward-port cfa1e101e2 2019-06-21 11:55:09 +02:00
Patrick Hoste be5e8fdab8 [FIX] eLearning: allow portal user to share a slide by mail
Before, a portal user who tried to share a slide by mail got
a Odoo Server Error. He will now be able to share it without
any error.

closes odoo/odoo#34320

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-06-19 11:50:33 +00:00
Christophe Simonis 039e6bae99 [MERGE] forward port branch 12.0 up to 9c742d0c65 2019-07-05 11:13:53 +02:00
Jeremy Kerstenandqsm-odoo 0b8c430706 [FIX] website_slides: make url multi website compliant
Before this commit, all url of channel were using `web.base.url` instead of the
current website domain.

Fixes #32348

The override of `get_base_url` method should not be forward ported after
saas-12.4 as since saas-12.5 it is now a model method (f727cd2645).

closes odoo/odoo#34421

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>


Co-authored-by: qsm-odoo <qsm@odoo.com>
2019-06-28 14:36:02 +00:00
mgh-odoo 669b224f66 [FIX] website_slides: large image thumbnail
When user uploads video and set thumbnail from Promote >
optimize SEO > social share, it shows a small image that
changed to a large resolution image

Task-2010019

closes odoo/odoo#34177

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-06-17 09:58:11 +00:00
Patrick Hoste f0ec2a8fc8 [FIX] website_slides: fix various issues to eLearning platform
Including

* change h4 to h1 on the slide page;
* add the rel='canonical' link header on the fullscreen view in order to
improve SEO and links;
* add space between quiz questions;
* remove social share statistics as they are broken and not really useful;
* moved tabs before the Quiz on the slide page;
* allow to modify slide in backend by removing some readonly attributes;

Linked to task ID 2010024
Related to PR #34176

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-06-18 11:25:03 +00:00