Version Notes
-Passing related items, and recently viewed items to velaro for integration
Download this release
Release Info
| Developer | Velaro |
| Extension | Velaro_Chat |
| Version | 1.3.0 |
| Comparing to | |
| See all releases | |
Code changes from version 1.2.2 to 1.3.0
- js/velaro_chat/velaro-admin.js +6 -3
- package.xml +5 -5
js/velaro_chat/velaro-admin.js
CHANGED
|
@@ -17,6 +17,7 @@
|
|
| 17 |
(function () {
|
| 18 |
|
| 19 |
document.observe('dom:loaded', function () {
|
|
|
|
| 20 |
var setupVelaroSelects = function () {
|
| 21 |
var selectMappings = {
|
| 22 |
velaro_enabled: 'velaro-enabled',
|
|
@@ -30,7 +31,9 @@
|
|
| 30 |
$$('[name=' + selectMappings[key] + '] option').each(function (el) {
|
| 31 |
el.writeAttribute('selected', false);
|
| 32 |
});
|
| 33 |
-
|
|
|
|
|
|
|
| 34 |
|
| 35 |
//setup change events
|
| 36 |
var $select = $$('[name=' + selectMappings[key] + ']')[0];
|
|
@@ -78,14 +81,14 @@
|
|
| 78 |
UserName: userName,
|
| 79 |
Password: password
|
| 80 |
};
|
| 81 |
-
var request = new Ajax.Request('
|
| 82 |
{
|
| 83 |
method: 'post',
|
| 84 |
parameters: JSON.stringify(model),
|
| 85 |
contentType: 'application/json',
|
| 86 |
dataType: 'json',
|
| 87 |
onSuccess: function (response) {
|
| 88 |
-
if(response.status == 200){
|
| 89 |
var start = response.responseText.indexOf('<Content>') + 9;
|
| 90 |
var end = response.responseText.indexOf('</Content>');
|
| 91 |
var data = JSON.parse(response.responseText.substring(start, end));
|
| 17 |
(function () {
|
| 18 |
|
| 19 |
document.observe('dom:loaded', function () {
|
| 20 |
+
var baseUrl = $$('[name=velarobaseurl]')[0].value;
|
| 21 |
var setupVelaroSelects = function () {
|
| 22 |
var selectMappings = {
|
| 23 |
velaro_enabled: 'velaro-enabled',
|
| 31 |
$$('[name=' + selectMappings[key] + '] option').each(function (el) {
|
| 32 |
el.writeAttribute('selected', false);
|
| 33 |
});
|
| 34 |
+
if(value){
|
| 35 |
+
$$('[name=' + selectMappings[key] + '] option[value="' + value + '"]')[0].writeAttribute('selected', true);
|
| 36 |
+
}
|
| 37 |
|
| 38 |
//setup change events
|
| 39 |
var $select = $$('[name=' + selectMappings[key] + ']')[0];
|
| 81 |
UserName: userName,
|
| 82 |
Password: password
|
| 83 |
};
|
| 84 |
+
var request = new Ajax.Request(baseUrl + '/api/plugins/login',
|
| 85 |
{
|
| 86 |
method: 'post',
|
| 87 |
parameters: JSON.stringify(model),
|
| 88 |
contentType: 'application/json',
|
| 89 |
dataType: 'json',
|
| 90 |
onSuccess: function (response) {
|
| 91 |
+
if (response.status == 200) {
|
| 92 |
var start = response.responseText.indexOf('<Content>') + 9;
|
| 93 |
var end = response.responseText.indexOf('</Content>');
|
| 94 |
var data = JSON.parse(response.responseText.substring(start, end));
|
package.xml
CHANGED
|
@@ -1,18 +1,18 @@
|
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Velaro_Chat</name>
|
| 4 |
-
<version>1.
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="https://opensource.org/licenses/OSL-3.0">Open Software License (OSL)</license>
|
| 7 |
<channel>community</channel>
|
| 8 |
<extends/>
|
| 9 |
<summary>Add Velaro Live Chat into your pages</summary>
|
| 10 |
<description>Add Velaro Live Chat into your pages</description>
|
| 11 |
-
<notes>-
|
| 12 |
<authors><author><name>Velaro</name><user>jtuttle87</user><email>jonathan@velaro.com</email></author></authors>
|
| 13 |
-
<date>
|
| 14 |
-
<time>
|
| 15 |
-
<contents><target name="magedesign"><dir name="."><dir name="app"><dir name="design"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="velaro.xml" hash=""/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="velaro.xml" hash=""/></dir></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="."><dir name="app"><dir name="etc"><dir name="modules"><file name="Velaro_Chat.xml" hash=""/></dir></dir></dir></dir></target><target name="mageweb"><dir name="."><dir name="js"><dir name="velaro_chat"><file name="velaro-admin.js" hash="
|
| 16 |
<compatible/>
|
| 17 |
<dependencies><required><php><min>5.3.0</min><max>5.5.0</max></php></required></dependencies>
|
| 18 |
</package>
|
| 1 |
<?xml version="1.0"?>
|
| 2 |
<package>
|
| 3 |
<name>Velaro_Chat</name>
|
| 4 |
+
<version>1.3.0</version>
|
| 5 |
<stability>stable</stability>
|
| 6 |
<license uri="https://opensource.org/licenses/OSL-3.0">Open Software License (OSL)</license>
|
| 7 |
<channel>community</channel>
|
| 8 |
<extends/>
|
| 9 |
<summary>Add Velaro Live Chat into your pages</summary>
|
| 10 |
<description>Add Velaro Live Chat into your pages</description>
|
| 11 |
+
<notes>-Passing related items, and recently viewed items to velaro for integration</notes>
|
| 12 |
<authors><author><name>Velaro</name><user>jtuttle87</user><email>jonathan@velaro.com</email></author></authors>
|
| 13 |
+
<date>2016-03-16</date>
|
| 14 |
+
<time>19:31:08</time>
|
| 15 |
+
<contents><target name="magedesign"><dir name="."><dir name="app"><dir name="design"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="velaro.xml" hash=""/></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="velaro.xml" hash=""/></dir></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="."><dir name="app"><dir name="etc"><dir name="modules"><file name="Velaro_Chat.xml" hash=""/></dir></dir></dir></dir></target><target name="mageweb"><dir name="."><dir name="js"><dir name="velaro_chat"><file name="velaro-admin.js" hash="514733cc14c15496180a79b504481fb5"/></dir></dir></dir></target></contents>
|
| 16 |
<compatible/>
|
| 17 |
<dependencies><required><php><min>5.3.0</min><max>5.5.0</max></php></required></dependencies>
|
| 18 |
</package>
|
