Require field on publish only

by JOakland   Last Updated April 20, 2018 20:07 PM

I have a D8 site on which I would like to require an image field to be completed only when a node is published; if the publish box is not checked, the field should not be required. I was able to do this with a custom module in D7, but since D8 has decoupled entity validation from form validation, I'm at a loss.

I've tried doing this with the Rules module, with no luck.

Tags : 8 forms entities

Related Questions

Validate File Extension In Drupal 8 Entity Form

Updated March 03, 2016 05:03 AM

Get the Entity form value from radio button

Updated July 31, 2017 21:07 PM