package com.example.controller; import com.example.factory.ServiceFactory; import com.example.service.LisService; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; import java.util.Map; /** * @Company: 西安路泰科技有限公司 * @Author: zhaowenxuan * @Date: 2024/12/25 10:13 */ @RestController @RequestMapping("/api/his") public class LisController { private final ServiceFactory serviceFactory; @Autowired public LisController(ServiceFactory serviceFactory) { this.serviceFactory = serviceFactory; } /** * 生成申请单 * @param hospName * @param map * @return */ @PostMapping("/{hospName}/create") public String makeSqd(@PathVariable("hospName") String hospName, @RequestBody Map map){ LisService lisService = serviceFactory.getLisService(hospName); return lisService.makeSqd(map); } }