|
@@ -56,10 +56,12 @@ import com.lemon.lifecenter.common.LifeCenterSessionController;
|
|
|
import com.lemon.lifecenter.dto.CenterInfoDTO;
|
|
|
import com.lemon.lifecenter.dto.FileDownloadDTO;
|
|
|
import com.lemon.lifecenter.dto.PatientDTO;
|
|
|
+import com.lemon.lifecenter.dto.PushDTO;
|
|
|
import com.lemon.lifecenter.dto.StaffDTO;
|
|
|
import com.lemon.lifecenter.service.CenterService;
|
|
|
import com.lemon.lifecenter.service.FileDownloadService;
|
|
|
import com.lemon.lifecenter.service.PatientService;
|
|
|
+import com.lemon.lifecenter.service.PushService;
|
|
|
import com.lemon.lifecenter.service.StaffService;
|
|
|
|
|
|
|
|
@@ -79,6 +81,9 @@ public class PatientController extends LifeCenterController {
|
|
|
@Autowired
|
|
|
private FileDownloadService fileDownloadService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private PushService pushService;
|
|
|
+
|
|
|
@Autowired
|
|
|
private LifeCenterConfigVO config;
|
|
|
|
|
@@ -515,6 +520,7 @@ public class PatientController extends LifeCenterController {
|
|
|
@ResponseBody
|
|
|
public String nonFaceStart(
|
|
|
@RequestParam( value="pId", required = true ) String pId,
|
|
|
+ @RequestParam( value="patientIdx", required = true ) String patientIdx,
|
|
|
@RequestParam( value="roomId", required = true ) String roomId,
|
|
|
@RequestParam( value="pName", required = true ) String pName,
|
|
|
HttpServletRequest request, HttpServletResponse response) throws Exception {
|
|
@@ -549,6 +555,29 @@ public class PatientController extends LifeCenterController {
|
|
|
|
|
|
if (!message.equals("")) {
|
|
|
//error
|
|
|
+ } else {
|
|
|
+ int sesCenterCode = Integer.valueOf( LifeCenterSessionController.getSession( request, "sesCenterCode" ) ) ;
|
|
|
+ String sesId = LifeCenterSessionController.getSession( request, "sesId" );
|
|
|
+ String remoteIp = LifeCenterFunction.getRemoteAddr( request );
|
|
|
+
|
|
|
+ PushDTO dto = new PushDTO();
|
|
|
+
|
|
|
+ dto.setPatientIdx(Integer.valueOf(patientIdx));
|
|
|
+
|
|
|
+ pushService.insertPushTargetTemp(dto);
|
|
|
+
|
|
|
+ dto.setSendType("D");
|
|
|
+ dto.setTargetType("P");
|
|
|
+ dto.setPushTitle("비대면 진료");
|
|
|
+ dto.setPushContent("비대면 진료를 요청하였습니다.");
|
|
|
+ dto.setPushPayLoad1("nonface");
|
|
|
+
|
|
|
+ dto.setCenterCode( sesCenterCode );
|
|
|
+ dto.setSender( sesId );
|
|
|
+ dto.setSenderIp( remoteIp );
|
|
|
+ dto.setSendState( "W" );
|
|
|
+
|
|
|
+ pushService.insertPushData(dto);
|
|
|
}
|
|
|
String hashData = LifeCenterFunction.getSignature(config.nonFaceApiSecret, config.nonFaceApiKey, roomId + userId); //"1011503101"
|
|
|
|