mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-16 21:12:13 +00:00
EventDuplicate now presents an edit view before saving
This commit is contained in:
@@ -89,10 +89,10 @@ class EventForm(forms.ModelForm):
|
||||
return items
|
||||
|
||||
def _get_or_initialise_item(self, pk, data, event):
|
||||
if (pk < 0):
|
||||
try:
|
||||
item = models.EventItem.objects.get(pk=pk,event=event)
|
||||
except models.EventItem.DoesNotExist:
|
||||
item = models.EventItem()
|
||||
else:
|
||||
item = models.EventItem.objects.get(pk=pk)
|
||||
|
||||
item.name = data['name']
|
||||
item.description = data['description']
|
||||
|
||||
Reference in New Issue
Block a user