Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Scout » A newcomer: building a web based REST frontend(Seeking advice concerning builiding a REST frontend using Eclipse Scout)
A newcomer: building a web based REST frontend [message #1837767] Fri, 05 February 2021 18:18 Go to next message
J D is currently offline J DFriend
Messages: 99
Registered: February 2021
Member
Hello there eveyone,

First of all thanks to the creators of this wonderful tool. I am really in awe of it and I am itching to try it.

I want to port an old multi-tier project of mine to the web. I want to keep the server intact for the time being because it is a REST based application server and it does it's work very well. So I want to build an Eclipse Scout frontend that consumes this RESTful service. The frontend does not need to know about the details of the data model and the structure of tables.

How do I start doing this with the Eclipse Scout?

I would also like to know the following:
a) creating dashboards with Eclipse Scout
b) creating charts with Eclipse Scout

Does Eclipse Scout allow using any external tools in the Java ecosystem or GUI like JasperStudio and JavaFX. This would make creating and inserting charts more evident.

Thanks a lot for your kind assistance. I look forward to hearing and learning from you all.

JD
Re: A newcomer: building a web based REST frontend [message #1837778 is a reply to message #1837767] Sat, 06 February 2021 07:29 Go to previous messageGo to next message
Andre Wegmueller is currently offline Andre WegmuellerFriend
Messages: 204
Registered: September 2012
Location: Baden-Dättwil, Switzerla...
Senior Member
Hi J D

We use a Scout front end with a REST back end in our own applications too. Basically not much is different from a regular Scout application _with_ a back end.
Take a look at the module "org.eclipse.scout.rt.rest" to start.

A few things are different:


  • Instead of the FormData concept to transport data between client/server, you should use IDoEntities (which are basically beans you can serialize/deserialize into JSON)
  • For each entity create a XyzRestResourceClient (see IRestResourceClient), it should provide a method for each operation on your REST API. They accept and return DOs (data object) and use JAX RS to make a call to the REST backend.
  • Its a good practice to make a XyzForm/PageService for each Form or Page in Scout which reads data from the REST API by calling the XyzRestResourceClient and prepares the data for the UI - and vice versa.


To your other questions:

Yes, you can build dashboards with Eclipse Scout. Here's an example of a (commercial) dashboard built with Scout. Basically it uses the LogicalGridLayout to place Widgets or Fields on a Form. Some of the widgets you see on the screen belong to our CRM and are closed source, others are open source. Like...

The ChartField which integrates Chart JS into the Scout UI.

And yes, you can also use external Java and JavaScript libraries in your Scout project. However, since Eclipse Scout renders a HTML UI in the browser, JavaFX is probably not an option in this case.

Hope that gives you some ideas on where to start.

Cheers,
André




Eclipse Scout Homepage | Documentation | GitHub
Re: A newcomer: building a web based REST frontend [message #1837787 is a reply to message #1837778] Sat, 06 February 2021 12:01 Go to previous messageGo to next message
Claudio Guglielmo is currently offline Claudio GuglielmoFriend
Messages: 256
Registered: March 2010
Senior Member
Hi

Some additional information from my side.
If you want to use Charts I have some good news. The upcoming Scout release contains official support for Charts! Until now you had to integrate your favorite chart library by yourself. With Scout 11 you will be able to use the built in Chart widget.
We will officially release Scout 11 in March, but you can already use it (I think the current version is 11.0.3). Please have a look at the release notes for more information: https://eclipsescout.github.io/11.0/release-notes.html#chart

Regarding dashboards: I suggest using the TileGrid (https://scout.bsi-software.com/widgets/?dl=widget-tilefield). You can use the FormFieldTile that wraps a FormField and optimizes the look for dashboards. Or you can add plain tiles with custom content and style.

You should also decide whether you want to use Scout Classic where you use Java for the frontent part, or Scout JS where you use JavaScript. We'll be releasing some new getting started content along with the Scout 11 release in March. Stay tuned!
Re: A newcomer: building a web based REST frontend [message #1837809 is a reply to message #1837787] Mon, 08 February 2021 00:29 Go to previous message
J D is currently offline J DFriend
Messages: 99
Registered: February 2021
Member
Thank you both so much for your replies and you encouragement. I'll go ahead and start using Scout. I have a lot to learn but I think it will be worth it. And I'm looking forward to Scout 11 release in March.

JD
Previous Topic:RESTful mit Eclipse Scout
Next Topic:speed up ci pipeline
Goto Forum:
  


Current Time: Tue Apr 16 05:36:07 GMT 2024

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

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

Back to the top