PluginProbe
FluentCart A New Era of eCommerce – Faster, Lighter, and Simpler / 1.6.4
FluentCart A New Era of eCommerce – Faster, Lighter, and Simpler v1.6.4
1.6.4 1.6.3 1.6.2 1.6.1 1.6.0 1.5.4 1.5.5 1.5.3 1.5.2 1.5.1 1.5.0 1.4.2 1.4.1 1.4.0 1.3.28 1.3.27 1.3.26 1.3.25 1.3.23 1.3.22 1.3.21 1.3.20 1.3.19 trunk 1.2.0 All 47 releases
fluent-cart / app / Modules / Integrations / AddOnModule.php

AddOnModule.php in FluentCart A New Era of eCommerce – Faster, Lighter, and Simpler 1.6.4, at app/Modules/Integrations/AddOnModule.php

65 lines 1.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace FluentCart\App\Modules\Integrations;
4
5 use FluentCart\Framework\Support\Arr;
6 use FluentCart\App\Vite;
7
8
9 class AddOnModule
10 {
11 /**
12 * Show the add-ons list.
13 */
14 public static function showAddOns(): array
15 {
16 $addOns = apply_filters('fluent_cart/integration/order_integrations', []);
17
18 return [
19 'addOns' => $addOns
20 ];
21 }
22
23 public function updateAddOnsStatus($request): array
24 {
25 $addons = wp_unslash(Arr::get($request, 'addons'));
26 fluent_cart_update_option('fluent_cart_global_integrations', $addons);
27
28 return [
29 'message' => __('Status successfully updated', 'fluent-cart')
30 ];
31 }
32
33
34 public static function getPremiumAddOns(): array
35 {
36 return [];
37 }
38
39 public static function getFluentCrm(): array
40 {
41 return [
42 'fluent-crm' => [
43 'title' => __('Fluent CRM', 'fluent-cart'),
44 'description' => __('Connect FluentCRM with FluentCart and subscribe a contact when a form is submitted', 'fluent-cart'),
45 'logo' => Vite::getAssetUrl('images/integrations/fluentcrm.svg'),
46 'enabled' => 'yes',
47 'purchase_url' => 'https://wordpress.org/plugins/fluent-crm/',
48 'category' => 'crm',
49 'btnTxt' => __('Install & Activate', 'fluent-cart')
50 ]
51 ];
52 }
53
54 // public static function isModuleEnabled($module = 'slack')
55 // {
56 // $globalModules = fct_get_option('fluent_cart_global_integrations');
57 // return $globalModules && isset($globalModules[$module]) && $globalModules[$module] == 'yes';
58 // }
59
60 public static function getFluentSupport()
61 {
62 return [];
63 }
64 }
65