static function getMap()
{
return array(
'ID' => array(
'data_type' => 'integer',
'primary' => true,
'autocomplete' => true,
),
'DATE_CREATE' => array(
'data_type' => 'datetime',
'default_value' => new DateTime(),
),
'CREATED_BY' => array(
'data_type' => 'integer',
),
'ACTIVE' => array(
'data_type' => 'boolean',
'required' => true,
'default_value' => 'Y',
'values' => array('N', 'Y')
),
'ACTIVE_CHANGE_DATE' => array(
'data_type' => 'datetime',
'default_value' => new DateTime(),
),
'ACTIVE_CHANGE_BY' => array(
'data_type' => 'integer',
),
'NAME' => array(
'data_type' => 'string',
'required' => true,
'title' => Loc::getMessage('CRM_BUTTON_FIELD_NAME_TITLE'),
),
'BACKGROUND_COLOR' => array(
'data_type' => 'string',
),
'ICON_COLOR' => array(
'data_type' => 'string',
),
'LOCATION' => array(
'data_type' => 'enum',
'default_value' => self::ENUM_LOCATION_BOTTOM_RIGHT,
'values' => array_keys(self::getLocationList())
),
'DELAY' => array(
'data_type' => 'integer',
),
'LANGUAGE_ID' => array(
'data_type' => 'string',
),
'ITEMS' => array(
'data_type' => 'string',
'required' => true,
'serialized' => true
),
'SETTINGS' => array(
'data_type' => 'string',
'serialized' => true
),
'SECURITY_CODE' => array(
'data_type' => 'string',
'default_value' => function(){
return Random::getString(6);
}
),
'IS_SYSTEM' => array(
'data_type' => 'boolean',
'required' => true,
'default_value' => 'N',
'values' => array('N','Y')
),
'XML_ID' => array(
'data_type' => 'string',
),
);
}