I am trying to conditionally hide the save as draft button until a specific field is not blank. I have tried plagiarizing some JavaScript and manipulating it, as I don't know JavaScript at all, but have usually been able to get it to work after some trial and error. I can't seem to get this one to work though. Any help is appreciated.
$(document).ready(function() {
if ($('.PolyType input').val() == ""){
$('#IsDraft').parent().hide();}
});