Skip to content

Commit d74c7a8

Browse files
committed
Align code, tests, and url templates around the person ajax json views. Fix a dangling pyflake nit. Commit ready for merge.
- Legacy-Id: 19453
1 parent f909a19 commit d74c7a8

3 files changed

Lines changed: 4 additions & 5 deletions

File tree

ietf/person/urls.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
urlpatterns = [
55
url(r'^merge/$', views.merge),
66
url(r'^search/(?P<model_name>(person|email))/$', views.ajax_select2_search),
7-
url(r'^(?P<personid>[a-z0-9]+).json$', ajax.person_json),
8-
url(r'^(?P<personid>[a-z0-9]+)/email.json$', ajax.person_email_json),
7+
url(r'^(?P<personid>[0-9]+).json$', ajax.person_json),
8+
url(r'^(?P<personid>[0-9]+)/email.json$', ajax.person_email_json),
99
url(r'^(?P<email_or_name>[^/]+)$', views.profile),
1010
url(r'^(?P<email_or_name>[^/]+)/photo/?$', views.photo),
1111
]

ietf/person/utils.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
import debug # pyflakes:ignore
1616

1717
from ietf.person.models import Person
18-
from ietf.group.models import GroupFeatures
1918
from ietf.utils.mail import send_mail
2019

2120
def merge_persons(request, source, target, file=sys.stdout, verbose=False):

ietf/templates/doc/edit_authors.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ <h1>Edit authors<br><small>{{ titletext }}</small></h1>
7878
var list_container;
7979
var form_counter;
8080
var author_template;
81-
var ajax_url = '{% url "ietf.person.ajax.person_email_json" personid="0000placeholder0000" %}';
81+
var ajax_url = '{% url "ietf.person.ajax.person_email_json" personid="123454321" %}';
8282
var person_select2_input_selector = 'input.select2-field[name^="author-"][name$="-person"]';
8383

8484
function handle_drag_end() {
@@ -126,7 +126,7 @@ <h1>Edit authors<br><small>{{ titletext }}</small></h1>
126126
var person_elt = $(this);
127127
var email_select = $('#' + person_elt.attr('id').replace(/-person$/, '-email'));
128128
$.get(
129-
ajax_url.replace('0000placeholder0000', $(this).val()),
129+
ajax_url.replace('123454321', $(this).val()),
130130
null,
131131
update_email_options_cb_factory(email_select)
132132
);

0 commit comments

Comments
 (0)