mirror of
https://github.com/Hopiu/django-fobi.git
synced 2026-05-10 13:54:41 +00:00
prepare 0.6.4; minor fixes
This commit is contained in:
parent
f0039ab28b
commit
2e80834754
6 changed files with 22 additions and 13 deletions
|
|
@ -15,6 +15,12 @@ are used for versioning (schema follows below):
|
|||
0.3.4 to 0.4).
|
||||
- All backwards incompatible changes are mentioned in this document.
|
||||
|
||||
0.6.4
|
||||
-----
|
||||
2015-12-24
|
||||
|
||||
- Minor fixes.
|
||||
|
||||
0.6.3
|
||||
-----
|
||||
2015-12-23
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ django-formtools==1.0
|
|||
django-localeurl==2.0.2
|
||||
django-nine==0.1.6
|
||||
django-nonefield==0.1
|
||||
django-registration-redux==1.3a0
|
||||
django-registration-redux>=1.3a0
|
||||
docopt==0.4.0
|
||||
docutils==0.12
|
||||
easy-thumbnails==2.3
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ django-debug-toolbar>=0.11.0
|
|||
django-formtools
|
||||
django-localeurl>=2.0.2
|
||||
django-nine>=0.1.6
|
||||
django-registration-redux>=1.1
|
||||
django-registration-redux>=1.3a0
|
||||
docutils
|
||||
ipdb
|
||||
ipython
|
||||
|
|
|
|||
2
setup.py
2
setup.py
|
|
@ -69,7 +69,7 @@ for static_dir in static_dirs:
|
|||
for locale_dir in locale_dirs:
|
||||
locale_files += [os.path.join(locale_dir, f) for f in os.listdir(locale_dir)]
|
||||
|
||||
version = '0.6.3'
|
||||
version = '0.6.4'
|
||||
|
||||
install_requires = [
|
||||
'Pillow>=2.0.0',
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
__title__ = 'django-fobi'
|
||||
__version__ = '0.6.3'
|
||||
__build__ = 0x00004c
|
||||
__version__ = '0.6.4'
|
||||
__build__ = 0x00004d
|
||||
__author__ = 'Artur Barseghyan <artur.barseghyan@gmail.com>'
|
||||
__copyright__ = '2014-2015 Artur Barseghyan'
|
||||
__license__ = 'GPL 2.0/LGPL 2.1'
|
||||
|
|
|
|||
|
|
@ -51,15 +51,18 @@ class SavedFormDataEntry(models.Model):
|
|||
|
||||
:return string:
|
||||
"""
|
||||
headers = json.loads(self.form_data_headers)
|
||||
data = json.loads(self.saved_data)
|
||||
for key, value in data.items():
|
||||
if isinstance(value, string_types) and \
|
||||
(value.startswith(settings.MEDIA_URL) or \
|
||||
value.startswith('http://') or value.startswith('https://')):
|
||||
try:
|
||||
headers = json.loads(self.form_data_headers)
|
||||
data = json.loads(self.saved_data)
|
||||
for key, value in data.items():
|
||||
if isinstance(value, string_types) and \
|
||||
(value.startswith(settings.MEDIA_URL) or \
|
||||
value.startswith('http://') or value.startswith('https://')):
|
||||
|
||||
data[key] = '<a href="{value}">{value}</a>'.format(value=value)
|
||||
data[key] = '<a href="{value}">{value}</a>'.format(value=value)
|
||||
|
||||
return two_dicts_to_string(headers, data)
|
||||
return two_dicts_to_string(headers, data)
|
||||
except (ValueError, json.decoder.JSONDecodeError as err):
|
||||
return ''
|
||||
formatted_saved_data.allow_tags = True
|
||||
formatted_saved_data.short_description = _("Saved data")
|
||||
|
|
|
|||
Loading…
Reference in a new issue