Files: 
CommentFileSizeAuthor
#21 drupal-viewsRename-add_orderby-2002272-21.patch13.68 KBheddn
PASSED: [[SimpleTest]]: [MySQL] 59,006 pass(es).
[ View ]
#21 interdiff.txt11.79 KBheddn
#17 2002272-17.patch12.14 KBjibran
FAILED: [[SimpleTest]]: [MySQL] 56,523 pass(es), 1 fail(s), and 0 exception(s).
[ View ]
#6 2002272-6-rename-add_order_by.patch12.12 KBelvis2
PASSED: [[SimpleTest]]: [MySQL] 55,745 pass(es).
[ View ]
#3 2002272-1-rename-add_order_by.patch12.11 KBelvis2
PASSED: [[SimpleTest]]: [MySQL] 55,899 pass(es).
[ View ]

Comments

Title:Rename Views method add_orderby(() to addOrderby()Rename Views method add_orderby() to addOrderby()

Fix issue title.

Assigned:Unassigned» elvis2

Status:Active» Needs review
StatusFileSize
new12.11 KB
PASSED: [[SimpleTest]]: [MySQL] 55,899 pass(es).
[ View ]

No documentation changes were required.

Status:Needs review» Reviewed & tested by the community

Looks ok to me

Status:Reviewed & tested by the community» Needs work

+++ b/core/modules/views/lib/Drupal/views/Plugin/views/query/Sql.phpundefined
@@ -992,7 +992,7 @@ function add_having_expression($group, $snippet, $args = array()) {
+  function addOrderby($table, $field = NULL, $order = 'ASC', $alias = '', $params = array()) {

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

Status:Needs work» Needs review
StatusFileSize
new12.12 KB
PASSED: [[SimpleTest]]: [MySQL] 55,745 pass(es).
[ View ]

@oenie, thanks!

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

The last submitted patch, 2002272-6-rename-add_order_by.patch, failed testing.

Status:Needs work» Needs review

#6: 2002272-6-rename-add_order_by.patch queued for re-testing.

Status:Needs review» Needs work

The last submitted patch, 2002272-6-rename-add_order_by.patch, failed testing.

Status:Needs work» Needs review

#6: 2002272-6-rename-add_order_by.patch queued for re-testing.

Status:Needs review» Needs work

The last submitted patch, 2002272-6-rename-add_order_by.patch, failed testing.

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

#6: 2002272-6-rename-add_order_by.patch queued for re-testing.

Status:Needs review» Reviewed & tested by the community

Looks good to me now
Except maybe from a very minor comment issue:
core/modules/views/lib/Drupal/views/Plugin/views/query/Sql.php, Line 997:

// @todo: Maybe it would make sense to just add a add_orderby_rand or something similar.

Thanks @oenie, I will ask the parent issue what do to about that.

Ordinarily I'd suggest we not make the change from #13 right now. The scope of this issue was to only rename methods. However, this feels like an exception. Go ahead and change the comment to camel case.

Status:Reviewed & tested by the community» Needs work

Needs a re-roll

curl http://drupal.org/files/2002272-6-rename-add_order_by.patch | git a
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 12411  100 12411    0     0  17634      0 --:--:-- --:--:-- --:--:-- 23640
error: patch failed: core/modules/views/lib/Drupal/views/Plugin/views/argument/ArgumentPluginBase.php:873
error: core/modules/views/lib/Drupal/views/Plugin/views/argument/ArgumentPluginBase.php: patch does not apply

And lets make the change suggested by #13 to fix up the comment.

Status:Needs work» Needs review
StatusFileSize
new12.14 KB
FAILED: [[SimpleTest]]: [MySQL] 56,523 pass(es), 1 fail(s), and 0 exception(s).
[ View ]

Reroll
conflict I

++<<<<<<< HEAD
+  public function summarySort($order, $by = NULL) {
+    $this->query->add_orderby(NULL, NULL, $order, (!empty($by) ? $by : $this->name_alias));
++=======
+   function summary_sort($order, $by = NULL) {
+     $this->query->addOrderby(NULL, NULL, $order, (!empty($by) ? $by : $this->name_alias));
++>>>>>>> 6

resolved
-  function summary_sort($order, $by = NULL) {
+  public function summarySort($order, $by = NULL) {
-     $this->query->add_orderby(NULL, NULL, $order, (!empty($by) ? $by : $this->name_alias));
+     $this->query->addOrderby(NULL, NULL, $order, (!empty($by) ? $by : $this->name_alias));

conflict II
++<<<<<<< HEAD
+        $menu_links = $this->query->addTable('menu_links', NULL, $join);
+        $this->query->add_orderby($menu_links, 'weight', $this->options['order']);
+        $this->query->add_orderby($menu_links, 'link_title', $this->options['order']);
++=======
+         $menu_links = $this->query->add_table('menu_links', NULL, $join);
+         $this->query->addOrderby($menu_links, 'weight', $this->options['order']);
+         $this->query->addOrderby($menu_links, 'link_title', $this->options['order']);
++>>>>>>> 6

resolved
-        $menu_links = $this->query->add_table('menu_links', NULL, $join);
+        $menu_links = $this->query->addTable('menu_links', NULL, $join);
-         $this->query->add_orderby($menu_links, 'weight', $this->options['order']);
-         $this->query->add_orderby($menu_links, 'link_title', $this->options['order']);
+         $this->query->addOrderby($menu_links, 'weight', $this->options['order']);
+         $this->query->addOrderby($menu_links, 'link_title', $this->options['order']);

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

The last submitted patch, 2002272-17.patch, failed testing.

Status:Needs work» Needs review

#17: 2002272-17.patch queued for re-testing.

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

The last submitted patch, 2002272-17.patch, failed testing.

StatusFileSize
new11.79 KB
new13.68 KB
PASSED: [[SimpleTest]]: [MySQL] 59,006 pass(es).
[ View ]

re-roll and fixing #13

Status:Needs work» Needs review

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

The last submitted patch, drupal-viewsRename-add_orderby-2002272-21.patch, failed testing.

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

Status:Needs review» Reviewed & tested by the community

Done thnx :)

Status:Reviewed & tested by the community» Fixed

Committed 9c5e4bc and pushed to 8.x. Thanks!

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