From 27fe5f2e75e4bca7cd179b977467737864116ae9 Mon Sep 17 00:00:00 2001 From: Chenx221 Date: Sun, 7 Apr 2024 14:36:08 +0800 Subject: [PATCH] fix warning --- views/admin/share_manage.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/admin/share_manage.php b/views/admin/share_manage.php index 9780427..b87b94a 100644 --- a/views/admin/share_manage.php +++ b/views/admin/share_manage.php @@ -63,7 +63,7 @@ $this->params['breadcrumbs'][] = $this->title; if ($action === 'view') { // 返回查看按钮的链接 return $model->status != 0 ? Url::toRoute(['share-manage-view', 'share_id' => $model->share_id]): null; - } elseif ($action === 'delete') { + } else { // 如果 status 为 0,禁用删除按钮 return $model->status != 0 ? Url::toRoute(['share-manage-delete', 'share_id' => $model->share_id]) : null; }