|
@@ -352,6 +352,7 @@ procedure TBillsMeasureData.sdvBillsMeasureSetText(var Text: String;
|
|
procedure SetQuantity(ANode: TBillsIDTreeNode; const AField: string);
|
|
procedure SetQuantity(ANode: TBillsIDTreeNode; const AField: string);
|
|
var
|
|
var
|
|
vNode: TBillsIDTreeNode;
|
|
vNode: TBillsIDTreeNode;
|
|
|
|
+ sValue: String;
|
|
begin
|
|
begin
|
|
if CheckStringNull(Text) or CheckNumeric(Text) then
|
|
if CheckStringNull(Text) or CheckNumeric(Text) then
|
|
begin
|
|
begin
|
|
@@ -367,14 +368,15 @@ procedure TBillsMeasureData.sdvBillsMeasureSetText(var Text: String;
|
|
end
|
|
end
|
|
else
|
|
else
|
|
begin
|
|
begin
|
|
- Text := FloatToStr(QuantityRoundTo(EvaluateExprs(Text)));
|
|
|
|
|
|
+ sValue := FloatToStr(QuantityRoundTo(EvaluateExprs(Text)));
|
|
// ±ä¸üӦѡÔñ±ä¸üÁî
|
|
// ±ä¸üӦѡÔñ±ä¸üÁî
|
|
if SameText(AField , 'Qc') or SameText(AField , 'Pc') then
|
|
if SameText(AField , 'Qc') or SameText(AField , 'Pc') then
|
|
- Allow := SelectAndUpdateBGL(GetBillsID, AValue.Owner, StrToFloatDef(Text, 0), AField);
|
|
|
|
|
|
+ Allow := SelectAndUpdateBGL(GetBillsID, AValue.Owner, StrToFloatDef(sValue, 0), AField);
|
|
if not Allow then Exit;
|
|
if not Allow then Exit;
|
|
|
|
|
|
AValue.Owner.ValueByName(AField + 'Flag').AsInteger := 1;
|
|
AValue.Owner.ValueByName(AField + 'Flag').AsInteger := 1;
|
|
AValue.Owner.ValueByName(AField + 'Formula').AsString := Text;
|
|
AValue.Owner.ValueByName(AField + 'Formula').AsString := Text;
|
|
|
|
+ Text := sValue;
|
|
end;
|
|
end;
|
|
|
|
|
|
ANode.Rec.SetIntValue(ANode.Rec.CalcType, 0);
|
|
ANode.Rec.SetIntValue(ANode.Rec.CalcType, 0);
|