package com.neusoft.smart.pos.gateway.controller;


import com.neusoft.smart.pos.gateway.service.PrinterService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@Api(value = "打印服务使用rest接口", description = "打印服务使用rest接口")
@RestController
@RequestMapping(path = "/unionService/printer")
@Validated
public class PrinterController {

	@Autowired
	private PrinterService printerService;

	@ApiOperation(value = "打印任务推送接口", notes = "打印任务推送使用方法")
	@GetMapping("/pushPrinterTask")
	public void pushPrinterTask(@RequestParam(value="orderNumber",defaultValue = "") String orderNumber,@RequestParam(value="operationType",defaultValue = "") String operationType){
		printerService.pushPrinterTaskByOrderNumber(orderNumber,operationType);
	}

}
	