feat: update click_zan display_cnt
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Baoshuo Ren 2023-02-24 17:04:29 +08:00
parent 48824e6fc7
commit d2e2760be3
Signed by: baoshuo
GPG Key ID: 00CB9680AB29F51A
3 changed files with 4 additions and 4 deletions

View File

@ -119,7 +119,7 @@ class ClickZans {
$display_cnt = $cnt > 0 ? '+' . $cnt : $cnt;
if ($cnt < 0) $display_cnt = '-';
if ($cnt < 0) $display_cnt = '-?';
return '<span class="' . $cls . '"><span class="uoj-click-zan-cnt">[<strong>' . $display_cnt . '</strong>]</span></span>';
}

View File

@ -123,9 +123,9 @@ class UOJBlog {
}
public function getDisplayZanCnt() {
$display_zan = $this->info['zan'] > 0 ? "+{$this->info['zan']}" : $this->info['zan'];
$display_zan = $this->info['zan'];
if ($this->info['zan'] < 0) $display_zan = '-';
if ($this->info['zan'] < 0) $display_zan = '-?';
return $display_zan;
}

View File

@ -329,7 +329,7 @@ $.fn.click_zan_block = function() {
var display_cnt = cnt > 0 ? '+' + cnt : cnt;
if (cnt < 0) display_cnt = '-';
if (cnt < 0) display_cnt = '-?';
$(this)
.append(up_node)