Browse Source

Task #1230 本期价差总额,不再写入“价差调整”节点“本期完成计量--金额”

MaiXinRong 8 years ago
parent
commit
d0fa7993b4

+ 4 - 4
DataModules/BillsMeasureDm.pas

@@ -281,8 +281,8 @@ procedure TBillsMeasureData.sdvBillsMeasureSetText(var Text: String;
   begin
   begin
     iCreatePhase := ANode.Rec.ValueByName('CreatePhaseID').AsInteger;
     iCreatePhase := ANode.Rec.ValueByName('CreatePhaseID').AsInteger;
 
 
-    if ANode.ID = iPriceMarginID then
-      DataSetErrorMessage(Allow, sBills_PMHint);
+    {if ANode.ID = iPriceMarginID then
+      DataSetErrorMessage(Allow, sBills_PMHint);}
 
 
     if SameText('B_Code', AColumn.FieldName) or
     if SameText('B_Code', AColumn.FieldName) or
         SameText('Name', AColumn.FieldName) or
         SameText('Name', AColumn.FieldName) or
@@ -537,8 +537,8 @@ procedure TBillsMeasureData.sdvBillsMeasureNeedLookupRecord(
   begin
   begin
     Result := True;
     Result := True;
 
 
-    if ANode.ID = iPriceMarginID then
-      DataSetErrorMessage(Result, sBills_PMHint);
+    {if ANode.ID = iPriceMarginID then
+      DataSetErrorMessage(Result, sBills_PMHint);}
 
 
     if ANode.HasChildren then
     if ANode.HasChildren then
     begin
     begin

+ 6 - 6
DataModules/PriceMarginBillsDm.pas

@@ -281,16 +281,16 @@ begin
     with TProjectData(FProjectData).ProjectGLData do
     with TProjectData(FProjectData).ProjectGLData do
       CalculateGL_PM(ARec.GLID.AsInteger);
       CalculateGL_PM(ARec.GLID.AsInteger);
     // 更新清单调差数据,材料调差节点数据
     // 更新清单调差数据,材料调差节点数据
-    with TProjectData(FProjectData).PhaseData.StageData do
+    {with TProjectData(FProjectData).PhaseData.StageData do
     begin
     begin
       CalculatePriceMargin(ARec.BillsID.AsInteger);
       CalculatePriceMargin(ARec.BillsID.AsInteger);
       CalculatePriceMarginNode;
       CalculatePriceMarginNode;
-    end;
+    end;}
     // 更新价差清单内存表信息
     // 更新价差清单内存表信息
     with TProjectData(FProjectData).PriceMarginBillsData do
     with TProjectData(FProjectData).PriceMarginBillsData do
       RefreshDetailBills(ARec.BillsID.AsInteger);
       RefreshDetailBills(ARec.BillsID.AsInteger);
     // 更新合同支付
     // 更新合同支付
-    TProjectData(FProjectData).PhaseData.PhasePayData.CalculateAll;
+    //TProjectData(FProjectData).PhaseData.PhasePayData.CalculateAll;
   end;
   end;
 end;
 end;
 
 
@@ -325,16 +325,16 @@ begin
     with TProjectData(FProjectData).ProjectGLData do
     with TProjectData(FProjectData).ProjectGLData do
       CalculateGL_PM(ARec.GLID.AsInteger);
       CalculateGL_PM(ARec.GLID.AsInteger);
     // 更新清单调差数据,材料调差节点数据
     // 更新清单调差数据,材料调差节点数据
-    with TProjectData(FProjectData).PhaseData.StageData do
+    {with TProjectData(FProjectData).PhaseData.StageData do
     begin
     begin
       CalculatePriceMargin(ARec.BillsID.AsInteger);
       CalculatePriceMargin(ARec.BillsID.AsInteger);
       CalculatePriceMarginNode;
       CalculatePriceMarginNode;
-    end;
+    end;}
     // 更新价差清单内存表信息
     // 更新价差清单内存表信息
     with TProjectData(FProjectData).PriceMarginBillsData do
     with TProjectData(FProjectData).PriceMarginBillsData do
       RefreshDetailBills(ARec.BillsID.AsInteger);
       RefreshDetailBills(ARec.BillsID.AsInteger);
     // 更新合同支付
     // 更新合同支付
-    TProjectData(FProjectData).PhaseData.PhasePayData.CalculateAll;
+    //TProjectData(FProjectData).PhaseData.PhasePayData.CalculateAll;
   end;
   end;
 end;
 end;
 
 

+ 1 - 1
DataModules/ProjectGLDm.pas

@@ -224,7 +224,7 @@ begin
     CalculatePM_Quantity(TProjectGLRecord(AValue.Owner));
     CalculatePM_Quantity(TProjectGLRecord(AValue.Owner));
     CalculatePM_TotalPrice(TProjectGLRecord(AValue.Owner));
     CalculatePM_TotalPrice(TProjectGLRecord(AValue.Owner));
     CalculatePALRela(TProjectGLRecord(AValue.Owner));
     CalculatePALRela(TProjectGLRecord(AValue.Owner));
-    CalculateRelaBills(TProjectGLRecord(AValue.Owner));
+    //CalculateRelaBills(TProjectGLRecord(AValue.Owner));
     TProjectData(FProjectData).PriceMarginBillsData.RefreshAllDetailBills;
     TProjectData(FProjectData).PriceMarginBillsData.RefreshAllDetailBills;
   end;
   end;
   if SameText(AValue.FieldName, 'UsedQuantity') then
   if SameText(AValue.FieldName, 'UsedQuantity') then

+ 25 - 14
DataModules/StageDm.pas

@@ -642,7 +642,8 @@ procedure TStageData.CalculateNode(ANode: TsdIDTreeNode);
 
 
   function IsSpecialNode: Boolean;
   function IsSpecialNode: Boolean;
   begin
   begin
-    Result := ANode.ID = iPriceMarginID;
+    //Result := ANode.ID = iPriceMarginID;
+    Result := False;
   end;
   end;
 
 
 begin
 begin
@@ -666,7 +667,7 @@ procedure TStageData.CalculateParent(ANode: TMeasureBillsIDTreeNode);
 var
 var
   iChild: Integer;
   iChild: Integer;
   ChildNode: TMeasureBillsIDTreeNode;
   ChildNode: TMeasureBillsIDTreeNode;
-  fDeal, fQc, fPc, fPM: Double;
+  fDeal, fQc, fPc, fTotal, fPM: Double;
 begin
 begin
   if not Assigned(ANode.StageRec) then Exit;
   if not Assigned(ANode.StageRec) then Exit;
 
 
@@ -682,25 +683,35 @@ begin
     fQc := TotalPriceRoundTo(fQc + ChildNode.StageRec.QcTotalPrice.AsFloat);
     fQc := TotalPriceRoundTo(fQc + ChildNode.StageRec.QcTotalPrice.AsFloat);
     fPc := TotalPriceRoundTo(fPc + ChildNode.StageRec.PcTotalPrice.AsFloat);
     fPc := TotalPriceRoundTo(fPc + ChildNode.StageRec.PcTotalPrice.AsFloat);
     fPM := TotalPriceRoundTo(fPM + ChildNode.StageRec.PM_TotalPrice.AsFloat);
     fPM := TotalPriceRoundTo(fPM + ChildNode.StageRec.PM_TotalPrice.AsFloat);
-  end;
+  end;                                                                      
+  fTotal := TotalPriceRoundTo(fDeal + fQc + fPc);
 
 
   with ANode.StageRec do
   with ANode.StageRec do
   begin
   begin
-    if (DealTotalPrice.AsFloat <> fDeal) or
-       (QcTotalPrice.AsFloat <> fQc) or
-       (PcTotalPrice.AsFloat <> fPc) then
+    if DealTotalPrice.AsFloat <> fDeal then
     begin
     begin
       DealTotalPrice.AsFloat := fDeal;
       DealTotalPrice.AsFloat := fDeal;
-      QcTotalPrice.AsFloat := fQc;
-      PcTotalPrice.AsFloat := fPc;
-      GatherTotalPrice.AsFloat := TotalPriceRoundTo(fDeal + fQc + fPc);
       EndDealTotalPrice.AsFloat := TotalPriceRoundTo(PreDealTotalPrice.AsFloat + fDeal);
       EndDealTotalPrice.AsFloat := TotalPriceRoundTo(PreDealTotalPrice.AsFloat + fDeal);
+    end;
+
+    if QcTotalPrice.AsFloat <> fQc then
+    begin
+      QcTotalPrice.AsFloat := fQc;
       EndQcTotalPrice.AsFloat := TotalPriceRoundTo(PreQcTotalPrice.AsFloat + fQc);
       EndQcTotalPrice.AsFloat := TotalPriceRoundTo(PreQcTotalPrice.AsFloat + fQc);
+    end;
+
+    if PcTotalPrice.AsFloat <> fPc then
+    begin
+      PcTotalPrice.AsFloat := fPc;
       EndPcTotalPrice.AsFloat := TotalPriceRoundTo(PrePcTotalPrice.AsFloat + fPc);
       EndPcTotalPrice.AsFloat := TotalPriceRoundTo(PrePcTotalPrice.AsFloat + fPc);
-      EndGatherTotalPrice.AsFloat := TotalPriceRoundTo(
-        PreGatherTotalPrice.AsFloat + GatherTotalPrice.AsFloat);
     end;
     end;
 
 
+    if GatherTotalPrice.AsFloat <> fTotal then
+    begin
+      GatherTotalPrice.AsFloat := fTotal;
+      EndGatherTotalPrice.AsFloat := TotalPriceRoundTo(PreGatherTotalPrice.AsFloat + fTotal);
+    end;
+    
     if PM_TotalPrice.AsFloat <> fPM then
     if PM_TotalPrice.AsFloat <> fPM then
       PM_TotalPrice.AsFloat := fPM;
       PM_TotalPrice.AsFloat := fPM;
   end;
   end;
@@ -871,9 +882,9 @@ begin
     fPMDiffer := fPM - Rec.PM_TotalPrice.AsFloat;
     fPMDiffer := fPM - Rec.PM_TotalPrice.AsFloat;
     Rec.PM_TotalPrice.AsFloat := fPM;
     Rec.PM_TotalPrice.AsFloat := fPM;
     UpdateParentPriceMargin(ABillsID, fPMDiffer);
     UpdateParentPriceMargin(ABillsID, fPMDiffer);
-    UpdatePriceMarginNode(fPMDiffer);
-    with TProjectData(TPhaseData(FPhaseData).ProjectData).BillsMeasureData do
-     UpdateRecordPM(ABillsID, fPMDiffer);
+    //UpdatePriceMarginNode(fPMDiffer);
+    //with TProjectData(TPhaseData(FPhaseData).ProjectData).BillsMeasureData do
+      //UpdateRecordPM(ABillsID, fPMDiffer);
   end;
   end;
 end;
 end;
 
 

+ 57 - 66
Forms/ProjectPropertiesFrm.dfm

@@ -225,7 +225,8 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           Width = 438
           Width = 438
           Height = 247
           Height = 247
           HorzScrollBar.Range = 401
           HorzScrollBar.Range = 401
-          VertScrollBar.Range = 1157
+          VertScrollBar.Position = 886
+          VertScrollBar.Range = 1133
           Align = alClient
           Align = alClient
           AutoScroll = False
           AutoScroll = False
           BevelInner = bvNone
           BevelInner = bvNone
@@ -242,7 +243,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           OnVScroll = msbBaseVScroll
           OnVScroll = msbBaseVScroll
           object lblDealInfo: TLabel
           object lblDealInfo: TLabel
             Left = 7
             Left = 7
-            Top = 4
+            Top = -882
             Width = 48
             Width = 48
             Height = 12
             Height = 12
             Caption = #21512#21516#20449#24687
             Caption = #21512#21516#20449#24687
@@ -255,28 +256,28 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object lblBuilder: TLabel
           object lblBuilder: TLabel
             Left = 34
             Left = 34
-            Top = 108
+            Top = -778
             Width = 60
             Width = 60
             Height = 12
             Height = 12
             Caption = #24314#35774#21333#20301#65306
             Caption = #24314#35774#21333#20301#65306
           end
           end
           object lblConstructor: TLabel
           object lblConstructor: TLabel
             Left = 34
             Left = 34
-            Top = 192
+            Top = -694
             Width = 60
             Width = 60
             Height = 12
             Height = 12
             Caption = #25215#21253#21333#20301#65306
             Caption = #25215#21253#21333#20301#65306
           end
           end
           object lblSupervisor: TLabel
           object lblSupervisor: TLabel
             Left = 34
             Left = 34
-            Top = 276
+            Top = -610
             Width = 60
             Width = 60
             Height = 12
             Height = 12
             Caption = #30417#29702#21333#20301#65306
             Caption = #30417#29702#21333#20301#65306
           end
           end
           object lblTechParameters: TLabel
           object lblTechParameters: TLabel
             Left = 7
             Left = 7
-            Top = 371
+            Top = -515
             Width = 48
             Width = 48
             Height = 12
             Height = 12
             Caption = #25216#26415#21442#25968
             Caption = #25216#26415#21442#25968
@@ -289,14 +290,14 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object lblLoadLevel: TLabel
           object lblLoadLevel: TLabel
             Left = 34
             Left = 34
-            Top = 393
+            Top = -493
             Width = 60
             Width = 60
             Height = 12
             Height = 12
             Caption = #20844#36335#31561#32423#65306
             Caption = #20844#36335#31561#32423#65306
           end
           end
           object lblDealPayTitle: TLabel
           object lblDealPayTitle: TLabel
             Left = 7
             Left = 7
-            Top = 531
+            Top = -355
             Width = 48
             Width = 48
             Height = 12
             Height = 12
             Caption = #21512#21516#25903#20184
             Caption = #21512#21516#25903#20184
@@ -309,7 +310,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object lblSafeTitel: TLabel
           object lblSafeTitel: TLabel
             Left = 7
             Left = 7
-            Top = 635
+            Top = -251
             Width = 48
             Width = 48
             Height = 12
             Height = 12
             Caption = #25991#20214#23433#20840
             Caption = #25991#20214#23433#20840
@@ -322,14 +323,14 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object lblUnlockPassword: TLabel
           object lblUnlockPassword: TLabel
             Left = 36
             Left = 36
-            Top = 659
+            Top = -227
             Width = 84
             Width = 84
             Height = 12
             Height = 12
             Caption = #35299#38145#33410#28857#23494#30721#65306
             Caption = #35299#38145#33410#28857#23494#30721#65306
           end
           end
           object lblPasswordHint: TLabel
           object lblPasswordHint: TLabel
             Left = 128
             Left = 128
-            Top = 660
+            Top = -226
             Width = 90
             Width = 90
             Height = 12
             Height = 12
             Caption = 'lblPasswordHint'
             Caption = 'lblPasswordHint'
@@ -343,7 +344,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object lblCalcParametersTitel: TLabel
           object lblCalcParametersTitel: TLabel
             Left = 7
             Left = 7
-            Top = 763
+            Top = -123
             Width = 48
             Width = 48
             Height = 12
             Height = 12
             Caption = #35745#31639#21442#25968
             Caption = #35745#31639#21442#25968
@@ -356,14 +357,14 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object Label1: TLabel
           object Label1: TLabel
             Left = 36
             Left = 36
-            Top = 787
+            Top = -99
             Width = 84
             Width = 84
             Height = 12
             Height = 12
             Caption = #20445#30041#23567#25968#20301#25968#65306
             Caption = #20445#30041#23567#25968#20301#25968#65306
           end
           end
           object lblDateTime: TLabel
           object lblDateTime: TLabel
             Left = 7
             Left = 7
-            Top = 915
+            Top = 4
             Width = 48
             Width = 48
             Height = 12
             Height = 12
             Caption = #26102#38388#21442#25968
             Caption = #26102#38388#21442#25968
@@ -376,21 +377,21 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object lblBaseline: TLabel
           object lblBaseline: TLabel
             Left = 36
             Left = 36
-            Top = 938
+            Top = 27
             Width = 60
             Width = 60
             Height = 12
             Height = 12
             Caption = #36215#22987#26085#26399#65306
             Caption = #36215#22987#26085#26399#65306
           end
           end
           object lblDeadline: TLabel
           object lblDeadline: TLabel
             Left = 36
             Left = 36
-            Top = 962
+            Top = 51
             Width = 60
             Width = 60
             Height = 12
             Height = 12
             Caption = #25130#27490#26085#26399#65306
             Caption = #25130#27490#26085#26399#65306
           end
           end
           object pnlDealInfoBar: TPanel
           object pnlDealInfoBar: TPanel
             Left = 62
             Left = 62
-            Top = 9
+            Top = -877
             Width = 339
             Width = 339
             Height = 2
             Height = 2
             BevelOuter = bvLowered
             BevelOuter = bvLowered
@@ -398,7 +399,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leProjectName: TLabeledEdit
           object leProjectName: TLabeledEdit
             Left = 33
             Left = 33
-            Top = 36
+            Top = -850
             Width = 330
             Width = 330
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -410,7 +411,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leDealName: TLabeledEdit
           object leDealName: TLabeledEdit
             Left = 33
             Left = 33
-            Top = 76
+            Top = -810
             Width = 152
             Width = 152
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -422,7 +423,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leDealIndex: TLabeledEdit
           object leDealIndex: TLabeledEdit
             Left = 195
             Left = 195
-            Top = 76
+            Top = -810
             Width = 80
             Width = 80
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -434,7 +435,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leBName: TLabeledEdit
           object leBName: TLabeledEdit
             Left = 101
             Left = 101
-            Top = 123
+            Top = -763
             Width = 261
             Width = 261
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -446,7 +447,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leBLegal: TLabeledEdit
           object leBLegal: TLabeledEdit
             Left = 101
             Left = 101
-            Top = 164
+            Top = -722
             Width = 137
             Width = 137
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -458,7 +459,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leBDate: TLabeledEdit
           object leBDate: TLabeledEdit
             Left = 245
             Left = 245
-            Top = 164
+            Top = -722
             Width = 119
             Width = 119
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -470,7 +471,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leCName: TLabeledEdit
           object leCName: TLabeledEdit
             Left = 101
             Left = 101
-            Top = 207
+            Top = -679
             Width = 262
             Width = 262
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -482,7 +483,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leCLegal: TLabeledEdit
           object leCLegal: TLabeledEdit
             Left = 101
             Left = 101
-            Top = 248
+            Top = -638
             Width = 137
             Width = 137
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -494,7 +495,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leCDate: TLabeledEdit
           object leCDate: TLabeledEdit
             Left = 245
             Left = 245
-            Top = 248
+            Top = -638
             Width = 119
             Width = 119
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -506,7 +507,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leSName: TLabeledEdit
           object leSName: TLabeledEdit
             Left = 101
             Left = 101
-            Top = 291
+            Top = -595
             Width = 262
             Width = 262
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -518,7 +519,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leSLegal: TLabeledEdit
           object leSLegal: TLabeledEdit
             Left = 101
             Left = 101
-            Top = 331
+            Top = -555
             Width = 137
             Width = 137
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -530,7 +531,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leSDate: TLabeledEdit
           object leSDate: TLabeledEdit
             Left = 245
             Left = 245
-            Top = 331
+            Top = -555
             Width = 119
             Width = 119
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -542,7 +543,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object pnlTechParametersBar: TPanel
           object pnlTechParametersBar: TPanel
             Left = 62
             Left = 62
-            Top = 376
+            Top = -510
             Width = 339
             Width = 339
             Height = 2
             Height = 2
             BevelOuter = bvLowered
             BevelOuter = bvLowered
@@ -550,7 +551,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leStartPeg: TLabeledEdit
           object leStartPeg: TLabeledEdit
             Left = 34
             Left = 34
-            Top = 451
+            Top = -435
             Width = 132
             Width = 132
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -562,7 +563,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leEndPeg: TLabeledEdit
           object leEndPeg: TLabeledEdit
             Left = 176
             Left = 176
-            Top = 451
+            Top = -435
             Width = 131
             Width = 131
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -574,7 +575,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leLength: TLabeledEdit
           object leLength: TLabeledEdit
             Left = 34
             Left = 34
-            Top = 491
+            Top = -395
             Width = 132
             Width = 132
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -586,7 +587,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leLaneCount: TLabeledEdit
           object leLaneCount: TLabeledEdit
             Left = 176
             Left = 176
-            Top = 491
+            Top = -395
             Width = 132
             Width = 132
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -598,7 +599,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object cbLoadLevel: TComboBox
           object cbLoadLevel: TComboBox
             Left = 34
             Left = 34
-            Top = 410
+            Top = -476
             Width = 132
             Width = 132
             Height = 20
             Height = 20
             Ctl3D = False
             Ctl3D = False
@@ -615,7 +616,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object pnlDealPayBar: TPanel
           object pnlDealPayBar: TPanel
             Left = 62
             Left = 62
-            Top = 537
+            Top = -349
             Width = 339
             Width = 339
             Height = 2
             Height = 2
             BevelOuter = bvLowered
             BevelOuter = bvLowered
@@ -623,7 +624,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leContractPrice: TLabeledEdit
           object leContractPrice: TLabeledEdit
             Left = 133
             Left = 133
-            Top = 552
+            Top = -334
             Width = 117
             Width = 117
             Height = 18
             Height = 18
             BiDiMode = bdLeftToRight
             BiDiMode = bdLeftToRight
@@ -641,7 +642,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leStartedSubsist: TLabeledEdit
           object leStartedSubsist: TLabeledEdit
             Left = 133
             Left = 133
-            Top = 579
+            Top = -307
             Width = 118
             Width = 118
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -655,7 +656,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leMaterialSubsist: TLabeledEdit
           object leMaterialSubsist: TLabeledEdit
             Left = 133
             Left = 133
-            Top = 605
+            Top = -281
             Width = 119
             Width = 119
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -669,7 +670,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object pnlSafeBar: TPanel
           object pnlSafeBar: TPanel
             Left = 62
             Left = 62
-            Top = 641
+            Top = -245
             Width = 339
             Width = 339
             Height = 2
             Height = 2
             BevelOuter = bvLowered
             BevelOuter = bvLowered
@@ -677,7 +678,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object pnlUnlockPassword: TPanel
           object pnlUnlockPassword: TPanel
             Left = 40
             Left = 40
-            Top = 673
+            Top = -213
             Width = 361
             Width = 361
             Height = 85
             Height = 85
             BevelOuter = bvNone
             BevelOuter = bvNone
@@ -905,7 +906,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leDealType: TLabeledEdit
           object leDealType: TLabeledEdit
             Left = 283
             Left = 283
-            Top = 76
+            Top = -810
             Width = 80
             Width = 80
             Height = 18
             Height = 18
             Ctl3D = False
             Ctl3D = False
@@ -917,7 +918,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object pnlCalcParametersBar: TPanel
           object pnlCalcParametersBar: TPanel
             Left = 62
             Left = 62
-            Top = 769
+            Top = -117
             Width = 339
             Width = 339
             Height = 2
             Height = 2
             BevelOuter = bvLowered
             BevelOuter = bvLowered
@@ -925,7 +926,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leQuantityDigit: TLabeledEdit
           object leQuantityDigit: TLabeledEdit
             Left = 100
             Left = 100
-            Top = 804
+            Top = -82
             Width = 87
             Width = 87
             Height = 18
             Height = 18
             EditLabel.Width = 36
             EditLabel.Width = 36
@@ -937,7 +938,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object leTotalPriceDigit: TLabeledEdit
           object leTotalPriceDigit: TLabeledEdit
             Left = 264
             Left = 264
-            Top = 804
+            Top = -82
             Width = 87
             Width = 87
             Height = 18
             Height = 18
             EditLabel.Width = 36
             EditLabel.Width = 36
@@ -949,7 +950,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object udQuantity: TUpDown
           object udQuantity: TUpDown
             Left = 187
             Left = 187
-            Top = 804
+            Top = -82
             Width = 16
             Width = 16
             Height = 18
             Height = 18
             Associate = leQuantityDigit
             Associate = leQuantityDigit
@@ -959,7 +960,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object udTotalPrice: TUpDown
           object udTotalPrice: TUpDown
             Left = 351
             Left = 351
-            Top = 804
+            Top = -82
             Width = 16
             Width = 16
             Height = 18
             Height = 18
             Associate = leTotalPriceDigit
             Associate = leTotalPriceDigit
@@ -968,15 +969,15 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object gbPM_Digit: TGroupBox
           object gbPM_Digit: TGroupBox
             Left = 52
             Left = 52
-            Top = 830
+            Top = -56
             Width = 349
             Width = 349
-            Height = 73
+            Height = 49
             Caption = #20215#24046
             Caption = #20215#24046
             TabOrder = 31
             TabOrder = 31
             Visible = False
             Visible = False
             object lePM_PriceDigit: TLabeledEdit
             object lePM_PriceDigit: TLabeledEdit
-              Left = 51
-              Top = 43
+              Left = 48
+              Top = 19
               Width = 87
               Width = 87
               Height = 18
               Height = 18
               EditLabel.Width = 36
               EditLabel.Width = 36
@@ -987,28 +988,18 @@ object ProjectPropertiesForm: TProjectPropertiesForm
               Text = '0'
               Text = '0'
             end
             end
             object udPM_PriceDigit: TUpDown
             object udPM_PriceDigit: TUpDown
-              Left = 138
-              Top = 43
+              Left = 135
+              Top = 19
               Width = 16
               Width = 16
               Height = 18
               Height = 18
               Associate = lePM_PriceDigit
               Associate = lePM_PriceDigit
               Max = 10
               Max = 10
               TabOrder = 1
               TabOrder = 1
             end
             end
-            object cbDisplayPM: TCheckBox
-              Left = 11
-              Top = 19
-              Width = 166
-              Height = 17
-              Caption = #22635#20889#20215#24046#37329#39069#33267#35745#37327#21488#36134
-              Ctl3D = False
-              ParentCtl3D = False
-              TabOrder = 2
-            end
           end
           end
           object pnlDateTime: TPanel
           object pnlDateTime: TPanel
             Left = 62
             Left = 62
-            Top = 921
+            Top = 10
             Width = 339
             Width = 339
             Height = 2
             Height = 2
             BevelOuter = bvLowered
             BevelOuter = bvLowered
@@ -1016,7 +1007,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object dtpBaseline: TDateTimePicker
           object dtpBaseline: TDateTimePicker
             Left = 104
             Left = 104
-            Top = 934
+            Top = 23
             Width = 105
             Width = 105
             Height = 20
             Height = 20
             Date = 0.457352881945553200
             Date = 0.457352881945553200
@@ -1026,7 +1017,7 @@ object ProjectPropertiesForm: TProjectPropertiesForm
           end
           end
           object dtpDeadline: TDateTimePicker
           object dtpDeadline: TDateTimePicker
             Left = 104
             Left = 104
-            Top = 958
+            Top = 47
             Width = 105
             Width = 105
             Height = 20
             Height = 20
             Date = 0.457352881945553200
             Date = 0.457352881945553200

+ 4 - 3
Forms/ProjectPropertiesFrm.pas

@@ -102,7 +102,6 @@ type
     gbPM_Digit: TGroupBox;
     gbPM_Digit: TGroupBox;
     lePM_PriceDigit: TLabeledEdit;
     lePM_PriceDigit: TLabeledEdit;
     udPM_PriceDigit: TUpDown;
     udPM_PriceDigit: TUpDown;
-    cbDisplayPM: TCheckBox;
     pnlReport: TPanel;
     pnlReport: TPanel;
     leReport: TLabel;
     leReport: TLabel;
     cbShowReportShading: TCheckBox;
     cbShowReportShading: TCheckBox;
@@ -195,6 +194,8 @@ var
 begin
 begin
   PropertiesForm := TProjectPropertiesForm.Create(nil);
   PropertiesForm := TProjectPropertiesForm.Create(nil);
   try
   try
+    PropertiesForm.ClientHeight := 357;
+    PropertiesForm.ClientWidth := 530;
     PropertiesForm.ProjectFrame := ProjectFrame;
     PropertiesForm.ProjectFrame := ProjectFrame;
     PropertiesForm.ProjectData := ProjectFrame.ProjectData;
     PropertiesForm.ProjectData := ProjectFrame.ProjectData;
     PropertiesForm.zgStaff.OnCellCanEdit := PropertiesForm.zgStaffCellCanEdit;
     PropertiesForm.zgStaff.OnCellCanEdit := PropertiesForm.zgStaffCellCanEdit;
@@ -321,7 +322,7 @@ begin
     ResetContentsCheck(tobtnDealPayment.Tag)
     ResetContentsCheck(tobtnDealPayment.Tag)
   else if msbBase.VertScrollBar.Position < 758 then
   else if msbBase.VertScrollBar.Position < 758 then
     ResetContentsCheck(tobtnSafe.Tag)
     ResetContentsCheck(tobtnSafe.Tag)
-  else if msbBase.VertScrollBar.Position < 910 then
+  else if msbBase.VertScrollBar.Position < 886 then
     ResetContentsCheck(tobtnCalcParameters.Tag)
     ResetContentsCheck(tobtnCalcParameters.Tag)
   else
   else
     ResetContentsCheck(tobtnDateTime.Tag);
     ResetContentsCheck(tobtnDateTime.Tag);
@@ -346,7 +347,7 @@ begin
   else if ATag = tobtnCalcParameters.Tag then
   else if ATag = tobtnCalcParameters.Tag then
     msbBase.VertScrollBar.Position := 758
     msbBase.VertScrollBar.Position := 758
   else if ATag = tobtnDateTime.Tag then
   else if ATag = tobtnDateTime.Tag then
-    msbBase.VertScrollBar.Position := 910;
+    msbBase.VertScrollBar.Position := 886;
 end;
 end;
 
 
 procedure TProjectPropertiesForm.InitDealInfo;
 procedure TProjectPropertiesForm.InitDealInfo;

+ 1 - 1
Frames/ProjectGLFme.dfm

@@ -345,7 +345,7 @@ object ProjectGLFrame: TProjectGLFrame
         Title.Font.Height = -12
         Title.Font.Height = -12
         Title.Font.Name = #23435#20307
         Title.Font.Name = #23435#20307
         Title.Font.Style = []
         Title.Font.Style = []
-        Alignment = taLeftJustify
+        Alignment = taRightJustify
         Font.Charset = GB2312_CHARSET
         Font.Charset = GB2312_CHARSET
         Font.Color = clWindowText
         Font.Color = clWindowText
         Font.Height = -12
         Font.Height = -12