本文发表在 rolia.net 枫下论坛(1) design a data structure in MySql, create tables.
(2) design a stylesheet for a portlet to display data tree structure.
(4) design javascript library wrapped in JSP for dynamic session id, and language support.
(5) In JS library, design mousedown, mouseup, mousemove functions, ajax call, portlet refresh.
(6) In application tier, design ajax request handler, reuse stylesheet in (2) to be response.
Next improvement:
(1) when an item is drag-and-dropped, client side DOM will be updated, instead of sending request to server. When everything is ready, DOM will be send to server and update database.
(2) when an item is drag-and-dropped, conversation object on application tier will be updated through ajax calls, When everything is ready, data in object will be committed into database.
Problems:
(1) Mouseover event is laggardly fired. You have to drop item in the right angle, and with some sort of speed.
(2) Need a loop in client to slow down item return movement when mouse is up to build better user UI experience.
(3) Need further coding for leaf items reshuffling at the same branch level, new branch level creation, and branch leaf reshuffling.更多精彩文章及讨论,请光临枫下论坛 rolia.net
(2) design a stylesheet for a portlet to display data tree structure.
(4) design javascript library wrapped in JSP for dynamic session id, and language support.
(5) In JS library, design mousedown, mouseup, mousemove functions, ajax call, portlet refresh.
(6) In application tier, design ajax request handler, reuse stylesheet in (2) to be response.
Next improvement:
(1) when an item is drag-and-dropped, client side DOM will be updated, instead of sending request to server. When everything is ready, DOM will be send to server and update database.
(2) when an item is drag-and-dropped, conversation object on application tier will be updated through ajax calls, When everything is ready, data in object will be committed into database.
Problems:
(1) Mouseover event is laggardly fired. You have to drop item in the right angle, and with some sort of speed.
(2) Need a loop in client to slow down item return movement when mouse is up to build better user UI experience.
(3) Need further coding for leaf items reshuffling at the same branch level, new branch level creation, and branch leaf reshuffling.更多精彩文章及讨论,请光临枫下论坛 rolia.net