Block Time Logging on a Specific Status
Set a New Workflow Property
You can set a workflow property to ensure that users can’t log time on a specific status in your workflow. This is useful for preventing users from logging time on closed work items.
Go to Jira Settings > Work items > Workflows.
Find the appropriate workflow and click Edit.
Select the Status where logging should be restricted

Select Properties in the modal box that appears
Add '
jira.permission.work.denied
' to the Property Key in the Add New Property formSet the Property Value as True

You can put a workflow Property on any transition, not only DONE.