Sensei: Moved lessons do not appear under new course at Lessons > Order Lessons

Created on 12 May 2017  路  5Comments  路  Source: Automattic/sensei

If you move a lesson from one course and module to a different course that doesn't have any modules, the lesson does not appear at Lessons > Order Lessons for either the new or old course.

Steps to repro:

  1. Create two courses with a few lessons.
  2. Make sure one of the courses has a module while the other one does not and add the lessons to the module.
  3. Move one of the lessons from that course/module to the other course that doesn't have any modules.
  4. Go to Lessons > Order Lessons and select the course the lesson was moved to.

I expected to see the moved lesson in the list for the course I just moved it to.

Reported in 575442-zd-woothemes

[Pri] Normal [Type] Bug

All 5 comments

Somewhat related: 600210-zd-woothemes. Though in the case the user has simply added lessons after the course was live. :/

This was an issue with the module not being set/unset properly when the lesson was moved. The UI change in #1891 should fix it for most of our users moving forward.

@pgk do you think the UI-level fix should be enough for now? Or should we do some backend checks/tests as well, in case e.g. the user has Javascript disabled and the frontend functionality doesn't work?

cc @dbtlr

@alexsanford IMHO you should always back client-side limitations with server-side validation, otherwise, you find yourself with unintended consequences when people start playing around with things.

@dbtlr I agree. I'll dive in 馃槃

do you think the UI-level fix should be enough for now?

I would check for an inconsistent lesson/module state on the lesson save hook just before updating lesson course.

Was this page helpful?
0 / 5 - 0 ratings