lisai17@sina.com 2020-09-17 11:09:54 +08:00
parent ec1244d27a
commit 865d65b8a7
2 changed files with 26 additions and 6 deletions

View File

@ -139,4 +139,24 @@ public class OrderTempController extends BaseController {
renderJson(OrderTempSyncService.me.invoice(sn, printer, tokenuser));
}
}
@Before(SnValidator.class)
public void print() {
Sysuser tokenuser = SysuserSyncService.me.getSysuserByToken(get("token"));
if (tokenuser == null) {
renderJson(Result.noauth());
return;
}
String sn = get("sn");
String printer = get("printer", Enums.PrinterIdEnum.printer1.name());
if (Integer.parseInt(sn.substring(10, 12)) != OrderTypeEnum.TEMP.getTypeid()) {
renderJson(Result.failed("sn 不能为 null"));
} else {
renderJson(OrderService.me.print(sn, printer, tokenuser));
}
}
}

View File

@ -1,12 +1,12 @@
# mysql
# GRANT ALL PRIVILEGES ON *.* TO 'root'@'192.168.1.119' IDENTIFIED BY 'Local_1' WITH GRANT OPTION;
#jdbcUrl=jdbc:mysql://rm-wz9wa070076b2uge2ro.mysql.rds.aliyuncs.com:3306/ssjy_xsx_dev?characterEncoding=utf8&useSSL=false&zeroDateTimeBehavior=convertToNull&useInformationSchema=true&serverTimezone=GMT%2B8&autoReconnect=true
#user=dev_ssjy_xsx
#password=Ssjy_xs_890
jdbcUrl=jdbc:mysql://rm-wz9wa070076b2uge2ro.mysql.rds.aliyuncs.com:3306/ssjy_xsx_dev?characterEncoding=utf8&useSSL=false&zeroDateTimeBehavior=convertToNull&useInformationSchema=true&serverTimezone=GMT%2B8&autoReconnect=true
user=dev_ssjy_xsx
password=Ssjy_xs_890
jdbcUrl=jdbc:mysql://192.168.20.2:3306/ssjy_xsx_dev?characterEncoding=utf8&useSSL=false&zeroDateTimeBehavior=convertToNull&useInformationSchema=true&serverTimezone=GMT%2B8&autoReconnect=true
user=root
password=Ssjy_xsx_890
#jdbcUrl=jdbc:mysql://192.168.20.2:3306/ssjy_xsx_dev?characterEncoding=utf8&useSSL=false&zeroDateTimeBehavior=convertToNull&useInformationSchema=true&serverTimezone=GMT%2B8&autoReconnect=true
#user=root
#password=Ssjy_xsx_890
# redis
redis.basekey=ssjcgl_xsx_dev