Parcourir la source

Merge remote-tracking branch 'remotes/origin/master' into SiChuanJiaoTou

MaiXinRong il y a 10 ans
Parent
commit
9c13e83b45

+ 13 - 2
DataModules/OtherMeasureOnceDm.pas

@@ -3,6 +3,7 @@ unit OtherMeasureOnceDm;
 interface
 interface
 
 
 uses
 uses
+  CalcDecimal,
   SysUtils, Classes, sdDB, sdProvider, ADODB;
   SysUtils, Classes, sdDB, sdProvider, ADODB;
 
 
 type
 type
@@ -20,13 +21,16 @@ type
 
 
     function GetNewID: Integer;
     function GetNewID: Integer;
     function GetNewSerialNo: Integer;
     function GetNewSerialNo: Integer;
+    function GetDecimal: TCalcDecimal;
   public
   public
     constructor Create(AProjectData: TObject);
     constructor Create(AProjectData: TObject);
     destructor Destroy; override;
     destructor Destroy; override;
 
 
     procedure Open(AConnection: TADOConnection);
     procedure Open(AConnection: TADOConnection);
     procedure Close;
     procedure Close;
-    procedure Save;    
+    procedure Save;
+    
+    property Decimal: TCalcDecimal read GetDecimal;
   end;
   end;
 
 
 implementation
 implementation
@@ -132,7 +136,9 @@ begin
     begin
     begin
       DataSetErrorMessage(Allow, '编号、名称不可同时为空,请先填写编号或名称,再填写其他信息。');
       DataSetErrorMessage(Allow, '编号、名称不可同时为空,请先填写编号或名称,再填写其他信息。');
       sddOnce.Remove(AValue.Owner);
       sddOnce.Remove(AValue.Owner);
-    end;
+    end
+    else if Pos('TotalPrice', AColumn.FieldName) > 0 then
+      Text := FloatToStr(Decimal.TotalPrice.RoundTo(StrToFloatDef(Text, 0)));
   end;
   end;
 end;
 end;
 
 
@@ -152,4 +158,9 @@ begin
     GetDisplayText;
     GetDisplayText;
 end;
 end;
 
 
+function TOtherMeasureOnceData.GetDecimal: TCalcDecimal;
+begin
+  Result := TProjectData(FProjectData).ProjProperties.DecimalManager.Common;
+end;
+
 end.
 end.

+ 11 - 1
DataModules/OtherMeasurePhaseDm.pas

@@ -3,6 +3,7 @@ unit OtherMeasurePhaseDm;
 interface
 interface
 
 
 uses
 uses
+  CalcDecimal,
   SysUtils, Classes, sdDB, sdProvider, ADODB, OMPhaseRecord;
   SysUtils, Classes, sdDB, sdProvider, ADODB, OMPhaseRecord;
 
 
 type
 type
@@ -35,6 +36,7 @@ type
     procedure BeforeBatchOperation;
     procedure BeforeBatchOperation;
     procedure AfterBatchOperation;
     procedure AfterBatchOperation;
     procedure SetFilterDeletedRec(const Value: Boolean);
     procedure SetFilterDeletedRec(const Value: Boolean);
+    function GetDecimal: TCalcDecimal;
   public
   public
     constructor Create(AProjectData: TObject);
     constructor Create(AProjectData: TObject);
     destructor Destroy; override;
     destructor Destroy; override;
@@ -44,6 +46,7 @@ type
 
 
     procedure LoadCurStageData;
     procedure LoadCurStageData;
 
 
+    property Decimal: TCalcDecimal read GetDecimal;
     property FilterDeletedRec: Boolean read FFilterDeletedRec write SetFilterDeletedRec;
     property FilterDeletedRec: Boolean read FFilterDeletedRec write SetFilterDeletedRec;
   end;
   end;
 
 
@@ -265,7 +268,9 @@ begin
     begin
     begin
       DataSetErrorMessage(Allow, '编号、名称不可同时为空,请先填写编号或名称,再填写其他信息。');
       DataSetErrorMessage(Allow, '编号、名称不可同时为空,请先填写编号或名称,再填写其他信息。');
       sddPhase.Remove(AValue.Owner);
       sddPhase.Remove(AValue.Owner);
-    end;
+    end
+    else if Pos('TotalPrice', AColumn.FieldName) > 0 then
+      Text := FloatToStr(Decimal.TotalPrice.RoundTo(StrToFloatDef(Text, 0)));
   end;
   end;
 end;
 end;
 
 
@@ -318,4 +323,9 @@ begin
     GetDisplayText;
     GetDisplayText;
 end;
 end;
 
 
+function TOtherMeasurePhaseData.GetDecimal: TCalcDecimal;
+begin
+  Result := TProjectData(FProjectData).ProjProperties.DecimalManager.Common;
+end;
+
 end.
 end.

+ 2 - 2
Dprs/Pro/Measure.dof

@@ -115,7 +115,7 @@ AutoIncBuild=1
 MajorVer=3
 MajorVer=3
 MinorVer=1
 MinorVer=1
 Release=6
 Release=6
-Build=1035
+Build=1036
 Debug=0
 Debug=0
 PreRelease=0
 PreRelease=0
 Special=0
 Special=0
@@ -126,7 +126,7 @@ CodePage=936
 [Version Info Keys]
 [Version Info Keys]
 CompanyName=珠海纵横创新软件有限公司
 CompanyName=珠海纵横创新软件有限公司
 FileDescription=纵横结算决算计量一体化专业版
 FileDescription=纵横结算决算计量一体化专业版
-FileVersion=3.1.6.1035
+FileVersion=3.1.6.1036
 InternalName=
 InternalName=
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalTrademarks=Measure
 LegalTrademarks=Measure

BIN
Dprs/Pro/Measure.res


+ 2 - 2
Dprs/Pro/Measure_Cloud.dof

@@ -115,7 +115,7 @@ AutoIncBuild=1
 MajorVer=3
 MajorVer=3
 MinorVer=1
 MinorVer=1
 Release=6
 Release=6
-Build=1035
+Build=1036
 Debug=0
 Debug=0
 PreRelease=0
 PreRelease=0
 Special=0
 Special=0
@@ -126,7 +126,7 @@ CodePage=936
 [Version Info Keys]
 [Version Info Keys]
 CompanyName=珠海纵横创新软件有限公司
 CompanyName=珠海纵横创新软件有限公司
 FileDescription=纵横结算决算计量一体化云版
 FileDescription=纵横结算决算计量一体化云版
-FileVersion=3.1.6.1035
+FileVersion=3.1.6.1036
 InternalName=
 InternalName=
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalTrademarks=Measure
 LegalTrademarks=Measure

BIN
Dprs/Pro/Measure_Cloud.res


+ 2 - 2
Dprs/Pro/Measure_GuangDong.dof

@@ -115,7 +115,7 @@ AutoIncBuild=1
 MajorVer=3
 MajorVer=3
 MinorVer=1
 MinorVer=1
 Release=6
 Release=6
-Build=1035
+Build=1036
 Debug=0
 Debug=0
 PreRelease=0
 PreRelease=0
 Special=0
 Special=0
@@ -126,7 +126,7 @@ CodePage=936
 [Version Info Keys]
 [Version Info Keys]
 CompanyName=珠海纵横创新软件有限公司
 CompanyName=珠海纵横创新软件有限公司
 FileDescription=纵横结算决算计量一体化广东专业版
 FileDescription=纵横结算决算计量一体化广东专业版
-FileVersion=3.1.6.1035
+FileVersion=3.1.6.1036
 InternalName=
 InternalName=
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalTrademarks=Measure
 LegalTrademarks=Measure

BIN
Dprs/Pro/Measure_GuangDong.res


+ 2 - 2
Dprs/Pro/Measure_GuangDong_Cloud.dof

@@ -115,7 +115,7 @@ AutoIncBuild=1
 MajorVer=3
 MajorVer=3
 MinorVer=1
 MinorVer=1
 Release=6
 Release=6
-Build=1035
+Build=1036
 Debug=0
 Debug=0
 PreRelease=0
 PreRelease=0
 Special=0
 Special=0
@@ -126,7 +126,7 @@ CodePage=936
 [Version Info Keys]
 [Version Info Keys]
 CompanyName=珠海纵横创新软件有限公司
 CompanyName=珠海纵横创新软件有限公司
 FileDescription=纵横结算决算计量一体化广东云版
 FileDescription=纵横结算决算计量一体化广东云版
-FileVersion=3.1.6.1035
+FileVersion=3.1.6.1036
 InternalName=
 InternalName=
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalTrademarks=Measure
 LegalTrademarks=Measure

BIN
Dprs/Pro/Measure_GuangDong_Cloud.res


+ 2 - 2
Dprs/Pro/Measure_TZ.dof

@@ -115,7 +115,7 @@ AutoIncBuild=1
 MajorVer=3
 MajorVer=3
 MinorVer=1
 MinorVer=1
 Release=6
 Release=6
-Build=1035
+Build=1036
 Debug=0
 Debug=0
 PreRelease=0
 PreRelease=0
 Special=0
 Special=0
@@ -126,7 +126,7 @@ CodePage=936
 [Version Info Keys]
 [Version Info Keys]
 CompanyName=珠海纵横创新软件有限公司
 CompanyName=珠海纵横创新软件有限公司
 FileDescription=纵横0号台账专业版
 FileDescription=纵横0号台账专业版
-FileVersion=3.1.6.1035
+FileVersion=3.1.6.1036
 InternalName=
 InternalName=
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalCopyright=版权所有(C)珠海纵横创新软件有限公司2003-2016
 LegalTrademarks=Measure
 LegalTrademarks=Measure

BIN
Dprs/Pro/Measure_TZ.res


+ 2 - 0
Forms/ProjectPropertiesFrm.pas

@@ -568,6 +568,8 @@ begin
     FProjProperties.QuantityDigit := udQuantity.Position;
     FProjProperties.QuantityDigit := udQuantity.Position;
     FProjProperties.TotalPriceDigit := udTotalPrice.Position;
     FProjProperties.TotalPriceDigit := udTotalPrice.Position;
     FProjectData.ResetFloatDigitView;
     FProjectData.ResetFloatDigitView;
+    FProjProperties.DecimalManager.Common.Quantity.Digit := udQuantity.Position;
+    FProjProperties.DecimalManager.Common.TotalPrice.Digit := udTotalPrice.Position;    
     FProjProperties.DecimalManager.PriceMargin.Quantity.Digit := udQuantity.Position;
     FProjProperties.DecimalManager.PriceMargin.Quantity.Digit := udQuantity.Position;
     FProjProperties.DecimalManager.PriceMargin.TotalPrice.Digit := udTotalPrice.Position;
     FProjProperties.DecimalManager.PriceMargin.TotalPrice.Digit := udTotalPrice.Position;
   end;
   end;