This error occurs when user tries to click on the checkbox to 'Mark as done'.
Steps to produce:
- Install the `website_slides` module.
- Go to Website > Courses > Open a course containing one or more sections
(e.g., 'Taking care of Trees').
- Click on the `Add Content` button located at the bottom in blue.
- Select the video option and upload two videos, one after the other.
- Now, click the 'Mark as done' checkbox for the first video.
- When attempting to click the 'Mark as done' checkbox for the second video,
the error will occur.
Error: AttributeError: 'int' object has no attribute 'id'
To solve this issue we have returned the record for `next_category`from that it
will get the record `id`.
Previously, this code returned an integer value, see here:
https://github.com/odoo/odoo/blob/f34d87ecb7772417f1dd8f3d8836c89ddb903de8/addons/website_slides/models/slide_slide.py#L1321
here we are using that return value from the above line
https://github.com/odoo/odoo/blob/69fca30bb4fb66e6d979ce5ddc1bff4db963ca71/addons/website_slides/controllers/main.py#L1062
Previously it gets the integer and try to get id of that integer value.
sentry-4414398591
closesodoo/odoo#135805
X-original-commit: 9cc11ef9a0f2025a717602fb2087b96eda5e8218
Signed-off-by: Achraf Ben Azzouz (abz) <abz@odoo.com>