Compare commits
1 commit
main
...
post-timez
| Author | SHA1 | Date | |
|---|---|---|---|
| 33d70539a6 |
5 changed files with 17 additions and 4 deletions
|
|
@ -72,7 +72,9 @@ class PostModal extends React.Component {
|
|||
<div className="post__header">
|
||||
<h2 className={titleClassName}>{`${post.title} `}</h2>
|
||||
<div className="post__meta-info">
|
||||
<span className="post__date">{publicationDate}</span>
|
||||
<span className="post__date">
|
||||
{publicationDate} {this.props.rule.timezone}
|
||||
</span>
|
||||
{post.author && <span className="post__author">{post.author}</span>}
|
||||
{this.props.category && (
|
||||
<span className="badge post__category" title={this.props.category.name}>
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ class PostItem extends React.Component {
|
|||
|
||||
<div className="posts-info">
|
||||
<span className="posts-info__date" title={publicationDate}>
|
||||
{publicationDate} {post.author && `By ${post.author}`}
|
||||
{publicationDate} {rule.timezone} {post.author && `By ${post.author}`}
|
||||
</span>
|
||||
{this.props.selected.type == CATEGORY_TYPE && (
|
||||
<span className="badge">
|
||||
|
|
|
|||
|
|
@ -12,4 +12,14 @@ class RuleSerializer(serializers.ModelSerializer):
|
|||
|
||||
class Meta:
|
||||
model = CollectionRule
|
||||
fields = ("id", "type", "name", "url", "favicon", "category", "user", "unread")
|
||||
fields = (
|
||||
"id",
|
||||
"type",
|
||||
"name",
|
||||
"url",
|
||||
"favicon",
|
||||
"category",
|
||||
"user",
|
||||
"unread",
|
||||
"timezone",
|
||||
)
|
||||
|
|
|
|||
|
|
@ -9,6 +9,6 @@
|
|||
{% endif %}
|
||||
|
||||
{% url "news:collection:rules" as cancel_url %}
|
||||
{% include "components/form/form.html" with form=form title="Update feed" cancel_url=cancel_url confirm_text="Save feed" only %}
|
||||
{% include "components/form/form.html" with form=form title="Update feed" cancel_url=cancel_url confirm_text="Save feed" %}
|
||||
</main>
|
||||
{% endblock %}
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ class CollectionRuleDetailViewTestCase(TestCase):
|
|||
self.assertTrue("favicon" in data)
|
||||
self.assertTrue("category" in data)
|
||||
self.assertTrue("type" in data)
|
||||
self.assertTrue("timezone" in data)
|
||||
|
||||
def test_not_known(self):
|
||||
response = self.client.get(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue