add elasticsearch terms query