method insert documentation in bbn\Appui\Planning

Inserts an event for the given staff id

function(string $id_staff, array $event, string $id_alias = NULL, string $alias = NULL) { if ( \bbn\Str::isUid($id_staff) && (\bbn\Str::isUid($id_alias) || \is_null($id_alias)) && (\bbn\Str::isDateSql($alias) || \is_null($alias)) && ($id_event = $this->events->insert($event)) && $this->db->insert($this->class_table, [ $this->fields['id_event'] => $id_event, $this->fields['id_staff'] => $id_staff, $this->fields['id_alias'] => $id_alias, $this->fields['alias'] => \bbn\Str::isDateSql($alias) ? date('Y-m-d', strtotime($alias)) : null ]) ){ return $this->db->lastId(); } return null; }

Inserts an event for the given staff id BBN is a suite of PHP and JS libraries and VueJS components - all open-source! bbn.io, build applications, the quick way

This website uses cookies to ensure you get the best experience on our website.