mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-18 22:33:44 +02:00
remove permission based view
recent changes that were made always show the primary allocation to the end users even if they don't have the read permission.
This commit is contained in:
@@ -6,7 +6,6 @@ import { bytesToHuman, megabytesToHuman } from '@/helpers';
|
||||
import TitledGreyBox from '@/components/elements/TitledGreyBox';
|
||||
import { ServerContext } from '@/state/server';
|
||||
import CopyOnClick from '@/components/elements/CopyOnClick';
|
||||
import Can from '@/components/elements/Can';
|
||||
|
||||
interface Stats {
|
||||
memory: number;
|
||||
@@ -71,14 +70,12 @@ const ServerDetailsBlock = () => {
|
||||
/>
|
||||
{!status ? 'Connecting...' : status}
|
||||
</p>
|
||||
<Can action={'allocation.read'}>
|
||||
<CopyOnClick text={primaryAllocation}>
|
||||
<p css={tw`text-xs mt-2`}>
|
||||
<FontAwesomeIcon icon={faEthernet} fixedWidth css={tw`mr-1`}/>
|
||||
<code css={tw`ml-1`}>{primaryAllocation}</code>
|
||||
</p>
|
||||
</CopyOnClick>
|
||||
</Can>
|
||||
<CopyOnClick text={primaryAllocation}>
|
||||
<p css={tw`text-xs mt-2`}>
|
||||
<FontAwesomeIcon icon={faEthernet} fixedWidth css={tw`mr-1`}/>
|
||||
<code css={tw`ml-1`}>{primaryAllocation}</code>
|
||||
</p>
|
||||
</CopyOnClick>
|
||||
<p css={tw`text-xs mt-2`}>
|
||||
<FontAwesomeIcon icon={faMicrochip} fixedWidth css={tw`mr-1`}/> {stats.cpu.toFixed(2)}%
|
||||
</p>
|
||||
|
||||
Reference in New Issue
Block a user