瀏覽代碼

总分包,工程量清单模式,汇总结果,按清单编号排序

MaiXinRong 5 年之前
父節點
當前提交
46667f7158

+ 4 - 1
SubTenderGatherGcl/stgGatherGclCacheData.pas

@@ -67,6 +67,7 @@ type
   TstgGatherGcl = class
   private
     FID: Integer;
+    FIndexCode: string;
     FB_Code: string;
     FName: string;
     FUnits: string;
@@ -88,6 +89,7 @@ type
 
     property ID: Integer read FID;
     property B_Code: string read FB_Code;
+    property IndexCode: string read FIndexCode;
     property Name: string read FName;
     property Units: string read FUnits;
     property Price: Double read FPrice;
@@ -161,9 +163,10 @@ constructor TstgGatherGcl.Create(AID: Integer; ARec: TBillsRecord);
 begin
   FSubTenders := TList.Create;
   FGather := TstgGclStageData.Create;
-     
+
   FID := AID;
   FB_Code := ARec.B_Code.AsString;
+  FIndexCode := B_CodeToIndexCode(FB_Code);
   FName := ARec.Name.AsString;
   FUnits := ARec.Units.AsString;
   FPrice := ARec.Price.AsFloat;

+ 34 - 28
SubTenderGatherGcl/stgGclGatherDm.dfm

@@ -21,36 +21,39 @@ object stgGclGatherData: TstgGclGatherData
       650606425F436F6465094669656C644E616D650606425F436F64650844617461
       547970650218084461746153697A6502320549734B6579080F4E65656450726F
       636573734E616D650809507265636973696F6E02000453697A6502000001044E
-      616D6506044E616D65094669656C644E616D6506044E616D6508446174615479
-      70650218084461746153697A6503FF000549734B6579080F4E65656450726F63
-      6573734E616D650809507265636973696F6E02000453697A6502000001044E61
-      6D650605556E697473094669656C644E616D650605556E697473084461746154
-      7970650218084461746153697A6502140549734B6579080F4E65656450726F63
-      6573734E616D650809507265636973696F6E02000453697A6502000001044E61
-      6D65060C4465616C5175616E74697479094669656C644E616D65060C4465616C
-      5175616E746974790844617461547970650206084461746153697A6502080549
-      734B6579080F4E65656450726F636573734E616D650809507265636973696F6E
-      02000453697A6502000001044E616D65060A51635175616E7469747909466965
-      6C644E616D65060A51635175616E746974790844617461547970650206084461
-      746153697A6502080549734B6579080F4E65656450726F636573734E616D6508
-      09507265636973696F6E02000453697A6502000001044E616D65060E4465616C
-      546F74616C5072696365094669656C644E616D65060E4465616C546F74616C50
-      726963650844617461547970650206084461746153697A6502080549734B6579
+      616D650609496E646578436F6465094669656C644E616D650609496E64657843
+      6F64650844617461547970650218084461746153697A6503FF000549734B6579
       080F4E65656450726F636573734E616D650809507265636973696F6E02000453
-      697A6502000001044E616D65060C5163546F74616C5072696365094669656C64
-      4E616D65060C5163546F74616C50726963650844617461547970650206084461
-      746153697A6502080549734B6579080F4E65656450726F636573734E616D6508
-      09507265636973696F6E02000453697A6502000001044E616D65060951634247
-      4C436F6465094669656C644E616D650609516342474C436F6465084461746154
-      7970650218084461746153697A6503FF000549734B6579080F4E65656450726F
+      697A6502000001044E616D6506044E616D65094669656C644E616D6506044E61
+      6D650844617461547970650218084461746153697A6503FF000549734B657908
+      0F4E65656450726F636573734E616D650809507265636973696F6E0200045369
+      7A6502000001044E616D650605556E697473094669656C644E616D650605556E
+      6974730844617461547970650218084461746153697A6502140549734B657908
+      0F4E65656450726F636573734E616D650809507265636973696F6E0200045369
+      7A6502000001044E616D65060C4465616C5175616E74697479094669656C644E
+      616D65060C4465616C5175616E74697479084461746154797065020608446174
+      6153697A6502080549734B6579080F4E65656450726F636573734E616D650809
+      507265636973696F6E02000453697A6502000001044E616D65060A5163517561
+      6E74697479094669656C644E616D65060A51635175616E746974790844617461
+      547970650206084461746153697A6502080549734B6579080F4E65656450726F
       636573734E616D650809507265636973696F6E02000453697A6502000001044E
-      616D650608516342474C4E756D094669656C644E616D650608516342474C4E75
-      6D0844617461547970650218084461746153697A6503FF000549734B6579080F
-      4E65656450726F636573734E616D650809507265636973696F6E02000453697A
-      6502000001044E616D6506055072696365094669656C644E616D650605507269
-      63650844617461547970650206084461746153697A6502080549734B6579080F
-      4E65656450726F636573734E616D650809507265636973696F6E02000453697A
-      6502000000}
+      616D65060E4465616C546F74616C5072696365094669656C644E616D65060E44
+      65616C546F74616C50726963650844617461547970650206084461746153697A
+      6502080549734B6579080F4E65656450726F636573734E616D65080950726563
+      6973696F6E02000453697A6502000001044E616D65060C5163546F74616C5072
+      696365094669656C644E616D65060C5163546F74616C50726963650844617461
+      547970650206084461746153697A6502080549734B6579080F4E65656450726F
+      636573734E616D650809507265636973696F6E02000453697A6502000001044E
+      616D650609516342474C436F6465094669656C644E616D650609516342474C43
+      6F64650844617461547970650218084461746153697A6503FF000549734B6579
+      080F4E65656450726F636573734E616D650809507265636973696F6E02000453
+      697A6502000001044E616D650608516342474C4E756D094669656C644E616D65
+      0608516342474C4E756D0844617461547970650218084461746153697A6503FF
+      000549734B6579080F4E65656450726F636573734E616D650809507265636973
+      696F6E02000453697A6502000001044E616D6506055072696365094669656C64
+      4E616D65060550726963650844617461547970650206084461746153697A6502
+      080549734B6579080F4E65656450726F636573734E616D650809507265636973
+      696F6E02000453697A6502000000}
   end
   object sdvGatherGcl: TsdDataView
     Active = False
@@ -58,6 +61,9 @@ object stgGclGatherData: TstgGclGatherData
     Filtered = False
     Columns = <
       item
+        FieldName = 'IndexCode'
+      end
+      item
         FieldName = 'B_Code'
       end
       item

+ 6 - 1
SubTenderGatherGcl/stgGclGatherDm.pas

@@ -58,8 +58,12 @@ procedure TstgGclGatherData.LoadGatherData(ACacheData: TstgGatherGclCacheData);
 begin
   LoadSubTenders(ACacheData);
   LoadGatherGcls(ACacheData);
-
+  
+  if not Assigned(sddGatherGcl.FindIndex('idxIndexCode')) then
+    sddGatherGcl.AddIndex('idxIndexCode', 'IndexCode');
   sdvGatherGcl.Active := True;
+  sdvGatherGcl.IndexName := 'idxIndexCode';
+
   sdvBillsDetail.Active := True;
   sdvBillsDetail.RefreshFilter;
 
@@ -81,6 +85,7 @@ begin
   Rec := sddGatherGcl.Add;
   Rec.ValueByName('ID').AsInteger := AGcl.ID;
   Rec.ValueByName('B_Code').AsString := AGcl.B_Code;
+  Rec.ValueByName('IndexCode').AsString := AGcl.IndexCode;
   Rec.ValueByName('Name').AsString := AGcl.Name;
   Rec.ValueByName('Units').AsString := AGcl.Units;
   Rec.ValueByName('Price').AsFloat := AGcl.Price;