身份证读取(完成)、社保卡读取(待调试)

This commit is contained in:
2025-02-17 16:58:54 +08:00
parent 6ca1cdce4b
commit 47c9d8dc5a
30 changed files with 7692 additions and 1498 deletions

View File

@@ -14,20 +14,19 @@ import org.springframework.web.bind.annotation.RestController;
*/
@Slf4j
@RestController
@RequestMapping("cardReader")
@RequestMapping("readCard")
public class CardReaderController {
@Autowired
private CardReaderService cardReaderService;
/**
* 连接设备并读取身份证信息
*
* @return
*/
@GetMapping("connectedDevice")
public Result<?> connectedDevice(@RequestParam(name = "devName") String devName) {
@GetMapping("IDCardReader")
public Result IDCardReader() {
try {
return cardReaderService.connectedDevice(devName);
return cardReaderService.IDCardReader();
} catch (Exception e) {
e.printStackTrace();
log.info("设备连接失败 {}", e.getMessage());
@@ -38,13 +37,12 @@ public class CardReaderController {
/**
* 连接设备并读取社保卡信息
*
* @return
*/
@GetMapping("readSocialSecurityCard")
public Result<?> readSocialSecurityCard(@RequestParam(name = "devName") String devName) {
@GetMapping("SocialSecurityCardReader")
public Result<?> SocialSecurityCardReader() {
try {
return cardReaderService.readSocialSecurityCard(devName);
return cardReaderService.SocialSecurityCardReader();
} catch (Exception e) {
e.printStackTrace();
log.info("连接设备并读取社保卡信息失败 {}", e.getMessage());