用户中心减层:收敛本人入口与 panel 契约
This commit is contained in:
1 parent
31c95c3bc6
commit
dec33ea15a
33 files changed
+1585
-1488
No files matched your search
+44
-1389
File diff suppressed because it is too large.
Load diff
@@ -174,20 +174,19 @@ $home_url = function_exists('aksrt_get_user_home_url') ? aksrt_get_user_home_url
|
||||
<div class="profile-list">
|
||||
<?php while ($author_posts->have_posts()) : $author_posts->the_post(); ?>
|
||||
<?php
|
||||
set_query_var('aksrt_profile_item_action', [
|
||||
'type' => 'view',
|
||||
'url' => get_permalink(),
|
||||
'label' => __('阅读', 'aksrt'),
|
||||
]);
|
||||
set_query_var('aksrt_profile_item_status', '');
|
||||
get_template_part('templates/parts/content', 'profile-list-item');
|
||||
get_template_part('templates/parts/content', 'profile-list-item', [
|
||||
'action' => [
|
||||
'type' => 'view',
|
||||
'url' => get_permalink(),
|
||||
'label' => __('阅读', 'aksrt'),
|
||||
],
|
||||
]);
|
||||
?>
|
||||
<?php endwhile; ?>
|
||||
</div>
|
||||
<?php
|
||||
aksrt_render_profile_pagination((int) $author_posts->max_num_pages, $posts_page, 'posts_page');
|
||||
wp_reset_postdata();
|
||||
set_query_var('aksrt_profile_item_action', []);
|
||||
else :
|
||||
aksrt_render_profile_empty($svg_empty_post, __('TA 还没有发布文章', 'aksrt'));
|
||||
endif;
|
||||
@@ -211,11 +210,9 @@ $home_url = function_exists('aksrt_get_user_home_url') ? aksrt_get_user_home_url
|
||||
<div class="profile-comment-list">
|
||||
<?php foreach ($user_comments as $c) : ?>
|
||||
<?php
|
||||
set_query_var('aksrt_profile_comment', $c);
|
||||
get_template_part('templates/parts/content', 'profile-comment-item');
|
||||
get_template_part('templates/parts/content', 'profile-comment-item', ['comment' => $c]);
|
||||
?>
|
||||
<?php endforeach; ?>
|
||||
<?php set_query_var('aksrt_profile_comment', null); ?>
|
||||
</div>
|
||||
<?php
|
||||
$cm_total_pages = (int) ceil($comment_count / $per_page);
|
||||
@@ -247,20 +244,19 @@ $home_url = function_exists('aksrt_get_user_home_url') ? aksrt_get_user_home_url
|
||||
<div class="profile-list">
|
||||
<?php while ($favorites_query->have_posts()) : $favorites_query->the_post(); ?>
|
||||
<?php
|
||||
set_query_var('aksrt_profile_item_action', [
|
||||
'type' => 'view',
|
||||
'url' => get_permalink(),
|
||||
'label' => __('阅读', 'aksrt'),
|
||||
get_template_part('templates/parts/content', 'profile-list-item', [
|
||||
'action' => [
|
||||
'type' => 'view',
|
||||
'url' => get_permalink(),
|
||||
'label' => __('阅读', 'aksrt'),
|
||||
],
|
||||
]);
|
||||
set_query_var('aksrt_profile_item_status', '');
|
||||
get_template_part('templates/parts/content', 'profile-list-item');
|
||||
?>
|
||||
<?php endwhile; ?>
|
||||
</div>
|
||||
<?php
|
||||
aksrt_render_profile_pagination((int) $favorites_query->max_num_pages, $favorites_page, 'favorites_page');
|
||||
wp_reset_postdata();
|
||||
set_query_var('aksrt_profile_item_action', []);
|
||||
else :
|
||||
aksrt_render_profile_empty($svg_empty_favorite, __('TA 还没有收藏文章', 'aksrt'));
|
||||
endif;
|
||||
|
||||
Reference in new issue
Block a user