add signalement model and form on maraudes:index
This commit is contained in:
@@ -3,7 +3,7 @@ from django.forms import inlineformset_factory
|
||||
from notes.forms import NoteForm
|
||||
# Models
|
||||
from .models import Maraude, Rencontre
|
||||
from .notes import Observation
|
||||
from .notes import Observation, Signalement
|
||||
|
||||
|
||||
class MaraudeAutoDateForm(forms.ModelForm):
|
||||
@@ -24,6 +24,12 @@ class RencontreForm(forms.ModelForm):
|
||||
fields = ['lieu', 'heure_debut', 'duree']
|
||||
|
||||
|
||||
class SignalementForm(NoteForm):
|
||||
|
||||
class Meta:
|
||||
model = Signalement
|
||||
fields = ['source', 'created_date', 'created_time', 'sujet', 'text']
|
||||
|
||||
|
||||
ObservationInlineFormSet = inlineformset_factory( Rencontre, Observation,
|
||||
form=NoteForm,
|
||||
|
||||
Reference in New Issue
Block a user