mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 21:00:31 +00:00
41 lines
1.1 KiB
TypeScript
41 lines
1.1 KiB
TypeScript
// @ts-nocheck
|
|
import React from 'react';
|
|
import { Button, Intent } from '@blueprintjs/core';
|
|
import { useHistory } from 'react-router-dom';
|
|
import { Can, FormattedMessage as T, EmptyStatus } from '@/components';
|
|
import { ItemAction, AbilitySubject } from '@/constants/abilityOption';
|
|
|
|
export default function ItemsEmptyStatus() {
|
|
const history = useHistory();
|
|
|
|
return (
|
|
<EmptyStatus
|
|
title={<T id={'manage_the_organization_s_services_and_products'} />}
|
|
description={
|
|
<p>
|
|
<T id={'here_a_list_of_your_organization_products_and_services'} />
|
|
</p>
|
|
}
|
|
action={
|
|
<>
|
|
<Can I={ItemAction.Create} a={AbilitySubject.Item}>
|
|
<Button
|
|
intent={Intent.PRIMARY}
|
|
large={true}
|
|
onClick={() => {
|
|
history.push('/items/new');
|
|
}}
|
|
>
|
|
<T id={'new_item'} />
|
|
</Button>
|
|
|
|
<Button intent={Intent.NONE} large={true}>
|
|
<T id={'learn_more'} />
|
|
</Button>
|
|
</Can>
|
|
</>
|
|
}
|
|
/>
|
|
);
|
|
}
|