Skip to content
This repository has been archived by the owner on Dec 5, 2023. It is now read-only.

Updates to Questionnaire API endpoint (#607) #621

Closed
wants to merge 12 commits into from
Closed

Conversation

vleong2332
Copy link
Contributor

@vleong2332 vleong2332 commented Jun 8, 2016

  • Update the response for /api/questionnaire

Language direction is now indicated with "ltr" or "rtl" as opposed to
"l" or "r". This follows the pattern in langnames.json.

Give additional field of "language_data", which tells which question
maps to which property on a language.

  • Fix flake8 error(s)
  • Change questionnaire API view to class-based; Write unit-tests

The receiving endpoint now supports raw JSON data, instead of just POST form-data.

Resolves #603


This change is Reviewable

* Update the response for /api/questionnaire

Language direction is now indicated with "ltr" or "rtl" as opposed to
"l" or "r". This follows the pattern in langnames.json.

Give additional field of "language_data", which tells which question
maps to which property on a language.

* Fix flake8 error(s)

* Change questionnaire API view to class-based; Write unit-tests

The receiving endpoint now supports raw JSON data, instead of just POST form-data.

Resolves #603
@vleong2332 vleong2332 self-assigned this Jun 8, 2016
@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 74.025% when pulling ab4da08 on develop into bdfeb4d on master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 74.025% when pulling 74e4e71 on develop into bdfeb4d on master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.3%) to 74.121% when pulling d4507b4 on develop into bdfeb4d on master.

* Initial integration of django_comments and django-taggit

* Customize Tag from django-taggit

We need a Tag model/table to be some sort of "tag register" that lists
models (WARegion, Country, Language, Charter, Event are intendended)
alongside their tag slug. In other words, it need to keys to one of the
models in addition to the comment.

In admin, we'll use this custom tag (CommentTag) instead of
django-taggit's Tag.

* Add tag_slug property to WARegion, Country, Language, Charter, and Event

* Create management command to update CommentTag

* Add receivers and handler function to update comment tag

* Add hashtag info to WARegion, Country, Language, Charter, and Event detail page

* Parse hashtags in comments

* Add comment sections to Country, Language, and Event

* Add commenting to charter tab under language

* Add filter for all, originals, and mentions

* Add commenting management commands

* Display object name instead of the tag slug

* Prep work for review

Adjust tag slugging rule to use language's ISO-639-3 instead of its
code (IETF) if the code has less than 3 letters.

Fix duplicate comments and comment counts when writing a comment that
mentions itself.

Add missing "mentions" property to Charter and Event.

* Let comments and mentions be called as an object property.

Abstract out tags and comments properties in CommentableModel.

* Put events' comments under Translation Work tab in Language detail

* Make post_comment a class-based view

* Fix broken unit-tests

IntegrityError in create_comment_tag() causes database to close
connection early. Hence breaking the rest of the unit-tests.

* Add ability to delete one's own comment

* Write unit-tests
@coveralls
Copy link

Coverage Status

Coverage increased (+0.3%) to 74.186% when pulling 3adbbe4 on develop into bdfeb4d on master.

The denominator doesn't take into account which phase are we looking
at. As a result phase 1 completion percentage is divided against phase
1 and phase 2 word count, which results in a much lower number.
@coveralls
Copy link

Coverage Status

Coverage increased (+0.3%) to 74.186% when pulling b0843e8 on develop into bdfeb4d on master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.3%) to 74.186% when pulling 59d3509 on develop into bdfeb4d on master.

@vleong2332 vleong2332 closed this Jun 15, 2016
@coveralls
Copy link

Coverage Status

Coverage increased (+0.3%) to 74.186% when pulling 87e009b on develop into bdfeb4d on master.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants