Jump to content

check the operation of "Infinite Scroll"


gerardocrisci

Recommended Posts

In the meantime .. I put a patch like this

procedure TUniCustomDBGrid.JSEventHandler(AEventName: string; AParams: TUniStrings);
var
  AStart, APage, ALimit : Integer;
begin
  inherited;
  if AEventName = UNI_DATA_EVENT then
  begin
    if not (dgPersistentSelection in FOptions) then
      FBookmarks.Clear;

    if FDelayBeboreLoad and FFirstLoad then Sleep(500);
    FFirstLoad := False;

    ALimit:=AParams['limit'].AsInteger;
    if FBufferedStore.FEnabled then
    begin
      APage  :=StrToIntDef(AParams['page'].AsString, 1)-1;
      AStart := APage*ALimit;
    end
    else
      AStart := StrToIntDef(AParams['start'].AsString, -1);
    HandleData(
      AStart,
      AParams['limit'].AsInteger,
      AParams['options'].AsInteger,
      AParams['sort'].AsString,
      AParams['group'].AsString
    );
  end;
end;

 

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...