|
@@ -97,7 +97,7 @@ namespace MySystem.Areas.Api.Controllers.v1
|
|
|
SnNo = SnNo.TrimEnd('\0');
|
|
|
SnNo = SnNo.Substring(0, 20);
|
|
|
}
|
|
|
- if(!string.IsNullOrEmpty(MachineNo))
|
|
|
+ if (!string.IsNullOrEmpty(MachineNo))
|
|
|
{
|
|
|
if (MachineNo.Length > 20)
|
|
|
{
|
|
@@ -116,6 +116,14 @@ namespace MySystem.Areas.Api.Controllers.v1
|
|
|
Models.Main1.PosMachinesTwo pos = PosMachinesTwoService.Query(" PosSn='" + SnNo + "'");
|
|
|
Models.Main1.PosMachines machines = PosMachinesService.Query(" PosSn='" + SnNo + "'");
|
|
|
MerchantInfo merchant = MerchantInfoService.Query(MerchantId);
|
|
|
+ if (pos.BindingState == 1)
|
|
|
+ {
|
|
|
+ return new AppResultJson() { Status = "-1", Info = "绑定失败,该二维码已绑定" };
|
|
|
+ }
|
|
|
+ if (machines.BindingState == 1)
|
|
|
+ {
|
|
|
+ return new AppResultJson() { Status = "-1", Info = "绑定失败,该二维码已绑定" };
|
|
|
+ }
|
|
|
int PosId = 0;
|
|
|
if (SnNo == MachineNo || string.IsNullOrEmpty(MachineNo))
|
|
|
{
|
|
@@ -192,7 +200,7 @@ namespace MySystem.Areas.Api.Controllers.v1
|
|
|
|
|
|
|
|
|
|
|
|
- if(machines.BrandId == 1)
|
|
|
+ if (machines.BrandId == 1)
|
|
|
{
|
|
|
MerchantAddInfo addinfo = MerchantAddInfoService.Query(MerchantId);
|
|
|
|