public function sort(SS_HTTPRequest $r) {
		if($sort = $r->requestVar('dashboard-panel')) {
			foreach($sort as $index => $id) {
				if($panel = DashboardPanel::get()->byID((int) $id)) {
					if($panel->MemberID == Member::currentUserID()) {
						$panel->SortOrder = $index;
						$panel->write();
					}					
				}				
			}
		}
	}
public function sort(SS_HTTPRequest $r) {
		if($sort = $r->requestVar('dashboard-panel')) {
			foreach($sort as $index => $id) {
				if($panel = DashboardPanel::get()->byID((int) $id)) {
					if($panel->MemberID == Member::currentUserID()) {
						$panel->SortOrder = $index;
						$panel->write();
					}					
				}				
			}
		}
	}
public function sort ( SS_HTTPRequest $ r ) { if ( $ sort = $ r -> requestVar ( 'dashboard-panel' ) ) { foreach ( $ sort as $ index => $ id ) { if ( $ panel = DashboardPanel :: get ( ) -> byID ( ( int ) $ id ) ) { if ( $ panel -> MemberID == Member :: currentUserID ( ) ) { $ panel -> SortOrder = $ index ; $ panel -> write ( ) ; } } } } }
A controller action that handles the reordering of the panels

@param SS_HTTPRequest The current request
@return SS_HTTPResponse
A controller action that handles the reordering of the panels