Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Adrián Ribao
Cartero
Commits
162f95e2
Commit
162f95e2
authored
Feb 01, 2016
by
Adrián Ribao
Browse files
use genericipaddressfields
parent
6501ff8e
Changes
1
Show whitespace changes
Inline
Side-by-side
cartero/models.py
View file @
162f95e2
...
...
@@ -245,7 +245,7 @@ class LinkClick(models.Model):
url
=
models
.
ForeignKey
(
ShortURL
,
verbose_name
=
_
(
u
'url'
))
#url = models.CharField(max_length=255, verbose_name=_(u'URL'), db_index=True)
#short_url = models.CharField(max_length=75, verbose_name=_(u'Short url'), db_index=True)
ip_address
=
models
.
IPAddressField
(
verbose_name
=
_
(
u
'IP Address'
),
null
=
True
,
db_index
=
True
)
ip_address
=
models
.
Generic
IPAddressField
(
verbose_name
=
_
(
u
'IP Address'
),
null
=
True
,
db_index
=
True
)
campaign
=
models
.
ForeignKey
(
Campaign
,
verbose_name
=
_
(
u
'Campaign'
))
...
...
@@ -281,7 +281,7 @@ class OpenEmail(models.Model):
"""
created
=
models
.
DateTimeField
(
auto_now_add
=
True
)
modified
=
models
.
DateTimeField
(
auto_now
=
True
)
ip_address
=
models
.
IPAddressField
(
verbose_name
=
_
(
u
'IP Address'
),
null
=
True
,
db_index
=
True
)
ip_address
=
models
.
Generic
IPAddressField
(
verbose_name
=
_
(
u
'IP Address'
),
null
=
True
,
db_index
=
True
)
campaign
=
models
.
ForeignKey
(
Campaign
,
verbose_name
=
_
(
u
'Campaign'
))
contact
=
models
.
ForeignKey
(
Contact
,
verbose_name
=
_
(
u
'Contact'
))
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment