I've tested and it's working.
The only thing that i need to edit & save request so that the value is being saved.
Is there function to 'edit' and save the request? So I can 'preupdate' the request.
var log_bounce = 0;
<PDM_LIST prefix="countTransfeerBounces" factory="alg" where="call_req_id='$args.persistent_id' and type='TR'">
<PDM_IF "$countTransfeerBounces.id" != "0">
log_bounce++;
</PDM_IF>
</PDM_LIST>
document.forms["main_form"].elements["SET.zbounces"].value=log_bounce;
});
Thanks,
Domagoj