Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Scout » AbstractPage(WithTable) ans SearchForms
AbstractPage(WithTable) ans SearchForms [message #1749558] Thu, 08 December 2016 06:48 Go to next message
Peter Pfeifer is currently offline Peter PfeiferFriend
Messages: 213
Registered: November 2014
Senior Member

Hi there,

I'm playing around with "search while you type".

Therefore I created a SearchForm which I attached to a TablePage. But I don't want to use the OK or CANCEL buttons. Instead a search should be invoked when the user has typed more than 3 characters.

So far so good.

I can invoke the search, call my services and get the desired result.

But how can I access my TablePage from within the SearchForm an repopulate the table there? Is there some kind of accessor to get hold of the master table page?

Thanks in advance

Peter

Re: AbstractPage(WithTable) ans SearchForms [message #1749559 is a reply to message #1749558] Thu, 08 December 2016 06:59 Go to previous messageGo to next message
Matthias OtterbachFriend
Messages: 55
Registered: August 2015
Location: Munich
Member
I don't think, the search form itself has a built-in reference to the "parent page".

But if you just want to reload the table data, you might be able to use the same technique the search form uses after a button click. After creating the search form, the table page registers a listener, see org.eclipse.scout.rt.client.ui.desktop.outline.pages.AbstractPageWithTable.attachToSearchFormInternal(), and waits for org.eclipse.scout.rt.client.ui.form.FormEvent.TYPE_STORE_AFTER events. Therefore I guess you could fire a store event (e.g. by calling org.eclipse.scout.rt.client.ui.form.IForm.doOk() on the search form) and hopefully the table page will reload its data?
Re: AbstractPage(WithTable) ans SearchForms [message #1749567 is a reply to message #1749559] Thu, 08 December 2016 09:04 Go to previous message
Peter Pfeifer is currently offline Peter PfeiferFriend
Messages: 213
Registered: November 2014
Senior Member

Hi,

did a quick try with the FormEventListener.

It gets called, but unfortunately 10 times. And my table is only refreshed, when OK is pressed...

Any ideas why? Thanks a lot

Peter

[Updated on: Thu, 08 December 2016 10:06]

Report message to a moderator

Previous Topic:Scout, PostgreSQL and Docker
Next Topic:Project Export Errors
Goto Forum:
  


Current Time: Fri Apr 19 23:16:44 GMT 2024

Powered by FUDForum. Page generated in 0.03003 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top