Beispiel #1
0
 public static function get_meta_relations($keys, $metadata_id)
 {
     $relations = array();
     for ($i = 0; $i < count($keys); $i++) {
         $key = $keys[$i];
         $metadata_field = ormlib::get_from_instance(new metadata_field(), array("id"), array($key));
         $metadata_table = ormlib::get_from_instance(new metadata_table(), array("id"), array($metadata_field->metadata_table_id));
         $relations = array_merge($relations, query::get_meta_relations_1($metadata_table->metadata_id, $metadata_id));
         $relations = array_merge($relations, query::get_meta_relations_1($metadata_id, $metadata_table->metadata_id));
     }
     return $relations;
 }