Files: 
CommentFileSizeAuthor
#13 views-2002270-remove-add_having-13.patch2.3 KBvito_a
PASSED: [[SimpleTest]]: [MySQL] 56,079 pass(es).
[ View ]
#7 views-2002270-addHaving-7.patch1.11 KBzschmid
PASSED: [[SimpleTest]]: [MySQL] 57,284 pass(es).
[ View ]
#2 views-2002270-addHaving.patch737 bytesphenaproxima
FAILED: [[SimpleTest]]: [MySQL] 55,820 pass(es), 1 fail(s), and 0 exception(s).
[ View ]

Comments

Assigned:Unassigned» phenaproxima

Assigned:phenaproxima» Unassigned
Status:Active» Needs review
StatusFileSize
new737 bytes
FAILED: [[SimpleTest]]: [MySQL] 55,820 pass(es), 1 fail(s), and 0 exception(s).
[ View ]

Status:Needs review» Reviewed & tested by the community

Ran successful test creating a new view.

Status:Reviewed & tested by the community» Needs work
Issue tags:-Novice, -VDC

The last submitted patch, views-2002270-addHaving.patch, failed testing.

Status:Needs work» Needs review
Issue tags:+Novice, +VDC

#2: views-2002270-addHaving.patch queued for re-testing.

Status:Needs review» Needs work

+++ b/core/modules/views/lib/Drupal/views/Plugin/views/query/Sql.phpundefined
@@ -915,7 +915,7 @@ function add_where_expression($group, $snippet, $args = array()) {
+  function addHaving($group, $field, $value = NULL, $operator = NULL) {

Add public access modifier in front of the function to adher to the new OOP standards.

Status:Needs work» Needs review
StatusFileSize
new1.11 KB
PASSED: [[SimpleTest]]: [MySQL] 57,284 pass(es).
[ View ]

adding public access modifier

Status:Needs review» Reviewed & tested by the community

Looks fine to me now !

Status:Reviewed & tested by the community» Needs review

This function does not seem to be called anywhere... is it needed?

Yes that's true there is no place currently in core which calls this function.

To be honest I can't think of a usecase of a having expression without using a snippet (like addHavingExpression() allows you)
as you always need an aggregation function. I would go with dropping support for it.

Title:Rename Views method add_having() to addHaving()Remove views method add_having()
Status:Needs review» Needs work

:)

Assigned:Unassigned» vito_a

Assigned:vito_a» Unassigned
Status:Needs work» Needs review
Issue tags:+CodeSprintUA
StatusFileSize
new2.3 KB
PASSED: [[SimpleTest]]: [MySQL] 56,079 pass(es).
[ View ]

removing it

Status:Needs review» Reviewed & tested by the community

If we really see that someone is using it we can readd it. This will not break any api in the future.

Title:Remove views method add_having()Change notice: Remove views method add_having()
Project:Drupal core» Views
Version:8.x-dev» 8.x-3.x-dev
Component:views.module» Code
Status:Reviewed & tested by the community» Active
Issue tags:+Needs change record

Committed and pushed to 8.x. Thanks!

Moving to Views for the change notice.

Title:Change notice: Remove views method add_having()Remove views method add_having()
Project:Views» Drupal core
Version:8.x-3.x-dev» 8.x-dev
Component:Code» views.module
Status:Active» Fixed
Issue tags:-Needs change record

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