Statutory delegates can vote at APC presidential primary, court rules