Dashboard: Allow add panel for viewers_can_edit (#28570)

Signed-off-by: clyang82 <chuyang@redhat.com>
This commit is contained in:
Chunlin Yang
2020-10-28 19:16:23 +08:00
committed by GitHub
parent cb965ce177
commit d61e1e7b23

View File

@@ -217,12 +217,12 @@ class DashNav extends PureComponent<Props> {
renderRightActionsButton() {
const { dashboard, onAddPanel } = this.props;
const { canSave, showSettings } = dashboard.meta;
const { canEdit, showSettings } = dashboard.meta;
const { snapshot } = dashboard;
const snapshotUrl = snapshot && snapshot.originalUrl;
const buttons: ReactNode[] = [];
if (canSave) {
if (canEdit) {
buttons.push(
<DashNavButton
classSuffix="save"