Contentful logo

Contentful Community

Disable or lock Fields

Hey All,

I have the need create an extension that will disable all the entry fields based on certain conditions.
One, which is pretty straight forward, where I would just have a button where authors with privs would be able to click and Lock/Unlock the record.

I had quickly created a field level extension the other day that has a button and just toggles disabled is true false, and then updates 0/1 into a hidden meta field (so I could persist it).

But I dont think field level is what I am looking for, as I dont think I have access to the other fields in the entry’s DOM properties.

Has anyone else done something similar that locks all the fields records, (maybe sidebar, just havent played with that enough). Are there any exposed methods that already perform this that you are aware of?

Also, eventually want to make this where only the originator of the lock or Admin can revert, or even to where select users can edit and others are locked, so this might be able to be used in conjunction with a workflow so as to prevent others from making edits on approvals in flight.


I am also looking for same kind of functionality.

I was able to create an entry level UI extension to do this. You do have to reimplement the fields, however there are React components using Forma36 that mimic the built in input types in Contentful.