Category_Edit implements Registerable, Standard_Service

Handles fields and data on the Product Category Add/Edit screen

Tags
author

Barn2 Plugins support@barn2.com

license

GPL-3.0

copyright

Barn2 Media Ltd

Interfaces, Classes and Traits

Registerable
Standard_Service

Table of Contents

add_hide_prices_select_field()  : mixed
Add hide price control field (WooCommerce Protected Categories) to 'Add product category' screen.
add_role_pricing_field()  : mixed
Add role pricing field to 'add product category' screen
add_visiblity_control_field()  : mixed
Add visibility control field (WooCommerce Protected Categories) to 'Add product category' screen.
add_wholesale_visibility_field()  : mixed
Add visibility field to 'add product category' screen
cat_table_visibility_column()  : string
Adds the value to our visiblity column if Protected Categories isn't used.
cat_table_visibility_column_heading()  : array<string|int, mixed>
Adds the visiblity column heading if Protected Categories is not active
edit_hide_prices_select_field()  : mixed
Add hide price control field (WooCommerce Protected Categories) to 'Edit product category' screen.
edit_role_pricing_field()  : mixed
Add role pricing field to 'edit product category' screen
edit_visiblity_control_field()  : mixed
Add visibility control field (WooCommerce Protected Categories) to 'Edit product category' screen.
edit_wholesale_visiblity_field()  : mixed
Add visibility field to 'edit product category' screen
register()  : mixed
{@inheritdoc}
save_hide_prices_field()  : mixed
Save visibility field
save_role_discounts()  : mixed
Save wholesale discounts
save_visibility_control_field()  : mixed
Save visibility control (WooCommerce Protected Categories) integration
save_visibility_field()  : mixed
Save visibility field
display_hide_prices_select()  : mixed
Display Visiblity Radio Buttons
display_role_discount_group()  : mixed
Display Role Discount Inputs
display_visibility_control()  : mixed
Display Radio Buttons for WooCommerce Protected Categories Integration
display_visibility_group()  : mixed
Display Visiblity Radio Buttons
list_table_insert_after_column()  : array<string|int, mixed>
Inserts a value into the columns array at a specified position

Methods

add_hide_prices_select_field()

Add hide price control field (WooCommerce Protected Categories) to 'Add product category' screen.

public add_hide_prices_select_field() : mixed
Tags
Return values
mixed

add_role_pricing_field()

Add role pricing field to 'add product category' screen

public add_role_pricing_field() : mixed
Tags
Return values
mixed

add_visiblity_control_field()

Add visibility control field (WooCommerce Protected Categories) to 'Add product category' screen.

public add_visiblity_control_field() : mixed
Tags
Return values
mixed

add_wholesale_visibility_field()

Add visibility field to 'add product category' screen

public add_wholesale_visibility_field() : mixed
Tags
Return values
mixed

cat_table_visibility_column()

Adds the value to our visiblity column if Protected Categories isn't used.

public cat_table_visibility_column(string $output, string $column, int $term_id) : string
Parameters
$output : string
$column : string
$term_id : int
Tags
Return values
string

$output

cat_table_visibility_column_heading()

Adds the visiblity column heading if Protected Categories is not active

public cat_table_visibility_column_heading(array<string|int, mixed> $columns) : array<string|int, mixed>
Parameters
$columns : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>

$columns

edit_hide_prices_select_field()

Add hide price control field (WooCommerce Protected Categories) to 'Edit product category' screen.

public edit_hide_prices_select_field(WP_Term $term) : mixed
Parameters
$term : WP_Term
Tags
Return values
mixed

edit_role_pricing_field()

Add role pricing field to 'edit product category' screen

public edit_role_pricing_field(mixed $term) : mixed
Parameters
$term : mixed

The product category being edited

Tags
Return values
mixed

edit_visiblity_control_field()

Add visibility control field (WooCommerce Protected Categories) to 'Edit product category' screen.

public edit_visiblity_control_field(WP_Term $term) : mixed
Parameters
$term : WP_Term
Tags
Return values
mixed

edit_wholesale_visiblity_field()

Add visibility field to 'edit product category' screen

public edit_wholesale_visiblity_field(mixed $term) : mixed
Parameters
$term : mixed

The product category being edited

Tags
Return values
mixed

register()

{@inheritdoc}

public register() : mixed
Tags
Return values
mixed

save_hide_prices_field()

Save visibility field

public save_hide_prices_field(mixed $term_id[, mixed $tt_id = '' ]) : mixed
Parameters
$term_id : mixed

Term ID being saved

$tt_id : mixed = ''

The term taxonomy ID

Tags
Return values
mixed

save_role_discounts()

Save wholesale discounts

public save_role_discounts(mixed $term_id[, mixed $tt_id = '' ]) : mixed
Parameters
$term_id : mixed

Term ID being saved

$tt_id : mixed = ''

The term taxonomy ID

Tags
Return values
mixed

save_visibility_control_field()

Save visibility control (WooCommerce Protected Categories) integration

public save_visibility_control_field(mixed $term_id[, mixed $tt_id = '' ]) : mixed
Parameters
$term_id : mixed

Term ID being saved

$tt_id : mixed = ''

The term taxonomy ID

Tags
Return values
mixed

save_visibility_field()

Save visibility field

public save_visibility_field(mixed $term_id[, mixed $tt_id = '' ]) : mixed
Parameters
$term_id : mixed

Term ID being saved

$tt_id : mixed = ''

The term taxonomy ID

Tags
Return values
mixed

display_hide_prices_select()

Display Visiblity Radio Buttons

private display_hide_prices_select([mixed $term_id = false ]) : mixed
Parameters
$term_id : mixed = false
Tags
Return values
mixed

display_role_discount_group()

Display Role Discount Inputs

private display_role_discount_group([mixed $term_id = false ]) : mixed
Parameters
$term_id : mixed = false
Tags
Return values
mixed

display_visibility_control()

Display Radio Buttons for WooCommerce Protected Categories Integration

private display_visibility_control([mixed $term_id = false ]) : mixed
Parameters
$term_id : mixed = false
Tags
Return values
mixed

display_visibility_group()

Display Visiblity Radio Buttons

private display_visibility_group([mixed $term_id = false ]) : mixed
Parameters
$term_id : mixed = false
Tags
Return values
mixed

list_table_insert_after_column()

Inserts a value into the columns array at a specified position

private list_table_insert_after_column(array<string|int, mixed> $columns, string $after_key, string $insert_key, string $insert_value) : array<string|int, mixed>
Parameters
$columns : array<string|int, mixed>
$after_key : string
$insert_key : string
$insert_value : string
Tags
Return values
array<string|int, mixed>

$new_columns

Search results