Files
wp-graphql-woocommerce/includes/admin/class-general.php
T
Geoffrey K TaylorandGitHub f4b153f147 feat: Docs Restored. Unsupported product type setting implemented. (#731)
* feat: docs started. Unsupported product type implemented.

* chore: WPCS compliance met

* chore: file renamed.

* feat: More docs written

* feat: 2 more docs written

* fix: settings docs images added.

* fix: settings docs images added.

* devops: UnsupportProductTypeTest added.

* devops: More docs changes.

* chore: WPCS compliance met

* devops: UnsupportedProductTypeTest updated.

* chore: WPCS compliance met
2023-04-18 23:48:08 -04:00

39 lines
1.0 KiB
PHP

<?php
/**
* Defines WooGraphQL's general settings.
*
* @package WPGraphQL\WooCommerce\Admin
*/
namespace WPGraphQL\WooCommerce\Admin;
/**
* General class
*/
class General extends Section {
/**
* Returns General settings fields.
*
* @return array
*/
public static function get_fields() {
return [
[
'name' => 'disable_ql_session_handler',
'label' => __( 'Disable QL Session Handler', 'wp-graphql-woocommerce' ),
'desc' => __( 'The QL Session Handler takes over management of WooCommerce Session Management on WPGraphQL request replacing the usage of HTTP Cookies with JSON Web Tokens.', 'wp-graphql-woocommerce' ),
'type' => 'checkbox',
'default' => 'off',
],
[
'name' => 'enable_unsupported_product_type',
'label' => __( 'Enable Unsupported types', 'wp-graphql-woocommerce' ),
'desc' => __( 'Substitute unsupported product types with SimpleProduct', 'wp-graphql-woocommerce' ),
'type' => 'checkbox',
'default' => 'off',
],
];
}
}