Download Laravel-xCRUD Integration Full Code that includes this full demo


<?php

namespace App\Http\Controllers;

use 
Illuminate\Http\Request;

class 
xOrderingController extends Controller
{
    public function 
index()
    {
        
$xcrud Xcrud_get_instance();
        
$xcrud->table('offices');
     
        
$xcrud->button('#'"Top"'glyphicon glyphicon-arrow-up icon-arrow-up''btn xcrud-action', array(
            
'data-action' => 'movetop',
            
'data-task' => 'action',
            
'data-primary' => '{officeCode}'));
        
$xcrud->button('#'"Bottom"'glyphicon glyphicon-arrow-down icon-arrow-down''btn xcrud-action', array(
            
'data-action' => 'movebottom',
            
'data-task' => 'action',
            
'data-primary' => '{officeCode}'));
         
        
$xcrud->create_action('movetop''movetop');
        
$xcrud->create_action('movebottom''movebottom');
     
        
$xcrud->unset_sortable();
        
$xcrud->order_by('ordering');
        
$xcrud->columns('city,phone,addressLine1,country');

        
$render $xcrud->render();                              
        return 
view('xcrud_simple', ['render' => $render]);
        
    }
}

Offices

#CityPhoneAddressline1Country 
1San Francisco+1 650 219 4782100 Market StreetUSA Top Bottom View Edit Remove
2Boston+1 215 837 08251550 Court PlaceUSA Top Bottom View Edit Remove
3NYC+1 212 555 3000523 East 53rd StreetUSA Top Bottom View Edit Remove
4Paris+33 14 723 440443 Rue Jouffroy D'abbansFrance Top Bottom View Edit Remove
5Sydney+61 2 9264 24515-11 Wentworth AvenueAustralia Top Bottom View Edit Remove
6London+44 20 7877 204125 Old Broad StreetUK Top Bottom View Edit Remove
7Tokyo+81 33 224 50004-1 KioichoJapan Top Bottom View Edit Remove
Search