Files
yinyitong-zhongyuyuan-dll-hang/src/main/java/com/dpkj/modules/autoReplyPrint/controller/AutoReplyPrintController.java
2025-02-18 15:26:28 +08:00

36 lines
1.0 KiB
Java

package com.dpkj.modules.autoReplyPrint.controller;
import com.dpkj.common.vo.Result;
import com.dpkj.modules.autoReplyPrint.service.AutoReplyPrintService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
/**
* 壁挂打印机
*/
@Slf4j
@RestController
@RequestMapping("autoReplyPrint")
public class AutoReplyPrintController {
@Autowired
private AutoReplyPrintService autoReplyPrintService;
/**
* 获取打印机固件版本
*/
@PostMapping("CPPrinterGetPrinterFirmwareVersion")
public Result<?> CPPrinterGetPrinterFirmwareVersion(@RequestParam(defaultValue = "VID:0x0FE6,PID:0x811E") String USBName) {
return autoReplyPrintService.CPPrinterGetPrinterFirmwareVersion(USBName);
}
/**
* 测试打印
*/
@PostMapping("/testWrite")
private Result<?> testWrite(@RequestParam(defaultValue = "VID:0x0FE6,PID:0x811E") String USBName){
return this.autoReplyPrintService.testWrite(USBName);
}
}