I have a hierarchy list of employees in a select list. I need to visually maintain the list with the hierarchy structure so I can't hide the entries. But I need to limit one person from being selected. My Page item with type Select List is called P20_CURRENT_USER. I have a list of names and the one I need to hide is a person's name with their ID value of 221. I created a DA on the page to fire after refresh and can't seem to get the syntax correct.
Can you tell me what is wrong with my syntax?
$('#P20_CURRENT_USER option').val("221").prop("disabled", true);
I am on Apex 19.1.0.00.15