优化权限规则显示

pull/516/MERGE
Karson 2026-01-14 10:54:14 +08:00
parent cbc3477cb4
commit be099f6254
1 changed files with 1 additions and 1 deletions

View File

@ -309,7 +309,7 @@ class Group extends Backend
continue;
}
$state = array('selected' => in_array($v['id'], $currentRuleIds) && !in_array($v['id'], $hasChildrens));
$nodeList[] = array('id' => $v['id'], 'parent' => $v['pid'] ? $v['pid'] : '#', 'text' => __($v['title']), 'type' => 'menu', 'state' => $state);
$nodeList[] = array('id' => $v['id'], 'parent' => $v['pid'] ? $v['pid'] : '#', 'text' => __($v['title']), 'type' => in_array($v['id'], $hasChildrens) ? 'menu' : 'file', 'state' => $state);
}
$this->success('', null, $nodeList);
} else {