How to use native data type as a field in drupal 7?

I have several user data types in drupal 7

  • a restaurant
  • menu
  • recipe
  • cook

I want to create associations between this data collector โ†’ restaurant โ†’ menu โ†’ recipe so that the recipe can get the name of the cooks and the address of the restaurants and the menu can get a list of recipes, etc.

In the SQL country, I would call it a foreign key, but I have a lot of problems finding how to do this in drupal 7.

I suspect there must be some kind of module or functionality that I am not familiar with. But drupal uses its own jargon, and I think I'm falling for my google-fu

Does anyone know what I'm looking for?

+5
source share
2 answers

, , , . ,

  • ( ) (- , , ..).
  • ( ) node.

References ( Drupal 7 nodereference, CCK Drupal 6). . , . () node, node. Drupal 6 Node referrer . , Drupal 7.

. Entity E ntity API. , , , () Entity (Seach API ..).

, Entity, Relation. . , , (, - ).

, node. Relation, References Drupal 6, . hook_node_view() , , $node->content .

Entity , node, node ( node ). node ( , hook_node_view()) .

+5

Drupal 6 CCK Node Reference. Node - , node. Drupal 7, CCK , Node References.

+2
source

All Articles