|
|
@ -111,6 +111,8 @@ def resitelEditView(request): |
|
|
|
prefill_1.update(prefill_3) |
|
|
|
if 'datum_narozeni' in prefill_1: |
|
|
|
prefill_1['datum_narozeni'] = str(prefill_1['datum_narozeni']) |
|
|
|
if 'datum_souhlasu_udaje' in prefill_1: |
|
|
|
prefill_1['spam'] = bool(prefill_1['datum_souhlasu_zasilani']) |
|
|
|
if 'rok_maturity' not in prefill_1 or prefill_1['rok_maturity'] < date.today().year: |
|
|
|
form = PoMaturiteProfileEditForm(initial=prefill_1) |
|
|
|
else: |
|
|
@ -143,6 +145,8 @@ def resitelEditView(request): |
|
|
|
## Změny v osobě s podmínkami |
|
|
|
if fcd.get('spam',False): |
|
|
|
osoba_edit.datum_souhlasu_zasilani = date.today() |
|
|
|
else: |
|
|
|
osoba_edit.datum_souhlasu_zasilani = None |
|
|
|
if fcd.get('stat','') in ('CZ','SK'): |
|
|
|
osoba_edit.stat = fcd['stat'] |
|
|
|
else: |
|
|
|