-
-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathwoocommerce.php
63 lines (59 loc) · 1.62 KB
/
woocommerce.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<?php
/*
* Plugin Name: Remove WooCommerce features
* Plugin URI: https://github.com/szepeviktor/wordpress-website-lifecycle
*/
add_filter(
'woocommerce_admin_features',
static function ($features) {
// From includes/react-admin/feature-config.php
$disabled_features = [
'activity-panels',
'analytics',
'product-block-editor',
'coupons',
'core-profiler',
'customize-store',
'customer-effort-score-tracks',
'import-products-task',
'experimental-fashion-sample-products',
'shipping-smart-defaults',
'shipping-setting-tour',
'homescreen',
'marketing',
'mobile-app-banner',
'navigation',
'onboarding',
'onboarding-tasks',
'product-custom-fields',
'remote-inbox-notifications',
'remote-free-extensions',
'payment-gateway-suggestions',
'shipping-label-banner',
'subscriptions',
'store-alerts',
'transient-notices',
'woo-mobile-welcome',
'wc-pay-promotion',
'wc-pay-welcome-page',
'launch-your-store',
];
return array_diff($features, $disabled_features);
},
11,
1
);
// Disable password change notification email
add_filter(
'woocommerce_disable_password_change_notification',
'__return_true',
10,
0
);
// Disable Marketplace promotions
add_filter(
'woocommerce_marketplace_suppress_promotions',
'__return_true',
10,
0
);