-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Analysis/report #43
base: master
Are you sure you want to change the base?
Analysis/report #43
Conversation
…nto Edit/TicketMOdel
…admin_ui into Edit/TicketMOdel
Feature
|
{days < 0 && ( | ||
<> | ||
<AccessTimeIcon fontSize='small' color='success' /> | ||
<Typography>{-1 * days} days left</Typography> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need of multiplying it with -1 as its unnecessary. just -{days} days left
should be fine
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here I am doing negative number convert into +ve
@@ -0,0 +1,5 @@ | |||
import { Overdue } from './components/Overduetime'; | |||
|
|||
export const TicketAsTime = () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why to create extra component if there are no extra changes done here? We can just use the Overdue component directly wherever required
const [errorDepartment, setErrorDepartment] = useState<boolean>(false); | ||
const { data: categoriesList, isLoading: listFetching } = | ||
useCategories(departmentId); | ||
const categoryOptions = useMemo(() => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add empty lines between hooks.
If we just don't need the raw categoriesList anywhere instead of manipulating it here inside useMemo you can convert it in your required format inside the useQuery hook itself using the 'select' option
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
select give always manipulated data but this list data use different-different place with deifferent structure
like when it show in drop down [{value:"",lable:""}],
when it use to show category tabel required as it is as we fetch.
assigned: 400, | ||
inprogress: 122, | ||
closed: 220, | ||
resolved: 223, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the dummy data now if not required
return ( | ||
<> | ||
<PieChartDepartment | ||
data1={data1} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the data not available for this chart?
No description provided.