public static function queryWithAuthor( $config = [] ) {

		$config[ 'relations' ][] = [ 'avatar', 'modelContent', 'modelContent.template', 'modelContent.banner', 'creator' ];

		$config[ 'relations' ][] = [ 'creator.avatar'  => function ( $query ) {
			$fileTable	= CoreTables::getTableName( CoreTables::TABLE_FILE );
			$query->from( "$fileTable aavatar" ); }
		];

		return parent::queryWithAll( $config );
	}
public static function queryWithAuthor( $config = [] ) {

		$config[ 'relations' ][] = [ 'avatar', 'modelContent', 'modelContent.template', 'modelContent.banner', 'creator' ];

		$config[ 'relations' ][] = [ 'creator.avatar'  => function ( $query ) {
			$fileTable	= CoreTables::getTableName( CoreTables::TABLE_FILE );
			$query->from( "$fileTable aavatar" ); }
		];

		return parent::queryWithAll( $config );
	}
public static function queryWithAuthor ( $ config = [ ] ) { $ config [ 'relations' ] [ ] = [ 'avatar' , 'modelContent' , 'modelContent.template' , 'modelContent.banner' , 'creator' ] ; $ config [ 'relations' ] [ ] = [ 'creator.avatar' => function ( $ query ) { $ fileTable = CoreTables :: getTableName ( CoreTables :: TABLE_FILE ) ; $ query -> from ( "$fileTable aavatar" ) ; } ] ; return parent :: queryWithAll ( $ config ) ; }
Return query to find the model with avatar, content, template, banner, author and author avatar.

@param array $config
@return \yii\db\ActiveQuery to query with avatar, content, template, banner, author and author avatar.
Return query to find the model with avatar content template banner author and author avatar .