Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added re_post to urls to support regular expression in urls, changed … #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion main/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class Job(models.Model):

posted_by_user_agent = models.CharField(max_length=1024, default="Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.22 (KHTML, like Gecko) Chrome/25.0.1364.172 Safari/537.22")

posted_from_ip = models.IPAddressField(blank=True, null=True)
posted_from_ip = models.GenericIPAddressField(blank=True, null=True)

title = models.CharField(max_length=1024)

Expand Down
6 changes: 3 additions & 3 deletions main/urls.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from django.urls import path
from django.urls import path, re_path
from django.views.generic.base import TemplateView

from main.feeds import LatestEntriesFeed, UnapprovedEntriesFeed
Expand All @@ -21,12 +21,12 @@
job_detail,
name="view_job"
),
path(
re_path(
'<int:object_id>/approve$',
approve,
name="approve_job"
),
path(
re_path(
'<int:object_id>/disapprove$',
disapprove,
name="disapprove_job"
Expand Down