Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
La Quadrature du Net
rpteam
Revue de Press
Commits
ab0c8db4
Commit
ab0c8db4
authored
Apr 02, 2019
by
Okhin
Browse files
Display the status of the article in the feeds
parent
ba1a8794
Changes
2
Hide whitespace changes
Inline
Side-by-side
apps/rp/api/serializers.py
View file @
ab0c8db4
...
...
@@ -33,5 +33,5 @@ class ArticleSerializer(serializers.ModelSerializer):
class
Meta
:
model
=
Article
fields
=
(
'id'
,
'url'
,
'title'
,
'tags'
,
'extracts'
,
fields
=
(
'id'
,
'url'
,
'title'
,
'tags'
,
'extracts'
,
'status'
,
'und_score_up'
,
'und_score_down'
)
apps/rp/feeds/feeds.py
View file @
ab0c8db4
...
...
@@ -5,7 +5,7 @@ from rp.models import Article
class
ArticlesFeed
(
Feed
):
title
=
"Revue de presse de la Quadrature"
link
=
"/feed/"
link
=
"/feed
s
/"
description
=
"La revue de presse recense les articles de presse relatifs aux sujets de la Quadrature. Elle est compilée chaque jour par ses bénévoles, à partir de la presse francophone et internationale. Bonne lecture !"
def
__init__
(
self
,
**
kwargs
):
...
...
@@ -18,6 +18,9 @@ class ArticlesFeed(Feed):
def
item_title
(
self
,
item
):
return
item
.
title
def
item_status
(
self
,
item
):
return
item
.
status
def
item_description
(
self
,
item
):
return
item
.
extracts
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment