Allow fine-grained setting of rich text modes per-field.
Review Request #6456 — Created Oct. 17, 2014 and submitted — Latest diff uploaded
When we introduced Markdown support, we added a single rich_text field
for each supported model, and all fields were tied to that setting.
However, if a person wanted to use Markdown for one field but not
another, they were out of luck. That also required that we perform some
complex escaping/unescaping of all fields on a model when switching text
modes.This is the first change in a series that splits the rich_text field,
providing per-field flags. The changes are all inter-dependent, but
split up based on layers of the codebase.This change adds the new rich_text fields, updates logic and templates
to point to the new fields, and removes usage of the old fields.
This testing required the other related changes:
- Unit tests pass
- Editing fields in the UI set those fields to be in Markdown format, but
left other fields un-touched. - Fields with a rich_text=false render as plain text, but render as Markdown
with rich_text=true.
Diff Revision 1 (Latest)
reviewboard/reviews/admin.py |
---|
reviewboard/reviews/builtin_fields.py |
---|
reviewboard/reviews/tests.py |
---|
reviewboard/reviews/evolutions/__init__.py |
---|
reviewboard/reviews/evolutions/split_rich_text.py |
---|
reviewboard/reviews/models/base_review_request_details.py |
---|
reviewboard/reviews/models/review.py |
---|
reviewboard/reviews/models/review_request_draft.py |
---|
reviewboard/reviews/templatetags/reviewtags.py |
---|
reviewboard/templates/notifications/reply_email.html |
---|
reviewboard/templates/notifications/reply_email.txt |
---|
reviewboard/templates/notifications/review_email.html |
---|
reviewboard/templates/notifications/review_email.txt |
---|
reviewboard/templates/notifications/review_request_email.html |
---|
reviewboard/templates/notifications/review_request_email.txt |
---|
reviewboard/templates/reviews/reviewable_page_data.js |
---|
reviewboard/templates/reviews/boxes/review.html |
---|