Add student_view_data to HTML XBlock (#853)

Description

Allows HTML content of the HtmlBlock to be downloaded via the course blocks API.

  • Added student_view_data to HtmlBlock

  • Added some tests for html xblock student_view_data

*JIRA tickets*: [OC-2995](https://tasks.opencraft.com/browse/OC-2995) [MCKIN-5637](https://edx-wiki.atlassian.net/browse/MCKIN-5637)

*Dependencies*: None

*Merge deadline*: None

*Testing instructions*:

1. Have a course with a Text Html XBlock
2. Navigate to http://localhost:8000/api/courses/v1/blocks/?all_blocks=true&depth=all&requested_fields=student_view_data&course_id=<course_id>
3. See that the block's HTML content is available in the API output as:
```json
"student_view_data": {
"html": "<h1>HTML Content</h3>"
}
```

*Reviewers*

  • [ ] @e-kolpakov

  • [ ] TBD

Activity

Show:
Dennis Jen
October 31, 2017, 2:07 PM

- thank you!

Nimisha Asthagiri
October 31, 2017, 1:57 PM

Yes. I'll review. (Side-effect of me not having a JIRA board to track this work - sorry.)

Dennis Jen
October 31, 2017, 1:51 PM

– we saw that you commented on it. Are you continuing to review?

George Song
September 13, 2017, 3:25 PM

Re-opened. Unfortunately I can't change the resolution status. Please ignore the "won't do" designation.

Braden MacDonald
September 11, 2017, 4:36 PM

We accidentally closed this PR, sorry! Could you please re-open this ticket?

Done

Assignee

Unassigned

Reporter

Open Source Pull Request Bot

Contributor Name

Brad Melin

Repo

edx/edx-platform

Customer

Epic Link

None

OSCM Assignee

None

Platform Map Area (Levels 1 &amp; 2)

None

Platform Map Area (Levels 3 &amp; 4)

None

Blended Hour Utilization Percentage

None

edX Theme

None

edX Squad

None

Github Lines Added

None

Github Lines Deleted

None

Priority

Unset