diff --git a/debian/control b/debian/control index 218de93..81762a9 100644 --- a/debian/control +++ b/debian/control @@ -11,6 +11,5 @@ Package: python-authentic2-auth-fedict Architecture: all Depends: ${misc:Depends}, python-authentic2 (>= 2.1.20.1054) -Conflicts: python-authentic2 (> 2.1.20.1137) Description: Fedict authentication frontend for Authentic2 diff --git a/src/authentic2_auth_fedict/__init__.py b/src/authentic2_auth_fedict/__init__.py index 216f6e9..edfdbe4 100644 --- a/src/authentic2_auth_fedict/__init__.py +++ b/src/authentic2_auth_fedict/__init__.py @@ -14,6 +14,8 @@ # You should have received a copy of the GNU Affero General Public License # along with this program. If not, see . +import json + import django.apps from django.utils.translation import ugettext_lazy as _ from django.contrib.auth.signals import user_logged_in @@ -63,20 +65,32 @@ class Plugin(object): return [ {'label': _('National Register Number'), 'name': 'nrn', + 'serialize': json.dumps, + 'deserialize': json.loads, 'field_class': fields.NrnField, }, {'label': _('Date'), + 'serialize': json.dumps, + 'deserialize': json.loads, 'name': 'date', 'field_class': fields.DateField, }, {'label': _('Street'), + 'serialize': json.dumps, + 'deserialize': json.loads, 'name': 'street', 'field_class': fields.StreetField, }, {'label': _('House number'), + 'serialize': json.dumps, + 'deserialize': json.loads, 'name': 'num_house', 'field_class': fields.NumHouseField, }, {'label': _('Phone number'), + 'serialize': json.dumps, + 'deserialize': json.loads, 'name': 'phone', 'field_class': fields.NumPhoneField, }, {'label': _('Country'), + 'serialize': json.dumps, + 'deserialize': json.loads, 'name': 'country', 'field_class': fields.CountryField, }, ]