| | |
| | | |
| | | import com.ruoyi.common.utils.DateUtils; |
| | | import com.ruoyi.common.utils.RSAPublicKeyExample; |
| | | import com.ruoyi.common.utils.StringUtils; |
| | | import com.smartor.domain.ServiceOutPath; |
| | | import com.smartor.domain.ServiceTask; |
| | | import com.smartor.mapper.ServiceOutPathMapper; |
| | |
| | | ServiceTask serviceTask = serviceTaskMapper.selectServiceTaskByTaskid(Long.valueOf(serviceOutPath.getParam1())); |
| | | RSAPublicKeyExample rsaPublicKeyExample = new RSAPublicKeyExample(); |
| | | String taskId = rsaPublicKeyExample.encryptedData(serviceOutPath.getParam1().toString(), pub_key); |
| | | String patid= rsaPublicKeyExample.encryptedData(serviceOutPath.getParam2().toString(), pub_key); |
| | | String subid= rsaPublicKeyExample.encryptedData(serviceOutPath.getParam6().toString(), pub_key); |
| | | String patid = rsaPublicKeyExample.encryptedData(serviceOutPath.getParam2().toString(), pub_key); |
| | | String subid = rsaPublicKeyExample.encryptedData(serviceOutPath.getParam6().toString(), pub_key); |
| | | Date now = DateUtils.getNowDate(); |
| | | ServiceOutPath sop = new ServiceOutPath(); |
| | | sop.setParam1(taskId); |
| | |
| | | serviceOutPathMapper.insertServiceOutPath(sop); |
| | | //转成16进制并回写radix和updateTime |
| | | serviceOutPath.setRadix(String.format("%03X", sop.getId())); |
| | | serviceOutPath.setUrl(localIP + ":" + req_path + "/wt?p=" + sop.getRadix()); |
| | | serviceOutPath.setUrl(StringUtils.isNotEmpty(req_path) ? localIP + ":" + req_path + "/wt?p=" + sop.getRadix() : localIP + "/wt?p=" + sop.getRadix()); |
| | | serviceOutPathMapper.updateServiceOutPath(serviceOutPath); |
| | | return serviceOutPath.getUrl(); |
| | | } |