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

expose the apFetchedAt field of users and magazines for admins #826

Merged
merged 2 commits into from
Jun 14, 2024
Merged
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
5 changes: 5 additions & 0 deletions templates/components/magazine_box.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@
<li>{{ 'created_at'|trans }}:
{{ component('date', {date: computed.magazine.createdAt}) }}
</li>
{% if app.user is defined and app.user is not null and app.user.admin() and computed.magazine.apId is not null %}
<li>
{{ 'last_updated'|trans }}: {{ component('date', {date: computed.magazine.apFetchedAt}) }}
</li>
{% endif %}
<li>{{ 'subscribers'|trans }}: <span>{{ computed.magazine.subscriptionsCount }}</span></li>
</ul>
{% endif %}
Expand Down
5 changes: 5 additions & 0 deletions templates/user/_info.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@
{% endif %}
<ul class="info">
<li>{{ 'joined'|trans }}: {{ component('date', {date: user.createdAt}) }}</li>
{% if app.user is defined and app.user is not null and app.user.admin() and user.apId is not null %}
<li>
{{ 'last_updated'|trans }}: {{ component('date', {date: user.apFetchedAt}) }}
</li>
{% endif %}
{%- set TYPE_ENTRY = constant('App\\Repository\\ReputationRepository::TYPE_ENTRY') -%}
<li><a href="{{ path('user_reputation', {username: user.username, reputationType: TYPE_ENTRY}) }}" class="stretched-link">{{ 'reputation_points'|trans }}:</a> {{ get_reputation_total(user) }}</li>
<li><a href="{{ path('user_moderated', {username: user.username}) }}"
Expand Down
1 change: 1 addition & 0 deletions translations/messages.en.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -828,3 +828,4 @@ continue_with: Continue with
someone: Someone
magazine_log_mod_added: has added a moderator
magazine_log_mod_removed: has removed a moderator
last_updated: Last updated
Loading