mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-07-25 12:56:12 +02:00
Fix error if no connection found, and adapt load/save to changed verb indexes
git-svn-id: trunk@61454 -
This commit is contained in:
parent
87642bb738
commit
1c9f5af2ca
@ -503,7 +503,8 @@ begin
|
||||
try
|
||||
Frm.Schema:=S;
|
||||
cList:=GetSchemaConnections(S);
|
||||
Frm.Connections:=cList;
|
||||
if Assigned(cList) then
|
||||
Frm.Connections:=cList;
|
||||
if Frm.ShowModal=mrOK then
|
||||
begin
|
||||
if Frm.SchemaModified then
|
||||
@ -520,6 +521,9 @@ end;
|
||||
|
||||
procedure TSQLDBRestSchemaComponentEditor.ExecuteVerb(Index: Integer);
|
||||
|
||||
Const
|
||||
idxSave = 2;
|
||||
|
||||
Var
|
||||
FN : UTF8String;
|
||||
S : TSQLDBRestSchema;
|
||||
@ -531,8 +535,8 @@ begin
|
||||
1,2 :
|
||||
begin
|
||||
FN:=Component.Name+'.json';
|
||||
if GetFileName(FN, Format(SJSONFilesFilter, [allFilesMask]), Index=0) then
|
||||
if Index=0 then
|
||||
if GetFileName(FN, Format(SJSONFilesFilter, [allFilesMask]), Index=idxSave) then
|
||||
if idxSave=2 then
|
||||
S.SaveToFile(FN)
|
||||
else
|
||||
begin
|
||||
|
Loading…
Reference in New Issue
Block a user