Skip to main content
OverflowAI is here! AI power for your Stack Overflow for Teams knowledge community. Learn more

Questions tagged [views]

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

Filter by
Sorted by
Tagged with
0 votes
1 answer
590 views

Views Bulk Operations with Field Collection Item tokens

I am trying to modify the values of one field in all instances of a field collection type. I have a view listing all field collection items, that I want and an operation field with modify entity. ...
2 votes
1 answer
974 views

Views PDF CSS file not being applied on generated PDF

I've created a pdf display with views_pdf module in views, and under the PDF SETTINGS i've included a CSS File (eg. sites/all/themes/custom/mytheme/css/mytheme.css). When viewing the page display of ...
1 vote
2 answers
2k views

print field in views row template

I try to make a custom view using templates. I need to print one certain field at the last row, after all other fields have been printed like so: --1st row field1 field2 --2nd row field1a field2a --...
0 votes
0 answers
9 views

in view path, can I replace tid with token:name

What I have, the view path bild the path with token id's. such like: excample.com/view?token=555 maybe with [node:field_token:entity:name] or {{ node:field_token:entity:name }} ? with ...
1 vote
1 answer
668 views

Adding two contextual filters (Content : nid)

I want to display two type of contents : News and Events. So I added them in the filters criteria. This works great. Now I want them to be further filtered on the basis of the category the News and ...
1 vote
1 answer
2k views

Entity Reference View Widget problem with add selective

I am using a content type which uses a field as "Views" Entity Reference View Widget. When I click "add selective" or "add .. and close" in form of this widget, it's just redirect to http://localhost/...
2 votes
2 answers
2k views

Theming a views field output using views-view-fields.html.twig

I am trying to customize a views output on a view page to wrap the fields in custom markup. I need to group a set of fields to achieve the desired layout like so: Example: <div class="wrapper"&...
0 votes
1 answer
509 views

Why is my view for Solr indexing is not showing any results?

I have installed solr 8.2.0 for drupal 8.7.6. My Solr server and index are enabled and indexed. But when try to search via views, the results are not showing up. Please help me in solving this. My ...
0 votes
1 answer
2k views

Printing views exposed sort criteria separately to exposed filters

Exposed filters are either: - Printed in views-view.tpl.php using the $exposed variable. - Printed in a block, probably using the same variable. This variable ($exposed) contains the exposed sort ...
0 votes
0 answers
13 views

How to create a view with filters using data from an api?

We have a multisite setup and need to share taxonomy data from one site to all of the other sites. I have created a REST Export view on the site that has the taxonomy data. The next thing I've done is ...
-1 votes
0 answers
11 views

sort by relevance in search api index views

When adding an exposed sort by relevance in a search api view index : The select option has only the option "sort by relevance". What is the use of that exposed sort then ? Should there not ...
3 votes
1 answer
435 views

Taxonomy Term Hierarchy(not programmatically nor content related)

I know there are zillion topics about this, but I just couldn't apply it to my View Block in Drupal 8. On the other hand all these Taxonomy Term Tree creation is based on content related. Here is ...
1 vote
0 answers
10 views

How add a "Raw value" field on views?

I'm on Drupal 10.2.x and editing the view content. I'm using the contrib module views_cm_current_state. The module implements hook_views_data() to add, for what I understand, a new field. The field ...
1 vote
1 answer
390 views

views_query_alter Matching all values in IN clause

I have a content type with a list(text) field. In which the admin can set multiple values on the field for the content type. Using a view the information is exposed to the end user. The views has a ...
0 votes
1 answer
537 views

How to display the form submission results in a custom page?

How to display the form submission results in a custom page or a view ? I want to display it in a custom style with table , and want to do custom php coding too . where i have to create custom page ...
0 votes
2 answers
652 views

Get parent Paragraph Entity from Referenced View

I have a custom paragraph type - which has 2 fields: Display Mode, View to be rendered I want to let users choose Display Mode in this paragraph, then I will render view dynamically based on this ...
1 vote
1 answer
862 views

How to format the raw date formats when using Google Analytic Reports?

I am using Google Chart Tools, Views, and Google Analytic Reports to create charts for an admin dashboard. However the date format (Time Dimensions: ga:date) outputs the date in the YYYYMMDD format. ...
0 votes
1 answer
1k views

How to filter entities in View by all of their taxonomy term reference fields?

Let's say I have a custom entity that has two taxonomy reference fields: categories and tags. And I want to display all entities that have taxonomy term with id 1. The term is a dynamic value(...
1 vote
1 answer
453 views

Views with tables have different column width with same setting

I'm having problems with drupal views. I used a table to make a list of items with an image, a title and a body each. The first time I tried it it worked perfectly, each column only taking the ...
1 vote
3 answers
2k views

How do I use a "contains" operation as restful contextual filter for text fields

I'm trying to create a restful view which takes a string as input, search specific content-type titles for similar nodes and return them as result. The problem is I can't figure out how to configure ...
5 votes
4 answers
19k views

How do I implement hook_views_query_alter()?

I try to implement hook_views_query_alter() in Drupal 8. I found a hint, that it has to be in my_module.views_execution.inc. I tried it, but the hook never gets called. function ...
1 vote
1 answer
755 views

Update commerce cart block when product added through ajax

Hii How can I update commerce_cart_block when my product is added through ajax. Any suggestion will be helpfull.
1 vote
1 answer
454 views

Views: attachment inherits exposed filters when set to No

I created a page with an attachment to it. Its a Glossary for the Username. And here is my attachment setting: i Have exposed filters on the page where it is attached to: And the Filters works ...
0 votes
1 answer
394 views

Scroll to view's result after applying exposed filter

when a user submit the view's exposed form the site is reloaded and the page's focus is not on the view's results but on the very top of the page. I use quite a few exposed filters above a table view. ...
0 votes
2 answers
2k views

How do I add a template suggestion for a Views block?

I am very much so new to Drupal and have moved to this platform after working with Magento for 5 years. I am trying to create a template for a view. I have created the twig template under /templates/...
1 vote
1 answer
32 views

Counting by rewritten element

In my view, I'd like to group my row by values. The initial data look like this. In the field configuration in the view, I rewrite each value like this {{ field__value |split('-')[2] }} to get only ...
0 votes
1 answer
482 views

How can I set only a view of two views added to a panel to be shown as accordion?

I have a panel page which contains 2 views. I only want a single view to display as accordion. If I set the style setting of that view to Accordion, nothing happens; if I set the style setting of the ...
1 vote
1 answer
519 views

#states on exposed filter form

I have a #states on the exposed filter form as follow: If field_a == 'b' then field_b show, field_c hidden; else if field_a == 'c' then field_c show, field_b hidden; All fields here are Select ...
3 votes
3 answers
1k views

View inside display suite block field - contextual filter

using display suite's block field, which i chose a view block.. so when i have view page ('parent' view) it list many nodes. each node has a field for block view ('child' view). how do i get child ...
0 votes
1 answer
2k views

Pre-populate an Entity Reference when Adding a Node : Based on URL Alias

I am trying to pre-populate an entity reference with a specific game node, when a profile node is added; based on URL of the game the add button is on. The game node I want to reference in profile ...
1 vote
1 answer
436 views

trigger colorbox on view page load

What if I just want to trigger the first colorbox on a view page? maybe with js injector module. Drupal.behaviors.commerce_kickstart_theme_custom_mytest = { attach: function(context, settings) { ...
1 vote
1 answer
147 views

Seller and Buyers Own Comments (Commerce Communicae)

I would like to have a way for my seller/author (author of node) and my buyer/user (not author of node) to communicate. First, I have looked at the comments. If I allowed buyers to only start one ...
3 votes
1 answer
707 views

Accessing content for a specific node revision via a relationship in Views

A module I've written implements hooks defined by the Field API to provide a custom field for defining references to specific node revisions by storing vids. (The module borrows functionality from the ...
0 votes
1 answer
399 views

Long Ajax error using Date module Views and Fullcalendar

I have searched for many posts and i am already doing the suggestions. Nothing is fixing this. Fullcalendar module says to use the "use ajax" option within views but it throws a huge error. ...
0 votes
2 answers
458 views

Taxonomy filter exposed to user that dynamically only includes terms attached to currently published content

Background: a) Taxonomy: I have built as site that allows users to tag content of a particular content type with tags. The system started with a pre-existing taxonomy before any content was added, ...
4 votes
2 answers
1k views

Display a grid view without border columns

I'm trying to display a specific number of products in a e-commerce drupal site in the front page. I would like to use a display as in my theme's demo : http://demo.morethanthemes.com/tophit/ I ...
1 vote
1 answer
1k views

Display parent term based on child term in views

I have a vocabulary with the following structure: Vocabulary Parent term 1 Child term 1.1 Child term 1.1.1 Child term 1.2 Child term 1.2.1 Parent term 2 Child term 2.1 ...
0 votes
1 answer
556 views

How to expose an entity reference field as a filter on a custom entity in Views?

I have a field on a custom entity that is an entity reference to a node. However when I select this field as a filter and expose it, it just acts like a numeric field instead of a reference field (...
2 votes
2 answers
993 views

Show custom banner per page

Admin user wants to be able to upload image banners and select on which pages/nodes/views/panels to show it when visited (as a wide screen image banner above title). It means when creating the banner ...
1 vote
1 answer
454 views

how to use tokens as “views filter criteria” for a custom table?

I created view for fields from a custom table using handlers. I need to create a filter so that only the users who created the data can see the data. how can I create the filter?
2 votes
1 answer
1k views

Filter a view based on current user's roles

I'm using a view to populate an Entity reference field on a profile. (So it's a view of "Entity Reference" display type.) I want to filter this view to show (and allow users to select) only: ...
3 votes
1 answer
2k views

Custom Views Sort Order Using Filter Value

I have a View containing a list of events. There is a date field on the event content type which contains start and end time: There is a filter for start time, which is setup using the Views ...
1 vote
1 answer
390 views

Couldn't avoid duplicates and merge rows on my views

I have a view of list of contents referenced in many others content types in my site. Lets talk about just 2 content types : A content type called container is referenced in a content type position, ...
2 votes
1 answer
5k views

Change field value with hook_views_pre_render()

I'm using Views in 8.4.0 and attempting to change the output of a field value with hook_views_pre_render(). The default value of the field is a node ID. The intent is to replaced the value with a ...
0 votes
2 answers
868 views

Querystring in Views ajax_view.js

I'm using Views 7.x-3.11 with Better Exposed Filters and Ajax auto-submit in a panels page, and running into some issues that seem to be stemming from code in Views/js/ajax_view.js. I want to make the ...
0 votes
1 answer
1k views

Alter views contextual filter field

I have two content types, Brand and Sector. Brand have a sector field which is an Entity reference field. I have views that display the list of Brands and it has a sector contextual filter which ...
2 votes
1 answer
1k views

How to resolve lazy_builder error?

We have a field that is an Entity Reference to Blocks. In our situation, this field is referencing a View block. We are able to add this field on the content type and node properly, but when the page ...
0 votes
1 answer
612 views

Group date field by day for chart

I have a custom database table with a datetime column that I have made accessible to Views. I want to create a line charts of number of rows per day but I can't get the View right. With aggregation ...
0 votes
1 answer
1k views

alter query view by adding fields in an andGroup within an orGroup

I have a multilanguage site with two languages: English and Dutch. Not all nodes are created in both languages. Some nodes even have no language ('und', 'zxx'). I want the default Drupal provided ...
0 votes
1 answer
555 views

Using Twig in global custom text to check for a specific content type

I am filtering for two content types to display in a view: Artwork Page and Cover Page. I want to change the HTML markup for Cover Page. I have researched and tried many field names for Content Type, ...

1
2 3 4 5
304