Browse Source

需求单No.158690 1、称重打码客户端:不允许打负数;

master
yibo 4 years ago
parent
commit
52d9f82c25
1 changed files with 4 additions and 4 deletions
  1. +4
    -4
      ButcherFactory.Form/SegmentProductionAuto_/SegmentProductionAutoForm.cs

+ 4
- 4
ButcherFactory.Form/SegmentProductionAuto_/SegmentProductionAutoForm.cs View File

@ -236,10 +236,10 @@ namespace ButcherFactory.SegmentProductionAuto_
// if (weight == 0)
// weight = (g.StandardWeightLow ?? 4.0m) + 0.1m;
//#endif
if (weight == 0)
if (weight <= 0)
{
//weight = 10;
MessageBox.Show("重量不能为0");
MessageBox.Show("重量必须大于0");
return;
}
if (g.StandardWeight.HasValue)
@ -336,8 +336,8 @@ namespace ButcherFactory.SegmentProductionAuto_
// if (weight == 0)
// weight = (detail.StandardWeightLow ?? 4.0m) + 0.1m;
//#endif
if (weight == 0)
throw new Exception("重量不能为0");
if (weight <= 0)
throw new Exception("重量必须大于0");
if (detail.StandardWeight.HasValue)
{


Loading…
Cancel
Save