Struts2 jQuery Plugin 3.6.0 and Struts2 Bootstrap Plugin 1.6.1 available

Posted by on 02 Jun 2013 | Filed under: java, jQuery, Struts jQuery Plugin, struts2, Struts2 Bootstrap Plugin

Struts2 jQuery Plugin

This release is mostly a maintenance release, this means it includes a new jQuery, jQuery UI and related Plugins Software Stack but also some Bug Fixes. For a complete list of changes since last version, please visit the Changelog.

The new release is based on jQuery UI 1.10.3 and includes some API Changes again. If you are upgrading from a previous Struts2 jQuery Version please respect the Upgrade Guide.

Library Updates

.

Download: http://code.google.com/p/struts2-jquery/downloads/list
Showcase: http://struts.jgeppert.com/struts2-jquery-showcase/
Issues: http://code.google.com/p/struts2-jquery/issues/list
User Group: http://groups.google.com/group/struts2-jquery

Struts2 Bootstrap Plugin

The new release 1.6.1 includes a patch provided by Brendan Le Ny. This patch allows an easy to use input prepend/append icon.

<s:textfield
        label="Textfield with prepended icon"
        inputPrependIcon="envelope"
        name="prependIcon"/>
 
<s:textfield
        label="Textfield with appended icon"
        inputAppendIcon="user"
        name="appendIcon"/>

Download: http://code.google.com/p/struts2-bootstrap/downloads/list
Showcase: http://struts.jgeppert.com/struts2-bootstrap-showcase/
Issues: http://code.google.com/p/struts2-bootstrap/issues/list

jQuery UI Menu support with now released Struts2 jQuery Plugin 3.5.0

Posted by on 17 Dez 2012 | Filed under: Allgemein, java, jQuery, projekte, Struts jQuery Plugin, struts2, Struts2 Bootstrap Plugin

With jQuery UI 1.9 this popular JavaScript Library provides a Menu Widget, which is now also available in the Struts2 jQuery Plugin. jQuery UI 1.9 includes some API redesigns which also touches the Struts2 jQuery Plugin. So please respect the Upgrade Guide.

Menu Tag

The Menu Tag can be used with some manually added Menu Items or it can be generated form a List of Values. Two new Showcase Examples explain this. Struts2 jQuery Menu

    <sj:menu id="menuWithItems" cssStyle="width:50%">
        <sj:menuItem title="Struts2" href="http://struts.apache.org/2.x/index.html"/>
        <sj:menuItem title="Struts2 jQuery News" menuIcon="ui-icon-extlink" href="http://www.jgeppert.com/category/java/struts2-jquery/"/>
        <sj:menuItem title="Struts2 Plugins">
            <sj:menu id="subMenuPlugins" cssStyle="width:50%">
                <sj:menuItem title="Struts2 Plugins" href="https://cwiki.apache.org/S2PLUGINS/home.html"/>
                <sj:menuItem title="Struts2 jQuery Plugin" href="http://code.google.com/p/struts2-jquery/"/>
                <sj:menuItem title="Struts2 Bootstrap Plugin" href="http://code.google.com/p/struts2-jquery/"/>
            </sj:menu>
        </sj:menuItem>
 
        <sj:menuItem title="Struts2 @ Social Media">
            <sj:menu id="subMenuSocialMedia" cssStyle="width:50%">
                <sj:menuItem title="Struts2 @ Twitter" href="https://twitter.com/TheApacheStruts"/>
                <sj:menuItem title="Struts2 @ Google+" href="https://www.google.com/+ApacheStruts"/>
                <sj:menuItem title="Struts2 @ Facebook" href="http://www.facebook.com/struts2"/>
            </sj:menu>
        </sj:menuItem>
 
        <sj:menuItem title="AJAX">
            <sj:menu id="subMenuAjax" cssStyle="width:50%">
                <s:url var="ajax1" value="/ajax1.action"/>
                <sj:menuItem title="Ajax 1" href="%{ajax1}" targets="result"/>
                <s:url var="ajax2" value="/ajax2.action"/>
                <sj:menuItem title="Ajax 2" href="%{ajax2}" targets="result" effect="highlight" effectDuration="2500"/>
                <s:url var="ajax3" value="/ajax3.action"/>
                <sj:menuItem title="Ajax 3" href="%{ajax3}" targets="result" onBeforeTopics="beforeLink"
                             onCompleteTopics="completeLink"/>
                <s:url var="ajax4" value="/ajax4.action"/>
                <sj:menuItem title="Ajax 4" href="%{ajax4}" menuIcon="ui-icon-gear" targets="result" effect="bounce" effectDuration="1000"/>
            </sj:menu>
        </sj:menuItem>
    </sj:menu>

Spinner Tag

The currently based Spinner Tag was based on an community jQuery plugin. This plugin was replaced by the Spinner Widget provided by the jQuery UI Lib itself. This brings some API Changes, especially the handling for Currency and Number Formating was changed. This is now based on jQuery Globalize project.

Modern Web Application Development With Apache Struts2 - ApacheCon Europa 2012

I give my first Conference Talk ever at the ApacheCon Europa 2012 together with René Gielen the PMC Chair of the Apache Struts Project. This was a great Experience for me. The Talk was recorded and is now free available at youtube.com. This talks explains how to develop modern Web Applications with Apache Struts and the both Plugins Struts2 jQuery and Struts2 Bootstrap.

Slides

Video

Code

The Code form our Todo Example is free available at github.

https://github.com/jogep/struts2-todo-examples

Simply check it out and run mnv:install to get the war file or run mvn:jetty run and take a look at the result in your browser.

http://localhost:8080/todo/todo

Library Updates

For a complete list of changes since last version, please visit the Changelog.

Download: http://code.google.com/p/struts2-jquery/downloads/list
Showcase: http://struts.jgeppert.com/struts2-jquery-showcase/
Issues: http://code.google.com/p/struts2-jquery/issues/list
User Group: http://groups.google.com/group/struts2-jquery

Struts2 jQuery Plugin 3.4.0 with improved Chart Tag released

Posted by on 15 Okt 2012 | Filed under: java, jQuery, Struts jQuery Plugin, struts2

The new Version 3.4.0 of Struts2 jQuery Plugin with some Bugfixes and an improved Chart Tag is released.

Chart Tag

In this release there is gone some attention to the Chart Tag. So it is now possible to create Curved Lines, adding Axis Labels and build Stacked Charts. See the updated Examples Page in the Showcase App. Struts2 jQuery Chart with stacked Values

    <sjc:chart
    	id="chartAjaxTwo"
    	cssStyle="width: 600px; height: 400px;"
    >
    	<sjc:chartData
    		id="chartAjaxTwoData1"
    		label="Map -Double, Double-"
    		href="%{chartDataUrl}"
    		list="doubleMap"
    		bars="{show : true, barWidth: 0.7}"
    		stack="stack1"
    	/>
    	<sjc:chartData
    		id="chartAjaxTwoData2"
    		label="List -ListValue-"
    		href="%{chartDataUrl}"
    		list="objList"
    		listKey="myKey"
    		listValue="myValue"
    		bars="{show : true, barWidth: 0.7}"
    		stack="stack1"
    	/>
    </sjc:chart>

ApacheCon Europa 2012 - 5–8 November 2012

This Year Rene Gielen and I talk about Modern Web Application Development with Struts2 at the ApacheCon Europa 2012. Save the Date and the Tickets and we see us at 6. Nov. in Sinsheim.

Library Updates

For a complete list of changes since last version, please visit the Changelog.

Download: http://code.google.com/p/struts2-jquery/downloads/list
Showcase: http://struts.jgeppert.com/struts2-jquery-showcase/
Issues: http://code.google.com/p/struts2-jquery/issues/list
User Group: http://groups.google.com/group/struts2-jquery

Struts2 jQuery Plugin new version 3.3.2 provides now support for Trees with Checkboxes

Posted by on 10 Jul 2012 | Filed under: java, jQuery, Struts jQuery Plugin, struts2

The new Version 3.3.2 of Struts2 jQuery Plugin is now available.

Tree with Checkboxes

This release is not only a bugfix release it brings also some usefully new features to you. One of the new Features is the support for Checkboxes in the TreeTag. See the new Tree with Checkboxes Example in the Showcase App. Struts2 jQuery Tree Tag with Checkboxes

<s:form id="treeForm" action="echo" theme="simple">
    	<sjt:tree 
    		name="echo"
    		id="treeDynamicCheckboxes" 
    		jstreetheme="apple"
    		rootNode="nodes"
    		childCollectionProperty="children"
    		nodeTitleProperty="title"
    		nodeIdProperty="id"
    		openAllOnLoad="true" 
    		checkbox="true"
    		checkboxCheckAllTopics="checkAllNodesTopic"
    		checkboxUncheckAllTopics="uncheckAllNodesTopic"
    		checkboxShowTopics="showCheckboxesTopic"
    		checkboxHideTopics="hideCheckboxesTopic"
    		onClickTopics="treeClicked" 
    	/>
    	<sj:submit formIds="treeForm" targets="result3" button="true" />
    	<sj:submit onClickTopics="checkAllNodesTopic" value="Check all Nodes" button="true" />
    	<sj:submit onClickTopics="uncheckAllNodesTopic" value="Uncheck all Nodes" button="true" />
    	<sj:submit onClickTopics="showCheckboxesTopic" value="Show Checkboxes" button="true" />
    	<sj:submit onClickTopics="hideCheckboxesTopic" value="Hide Checkboxes" button="true" />
</s:form>

Improved DIV an Anchor Tag

The Div Tag has now two new attributes. The first new attribute is the delay attribute which allows to set an delay in milliseconds until the div should load the remote content via AJAX. The other new attribute is updateFreq which provide an ability to reload the div content after a specified interval in milliseconds.

<sj:div delay="200" updateFreq="5000"/>

The Anchor Tag provides also some new attributes. This new attributes allows an improved handling when submitting a form via Anchor Tag. For details please see Issue 849. A other new attribute openDialogTitle allows to set dynamically the Title of an Dialog when opened this dialog via openDialog attribute or via topics. See the updated Remote Dialogs Example in the Showcase App.

Library Updates

For a complete list of changes since last version, please visit the Changelog.

Download: http://code.google.com/p/struts2-jquery/downloads/list
Showcase: http://struts.jgeppert.com/struts2-jquery-showcase/
Issues: http://code.google.com/p/struts2-jquery/issues/list
User Group: http://groups.google.com/group/struts2-jquery

Struts2 jQuery Plugin now based on jQuery 1.7 and with support for frozen Columns

Posted by on 13 Mrz 2012 | Filed under: java, jQuery, Struts jQuery Plugin, struts2

I am happy to announce that the Version 3.3.0 of Struts2 jQuery Plugin is now available. The main change is the switch from jQuery 1.6.4 to the latest version 1.7.1 of the jQuery 1.7.x releases.

This Version includes a lot of library updates and 18 solved Issues. The Handler Functions are now split into two different JavaScript Files. One for the base jQuery AJAX Handling and one for the jQuery UI Tags. This improves the load time in all application which are running without jQuery UI widgets.

The Grid tag is now supporting frozen columns which comes with the latest jqGrid release 4.3.1. Simply add the frozen attribute to your first grid column to enable this feature. Also take a look at the new add and delete buttons in your Navigator when using Edit inline. To enable this buttons set the navigatorInlineEditButtons to true.

<sjg:gridColumn ... frozen="true" .. />

The Struts2 jQuery Plugin provides now two Maven Archetypes for an easy start with Struts2, jQuery and Maven. The first is based on the Struts2 Convention Archetype but with included s2j dependencies. The second is for an easy start with the Grid Plugin. This new Archetypes shrinks the Steps described in my previous post 4 Easy Steps to create a Java based Web Application with Struts2 and jQuery to only one Step.

mvn archetype:generate -B -DgroupId=com.mycompany.mysystem -DartifactId=myWebApp -DarchetypeGroupId=com.jgeppert.struts2.jquery -DarchetypeArtifactId=struts2-jquery-archetype-base -DarchetypeVersion=3.3.0 or mvn archetype:generate -B -DgroupId=com.mycompany.mysystem -DartifactId=myWebAppGrid -DarchetypeGroupId=com.jgeppert.struts2.jquery -DarchetypeArtifactId=struts2-jquery-bootstrap-archetype-grid -DarchetypeVersion=3.3.0

Library Updates

For a complete list of changes since last version, please visit the Changelog.

Download: http://code.google.com/p/struts2-jquery/downloads/list
Showcase: http://struts.jgeppert.com/struts2-jquery-showcase/
Issues: http://code.google.com/p/struts2-jquery/issues/list
User Group: http://groups.google.com/group/struts2-jquery

Version 1.2.0 of Struts2 Bootstrap Plugin released

Posted by on 04 Feb 2012 | Filed under: java, struts2, Struts2 Bootstrap Plugin

Since the First 1.0.0 Release of Struts2 Bootstrap Plugin there are some important changes.

Maven Support

Like promised in my previous post, this Plugin is now available as Maven Artifact.
<dependencies>
    ...
    <dependency>
        <groupId>com.jgeppert.struts2.bootstrap</groupId>
        <artifactId>struts2-bootstrap-plugin</artifactId>
        <version>1.2.0</version>
    </dependency>
    ...
</dependencies>

Extended Showcase

The Showcase includes now more Examples.
  • Example for Vertical Form Layout
  • Example for Inline Form Layout
  • Form Elements with Help Text
  • Textfields with prepended text or appended text
  • An AJAX Example in combination with the Struts jQuery Plugin
Currently only the the SNAPSHOT Version 3.3.0 of Struts2 jQuery Plugin is supported, because Bootstrap requires jquery version 1.7.1 as minimum.

Download: http://code.google.com/p/struts2-bootstrap/downloads/list
Showcase: http://struts.jgeppert.com/struts2-bootstrap-showcase/
Issues: http://code.google.com/p/struts2-bootstrap/issues/list

New Struts2 Bootstrap Plugin released

Posted by on 01 Feb 2012 | Filed under: java, struts2, Struts2 Bootstrap Plugin

I have just released my first GIT based Project at Google Code. Thanks to IntelliJ IDEA for the great GIT Integration.

This Struts2 Bootstrap Plugin is for an easy Integration of Twitter Bootstrap into an Bootstrap based Struts2 Webapp. It provides a Head Tag which loads necessary resources and a new theme for Struts2 Tags. A new Struts2 Bootstrap Plugin Showcase provides a short introduction how to use this Plugin.

Steps to use it in your Project:

1. Add the jar

To use this plugin you need to copy the struts2-bootstrap-plugin.jar into your WEB-INF/lib path. A maven Integration is following soon.

2. Add the Head Tag to your JSP

To load the required CSS Styles and JavaScript Resources you need to add the Head Tag to your html head area like following Example.

<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ taglib prefix="sb" uri="/struts-bootstrap-tags" %>
<!DOCTYPE html>
<html lang="en">
<head>
    <title>MyApp Title</title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
 
    <!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
    <!--[if lt IE 9]>
    <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
 
    <sb:head/>
</head>
<body>
...
</body>
</html>

3. Using the Form Tags

Now you are able to use the form theme, simple by adding the theme="bootstrap" attribute to your tag.

    <s:actionerror theme="bootstrap"/>
    <s:actionmessage theme="bootstrap"/>
    <s:fielderror theme="bootstrap"/>
 
 
    <s:form action="index" enctype="multipart/form-data" theme="bootstrap" cssClass="form-horizontal"
            label="A sample horizontal Form">
        <s:textfield
                label="Name"
                name="name"
                tooltip="Enter your Name here"/>
 
        <s:textfield
                label="Textfield with Error"
                name="error"/>
 
        <s:textarea
                tooltip="Enter your Biography"
                label="Biography"
                name="bio"
                cols="20"
                rows="3"/>
 
        <s:select
                tooltip="Choose Your Favourite Color"
                label="Favorite Color"
                list="{'Red', 'Blue', 'Green'}"
                name="favouriteColor"
                emptyOption="true"
                headerKey="None"
                headerValue="None"/>
 
        <s:checkboxlist
                tooltip="Choose your Friends"
                label="Friends"
                list="{'Wes', 'Patrick', 'Jason', 'Jay', 'Toby', 'Rene'}"
                name="friends"/>
 
        <s:radio
                tooltip="Choose your Best Friend"
                label="Best Friend"
                list="{'Wes', 'Patrick', 'Jason', 'Jay', 'Toby', 'Rene'}"
                name="bestFriend"
                cssErrorClass="foo"/>
 
        <s:checkbox
                tooltip="Confirmed that your are Over 18"
                label="Age 18+"
                name="legalAge"/>
 
        <s:submit cssClass="btn"/>
    </s:form>

Download: http://code.google.com/p/struts2-bootstrap/downloads/list
Showcase: http://struts.jgeppert.com/struts2-bootstrap-showcase/
Issues: http://code.google.com/p/struts2-bootstrap/issues/list

Older Entries »