0
votes
0answers
19 views

How to add entity reference to custom entity

I've created two custom entities and need to create a one to many reference between them. What I would like to achieve is to have the Child entity with field Parent that would reference the Parent ...
0
votes
0answers
39 views

Assigning custom entities to other entities

I will like to create a new entity, Job, in my site which can be assigned to other entities, such as Customers. This would be similar to how Comments are related to Nodes. In my particular example, ...
0
votes
0answers
27 views

custom entity fields are revised

I created a custom entity with "model entities" module and I added some fields to this entity. How can i disable field revision's for my custom entity?
0
votes
0answers
79 views

Creating an entity reference in a custom entity

I have created an entity that I want to collect data with from an external source and I want to reference that data to a node. How should i set up that entity in DB so it can properly reference a ...
1
vote
1answer
86 views

How do I programmatically create an entity reference in hook_entity_info()?

Is there a way to create an entity reference in hook_entity_info? I was hoping for something like the following. 'entity keys' => array( 'id' => 'id', 'store_ref_id' => 'store_ref_id', ...
0
votes
0answers
567 views

Entity Reference Module > Undefined & Non-Object Crashes

Preface I have a fresh site install of Drupal. I'm fairly new to Drupal, but I feel rather confident with anything but module hacking right now. I've just finished about a month+ of editing and ...
0
votes
0answers
52 views

Get list of all entities that have a reference (via organic groups) to another entity (different bundles)

I have a "Date" entity and an "Event" entity. Dates can be linked to Events via Entity Reference using the OG Reference widget. I am having trouble getting all of the dates for a specific Event. I ...
0
votes
1answer
142 views

How would I use entity wrapper to insert new values into an entity property list? bundle?

I would like to save a list of values into a entity property. foreach ($results as $result) { $wrapper->title->set(value); } Can an entity property hold an array of values or would I use ...
0
votes
0answers
31 views

Create new entity references based on lastfm lookup using the entity api

I have an entity, that I want to then create entity references for using the entity api. I am doing a look up on the lastfm api to compare artist names with my entity with contains an artist name. ...
3
votes
2answers
620 views

How to programmatically create an entity and fill in entity reference fields

I'm trying to create an entity that has a number of entity refernce fields, and I'm confused about the best way to do that. so far I've gotten as far as this $entity = entity_create('mytype', ...
1
vote
1answer
275 views

How do I use entity_metadata_wrapper to create a node and at the same time multiple node references?

I have an XML response from a REST api call that returns an object with an array of sub-objects contained in it. I need to create a node with all the properties of the top level object and node ...
0
votes
2answers
465 views

referenced entity not showing up in the node view page or in any view I create

I have a custom module which defines a custom entity. On a content type, I have an 'Entity reference' field that let's me select a custom entity. The value is saved in the database (I looked directly ...
0
votes
1answer
205 views

Puilling Information From Referenced Entities to Display/Use In A Custom Content Type?

Exposition I have two Content Types with the following fields: Scenes Scene Name Starring (Actor's names) Streaming Link Releases (DVD Releases) Title Description Starring (All actor's names ...
0
votes
1answer
87 views

Referencing both a node and user in the same field

In Drupal 7, I am looking to create a field in a content type that can either reference another specific content type and/or also reference a user. I am creating the content type programmatically in ...