The issue here is that you will need to use the callback function for your view to reload the function after the view performs its AJAX search function.
Add your function inside this callback function as well.
jQuery( document ).on( 'js_event_wpv_parametric_search_triggered', function( event, data ) {
/**
* data.view_unique_id (string) The View unique ID hash
* data.form (object) The jQuery object for the View form
* data.update_form (bool) Whether the custom search form will be updated
* data.update_results (bool) Whether the custom search results will be updated
*/
});
This will allow your code to run again once the search has been triggered.