|
|
|
@ -8,6 +8,7 @@ import com.rabbitmq.client.Channel;
|
|
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
|
import org.springblade.common.constant.RabbitConstant; |
|
|
|
|
import org.springblade.common.exception.CustomerException; |
|
|
|
|
import org.springblade.core.redis.cache.BladeRedis; |
|
|
|
|
import org.springblade.core.tool.utils.StringUtil; |
|
|
|
|
import org.springframework.amqp.core.Message; |
|
|
|
|
import org.springframework.amqp.rabbit.annotation.RabbitHandler; |
|
|
|
@ -35,6 +36,8 @@ public class DealWithDataHandler {
|
|
|
|
|
private IPanFactoryDataService panFactoryDataService; |
|
|
|
|
@Autowired |
|
|
|
|
private IFactoryCommonService factoryCommonService; |
|
|
|
|
@Autowired |
|
|
|
|
private BladeRedis bladeRedis; |
|
|
|
|
|
|
|
|
|
private Integer retryCount = 1; |
|
|
|
|
|
|
|
|
@ -70,12 +73,11 @@ public class DealWithDataHandler {
|
|
|
|
|
if ("4".equals(status)) { |
|
|
|
|
panFactoryDataService.handleDataToPlatform(unitNo, operationTime); |
|
|
|
|
}else if("2".equals(status)){ |
|
|
|
|
// //同步打托数据
|
|
|
|
|
// if(!Objects.isNull(trayId)){
|
|
|
|
|
// factoryCommonService.syncTrayTypeData(unitNo,trayId,currentWarehouseId);
|
|
|
|
|
// }
|
|
|
|
|
bladeRedis.setEx("tray-"+unitNo,unitNo,30L); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
//同步打托数据
|
|
|
|
|
factoryCommonService.syncTrayTypeData(unitNo,trayId,currentWarehouseId); |
|
|
|
|
|
|
|
|
|
} catch (Exception e) { |
|
|
|
|
e.printStackTrace(); |
|
|
|
|