Skip to main content

Posts

Showing posts from April, 2016

Display Referencing Nodes List on Referenced Node Using EVA (Drupal 7)

This is in continuation of the previous tutorials about how to show a add link using prepopulate link. In this, we are going to create a view using EVA to show all the referencing nodes on referenced node (i.e. Show courses offered by colleges).

- create your Views to display the Courses attached to a referencable node (i.e. College) being viewed. This will show all the courses offered by College when the college node is viewed. Here again, EVA (i.e. Entity Views Attachments) comes into play.
- While atadmin/structure/views, click the "Add new view" link, name it something like "Attached Courses" and select Show Content of type Task. Uncheck create a page, and leave create a block unchecked. - Use the "+Add" button near the top, to add an "EVA Field" display to your newly created View.
- Under the "ENTITY CONTENT SETTINGS" pane, select "Node" for the "Entity type", select the "College" for Bundles (i.e. the …

Create Entity Reference Pre-populate Add Links using Views in Drupal 7 ( Tutorials )

This post is about adding an entity reference pre-populate link to a node in Drupal 7. Entity Reference Pr-populate module is such a powerful module but lacks the features of adding link out of the box. The method discussed utilities the flexibility of Views in Drupal 7 to achieve this.
Required Modules: - Entity Reference - Entity Reference Pre-populate - Views - EVA (i.e. Entity Views Attachments)
1. CREATE CONTENT TYPES: For the sake of this example, I have created two content types - - College - Course 2. CREATE ENTITY REFERENCE FIELD Create a Entity Reference field using autocomplete widget on the "Course" content type. This field can be set to required field if needed.
Steps: - Go to /admin/structure/types and click on "Manage fields" under "Course" content type. - Add a new Entity Reference field - "field_college_er" - Check the "Enable Entity reference prepopulate" box, select "Disable field" for Action and "Do noth…