Переглянути джерело

P_ZJJL_DetailBills缓存表,新增多个字段,以供报表查询

MaiXinRong 7 роки тому
батько
коміт
bc6c4a1607
1 змінених файлів з 9 додано та 3 видалено
  1. 9 3
      Units/ProjectData.pas

+ 9 - 3
Units/ProjectData.pas

@@ -904,10 +904,16 @@ procedure TProjectData.CopyPhaseData;
             '  From Bills As B, P_Stage As PS, P_ZJJL As PZ' +
             '  Where (PZ.BillsID = B.LeafXmjParentID) And (B.ID = PS.BillsID) And (B.IsLeaf=True)';
     ExecuteSql(sSql);
-    sSql := 'Select PZD.ID, PZD.BillsID, B.Quantity As Quantity,' +
+    sSql := 'Select PZD.ID, PZD.BillsID, B.Quantity As Quantity, B.TotalPrice As TotalPrice,' +
+            '    PS.DealQuantity As DealQuantity, PS.DealTotalPrice As DealTotalPrice,' +
+            '    PS.QcQuantity As QcQuantity, PS.QcTotalPrice As QcTotalPrice,' +
             '    PS.GatherQuantity As GatherQuantity, PS.GatherTotalPrice As GatherTotalPrice,' +
-            '    PS.PreGatherQuantity As PreGatherQuantity, PS.GatherTotalPrice As PreGatherTotalPrice,' +
-            '    PS.EndGatherQuantity As EndGatherQuantity, PS.GatherTotalPrice As EndGatherTotalPrice' +
+            '    PS.PreDealQuantity As PreDealQuantity, PS.PreDealTotalPrice As PreDealTotalPrice,' +
+            '    PS.PreQcQuantity As PreQcQuantity, PS.PreQcTotalPrice As PreQcTotalPrice,' +
+            '    PS.PreGatherQuantity As PreGatherQuantity, PS.PreGatherTotalPrice As PreGatherTotalPrice,' +
+            '    PS.EndDealQuantity As EndDealQuantity, PS.EndDealTotalPrice As EndDealTotalPrice,' +
+            '    PS.EndQcQuantity As EndQcQuantity, PS.EndQcTotalPrice As EndQcTotalPrice,' +
+            '    PS.EndGatherQuantity As EndGatherQuantity, PS.EndGatherTotalPrice As EndGatherTotalPrice' +
             '  Into P_ZJJL_DetailBills' +
             '  From Bills As B, P_Stage As PS, P_ZJJL_Detail As PZD' +
             '  Where (PZD.BillsID = PS.BillsID) And (B.ID = PZD.BillsID)';