Render template variables manage button based on authorization
Signed-off-by: Jared Scheib <jared.scheib@gmail.com>pull/10616/head
parent
4c40055aff
commit
0970629a39
|
@ -2,6 +2,8 @@ import React, {PropTypes} from 'react'
|
|||
import classnames from 'classnames'
|
||||
import calculateSize from 'calculate-size'
|
||||
|
||||
import Authorized, {EDITOR_ROLE} from 'src/auth/Authorized'
|
||||
|
||||
import Dropdown from 'shared/components/Dropdown'
|
||||
|
||||
const minTempVarDropdownWidth = 146
|
||||
|
@ -75,6 +77,7 @@ const TemplateControlBar = ({
|
|||
This dashboard does not have any Template Variables
|
||||
</div>}
|
||||
</div>
|
||||
<Authorized requiredRole={EDITOR_ROLE}>
|
||||
<button
|
||||
className="btn btn-primary btn-sm template-control--manage"
|
||||
onClick={onOpenTemplateManager}
|
||||
|
@ -82,6 +85,7 @@ const TemplateControlBar = ({
|
|||
<span className="icon cog-thick" />
|
||||
Manage
|
||||
</button>
|
||||
</Authorized>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Reference in New Issue