Merge pull request #10012 from frozzare/docs/admin-walkers

Improve docblock comments Walker classes
This commit is contained in:
Mike Jolley 2016-01-07 10:46:26 +00:00
commit c5c709ed62
2 changed files with 42 additions and 2 deletions

View File

@ -17,10 +17,27 @@ if ( ! class_exists( 'WC_Product_Cat_Dropdown_Walker' ) ) :
class WC_Product_Cat_Dropdown_Walker extends Walker {
/**
* What the class handles.
*
* @var string
*/
public $tree_type = 'category';
public $db_fields = array ('parent' => 'parent', 'id' => 'term_id', 'slug' => 'slug' );
/**
* DB fields to use.
*
* @var array
*/
public $db_fields = array(
'parent' => 'parent',
'id' => 'term_id',
'slug' => 'slug'
);
/**
* Starts the list before the elements are added.
*
* @see Walker::start_el()
* @since 2.1.0
*

View File

@ -17,10 +17,27 @@ if ( ! class_exists( 'WC_Product_Cat_List_Walker' ) ) :
class WC_Product_Cat_List_Walker extends Walker {
/**
* What the class handles.
*
* @var string
*/
public $tree_type = 'product_cat';
public $db_fields = array ( 'parent' => 'parent', 'id' => 'term_id', 'slug' => 'slug' );
/**
* DB fields to use.
*
* @var array
*/
public $db_fields = array(
'parent' => 'parent',
'id' => 'term_id',
'slug' => 'slug'
);
/**
* Starts the list before the elements are added.
*
* @see Walker::start_lvl()
* @since 2.1.0
*
@ -37,6 +54,8 @@ class WC_Product_Cat_List_Walker extends Walker {
}
/**
* Ends the list of after the elements are added.
*
* @see Walker::end_lvl()
* @since 2.1.0
*
@ -53,6 +72,8 @@ class WC_Product_Cat_List_Walker extends Walker {
}
/**
* Start the element output.
*
* @see Walker::start_el()
* @since 2.1.0
*
@ -83,6 +104,8 @@ class WC_Product_Cat_List_Walker extends Walker {
}
/**
* Ends the element output, if needed.
*
* @see Walker::end_el()
* @since 2.1.0
*