PluginProbe
Awesome Support – WordPress HelpDesk & Support Plugin / trunk
Awesome Support – WordPress HelpDesk & Support Plugin vtrunk
6.4.0 trunk 3.0.0 3.0.1 3.1.0 3.1.1 3.1.10 3.1.11 3.1.12 3.1.2 3.1.3 3.1.4 3.1.5 3.1.6 3.1.7 3.1.8 3.1.9 3.2.0 3.2.1 3.2.2 3.2.3 3.2.4 3.2.5 3.2.6 3.2.7 All 95 releases
awesome-support / includes / admin / settings / settings-integration.php

settings-integration.php in Awesome Support – WordPress HelpDesk & Support Plugin trunk, at includes/admin/settings/settings-integration.php

147 lines 6.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 add_filter( 'wpas_plugin_settings', 'wpas_core_settings_integration', 95, 1 );
3 /**
4 * Add plugin integration settings
5 *
6 * @param (array) $def Array of existing settings
7 * @return (array) Updated settings
8 */
9 function wpas_core_settings_integration( $def ) {
10
11 // translators: %s is the link to the addons.
12 $desc = __( 'Add the MY TICKETS and OPEN A TICKET links to the MY ACCOUNT page in WooCommerce. For more advanced integration features checkout our %s', 'awesome-support' );
13
14 // translators: %s is the link to the addons.
15 $desc1 = __( 'Integration options with MY CRED. You must have the MY CRED plugin installed and activated before enabling anythign in this section. Get myCRED from here: %s', 'awesome-support' );
16 $settings = array(
17 'integration' => array(
18 'name' => __( 'Integrations', 'awesome-support' ),
19 'options' => array(
20
21 array(
22 'name' => __( 'WooCommerce', 'awesome-support' ),
23 'id' => 'simple_wc',
24 'type' => 'heading',
25 'desc' => sprintf( $desc, '<a href="https://getawesomesupport.com/addons/woocommerce/" target="_blank">' . 'WooCommerce Addon' . '</a>' ),
26 ),
27 array(
28 'name' => __( 'Enable WooCommerce Integration', 'awesome-support' ),
29 'id' => 'enable_simple_wc',
30 'type' => 'checkbox',
31 'desc' => __( 'Add the Awesome Support MY TICKETS and OPEN A TICKET page links on the WooCommerce MY ACCOUNT page', 'awesome-support' ),
32 'default' => false,
33 ),
34 array(
35 'name' => __( 'Permalinks Warning:', 'awesome-support' ),
36 'type' => 'note',
37 'desc' => __( 'Note: You must go to your Permalinks page and save the settings there again if you turn on or off the WooCommerce option above.', 'awesome-support' ),
38 ),
39 array(
40 'name' => __( 'Label for MY TICKETS link', 'awesome-support' ),
41 'id' => 'simple_wc_my_tickets_label',
42 'type' => 'text',
43 'desc' => __( 'If left blank, the label will be "My tickets". Leave blank if you are creating a multi-language website', 'awesome-support' ),
44 ),
45 array(
46 'name' => __( 'Label for SUBMIT TICKET link', 'awesome-support' ),
47 'id' => 'simple_wc_submit_ticket_label',
48 'type' => 'text',
49 'desc' => __( 'If left blank, the label will be "Open a support ticket". Leave blank if you are creating a multi-language website', 'awesome-support' ),
50 ),
51
52 array(
53 'name' => __( 'myCRED', 'awesome-support' ),
54 'id' => 'my_cred',
55 'type' => 'heading',
56 'desc' => sprintf( $desc1, '<a href="https://wordpress.org/plugins/mycred/" target="_blank">' . 'myCRED' . '</a>' ),
57 ),
58 array(
59 'name' => __( 'Enable myCRED Integration', 'awesome-support' ),
60 'id' => 'enable_my_cred',
61 'type' => 'checkbox',
62 'desc' => __( 'Send ticket data to myCRED so agents and users can earn badges, ranks and other points.', 'awesome-support' ),
63 'default' => false,
64 ),
65 array(
66 'name' => __( 'myCRED Agent Point Type', 'awesome-support' ),
67 'id' => 'myCRED_agent_point_type',
68 'type' => 'text',
69 'desc' => __( 'What is the myCRED Meta Key that should be used to record points for agents? The default is <em>mycred_default</em>. See the myCRED settings screen and documentation for more information.', 'awesome-support' ),
70 'default' => 'mycred_default',
71 ),
72 array(
73 'name' => __( 'myCRED Agent Points: Submit Ticket', 'awesome-support' ),
74 'id' => 'myCRED_agent_points_ticket_submit',
75 'type' => 'number',
76 'desc' => __( 'How many points should an agent get when they submit or open a ticket?', 'awesome-support' ),
77 'default' => 1,
78 ),
79 array(
80 'name' => __( 'myCRED Agent Points: Closing Tickets', 'awesome-support' ),
81 'id' => 'myCRED_agent_points_ticket_close',
82 'type' => 'number',
83 'desc' => __( 'How many points should an agent get when they close a ticket?', 'awesome-support' ),
84 'default' => 1,
85 ),
86 array(
87 'name' => __( 'myCRED Agent Points: Replies', 'awesome-support' ),
88 'id' => 'myCRED_agent_points_ticket_reply',
89 'type' => 'number',
90 'desc' => __( 'How many points should an agent get when they add a reply to a ticket?', 'awesome-support' ),
91 'default' => 1,
92 ),
93 array(
94 'name' => __( 'myCRED User Point Type', 'awesome-support' ),
95 'id' => 'myCRED_user_point_type',
96 'type' => 'text',
97 'desc' => __( 'What is the myCRED Meta Key that should be used to record points for users? The default is <em>mycred_default</em>. See the myCRED settings screen and documentation for more information.', 'awesome-support' ),
98 'default' => 'mycred_default',
99 ),
100 array(
101 'name' => __( 'myCRED User Points: Submit Ticket', 'awesome-support' ),
102 'id' => 'myCRED_user_points_ticket_submit',
103 'type' => 'number',
104 'desc' => __( 'How many points should a user get when they submit or open a ticket?', 'awesome-support' ),
105 'default' => 1,
106 ),
107 array(
108 'name' => __( 'myCRED User Points: Replies', 'awesome-support' ),
109 'id' => 'myCRED_user_points_ticket_reply',
110 'type' => 'number',
111 'desc' => __( 'How many points should a user get when they reply to a ticket?', 'awesome-support' ),
112 'default' => 1,
113 ),
114 array(
115 'name' => __( 'myCRED User Points: Closing Tickets', 'awesome-support' ),
116 'id' => 'myCRED_user_points_ticket_close',
117 'type' => 'number',
118 'desc' => __( 'How many points should a user get when they close a ticket?', 'awesome-support' ),
119 'default' => 1,
120 ),
121 array(
122 'name' => __( 'Agent Gets Credit For User Closing Ticket', 'awesome-support' ),
123 'id' => 'myCRED_agent_gets_points_user_close',
124 'type' => 'checkbox',
125 'desc' => __( 'If the user closes a ticket should the agent get points for it anyway?', 'awesome-support' ),
126 'default' => false,
127 ),
128
129 array(
130 'name' => __( 'Teamviewer', 'awesome-support' ),
131 'id' => 'simple_tv',
132 'type' => 'heading',
133 ),
134 array(
135 'name' => __( 'Enable Teamviewer Chat', 'awesome-support' ),
136 'id' => 'enable_teamviewer_chat',
137 'type' => 'checkbox',
138 'desc' => __( 'If your team is licensed to use teamviewer in a multi-user environment you can use teamviewer chat right inside the Awesome Support ticket screens!', 'awesome-support' ),
139 'default' => false
140 ),
141 )
142 ),
143 );
144
145 return array_merge( $def, apply_filters('wpas_settings_integration', $settings ) );
146
147 }