补招逻辑修改,手动补招和前端采用websokcet通讯

This commit is contained in:
hzj
2025-08-25 09:11:50 +08:00
parent 99f12e74fb
commit 7bee39f076
2 changed files with 5 additions and 4 deletions

View File

@@ -114,7 +114,7 @@ public class DataRecallController extends BaseController {
if(collect1.containsKey(temp)&&collect1.get(temp).containsKey(curDateString)){ if(collect1.containsKey(temp)&&collect1.get(temp).containsKey(curDateString)){
DataIntegrityDto dto = collect1.get(temp).get(curDateString).get(0); DataIntegrityDto dto = collect1.get(temp).get(curDateString).get(0);
if( dto.getDueTime()!=0){ if( dto.getDueTime()!=0){
int i = (dto.getRealTime()) / dto.getDueTime(); double i =(double)dto.getRealTime() / dto.getDueTime();
if( i>=0.98){ if( i>=0.98){
recallType=3; recallType=3;
} else if(i<0.98&&i>0.8){ } else if(i<0.98&&i>0.8){
@@ -332,7 +332,7 @@ public class DataRecallController extends BaseController {
if(collect1.containsKey(temp)&&collect1.get(temp).containsKey(curDateString)){ if(collect1.containsKey(temp)&&collect1.get(temp).containsKey(curDateString)){
DataIntegrityDto dto = collect1.get(temp).get(curDateString).get(0); DataIntegrityDto dto = collect1.get(temp).get(curDateString).get(0);
if( dto.getDueTime()!=0){ if( dto.getDueTime()!=0){
int i = (dto.getRealTime()) / dto.getDueTime(); double i = (double)dto.getRealTime() / dto.getDueTime();
if( i>=0.98){ if( i>=0.98){
recallType=3; recallType=3;
} else if(i<0.98&&i>0.8){ } else if(i<0.98&&i>0.8){

View File

@@ -210,7 +210,7 @@ public class RecallWebSocketServer {
if(collect1.containsKey(temp)&&collect1.get(temp).containsKey(curDateString)){ if(collect1.containsKey(temp)&&collect1.get(temp).containsKey(curDateString)){
DataIntegrityDto dto = collect1.get(temp).get(curDateString).get(0); DataIntegrityDto dto = collect1.get(temp).get(curDateString).get(0);
if( dto.getDueTime()!=0){ if( dto.getDueTime()!=0){
int i = (dto.getRealTime()) / dto.getDueTime(); double i = (double)dto.getRealTime() / dto.getDueTime();
if( i>=0.98){ if( i>=0.98){
recallType=3; recallType=3;
} else if(i<0.98&&i>0.8){ } else if(i<0.98&&i>0.8){
@@ -255,7 +255,7 @@ public class RecallWebSocketServer {
String jsonString =redisUtil.getStringByKey(key); String jsonString =redisUtil.getStringByKey(key);
if(Objects.nonNull(jsonString)){ if(Objects.nonNull(jsonString)){
TopicReplyDTO bean = JSONUtil.toBean(jsonString, TopicReplyDTO.class, true); TopicReplyDTO bean = JSONUtil.toBean(jsonString, TopicReplyDTO.class, true);
redisUtil.delete(key);
flag =false; flag =false;
sendInfo(bean.getResult()); sendInfo(bean.getResult());
BaseParam baseParam = new BaseParam(); BaseParam baseParam = new BaseParam();
@@ -314,6 +314,7 @@ public class RecallWebSocketServer {
String jsonString =redisUtil.getStringByKey(key); String jsonString =redisUtil.getStringByKey(key);
if(Objects.nonNull(jsonString)){ if(Objects.nonNull(jsonString)){
TopicReplyDTO bean = JSONUtil.toBean(jsonString, TopicReplyDTO.class, true); TopicReplyDTO bean = JSONUtil.toBean(jsonString, TopicReplyDTO.class, true);
redisUtil.delete(key);
flag =false; flag =false;
sendInfo(bean.getResult()); sendInfo(bean.getResult());