What functionality does this module provide that the viewfield module does not?

Comments

2pha created an issue. See original summary.

NewZeal’s picture

Looks like viewfield only has a select option and currently doesn't have provision for more advanced options. Otherwise they use the same principle.

2pha’s picture

Status: Active » Closed (works as designed)

Thanks for the reply.
I ended up going for this module and it has all the functionality that I need thanks.

colan’s picture

Category: Support request » Task
Status: Closed (works as designed) » Active

As done elsewhere, please add a Similar Modules section to the project page here, listing Viewfield, and an explanation such as the one above. Thanks! (Otherwise, folks need to dig through all of these issues to figure out the difference.)

Longer term, please consider #1299222: Merge the Views Reference Field and Viewfield modules as there seems to be a lot of overlap between the modules. Combining efforts would prevent work duplication. Please also add a link to this issue on the project page, wherever you mention the other module.

jasonawant’s picture

I recently want created #3094888: Requesting project co-maintainership and then came across this issue while looking at all 8.x-1.x issues.

Here's a comparison I've put together so far.

Viewsreference 8.x-1.x-dev features
a screenshot of Drupal viewsreference 1x version ui

  • Provides a custom field type
  • Field config options include:
    • Default option
    • Reference method: ? Is this provided by the EntityReferenceItem base field type
    • View display plugins to allow: configurable allowed/disallowed views plugins: master, block, page, etc. Note: this only displays options from among existing, already created, view displays.
    • Preselect View Options: provides option to restrict the views that can be selected when authoring content.
  • Field Widget
    • 1) Views Reference Autocomplete widget with standard config: Autocomplete matching: Contains, Textfield size, and placeholder
    • 2) Views Reference Select list widget without any config
    • DX: both widgets use trait for shared functionality
  • Field Formatter
  • Config options for label as expected
  • Config options for "View display plugins to allow", which seems redundant from the field config

Viewsreference 8.x-2.x-dev features:
TBD

Viewfield 8.x-3.x version features
a screenshot of Drupal viewfield 3x version ui

  • Field config options include:
    • Default option
    • Always use default value: Hides this field in entity edit forms and enforces the configured default value for all entities in the bundle, making it unnecessary to assign values individually to each one.
      If this is checked, you must provide a default value.
    • Allowed views
    • Allowed display types
  • Field Widget: None, provides one custom widget
  • Field Formatter options
    • Config options for label as expected
    • 1) Title and display name
    • 2) Viewfield
      • Title option: Option to render the view display title.
      • Always build output option: Produce renderable output even if the view produces no results.
        This option may be useful for some specialized cases, e.g., to force rendering of an attachment display even if there are no view results. Includes additional config to render Empty view title.
jasonawant’s picture

StatusFileSize
new68.25 KB
new112.01 KB
colan’s picture

Title: How different from Viewfield module » Compare with other views-embedding modules
Version: 8.x-1.x-dev » 8.x-2.x-dev
Status: Active » Needs work

I added #5 to the new comparison page in the docs.

Now we need to add 2.x information there, and then link to it from the project page. I believe 1.x is no longer supported.

seanb’s picture

Status: Needs work » Fixed

Added a link to the documentation page on the project homepage. Thanks for starting this, it looks great!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.