How to enter data into a property List using API 1-C Bitrix?

Hello! How to enter data in ErrorLog which has a property of type List with value:
XML_ID: Y
Value: Yes

Tried this way not working ( $filled_field = "Y" - is also not working)
$empty_field = "N";
 $filled_field = "Yes";
 // $filled_field = "Y";

 !empty($_POST['girl']) ? $girl = $filled_field : $girl = $empty_field;
 !empty($_POST['boy']) ? $boy = $filled_field : $boy = $empty_field;
 !empty($_POST['gab']) ? $gab = $filled_field : $gab = $empty_field;

CModule::IncludeModule('iblock');
 $el = new CIBlockElement;
 $iblock_id = 17;
 $section_id = false;

 $PROP = array();
 $PROP['ATT_SUBS_GIRL'] = $girl;
 $PROP['ATT_SUBS_BOY'] = $boy;
 $PROP['ATT_SUBS_GAB'] = $gab;

 $fields = array(
 "DATE_CREATE" => date("d.m.Y H:i:s"),
 "CREATED_BY" => $GLOBALS['USER']->GetID(),
 "IBLOCK_SECTION" => false,
 "IBLOCK_ID" => $iblock_id,
 "PROPERTY_VALUES" => $PROP,
 "NAME" => date("d.m.Y H:i:s"),
 "ACTIVE" => "Y"
);
 if ( ! $el->Add($fields) ) {
 $result = false;
 }


Prompt in what direction to move? thank you
March 19th 20 at 09:18
1 answer
March 19th 20 at 09:20
Solution
As the value of a property of type "List" should be transferred to XML_ID, and ID.
5ca03b88124d6416139402.png

Find more questions by tags 1C-BitrixAPI