Ticket #29881: 29881.3.diff
File 29881.3.diff, 6.5 KB (added by , 9 years ago) |
---|
-
wp-admin/includes/class-wp-list-table.php
diff --git a/wp-admin/includes/class-wp-list-table.php b/wp-admin/includes/class-wp-list-table.php index 74a8b00..56b98a8 100644
a b class WP_List_Table { 1145 1145 echo '<th scope="row" class="check-column">'; 1146 1146 echo $this->column_cb( $item ); 1147 1147 echo '</th>'; 1148 } 1149 elseif ( method_exists( $this, 'column_' . $column_name ) ) { 1150 echo "<td $attributes>"; 1151 echo call_user_func( array( $this, 'column_' . $column_name ), $item ); 1152 echo $this->handle_row_actions( $item, $column_name, $primary ); 1153 echo "</td>"; 1148 } 1149 elseif ( method_exists( $this, 'single_row_column_' . $column_name ) ) { 1150 call_user_func( array( $this, 'single_row_column_' . $column_name ), $item, $classes ); 1154 1151 } 1155 1152 else { 1156 1153 echo "<td $attributes>"; 1157 echo $this->column_default( $item, $column_name ); 1154 1155 if ( method_exists( $this, 'column_' . $column_name ) ) { 1156 call_user_func( array( $this, 'column_' . $column_name ), $item ); 1157 } else { 1158 $this->column_default( $item, $column_name ); 1159 } 1160 1158 1161 echo $this->handle_row_actions( $item, $column_name, $primary ); 1159 1162 echo "</td>"; 1160 1163 } -
wp-admin/includes/class-wp-ms-sites-list-table.php
diff --git a/wp-admin/includes/class-wp-ms-sites-list-table.php b/wp-admin/includes/class-wp-ms-sites-list-table.php index 29e3e6e..460d87b 100644
a b class WP_MS_Sites_List_Table extends WP_List_Table { 388 388 /** 389 389 * @since 4.3.0 390 390 * 391 * @param array $item 391 * @param array $item 392 * @param string $classes 392 393 */ 393 public function single_row_columns( $item ) { 394 list( $columns, $hidden, $sortable, $primary ) = $this->get_column_info(); 395 396 foreach ( $columns as $column_name => $column_display_name ) { 397 $classes = "$column_name column-$column_name"; 398 if ( $primary === $column_name ) { 399 $classes .= ' has-row-actions column-primary'; 400 } 401 402 if ( in_array( $column_name, $hidden ) ) { 403 $classes .= ' hidden'; 404 } 405 406 $attributes = "class='$classes'"; 407 408 if ( 'cb' === $column_name ) { 409 echo '<th scope="row" class="check-column">'; 410 411 $this->column_cb( $item ); 412 413 echo '</th>'; 414 } elseif ( 'id' === $column_name ) { 415 ?> 416 <th scope="row"> 417 <?php echo $item['blog_id'] ?> 418 </th> 419 <?php 420 } elseif ( method_exists( $this, 'column_' . $column_name ) ) { 421 echo "<td $attributes>"; 422 423 echo call_user_func( array( $this, 'column_' . $column_name ), $item ); 424 425 echo $this->handle_row_actions( $item, $column_name, $primary ); 426 echo "</td>"; 427 } else { 428 echo "<td $attributes>"; 429 430 echo $this->column_default( $item, $column_name ); 431 432 echo $this->handle_row_actions( $item, $column_name, $primary ); 433 echo "</td>"; 434 } 435 } 394 public function single_row_column_id( $item, $classes ) { 395 echo '<th scope="row">'; 396 echo $item['blog_id']; 397 echo '</th>'; 436 398 } 437 399 438 400 /** -
wp-admin/includes/class-wp-ms-users-list-table.php
diff --git a/wp-admin/includes/class-wp-ms-users-list-table.php b/wp-admin/includes/class-wp-ms-users-list-table.php index df5fb66..3422d27 100644
a b class WP_MS_Users_List_Table extends WP_List_Table { 318 318 * @since 4.3.0 319 319 * 320 320 * @param object $item 321 * @param string $classes 321 322 */ 322 public function single_row_columns( $item ) { 323 list( $columns, $hidden, $sortable, $primary ) = $this->get_column_info(); 324 325 foreach ( $columns as $column_name => $column_display_name ) { 326 $classes = "$column_name column-$column_name"; 327 if ( $primary === $column_name || 'blogs' === $column_name ) { 328 $classes .= ' has-row-actions'; 329 } 330 331 if ( $primary === $column_name ) { 332 $classes .= ' column-primary'; 333 } 334 335 if ( in_array( $column_name, $hidden ) ) { 336 $classes .= ' hidden'; 337 } 338 339 $attributes = "class='$classes'"; 340 341 if ( 'cb' === $column_name ) { 342 echo '<th scope="row" class="check-column">'; 343 344 $this->column_cb( $item ); 345 346 echo '</th>'; 347 } elseif ( method_exists( $this, 'column_' . $column_name ) ) { 348 echo "<td $attributes>"; 349 350 call_user_func( array( $this, 'column_' . $column_name ), $item ); 351 352 echo $this->handle_row_actions( $item, $column_name, $primary ); 353 echo "</td>"; 354 } else { 355 echo "<td $attributes>"; 356 357 $this->column_default( $item, $column_name ); 358 359 echo $this->handle_row_actions( $item, $column_name, $primary ); 360 echo "</td>"; 361 } 362 } 323 public function single_row_column_blogs( $item, $classes ) { 324 echo '<td class="' . $classes . ' has-row-actions">'; 325 echo $this->column_blogs( $item ); 326 echo $this->handle_row_actions( $item, 'blogs', 'username' ); 327 echo '</td>'; 363 328 } 364 329 365 330 public function display_rows() { -
wp-admin/includes/class-wp-posts-list-table.php
diff --git a/wp-admin/includes/class-wp-posts-list-table.php b/wp-admin/includes/class-wp-posts-list-table.php index 6897ce6..8b3004c 100644
a b class WP_Posts_List_Table extends WP_List_Table { 955 955 * @since 4.3.0 956 956 * 957 957 * @param WP_Post $item 958 * @param string $classes 958 959 */ 959 public function single_row_columns( $item ) { 960 list( $columns, $hidden, $sortable, $primary ) = $this->get_column_info(); 961 962 foreach ( $columns as $column_name => $column_display_name ) { 963 $classes = "$column_name column-$column_name"; 964 if ( $primary === $column_name ) { 965 $classes .= ' has-row-actions column-primary'; 966 } 967 968 if ( 'title' === $column_name ) { 969 $classes .= ' page-title'; // Special addition for title column 970 } 971 972 if ( in_array( $column_name, $hidden ) ) { 973 $classes .= ' hidden'; 974 } 975 976 $attributes = "class='$classes'"; 977 978 if ( 'cb' === $column_name ) { 979 echo '<th scope="row" class="check-column">'; 980 981 $this->column_cb( $item ); 982 983 echo '</th>'; 984 } else { 985 echo "<td $attributes>"; 986 987 if ( method_exists( $this, 'column_' . $column_name ) ) { 988 call_user_func( array( $this, 'column_' . $column_name ), $item ); 989 } else { 990 $this->column_default( $item, $column_name ); 991 } 992 993 echo $this->handle_row_actions( $item, $column_name, $primary ); 994 echo '</td>'; 995 } 996 } 960 public function single_row_column_title( $item, $classes ) { 961 echo '<td class="' . $classes . ' page-title">'; 962 echo $this->column_title( $item ); 963 echo $this->handle_row_actions( $item, 'title', 'title' ); 964 echo '</td>'; 997 965 } 998 966 999 967 /**