Skip to content

Assessment targeted review - #61

Merged
bradenmacdonald merged 8 commits into
masterfrom
assessment-targeted-review
Sep 10, 2015
Merged

Assessment targeted review#61
bradenmacdonald merged 8 commits into
masterfrom
assessment-targeted-review

Conversation

@bradenmacdonald

Copy link
Copy Markdown
Member

This new feature allows content authors to set an optional "review message" on each MCQ/MRQ/Rating question.

The review messages are shown in assessment mode when the student is reviewing their grade before being allowed to try again. The review screen now includes a list of topics to review, based on which questions the student got wrong.

Screenshot:
screen shot 2015-09-04 at 4 28 44 pm

If the student got all the questions right or has no attempts remaining, the new review section is not shown.

Here's how it looks to course authors in Studio:
screen shot 2015-09-04 at 4 29 13 pm

@bradenmacdonald
bradenmacdonald force-pushed the assessment-targeted-review branch from cc7902e to 96f9e14 Compare September 5, 2015 00:01
@bradenmacdonald
bradenmacdonald force-pushed the assessment-targeted-review branch from 96f9e14 to 77ca788 Compare September 5, 2015 00:39
Comment thread problem_builder/step.py

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@bradenmacdonald nit: could be lazy - lazies are per-instance, so even if you're in mixin each object of every class will get it's own lazy property.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@e-kolpakov Using lazy would be nice, but it would force this to become an attribute rather than a method, and I'd like this to be a method so that block.steps and block.get_steps() follows the same API pattern as block.children / block.get_children() and block.parent / block.get_parent()

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

@bradenmacdonald makes sense

@e-kolpakov

Copy link
Copy Markdown
Contributor

@bradenmacdonald one minor nit: the formatting of the list is different from the design doc. Here's what I see:

question assessment review

And it should look like this:
content_content_examplesguidance

Note the left margin and line spacing in the list. Also, the list itself should be positioned under the submit, not above.

@e-kolpakov

Copy link
Copy Markdown
Contributor

@bradenmacdonald one more thing :) It looks like the code does not support more than a single assessment message, but one can add any number of them in Studio. It would be nice to allow single instance only, similar to how it's made for mentoring-level messages.

Also, latest xblock-utils provide a mixin for handling nested blocks in a more "declarative" way - you might want to check it out: StudioContainerWithNestedXBlocksMixin. Examples are in GP v2 utils-update branch (virtually everywhere, but GroupProjectXBlock is probably the richest example so far).

Simply put:

  • Parent block need to inherit from the StudioContainerWithNestedXBlocksMixin (which inherits from StudioContainerXBlockMixin), and override allowed_nested_blocks property to contain a list of blocks that we want to add to it via Studio as either:
    ** XBlock class - simple mode, just allows unlimited children of the type
    ** NestedXBlockSpec instance - provides more config options including only allowing single instance.
  • Nested Blocks (i.e. in this case Answer, Tip and Message) need to have the follwoing constants set:
    ** CATEGORY - XBlock category as set on add button (and setup.py entrypoint)
    ** STUDIO_LABEL - human-readable name for an XBlock

If any css/js needs to be added you can just override the author_preview_view and author_edit_view. Also, for hiding the studio header in preview - I've took another option to not use any view that studio appends the header to, so XBlockWithPreviewMixin was created.

@bradenmacdonald
bradenmacdonald force-pushed the assessment-targeted-review branch from 5b7c35c to e8e2b48 Compare September 8, 2015 05:44
@bradenmacdonald

Copy link
Copy Markdown
Member Author

@e-kolpakov I think I've addressed all your comments.

I tried using StudioContainerWithNestedXBlocksMixin and it looks really nice - I just ran into two issues:

  1. Does it include any CSS by default? The buttons were the wrong shape:
    screen shot 2015-09-07 at 10 52 50 pm
  2. I can't use it with pb-message, because the MentoringMessageBlock has many different names in Studio - the STUDIO_LABEL depends on the boilerplate value. If you add some way to override the label when defining a NestedXBlockSpec then it could work.

I'd love to refactor the whole problem builder to use StudioContainerWithNestedXBlocksMixin but I think that's outside the scope of this PR.

@e-kolpakov

Copy link
Copy Markdown
Contributor

@bradenmacdonald the rules we used for those buttons were xblock-specific. Also, preview and edit views usually need studio view rules applied in order to look more or less like the actual student content. So I decided it would make sense to not include the css into StudioContainerWithNestedXBlocksMixin - instead, inherting class would just build the fragment via single super call and append required css, like this.

On the other hand, it actually might make sense to include basic rules for buttons. If you send a PR against utils I'll be happy to review it, otherwise (if you decide to go with adding css in descendant class) I'll include that next time I get to work on it.

Same thing about NestedXBlock. I believe just adding a kwarg label to override block label would just do the trick.

Also, it might be a good idea to log this feature requests as issues on utils repo - I'll go create them. :)

UPD:

@e-kolpakov

Copy link
Copy Markdown
Contributor

@bradenmacdonald positioning issue is fixed, but now "If you retake..." message persists when user is retaking the assessment:

retake_message

Is that intentional?

@bradenmacdonald

Copy link
Copy Markdown
Member Author

Good catch, thanks. I will fix.

@e-kolpakov

Copy link
Copy Markdown
Contributor

@bradenmacdonald 👍

bradenmacdonald added a commit that referenced this pull request Sep 10, 2015
@bradenmacdonald
bradenmacdonald merged commit 6af171b into master Sep 10, 2015
@bradenmacdonald
bradenmacdonald deleted the assessment-targeted-review branch September 10, 2015 18:07
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.

2 participants