If the 15S is not answered, the system will remind the next person no one to answer the order
It's an interface written to Android and iOS using thinkphp.
(Divided into two terminal one is the client one is the server I am the service)
Client sends order service termination order if 15s No one is receiving feedback to client information
How can this interface be implemented?
Reply content:
If the 15S is not answered, the system will remind the next person no one to answer the order
It's an interface written to Android and iOS using thinkphp.
(Divided into two terminal one is the client one is the server I am the service)
Client sends order service termination order if 15s No one is receiving feedback to client information
How can this interface be implemented?
Why don't you give it to the client?
15s internal interface reaction is processed, no response in the client prompt no one to answer.
Client 15s requests an interface once and returns whether or not someone is receiving the order
var ajaxTimeoutTest = $.ajax({ url:'', //请求的URL **timeout : 1000, //超时时间设置,单位毫秒** type : 'get', //请求方式,get或post data :{}, //请求所传参数,json格式 dataType:'json',//返回的数据格式 success:function(data){ //请求成功的回调函数 alert("成功"); }, complete : function(XMLHttpRequest,status){ //请求完成后最终执行参数 if(status=='timeout'){//超时,status还有success,error等值的情况 ajaxTimeoutTest.abort(); alert("超时"); } }});
You can set the timeout setting, and if the time is up, execute the Timeout method to prompt the client to
First floor is right, do not hand over to the server, the front end 15 seconds after the discovery or no response to think is no one to take orders, or to the user to order for the start time, set the timer, 15 seconds after the response to customer service, Linux timer is the most famous Linux cron