![]() |
Auto create date - annoation - Codeigniter 2 and Doctrine 2 - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Auto create date - annoation - Codeigniter 2 and Doctrine 2 (/showthread.php?tid=46385) |
Auto create date - annoation - Codeigniter 2 and Doctrine 2 - El Forum - 10-30-2011 [eluser]Mario Ropič[/eluser] Hello! I am using Doctrine 2 with Codeigniter 2 and I would like to Doctrine automatically generate current date on insert in a given field in the table. CLASS FILE: Code: <?php INSERT METHOD: Code: $worker = new models\Workers(); Everytime I insert new record in table "workers", there is allways "created_on" field NULL instead of insertion date. What am I doing wrong? This question is also on Stack Overflow. |