POST instantiation for Django-Angular

Bug #1395270 reported by Thai Tran
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
Fix Released
Undecided
Thai Tran

Bug Description

We currently need to include a CSRF token in our form if we want to POST to a Django view. Furthermore, we need to change the content-type to 'application/x-www-form-urlencoded' before we can POST. This is cumbersome and should really be a global setting.

http://www.daveoncode.com/2013/10/17/how-to-make-angularjs-and-django-play-nice-together/
http://django-angular.readthedocs.org/en/latest/csrf-protection.html?highlight=post#set-header-with-x-csrftoken-via-cookie
for more details.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (master)

Fix proposed to branch: master
Review: https://review.openstack.org/136556

Changed in horizon:
assignee: nobody → Thai Tran (tqtran)
status: New → In Progress
Changed in horizon:
assignee: Thai Tran (tqtran) → Richard Jones (r1chardj0n3s)
Changed in horizon:
assignee: Richard Jones (r1chardj0n3s) → Thai Tran (tqtran)
Changed in horizon:
assignee: Thai Tran (tqtran) → Kahou Lei (kahou82)
Changed in horizon:
assignee: Kahou Lei (kahou82) → Thai Tran (tqtran)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to horizon (master)

Reviewed: https://review.openstack.org/136556
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=04ce53bcb3896fbb6f251eb57458edbc845f791f
Submitter: Jenkins
Branch: master

commit 04ce53bcb3896fbb6f251eb57458edbc845f791f
Author: Thai Tran <email address hidden>
Date: Fri Dec 5 13:58:48 2014 -0800

    POST instantiation for Django-Angular

    We currently need to include a CSRF token in our form if we want to POST
    to a Django view. This is cumbersome and should really be a global setting.

    Change-Id: I607a0e428833e7478b073eec4d9ef9e1e856ae12
    Closes-Bug: #1395270

Changed in horizon:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in horizon:
milestone: none → kilo-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in horizon:
milestone: kilo-1 → 2015.1.0
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.