进行了一些小修复

This commit is contained in:
2026-08-26 15:29:37 +08:00
parent ae10b3d3fd
commit 562beb15cf
6 changed files with 206 additions and 43 deletions
+2 -15
View File
@@ -759,21 +759,8 @@ if (!function_exists('aksrt_single_render_pay_box')) :
$has_access = function_exists('aksrt_has_paid_access') ? aksrt_has_paid_access($post) : false;
if ($has_access) {
if ($pay_type === 'download') {
get_template_part('templates/parts/resource-download-box');
return;
}
$order_type = $pay_type === 'gallery' ? 5 : ($pay_type === 'video' ? 6 : 4);
echo '<div class="zib-widget pay-box paid-box order-type-' . esc_attr((string) $order_type) . '" id="posts-pay">';
if ($pay_type === 'gallery') {
echo aksrt_render_paid_gallery($post); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
} elseif ($pay_type === 'video') {
echo aksrt_render_paid_video($post); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
} else {
echo '<div class="box-body"><span class="badg c-green hollow badg-sm mr6">' . esc_html__('已解锁', 'aksrt') . '</span><b>' . esc_html(get_the_title($post)) . '</b></div>';
}
echo '</div>';
} else {
echo aksrt_get_paid_box_html($post); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
} elseif ($pay_type !== 'reading') {
echo aksrt_get_paywall_html($post); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
}
}