Browse Source

* Fix bug #33388, name is lost when doing loadfromjson

git-svn-id: trunk@38464 -
michael 7 years ago
parent
commit
c1f8a15e32
1 changed files with 3 additions and 0 deletions
  1. 3 0
      packages/fcl-report/src/fpjsonreport.pp

+ 3 - 0
packages/fcl-report/src/fpjsonreport.pp

@@ -113,14 +113,17 @@ procedure TFPJSONReport.LoadFromJSON(aJSON: TJSONObject);
 
 
 Var
 Var
   R : TFPReportJSONStreamer;
   R : TFPReportJSONStreamer;
+  N : String;
 
 
 begin
 begin
+  N:=Name;
   R:=TFPReportJSONStreamer.Create(Nil);
   R:=TFPReportJSONStreamer.Create(Nil);
   try
   try
     R.OwnsJSON:=False;
     R.OwnsJSON:=False;
     R.JSON:=aJSON;
     R.JSON:=aJSON;
     ReadElement(R);
     ReadElement(R);
   finally
   finally
+    Name:=N;
     R.Free;
     R.Free;
   end;
   end;
 end;
 end;