Add ref type of ref id.