wire/modules/Process/ProcessPageList/ProcessPageList.js
/**
			 * Event called when the 'move' action/link is clicked on
			 *
			 * @param event e
			 *
			 */
Event called when the 'move' action/link is clicked on
@param event e
Event called when the ' move ' action / link is clicked on @param event e
function clickMove() {
				if(ignoreClicks) return false;
				var $t = $(this);
				if($(".PageListItem:visible").length == 1) {
					$t.css('text-decoration', 'line-through').addClass('ui-state-disabled');
					return false;
				}
				var $li = $t.parent('li').parent('ul.PageListActions').parent('.PageListItem'); 
				if($li.hasClass("PageListItemOpen")) $li.children(".PageListPage").click(); 
				$root.find('.PageListItemOpen').each(function() {
					var numChildren = getNumChildren($(this)); 
					if(parseInt(numChildren) > 1 && $(this).next().find(".PageList:visible").length == 0) {
						return; 
					}
					var $ul = $("<div></div>").addClass('PageListPlaceholder').addClass('PageList');
					$ul.append($("<div></div>").addClass('PageListItem PageListPlaceholderItem').html('&nbsp;'));
					$(this).after($ul);
				}); 
				var sortOptions = {
					stop: stopMove, 
					helper: 'PageListItemHelper', 
					items: '.PageListItem:not(.PageListItemOpen)',
					placeholder: 'PageListSortPlaceholder',
					start: function(e, ui) {
						$(".PageListSortPlaceholder").css('width', ui.item.children(".PageListPage").outerWidth() + 'px'); 
					}
				};
				var $sortRoot = $root.children('.PageList').children('.PageList');
				var $cancelLink = $("<a href='#'>" + options.selectCancelLabel + "</a>").click(function() { 
					return cancelMove($li); 
				});
				var $actions = $li.children("ul.PageListActions");
				var $moveAction = $("<span class='PageListMoveNote detail'><i class='fa fa-fw fa-sort'></i> " + options.moveInstructionLabel + "<i class='fa fa-fw fa-angle-left'></i></span>");
				$moveAction.append($cancelLink);
				$actions.before($moveAction); 
				$li.addClass('PageListSortItem'); 
				$li.parent('.PageList').attr('id', 'PageListMoveFrom'); 
				$root.addClass('PageListSorting'); 
				$sortRoot.addClass('PageListSortingList').sortable(sortOptions); 
				return false; 
			}
function clickMove ( ) { if ( ignoreClicks ) return false ; var $t = $ ( this ) ; if ( $ ( ".PageListItem:visible" ) . length == 1 ) { $t . css ( 'text-decoration' , 'line-through' ) . addClass ( 'ui-state-disabled' ) ; return false ; } var $li = $t . parent ( 'li' ) . parent ( 'ul.PageListActions' ) . parent ( '.PageListItem' ) ; if ( $li . hasClass ( "PageListItemOpen" ) ) $li . children ( ".PageListPage" ) . click ( ) ; $root . find ( '.PageListItemOpen' ) . each ( function ( ) { var numChildren = getNumChildren ( $ ( this ) ) ; if ( parseInt ( numChildren ) > 1 && $ ( this ) . next ( ) . find ( ".PageList:visible" ) . length == 0 ) { return ; } var $ul = $ ( "<div></div>" ) . addClass ( 'PageListPlaceholder' ) . addClass ( 'PageList' ) ; $ul . append ( $ ( "<div></div>" ) . addClass ( 'PageListItem PageListPlaceholderItem' ) . html ( '&nbsp;' ) ) ; $ ( this ) . after ( $ul ) ; } ) ; var sortOptions = { stop : stopMove , helper : 'PageListItemHelper' , items : '.PageListItem:not(.PageListItemOpen)' , placeholder : 'PageListSortPlaceholder' , start : function ( e , ui ) { $ ( ".PageListSortPlaceholder" ) . css ( 'width' , ui . item . children ( ".PageListPage" ) . outerWidth ( ) + 'px' ) ; } } ; var $sortRoot = $root . children ( '.PageList' ) . children ( '.PageList' ) ; var $cancelLink = $ ( "<a href='#'>" + options . selectCancelLabel + "</a>" ) . click ( function ( ) { return cancelMove ( $li ) ; } ) ; var $actions = $li . children ( "ul.PageListActions" ) ; var $moveAction = $ ( "<span class='PageListMoveNote detail'><i class='fa fa-fw fa-sort'></i> " + options . moveInstructionLabel + "<i class='fa fa-fw fa-angle-left'></i></span>" ) ; $moveAction . append ( $cancelLink ) ; $actions . before ( $moveAction ) ; $li . addClass ( 'PageListSortItem' ) ; $li . parent ( '.PageList' ) . attr ( 'id' , 'PageListMoveFrom' ) ; $root . addClass ( 'PageListSorting' ) ; $sortRoot . addClass ( 'PageListSortingList' ) . sortable ( sortOptions ) ; return false ; }
Event called when the 'move' action/link is clicked on
 @param event e
Event called when the ' move ' action / link is clicked on @param event e
// no other items to sort/move to // $li.children(".PageListPage").click();  // @somatonic PR163 // make an invisible PageList placeholder that allows 'move' action to create a child below this // if there are children and the next sibling doesn't contain a visible .PageList, then don't add a placeholder //$(this).prepend($ul.clone());  //$(this).addClass('PageListItemNoSort'); 