Akelos Framework v1 forum archive. This forum is no longer maintained. To report bugs please visit https://github.com/akelos/akelos/issues
    • CommentAuthorguillaumev


    I have this in my view: <?php echo $date_helper->date_select("tree", "plantation_on", array('discard_day' => true, 'start_year' => 1749, 'end_year' => date('Y'))); ?>

    and this in my controller: $this->Tree->create($this->params["tree"]);

    It adds the tree in the database without any problem, but it uses the current date instead of using the date given in the date_select.

    When I try to output the plantation_on using this code: $tree = new Tree($this->params["tree"]); Ak::getLogger()->info($tree->plantation_on);

    It outputs 1994-3 for example.

    Unless I'm missing something, there are two bugs here: - The month should be prefixed with a 0 in order to have a date parseable by SQL - The day should be added to a default of 01

    But maybe I'm missing something...