Revision 0259c7ef
Added by Jérôme Schneider over 12 years ago
calebasse/dossiers/views.py | ||
---|---|---|
5 | 5 |
from calebasse.agenda.models import Occurrence |
6 | 6 |
from calebasse.dossiers.models import PatientRecord, Status, FileState |
7 | 7 |
from calebasse.dossiers.forms import (SearchForm, CivilStatusForm, StateForm, |
8 |
PhysiologyForm, FamillyForm, InscriptionForm) |
|
8 |
PhysiologyForm, FamillyForm, InscriptionForm, GeneralForm)
|
|
9 | 9 |
from calebasse.dossiers.states import STATES_MAPPING, STATE_CHOICES_TYPE |
10 | 10 |
from calebasse.ressources.models import Service |
11 | 11 |
|
... | ... | |
51 | 51 |
class PatientRecordView(ServiceViewMixin, MultiUpdateView): |
52 | 52 |
model = PatientRecord |
53 | 53 |
forms_classes = { |
54 |
'general': GeneralForm, |
|
54 | 55 |
'id': CivilStatusForm, |
55 | 56 |
'physiology': PhysiologyForm, |
56 | 57 |
'inscription': InscriptionForm, |
... | ... | |
60 | 61 |
success_url = './view' |
61 | 62 |
|
62 | 63 |
def get_success_url(self): |
63 |
return self.success_url + '#tab=' + self.request.POST['tab'] |
|
64 |
if self.request.POST.has_key('tab'): |
|
65 |
return self.success_url + '#tab=' + self.request.POST['tab'] |
|
66 |
else: |
|
67 |
return self.success_url |
|
64 | 68 |
|
65 | 69 |
def get_context_data(self, **kwargs): |
66 | 70 |
ctx = super(PatientRecordView, self).get_context_data(**kwargs) |
Also available in: Unified diff
dossiers: enable pause facturation and comment