SciPost Code Repository
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SciPost
Manage
Activity
Members
Labels
Plan
Issues
118
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SciPost
SciPost
Commits
3b312c82
Commit
3b312c82
authored
3 years ago
by
Jean-Sébastien Caux
Browse files
Options
Downloads
Patches
Plain Diff
Add Django job openings RSS feed
parent
e64e691e
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
scipost_django/scipost/feeds.py
+20
-0
20 additions, 0 deletions
scipost_django/scipost/feeds.py
scipost_django/scipost/urls.py
+11
-3
11 additions, 3 deletions
scipost_django/scipost/urls.py
with
31 additions
and
3 deletions
scipost_django/scipost/feeds.py
+
20
−
0
View file @
3b312c82
...
...
@@ -10,6 +10,7 @@ from django.utils.feedgenerator import Atom1Feed
from
django.urls
import
reverse
from
django.db.models
import
Q
from
careers.models
import
JobOpening
from
comments.models
import
Comment
from
commentaries.models
import
Commentary
from
journals.models
import
Publication
...
...
@@ -179,3 +180,22 @@ class LatestPublicationsFeedAtom(LatestPublicationsFeedRSS):
return
datetime
.
datetime
(
item
.
publication_date
.
year
,
item
.
publication_date
.
month
,
item
.
publication_date
.
day
)
class
DjangoJobOpeningsFeedRSS
(
Feed
):
title
=
'
SciPost: Dev Jobs
'
link
=
'
/careers/django/
'
description
=
"
SciPost: Django dev job openings
"
def
items
(
self
):
return
JobOpening
.
objects
.
publicly_visible
().
filter
(
description__icontains
=
'
django
'
)
def
item_title
(
self
,
item
):
return
item
.
title
def
item_description
(
self
,
item
):
return
item
.
short_description
def
item_link
(
self
,
item
):
return
item
.
get_absolute_url
()
This diff is collapsed.
Click to expand it.
scipost_django/scipost/urls.py
+
11
−
3
View file @
3b312c82
...
...
@@ -9,9 +9,12 @@ from django.views.generic.base import RedirectView
from
django.urls
import
include
,
path
,
re_path
from
.
import
views
,
sso
from
.feeds
import
LatestNewsFeedRSS
,
LatestNewsFeedAtom
,
LatestCommentsFeedRSS
,
\
LatestCommentsFeedAtom
,
LatestSubmissionsFeedRSS
,
LatestSubmissionsFeedAtom
,
\
LatestPublicationsFeedRSS
,
LatestPublicationsFeedAtom
from
.feeds
import
(
LatestNewsFeedRSS
,
LatestNewsFeedAtom
,
LatestCommentsFeedRSS
,
LatestCommentsFeedAtom
,
LatestSubmissionsFeedRSS
,
LatestSubmissionsFeedAtom
,
LatestPublicationsFeedRSS
,
LatestPublicationsFeedAtom
,
DjangoJobOpeningsFeedRSS
,
)
from
journals
import
views
as
journals_views
from
journals.regexes
import
ISSUE_DOI_LABEL_REGEX
,
\
...
...
@@ -300,6 +303,11 @@ urlpatterns = [
LatestPublicationsFeedAtom
(),
name
=
'
feeds_atom_publications
'
),
path
(
'
rss/careers/django/
'
,
DjangoJobOpeningsFeedRSS
(),
name
=
'
feeds_django_job_openings
'
),
path
(
'
atom/publications/<specialty:specialty>
'
,
LatestPublicationsFeedAtom
(),
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment