Update Celery to 4.3
[wolnelektury.git] / src / club / payu / forms.py
1 from django import forms
2
3
4 class CardTokenForm(forms.Form):
5     token = forms.CharField(widget=forms.HiddenInput)
6
7     def get_queryset(self, view):
8         raise NotImplementedError()
9
10     def save(self, view):
11         self.instance, created = self.get_queryset(view).get_or_create(
12             pos_id=view.get_pos().pos_id,
13             disposable_token=self.cleaned_data['token']
14         )