Граф коммитов

23 Коммитов

Автор SHA1 Сообщение Дата
Pomax f4c237a106
Multiple serializers for Entry based on type (#490)
* entry types with appropriate serializers and URL endpoints
2019-05-23 11:15:58 -07:00
Gideon Thomas 0a889e550b
Switch over auth system to django-allauth and add Github auth (#413)
This PR adds django-allauth as an auth mechanism and adds Github auth as another way to sign in to pulse.
2018-11-14 11:37:07 -05:00
Lucie 72a5478fe0
Activate cache on appveyor + migration test (#350)
* add pip upgrade to travis

* appveyor cache
2018-05-16 10:45:09 +02:00
Gideon Thomas 89a46577f1
Replace creators with profiles (#348)
* Remove model abstraction of creators

* Add intermediary model between Entry and UserProfile

* Migrate data from Creators to intermediary model

* Modify serializers

* Fix tests

* Remove old creator models

* Add searching functionality for profiles

* Fix #349 - Add id to profile entry routes

* Update README
2018-04-26 15:13:17 -04:00
Gideon Thomas d7a0eb7fbe
Add route for profile favorites (#320)
* Add profile entry routes to get published, created, and favorited entries

* Return entry count if no params passed to profile entry route

* Add v2 for profile route to only return profile info, not related entries

* Add v2 for profile list route to only return list of simple profile info without related entries
2018-03-28 13:38:08 -04:00
Chris DeCairos 6638cf1b0c
flake 2018-03-15 13:30:22 -04:00
Chris DeCairos 730debea88
Modify tests so that a moderator group can be tested, clean up the entries tests a bit 2018-03-15 13:16:59 -04:00
Lucie 748ce791fd
Create fake data for review apps and local dev (#300)
* management commands in place + basic entry factory

* flake :)

* Entries don't create new users but get existing ones

* Create profile factory and connect it with user

* Entries have tags, issues and helptypes

* Moar work in users + creators + bookmarks

* Updated the load_fake_data script, added thumbnails support, finished creators

* polishing + updated the flush script

* Make sure that entries can be bookmarked by multiple users + entries can have multiples creators

* Test new management commands + docs + small fixes

* Forgot to fix this ><

* Small fixes and bookmarks only for published entries
2018-02-27 17:00:49 +01:00
Gideon Thomas a391f455e2
Add versioning to the routes (#284)
* Add versioning to the routes

* Fix incorrect link

* Tests for versioning

* Last fixes to versioning

* Travis

* Fix documentation according to PR comments

* Remove raw string notation from urls
2018-02-14 13:36:00 -05:00
Mike Kamermans a6f7f11693
Extended profile (#274)
- add extended profile fields with serialization toggle
- changed `/myprofile` PUT handling to prevent updates for data that is not exposed.
2018-02-05 12:42:58 -08:00
Gideon Thomas fe60e1510f fix(entries): POST autocompleted creators for entries (#238)
Fix #215
1. Adds functionality to auto-create creator objects when profiles are created and creates creator objects for existing profiles.
2. Changes POST /entries to accept existing creators and create new ones if they don't exist.

Fix #233
Refer to request correctly in serializer for is_bookmarked on entries

* Auto-create creators on creating profiles

* Allow existing creators to be used in POSTing new entries

* Try to fix entry post data format

* Still fixing querydict

* Force JSON for entry views

* Use JSON for tests + test fixes

* Test related_creators while posting an entry

* Readme update

* Review fixes

* Test for follow
2017-10-19 13:41:27 -04:00
Gideon Thomas b2f12cfd19 Link creators to profiles (#227)
* fix(creators): #218 relate creators to profiles

* API fixes for creators

* Update docs
2017-10-10 14:21:37 -04:00
Gideon Thomas 22a49be912 Users can only be associated with one profile (#217)
* Fix #214 - Users can be associated only with one profile

* Lint fixes

* Move profile-user relationship to users instead of profiles

* Fix migration dependencies

* Fix references to user in profile views

* Finally

* Last one
2017-10-03 16:47:56 -04:00
Gideon Thomas 5be82677e6 Test creators being serialized correctly for entries (#216)
* Test creators being serialized correctly for entries

* Review fixes
2017-09-29 15:23:50 -04:00
Mike Kamermans c84c7c83a5 Add flake8 linting (#179)
Added flake8 linting to the codebase
2017-08-14 15:27:30 -07:00
Mike Kamermans a28f374f68 Move bookmarks from EmailUser to UserProfile (#171)
This PR effects the following steps:
- step 1: create a profiles app
- step 2: associate user profiles for each existing user
- intermediate step: code refactors while making sure to keep passing tests
- step 3: create parallel bookmark data by copying from users to asscoaited profiles
- step 4: rebing everything to profile.UserBookmarks
- step 5: finally, removed the bookmark code from the user model
2017-08-09 22:22:43 -07:00
Mike Kamermans b68d2dedb0 Sync with network api (#125)
* moderation states and associated API endpoints
* default group assignment ("staff")
* make bulk creates duplicate-safe
* renamed is_staff in the admin view to a clear "this user can do everything" flag

* PR notes

* issue get_or_create

* Update 0001_initial.py
2017-06-16 10:45:45 -07:00
Mike Kamermans 7c489e888a Moderation states (#120)
This also migrates `is_approved` to multiple moderation states
2017-06-02 08:43:55 -07:00
Alan Mooiman 3b5984141b Add basic moderation (#114)
* Add basic moderation

Anyone can log in and submit an entry, only staff entries are approved by default.

Admins can approve entries

* Filter individual entries by approved

* Tests work

* Tests and env var for universal login
2017-05-03 14:06:26 -04:00
Mike Kamermans 55c916812b reset migrations, and removal of old files (#41) 2017-01-20 16:06:58 -08:00
Alan Mooiman 5f89af56c1 Simplify required fields (#31)
* Simplify required fields

Closes https://github.com/mozilla/network-pulse-api/issues/22

* Oops

* Update test for required content_url

* Split required fields test into two
2017-01-19 19:34:20 -05:00
Mike Kamermans 543e1bb1ff Test suite (#9)
Tests are great
2017-01-10 14:53:10 -08:00
Mike Kamermans 663dab4bef email-based user model and google auth (#2)
* email-based user model and google auth

* this dir should not be here

* flow fix, and moved files, and addded docs

* test form in ./public (host on :8080), entry posting works

* docs

* docs

* spacing

* docs

* pip freeze

* docs

* code formatting

* tags work

* safari-proof

* let~
2016-12-20 12:24:54 -08:00