table_name = $this->dbl->prefix . 'arlo_eventtemplates_categories'; } protected function save_entity($item) { $sql = " UPDATE " . $this->table_name . " SET et_order = %d WHERE et_arlo_id = %d AND c_arlo_id = %d "; $query = $this->dbl->query( $this->dbl->prepare($sql, !empty($item->SequenceIndex) ? $item->SequenceIndex : 0, $item->EventTemplateID, $item->CategoryID) ); if ($query === false) { throw new \Exception('SQL error: ' . $this->dbl->last_error . ' ' .$this->dbl->last_query); } } }