public function insert(SimpleBlogPost $blogPost) { //needs changing //$now = new DateTime(); $blogPost->setId(null); //$flightBooking->setCreatedOn($now); //$flightBooking->setLastModifiedOn($now); $blogPost->setStatus(SimpleBlogPost::PENDING); $sql = ' INSERT INTO blog_posts (blog_id, status, date, content, description, created_by, modified_by, restaurant_id) VALUES (:blog_id, :status, :date, :content, :description, :created_by, :modified_by, :restaurant_id)'; return $this->execute($sql, $blogPost); }