修正分享管理中的逻辑问题
允许查看已经失效的分享详情
This commit is contained in:
parent
5d5c786ab0
commit
69b7bb42d1
@ -62,7 +62,7 @@ $this->params['breadcrumbs'][] = $this->title;
|
|||||||
'urlCreator' => function ($action, Share $model, $key, $index, $column) {
|
'urlCreator' => function ($action, Share $model, $key, $index, $column) {
|
||||||
if ($action === 'view') {
|
if ($action === 'view') {
|
||||||
// 返回查看按钮的链接
|
// 返回查看按钮的链接
|
||||||
return $model->status != 0 ? Url::toRoute(['share-manage-view', 'share_id' => $model->share_id]): null;
|
return Url::toRoute(['share-manage-view', 'share_id' => $model->share_id]);
|
||||||
} else {
|
} else {
|
||||||
// 如果 status 为 0,禁用删除按钮
|
// 如果 status 为 0,禁用删除按钮
|
||||||
return $model->status != 0 ? Url::toRoute(['share-manage-delete', 'share_id' => $model->share_id]) : null;
|
return $model->status != 0 ? Url::toRoute(['share-manage-delete', 'share_id' => $model->share_id]) : null;
|
||||||
|
Loading…
Reference in New Issue
Block a user