Easyjweb 1.1 quick experience-extjs without Javascript

Source: Internet
Author: User

Easyjweb1.1, which is mainly used to enhance the Ajax support function of easyjweb and provides a rich component implementation in the easyjweb Extension Project. Open Source: wlr.easyjf.com. With the release of easyjweb 1.1, you only need to write Java code to put on a brilliant extjs coat for your Java EE application. Use ext without JavaScript to describe rich componet in easyjweb 1.1.

Body:
Download easyjweb 1.1:

Easyjweb-1.1.zip 22.0 m with dependency package
Easyjweb-1.1-without-dependencies.zip 5.42 m no dependent package

2. decompress the downloaded file and switch to the bin directory of easyjweb1.1's main directory, as shown in:
3. Run easyjweb project D:/test/demo-extjs to generate an empty project in D:/test/demo.
4. Import the demo project just created using the command in eclipse.
5. Add a simpleaction in MyApp. Action to inherit richcomponetaction
6. Add dogrid as follows:
Public page dogrid (){
Viewport view = new viewport ();
Gridpanel grid = new gridpanel ("Grid", "data sheet", 500,100 );
Grid. setcolumns (New String [] {"ID", "name", "Date of Birth", "email "});
View. Add (GRID );
This. addcomponent (View );
Return componentpage;
}
7. Use the command line to switch to the D:/test/demo/bin directory and enter easyjweb war.
8. Copy the generated demo. War file to the webapps directory of Tomcat and start Tomcat.
9. Use http: // localhost: 8080/mini/simple. EJF? Cmd = grid. You can see the effect.
10. Add a dotree method to simpleaction. The Code is as follows:
Public page dotree (){
Viewport view = new viewport ();
Treepanel tree = new treepanel ("Tree", "simple trees", 200 );
Treenode root = new treenode ("root", "root ");
Root. Add (New treenode ("C1", "kid 1 "));
Root. Add (New treenode ("C2", "Kid 2 "));
Root. getchildnodes (). Get (1). Add (New treenode ("C3", ""));
Tree. setroot (Root );
View. Add (tree );
This. addcomponent (View );
Return componentpage;
}
11. Repeat Step 5 to repackage the project, release and run the project, and enter http: // localhost: 7th/mini/simple. EJF? Cmd = tree. You can see the effect without an accident:
You don't need to write a javascript sentence. You just need to create several rich componet in action, and then you can let the client browse the beautiful ext interface.

Without writing JavaScript, the application can have a brilliant appearance. This is indeed a good thing for Java Development. The rich componet integration of this version is not complete enough, we hope that you will be able to improve your skills together.
 
If you are interested, you can refer to http://wlr2.easyjf.com/directly using Java to write beautiful ajaxapplications Based on the extjs client framework.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.