• Модуль: main
  • Путь к файлу: ~/bitrix/modules/main/lib/test/typography/authortable.php
  • Класс: BitrixMainTestTypographyAuthorTable
  • Вызов: AuthorTable::getMap
static function getMap()
{
	return [
		(new IntegerField('ID'))
			->configurePrimary()
			->configureAutocomplete(),

		(new StringField('NAME')),

		(new StringField('LAST_NAME')),

		(new ManyToMany('BOOKS', BookTable::class))
			->configureMediatorTableName('(
				(SELECT 1 AS BOOK_ID, 18 AS AUTHOR_ID)
				UNION
				(SELECT 2 AS BOOK_ID, 17 AS AUTHOR_ID)
				UNION
				(SELECT 2 AS BOOK_ID, 18 AS AUTHOR_ID)
			)'),
	];
}