Updated: Comment #0

Problem/Motivation

Noticed while reviewing #2006606: Views rendering ignores entity language, eg: Identical nodes rendered in views when nodes have translations, looking at query().

In core/modules/views/lib/Drupal/views/Plugin/views/row/RowPluginBase.php
missing doc blocks for query() and defineOptions()

Proposed resolution

Add missing docs.
See https://drupal.org/node/1354

Remaining tasks

Should we fix other docs that are not standard like one line summaries, and listing @params? (forms)?

User interface changes

None.

API changes

None.

Comments

tim bozeman’s picture

Assigned: Unassigned » tim bozeman

:D

tim bozeman’s picture

Assigned: tim bozeman » Unassigned
Status: Active » Needs review
StatusFileSize
new971 bytes

I looked at some other doc blocks for definedOptions() and most of them had {@inheritdoc} so I added that and * Add this relationship to the query. for query().

dawehner’s picture

+++ b/core/modules/views/lib/Drupal/views/Plugin/views/row/RowPluginBase.php
@@ -117,6 +119,9 @@ public function validateOptionsForm(&$form, &$form_state) { }
+   * Add this relationship to the query.

This comment seems to be c&p

tim bozeman’s picture

StatusFileSize
new949 bytes

We checked the pluginBase class and both defineOptions() and query() have the same params and returns so this patch sets the docblock to @inheritdoc.

Status: Needs review » Needs work

The last submitted patch, 4: RowPluginBase_docblock-2160797-4.patch, failed testing.

tim bozeman’s picture

The test failed on Drupal\user\Tests\UserCreateFailMailTest->testUserAdd() on line 35 of UserCreateFailMailTest.php. I suspect it's a random fail.

tim bozeman’s picture

Status: Needs work » Needs review
dawehner’s picture

Status: Needs review » Reviewed & tested by the community

Thank you.

jhodgdon’s picture

Status: Reviewed & tested by the community » Fixed

Thanks all! Committed to 8.x.

Status: Fixed » Closed (fixed)

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