coachz

Forum Replies Created

Viewing 10 replies - 1 through 10 (of 10 total)
  • Author
    Replies
  • in reply to: Sort Grid #123755
    coachz
    Participant

    Thanks for the reply. I believe that demo is just for sorting. I’m trying to reload the grid and sort it after the reload. I cannot get that to work unless i have a timeout. Is that the only way?

    in reply to: Sort Grid #123733
    coachz
    Participant

    When i try the single line, it doesn’t sort.

    in reply to: Add scrollbar to top of grid ? #123573
    coachz
    Participant

    That’s not my code, just somebody elses site.  Is there are an easy way to add the horizontal scrollbar to the top or are you saying that would be complicated to do ?  Thanks for the time.

    in reply to: Add scrollbar to top of grid ? #123565
    coachz
    Participant

    Thank you.  My goal is to have 2 horizontal scrollbars, one at the bottom of the data grid like I have now and one additional one above the data.

    http://www.ok-soft-gmbh.com/jqGrid/FrozenColumnsAndScrollbarOnTop.htm

    in reply to: External drop down filter ? #102270
    coachz
    Participant

    Thanks so much. Is there an example anywhere for this by chance?

    in reply to: How to Paginate please #102253
    coachz
    Participant

    I had to write the entire paginator…….

        // coming in from jqGrid
            Log::info(Input::all());
                // array (
                //   ‘_search’ => ‘false’,            // search enabled
                //   ‘nd’ => ‘1410449702065’,
                //   ‘per_page’ => ’10’,
                //   ‘current_page’ => ‘1’,
                //   ‘sidx’ => ‘CompanyName’,
                //   ‘sord’ => ‘desc’,
                // )

            $page = Input::get(“page”, 1);    // get the requested page
            $limit = Input::get(“rows”); // get how many rows we want to have into the grid
            $sidx = Input::get(“sidx”, 1); // get index row – i.e. user click to sort
            $sord = Input::get(“sord”, “asc”); // get the direction
              if (!$limit) $limit = 25;

            $count = DB::table(‘customers’)->count();
            
            // calculate the total pages for the query
            if( $count > 0 && $limit > 0) {
                $count = ceil($count/$limit);
            } else {
                $count = 0;
            }
            
            // if for some reasons the requested page is greater than the total
             // set the requested page to total page
            if ($page > $count) $page=$count;

            // calculate the starting position of the rows
              $start = $limit * $page – $limit; // do not put $limit*($page – 1)

            // if for some reasons start position is negative set it to 0
              // typical case is that the user type 0 for the requested page
              if($start <0) $start = 0;

              Log::info($sidx . “|” . $sord . “|” . $limit . “|” . $start);

            $results = DB::table(‘customers’)->orderBy($sidx, $sord)->take($limit)->skip($start)->get();
            
            Log::info($results);
            //$paginationResults = Paginator::make( $rows, $count, $page);
                 //$items – record set of query result
                 //$total – number of records into fetch result
                 //$per_page – number of records per page you want

            //$results = Customer::all();
            //$arr = [“page” => 1, “records” => 4, ‘total’=> 2, ‘rows’ => $results];
            $arr = [“page” => $page, “records” => $limit, ‘total’=> $count, ‘rows’ => $results];
            //return Response::json($arr);

            return Response::json($arr);

    in reply to: How to Paginate please #102247
    coachz
    Participant

    I’m sorry but that didn’t help me solve my problem.  I have pasted what the server is returning to the grid and what my grid config is.  Why do I not get any pagination or data showing up please ?

    in reply to: Can’t get datepicker to work #99789
    coachz
    Participant

    paste was wrong.

    in reply to: Page Nav input too small #97058
    coachz
    Participant

    yeah but i'm not great at css

    in reply to: Hide a column in jqGrid #97055
    coachz
    Participant

    add

Viewing 10 replies - 1 through 10 (of 10 total)

Stay connected with us in your favorite flavor!