All Questions
370 questions
2
votes
1
answer
538
views
Arrange formatted fields in Views row using a template
I want to render the rows of my “Recent content” Views page using a template in order to
subdivide the rows into multiple divs,
freely move around the rendered fields within these divs, and
apply ...
1
vote
1
answer
950
views
Views math expression or Computed field to find date difference in views
I have two content type, Bill (Type1) and Cash Receipts (Type2), Type2 referencing Type1 when cash is received.
In Type1 I have date field called (Bill Issue date), and Type2 I have date field cash ...
1
vote
2
answers
872
views
Views, Pathauto and contextual filters
My question is rather simple, but I didn't manage to find anything that can help.
Summary of my setup :
Pathauto
Views
Entity Reference
So I have various custom content types, which I want to ...
0
votes
1
answer
568
views
I need to reference a custom field I created in User Profile
I used Drupal 7 computed fields to calculate weight loss. This is what I current have. Which works in a sense but only where the user inputs their initial weight and subtracts their current weight to ...
0
votes
1
answer
607
views
How to get the actual value of a field in Views?
I'm using the Views module and Drupal 7 and want to add a class to all rows of my table that have a certain value for a certain field.
The field is a bit field and is included in my query. I have ...
0
votes
1
answer
1k
views
Ajaxy entity reference views filter by entity reference view
I have two content types that share a taxonomy (Size).
On content type A, I have an "entity reference" to content type B in the form of a checkbox widget.
What I want:
On the node creation form, ...
4
votes
3
answers
1k
views
Get field_collection values in field template
I have installed field_collection and have a collection called field_contact,
each entry of which has a field called field_contact_url
I'm trying to customise the display of that field by overriding ...
1
vote
2
answers
690
views
Entity Reference and Views to allow a nested structure
I'm trying to implement a nested structure in such a way as to get a table (within a view?) similar to this:
Parent Child Grandchild Age Sex
John ...
3
votes
1
answer
908
views
How to add a class to the <a> link elements within a Multiple Values field in a View?
I have a Views field (in this case, taxonomy term references) with Multiple Values set to "Display all values in the same row", using the Link formatter and a seperator. I want to add a class to each "...
8
votes
3
answers
7k
views
Show node IDs along with titles in Entity reference Autocomplete list
I'll like to add this functionality to the autocomplete widget in Entityreference field to show node ID next to the titles in the dropdown list. The reason behind the idea is to differentiate between ...
3
votes
1
answer
268
views
How to show data of user that flagged a content(5 flag types or more)?
This is a followup question about this Old question
I have 5 flag types for a content type. consider we have 5 flag types and we don't know how many flags our user used. I mean, the first user can ...
2
votes
2
answers
2k
views
How to change a grouping field in a view programmatically?
I've added a custom field to a view and want to display results as a grid grouped by this field. How do I set that "Grouping field Nr.1" option in my code? I tried the following but it doesn't work (...
3
votes
5
answers
4k
views
How to bulk update select list fields?
I have a content type and it has a select list field. There are two options Yes or No and this field is not a required field.
The website has about 100,000 nodes and I want to bulk update all nodes ...
0
votes
1
answer
632
views
Set a Data Value from Text field to Term Reference field
Node has two fields:
Text field
Term reference field (autocomplete?)
The Text field is old and already has 500 nodes with 500 unique values.
The Term reference field is new and needs to contain same ...
1
vote
4
answers
3k
views
Map generated from custom address fields
I have a seemingly simple problem, but I've been stuck with it for some time now.
I have a big database of nodes of one content type. There are addresses there made of text fields: one field for ...
3
votes
3
answers
1k
views
How to count entity references from same field in different entity types?
I have three entity types:
Company
Team (has field_company which is an entity reference to Company)
Employee (also has field_company, and field_team which is an
optional entity reference to Team)
...
7
votes
1
answer
16k
views
can we add new column to a view programmatically?
I want to add new field in a existing view programmatically.
I am trying to use hook_views_pre_render().
function registration_export_views_pre_render(&$view) {
if ($view->name=='...
2
votes
3
answers
5k
views
How to get a field in a exposed filter criteria as an autocomplete?
In a view the field which has widget autocomplete does not get
an option to select as dropdown or autocomplete in exposed filter criteria.
I have a field in a content type which has following ...
3
votes
5
answers
7k
views
How to filter views results based on entity reference field
I use Drupal 7 and entityreference module.
I have a content type with a entity refenrece field to users called field_users_referenced.
So I created a view with views module and list nodes of thats ...
2
votes
2
answers
220
views
Multilingual Taxonomy Views - Entity Translation
I am trying to create a multilingual taxonomy view using Entity translation. So far, I am stuck displaying an English view even when using a language code.
I'm looking for the steps needed for this....
1
vote
1
answer
1k
views
Creating individual fields from a multi-column Field API widget
This references the Addressfield and Views modules.
I would like to have extended Views support for the Addressfield module like the Location module does. Some of the extra fields that the Location ...
2
votes
1
answer
871
views
How to pass metatags from a node into a view?
I'm sending the information of my node into an external application and I need to be able to send the meta tags of that node as well. Unfortunately, I do not see the meta tag fields.
My question is.....
0
votes
1
answer
219
views
How do i get views field labels in the template file
I am creating a view, and displaying view by using custom template files. As per theme suggestions I named the template file for fields as views-view-fields--blog-display--page.tpl. In this file I ...
0
votes
0
answers
40
views
How can I display a selected value of a multivalue entity reference field?
I have two content types A and B.
There is a multi valued field Persons in content type B. I have created a node of type B and enter two values in Persons field, X and Y.
Content type A has an ...
0
votes
1
answer
2k
views
How do you render a View with arguments using a Computed Field?
I have a computed field and i want to output a View's - block display with arguments passed into it. Can someone provide me with an example code of how to output a view with arguments?
thanks!
0
votes
3
answers
2k
views
ON/OFF toggle as a custom view field
I have a table view output of node data. The node type has a list field called status.
Status is set to accept a single value. It has the following option to select from:
Inactive
Active
Submitted
...
3
votes
4
answers
13k
views
remove divs and spans from view output
In my page.tpl.php I'm doing this to display one of my view:
print views_embed_view('teaserview', 'default');
That gives me the following html output:
<span thmr="thmr_10">
<div class="...
0
votes
1
answer
305
views
Node select list + dropdown + view of entity references
In a content type, and a field is an entity reference to another content type (the professionals companies).
I created a view, to display: first: the professionals flagged as favorite; then all the ...
1
vote
6
answers
5k
views
How do I use a field summary in a view?
I'd like to make a Drupal 7 view which displays nodes using the following behavior:
1) Show the body summary if it is populated.
2) Never show a trimmed version of anything.
3) If the body summary is ...
1
vote
1
answer
1k
views
In Views how to configure a contextual filter to exclude the node being viewed?
I have the following setup: a content type (event) can have a "mother" event, which is configured as entity reference (Basically it's the same event on another date).
I have a view for a single event ...
3
votes
3
answers
2k
views
Use single values added by field-collection module in Views?
I've already found this question, but it doesn't really help me out, maybe I just don't understand it (I've got the latest version of the module). How to integrate Field collection module in Views?
I ...
0
votes
1
answer
39
views
Provide name for Entity Reference
Is there any way referenced entities could be named in a meaningful way?
Currently when I am creating a custom view and need to reference some entity, I have tens of entities that are named exactly ...
0
votes
1
answer
3k
views
How to set a contextual filter based on an entity reference field
I am currently working on a radio website.
Here is the basic information to keep it simple.
I have two content types: [emission] (programme) and [podcast].
The [emision] content is merely a general ...
0
votes
1
answer
154
views
Drupal 7 Views filter criteria Entity Reference
At the moment i'm making a drupal environment.
I'm trying to reach the following:
"Use a views to show my content types, but only the content types that have lets say "ads" as a field_type (Entity ...
1
vote
1
answer
1k
views
Dynamically adjust argument or filter to views entity reference filter based on value from select list in form
I have a entity reference field that references a taxonomy term from a vocabulary named "fund". Now I'm needing to add a fiscal year field to the fund terms to allow us to have different budget lines ...
0
votes
4
answers
2k
views
How do I get a view to display as themed within a simplenews html email?
I am trying to create a simplenews newsletter, also using Simplenews Scheduler, to weekly send out a newsletter with the content defined by views.
I have a content type set up, and the views defined. ...
0
votes
0
answers
32
views
Individual row for each node field in a view
I'm trying to create a view of a node's fields, primarily a list of images and node references to be rendered with a views slideshow.
The view has two fields listed, an image field and a reference. ...
0
votes
0
answers
66
views
How to get a list of users based on the radius?
I want to allow users (workers) to give their address using addressfield and also give a distance or radius they are prepared to travel. It is a job site. When a client posts a job (node) and provides ...
0
votes
0
answers
45
views
EVA not working after update
After a safety update from Drupal 7.56 to Drupal 7.58 I also updated Views (7.x-3.18 > 7.x-3.20) and EVA: Entity Views Attachment (7.x-1.3 > 7.x-1.4), most Views are working fine, just the ones with ...
3
votes
1
answer
104
views
How do I edit the output of a field?
I am creating REST API using Services Module in Drupal 7.
I have created a View to Get lists of Groups. In this views, I have added a Field privacy which will tell if the group is Private or Public.
...
0
votes
1
answer
45
views
Filter referenced item without losing other content
I have 2 entity types Content type A and B.
Content type B has a date field and an entity reference to A.
I need a view that shows all the nodes of content type A
But also shows all the referenced ...
3
votes
4
answers
5k
views
Creating new bulk views operations (VBO) actions for custom entity types
I have the following code and created a view for my custom entity type. I just want to create a new action button to be able to change a field's text to something else. I'm not sure why this custom ...
4
votes
2
answers
4k
views
Template suggestions for file_entity.tpl.php
Short version
My aim is to theme a file field in a view of node fields. In the view configuration, the field formatter is set to Rendered file and a view mode is selected. How do I suggest a template ...
3
votes
2
answers
2k
views
Views: how to remove ending zeros from decimal field
Suppose, we have a view with a decimal field:
It is output like this:
5 000.000
Is it possible to remove the ending zeros, so it looked like this:
5 000
But if there are meaningful values in the ...
5
votes
8
answers
16k
views
Views - Add a wrapper around fields or rows
Example:
I have a view with fields:
[field_name] == Field collection item: Name
[field_title] == Field collection item: Title
[field_text] == Field collection item: Text
I can wrap these ...
0
votes
2
answers
159
views
list links to nodes in another node with Views
I'm currently struggling with the following scenario:
There are two different Content Types:
Offer
Event
What I want to achieve is this:
There are 6 offers and each of those offers have several ...
2
votes
1
answer
37
views
Strategy to consolidate multiple fields across content types?
I've got a handful of content types that all use different fields to hold the same type of data. For instance,
Content Type A --
Field Name: field_type_a_user,
Field type: Entity Reference
Content ...
1
vote
0
answers
245
views
Perform simple filtering on an Entity Reference autocomplete field
I have a content type that has an entity reference (user field) field_mr_mission_supervisor. The user accounts have a date field field_user_end_date. I'm trying to Filter the ...
0
votes
1
answer
286
views
How to programatically add a pseudo field to views and display the field value based on value of other field?
I need to add a field to view and display the value of that field depending on the value of other fields already present.
The pseudo field i need to add is not connected with any database table.
2
votes
1
answer
53
views
How do I create a unified list of referenced users in a multi-entry entity-reference field in a multi-entry field collection field?
My set up is similar to the setup in this question:
How to integrate Field collection module in Views?
I have a content type with a field collection field (hereafter itineraries) that accepts ...