Commit 86b47e12 by unknown

Merge branch 'release' of 192.168.10.6:caosy/fun-admin into release

parents 8e13d73a 708467f5
...@@ -115,6 +115,7 @@ public class SipPhoneControl { ...@@ -115,6 +115,7 @@ public class SipPhoneControl {
// String agentAid = request.getAttribute("userName").toString(); // String agentAid = request.getAttribute("userName").toString();
String agentAid = SpringSecurityUtil.getCurrentUserName(); String agentAid = SpringSecurityUtil.getCurrentUserName();
String sipPhoneName = request.getParameter("sipPhoneName"); String sipPhoneName = request.getParameter("sipPhoneName");
System.out.println("bbbbbbbbbbbbbbbbbbbbb:"+agentAid+" "+ sipPhoneName+" ");
return sipPhoneService.bind(agentAid, sipPhoneName); return sipPhoneService.bind(agentAid, sipPhoneName);
} }
...@@ -228,6 +229,12 @@ public class SipPhoneControl { ...@@ -228,6 +229,12 @@ public class SipPhoneControl {
String srcGateway = null; String srcGateway = null;
String srcAccessNumber = null; String srcAccessNumber = null;
GetMobileInfoResponse response = sipPhoneService.getMobileInfo(dst);
//如果是上海的手机号码,不需加0,非上海手机号码, 需在手机号码前面加0代表区号
if("0".equals(response.getErrCode()) && "021".equals(response.getAreaCode())){
}else{
dst = "0"+dst;
}
//获得绑定的分机号码 分机A //获得绑定的分机号码 分机A
AgentSipPhoneBindInfoResponse bindInfo = sipPhoneService.getBindInfo(userName, null); AgentSipPhoneBindInfoResponse bindInfo = sipPhoneService.getBindInfo(userName, null);
......
...@@ -20,13 +20,7 @@ import javax.websocket.server.ServerEndpoint; ...@@ -20,13 +20,7 @@ import javax.websocket.server.ServerEndpoint;
public class NewStateWebSocket { public class NewStateWebSocket {
public NewStateWebSocket(){} public NewStateWebSocket(){}
private static NewStateWebSocket single = null;
public static NewStateWebSocket getInstance(){
if(single==null){
single = new NewStateWebSocket();
}
return single;
}
private static Map<String, Session> sessionMap=new HashMap<String, Session>();//在线的客户端session集合,只在第一次new的时候初始化。 private static Map<String, Session> sessionMap=new HashMap<String, Session>();//在线的客户端session集合,只在第一次new的时候初始化。
/** /**
......
...@@ -71,21 +71,7 @@ public final class UserDetailsService extends BaseService implements org.springf ...@@ -71,21 +71,7 @@ public final class UserDetailsService extends BaseService implements org.springf
dbAuths = new ArrayList<GrantedAuthority>(dbAuthsSet); dbAuths = new ArrayList<GrantedAuthority>(dbAuthsSet);
} }
/*//将当前用户添加到callcenter中的 Agent
AgentSipPhoneBindInfoResponse aspbiresp = sipPhoneService.getBindInfo(adminUserBean.getUserName(), null);
if("SUCCESS".equals( aspbiresp.getErrMsg()) &&StringUtils.isNotBlank(aspbiresp.getSipPhoneName())){
// adminUserBean.setSipPhone(aspbiresp.getSipPhoneName());
}else{
// Agent agent = new Agent();
// agent.setAgentName(adminUserBean.getUserName());
// agent.setAid(adminUserBean.getUserName());
// agent.setJobNumber((long)adminUserBean.getId());
// List<Agent> agentList = new ArrayList<Agent>();
// agentList.add(agent);
//同步Agent
sipPhoneService.agentSave(adminUserBean.getUserName(),adminUserBean.getUserName(), 0l);
}
*/
// Ruisheng ruisheng = new Ruisheng(); // Ruisheng ruisheng = new Ruisheng();
Runnable myRunnable = new Ruisheng(adminUserBean); Runnable myRunnable = new Ruisheng(adminUserBean);
Thread ruishengThread = new Thread(myRunnable); Thread ruishengThread = new Thread(myRunnable);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment