edited flag for names and titles
This commit is contained in:
parent
ebc123a186
commit
634190cca6
4 changed files with 4 additions and 0 deletions
|
|
@ -19,6 +19,7 @@ def get_name_sort(name):
|
|||
class Person(models.Model):
|
||||
name = models.CharField(max_length=200, unique=True)
|
||||
name_sort = models.CharField(max_length=200)
|
||||
edited = models.BooleanField(default=False)
|
||||
numberofnames = models.IntegerField(default=0)
|
||||
|
||||
#FIXME: how to deal with aliases
|
||||
|
|
|
|||
|
|
@ -29,6 +29,7 @@ def editName(request):
|
|||
response = json_response()
|
||||
if 'nameSort' in data:
|
||||
person.name_sort = utils.sort_string(data['nameSort'])
|
||||
person.edited = True
|
||||
person.save()
|
||||
response['data'] = person.json()
|
||||
return render_to_json_response(response)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue