Conditional Inline editing in details page

Hello guys,

Has anyone tried the following. In a details page, when displaying connected record in a table to allow inline editing only if a status on the main record (which we open the details for) is “EDIT” or something similar. If the status is “NO EDIT” the inline editing to be disabled?

I don`t see any other easy to use option to edit connected records through a details page.