Showing posts with label Wicket. Show all posts
Showing posts with label Wicket. Show all posts

Monday, February 18, 2008

Wicket Version 1.3.1 released

Wicket released the version 1.3.1

http://www.apache.org/dyn/closer.cgi/wicket/1.3.1

Following bugs are fixed and improvments are done:

Bugs

  • WICKET-812 - Submit button, multipart content and UploadProgressBar
  • WICKET-989 - DatePicker: NaN if numerical input cannot be parsed
  • WICKET-1184 - PageSavingThread keeps running after undeploy
  • WICKET-1194 - UploadProgressBar incompatible with submit buttons onSubmit method (in FireFox at least)
  • WICKET-1243 - the DatePicker show the same week title in china.
  • WICKET-1249 - modal.js conflicts with mootools and possibly other javascript frameworks. + patch fix
  • WICKET-1254 - Binding to a BigDecimal don't honor browser locale
  • WICKET-1257 - iframe get request done 2x after ajax change in IE
  • WICKET-1258 - AjaxFormChoiceComponentUpdatingBehavior assumes Radio/Choice items are a direct child of the group in the client-side DOM
  • WICKET-1260 - CheckBox.setRequired() is not picked up in 1.3-final
  • WICKET-1262 - Page#readResolve is not called
  • WICKET-1263 - Using nested wicket:enclosure throws exception
  • WICKET-1264 - assertComponentOnAjaxResponse does not work with WicketTester.clickLink
  • WICKET-1270 - NPE in ListMultipleChoice.updateModel()
  • WICKET-1271 - Script in RenderHead method of AjaxFormChoiceComponentUpdatingBehavior needs fixing
  • WICKET-1274 - Only properties from first panel-implementation loaded when using different implementations of an abstract panel on the same page
  • WICKET-1275 - FLAG_HAS_BEEN_RENDERED is set when rendering invisible components
  • WICKET-1277 - When no component is focused on AjaxRequestTarget, wicket tries to focus element with id 'null'
  • WICKET-1282 - AjaxFormSubmitBehavior doesn't work well with nested forms
  • WICKET-1290 - PrependingStringBuffer.equals(Object obj) is not reflexive
  • WICKET-1304 - Form processing workflow is broken for FormComponentPanels

Improvements

  • WICKET-1020 - expose configuration of CompoundValidator, NumberValidator
  • WICKET-1193 - i18n: Translation of resource files in Korean
  • WICKET-1252 - Default start week day based on locale
  • WICKET-1272 - Better clustering support for DiskPageStore
  • WICKET-1283 - Allow to query component markup id without creating one
  • WICKET-1284 - Report last focused element id on ajax request
  • WICKET-1293 - Improve SelectOptions: allow customization of created SelectOption objects
  • WICKET-1299 - HybridUrlCodingStrategy should throw a PageExpiredException if a RequestListenerInterface is targeted on a non-existent page-id/version
  • WICKET-1309 - Properties files translation (_es)
  • WICKET-1313 - Created Norwegian translation of Application.properties
  • WICKET-1318 - NavigatorLabel should be localizable

Monday, January 21, 2008

Edit functionality for the rows of a DataView

Description
How can I implement the edit functionality over the whole row(s) of a DataView component?

Solution
JAVA
Add following code snippet in the implementet Method void populateItem(Item item) of the DataView component:

item.add(new AjaxEventBehavior("onclick") {
protected void onEvent(AjaxRequestTarget target) {
// action
}
});


Through this piece of code the action is called by each onclick event on the whole row.


HTML
Additionaly you can define the hand cursor of the row TR-tags:

<tr wicket:id="data" style="cursor: hand;">

Monday, January 7, 2008

IE Scrolling Problem bei Wicket Modal Windows

Beschreibung

Durch unser Konzept von ausschliesslich Ajax und Modal Dialogen, erkannten wir einen Fehler. Die Vorraussetzungen für den Fehler sind Wicket Release 1.3.0 und den Internet Explorer.

Das Problem tritt auf, wenn die Website zu lang ist, dann zeigt der Internet Explorer die Scrollbar an. Wenn jetzt ein Wicket Modal Window geöffnet und anschliessend geschlossen wird, scrollt der Internet Explorer ans Ende der Seite.

Lösung

Dieses Problem entsteht durch einen Bugfix, der ein Fokus Problem des Internet Explorer löst. Ein Bug ist bei Wicket erfasst, wer trotzdem schnell eine Lösung braucht kann dies wie folgt lösen:

Die Zeile in der Javascriptdatei

apache-wicket-extension-1.3.0.jar\org\apache\wicket\extensions\ajax\markup\html\modal\res\modal.js von der Funktion close:

document.body.appendChild(e);

muss durch folgende ersetzt werden:

document.body.insertBefore(e, document.body.firstChild);

und fertig

Saturday, January 5, 2008

Beurteilung des Frameworks Wicket

Was ist Wicket?
Wicket ist ein Apache Projekt, welches als Framework für Web-Applikationen gedacht ist. Wicket ist am ehesten vergleichbar mit Tapestry oder Echo. Es trennt Business Logik oder sonstige Logik komplett von der Benutzeroberfläche. Die Logik wird in Java Klassen implementiert, das GUI ist pur HTML. Jedes Element(Label, Textfeld, Panel) repräsentiert eine Java Klasse mit ihrem dazugehörigen HTML-Code. Durch hinzufügen von Elementen zu anderen Elementen kann so die Web-Applikation zusammengebaut werden. Die Verwendung von Javascript und CSS ist natürlich auch möglich.

Dadurch dass Wicket sich selber verwaltet so zusagen, müssen keine Daten oder Session verwaltet werden.

Vor kurzem wurde Wicket in der Version 1.3 released. Die Version ist sehr umfangreich und stabil. Sehr komfortabel sind auch die Ajax Komponenten, welche es erlauben eine komplett mit Ajax umgesetzte Web-Applikation zu realisieren.

Der erste Start
Der erste Start mit Wicket war sehr einfach. Herunterladen der Jars, implementierung der Test-Applikation und schon lief es. Bis allerdings das Konzept von Wicket verstanden wurde, dauerte es eine Weile.

Die hilfreichste Seite war http://www.wicket-library.com/wicket-examples. Die Website enthält viele und auch komplexe Beispiele. Eine einfache Web-Applikation konnte somit schon umgesetzt werden.

Web-Applikation komplett mit Ajax
Nach den ersten Versuchen wurde die Produktiv Web-Applikation begonnen. Diese sollte komplett mit Ajax und modalen Dialog umgesetzt werden. Dabei wurden viele Hürden bewältigt und Erfahrungen gesammelt.

Fazit
Mit Wicket ist grundsätzlich alles möglich. Die Integration von Javascript Frameworks wie z. B. Dojo lässt sich mit einiger Erfahrung auch in passabler Zeit bewärkstelligen.

Die Anforderungen die wir an Wicket stellten, wurden alle mit einem guten Ergebnis erfüllt.