refactor ajaxHandler service 4