public static function get_by_order($education_id) { $q = new query(RUDE_DATABASE_TABLE_EDUCATION_ITEMS_VALUES); $q->where('education_id', (int) $education_id); $q->order_by('order_num', 'ASC'); $q->query(); return $q->get_object_list(); }
public static function get($id = null) { $q = new query(RUDE_DATABASE_TABLE_SPECIALIZATIONS); if ($id !== null) { $q->where(RUDE_DATABASE_FIELD_ID, (int) $id); $q->query(); return $q->get_object(); } $q->order_by(RUDE_DATABASE_FIELD_NAME); $q->query(); return $q->get_object_list(); }