Module Description
πŸ‡ΊπŸ‡¦ This module is maintained by Ukrainian developers. Please consider supporting Ukraine in a fight for their freedom and safety of Europe. INTRODUCTION You can create comparison pages from a selected entity's bundle with this module. Your users can add and remove entities to this list, and they can see only their list.

CREATE ENTITY COMPARISON After installing the module, you can create, edit or delete entity comparisons on the following uri: /admin/structure/entity_comparison (Structure -> Entity comparison)

When you create entity comparison, you have to set the following fields:


* Label and machine name
* Text for the link "Add to comparison list"
* Text for the link to "Remove from the comparison"
* The limit on the number of compared items ("0" - no limit)
* Entity
* Bundle

You can select any content entity's any bundle.

After you created an entity comparison configuration entity, you should clear all cache.

The following things will be generated:


* A view mode for the related bundle
* A "Link for the entity comparison" field, which type is Entity comparison link.
* A block which contains a link for the comparison page
* A permission which allows users to use the created comparison function

PLACE THE LINK You can view the newly generated Link for the entity comparison on the selected bundle's view modes.

So you can place it where you want on which view mode you want (for example: Default, Teaser, Full content). If a content is not in the comparison list, the field will shows a link with the text, you added on the entity comparison settings (default: Add to comparison list).

If a content is in the comparison list, the field will shows a link with the remove text, you added on the entity comparison settings (default: Remove from the comparison).

SET THE SORT OF THE FIELDS A view mode with the identical name is generated after you save the entity comparison configuration entity. In this view mode, you can set which fields will be shown, the sort of the fields, and the field formatters of the fields.

PLACE THE BLOCK A block with the identical name is generated after you save the entity comparison configuration entity. It's output is a link to the comparison page. It shows also the item numbers of the comparison list.

SET THE PERMISSIONS Permissions are generated dynamically. When you create a new entity comparison a permission is generated like this:

[LABEL]: Use entity comparison

[LABEL] is replaced with the label of the entity comparison of course.

Project Usage
300
Creation Date
Changed Date
Security Covered
Covered By Security Advisory
Version Available
Production
Module Summary
This module aims to solve the creation of comparison pages for selected entities with the ability for users to add and remove entities to their list, while also providing the necessary configurations for labels, limits, and permissions.
Data Name
entity_comparison

OPENAI CHATBOT

OPENAI CHATBOT

12:24:29
Generic Chatbot
Hi, I'm a Drupal module expert powered by OpenAI, answering your questions about the Drupal module ecosystem. How can I be helpful today? Please note that we will log your question.