package com.example.controller;
|
|
import cn.hutool.core.util.XmlUtil;
|
import cn.hutool.json.JSONObject;
|
import cn.hutool.json.JSONUtil;
|
import com.example.constant.ApiParamsConstants;
|
import com.example.factory.ServiceFactory;
|
import com.example.service.HisService;
|
import com.example.service.PacsService;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.web.bind.annotation.*;
|
|
import java.util.Map;
|
|
@RestController
|
@RequestMapping("/api/pacs")
|
public class PacsController {
|
|
private final ServiceFactory serviceFactory;
|
|
@Autowired
|
public PacsController(ServiceFactory serviceFactory) {
|
this.serviceFactory = serviceFactory;
|
}
|
|
|
/**
|
* 3.2.2.申请单推送接口
|
* @return
|
*/
|
@PostMapping("/{hospName}/orderAll")
|
public String queryOrder(@PathVariable String hospName, @RequestBody String xml){
|
PacsService pacsService = serviceFactory.getPacsService(hospName);
|
return pacsService.orderAdd(xml);
|
}
|
}
|