KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.

HELP with DateRangePicker #920

Open paulo opened this topic on on Jun 11 - 4 comments

paulo commented on Jun 11

Hi, I am trying to follow the example https://www.koolreport.com/examples/reports/inputs/order_list/ but I am getting no results. If I remove the databapicker filter, I see the results. I've tried Get and POST. With and without the 'load' button. When I add the load button I and click on it I get "419 Page Expired"

HEre is my info:

 use \koolreport\inputs\POSTBinding;
    protected function defaultParamValues()
        $start_date = date('Y-m-d', strtotime('first day of last month'));
        $end_date = date('Y-m-d', strtotime('last day of last month'));
        return array(
           // "dateRange"=>array(date("Y-m-d 00:00:00"),date("Y-m-d 23:59:59"))

    protected function bindParamsToInputs()
        return array(

 function setup()
 WHERE ST.status = \"active\" and T.tour_status !=\"0\" AND T.startDate > :start  AND  T.endDate < :end
                    ORDER BY T.startDate")

Now, in the view:

   <form method="post">
        <div class="row">
            <div class="col-md-8 offset-md-2">

                <strong>Date Range Picker</strong>
                    "name" => "dateRange",

                <div class="form-group text-center">
                    <button class="btn btn-success"><i class="glyphicon glyphicon-refresh"></i> Load</button>

            if ($this->dataStore("oncalltours")->countData() > 0) {
                    "dataStore" => $this->dataStore("oncalltours"),
                    "options" => array(
                        "fixedHeader" => true,
                        "ordering" => true,
                    "cssClass" => array(
                        "table" => "table table-bordered"
                    "columns" => array(
                        "id" => array(
                            "type" => "text",
                            "label" => "id",
                            "formatValue" => "<a href='https://my.ellisontravel.com/tour/tours/@value'>@value</a>"
                        "client" => array(
                            "type" => "text",
                            "label" => "Client(s)"
                        "tourname" => array(
                            "type" => "text",
                            "label" => "Tours"

            } else {
                <div class="alert alert-warning">
                    <i class="glyphicon glyphicon-info-sign"></i> Sorry, we found no orders found


thank you very much for helping Paulo

KoolReport commented on Jun 12

Do you use in anykinds of framework?

paulo commented on Jun 13

yes, we are a Laravel shop. I've updated to the latest version of KoolReport. thanks

artemia3 commented on Jun 20

Solution in laravel, i have the same error think add csrf directive

    <form method="post">
   <?php echo csrf_field() ?>

good job eric

paulo commented on Jun 20

thank you very much artemia3. It seems to be working now at least locally. I appreciate. @Koolreport, this should be added to your documentation. thank you all

Give tips to supporter for his good work

If you feel that supporter has done a good work, consider giving him some credit. Any amount put into the tips box below is appreciated. By doing so, you have contribtuted to the existence of KoolReport and the quality of support.

Tips box
help needed