Version Notes
Initial release
Download this release
Release Info
| Developer | Zoho SalesIQ |
| Extension | Zoho_SalesIQ |
| Version | 1.0.1 |
| Comparing to | |
| See all releases | |
Version 1.0.1
- app/code/community/Zoho/Salesiq/Block/Button.php +27 -0
- app/code/community/Zoho/Salesiq/Block/Salesiq.php +56 -0
- app/code/community/Zoho/Salesiq/Block/System/Config/Salesiq/Info.php +20 -0
- app/code/community/Zoho/Salesiq/Helper/Data.php +48 -0
- app/code/community/Zoho/Salesiq/Model/Salesiq.php +28 -0
- app/code/community/Zoho/Salesiq/controllers/IndexController.php +14 -0
- app/code/community/Zoho/Salesiq/etc/adminhtml.xml +31 -0
- app/code/community/Zoho/Salesiq/etc/config.xml +81 -0
- app/code/community/Zoho/Salesiq/etc/system.xml +86 -0
- app/design/frontend/base/default/layout/salesiq.xml +26 -0
- app/design/frontend/base/default/template/salesiq/button.phtml +22 -0
- app/etc/modules/Zoho_Salesiq.xml +18 -0
- package.xml +43 -0
app/code/community/Zoho/Salesiq/Block/Button.php
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @category Zoho
|
| 4 |
+
* @package Zoho_Salesiq
|
| 5 |
+
* @author SalesIQ Team
|
| 6 |
+
* @website http://www.zoho.com/salesiq
|
| 7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 8 |
+
*/
|
| 9 |
+
class Zoho_Salesiq_Block_Button extends Mage_Core_Block_Template {
|
| 10 |
+
|
| 11 |
+
public function getQuestion() {
|
| 12 |
+
$question = 'Hi, I need to know more about ';
|
| 13 |
+
$question .= $this->helper('catalog/data')->getProduct()->getName();
|
| 14 |
+
$question .= ' (';
|
| 15 |
+
$question .= $this->helper('core/url')->getCurrentUrl();
|
| 16 |
+
$question .= ')';
|
| 17 |
+
return htmlspecialchars(json_encode($question));
|
| 18 |
+
}
|
| 19 |
+
|
| 20 |
+
public function getLabel() {
|
| 21 |
+
return $this->__('Click here to chat');
|
| 22 |
+
}
|
| 23 |
+
|
| 24 |
+
public function isQuickChatEnabled() {
|
| 25 |
+
return $this->helper('salesiq')->isQuickChatEnabled();
|
| 26 |
+
}
|
| 27 |
+
}
|
app/code/community/Zoho/Salesiq/Block/Salesiq.php
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @category Zoho
|
| 4 |
+
* @package Zoho_Salesiq
|
| 5 |
+
* @author SalesIQ Team
|
| 6 |
+
* @website http://www.zoho.com/salesiq
|
| 7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 8 |
+
*/
|
| 9 |
+
class Zoho_Salesiq_Block_Salesiq extends Mage_Core_Block_Template {
|
| 10 |
+
|
| 11 |
+
protected function _toHtml() {
|
| 12 |
+
$helper = Mage::helper('salesiq');
|
| 13 |
+
$includedPages = $helper->getIncludedPages();
|
| 14 |
+
$currentPage = Mage::app()->getFrontController()->getAction()->getFullActionName();
|
| 15 |
+
|
| 16 |
+
// If chat window option is enabled, include the widget code only if
|
| 17 |
+
// "All Pages" or the current page is configured in settings.
|
| 18 |
+
if ($helper->isChatWindowEnabled()
|
| 19 |
+
&& (in_array('all_pages', $includedPages)
|
| 20 |
+
|| in_array($currentPage, $includedPages))) {
|
| 21 |
+
return $this->_getWidgetCode($helper);
|
| 22 |
+
}
|
| 23 |
+
|
| 24 |
+
// If chat window is not enabled, but the Quick chat option is enabled
|
| 25 |
+
// and the current page is Product page, then include the widget code
|
| 26 |
+
// but hide the float button and window so that they are shown only if
|
| 27 |
+
// the Quick Chat button is clicked.
|
| 28 |
+
if ($currentPage == 'catalog_product_view'
|
| 29 |
+
&& $helper->isQuickChatEnabled()) {
|
| 30 |
+
$extra = '$zs.floatbutton.visible("hide");
|
| 31 |
+
$zs.floatwindow.visible("hide");';
|
| 32 |
+
return $this->_getWidgetCode($helper, $extra);
|
| 33 |
+
}
|
| 34 |
+
}
|
| 35 |
+
|
| 36 |
+
protected function _getName() {
|
| 37 |
+
return trim($this->helper('customer/data')->getCustomer()->getName());
|
| 38 |
+
}
|
| 39 |
+
|
| 40 |
+
protected function _getEmail() {
|
| 41 |
+
return trim($this->helper('customer/data')->getCustomer()->getEmail());
|
| 42 |
+
}
|
| 43 |
+
|
| 44 |
+
protected function _getWidgetCode($helper, $extra="") {
|
| 45 |
+
$code = $helper->getWidgetCode();
|
| 46 |
+
$code .= '<script>';
|
| 47 |
+
$code .= 'var $zs = $zoho.salesiq || $zoho.livedesk;';
|
| 48 |
+
$code .= '$zs.ready=function() {';
|
| 49 |
+
$code .= ' $zs.visitor.name("' . $this->_getName() . '");';
|
| 50 |
+
$code .= ' $zs.visitor.email("' . $this->_getEmail() . '");';
|
| 51 |
+
$code .= $extra;
|
| 52 |
+
$code .= '}</script>';
|
| 53 |
+
return $code;
|
| 54 |
+
}
|
| 55 |
+
|
| 56 |
+
}
|
app/code/community/Zoho/Salesiq/Block/System/Config/Salesiq/Info.php
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @category Zoho
|
| 4 |
+
* @package Zoho_Salesiq
|
| 5 |
+
* @author SalesIQ Team
|
| 6 |
+
* @website http://www.zoho.com/salesiq
|
| 7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 8 |
+
*/
|
| 9 |
+
class Zoho_Salesiq_Block_System_Config_Salesiq_Info
|
| 10 |
+
extends Mage_Adminhtml_Block_Abstract
|
| 11 |
+
implements Varien_Data_Form_Element_Renderer_Interface {
|
| 12 |
+
|
| 13 |
+
public function render(Varien_Data_Form_Element_Abstract $element) {
|
| 14 |
+
$html = '<div style="border:1px solid #CCCCCC;margin-bottom:10px;padding:10px 10px 10px 10px;">
|
| 15 |
+
<h4>About Zoho SalesIQ</h4>
|
| 16 |
+
<p>Engage with your customers in real time. Chat and deliver unbeatable customer support. Convert more, grow faster.</p>
|
| 17 |
+
</div>';
|
| 18 |
+
return $html;
|
| 19 |
+
}
|
| 20 |
+
}
|
app/code/community/Zoho/Salesiq/Helper/Data.php
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @category Zoho
|
| 4 |
+
* @package Zoho_Salesiq
|
| 5 |
+
* @author SalesIQ Team
|
| 6 |
+
* @website http://www.zoho.com/salesiq
|
| 7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 8 |
+
*/
|
| 9 |
+
class Zoho_Salesiq_Helper_Data extends Mage_Core_Helper_Abstract {
|
| 10 |
+
|
| 11 |
+
public function getConfig($field, $section = 'option', $default = null) {
|
| 12 |
+
$value = Mage::getStoreConfig('salesiq/' . $section . '/' . $field);
|
| 13 |
+
if (!isset($value) or trim($value) == '') {
|
| 14 |
+
return $default;
|
| 15 |
+
} else {
|
| 16 |
+
return $value;
|
| 17 |
+
}
|
| 18 |
+
}
|
| 19 |
+
|
| 20 |
+
public function log($data) {
|
| 21 |
+
if (!$this->getConfig('enable_log')) {
|
| 22 |
+
return;
|
| 23 |
+
}
|
| 24 |
+
|
| 25 |
+
if (is_array($data) || is_object($data)) {
|
| 26 |
+
$data = print_r($data, true);
|
| 27 |
+
}
|
| 28 |
+
|
| 29 |
+
Mage::log($data, null, 'salesiq.log');
|
| 30 |
+
}
|
| 31 |
+
|
| 32 |
+
public function getWidgetcode() {
|
| 33 |
+
return $this->getConfig('widget_code');
|
| 34 |
+
}
|
| 35 |
+
|
| 36 |
+
public function isChatWindowEnabled() {
|
| 37 |
+
return $this->getConfig('chat_window');
|
| 38 |
+
}
|
| 39 |
+
|
| 40 |
+
public function getIncludedPages() {
|
| 41 |
+
return explode(',', $this->getConfig('include_in', 'option', 'all_pages'));
|
| 42 |
+
}
|
| 43 |
+
|
| 44 |
+
public function isQuickChatEnabled() {
|
| 45 |
+
return $this->getConfig('quick_chat_button');
|
| 46 |
+
}
|
| 47 |
+
|
| 48 |
+
}
|
app/code/community/Zoho/Salesiq/Model/Salesiq.php
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @category Zoho
|
| 4 |
+
* @package Zoho_Salesiq
|
| 5 |
+
* @author SalesIQ Team
|
| 6 |
+
* @website http://www.zoho.com/salesiq
|
| 7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 8 |
+
*/
|
| 9 |
+
class Zoho_Salesiq_Model_Salesiq extends Mage_Core_Model_Abstract {
|
| 10 |
+
|
| 11 |
+
/**
|
| 12 |
+
* Options getter
|
| 13 |
+
*
|
| 14 |
+
* @return array
|
| 15 |
+
*/
|
| 16 |
+
public function toOptionArray()
|
| 17 |
+
{
|
| 18 |
+
return array(
|
| 19 |
+
array('value' => 'all_pages', 'label'=>Mage::helper('salesiq')->__('All Pages')),
|
| 20 |
+
array('value' => 'cms_index_index', 'label'=>Mage::helper('salesiq')->__('Home Page')),
|
| 21 |
+
array('value' => 'catalog_category_view', 'label'=>Mage::helper('salesiq')->__('Category Pages')),
|
| 22 |
+
array('value' => 'catalog_product_view', 'label'=>Mage::helper('salesiq')->__('Product Pages')),
|
| 23 |
+
array('value' => 'checkout_cart_index', 'label'=>Mage::helper('salesiq')->__('My Cart')),
|
| 24 |
+
array('value' => 'checkout_onepage_index', 'label'=>Mage::helper('salesiq')->__('Checkout'))
|
| 25 |
+
);
|
| 26 |
+
}
|
| 27 |
+
|
| 28 |
+
}
|
app/code/community/Zoho/Salesiq/controllers/IndexController.php
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @category Zoho
|
| 4 |
+
* @package Zoho_Salesiq
|
| 5 |
+
* @author SalesIQ Team
|
| 6 |
+
* @website http://www.zoho.com/salesiq
|
| 7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 8 |
+
*/
|
| 9 |
+
class Zoho_Salesiq_IndexController extends Mage_Core_Controller_Front_Action {
|
| 10 |
+
|
| 11 |
+
public function indexAction() {
|
| 12 |
+
}
|
| 13 |
+
|
| 14 |
+
}
|
app/code/community/Zoho/Salesiq/etc/adminhtml.xml
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* @category Zoho
|
| 5 |
+
* @package Zoho_Salesiq
|
| 6 |
+
* @author SalesIQ Team
|
| 7 |
+
* @website http://www.zoho.com/salesiq
|
| 8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 9 |
+
*/
|
| 10 |
+
-->
|
| 11 |
+
<config>
|
| 12 |
+
<acl>
|
| 13 |
+
<resources>
|
| 14 |
+
<admin>
|
| 15 |
+
<children>
|
| 16 |
+
<system>
|
| 17 |
+
<children>
|
| 18 |
+
<config>
|
| 19 |
+
<children>
|
| 20 |
+
<salesiq>
|
| 21 |
+
<title>Zoho SalesIQ Section</title>
|
| 22 |
+
</salesiq>
|
| 23 |
+
</children>
|
| 24 |
+
</config>
|
| 25 |
+
</children>
|
| 26 |
+
</system>
|
| 27 |
+
</children>
|
| 28 |
+
</admin>
|
| 29 |
+
</resources>
|
| 30 |
+
</acl>
|
| 31 |
+
</config>
|
app/code/community/Zoho/Salesiq/etc/config.xml
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* @category Zoho
|
| 5 |
+
* @package Zoho_Salesiq
|
| 6 |
+
* @author Salesiq Team
|
| 7 |
+
* @website http://www.zoho.com/salesiq
|
| 8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 9 |
+
*/
|
| 10 |
+
-->
|
| 11 |
+
<config>
|
| 12 |
+
<modules>
|
| 13 |
+
<Zoho_Salesiq>
|
| 14 |
+
<version>0.1.0</version>
|
| 15 |
+
</Zoho_Salesiq>
|
| 16 |
+
</modules>
|
| 17 |
+
<global>
|
| 18 |
+
<models>
|
| 19 |
+
<salesiq>
|
| 20 |
+
<class>Zoho_Salesiq_Model</class>
|
| 21 |
+
</salesiq>
|
| 22 |
+
</models>
|
| 23 |
+
<blocks>
|
| 24 |
+
<salesiq>
|
| 25 |
+
<class>Zoho_Salesiq_Block</class>
|
| 26 |
+
</salesiq>
|
| 27 |
+
</blocks>
|
| 28 |
+
<helpers>
|
| 29 |
+
<salesiq>
|
| 30 |
+
<class>Zoho_Salesiq_Helper</class>
|
| 31 |
+
</salesiq>
|
| 32 |
+
</helpers>
|
| 33 |
+
</global>
|
| 34 |
+
<frontend>
|
| 35 |
+
<routers>
|
| 36 |
+
<salesiq>
|
| 37 |
+
<use>standard</use>
|
| 38 |
+
<args>
|
| 39 |
+
<module>Zoho_Salesiq</module>
|
| 40 |
+
<frontName>salesiq</frontName>
|
| 41 |
+
</args>
|
| 42 |
+
</salesiq>
|
| 43 |
+
</routers>
|
| 44 |
+
<layout>
|
| 45 |
+
<updates>
|
| 46 |
+
<salesiq>
|
| 47 |
+
<file>salesiq.xml</file>
|
| 48 |
+
</salesiq>
|
| 49 |
+
</updates>
|
| 50 |
+
</layout>
|
| 51 |
+
</frontend>
|
| 52 |
+
<adminhtml>
|
| 53 |
+
<acl>
|
| 54 |
+
<resources>
|
| 55 |
+
<admin>
|
| 56 |
+
<children>
|
| 57 |
+
<system>
|
| 58 |
+
<children>
|
| 59 |
+
<config>
|
| 60 |
+
<children>
|
| 61 |
+
<salesiq>
|
| 62 |
+
<title>Zoho SalesIQ Section</title>
|
| 63 |
+
</salesiq>
|
| 64 |
+
</children>
|
| 65 |
+
</config>
|
| 66 |
+
</children>
|
| 67 |
+
</system>
|
| 68 |
+
</children>
|
| 69 |
+
</admin>
|
| 70 |
+
</resources>
|
| 71 |
+
</acl>
|
| 72 |
+
</adminhtml>
|
| 73 |
+
<default>
|
| 74 |
+
<salesiq>
|
| 75 |
+
<option>
|
| 76 |
+
<active>1</active>
|
| 77 |
+
<enable_log>1</enable_log>
|
| 78 |
+
</option>
|
| 79 |
+
</salesiq>
|
| 80 |
+
</default>
|
| 81 |
+
</config>
|
app/code/community/Zoho/Salesiq/etc/system.xml
ADDED
|
@@ -0,0 +1,86 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* @category Zoho
|
| 5 |
+
* @package Zoho_Salesiq
|
| 6 |
+
* @author SalesIQ Team
|
| 7 |
+
* @website http://www.zoho.com/salesiq
|
| 8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 9 |
+
*/
|
| 10 |
+
-->
|
| 11 |
+
<config>
|
| 12 |
+
<tabs>
|
| 13 |
+
<zohoall translate="label" module="salesiq">
|
| 14 |
+
<label>Zoho Extensions</label>
|
| 15 |
+
<sort_order>400</sort_order>
|
| 16 |
+
</zohoall>
|
| 17 |
+
</tabs>
|
| 18 |
+
<sections>
|
| 19 |
+
<salesiq module="salesiq">
|
| 20 |
+
<label>Zoho SalesIQ</label>
|
| 21 |
+
<tab>zohoall</tab>
|
| 22 |
+
<frontend_type>text</frontend_type>
|
| 23 |
+
<sort_order>1000</sort_order>
|
| 24 |
+
<show_in_default>1</show_in_default>
|
| 25 |
+
<show_in_website>1</show_in_website>
|
| 26 |
+
<show_in_store>1</show_in_store>
|
| 27 |
+
<groups>
|
| 28 |
+
<option translate="label">
|
| 29 |
+
<label>General Settings</label>
|
| 30 |
+
<frontend_type>text</frontend_type>
|
| 31 |
+
<sort_order>10</sort_order>
|
| 32 |
+
<show_in_default>1</show_in_default>
|
| 33 |
+
<show_in_website>1</show_in_website>
|
| 34 |
+
<show_in_store>1</show_in_store>
|
| 35 |
+
<fields>
|
| 36 |
+
<info>
|
| 37 |
+
<frontend_model>salesiq/system_config_salesiq_info</frontend_model>
|
| 38 |
+
<sort_order>0</sort_order>
|
| 39 |
+
<show_in_default>1</show_in_default>
|
| 40 |
+
<show_in_website>1</show_in_website>
|
| 41 |
+
<show_in_store>1</show_in_store>
|
| 42 |
+
</info>
|
| 43 |
+
<widget_code>
|
| 44 |
+
<label>Chat Widget Code</label>
|
| 45 |
+
<frontend_type>textarea</frontend_type>
|
| 46 |
+
<sort_order>10</sort_order>
|
| 47 |
+
<show_in_default>1</show_in_default>
|
| 48 |
+
<show_in_website>1</show_in_website>
|
| 49 |
+
<show_in_store>1</show_in_store>
|
| 50 |
+
<comment><![CDATA[<a href="https://salesiq.zoho.com/register.sas?source=Magento.config" target="_blank"><strong>Click here to sign up</strong></a> for Zoho SalesIQ and get the widget code]]></comment>
|
| 51 |
+
</widget_code>
|
| 52 |
+
<chat_window translate="label">
|
| 53 |
+
<label>Chat Window</label>
|
| 54 |
+
<frontend_type>select</frontend_type>
|
| 55 |
+
<source_model>adminhtml/system_config_source_enabledisable</source_model>
|
| 56 |
+
<sort_order>20</sort_order>
|
| 57 |
+
<show_in_default>1</show_in_default>
|
| 58 |
+
<show_in_website>1</show_in_website>
|
| 59 |
+
<show_in_store>1</show_in_store>
|
| 60 |
+
</chat_window>
|
| 61 |
+
<include_in>
|
| 62 |
+
<label>Include in</label>
|
| 63 |
+
<frontend_type>multiselect</frontend_type>
|
| 64 |
+
<source_model>salesiq/salesiq</source_model>
|
| 65 |
+
<sort_order>30</sort_order>
|
| 66 |
+
<show_in_default>1</show_in_default>
|
| 67 |
+
<show_in_website>1</show_in_website>
|
| 68 |
+
<show_in_store>1</show_in_store>
|
| 69 |
+
<comment><![CDATA[If <strong>All Pages</strong> is selected, the chat window is displayed throughout the site.]]></comment>
|
| 70 |
+
</include_in>
|
| 71 |
+
<quick_chat_button>
|
| 72 |
+
<label>Quick Chat Button</label>
|
| 73 |
+
<frontend_type>select</frontend_type>
|
| 74 |
+
<source_model>adminhtml/system_config_source_enabledisable</source_model>
|
| 75 |
+
<sort_order>40</sort_order>
|
| 76 |
+
<show_in_default>1</show_in_default>
|
| 77 |
+
<show_in_website>1</show_in_website>
|
| 78 |
+
<show_in_store>1</show_in_store>
|
| 79 |
+
<comment><![CDATA[If enabled, a <strong>Quick Chat Button</strong> is added above "Add to Cart" button in product pages. On click, the chat is initiated.]]></comment>
|
| 80 |
+
</quick_chat_button>
|
| 81 |
+
</fields>
|
| 82 |
+
</option>
|
| 83 |
+
</groups>
|
| 84 |
+
</salesiq>
|
| 85 |
+
</sections>
|
| 86 |
+
</config>
|
app/design/frontend/base/default/layout/salesiq.xml
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* @category Zoho
|
| 5 |
+
* @package Zoho_Salesiq
|
| 6 |
+
* @author SalesIQ Team
|
| 7 |
+
* @website http://www.zoho.com/salesiq
|
| 8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 9 |
+
*/
|
| 10 |
+
-->
|
| 11 |
+
<layout>
|
| 12 |
+
<default>
|
| 13 |
+
<reference name="before_body_end">
|
| 14 |
+
<block type="salesiq/salesiq" name="mp_salesiq" />
|
| 15 |
+
</reference>
|
| 16 |
+
</default>
|
| 17 |
+
|
| 18 |
+
<!--
|
| 19 |
+
Product view
|
| 20 |
+
-->
|
| 21 |
+
<catalog_product_view translate="label">
|
| 22 |
+
<reference name="product.info.extrahint">
|
| 23 |
+
<block type="salesiq/button" name="mp_salesiq_button" template="salesiq/button.phtml"/>
|
| 24 |
+
</reference>
|
| 25 |
+
</catalog_product_view>
|
| 26 |
+
</layout>
|
app/design/frontend/base/default/template/salesiq/button.phtml
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @category Zoho
|
| 4 |
+
* @package Zoho_Salesiq
|
| 5 |
+
* @author SalesIQ Team
|
| 6 |
+
* @website http://www.zoho.com/salesiq
|
| 7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 8 |
+
*/
|
| 9 |
+
?>
|
| 10 |
+
<?php if ($this->isQuickChatEnabled()): ?>
|
| 11 |
+
<button class="button"
|
| 12 |
+
title="<?php echo $this->getLabel(); ?>"
|
| 13 |
+
onclick="if ($zoho) {
|
| 14 |
+
var $zs = $zoho.salesiq || $zoho.livedesk;
|
| 15 |
+
$zs.floatwindow.visible('show');
|
| 16 |
+
$zs.visitor.question(<?php echo $this->getQuestion(); ?>);
|
| 17 |
+
$zs.chat.start();
|
| 18 |
+
}
|
| 19 |
+
return false;">
|
| 20 |
+
<span><span><?php echo $this->getLabel(); ?></span></span>
|
| 21 |
+
</button>
|
| 22 |
+
<?php endif ?>
|
app/etc/modules/Zoho_Salesiq.xml
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<!--
|
| 3 |
+
/**
|
| 4 |
+
* @category Zoho
|
| 5 |
+
* @package Zoho_Salesiq
|
| 6 |
+
* @author SalesIQ Team
|
| 7 |
+
* @website http://www.zoho.com/salesiq
|
| 8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
| 9 |
+
*/
|
| 10 |
+
-->
|
| 11 |
+
<config>
|
| 12 |
+
<modules>
|
| 13 |
+
<Zoho_Salesiq>
|
| 14 |
+
<active>true</active>
|
| 15 |
+
<codePool>community</codePool>
|
| 16 |
+
</Zoho_Salesiq>
|
| 17 |
+
</modules>
|
| 18 |
+
</config>
|
package.xml
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?xml version="1.0"?>
|
| 2 |
+
<package>
|
| 3 |
+
<name>Zoho_SalesIQ</name>
|
| 4 |
+
<version>1.0.1</version>
|
| 5 |
+
<stability>stable</stability>
|
| 6 |
+
<license uri="http://opensource.org/licenses/osl-3.0.php">Open Software License (OSL)</license>
|
| 7 |
+
<channel>community</channel>
|
| 8 |
+
<extends/>
|
| 9 |
+
<summary>With Zoho SalesIQ you can instantly connect to your customers and deliver instant support</summary>
|
| 10 |
+
<description>It’s time where communication with our customers have gone one step ahead in real time, Give your customers access to real-life agents who they connect instantly. Real names, real photos, real people, real easy. With Zoho SalesIQ you can instantly connect to your customers and deliver instant support.
|
| 11 |
+

|
| 12 |
+
Why SalesIQ?
|
| 13 |
+

|
| 14 |
+
In SalesIQ, you can customize the chat window color, text, logo, icons, input fields (Name, Email, contact number) and many more.
|
| 15 |
+

|
| 16 |
+
In the era of real-time communication and instant-everything, customers expect a prompt answer to their questions. With its neat web interface, Zoho SalesIQ allows agents to pick customer chat requests and help them to solve their problems instantly through Live Chat.
|
| 17 |
+

|
| 18 |
+
You can easily create, configure and customize your SalesIQ within minutes, Embed the customizable chat widgets into your website and provide a personalized Support experience to your customers.
|
| 19 |
+

|
| 20 |
+
Our Features
|
| 21 |
+

|
| 22 |
+
* Chat Embed Customization
|
| 23 |
+
* Support Customers from your Mobile Devices
|
| 24 |
+
* Gaze into the future and see what your customers type as they type it and magically make custom solutions appear before they ever hit submit
|
| 25 |
+
* Zoho SalesIQ Integration with Zoho CRM and Zoho Support
|
| 26 |
+
* Powerful Reporting
|
| 27 |
+
* Advanced organizational features, which includes departments.
|
| 28 |
+
* Chat transfer and Monitor
|
| 29 |
+
* Categorized Canned Messages
|
| 30 |
+
* IP Blocking
|
| 31 |
+
* Agent roles
|
| 32 |
+
* Business hour
|
| 33 |
+
Need to Know More? Visit our website: https://www.zoho.com/salesiq/help/getting-started-with-live-chat.html
|
| 34 |
+

|
| 35 |
+
Install Zoho SalesIQ plugin now and sign up for a free account at https://salesiq.zoho.com/register.sas?source=Magento.description</description>
|
| 36 |
+
<notes>Initial release</notes>
|
| 37 |
+
<authors><author><name>Zoho SalesIQ</name><user>salesiq</user><email>support@zohosalesiq.com</email></author></authors>
|
| 38 |
+
<date>2014-09-29</date>
|
| 39 |
+
<time>07:34:52</time>
|
| 40 |
+
<contents><target name="magecommunity"><dir name="Zoho"><dir name="Salesiq"><dir name="Block"><file name="Button.php" hash="6db97c4342b658487fec0a6900a830e4"/><file name="Salesiq.php" hash="c1e186b710004dc6fb22ff927e086c23"/><dir name="System"><dir name="Config"><dir name="Salesiq"><file name="Info.php" hash="cb616e9969232f0531cdbf6c42f6a15d"/></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="f15aebf9819cf68e1db2bce60850b079"/></dir><dir name="Model"><file name="Salesiq.php" hash="f0d2a771ff009b6f769f0084c0c17519"/></dir><dir name="controllers"><file name="IndexController.php" hash="1e404747e06a56187051f9bc216f8a08"/></dir><dir name="etc"><file name="adminhtml.xml" hash="cb3944866a6f437a0302a2ee4c221c41"/><file name="config.xml" hash="2e20560ac38f0e6ae808480a985806a0"/><file name="system.xml" hash="b2b1aaa2e79eb7b8950cc5e291dcda6a"/></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="salesiq.xml" hash="f7f195a3fbaeca4dd6625a759ea3cab3"/></dir><dir name="template"><dir name="salesiq"><file name="button.phtml" hash="41a8146a0be55f0557a46f093ef9fc71"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Zoho_Salesiq.xml" hash="5a7f856a8c5e3550e95a3abd9f29d848"/></dir></target></contents>
|
| 41 |
+
<compatible/>
|
| 42 |
+
<dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
|
| 43 |
+
</package>
|
