public static function entityDefinition() { /** @var static $columns */ $columns = new \stdClass(); $columns->diafilmId = Diafilm::entityDefinition()->id; $columns->tagId = Tag::entityDefinition()->id; $def = new Table($columns); return $def; }
public static function entityDefinition() { /** @var static $columns */ $columns = new \stdClass(); $columns->diafilmId = Diafilm::entityDefinition()->id; $columns->imageId = Image::entityDefinition()->id; $columns->position = new Column(Column::INTEGER); $def = new Table($columns); $def->setPrimaryKey($columns->diafilmId, $columns->imageId); return $def; }