Merge branch 'dev'
This commit is contained in:
commit
5b86609369
|
@ -11,11 +11,13 @@ import org.apache.commons.lang3.StringUtils;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
import org.springframework.util.CollectionUtils;
|
import org.springframework.util.CollectionUtils;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
import springfox.documentation.annotations.ApiIgnore;
|
import springfox.documentation.annotations.ApiIgnore;
|
||||||
import sw.vc3term.contingencyplan.ContingencyPlanUtil;
|
import sw.vc3term.contingencyplan.ContingencyPlanUtil;
|
||||||
|
|
||||||
|
import javax.annotation.PostConstruct;
|
||||||
import java.io.UnsupportedEncodingException;
|
import java.io.UnsupportedEncodingException;
|
||||||
import java.net.Inet4Address;
|
import java.net.Inet4Address;
|
||||||
import java.net.InetAddress;
|
import java.net.InetAddress;
|
||||||
|
@ -39,19 +41,27 @@ public class EnkeController {
|
||||||
private static final String videoConfernceIp = "35.1.190.62";
|
private static final String videoConfernceIp = "35.1.190.62";
|
||||||
private static final int videoConferncePort = 8756;
|
private static final int videoConferncePort = 8756;
|
||||||
|
|
||||||
private static final ContingencyPlanUtil cp;
|
private static ContingencyPlanUtil cp = null;
|
||||||
|
|
||||||
private static final Logger logger = LoggerFactory.getLogger(ActHistoryService.class);
|
private static final Logger logger = LoggerFactory.getLogger(ActHistoryService.class);
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private EnkeService enkeService;
|
private EnkeService enkeService;
|
||||||
|
@Value("#{new Boolean(${enke.enable})}")
|
||||||
|
private Boolean enke; // 是否进行恩科会议组会
|
||||||
|
|
||||||
static {
|
@PostConstruct
|
||||||
|
public void init() {
|
||||||
|
if (enke) {
|
||||||
cp = ContingencyPlanUtil.getInstance();
|
cp = ContingencyPlanUtil.getInstance();
|
||||||
// 初始化会议
|
// 初始化会议
|
||||||
cp.init(videoConfernceIp, videoConferncePort);
|
cp.init(videoConfernceIp, videoConferncePort);
|
||||||
List<String> ips = getLocalIP();
|
List<String> ips = getLocalIP();
|
||||||
cp.setLocalAddress(CollectionUtils.isEmpty(ips) ? "0.0.0.0" : ips.get(0), ContingencyPlanUtil.LOCAL_PORT);
|
cp.setLocalAddress(CollectionUtils.isEmpty(ips) ? "0.0.0.0" : ips.get(0), ContingencyPlanUtil.LOCAL_PORT);
|
||||||
|
logger.info("开启组会功能成功!");
|
||||||
|
} else {
|
||||||
|
logger.info("不开启组会功能");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -112,6 +122,7 @@ public class EnkeController {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
logger.info("本机ip:" + ips);
|
||||||
return ips;
|
return ips;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -179,4 +179,7 @@ shangdongtong:
|
||||||
reminders:
|
reminders:
|
||||||
# 催办间隔天数
|
# 催办间隔天数
|
||||||
interval: 7
|
interval: 7
|
||||||
|
# 恩科会议
|
||||||
|
enke:
|
||||||
|
enable: true
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue