Version Notes
First requires configuration in System > Configuration > Pixlee Account Configuration.
Download this release
Release Info
| Developer | Awad Sayeed |
| Extension | pixlee-for-magento |
| Version | 2.0.0.25 |
| Comparing to | |
| See all releases | |
Code changes from version 2.0.0.24 to 2.0.0.25
- app/code/community/Pixlee/Base/Block/Adminhtml/System/Config/Form/Demo.php +1 -1
- app/code/community/Pixlee/Base/Model/Resource/Setup.php +33 -2
- app/code/community/Pixlee/Base/etc/adminhtml.xml +26 -0
- app/code/community/Pixlee/Base/etc/config.xml +1 -1
- app/code/community/Pixlee/Base/etc/config.xml.bak +1 -1
- app/code/community/Pixlee/Base/etc/system.xml +14 -4
- app/code/community/Pixlee/Base/sql/pixlee_base_setup/mysql4-install-1.0.0.php +1 -0
- app/code/community/Pixlee/Base/version.txt +1 -1
- app/design/adminhtml/default/default/template/pixlee/system/config/demo_button.phtml +5 -5
- package.xml +1 -1
app/code/community/Pixlee/Base/Block/Adminhtml/System/Config/Form/Demo.php
CHANGED
|
@@ -12,7 +12,7 @@ class Pixlee_Base_Block_Adminhtml_System_Config_Form_Demo extends Mage_Adminhtml
|
|
| 12 |
public function getButtonHtml() {
|
| 13 |
$buttonData = array(
|
| 14 |
'id' => 'request_demo_button',
|
| 15 |
-
'label' => $this->helper('adminhtml')->__('Request
|
| 16 |
'onclick' => 'javascript:requestDemo(); return false;'
|
| 17 |
);
|
| 18 |
|
| 12 |
public function getButtonHtml() {
|
| 13 |
$buttonData = array(
|
| 14 |
'id' => 'request_demo_button',
|
| 15 |
+
'label' => $this->helper('adminhtml')->__('Request Access'),
|
| 16 |
'onclick' => 'javascript:requestDemo(); return false;'
|
| 17 |
);
|
| 18 |
|
app/code/community/Pixlee/Base/Model/Resource/Setup.php
CHANGED
|
@@ -1,3 +1,34 @@
|
|
| 1 |
<?php
|
| 2 |
-
|
| 3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
<?php
|
| 2 |
+
|
| 3 |
+
class Pixlee_Base_Model_Resource_Setup extends Mage_Core_Model_Resource_Setup {
|
| 4 |
+
public function send_to_pardot() {
|
| 5 |
+
Mage::log("Beginning to send lead to Pardot");
|
| 6 |
+
$store_name = Mage::app()->getStore()->getName();
|
| 7 |
+
$from_email = Mage::getStoreConfig('trans_email/ident_general/email'); //fetch sender email Admin
|
| 8 |
+
$from_name = Mage::getStoreConfig('trans_email/ident_general/name'); //fetch sender name Admin
|
| 9 |
+
|
| 10 |
+
if ($from_email != "owner@example.com") {
|
| 11 |
+
Mage::log("Lead data validated");
|
| 12 |
+
$data = json_encode(array(
|
| 13 |
+
"name" => $from_name,
|
| 14 |
+
"email" => $from_email,
|
| 15 |
+
"company" => $store_name,
|
| 16 |
+
"source" => "magento_1_download"
|
| 17 |
+
));
|
| 18 |
+
|
| 19 |
+
$ch = curl_init();
|
| 20 |
+
curl_setopt($ch, CURLOPT_URL, "https://app.pixlee.com/leads/add");
|
| 21 |
+
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "POST");
|
| 22 |
+
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
|
| 23 |
+
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
|
| 24 |
+
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
|
| 25 |
+
'Content-Type: application/json',
|
| 26 |
+
'Content-Length: ' . strlen($data))
|
| 27 |
+
);
|
| 28 |
+
|
| 29 |
+
$output = curl_exec($ch);
|
| 30 |
+
Mage::log("Response from CP" . $output);
|
| 31 |
+
curl_close($ch);
|
| 32 |
+
}
|
| 33 |
+
}
|
| 34 |
+
}
|
app/code/community/Pixlee/Base/etc/adminhtml.xml
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<config>
|
| 2 |
+
<acl>
|
| 3 |
+
<resources>
|
| 4 |
+
<admin>
|
| 5 |
+
<children>
|
| 6 |
+
<system>
|
| 7 |
+
<children>
|
| 8 |
+
<config>
|
| 9 |
+
<children>
|
| 10 |
+
<pixlee translate="title" module="pixlee">
|
| 11 |
+
<title>Account Config</title>
|
| 12 |
+
<sort_order>10</sort_order>
|
| 13 |
+
</pixlee>
|
| 14 |
+
<request translate="title" module="pixlee">
|
| 15 |
+
<title>Request Access</title>
|
| 16 |
+
<sort_order>12</sort_order>
|
| 17 |
+
</request>
|
| 18 |
+
</children>
|
| 19 |
+
</config>
|
| 20 |
+
</children>
|
| 21 |
+
</system>
|
| 22 |
+
</children>
|
| 23 |
+
</admin>
|
| 24 |
+
</resources>
|
| 25 |
+
</acl>
|
| 26 |
+
</config>
|
app/code/community/Pixlee/Base/etc/config.xml
CHANGED
|
@@ -2,7 +2,7 @@
|
|
| 2 |
<config>
|
| 3 |
<modules>
|
| 4 |
<Pixlee_Base>
|
| 5 |
-
<version>2.0.0.
|
| 6 |
</Pixlee_Base>
|
| 7 |
</modules>
|
| 8 |
<default>
|
| 2 |
<config>
|
| 3 |
<modules>
|
| 4 |
<Pixlee_Base>
|
| 5 |
+
<version>2.0.0.25</version>
|
| 6 |
</Pixlee_Base>
|
| 7 |
</modules>
|
| 8 |
<default>
|
app/code/community/Pixlee/Base/etc/config.xml.bak
CHANGED
|
@@ -2,7 +2,7 @@
|
|
| 2 |
<config>
|
| 3 |
<modules>
|
| 4 |
<Pixlee_Base>
|
| 5 |
-
<version>2.0.0.
|
| 6 |
</Pixlee_Base>
|
| 7 |
</modules>
|
| 8 |
<default>
|
| 2 |
<config>
|
| 3 |
<modules>
|
| 4 |
<Pixlee_Base>
|
| 5 |
+
<version>2.0.0.22</version>
|
| 6 |
</Pixlee_Base>
|
| 7 |
</modules>
|
| 8 |
<default>
|
app/code/community/Pixlee/Base/etc/system.xml
CHANGED
|
@@ -8,8 +8,8 @@
|
|
| 8 |
</pixlee>
|
| 9 |
</tabs>
|
| 10 |
<sections>
|
| 11 |
-
<
|
| 12 |
-
<label>
|
| 13 |
<tab>pixlee</tab>
|
| 14 |
<sort_order>1000</sort_order>
|
| 15 |
<show_in_default>1</show_in_default>
|
|
@@ -22,6 +22,7 @@
|
|
| 22 |
<frontend_type>text</frontend_type>
|
| 23 |
<sort_order>1</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 |
<fields>
|
|
@@ -50,7 +51,7 @@
|
|
| 50 |
<show_in_store>1</show_in_store>
|
| 51 |
</website>
|
| 52 |
<request_demo translate="label">
|
| 53 |
-
<label>Request
|
| 54 |
<frontend_type>button</frontend_type>
|
| 55 |
<frontend_model>pixlee/adminhtml_system_config_form_demo</frontend_model>
|
| 56 |
<sort_order>60</sort_order>
|
|
@@ -58,9 +59,18 @@
|
|
| 58 |
<show_in_website>1</show_in_website>
|
| 59 |
<show_in_store>1</show_in_store>
|
| 60 |
</request_demo>
|
| 61 |
-
|
| 62 |
</fields>
|
| 63 |
</demo>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 64 |
<pixlee translate="label" module="pixlee">
|
| 65 |
<label>API Credentials</label>
|
| 66 |
<frontend_type>text</frontend_type>
|
| 8 |
</pixlee>
|
| 9 |
</tabs>
|
| 10 |
<sections>
|
| 11 |
+
<request translate="label" module="pixlee">
|
| 12 |
+
<label>New Downloads</label>
|
| 13 |
<tab>pixlee</tab>
|
| 14 |
<sort_order>1000</sort_order>
|
| 15 |
<show_in_default>1</show_in_default>
|
| 22 |
<frontend_type>text</frontend_type>
|
| 23 |
<sort_order>1</sort_order>
|
| 24 |
<show_in_default>1</show_in_default>
|
| 25 |
+
<expanded>1</expanded>
|
| 26 |
<show_in_website>1</show_in_website>
|
| 27 |
<show_in_store>1</show_in_store>
|
| 28 |
<fields>
|
| 51 |
<show_in_store>1</show_in_store>
|
| 52 |
</website>
|
| 53 |
<request_demo translate="label">
|
| 54 |
+
<label>Request Access</label>
|
| 55 |
<frontend_type>button</frontend_type>
|
| 56 |
<frontend_model>pixlee/adminhtml_system_config_form_demo</frontend_model>
|
| 57 |
<sort_order>60</sort_order>
|
| 59 |
<show_in_website>1</show_in_website>
|
| 60 |
<show_in_store>1</show_in_store>
|
| 61 |
</request_demo>
|
|
|
|
| 62 |
</fields>
|
| 63 |
</demo>
|
| 64 |
+
</groups>
|
| 65 |
+
</request>
|
| 66 |
+
<pixlee translate="label" module="pixlee">
|
| 67 |
+
<label>Pixlee Account Configuration</label>
|
| 68 |
+
<tab>pixlee</tab>
|
| 69 |
+
<sort_order>1100</sort_order>
|
| 70 |
+
<show_in_default>1</show_in_default>
|
| 71 |
+
<show_in_website>1</show_in_website>
|
| 72 |
+
<show_in_store>1</show_in_store>
|
| 73 |
+
<groups>
|
| 74 |
<pixlee translate="label" module="pixlee">
|
| 75 |
<label>API Credentials</label>
|
| 76 |
<frontend_type>text</frontend_type>
|
app/code/community/Pixlee/Base/sql/pixlee_base_setup/mysql4-install-1.0.0.php
CHANGED
|
@@ -1,6 +1,7 @@
|
|
| 1 |
<?php
|
| 2 |
$installer = $this;
|
| 3 |
$installer->startSetup();
|
|
|
|
| 4 |
|
| 5 |
$table = $installer->getConnection()->newTable($installer->getTable('pixlee/product_album'))
|
| 6 |
->addColumn('id', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array(
|
| 1 |
<?php
|
| 2 |
$installer = $this;
|
| 3 |
$installer->startSetup();
|
| 4 |
+
$installer->send_to_pardot();
|
| 5 |
|
| 6 |
$table = $installer->getConnection()->newTable($installer->getTable('pixlee/product_album'))
|
| 7 |
->addColumn('id', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array(
|
app/code/community/Pixlee/Base/version.txt
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
|
| 1 |
+
98ebc375caef96902be89392ce8b9b773277a6c6
|
app/design/adminhtml/default/default/template/pixlee/system/config/demo_button.phtml
CHANGED
|
@@ -1,9 +1,9 @@
|
|
| 1 |
<script type="text/javascript">
|
| 2 |
//<