Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [views]

The Views module allows creating lists of content with a flexible query builder.

0
votes
0answers
22 views

How to switch between views displays through ajax

I do have a view with exposed filters and a quite hierarchical architecture of the data which demands multiple grouping and sorting criteria. because of different use cases, users need to change the ...
1
vote
1answer
20 views

Export JSON sitemap of views [closed]

I have a Drupal 8 site that is using a bunch of custom views with REST endpoints. These views contain a bunch of content nodes on them which make up a single page. I have been able to generate an XML ...
0
votes
0answers
64 views

Use Drupal's Default Views Filter Handler on “Pseudo” Views field?

How do I use Drupal's core Views filter handler plugins on a custom views field? I have a custom field which has its own FieldPluginBase Class. Does not have a DB query. MYMODULE.views.inc: /** * ...
0
votes
3answers
43 views

How can I display a list of users who have the same taxonomy term

The setup: A Taxonomy Vocabulary called "Area of work". The vocabulary has the following associated terms: A, B, C, D, E, F, G, etc. During registration users have to choose a department from the ...
1
vote
0answers
19 views

Saving a view shows “This display has no path”

I have migrated my website to a new host. Now, the front page logo is missing and dynamic block contents became static. On editing a view block, it shows: All changes are stored temporarily. ...
0
votes
1answer
22 views

Location Contextual Filter: Distance/Proximity works for all nodes but one

Drupal 7 site with Location and Location CCK modules. Client has custom content type with Location field provided by Location CCK module. Each Location node has a Views block display of Nearby ...
0
votes
2answers
41 views

Options form with FieldPluginBase?

I tried some variations on the code below, but I have not been able to pass my custom form options to render(). class CustomField extends FieldPluginBase { public function query() { // This is ...
0
votes
1answer
27 views

Cannot edit new View

Since I updated to 8.6.10, I can no longer edit a new view. I can create a view but when I go to the main interface after clicking Save & Edit, nothings works. No matter what I click on, aside ...
0
votes
1answer
14 views

Pass argument when overriding controller in RouteSubscriber

I am having the issue of overriding the default taxonomy controller /taxonomy/term/{tid}. I have created my own controller which takes {tid} as a parameter and I want to use it instead, so I overrode ...
0
votes
2answers
59 views

looking for equivalent webform select view module on Drupal 8 [closed]

I am a new to Drupal 8 I am trying to make select options with webform submission. What module do I need? and How can I make this select options with that module? Thank you very much! implement
1
vote
2answers
53 views

Print view header using the “Twig Tweak” module

I would like to print out the header for a view, but not the rest of the content using the Twig Tweak module. I've tried variations on {{ drupal_view('VIEW_NAME', 'PAGE_NAME', 'view_header') }}, but ...
0
votes
0answers
19 views

Exporting a view list

I have a clean install of Drupal 8 in Acquia running and I am using the REST API module which is built into Drupal 8. The frontend is built in Vue.js hence the reason why I am using the REST API. I ...
0
votes
0answers
14 views

Refresh title/block when validating a filter

I have built a views with filters. When we choose a filter, the results are displayed by ajax ('Use Ajax' option). I need to update the title of my views page, with the active argument of the view. ...
0
votes
0answers
19 views

Can we apply click sort on custom text?

I have 2 fields in view. First Name Last Name I have Combine this 2 fields in using "Global: Custom text" in view like, [field_user_first_name] [field_user_last_name] Now I want to apply click ...
0
votes
1answer
32 views

Calculate Database Field Value and Send to Views as New Field

I have a database field which stores a timestamp. This timestamp is sent to a custom views provider via hook_views_data(). This timestamp field is created as a date field to utilize the date format ...
0
votes
1answer
27 views

How can I update the values of an exposed view filter when another filter changes value?

I know there are several examples of this around, on a view with two exposed select list filters, I need to update the value of the second based on the value selected on the first. I can't even seem ...
0
votes
1answer
19 views

Search API - Acquia Search - Keyword Search

I'm using Acquia Search for searching within certain content types (articles, posts, etc). It seems to work for certain keywords but not others. For example, if I search: "Apple TV", I'm expecting the ...
0
votes
1answer
27 views

Sort criteria by year for blog posts

I have a View set up for blog post content in Drupal 8. The blog posts were all posted at the same time but have different "year" tags attached to them based on when the post is relevant to the ...
0
votes
2answers
33 views

How can I see all the places an asset or entity is referenced?

In Drupal 8, I have a requirement from a client that they be able to find a reference of a given asset (file, node, entity, etc) throughout a Drupal site. The ultimate goal is to know that if they ...
2
votes
1answer
104 views

How to change view REST export format

This is my settings in view. Data what I have is now in this format: [{"created":"1551709414","field_iot_integer":"43"}, {"created":"1551709404","field_iot_integer":"98"}, {"created":"1551709392","...
0
votes
0answers
44 views

Geofield Map - Show marker popup by clicking the filtered Title

I'm facing a problem with geofield map and I can't find a solution. So I have a view with all nodes of a content type, where I add an attachment of geofield map format. There I show all nodes from one ...
0
votes
0answers
7 views

Can user sort View's results in table by rewritten values?

First, this is not a duplicate of this: How can I sort a view based on a rewritten field? What I want to do is make it so that clicking on the column header will sort by the values the user sees, ...
0
votes
1answer
23 views

Show content of custom content type in a block based on taxonomy term

In D8 I have created two custom content types: Store Store products It's not an e-commerce, I just need two custom types to show all the stores on one of the subpages and the products that each ...
0
votes
0answers
17 views

How to use the “Link to Content” field in a Views Field Template [duplicate]

Within a Drupal 8 view, there is a field for "Content: Link to Content". The template below renders all of the view fields except for {{ fields.path.content }}. Is the field named wrong within the ...
1
vote
0answers
28 views

Continue odd/even striping across grouped fields?

I'm using Drupal 7 and views 3.20, unformatted list, choosing a grouping field and selecting Add striping (odd/even), first/last row classes . My views output is currently grouped by first letter: A ...
1
vote
1answer
25 views

Related block by entity reference

I have a 2 content types. Article Page and the Article content type can reference pages from an entity reference field. Now I want to display a block on Article nodes that have a same reference. ...
0
votes
1answer
29 views

What is the purpose of aggregation in view?

What is the purpose of aggregation in view? And why is it important to enable him when you make charts?
0
votes
0answers
25 views

Default entities in reference list

I'm implementing a way for providing documents to different users for download on Drupal 8. Each document has a category (implemented as own nodes). Some categories are global. Some categories are ...
-1
votes
1answer
15 views

How to sort two colums in a view based on one column? [closed]

I have two columns in table header and I have to sort them based on one.
0
votes
0answers
24 views

how to not display a sum with value 0 with views aggergation plus module

I'm using views aggregation plus module, doing group and compress from taxonomy fields and haveing a columns sum action, how can i hide sums with zero value? views conditional module do not have any ...
0
votes
1answer
29 views

How to show in a view the total number of paragraphs for a node?

I have a content type with a field of type paragraphs, with possible unlimited values. I need to show the total number of paragraphs for every node, in a column, in a views (table of fields). It seems ...
0
votes
0answers
19 views

Displaying two different content from relationship in views

I have a content type "productions" that has a related field "videos", relation to multiple "video" content type. I'm trying to build a "productions" list view that would display the following fields ...
1
vote
0answers
16 views

Drupal 8 + Modify datas structure of a views REST export

I need to build a sitemap.xml with a REST export in views. By default I get this datas structure with a REST export: <?xml version="1.0"?> <response> <item key="0"> <...
1
vote
1answer
18 views

Front Blank Webpage

Hi I am working on moving my website from local to development, but get this error: Uncaught PHP Exception InvalidArgumentException: "Class "Drupal\entity\QueryAccess\ViewsQueryAlter" does not exist."...
0
votes
1answer
39 views

Show logged in user's comments with views

I want to have a page/block the last/ recent comments the logged in user has posted. I made it in D7, but I can't seems to make it happen in D8. I googled, found article but mostly for D7 or less. ...
0
votes
1answer
17 views

Hook_views_query_alter: adding condition with entity reference value

I need to filter a table result based the current user. I added this condition in my hook_views_query_alter function my_module_views_query_alter(&$view, &$query) { global $user; if ($...
0
votes
0answers
7 views

How to target daterange field in form alter?

I have a date range field in my exposed filter and I want to add a class on it. The problem is that I can't target it despite I can do it for the rest of the field of the form.How can I achieve that? ...
0
votes
1answer
32 views

Print a View Field in Twig

I have to convert the following D7 to D8 in my view twig file. I tried the following but its not working. D7 Code : <?php print $view->result[$id]->field_field_document_upload[0]["rendered"...
0
votes
0answers
27 views

Group and compress

I am trying to add the salary of all employees by company wise using views aggregator plus module. Applied group and compress group function on company and sum group function on salary. But the result ...
0
votes
1answer
28 views

Get Node from link

Within the mymodule_preprocess_views_view_row_rss(&$variables) hook, we are able to get the link by using $variables['row']->link. However, we are not able to access the node for which that ...
0
votes
0answers
19 views

Distinct values with only a certain nid

I've been tasked with updating a drupal site for work. One of the errors that has been reported is that the view of a webform submissions is displaying duplicate entries. There are two types of ...
0
votes
0answers
25 views

How to override fields in a views StylePluginBase?

There are 2 fields: an image field and a link field in a node or rather in a view. I want the following rendered output: <div img src="..." longdesc="[here the uri from the link field]"> The ...
0
votes
0answers
13 views

How do I make common blocks appear?

On Drupal 8, I am using the Search API and the Views modules to show search results in page mode. However, I am not able to find a way to display the generic blocks like NAV and Footer on this page. ...
1
vote
0answers
25 views

Return more than one value from custom views field

I created custom views fields that calculate a percentage and number based on referencing nodes to current item. So of all 10 nodes 5 of them are referencing to this item. So output will be 50%, I ...
1
vote
1answer
37 views

How do I show a list of nodes referenced by a field?

I created two content types: News Agency and News. The News content type has the Headline, Title, Body, and News agency name (a reference to a News Agency node) fields. The News agency content type ...
0
votes
0answers
25 views

Using contextual filters with multiple taxonomies plus dynamic paths

I have a content type, FAQ, which has the Title, Body, and Related AP Course(s) fields. The last is a node reference field, where the target is a AP Exam node. I'd like to create a view page that ...
1
vote
1answer
16 views

How to add attachment in views slideshow

Goal: Putting text as an attachment on views slideshow Theme: Bootstrap Drupal: 8 Content type: Slideshow which has two fields: image and text Added two nodes of the content type. Created a ...
0
votes
1answer
33 views

Howdo I display all the images from a field in a view?

I'm trying to display multiple images from an image field in one view as an Owl Carousel, but I only see a maximum of 5 images to be displayed there. Googleing it, I found that there's an option ALL, ...
0
votes
1answer
64 views

How do I use a preprocess function to add custom classes to a view fields?

I have a View that outputs several fields per row. I'd like to use a preprocess function to add a class to one of the fields, depending on the value of another field. How do I do that in Drupal 8? ...
0
votes
1answer
46 views

How to create a redirect form?

I have a very important tag list (over 100k) (drupal 8). I'm using the default view of taxonomy. I need a form in my navbar that allows me to redirect to the different lists related to my tags ...