zendesk - Version 2.1.7

Version Notes

Add logging for exception on customer ticket fetch.

Download this release

Release Info

Developer Zendesk
Extension zendesk
Version 2.1.7
Comparing to
See all releases


Code changes from version 2.1.4 to 2.1.7

app/code/community/Zendesk/Zendesk/Helper/.gitignore ADDED
@@ -0,0 +1 @@
 
1
+ /vendor
app/code/community/Zendesk/Zendesk/Helper/_/Data.php ADDED
@@ -0,0 +1,445 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Copyright 2012 Zendesk.
4
+ *
5
+ * Licensed under the Apache License, Version 2.0 (the "License");
6
+ * you may not use this file except in compliance with the License.
7
+ * You may obtain a copy of the License at
8
+ *
9
+ * http://www.apache.org/licenses/LICENSE-2.0
10
+ *
11
+ * Unless required by applicable law or agreed to in writing, software
12
+ * distributed under the License is distributed on an "AS IS" BASIS,
13
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ * See the License for the specific language governing permissions and
15
+ * limitations under the License.
16
+ */
17
+
18
+ class Zendesk_Zendesk_Helper_Data extends Mage_Core_Helper_Abstract
19
+ {
20
+
21
+ public function getUrl($object = '', $id = null, $format = 'old')
22
+ {
23
+ $protocol = 'https://';
24
+ $domain = Mage::getStoreConfig('zendesk/general/domain');
25
+ $root = ($format === 'old') ? '' : '/agent';
26
+
27
+ $base = $protocol . $domain . $root;
28
+ $hc = $protocol . $domain . '/hc';
29
+
30
+ switch($object) {
31
+ case '':
32
+ return $base;
33
+ break;
34
+
35
+ case 'ticket':
36
+ return $base . '/tickets/' . $id;
37
+ break;
38
+
39
+ case 'user':
40
+ return $base . '/users/' . $id;
41
+ break;
42
+
43
+ case 'raw':
44
+ return $protocol . $domain . '/' . $id;
45
+ break;
46
+
47
+ case 'request':
48
+ return $hc . '/requests/' . $id;
49
+ break;
50
+ }
51
+ }
52
+
53
+ /**
54
+ * Returns configured Zendesk Domain
55
+ * format: company.zendesk.com
56
+ *
57
+ * @return mixed Zendesk Account Domain
58
+ */
59
+ public function getZendeskDomain()
60
+ {
61
+ return Mage::getStoreConfig('zendesk/general/domain');
62
+ }
63
+
64
+
65
+ /**
66
+ * Returns if SSO is enabled for EndUsers
67
+ * @return integer
68
+ */
69
+ public function isSSOEndUsersEnabled()
70
+ {
71
+ return Mage::getStoreConfig('zendesk/sso_frontend/enabled');
72
+ }
73
+
74
+ /**
75
+ * Returns if SSO is enabled for Admin/Agent Users
76
+ * @return integer
77
+ */
78
+ public function isSSOAdminUsersEnabled()
79
+ {
80
+ return Mage::getStoreConfig('zendesk/sso/enabled');
81
+ }
82
+
83
+ /**
84
+ * Returns frontend URL where authentication process starts for EndUsers
85
+ *
86
+ * @return string SSO Url to auth EndUsers
87
+ */
88
+ public function getSSOAuthUrlEndUsers()
89
+ {
90
+ return Mage::getUrl('zendesk/sso/login');
91
+ }
92
+
93
+ /**
94
+ * Returns backend URL where authentication process starts for Admin/Agents
95
+ *
96
+ * @return string SSO Url to auth Admin/Agents
97
+ */
98
+ public function getSSOAuthUrlAdminUsers()
99
+ {
100
+ return Mage::helper('adminhtml')->getUrl('*/zendesk/login');
101
+ }
102
+
103
+ /**
104
+ * Returns Zendesk Account Login URL for normal access
105
+ * format: https://<zendesk_account>/<route>
106
+ *
107
+ * @return string Zendesk Account login url
108
+ */
109
+ public function getZendeskAuthNormalUrl()
110
+ {
111
+ $protocol = 'https://';
112
+ $domain = $this->getZendeskDomain();
113
+ $route = '/access/normal';
114
+
115
+ return $protocol . $domain . $route;
116
+ }
117
+
118
+ /**
119
+ * Returns Zendesk Login Form unauthenticated URL
120
+ * format: https://<zendesk_account>/<route>
121
+ *
122
+ * @return string Zendesk Account login unauthenticated form url
123
+ */
124
+ public function getZendeskUnauthUrl()
125
+ {
126
+ $protocol = 'https://';
127
+ $domain = $this->getZendeskDomain();
128
+ //Zendesk will automatically redirect to login if user is not logged in
129
+ //previous URL followed to login page even if user has already logged in
130
+ $route = '/home';
131
+
132
+ return $protocol . $domain . $route;
133
+ }
134
+
135
+ public function getApiToken($generate = true)
136
+ {
137
+ // Grab any existing token from the admin scope
138
+ $token = Mage::getStoreConfig('zendesk/api/token', 0);
139
+
140
+ if( (!$token || strlen(trim($token)) == 0) && $generate) {
141
+ $token = $this->setApiToken();
142
+ }
143
+
144
+ return $token;
145
+ }
146
+
147
+ public function setApiToken($token = null)
148
+ {
149
+ if(!$token) {
150
+ $token = md5(time());
151
+ }
152
+ Mage::getModel('core/config')->saveConfig('zendesk/api/token', $token, 'default');
153
+
154
+ return $token;
155
+ }
156
+
157
+ /**
158
+ * Returns the provisioning endpoint for new setups.
159
+ *
160
+ * This uses the config/zendesk/provision_url XML path to retrieve the setting, with a default value set in
161
+ * the extension config.xml file. This can be overridden in your website's local.xml file.
162
+ * @return null|string URL or null on failure
163
+ */
164
+ public function getProvisionUrl()
165
+ {
166
+ $config = Mage::getConfig();
167
+ $data = $config->getNode('zendesk/provision_url');
168
+ if(!$data) {
169
+ return null;
170
+ }
171
+ return (string)$data;
172
+ }
173
+
174
+ public function getProvisionToken($generate = false)
175
+ {
176
+ $token = Mage::getStoreConfig('zendesk/hidden/provision_token', 0);
177
+
178
+ if( (!$token || strlen(trim($token)) == 0) && $generate) {
179
+ $token = $this->setProvisionToken();
180
+ }
181
+
182
+ return $token;
183
+ }
184
+
185
+ public function setProvisionToken($token = null)
186
+ {
187
+ if(!$token) {
188
+ $token = md5(time());
189
+ }
190
+
191
+ Mage::getModel('core/config')->saveConfig('zendesk/hidden/provision_token', $token, 'default');
192
+ Mage::getConfig()->removeCache();
193
+
194
+ return $token;
195
+ }
196
+
197
+ public function getOrderDetail($order)
198
+ {
199
+ // if the admin site has a custom URL, use it
200
+ $urlModel = Mage::getModel('adminhtml/url')->setStore('admin');
201
+
202
+ $orderInfo = array(
203
+ 'id' => $order->getIncrementId(),
204
+ 'status' => $order->getStatus(),
205
+ 'created' => $order->getCreatedAt(),
206
+ 'updated' => $order->getUpdatedAt(),
207
+ 'customer' => array(
208
+ 'name' => $order->getCustomerName(),
209
+ 'email' => $order->getCustomerEmail(),
210
+ 'ip' => $order->getRemoteIp(),
211
+ 'guest' => (bool)$order->getCustomerIsGuest(),
212
+ ),
213
+ 'store' => $order->getStoreName(),
214
+ 'total' => $order->getGrandTotal(),
215
+ 'currency' => $order->getOrderCurrencyCode(),
216
+ 'items' => array(),
217
+ 'admin_url' => $urlModel->getUrl('adminhtml/sales_order/view', array('order_id' => $order->getId())),
218
+ );
219
+
220
+ foreach($order->getItemsCollection(array(), true) as $item) {
221
+ $orderInfo['items'][] = array(
222
+ 'sku' => $item->getSku(),
223
+ 'name' => $item->getName(),
224
+ );
225
+ }
226
+
227
+ return $orderInfo;
228
+ }
229
+
230
+ public function getSupportEmail($store = null)
231
+ {
232
+ // Serves as the dafault email
233
+ $domain = Mage::getStoreConfig('zendesk/general/domain', $store);
234
+ $email = 'support@' . $domain;
235
+
236
+ // Get the actual default email from the API, return the default if somehow none is found
237
+ $defaultRecipient = Mage::getModel('zendesk/api_supportAddresses')->getDefault();
238
+
239
+ if (!is_null($defaultRecipient)) {
240
+ $email = $defaultRecipient['email'];
241
+ }
242
+
243
+ return $email;
244
+ }
245
+
246
+ public function loadCustomer($email, $website = null)
247
+ {
248
+ $customer = null;
249
+
250
+ if(Mage::getModel('customer/customer')->getSharingConfig()->isWebsiteScope()) {
251
+ // Customer email address can be used in multiple websites so we need to
252
+ // explicitly scope it
253
+ if($website) {
254
+ // We've been given a specific website, so try that
255
+ $customer = Mage::getModel('customer/customer')
256
+ ->setWebsiteId($website)
257
+ ->loadByEmail($email);
258
+ } else {
259
+ // No particular website, so load all customers with the given email and then return a single object
260
+ $customers = Mage::getModel('customer/customer')
261
+ ->getCollection()
262
+ ->addFieldToFilter('email', array('eq' => array($email)));
263
+ if($customers->getSize()) {
264
+ $id = $customers->getLastItem()->getId();
265
+ $customer = Mage::getModel('customer/customer')->load($id);
266
+ }
267
+ }
268
+
269
+ } else {
270
+ // Customer email is global, so no scoping issues
271
+ $customer = Mage::getModel('customer/customer')->loadByEmail($email);
272
+ }
273
+
274
+ return $customer;
275
+ }
276
+
277
+ /**
278
+ * Retrieve Use External ID config option
279
+ *
280
+ * @return integer
281
+ */
282
+ public function isExternalIdEnabled()
283
+ {
284
+ return Mage::getStoreConfig('zendesk/general/use_external_id');
285
+ }
286
+
287
+ public function getTicketUrl($row, $link = false)
288
+ {
289
+ if ($this->isAdmin()) {
290
+ $path = 'adminhtml/zendesk/login';
291
+ $object = 'ticket';
292
+ } else {
293
+ $path = '*/sso/login';
294
+ $object = 'request';
295
+ }
296
+ $path = Mage::getSingleton('admin/session')->getUser() ? 'adminhtml/zendesk/login' : '*/sso/login';
297
+
298
+ $url = Mage::helper('adminhtml')->getUrl($path, array("return_url" => Mage::helper('core')->urlEncode(Mage::helper('zendesk')->getUrl($object, $row['id']))));
299
+
300
+ if ($link)
301
+ return $url;
302
+
303
+ $subject = $row['subject'] ? $row['subject'] : $this->__('No Subject');
304
+
305
+ return '<a href="' . $url . '" target="_blank">' . Mage::helper('core')->escapeHtml($subject) . '</a>';
306
+ }
307
+
308
+ public function getStatusMap()
309
+ {
310
+ return array(
311
+ 'new' => 'New',
312
+ 'open' => 'Open',
313
+ 'pending' => 'Pending',
314
+ 'solved' => 'Solved',
315
+ 'closed' => 'Closed',
316
+ 'hold' => 'Hold'
317
+ );
318
+ }
319
+
320
+
321
+ public function getPriorityMap()
322
+ {
323
+ return array(
324
+ 'low' => 'Low',
325
+ 'normal' => 'Normal',
326
+ 'high' => 'High',
327
+ 'urgent' => 'Urgent'
328
+ );
329
+ }
330
+
331
+ public function getTypeMap()
332
+ {
333
+ return array(
334
+ 'problem' => 'Problem',
335
+ 'incident' => 'Incident',
336
+ 'question' => 'Question',
337
+ 'task' => 'Task'
338
+ );
339
+ }
340
+
341
+ public function getChosenViews() {
342
+ $list = trim(trim(Mage::getStoreConfig('zendesk/backend_features/show_views')), ',');
343
+ return explode(',', $list);
344
+ }
345
+
346
+ public function getFormatedDataForAPI($dateToFormat) {
347
+ $myDateTime = DateTime::createFromFormat('d/m/Y', $dateToFormat);
348
+ return $myDateTime->format('Y-m-d');
349
+ }
350
+
351
+ public function isValidDate($date) {
352
+ if(is_string($date)) {
353
+ $d = DateTime::createFromFormat('d/m/Y', $date);
354
+ return $d && $d->format('d/m/Y') == $date;
355
+ }
356
+
357
+ return false;
358
+ }
359
+
360
+ public function getFormatedDateTime($dateToFormat) {
361
+ return Mage::helper('core')->formatDate($dateToFormat, 'medium', true);
362
+ }
363
+
364
+ /**
365
+ * Tests if the provided username and password is correct. If either is empty the database values will be used.
366
+ *
367
+ * @param string $domain
368
+ * @param string $username
369
+ * @param string $password
370
+ * @return array
371
+ */
372
+ public function getConnectionStatus($domain = null, $username = null, $password = null) {
373
+ try {
374
+ $usersApi = Mage::getModel('zendesk/api_users');
375
+
376
+ $usersApi->setUsername($username);
377
+ $usersApi->setPassword($password);
378
+ $usersApi->setDomain($domain);
379
+
380
+ $user = $usersApi->me();
381
+
382
+ if(isset($user['id'])) {
383
+ return array(
384
+ 'success' => true,
385
+ 'msg' => Mage::helper('zendesk')->__('Connection to Zendesk API successful'),
386
+ );
387
+ }
388
+
389
+ $error = Mage::helper('zendesk')->__('Connection to Zendesk API failed') .
390
+ '<br />' . Mage::helper('zendesk')->__("Click 'Save Config' and try again. If the issue persist, check if the entered Agent Email Address and Agent Token combination is correct.");
391
+
392
+ return array(
393
+ 'success' => false,
394
+ 'msg' => $error,
395
+ );
396
+
397
+ } catch (Exception $ex) {
398
+ $error = Mage::helper('zendesk')->__('Connection to Zendesk API failed') .
399
+ '<br />' . $ex->getCode() . ': ' . $ex->getMessage() .
400
+ '<br />' . Mage::helper('zendesk')->__("Click 'Save Config' and try again. If the issue persist, check if the entered Agent Email Address and Agent Token combination is correct.");
401
+
402
+ return array(
403
+ 'success' => false,
404
+ 'msg' => $error,
405
+ );
406
+ }
407
+ }
408
+
409
+ /**
410
+ * Checks if the current connection details are valid.
411
+ *
412
+ * @return boolean
413
+ */
414
+ public function isConnected() {
415
+ $connection = $this->getConnectionStatus();
416
+ return $connection['success'];
417
+ }
418
+
419
+ public function storeDependenciesInCachedRegistry() {
420
+ $cache = Mage::app()->getCache();
421
+
422
+ if (null == Mage::registry('zendesk_groups')) {
423
+ if( $cache->load('zendesk_groups') === false) {
424
+ $groups = serialize( Mage::getModel('zendesk/api_groups')->all() );
425
+ $cache->save($groups, 'zendesk_groups', array('zendesk', 'zendesk_groups'), 1200);
426
+ }
427
+
428
+ $groups = unserialize( $cache->load('zendesk_groups') );
429
+ Mage::register('zendesk_groups', $groups);
430
+ }
431
+ }
432
+
433
+ /**
434
+ * Checks whether the user is in an admin page.
435
+ *
436
+ * @return boolean
437
+ */
438
+ public function isAdmin()
439
+ {
440
+ return (
441
+ Mage::getSingleton('admin/session')->getUser() &&
442
+ (Mage::app()->getStore()->isAdmin() || Mage::getDesign()->getArea() == 'adminhtml')
443
+ );
444
+ }
445
+ }
app/code/community/Zendesk/Zendesk/Helper/_/JWT.php ADDED
@@ -0,0 +1,211 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Retrieved 2013-04-29 - commit 82113fd351cea127ded3d07e40eb46865db9e8f2
4
+ // https://github.com/firebase/php-jwt
5
+
6
+ /**
7
+ * JSON Web Token implementation, based on this spec:
8
+ * http://tools.ietf.org/html/draft-ietf-oauth-json-web-token-06
9
+ *
10
+ * PHP version 5
11
+ *
12
+ * @category Authentication
13
+ * @package Authentication_JWT
14
+ * @author Neuman Vong <neuman@twilio.com>
15
+ * @author Anant Narayanan <anant@php.net>
16
+ * @license http://opensource.org/licenses/BSD-3-Clause 3-clause BSD
17
+ * @link https://github.com/firebase/php-jwt
18
+ */
19
+ /**
20
+ * JSON Web Token implementation, based on this spec:
21
+ * http://tools.ietf.org/html/draft-ietf-oauth-json-web-token-06
22
+ *
23
+ * @category Authentication
24
+ * @package Authentication_JWT
25
+ * @author Neuman Vong <neuman@twilio.com>
26
+ * @author Anant Narayanan <anant@php.net>
27
+ * @license http://opensource.org/licenses/BSD-3-Clause 3-clause BSD
28
+ * @link https://github.com/firebase/php-jwt
29
+ */
30
+ class JWT
31
+ {
32
+ /**
33
+ * Decodes a JWT string into a PHP object.
34
+ *
35
+ * @param string $jwt The JWT
36
+ * @param string|null $key The secret key
37
+ * @param bool $verify Don't skip verification process
38
+ *
39
+ * @return object The JWT's payload as a PHP object
40
+ * @throws UnexpectedValueException Provided JWT was invalid
41
+ * @throws DomainException Algorithm was not provided
42
+ *
43
+ * @uses jsonDecode
44
+ * @uses urlsafeB64Decode
45
+ */
46
+ public static function decode($jwt, $key = null, $verify = true)
47
+ {
48
+ $tks = explode('.', $jwt);
49
+ if (count($tks) != 3) {
50
+ throw new UnexpectedValueException('Wrong number of segments');
51
+ }
52
+ list($headb64, $bodyb64, $cryptob64) = $tks;
53
+ if (null === ($header = JWT::jsonDecode(JWT::urlsafeB64Decode($headb64)))) {
54
+ throw new UnexpectedValueException('Invalid segment encoding');
55
+ }
56
+ if (null === $payload = JWT::jsonDecode(JWT::urlsafeB64Decode($bodyb64))) {
57
+ throw new UnexpectedValueException('Invalid segment encoding');
58
+ }
59
+ $sig = JWT::urlsafeB64Decode($cryptob64);
60
+ if ($verify) {
61
+ if (empty($header->alg)) {
62
+ throw new DomainException('Empty algorithm');
63
+ }
64
+ if ($sig != JWT::sign("$headb64.$bodyb64", $key, $header->alg)) {
65
+ throw new UnexpectedValueException('Signature verification failed');
66
+ }
67
+ }
68
+ return $payload;
69
+ }
70
+
71
+ /**
72
+ * Converts and signs a PHP object or array into a JWT string.
73
+ *
74
+ * @param object|array $payload PHP object or array
75
+ * @param string $key The secret key
76
+ * @param string $algo The signing algorithm. Supported
77
+ * algorithms are 'HS256', 'HS384' and 'HS512'
78
+ *
79
+ * @return string A signed JWT
80
+ * @uses jsonEncode
81
+ * @uses urlsafeB64Encode
82
+ */
83
+ public static function encode($payload, $key, $algo = 'HS256')
84
+ {
85
+ $header = array('typ' => 'JWT', 'alg' => $algo);
86
+
87
+ $segments = array();
88
+ $segments[] = JWT::urlsafeB64Encode(JWT::jsonEncode($header));
89
+ $segments[] = JWT::urlsafeB64Encode(JWT::jsonEncode($payload));
90
+ $signing_input = implode('.', $segments);
91
+
92
+ $signature = JWT::sign($signing_input, $key, $algo);
93
+ $segments[] = JWT::urlsafeB64Encode($signature);
94
+
95
+ return implode('.', $segments);
96
+ }
97
+
98
+ /**
99
+ * Sign a string with a given key and algorithm.
100
+ *
101
+ * @param string $msg The message to sign
102
+ * @param string $key The secret key
103
+ * @param string $method The signing algorithm. Supported
104
+ * algorithms are 'HS256', 'HS384' and 'HS512'
105
+ *
106
+ * @return string An encrypted message
107
+ * @throws DomainException Unsupported algorithm was specified
108
+ */
109
+ public static function sign($msg, $key, $method = 'HS256')
110
+ {
111
+ $methods = array(
112
+ 'HS256' => 'sha256',
113
+ 'HS384' => 'sha384',
114
+ 'HS512' => 'sha512',
115
+ );
116
+ if (empty($methods[$method])) {
117
+ throw new DomainException('Algorithm not supported');
118
+ }
119
+ return hash_hmac($methods[$method], $msg, $key, true);
120
+ }
121
+
122
+ /**
123
+ * Decode a JSON string into a PHP object.
124
+ *
125
+ * @param string $input JSON string
126
+ *
127
+ * @return object Object representation of JSON string
128
+ * @throws DomainException Provided string was invalid JSON
129
+ */
130
+ public static function jsonDecode($input)
131
+ {
132
+ $obj = json_decode($input);
133
+ if (function_exists('json_last_error') && $errno = json_last_error()) {
134
+ JWT::_handleJsonError($errno);
135
+ } else if ($obj === null && $input !== 'null') {
136
+ throw new DomainException('Null result with non-null input');
137
+ }
138
+ return $obj;
139
+ }
140
+
141
+ /**
142
+ * Encode a PHP object into a JSON string.
143
+ *
144
+ * @param object|array $input A PHP object or array
145
+ *
146
+ * @return string JSON representation of the PHP object or array
147
+ * @throws DomainException Provided object could not be encoded to valid JSON
148
+ */
149
+ public static function jsonEncode($input)
150
+ {
151
+ $json = json_encode($input);
152
+ if (function_exists('json_last_error') && $errno = json_last_error()) {
153
+ JWT::_handleJsonError($errno);
154
+ } else if ($json === 'null' && $input !== null) {
155
+ throw new DomainException('Null result with non-null input');
156
+ }
157
+ return $json;
158
+ }
159
+
160
+ /**
161
+ * Decode a string with URL-safe Base64.
162
+ *
163
+ * @param string $input A Base64 encoded string
164
+ *
165
+ * @return string A decoded string
166
+ */
167
+ public static function urlsafeB64Decode($input)
168
+ {
169
+ $remainder = strlen($input) % 4;
170
+ if ($remainder) {
171
+ $padlen = 4 - $remainder;
172
+ $input .= str_repeat('=', $padlen);
173
+ }
174
+ return base64_decode(strtr($input, '-_', '+/'));
175
+ }
176
+
177
+ /**
178
+ * Encode a string with URL-safe Base64.
179
+ *
180
+ * @param string $input The string you want encoded
181
+ *
182
+ * @return string The base64 encode of what you passed in
183
+ */
184
+ public static function urlsafeB64Encode($input)
185
+ {
186
+ return str_replace('=', '', strtr(base64_encode($input), '+/', '-_'));
187
+ }
188
+
189
+ /**
190
+ * Helper method to create a JSON error.
191
+ *
192
+ * @param int $errno An error number from json_last_error()
193
+ *
194
+ * @return void
195
+ */
196
+ private static function _handleJsonError($errno)
197
+ {
198
+ $messages = array(
199
+ JSON_ERROR_DEPTH => 'Maximum stack depth exceeded',
200
+ JSON_ERROR_CTRL_CHAR => 'Unexpected control character found',
201
+ JSON_ERROR_SYNTAX => 'Syntax error, malformed JSON'
202
+ );
203
+ throw new DomainException(
204
+ isset($messages[$errno])
205
+ ? $messages[$errno]
206
+ : 'Unknown JSON error: ' . $errno
207
+ );
208
+ }
209
+
210
+ }
211
+
app/code/community/Zendesk/Zendesk/Helper/_/Log.php ADDED
@@ -0,0 +1,145 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Copyright 2013 Zendesk.
4
+ *
5
+ * Licensed under the Apache License, Version 2.0 (the "License");
6
+ * you may not use this file except in compliance with the License.
7
+ * You may obtain a copy of the License at
8
+ *
9
+ * http://www.apache.org/licenses/LICENSE-2.0
10
+ *
11
+ * Unless required by applicable law or agreed to in writing, software
12
+ * distributed under the License is distributed on an "AS IS" BASIS,
13
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ * See the License for the specific language governing permissions and
15
+ * limitations under the License.
16
+ */
17
+
18
+ class Zendesk_Zendesk_Helper_Log extends Mage_Core_Helper_Abstract
19
+ {
20
+ /**
21
+ * Maximum size log file can grow to before we truncate output.
22
+ * Value is arbitrary and based on trial and error for a reasonable amount of data to send back to the browser.
23
+ */
24
+ const MAX_LOG_SIZE = 524288;
25
+
26
+ /**
27
+ * Number of lines to take from the end of the log file, if it's too large.
28
+ */
29
+ const TAIL_SIZE = 1000;
30
+
31
+ public function getLogPath()
32
+ {
33
+ return Mage::getBaseDir('log') . DS. 'zendesk.log';
34
+ }
35
+
36
+ public function getLogSize()
37
+ {
38
+ return filesize($this->getLogPath());
39
+ }
40
+
41
+ public function getTailSize()
42
+ {
43
+ return self::TAIL_SIZE;
44
+ }
45
+
46
+ /**
47
+ * Retrieves the contents of the Zendesk log file, with optional truncation for sending directly back to a browser.
48
+ *
49
+ * NOTE: If allowing for truncation this method can still return a lot of data (too much) if you run into a
50
+ * situation where one of the lines near the end of the file is very, very long. In practice this should
51
+ * rarely happen since the log file should only be written to by this extension.
52
+ *
53
+ * @param bool $allowTruncate Whether the file should be truncated if it's too large
54
+ *
55
+ * @return string File contents
56
+ */
57
+ public function getLogContents($allowTruncate = true)
58
+ {
59
+ $path = $this->getLogPath();
60
+ $content = '';
61
+
62
+ if(file_exists($path)) {
63
+ if($allowTruncate && $this->isLogTooLarge()) {
64
+ $content = $this->_tail($path, self::TAIL_SIZE);
65
+ } else {
66
+ $content = file_get_contents($path);
67
+ }
68
+ }
69
+
70
+ return $content;
71
+ }
72
+
73
+ /**
74
+ * Is the Zendesk log file too large to display?
75
+ *
76
+ * This method doesn't map very well to the size of the tail command on the file in that it doesn't use the
77
+ * same number of lines to determine if the file is "too large". This means that there is the possibility for
78
+ * problems if the log files contains some lines at the end that are extremely long (millions of characters) then
79
+ * the _tail method will still return them.
80
+ *
81
+ * @return bool true if the file is too large to display, false if not
82
+ */
83
+ public function isLogTooLarge()
84
+ {
85
+ $size = $this->getLogSize();
86
+
87
+ if($size !== FALSE && $size > self::MAX_LOG_SIZE) {
88
+ return true;
89
+ }
90
+
91
+ return false;
92
+ }
93
+
94
+ public function clear()
95
+ {
96
+ @unlink($this->getLogPath());
97
+ touch($this->getLogPath());
98
+ }
99
+
100
+ /**
101
+ * Runs a tail operation to retrieve the last lines of a file.
102
+ * @param string $file Path to the file to tail
103
+ * @param int $lines Number of lines to retrieve
104
+ *
105
+ * @return string
106
+ */
107
+ protected function _tail($file, $lines = 10)
108
+ {
109
+ $data = '';
110
+
111
+ // If we're on a Unix-like system then run a much faster shell command to tail the file.
112
+ // Note that this could potentially be implemented as "everything that ISN'T Windows" but
113
+ // was done with a specific list of common kernels for safety.
114
+ // For a larger list see: http://en.wikipedia.org/wiki/Uname#Table_of_standard_uname_output
115
+ if(in_array(php_uname('s'), array('Linux', 'FreeBSD', 'NetBSD', 'OpenBSD', 'Darwin', 'SunOS', 'Unix'))) {
116
+ $data = shell_exec("tail -n $lines '$file'");
117
+ } else {
118
+ // Fall back to a much slower (and manual) process for using PHP to tail the file.
119
+ $fp = fopen($file, 'r');
120
+ $position = filesize($file);
121
+ fseek($fp, $position-1);
122
+ $chunklen = 4096;
123
+ $data = '';
124
+
125
+ while($position >= 0) {
126
+ $position = $position - $chunklen;
127
+
128
+ if ($position < 0) {
129
+ $chunklen = abs($position); $position=0;
130
+ }
131
+
132
+ fseek($fp, $position);
133
+ $data = fread($fp, $chunklen) . $data;
134
+
135
+ if (substr_count($data, "\n") >= $lines + 1) {
136
+ preg_match("!(.*?\n){".($lines-1)."}$!", $data, $match);
137
+ return $match[0];
138
+ }
139
+ }
140
+ fclose($fp);
141
+ }
142
+
143
+ return $data;
144
+ }
145
+ }
app/code/community/Zendesk/Zendesk/Model/Api/Tickets.php CHANGED
@@ -32,49 +32,7 @@ class Zendesk_Zendesk_Model_Api_Tickets extends Zendesk_Zendesk_Model_Api_Abstra
32
  $ticket = $response['ticket'];
33
 
34
  if($sideload) {
35
- // Sideload user information
36
- if(isset($response['users'])) {
37
- // Generate the list of user IDs from the users provided
38
- $users = array();
39
- foreach($response['users'] as $user) {
40
- $users[$user['id']] = $user;
41
- }
42
-
43
- // Use the list of generated users to attach additional details to the ticket
44
- if(isset($ticket['requester_id'])) {
45
- if(isset($users[$ticket['requester_id']])) {
46
- $ticket['requester'] = $users[$ticket['requester_id']];
47
- }
48
- }
49
-
50
- if(isset($ticket['submitter_id'])) {
51
- if(isset($users[$ticket['submitter_id']])) {
52
- $ticket['submitter'] = $users[$ticket['submitter_id']];
53
- }
54
- }
55
-
56
- if(isset($ticket['assignee_id'])) {
57
- if(isset($users[$ticket['assignee_id']])) {
58
- $ticket['assignee'] = $users[$ticket['assignee_id']];
59
- }
60
- }
61
- }
62
-
63
- // Sideload group information
64
- if(isset($response['groups'])) {
65
- // Generate the list of group IDs from the users provided
66
- $groups = array();
67
- foreach($response['groups'] as $group) {
68
- $groups[$group['id']] = $group;
69
- }
70
-
71
- // Use the list of generated groups to attach additional details to the ticket
72
- if(isset($ticket['group_id'])) {
73
- if(isset($groups[$ticket['group_id']])) {
74
- $ticket['group'] = $groups[$ticket['group_id']];
75
- }
76
- }
77
- }
78
  }
79
 
80
  return $ticket;
@@ -146,8 +104,19 @@ class Zendesk_Zendesk_Model_Api_Tickets extends Zendesk_Zendesk_Model_Api_Abstra
146
  {
147
  $user = Mage::getModel('zendesk/api_users')->find($customerEmail);
148
  if(isset($user['id'])) {
149
- $response = $this->_call('users/' . $user['id'] . '/requests.json', null, 'GET', null, false);
150
- return $response['requests'];
 
 
 
 
 
 
 
 
 
 
 
151
  } else {
152
  return array();
153
  }
@@ -192,4 +161,52 @@ class Zendesk_Zendesk_Model_Api_Tickets extends Zendesk_Zendesk_Model_Api_Abstra
192
  return (isset($response['ticket']) ? $response['ticket'] : null);
193
  }
194
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
195
  }
32
  $ticket = $response['ticket'];
33
 
34
  if($sideload) {
35
+ $this->formatSideloaded($response, $ticket);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
36
  }
37
 
38
  return $ticket;
104
  {
105
  $user = Mage::getModel('zendesk/api_users')->find($customerEmail);
106
  if(isset($user['id'])) {
107
+ $response = $this->_call(
108
+ 'users/' . $user['id'] . '/tickets/requested.json',
109
+ array('include' => 'users,groups', 'sort_by' => 'updated_at', 'sort_order' => 'desc'),
110
+ 'GET',
111
+ null,
112
+ false
113
+ );
114
+
115
+ foreach ($response['tickets'] as &$request) {
116
+ $request = $this->formatSideloaded($response, $request);
117
+ }
118
+
119
+ return $response['tickets'];
120
  } else {
121
  return array();
122
  }
161
  return (isset($response['ticket']) ? $response['ticket'] : null);
162
  }
163
 
164
+ private function formatSideloaded($response, $ticket)
165
+ {
166
+ // Sideload user information
167
+ if(isset($response['users'])) {
168
+ // Generate the list of user IDs from the users provided
169
+ $users = array();
170
+ foreach($response['users'] as $user) {
171
+ $users[$user['id']] = $user;
172
+ }
173
+
174
+ // Use the list of generated users to attach additional details to the ticket
175
+ if(isset($ticket['requester_id'])) {
176
+ if(isset($users[$ticket['requester_id']])) {
177
+ $ticket['requester'] = $users[$ticket['requester_id']];
178
+ }
179
+ }
180
+
181
+ if(isset($ticket['submitter_id'])) {
182
+ if(isset($users[$ticket['submitter_id']])) {
183
+ $ticket['submitter'] = $users[$ticket['submitter_id']];
184
+ }
185
+ }
186
+
187
+ if(isset($ticket['assignee_id'])) {
188
+ if(isset($users[$ticket['assignee_id']])) {
189
+ $ticket['assignee'] = $users[$ticket['assignee_id']];
190
+ }
191
+ }
192
+ }
193
+
194
+ // Sideload group information
195
+ if(isset($response['groups'])) {
196
+ // Generate the list of group IDs from the users provided
197
+ $groups = array();
198
+ foreach($response['groups'] as $group) {
199
+ $groups[$group['id']] = $group;
200
+ }
201
+
202
+ // Use the list of generated groups to attach additional details to the ticket
203
+ if(isset($ticket['group_id'])) {
204
+ if(isset($groups[$ticket['group_id']])) {
205
+ $ticket['group'] = $groups[$ticket['group_id']];
206
+ }
207
+ }
208
+ }
209
+
210
+ return $ticket;
211
+ }
212
  }
app/code/community/Zendesk/Zendesk/Model/Observer.php CHANGED
@@ -66,7 +66,7 @@ class Zendesk_Zendesk_Model_Observer
66
  }
67
 
68
  if($storeCode) {
69
- $scope = 'store';
70
  $store = Mage::getModel('core/store')->load($storeCode);
71
  $scopeId = $store->getId();
72
  }
66
  }
67
 
68
  if($storeCode) {
69
+ $scope = 'stores';
70
  $store = Mage::getModel('core/store')->load($storeCode);
71
  $scopeId = $store->getId();
72
  }
app/code/community/Zendesk/Zendesk/etc/config.xml CHANGED
@@ -19,7 +19,7 @@
19
  <config>
20
  <modules>
21
  <Zendesk_Zendesk>
22
- <version>2.1.4</version>
23
  </Zendesk_Zendesk>
24
  </modules>
25
  <zendesk>
19
  <config>
20
  <modules>
21
  <Zendesk_Zendesk>
22
+ <version>2.1.7</version>
23
  </Zendesk_Zendesk>
24
  </modules>
25
  <zendesk>
app/design/adminhtml/default/default/template/zendesk/customer/tickets.phtml CHANGED
@@ -17,21 +17,24 @@
17
  ?>
18
  <?php
19
 
20
- if(!Mage::getStoreConfig('zendesk/backend_features/show_on_customer')) {
21
  return;
22
  }
23
 
24
  $tickets = null;
25
- if($customer = Mage::registry('current_customer')) {
26
  try {
27
  $tickets = Mage::getModel('zendesk/api_tickets')->forRequester($customer->getEmail());
28
- } catch(Exception $e) {
29
- // Don't do anything, just don't show the tickets
30
  }
 
 
31
 
 
32
  }
33
  ?>
34
- <?php if($tickets): ?>
35
  <div class="clear"></div>
36
  <br/>
37
  <div class="entry-edit">
@@ -53,16 +56,15 @@ if($customer = Mage::registry('current_customer')) {
53
  </tr>
54
  </thead>
55
  <tbody class="odd">
56
- <?php foreach($tickets as $ticket): ?>
57
- <?php $t = Mage::getModel('zendesk/api_tickets')->get($ticket['id'], true); ?>
58
  <tr class="border">
59
  <td><?php echo ucwords($ticket['priority']); ?></td>
60
  <td><?php echo Mage::helper('zendesk')->getTicketUrl($ticket); ?></td>
61
  <td><?php echo Mage::helper('core')->formatDate($ticket['created_at'], Mage_Core_Model_Locale::FORMAT_TYPE_MEDIUM, true); ?></td>
62
  <td><?php echo Mage::helper('core')->formatDate($ticket['updated_at'], Mage_Core_Model_Locale::FORMAT_TYPE_MEDIUM, true); ?></td>
63
  <td><?php echo ucwords($ticket['status']); ?></td>
64
- <td><?php echo (isset($ticket['group_id'])) ? $t['group']['name'] : ''; ?></td>
65
- <td><?php echo ($ticket['assignee_id']) ? $t['assignee']['name'] : ''; ?></td>
66
  </tr>
67
  <?php endforeach; ?>
68
  </tbody>
17
  ?>
18
  <?php
19
 
20
+ if (!Mage::getStoreConfig('zendesk/backend_features/show_on_customer')) {
21
  return;
22
  }
23
 
24
  $tickets = null;
25
+ if ($customer = Mage::registry('current_customer')) {
26
  try {
27
  $tickets = Mage::getModel('zendesk/api_tickets')->forRequester($customer->getEmail());
28
+ } catch (Exception $e) {
29
+ Mage::log("Customer {$customer->getEmail()} ticket fetch resulted in: {$e->getMessage()}", null, 'zendesk.log');
30
  }
31
+ } else {
32
+ Mage::log('Magento failed to return current customer.', null, 'zendesk.log');
33
 
34
+ return;
35
  }
36
  ?>
37
+ <?php if ($tickets): ?>
38
  <div class="clear"></div>
39
  <br/>
40
  <div class="entry-edit">
56
  </tr>
57
  </thead>
58
  <tbody class="odd">
59
+ <?php foreach ($tickets as $ticket):?>
 
60
  <tr class="border">
61
  <td><?php echo ucwords($ticket['priority']); ?></td>
62
  <td><?php echo Mage::helper('zendesk')->getTicketUrl($ticket); ?></td>
63
  <td><?php echo Mage::helper('core')->formatDate($ticket['created_at'], Mage_Core_Model_Locale::FORMAT_TYPE_MEDIUM, true); ?></td>
64
  <td><?php echo Mage::helper('core')->formatDate($ticket['updated_at'], Mage_Core_Model_Locale::FORMAT_TYPE_MEDIUM, true); ?></td>
65
  <td><?php echo ucwords($ticket['status']); ?></td>
66
+ <td><?php echo (isset($ticket['group_id'])) ? $ticket['group']['name'] : ''; ?></td>
67
+ <td><?php echo ($ticket['assignee_id']) ? $ticket['assignee']['name'] : ''; ?></td>
68
  </tr>
69
  <?php endforeach; ?>
70
  </tbody>
app/design/frontend/base/default/template/zendesk/customer/tickets/list.phtml CHANGED
@@ -36,7 +36,6 @@
36
  </thead>
37
  <tbody class="odd">
38
  <?php foreach($tickets as $ticket): ?>
39
- <?php $t = Mage::getModel('zendesk/api_tickets')->get($ticket['id'], true); ?>
40
  <tr class="border">
41
  <td><?php echo Mage::helper('zendesk')->getTicketUrl($ticket); ?></td>
42
  <td><?php echo Mage::helper('core')->formatDate($ticket['created_at'], Mage_Core_Model_Locale::FORMAT_TYPE_MEDIUM, true); ?></td>
36
  </thead>
37
  <tbody class="odd">
38
  <?php foreach($tickets as $ticket): ?>
 
39
  <tr class="border">
40
  <td><?php echo Mage::helper('zendesk')->getTicketUrl($ticket); ?></td>
41
  <td><?php echo Mage::helper('core')->formatDate($ticket['created_at'], Mage_Core_Model_Locale::FORMAT_TYPE_MEDIUM, true); ?></td>
app/locale/en_US/Zendesk_Zendesk.yml DELETED
@@ -1,418 +0,0 @@
1
- title: "Magento"
2
- packages:
3
- - default
4
- - magento
5
- - classic
6
-
7
- parts:
8
-
9
- # Configuration Form
10
- - translation:
11
- key: "txt.integrations.magento.config.general.title"
12
- title: "Configuration form: title for the group of general configuration options"
13
- value: "General"
14
- - translation:
15
- key: "txt.integrations.magento.config.general.description"
16
- title: "Configuration form: description for the general section"
17
- value: "General settings that are required to connect Zendesk and Magento."
18
- - translation:
19
- key: "txt.integrations.magento.config.general.domain"
20
- title: "Configuration form: label for their Zendesk Domain"
21
- value: "Zendesk Domain"
22
- - translation:
23
- key: "txt.integrations.magento.config.general.email"
24
- title: "Configuration form: label for a Zendesk agent email address"
25
- value: "Agent Email Address"
26
- - translation:
27
- key: "txt.integrations.magento.config.general.token"
28
- title: "Configuration form: label for a Zendesk agent token"
29
- value: "Agent Token"
30
- - translation:
31
- key: "txt.integrations.magento.config.general.token_hint"
32
- title: "Configuration form: helper text to show them where to generate a token in Zendesk"
33
- value: "To generate a token, sign in to Zendesk then select Manage > Channels > API > Token"
34
- - translation:
35
- key: "txt.integrations.magento.config.sso.title"
36
- title: "Configuration form: title for agent Single Sign-on section"
37
- value: "Single Sign-on - Admins and Agents"
38
- - translation:
39
- key: "txt.integrations.magento.config.sso.comment"
40
- title: "Configuration form: description for agent Single Sign-on section"
41
- value: "Use Magento to manage admin and agent authentication."
42
- - translation:
43
- key: "txt.integrations.magento.config.sso.label"
44
- title: "Configuration form: label for single sign-on feature"
45
- value: "Single Sign-on Enabled"
46
- - translation:
47
- key: "txt.integrations.magento.config.sso.description"
48
- title: "Configuration form: description for the single sign-on section"
49
- value: "Use Magento to manage user authentication."
50
- - translation:
51
- key: "txt.integrations.magento.config.general.remote_auth"
52
- title: "Configuration form: label for the Zendesk remote authentication token"
53
- value: "Remote Authentication Token"
54
- - translation:
55
- key: "txt.integrations.magento.config.features.title"
56
- title: "Configuration form: title for features section"
57
- value: "Features"
58
- - translation:
59
- key: "txt.integrations.magento.config.features.description"
60
- title: "Configuration form: description for the features section"
61
- value: "Decide which features you would like turned on in your Magento store."
62
- - translation:
63
- key: "txt.integrations.magento.config.features.show_support_on_dashboard"
64
- title: "Configuration form: label asking if they would like to have a feature turned on or off"
65
- value: "Show support tickets on admin dashboard"
66
- - translation:
67
- key: "txt.integrations.magento.config.features.views_to_display"
68
- title: "Configuration form: label asking which Zendesk Views they would like to display"
69
- value: "Views to show on dashboards"
70
- - translation:
71
- key: "txt.integrations.magento.config.features.show_support_on_customer"
72
- title: "Configuration form: label asking if they would like to have a feature turned on or off"
73
- value: "Show support tickets on customer view"
74
- - translation:
75
- key: "txt.integrations.magento.config.features.show_support_on_order"
76
- title: "Configuration form: label asking if they would like to have a feature turned on or off"
77
- value: "Show support tickets on order view"
78
- - translation:
79
- key: "txt.integrations.magento.config.features.create_tickets"
80
- title: "Configuration form: label asking if they would like to have a feature turned on or off"
81
- value: "Create tickets from Contact Us form"
82
- - translation:
83
- key: "txt.integrations.magento.config.features.feedback_tab"
84
- title: "Configuration form: label asking if they would like to display a feedback tab"
85
- value: "Code to display Feedback Tab"
86
- - translation:
87
- key: "txt.integrations.magento.config.features.feedback_tab_customize"
88
- title: "Configuration form: link to let them customize their feedback tab"
89
- value: "Customize Feedback Tab"
90
- - translation:
91
- key: "txt.integrations.magento.config.features.web_widget"
92
- title: "Configuration form: label asking if they would like to display the web widget"
93
- value: "Include Web Widget"
94
- - translation:
95
- key: "txt.integrations.magento.config.features.web_widget_customize"
96
- title: "Configuration form: link to let them customize their web widget"
97
- value: "Customize Web Widget"
98
- - translation:
99
- key: "txt.integrations.magento.config.features.display_link_to_zendesk"
100
- title: "Configuration form: link to let them toggle the display of a link to Zendesk in the footer"
101
- value: "Display link to Zendesk in Magento footer"
102
- - translation:
103
- key: "txt.integrations.magento.config.features.order_field_id"
104
- title: "Configuration form: label asking for their Zendesk order number custom field ID"
105
- value: "Zendesk Order Number field ID"
106
- - translation:
107
- key: "txt.integrations.magento.config.features.order_field_id_hint"
108
- title: "Configuration form: hint text describing why the field is required"
109
- value: "Used to link order in Magento with tickets in Zendesk"
110
- - translation:
111
- key: "txt.integrations.magento.config.api_details.title"
112
- title: "Configuration form: title for API Details section"
113
- value: "API Details"
114
- - translation:
115
- key: "txt.integrations.magento.config.api_details.description"
116
- title: "Configuration form: description for the API details section"
117
- value: "Required for Magento App inside Zendesk to work."
118
- - translation:
119
- key: "txt.integrations.magento.config.api_details.enabled"
120
- title: "Configuration form: label asking if they would like the API to be enabled"
121
- value: "API Enabled"
122
- - translation:
123
- key: "txt.integrations.magento.config.api_details.token"
124
- title: "Configuration form: label for their API Token"
125
- value: "API Token"
126
- - translation:
127
- key: "txt.integrations.magento.config.api_details.generate"
128
- title: "Configuration form: button to generate an API token"
129
- value: "Generate"
130
- - translation:
131
- key: "txt.integrations.magento.config.api_details.generate_success"
132
- title: "Configuration form: message after a token has been successfully generated"
133
- value: "Successfully generated a new API token"
134
- - translation:
135
- key: "txt.integrations.magento.config.support_channels.title"
136
- title: "Configuration form: title for the support channels section"
137
- value: "Support Channels"
138
- - translation:
139
- key: "txt.integrations.magento.config.support_channels.description"
140
- title: "Configuration form: description for the support channels section"
141
- value: "Zendesk allows your customers to contact you using the methods they prefer. Use the links below to configure the channels you would like to use."
142
- - translation:
143
- key: "txt.integrations.magento.config.support_channels.voice"
144
- title: "Configuration form: label for a link to our voice channel"
145
- value: "Voice"
146
- - translation:
147
- key: "txt.integrations.magento.config.support_channels.feedback_tab"
148
- title: "Configuration form: label for a link to our feedback tab channel"
149
- value: "Feedback Tab"
150
- - translation:
151
- key: "txt.integrations.magento.config.support_channels.api"
152
- title: "Configuration form: label for a link to our API channel"
153
- value: "API"
154
- - translation:
155
- key: "txt.integrations.magento.config.support_channels.facebook"
156
- title: "Configuration form: label for a link to our Facebook channel"
157
- value: "Facebook"
158
- hidden: true
159
- - translation:
160
- key: "txt.integrations.magento.config.support_channels.chat"
161
- title: "Configuration form: label for a link to our chat channel"
162
- value: "Chat"
163
- - translation:
164
- key: "txt.integrations.magento.config.support_channels.web_portal"
165
- title: "Configuration form: label for a link to our web portal channel"
166
- value: "Web Portal"
167
- - translation:
168
- key: "txt.integrations.magento.config.support_channels.twitter"
169
- title: "Configuration form: label for a link to our twitter channel"
170
- value: "Twitter"
171
- hidden: true
172
- - translation:
173
- key: "txt.integrations.magento.config.support_channels.email"
174
- title: "Configuration form: label for a link to our email channel"
175
- value: "Email"
176
- - translation:
177
- key: "txt.integrations.magento.config.setup.title"
178
- title: "Configuration form: title for the setup section"
179
- value: "Setup"
180
- - translation:
181
- key: "txt.integrations.magento.config.setup.description"
182
- title: "Configuration form: description for the setup section"
183
- value: "Haven't setup Zendesk yet? Follow our easy setup guide to start using Zendesk to support your customers."
184
- - translation:
185
- key: "txt.integrations.magento.config.setup.guide"
186
- title: "Configuration form: button linking to the setup guide"
187
- value: "Setup guide"
188
- - translation:
189
- key: "txt.integrations.magento.config.save"
190
- title: "Configuration form: button to save the form"
191
- value: "Save Config"
192
- - translation:
193
- key: "text.integrations.magento.config.test_connection.title"
194
- title: "Configuration form: buttons to test API connections"
195
- value: "Test Connection"
196
- - translation:
197
- key: "text.integrations.magento.config.sso_frontend.title"
198
- title: "Configuration form: title for frontend SSO settings"
199
- value: "Single Sign-on - End-users"
200
- - translation:
201
- key: "text.integrations.magento.config.sso_frontend.comment"
202
- title: "Configuration form: description of frontend SSO"
203
- value: "Use Magento to manage end-user authentication."
204
- - translation:
205
- key: "text.integrations.magento.config.sso_frontend.enabled"
206
- title: "Configuration form: select box for enabling SSO for frontend users"
207
- value: "Single Sign-on Enabled"
208
- - translation:
209
- key: "text.integrations.magento.config.sso_frontend.token"
210
- title: "Configuration form: shared secret for SSO support"
211
- value: "Remote Authentication Token"
212
- - translation:
213
- key: "text.integrations.magento.config.test_connection.inbound.success"
214
- title: "Configuration message: connection to the Magento API succeeded"
215
- value: "API test connection successful"
216
- - translation:
217
- key: "text.integrations.magento.config.test_connection.outbound.success"
218
- title: "Configuration message: connection to the Zendesk API succeeded"
219
- value: "Connection to Zendesk API successful"
220
- - translation:
221
- key: "text.integrations.magento.config.test_connection.inbound.failure"
222
- title: "Configuration message: connection to the Magento API failed"
223
- value: "API test connection failed"
224
- - translation:
225
- key: "text.integrations.magento.config.test_connection.tips"
226
- title: "Configuration message: suggestion to look at provided URL for troubleshooting"
227
- value: 'Troubleshooting tips can be found at <a href="%s" target="_blank">%s</a>'
228
- obsolete: "2015-09-17"
229
- - translation:
230
- key: "text.integrations.magento.config.test_connection.outbound.failure"
231
- title: "Configuration message: connection to the Zendesk API failed"
232
- value: "Connection to Zendesk API failed"
233
- - translation:
234
- key: "text.integrations.magento.config.test_connection.troubleshooting"
235
- title: "Configuration message: suggestion to look at configured email and token for troubleshooting. See txt.integrations.magento.config.save, txt.integrations.magento.config.general.email and txt.integrations.magento.config.general.token for consistency"
236
- value: "Click 'Save Config' and try again. If the issue persist, check if the entered Agent Email Address and Agent Token combination is correct."
237
-
238
- # Tickets
239
- - translation:
240
- key: "txt.integrations.magento.tickets.assignee"
241
- title: "The Zendesk assignee for a ticket"
242
- value: "Assignee"
243
- - translation:
244
- key: "txt.integrations.magento.tickets.create_ticket"
245
- title: "Create a Zendesk ticket"
246
- value: "Create Ticket"
247
- - translation:
248
- key: "txt.integrations.magento.tickets.group"
249
- title: "A Zendesk group"
250
- value: "Group"
251
- - translation:
252
- key: "txt.integrations.magento.tickets.new_ticket"
253
- title: "Create a new support ticket"
254
- value: "New Support Ticket"
255
- - translation:
256
- key: "txt.integrations.magento.tickets.no_tickets"
257
- title: "No tickets could be found"
258
- value: "No tickets found"
259
- - translation:
260
- key: "txt.integrations.magento.tickets.priority"
261
- title: "The priority of a ticket"
262
- value: "Priority"
263
- - translation:
264
- key: "txt.integrations.magento.tickets.priority_low"
265
- title: "Low priority of a ticket"
266
- value: "Low"
267
- - translation:
268
- key: "txt.integrations.magento.tickets.priority_normal"
269
- title: "Normal priority of a ticket"
270
- value: "Normal"
271
- - translation:
272
- key: "txt.integrations.magento.tickets.priority_high"
273
- title: "High priority of a ticket"
274
- value: "High"
275
- - translation:
276
- key: "txt.integrations.magento.tickets.priority_urgent"
277
- title: "Urgent priority of a ticket"
278
- value: "Urgent"
279
- - translation:
280
- key: "txt.integrations.magento.tickets.requester"
281
- title: "The label for the requester of a ticket"
282
- value: "Requester"
283
- - translation:
284
- key: "txt.integrations.magento.tickets.requested"
285
- title: "The label for when a ticket was requested"
286
- value: "Requested"
287
- - translation:
288
- key: "txt.integrations.magento.tickets.requester_email"
289
- title: "The label for the requester's email address"
290
- value: "Requester Email"
291
- - translation:
292
- key: "txt.integrations.magento.tickets.requester_name"
293
- title: "The label for the requester's name"
294
- value: "Requester Name"
295
- - translation:
296
- key: "txt.integrations.magento.tickets.requester_website"
297
- title: "The label for the requester's website"
298
- value: "Requester Website"
299
- - translation:
300
- key: "txt.integrations.magento.tickets.subject"
301
- title: "Subject of the ticket"
302
- value: "Subject"
303
- - translation:
304
- key: "txt.integrations.magento.tickets.status"
305
- title: "Status of the ticket"
306
- value: "Status"
307
- - translation:
308
- key: "txt.integrations.magento.tickets.status_new"
309
- title: "New status of ticket"
310
- value: "New"
311
- - translation:
312
- key: "txt.integrations.magento.tickets.status_open"
313
- title: "Open status of ticket"
314
- value: "Open"
315
- - translation:
316
- key: "txt.integrations.magento.tickets.status_pending"
317
- title: "Pending status of ticket"
318
- value: "Pending"
319
- - translation:
320
- key: "txt.integrations.magento.tickets.status_on_hold"
321
- title: "On-hold status of ticket"
322
- value: "On-hold"
323
- - translation:
324
- key: "txt.integrations.magento.tickets.status_solved"
325
- title: "Solved status of ticket"
326
- value: "Solved"
327
- - translation:
328
- key: "txt.integrations.magento.tickets.type"
329
- title: "Type of the ticket"
330
- value: "Type"
331
- - translation:
332
- key: "txt.integrations.magento.tickets.type_problem"
333
- title: "Problem type of ticket"
334
- value: "Problem"
335
- - translation:
336
- key: "txt.integrations.magento.tickets.type_incident"
337
- title: "Incident type of ticket"
338
- value: "Incident"
339
- - translation:
340
- key: "txt.integrations.magento.tickets.type_question"
341
- title: "Question type of ticket"
342
- value: "Question"
343
- - translation:
344
- key: "txt.integrations.magento.tickets.type_task"
345
- title: "Task type of ticket"
346
- value: "Task"
347
- - translation:
348
- key: "txt.integrations.magento.tickets.order_number"
349
- title: "Label for order number field"
350
- value: "Order number"
351
- - translation:
352
- key: "txt.integrations.magento.tickets.description"
353
- title: "Label for the description of a ticket"
354
- value: "Description"
355
- - translation:
356
- key: "txt.integrations.magento.tickets.update"
357
- title: "When a ticket was last updated"
358
- value: "Updated"
359
- - translation:
360
- key: "txt.integrations.magento.tickets.ticket_created"
361
- title: "Ticket # %s Created"
362
- value: "Ticket #%s Created"
363
-
364
- # Log Viewer
365
- - translation:
366
- key: "txt.integrations.magento.log_viewer.title"
367
- title: "Log viewer page title"
368
- value: "Zendesk Log Viewer"
369
- - translation:
370
- key: "txt.integrations.magento.log_viewer.clear_confirmation"
371
- title: "Confirmation message for clearing the log file"
372
- value: "Are you sure you want to clear the entire Zendesk log?"
373
- - translation:
374
- key: "txt.integrations.magento.log_viewer.message.no_file"
375
- title: "Error message if log file does not exist"
376
- value: "The Zendesk log file has not been created. Check to see if logging has been enabled."
377
- - translation:
378
- key: "txt.integrations.magento.log_viewer.message.file_too_large"
379
- title: "Warning message shown if log file is too large to show all of it on screen"
380
- value: "File size too large - only showing the last %s lines. Click Download to retrieve the entire file."
381
-
382
- # General
383
- - translation:
384
- key: "txt.integrations.magento.general.dashboard"
385
- title: "Display the dashboard"
386
- value: "Dashboard"
387
- - translation:
388
- key: "txt.integrations.magento.general.settings"
389
- title: "Display the settings for the Zendesk extension"
390
- value: "Settings"
391
- - translation:
392
- key: "txt.integrations.magento.general.no_views_selected"
393
- title: "No views have been selected to display. Please select one or more from the settings page."
394
- value: "No views selected. Please select one or more from the settings page."
395
- - translation:
396
- key: "txt.integrations.magento.general.launch"
397
- title: "Open Zendesk"
398
- value: "Launch Zendesk"
399
- - translation:
400
- key: "txt.integrations.magento.general.sso_token_not_set"
401
- title: "Zendesk SSO token has not been set. Please add this to the settings page"
402
- value: "Zendesk SSO token not been set. Please add this to the settings page."
403
- - translation:
404
- key: "txt.integrations.magento.general.domain_not_set"
405
- title: "Zendesk domain has not set. Please add this to the settings page"
406
- value: "Zendesk domain not set. Please add this to the settings page."
407
- - translation:
408
- key: "txt.integrations.magento.general.view_ticket_in_zendesk"
409
- title: "View the ticket in Zendesk"
410
- value: "View ticket in Zendesk"
411
- - translation:
412
- key: "txt.integrations.magento.general.view_all_tickets"
413
- title: "View all the tickets"
414
- value: "View All Tickets"
415
- - translation:
416
- key: "txt.integrations.magento.general.support_tickets"
417
- title: "Title for a section display support tickets"
418
- value: "Support Tickets"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
package.xml CHANGED
@@ -1,12 +1,27 @@
1
  <?xml version="1.0"?>
2
- <package><name>Zendesk</name><version>2.1.4</version><stability>stable</stability><license>Apache Software License v2</license><channel>community</channel><extends></extends><summary>Zendesk helps deliver the best customer support to your customers.</summary><description>
3
- &lt;strong&gt;&lt;a href="https://www.zendesk.com/?utm_source=magento&amp;amp;utm_medium=appstore&amp;amp;utm_campaign=profile"&gt;Zendesk&lt;/a&gt;&lt;/strong&gt; is the market leader of smart, agile and convenient cloud-based customer support software. For growing organizations, Zendesk is the fastest way to enable great customer service.&lt;br /&gt;&lt;br /&gt;
4
- This extension makes Zendesk work seamlessly with Magento to enable stores to deliver great customer support. &lt;br /&gt;&lt;br /&gt;
5
-
6
- &lt;strong&gt;Features include:&lt;/strong&gt;&lt;br /&gt;
7
- - Enable Single Sign-on with Zendesk&lt;br /&gt;
8
- - Create support tickets without leaving Magento&lt;br /&gt;
9
- - Display relevant support tickets on order &amp; customer dashboards&lt;br /&gt;
10
- - Create support tickets from Contact Us requests&lt;br /&gt;
11
- - Easily add the Web Widget to your site
12
- </description><notes>Fix Setup Guide for sites with store codes enabled.</notes><authors><author><name>Jason Smale</name><user>zendesk</user><email>jsmale@zendesk.com</email></author><author><name>Fontis</name><user>fontis</user><email>magento@fontis.com.au</email></author></authors><date>2016-03-27</date><time>22:49:45</time><compatible></compatible><dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies><contents><target name="mage"><dir name="app"><dir name="code"><dir name="community"><dir name="Zendesk"><dir name="Zendesk"><file name="LICENSE.txt" hash="d9922043f61f536de5d4d7af831e7f73"/><dir name="Block"><file name="WebWidget.php" hash="292d16516b754c0ff0609ac3a8b8e5d2"/><dir name="Adminhtml"><file name="Dashboard.php" hash="330e44b755b2eacf218e4c23210dd709"/><file name="Log.php" hash="da85421d71f2e50c1ef2384eedd5688a"/><file name="Menu.php" hash="0f6a56232356c46cd1da31c910985d3b"/><dir name="Config"><file name="Link.php" hash="779827427e11db311b6e1de9d42818f2"/><dir name="Buttons"><file name="Generate.php" hash="7fa35e3e71b4bfb94f2dceddb19e86a0"/><file name="MagentoTest.php" hash="005323c12510f8ac07b46bede8df6349"/><file name="Signup.php" hash="60e3366256ab111e132b853aa6a4ea52"/><file name="Sync.php" hash="d561b6fcbf69d284e866113e7d9afd44"/><file name="ZendeskTest.php" hash="83b67b5e66f8a9757ec424a72121133c"/></dir></dir><dir name="Create"><file name="Customer.php" hash="afe5c04c6ac7aa0cfaefded4ceacef37"/><file name="Edit.php" hash="fae5df1b1f5c5f524257bdf31bd569b4"/><file name="Order.php" hash="857150ae3de0e3ded29ff972732060b3"/><dir name="Customer"><file name="Grid.php" hash="d5da59c8bd8f939a578d776648a1920c"/><dir name="Grid"><dir name="Renderer"><file name="Action.php" hash="4c599ec0b7210b32733318ca40b403f1"/></dir></dir></dir><dir name="Edit"><file name="Form.php" hash="c94acf32924a5140edeef7eae238aa4e"/></dir><dir name="Order"><file name="Grid.php" hash="0e4f085158ce9cc9d3566411b80d4592"/><dir name="Grid"><dir name="Renderer"><file name="Action.php" hash="7e9aa2cbd5600865fc77ce35fd6cb73a"/></dir></dir></dir></dir><dir name="Dashboard"><file name="Grids.php" hash="1489d6addfdad17f23bfd34ccaaeb809"/><dir name="Tab"><dir name="Tickets"><dir name="Grid"><file name="Abstract.php" hash="b9cbb0629a4970e39539893869a3cfd2"/><file name="All.php" hash="27a968cc57b9514de3bb9d60e1fda068"/><file name="Massaction.php" hash="9d3ba44e00b40f4585e167c200b4bfa6"/><file name="View.php" hash="5b5320a258e838e680bfbde6a8491d88"/><dir name="Renderer"><file name="Action.php" hash="53a3b787e3f473a86bd896a0f8d7992e"/><file name="Group.php" hash="814178c8eabb9d8444d2beadd1c07a84"/><file name="Type.php" hash="4f0cd9a88be44fbe7faa4e1f1ba55a38"/><file name="User.php" hash="ce383119807c67b55892d404afc2d21c"/></dir></dir></dir></dir></dir><dir name="Order"><dir name="View"><file name="Tickets.php" hash="a83a2ad42801ddbddad2d761779a597b"/></dir></dir></dir><dir name="Customer"><file name="Tickets.php" hash="6338ed7954be81569c5e6f7f13eeb811"/><dir name="Tickets"><file name="List.php" hash="eddae13553494e6689ba1736896327a7"/></dir></dir></dir><dir name="controllers"><file name="ApiController.php" hash="84672fb7c6110ebadb9414e9c99ddfd0"/><file name="IndexController.php" hash="f2caa943c4619d5add2149ef26443108"/><file name="SsoController.php" hash="2b99171f2c81573405d2258df835fa26"/><dir name="Adminhtml"><file name="ZendeskController.php" hash="3b8665b1bd1085110644b59ced48e0a3"/></dir><dir name="Customer"><file name="TicketsController.php" hash="89164100a9640def75e94345e0fe1a14"/></dir></dir><dir name="data"><dir name="zendesk_setup"><file name="data-upgrade-1.3.0-1.4.0.php" hash="bcf2b209ab108ed2fc045176262d35ad"/><file name="data-upgrade-1.3.1-1.4.0.php" hash="bcf2b209ab108ed2fc045176262d35ad"/><file name="data-upgrade-1.4.2-2.0.0.php" hash="2b8f26c843de7435cc2bc53ad9e5cdb9"/><file name="data-upgrade-2.0.5-2.0.6.php" hash="da5a78a75da35ec27e4cbea9704c9f36"/></dir></dir><dir name="etc"><file name="config.xml" hash="5d303a9bcba264f07ccfa1bdc4d6347a"/><file name="jstranslator.xml" hash="3f3bd74e4b6484613126a2b2f7e34aac"/><file name="system.xml" hash="2f37034472542a19e7fa67e37bb05da4"/></dir><dir name="Helper"><file name="Data.php" hash="813ca2e4af8b35bbb985dda481a38d52"/><file name="JWT.php" hash="6610b92191eccedb8edcf993730c3dc0"/><file name="Log.php" hash="358c44a7a478dc6166208eb59ccd53fb"/></dir><dir name="lib"><file name="functions.php" hash="b6376678adc0a336dc56ede8bc2ec60b"/></dir><dir name="Model"><file name="Observer.php" hash="8097cbd3fcd0352b1b317a55d97f5804"/><file name="Search.php" hash="cac21f222a240bab7ea813023c4523f0"/><file name="Tickets.php" hash="796782889d46c6bc658f3cd03ee74a1c"/><dir name="Api"><file name="Abstract.php" hash="e5abe46841988dff2fb77ea9f9b71f18"/><file name="Groups.php" hash="7c2694b292399083c8209d297a1e6746"/><file name="Requesters.php" hash="9ffa79d849543c3dd5dc282b5ea80ccf"/><file name="SupportAddresses.php" hash="819b2e43055e97c58d80ab867c305db3"/><file name="Tickets.php" hash="718815ad0a159e4c05c2b154f5a1dc91"/><file name="Users.php" hash="89ade09084a1a6291af5e80bd57c66b1"/><file name="Views.php" hash="eb978152b36c63040b65cbca5f85bb52"/></dir><dir name="Resource"><file name="Tickets.php" hash="8eed34a07f8d65e3680ba3e735a3a4a1"/><dir name="Tickets"><file name="Collection.php" hash="1eae1969bfd0ac305b90bc55ce03fe19"/></dir></dir><dir name="Search"><file name="Field.php" hash="2961022121af96a4bc599141d82e6732"/></dir><dir name="Source"><file name="Sortdir.php" hash="916a3319d52661df8a77438935bae56f"/><file name="Sortorder.php" hash="1c58234e5253987027c174aa192a2b5f"/><file name="Views.php" hash="1c7527338bf40082016a62e45fe44622"/></dir></dir></dir></dir></dir></dir><dir name="design"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="zendesk.xml" hash="b824f0f7099d22a7f1c0a31d83cd9efc"/></dir><dir name="template"><dir name="zendesk"><file name="autocomplete.phtml" hash="01f42e0bbe3337c058ebc0a8832ddca9"/><file name="left-menu.phtml" hash="167b660cb9e7f0bf9fadfbd15a950c42"/><file name="translations.phtml" hash="663af777fa809b84ea9001afa740109f"/><dir name="config"><file name="button-generate.phtml" hash="21a25898c1fdea93d31b02ae91c1dd6f"/><file name="button-signup.phtml" hash="8871a0aa0bad7f85a7419853db8e0ce4"/><file name="button-sync.phtml" hash="0a79ffa3cb7021e2883844d37133af3e"/><file name="button-test-magento.phtml" hash="e86287ab32a2ee29ce44aad62249bcab"/><file name="button-test-zendesk.phtml" hash="1c8b000905f5a7221a04b46c6f0e9d42"/><file name="link.phtml" hash="ce55d65900113183e770b2905a31b0eb"/></dir><dir name="create"><file name="customer.phtml" hash="4195705109186f619780613f31d3799d"/><file name="order.phtml" hash="6565383d06a6428ce91238d90a1a0a1a"/></dir><dir name="customer"><file name="tickets.phtml" hash="8e0ecab043f1f988a51e57f848c51348"/></dir><dir name="dashboard"><file name="empty.phtml" hash="d0c30af25f17ff45215d210b48063a46"/><file name="index.phtml" hash="a09f9036123888914d347e99312f4039"/></dir><dir name="log"><file name="index.phtml" hash="c54c187ce5f09da6f56078cbfdf3ca29"/></dir><dir name="order"><file name="tickets.phtml" hash="4fe433f11c40708b0eb56aef5b0ce663"/></dir><dir name="tickets"><file name="tickets.phtml" hash="fc60966507ec30a2521413cb9b998770"/></dir><dir name="widget"><file name="grid.phtml" hash="5e7beb2c7e37c9efe225ea3e80f1ffd7"/></dir></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="zendesk.xml" hash="09058ecabaf99b91c7a57e12c74b0b0d"/></dir><dir name="template"><dir name="zendesk"><dir name="customer"><file name="tickets.phtml" hash="1a33c2429f13b16a98225b43e345ac37"/><dir name="tickets"><file name="list.phtml" hash="70faead25efe6e55d4e45d0923ba55e2"/></dir></dir></dir></dir></dir></dir></dir></dir><dir name="etc"><dir name="modules"><file name="Zendesk_Zendesk.xml" hash="a630cf18c788dafb70d4c156a33eaa07"/></dir></dir><dir name="locale"><dir name="da_DA"><file name="Zendesk_Zendesk.csv" hash="7c20868dcfedb4be3d4c3acd688d0572"/></dir><dir name="de_DE"><file name="Zendesk_Zendesk.csv" hash="3892feb95f2173d3f934fe964708b75b"/></dir><dir name="en_CA"><file name="Zendesk_Zendesk.csv" hash="96f26f9fa0b6060ec5e47ceb5bfee923"/></dir><dir name="en_GB"><file name="Zendesk_Zendesk.csv" hash="6d38497b88ad5da6d2eafa6a7677fd1a"/></dir><dir name="en_US"><file name="Zendesk_Zendesk.csv" hash="3095edc19fafe1d9bc88166857986b79"/><file name="Zendesk_Zendesk.yml" hash="10000438bbffe5cd5c9e6aad1ee836b2"/></dir><dir name="es_419"><file name="Zendesk_Zendesk.csv" hash="59edae01cec3de6fd62228f391222529"/></dir><dir name="es_ES"><file name="Zendesk_Zendesk.csv" hash="a0c3268b8136b65ee5a5a961212323c0"/></dir><dir name="fr_CA"><file name="Zendesk_Zendesk.csv" hash="e8fba8cc289173cec7db70a527cd5ceb"/></dir><dir name="fr_FR"><file name="Zendesk_Zendesk.csv" hash="7a7609df060c812fb3c30c935b157a75"/></dir><dir name="it_IT"><file name="Zendesk_Zendesk.csv" hash="64de62c856de4c83a69dac292c2f04a7"/></dir><dir name="ja_JA"><file name="Zendesk_Zendesk.csv" hash="d0b39c43faa0a858cf89602d6424d652"/></dir><dir name="ja_JP"><file name="Zendesk_Zendesk.csv" hash="8d0ab1a39457a8ba2dcf986faf4eb742"/></dir><dir name="ko_KO"><file name="Zendesk_Zendesk.csv" hash="46a5072434274f035a34272c5fbf5042"/></dir><dir name="ko_KR"><file name="Zendesk_Zendesk.csv" hash="38aee57e5520d82f607999ce25ba5dc2"/></dir><dir name="nl_NL"><file name="Zendesk_Zendesk.csv" hash="985790d52273a6127c9e941dacc6a25d"/></dir><dir name="no_NO"><file name="Zendesk_Zendesk.csv" hash="455b220ca4d9a2362f78855032ad2482"/></dir><dir name="pt_BR"><file name="Zendesk_Zendesk.csv" hash="90568149b111a18cc7db9debf82f9dfc"/></dir><dir name="pt_PT"><file name="Zendesk_Zendesk.csv" hash="ab137db1555f19a61cfffef603bed878"/></dir><dir name="ru_RU"><file name="Zendesk_Zendesk.csv" hash="534791f7ae25eb537b9fa5c2be70d2d3"/></dir><dir name="sv_SV"><file name="Zendesk_Zendesk.csv" hash="7e0b337874ff0352c1020c56a0649b62"/></dir><dir name="tr_TR"><file name="Zendesk_Zendesk.csv" hash="a0c73068b30d7c1ab4f3100123415249"/></dir><dir name="uk_UK"><file name="Zendesk_Zendesk.csv" hash="cc4e4541ff307b51be5a089e6c5e0f38"/></dir><dir name="zh_CN"><file name="Zendesk_Zendesk.csv" hash="c8bfa3b4398c99ec8fd498b1635be1db"/></dir><dir name="zh_TW"><file name="Zendesk_Zendesk.csv" hash="2fff120a9ee211608f505400b60c733f"/></dir></dir></dir><dir name="js"><dir name="zendesk"><file name="validation.js" hash="488b2fe21b2d34ce0814815e745771a0"/></dir></dir><dir name="skin"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="zendesk"><file name="button.png" hash="58e62edb7f4be46e3b29c0bb774c7ad7"/><file name="icon.png" hash="b5bfce535c987d1e9e604823ac4b3943"/><file name="zendesk-logo.png" hash="ad03156afe04a9dcc8fbf82e1913ac23"/><file name="zendesk-tab.png" hash="0f322d15c392528c212d6491732bc133"/><file name="zendesk.css" hash="b5db959c683981f11b9a83c8787fa461"/></dir></dir></dir></dir></dir></target></contents></package>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  <?xml version="1.0"?>
2
+ <package>
3
+ <name>Zendesk</name>
4
+ <version>2.1.7</version>
5
+ <stability>stable</stability>
6
+ <license>Apache Software License</license>
7
+ <channel>community</channel>
8
+ <extends/>
9
+ <summary>Zendesk helps deliver the best customer support to your customers.</summary>
10
+ <description>&lt;strong&gt;&lt;a href="https://www.zendesk.com/?utm_source=magento&amp;utm_medium=appstore&amp;utm_campaign=profile"&gt;Zendesk&lt;/a&gt;&lt;/strong&gt; is the market leader of smart, agile and convenient cloud-based customer support software. For growing organizations, Zendesk is the fastest way to enable great customer service.&lt;br /&gt;&lt;br /&gt;&#xD;
11
+ &#xD;
12
+ This extension makes Zendesk work seamlessly with Magento to enable stores to deliver great customer support. &lt;br /&gt;&lt;br /&gt;&#xD;
13
+ &#xD;
14
+ &lt;strong&gt;Features include:&lt;/strong&gt;&lt;br /&gt;&#xD;
15
+ - Enable Single Sign-on for Magento administrators&lt;br /&gt;&#xD;
16
+ - Create support tickets without leaving Magento&lt;br /&gt;&#xD;
17
+ - Display relevant support tickets on order &amp; customer dashboards&lt;br /&gt;&#xD;
18
+ - Create support tickets from Contact Us requests&lt;br /&gt;&#xD;
19
+ - Easily add the Web Widget to your site</description>
20
+ <notes>Add logging for exception on customer ticket fetch.</notes>
21
+ <authors><author><name>Zendesk</name><user>MAG001580855</user><email>dev.manila@zendesk.com</email></author><author><name>Fontis</name><user>fontis</user><email>magento@fontis.com.au</email></author></authors>
22
+ <date>2016-09-20</date>
23
+ <time>04:10:02</time>
24
+ <contents><target name="magecommunity"><dir name="Zendesk"><dir name="Zendesk"><dir name="Block"><dir name="Adminhtml"><dir name="Config"><dir name="Buttons"><file name="Generate.php" hash="7fa35e3e71b4bfb94f2dceddb19e86a0"/><file name="MagentoTest.php" hash="005323c12510f8ac07b46bede8df6349"/><file name="Signup.php" hash="60e3366256ab111e132b853aa6a4ea52"/><file name="Sync.php" hash="d561b6fcbf69d284e866113e7d9afd44"/><file name="ZendeskTest.php" hash="83b67b5e66f8a9757ec424a72121133c"/></dir><file name="Link.php" hash="779827427e11db311b6e1de9d42818f2"/></dir><dir name="Create"><dir name="Customer"><dir name="Grid"><dir name="Renderer"><file name="Action.php" hash="4c599ec0b7210b32733318ca40b403f1"/></dir></dir><file name="Grid.php" hash="d5da59c8bd8f939a578d776648a1920c"/></dir><file name="Customer.php" hash="afe5c04c6ac7aa0cfaefded4ceacef37"/><dir name="Edit"><file name="Form.php" hash="c94acf32924a5140edeef7eae238aa4e"/></dir><file name="Edit.php" hash="fae5df1b1f5c5f524257bdf31bd569b4"/><dir name="Order"><dir name="Grid"><dir name="Renderer"><file name="Action.php" hash="7e9aa2cbd5600865fc77ce35fd6cb73a"/></dir></dir><file name="Grid.php" hash="0e4f085158ce9cc9d3566411b80d4592"/></dir><file name="Order.php" hash="857150ae3de0e3ded29ff972732060b3"/></dir><dir name="Dashboard"><file name="Grids.php" hash="1489d6addfdad17f23bfd34ccaaeb809"/><dir name="Tab"><dir name="Tickets"><dir name="Grid"><file name="Abstract.php" hash="b9cbb0629a4970e39539893869a3cfd2"/><file name="All.php" hash="27a968cc57b9514de3bb9d60e1fda068"/><file name="Massaction.php" hash="9d3ba44e00b40f4585e167c200b4bfa6"/><dir name="Renderer"><file name="Action.php" hash="53a3b787e3f473a86bd896a0f8d7992e"/><file name="Group.php" hash="814178c8eabb9d8444d2beadd1c07a84"/><file name="Type.php" hash="4f0cd9a88be44fbe7faa4e1f1ba55a38"/><file name="User.php" hash="ce383119807c67b55892d404afc2d21c"/></dir><file name="View.php" hash="5b5320a258e838e680bfbde6a8491d88"/></dir></dir></dir></dir><file name="Dashboard.php" hash="330e44b755b2eacf218e4c23210dd709"/><file name="Log.php" hash="da85421d71f2e50c1ef2384eedd5688a"/><file name="Menu.php" hash="0f6a56232356c46cd1da31c910985d3b"/><dir name="Order"><dir name="View"><file name="Tickets.php" hash="a83a2ad42801ddbddad2d761779a597b"/></dir></dir></dir><dir name="Customer"><dir name="Tickets"><file name="List.php" hash="eddae13553494e6689ba1736896327a7"/></dir><file name="Tickets.php" hash="6338ed7954be81569c5e6f7f13eeb811"/></dir><file name="WebWidget.php" hash="292d16516b754c0ff0609ac3a8b8e5d2"/></dir><dir name="Helper"><file name="Data.php" hash="813ca2e4af8b35bbb985dda481a38d52"/><file name="JWT.php" hash="6610b92191eccedb8edcf993730c3dc0"/><file name="Log.php" hash="358c44a7a478dc6166208eb59ccd53fb"/><dir name="_"><file name="Data.php" hash="813ca2e4af8b35bbb985dda481a38d52"/><file name="JWT.php" hash="6610b92191eccedb8edcf993730c3dc0"/><file name="Log.php" hash="358c44a7a478dc6166208eb59ccd53fb"/></dir><file name=".gitignore" hash="0c0ef7b9a3271d2fbfa0aca4d0bb61eb"/></dir><file name="LICENSE.txt" hash="d9922043f61f536de5d4d7af831e7f73"/><dir name="Model"><dir name="Api"><file name="Abstract.php" hash="e5abe46841988dff2fb77ea9f9b71f18"/><file name="Groups.php" hash="7c2694b292399083c8209d297a1e6746"/><file name="Requesters.php" hash="9ffa79d849543c3dd5dc282b5ea80ccf"/><file name="SupportAddresses.php" hash="819b2e43055e97c58d80ab867c305db3"/><file name="Tickets.php" hash="dfd005b60e8a81ac95ff9cb151f32569"/><file name="Users.php" hash="89ade09084a1a6291af5e80bd57c66b1"/><file name="Views.php" hash="eb978152b36c63040b65cbca5f85bb52"/></dir><file name="Observer.php" hash="edddb8502a8e8e3a4bcac856d84bd561"/><dir name="Resource"><dir name="Tickets"><file name="Collection.php" hash="1eae1969bfd0ac305b90bc55ce03fe19"/></dir><file name="Tickets.php" hash="8eed34a07f8d65e3680ba3e735a3a4a1"/></dir><dir name="Search"><file name="Field.php" hash="2961022121af96a4bc599141d82e6732"/></dir><file name="Search.php" hash="cac21f222a240bab7ea813023c4523f0"/><dir name="Source"><file name="Sortdir.php" hash="916a3319d52661df8a77438935bae56f"/><file name="Sortorder.php" hash="1c58234e5253987027c174aa192a2b5f"/><file name="Views.php" hash="1c7527338bf40082016a62e45fe44622"/></dir><file name="Tickets.php" hash="796782889d46c6bc658f3cd03ee74a1c"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="ZendeskController.php" hash="3b8665b1bd1085110644b59ced48e0a3"/></dir><file name="ApiController.php" hash="84672fb7c6110ebadb9414e9c99ddfd0"/><dir name="Customer"><file name="TicketsController.php" hash="89164100a9640def75e94345e0fe1a14"/></dir><file name="IndexController.php" hash="f2caa943c4619d5add2149ef26443108"/><file name="SsoController.php" hash="2b99171f2c81573405d2258df835fa26"/></dir><dir name="data"><dir name="zendesk_setup"><file name="data-upgrade-1.3.0-1.4.0.php" hash="bcf2b209ab108ed2fc045176262d35ad"/><file name="data-upgrade-1.3.1-1.4.0.php" hash="bcf2b209ab108ed2fc045176262d35ad"/><file name="data-upgrade-1.4.2-2.0.0.php" hash="2b8f26c843de7435cc2bc53ad9e5cdb9"/><file name="data-upgrade-2.0.5-2.0.6.php" hash="da5a78a75da35ec27e4cbea9704c9f36"/></dir></dir><dir name="etc"><file name="config.xml" hash="39291dc9f8af568dd53d8c3634d635b0"/><file name="jstranslator.xml" hash="3f3bd74e4b6484613126a2b2f7e34aac"/><file name="system.xml" hash="2f37034472542a19e7fa67e37bb05da4"/></dir><dir name="lib"><file name="functions.php" hash="b6376678adc0a336dc56ede8bc2ec60b"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="zendesk.xml" hash="09058ecabaf99b91c7a57e12c74b0b0d"/></dir><dir name="template"><dir name="zendesk"><dir name="customer"><dir name="tickets"><file name="list.phtml" hash="b11afac703cb07a25dc95ba4038862d5"/></dir><file name="tickets.phtml" hash="1a33c2429f13b16a98225b43e345ac37"/></dir></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="zendesk.xml" hash="b824f0f7099d22a7f1c0a31d83cd9efc"/></dir><dir name="template"><dir name="zendesk"><file name="autocomplete.phtml" hash="01f42e0bbe3337c058ebc0a8832ddca9"/><dir name="config"><file name="button-generate.phtml" hash="21a25898c1fdea93d31b02ae91c1dd6f"/><file name="button-signup.phtml" hash="8871a0aa0bad7f85a7419853db8e0ce4"/><file name="button-sync.phtml" hash="0a79ffa3cb7021e2883844d37133af3e"/><file name="button-test-magento.phtml" hash="e86287ab32a2ee29ce44aad62249bcab"/><file name="button-test-zendesk.phtml" hash="1c8b000905f5a7221a04b46c6f0e9d42"/><file name="link.phtml" hash="ce55d65900113183e770b2905a31b0eb"/></dir><dir name="create"><file name="customer.phtml" hash="4195705109186f619780613f31d3799d"/><file name="order.phtml" hash="6565383d06a6428ce91238d90a1a0a1a"/></dir><dir name="customer"><file name="tickets.phtml" hash="6a570b5a261ce6cb3117815dfb4ae389"/></dir><dir name="dashboard"><file name="empty.phtml" hash="d0c30af25f17ff45215d210b48063a46"/><file name="index.phtml" hash="a09f9036123888914d347e99312f4039"/></dir><file name="left-menu.phtml" hash="167b660cb9e7f0bf9fadfbd15a950c42"/><dir name="log"><file name="index.phtml" hash="c54c187ce5f09da6f56078cbfdf3ca29"/></dir><dir name="order"><file name="tickets.phtml" hash="4fe433f11c40708b0eb56aef5b0ce663"/></dir><dir name="tickets"><file name="tickets.phtml" hash="fc60966507ec30a2521413cb9b998770"/></dir><file name="translations.phtml" hash="663af777fa809b84ea9001afa740109f"/><dir name="widget"><file name="grid.phtml" hash="5e7beb2c7e37c9efe225ea3e80f1ffd7"/></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Zendesk_Zendesk.xml" hash="a630cf18c788dafb70d4c156a33eaa07"/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="zendesk"><file name="zendesk.css" hash="b5db959c683981f11b9a83c8787fa461"/><file name="button.png" hash="58e62edb7f4be46e3b29c0bb774c7ad7"/><file name="icon.png" hash="b5bfce535c987d1e9e604823ac4b3943"/><file name="zendesk-logo.png" hash="ad03156afe04a9dcc8fbf82e1913ac23"/><file name="zendesk-tab.png" hash="0f322d15c392528c212d6491732bc133"/><file name="zendesk.css" hash="b5db959c683981f11b9a83c8787fa461"/></dir></dir></dir></dir></target><target name="mage"><dir name="js"><dir name="zendesk"><file name="validation.js" hash="488b2fe21b2d34ce0814815e745771a0"/></dir></dir></target><target name="magelocale"><dir name="da_DA"><file name="Zendesk_Zendesk.csv" hash="7c20868dcfedb4be3d4c3acd688d0572"/></dir><dir name="de_DE"><file name="Zendesk_Zendesk.csv" hash="3892feb95f2173d3f934fe964708b75b"/></dir><dir name="en_CA"><file name="Zendesk_Zendesk.csv" hash="96f26f9fa0b6060ec5e47ceb5bfee923"/></dir><dir name="en_GB"><file name="Zendesk_Zendesk.csv" hash="6d38497b88ad5da6d2eafa6a7677fd1a"/></dir><dir name="en_US"><file name="Zendesk_Zendesk.csv" hash="3095edc19fafe1d9bc88166857986b79"/></dir><dir name="es_419"><file name="Zendesk_Zendesk.csv" hash="59edae01cec3de6fd62228f391222529"/></dir><dir name="es_ES"><file name="Zendesk_Zendesk.csv" hash="a0c3268b8136b65ee5a5a961212323c0"/></dir><dir name="fr_CA"><file name="Zendesk_Zendesk.csv" hash="e8fba8cc289173cec7db70a527cd5ceb"/></dir><dir name="fr_FR"><file name="Zendesk_Zendesk.csv" hash="7a7609df060c812fb3c30c935b157a75"/></dir><dir name="it_IT"><file name="Zendesk_Zendesk.csv" hash="64de62c856de4c83a69dac292c2f04a7"/></dir><dir name="ja_JA"><file name="Zendesk_Zendesk.csv" hash="d0b39c43faa0a858cf89602d6424d652"/></dir><dir name="ja_JP"><file name="Zendesk_Zendesk.csv" hash="8d0ab1a39457a8ba2dcf986faf4eb742"/></dir><dir name="ko_KO"><file name="Zendesk_Zendesk.csv" hash="46a5072434274f035a34272c5fbf5042"/></dir><dir name="ko_KR"><file name="Zendesk_Zendesk.csv" hash="38aee57e5520d82f607999ce25ba5dc2"/></dir><dir name="nl_NL"><file name="Zendesk_Zendesk.csv" hash="985790d52273a6127c9e941dacc6a25d"/></dir><dir name="no_NO"><file name="Zendesk_Zendesk.csv" hash="455b220ca4d9a2362f78855032ad2482"/></dir><dir name="pt_BR"><file name="Zendesk_Zendesk.csv" hash="90568149b111a18cc7db9debf82f9dfc"/></dir><dir name="pt_PT"><file name="Zendesk_Zendesk.csv" hash="ab137db1555f19a61cfffef603bed878"/></dir><dir name="ru_RU"><file name="Zendesk_Zendesk.csv" hash="534791f7ae25eb537b9fa5c2be70d2d3"/></dir><dir name="sv_SV"><file name="Zendesk_Zendesk.csv" hash="7e0b337874ff0352c1020c56a0649b62"/></dir><dir name="tr_TR"><file name="Zendesk_Zendesk.csv" hash="a0c73068b30d7c1ab4f3100123415249"/></dir><dir name="uk_UK"><file name="Zendesk_Zendesk.csv" hash="cc4e4541ff307b51be5a089e6c5e0f38"/></dir><dir name="zh_CN"><file name="Zendesk_Zendesk.csv" hash="c8bfa3b4398c99ec8fd498b1635be1db"/></dir><dir name="zh_TW"><file name="Zendesk_Zendesk.csv" hash="2fff120a9ee211608f505400b60c733f"/></dir></target></contents>
25
+ <compatible/>
26
+ <dependencies><required><php><min>5.2.0</min><max>6.0.0</max></php></required></dependencies>
27
+ </package>