AuthorAssignedType::GetAuthorTypesByAuthor PHP Метод

GetAuthorTypesByAuthor() публичный статический Метод

public static GetAuthorTypesByAuthor ( integer $p_authorId )
$p_authorId integer
    public static function GetAuthorTypesByAuthor($p_authorId)
    {
        global $g_ado_db;
        $queryStr = 'SELECT * FROM ' . self::TABLE . '
            WHERE fk_author_id = ' . $p_authorId;
        $query = $g_ado_db->Execute($queryStr);
        $authorTypes = array();
        while ($row = $query->FetchRow()) {
            $tmpAuthorType = new AuthorType();
            $tmpAuthorType->fetch($row);
            $authorTypes[] = $tmpAuthorType;
        }
        return $authorTypes;
    }