SyncwithMicrosoftDynamicCrm - Version 1.0

Version Notes

This extension would post real time leads from magento to salesforce automatically. This extension also has the capability to transfer abandoned shopping carts from Magento to salesforce as opportunities which would allow your sales team to track the opportunity and convert to a sale. We also have a feature where once an opportunity is converted to a sale in salesforce, it can create an order in magento. Please contact us at 302-355-0449 for further details or email me directly at _mailto:info@thylaksoft.com and _mailto:buyan@talktoaprogrammer.com for further information.

Download this release

Release Info

Developer Magento Core Team
Extension SyncwithMicrosoftDynamicCrm
Version 1.0
Comparing to
See all releases


Version 1.0

app/code/local/Thylak/Magemicrosoft/Block/Adminhtml/Magemicrosoft/Magemicrosoft.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magemicrosoft_Block_Adminhtml_Magemicrosoft_Magemicrosoft extends Mage_Adminhtml_Block_Widget_Form_Container
4
+ {
5
+ public function __construct()
6
+ {
7
+ $this->setTemplate('magemicrosoft/magemicrosoft.phtml');
8
+ }
9
+ }
10
+
11
+
12
+
app/code/local/Thylak/Magemicrosoft/Block/Adminhtml/Magemicrosoft/Thanks.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magemicrosoft_Block_Adminhtml_Magemicrosoft_Thanks extends Mage_Adminhtml_Block_Widget_Form_Container
4
+ {
5
+ public function __construct()
6
+ {
7
+ $this->setTemplate('magemicrosoft/thanks.phtml');
8
+ }
9
+ }
10
+
11
+
12
+
app/code/local/Thylak/Magemicrosoft/Helper/Data.php ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magemicrosoft_Helper_Data extends Mage_Core_Helper_Abstract
4
+ {
5
+
6
+ }
app/code/local/Thylak/Magemicrosoft/Model/Magemicrosoft.php ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magemicrosoft_Model_Magemicrosoft extends Mage_Core_Model_Abstract
4
+ {
5
+
6
+ //public function _construct()
7
+ //{
8
+ //parent::_construct();
9
+ //$this->_init('magesalesforce/magesalesforce');
10
+ //}
11
+
12
+ private $_url;
13
+ private $_email;
14
+ private $_fname;
15
+ private $_lname;
16
+
17
+ public function __construct($url,$email,$fname,$lname)
18
+ {
19
+ $this->_url = $url;
20
+ $this->_email = $email;
21
+ $this->_fname = $fname;
22
+ $this->_lname = $lname;
23
+ }
24
+
25
+ public function callCurl()
26
+ {
27
+ //$url = "http://173.15.158.230/timetracker/addlead.aspx?".$qrystr;
28
+ $ch = curl_init() or die(curl_error());
29
+ curl_setopt($ch, CURLOPT_URL,$this->_url);
30
+ curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
31
+ $data1=curl_exec($ch) or die(curl_error());
32
+ //echo "<font color=black face=verdana size=3>".$data1."</font>";
33
+ //echo curl_error($ch);
34
+ curl_close($ch);
35
+ return $data1;
36
+ }
37
+
38
+ public function sendEmail()
39
+ {
40
+ $fname = $this->_fname;
41
+ $lname = $this->_lname;
42
+ $name = $fname.' '.$lname;
43
+ $to = $this->_email;
44
+ $subject = 'Thanks for visiting our site';
45
+ // To send HTML mail, the Content-type header must be set
46
+ $headers = 'MIME-Version: 1.0' . "\r\n";
47
+ $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
48
+ // Additional headers
49
+ $headers .= 'From: Thylak Soft <info@thylaksoft.com>' . "\r\n";
50
+ $headers .= 'To: '.$fname.'<'.$to.'>' . "\r\n";
51
+ $headers .= 'Cc: buyan@talktoaprogrammer.com; kris@talktoaprogrammer.com' . "\r\n";
52
+ $message = "<html>
53
+ <head>
54
+ <title>Magento to Microsoft Dynamic CRM</title>
55
+ </head>
56
+ <body>
57
+ <p>Dear ".$name.",</p><br>
58
+ Thanks for your interest in Magento to Microsoft Dynamic CRM Extension. We would appreciate if you could <br />answer the following questions which would help us to get this right away to you.
59
+ <br />1. What version of Microsoft Dynamic CRM do you use?<br />2. Could you please tell me a few words about yourself, your role in your company and what your company does?<br />3. What is the best time and number to get in touch with you?<br />We would be contacting you soon on your request.<br />Thanks<br />Please click on this link to read further information about this extension.<br />http://www.thylaksoft.com/Retail/MagentoSoln/MagentoEnterprise.aspx<br />http://www.thylaksoft.com/Retail/MagentoSoln/Magento2Salesforce.aspx<br />
60
+ Regards,<br />
61
+ The Thylaksoft Team<br />
62
+ 302-355-0449<br />
63
+ www.thylaksoft.com
64
+ </body>
65
+ </html>";
66
+ mail($to, $subject, $message, $headers);
67
+ }
68
+
69
+
70
+ }
71
+
72
+
73
+
app/code/local/Thylak/Magemicrosoft/controllers/Adminhtml/MagemicrosoftController.php ADDED
@@ -0,0 +1,58 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magemicrosoft_Adminhtml_MagemicrosoftController extends Mage_Adminhtml_Controller_action
4
+ {
5
+
6
+ public function indexAction()
7
+ {
8
+ $this->loadLayout()
9
+ ->_addContent($this->getLayout()->createBlock('magemicrosoft/adminhtml_magemicrosoft_magemicrosoft'))
10
+ ->_setActiveMenu('magemicrosoft/items')
11
+ ->renderLayout();
12
+ }
13
+
14
+ public function thanksAction()
15
+ {
16
+ $this->loadLayout()
17
+ ->_addContent($this->getLayout()->createBlock('magemicrosoft/adminhtml_magemicrosoft_thanks'))
18
+ ->_setActiveMenu('magemicrosoft/items')
19
+ ->renderLayout();
20
+ }
21
+
22
+ public function savemagemicrosoftAction()
23
+ {
24
+ $fname=$this->getRequest()->getPost('firstname');
25
+ $lname=$this->getRequest()->getPost('lastname');
26
+ $email=$this->getRequest()->getPost('email');
27
+ $company=$this->getRequest()->getPost('company');
28
+ $ph=$this->getRequest()->getPost('phoneno');
29
+ $productversion=$this->getRequest()->getPost('productversion');
30
+ $desc=$this->getRequest()->getPost('description');
31
+ $timetotalk=$this->getRequest()->getPost('timetotalk');
32
+
33
+ $qrystr = 'FirstName='.str_replace(" ","%20",$fname).'&LastName='.str_replace(" ","%20",$lname).'&Email='.str_replace(" ","%20",$email).'&CompanyName='.str_replace(" ","%20",$company).'&Phone1='.str_replace(" ","%20",$ph).'&ProductVersion='.str_replace(" ","%20",$productversion).'&TimetoTalk='.str_replace(" ","%20",$timetotalk).'&CloseLeadComment='.str_replace(" ","%20",$desc).'&CreatedBy=139&SourceID=42';
34
+
35
+ $url = "http://www.thylaksoft.com/addLead.aspx?".$qrystr;
36
+
37
+ $mscrm = new Thylak_Magemicrosoft_Model_Magemicrosoft($url,$email,$fname,$lname);
38
+ $res = $mscrm->callCurl();
39
+
40
+ if($res=='success')
41
+ {
42
+ //try{
43
+ //$salesforce->sendEmail();
44
+ //}
45
+ //catch(Exception $e){
46
+ //echo $ex;
47
+ //}
48
+ $this->getResponse()->setRedirect($this->getUrl('magemicrosoft/adminhtml_magemicrosoft/thanks/fname/'.$fname.'/lname/'.$lname, array('_secure'=>true)));
49
+ }
50
+ else
51
+ {
52
+ Mage::getSingleton('core/session')->addError('There was an Error occured. Please try after some time.');
53
+ $this->getResponse()->setRedirect($this->getUrl('magemicrosoft/adminhtml_magemicrosoft/index/', array('_secure'=>true)));
54
+ }
55
+ return;
56
+ }
57
+
58
+ }
app/code/local/Thylak/Magemicrosoft/etc/config.xml ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+
3
+ <!-- Config file -->
4
+
5
+ <config>
6
+ <modules>
7
+ <Thylak_Magemicrosoft>
8
+ <version>0.1.0</version>
9
+ </Thylak_Magemicrosoft>
10
+ </modules>
11
+ <admin>
12
+ <routers>
13
+ <magemicrosoft>
14
+ <use>admin</use>
15
+ <args>
16
+ <module>Thylak_Magemicrosoft</module>
17
+ <frontName>magemicrosoft</frontName>
18
+ </args>
19
+ </magemicrosoft>
20
+ </routers>
21
+ </admin>
22
+ <adminhtml>
23
+ <menu>
24
+ <magemicrosoft module="magemicrosoft">
25
+ <title>Microsoft Dynamic CRM</title>
26
+ <sort_order>71</sort_order>
27
+ <children>
28
+ <items module="magemicrosoft">
29
+ <title>Magento to Microsoft Dynamic CRM</title>
30
+ <action>magemicrosoft/adminhtml_magemicrosoft/index</action>
31
+ <sort_order>20</sort_order>
32
+ </items>
33
+ </children>
34
+ </magemicrosoft>
35
+ </menu>
36
+ <acl>
37
+ <resources>
38
+ <all>
39
+ <title>Allow Everything</title>
40
+ </all>
41
+ <admin>
42
+ <children>
43
+ <Thylak_Magemicrosoft>
44
+ <title>Magemicrosoft Module</title>
45
+ <sort_order>10</sort_order>
46
+ </Thylak_Magemicrosoft>
47
+ </children>
48
+ </admin>
49
+ </resources>
50
+ </acl>
51
+ <layout>
52
+ <updates>
53
+ <magemicrosoft>
54
+ <file>magemicrosoft.xml</file>
55
+ </magemicrosoft>
56
+ </updates>
57
+ </layout>
58
+ </adminhtml>
59
+ <global>
60
+ <resources>
61
+ <magemicrosoft_setup>
62
+ <setup>
63
+ <module>Thylak_Magemicrosoft</module>
64
+ </setup>
65
+ <connection>
66
+ <use>core_setup</use>
67
+ </connection>
68
+ </magemicrosoft_setup>
69
+ <magemicrosoft_write>
70
+ <connection>
71
+ <use>core_write</use>
72
+ </connection>
73
+ </magemicrosoft_write>
74
+ <magemicrosoft_read>
75
+ <connection>
76
+ <use>core_read</use>
77
+ </connection>
78
+ </magemicrosoft_read>
79
+ </resources>
80
+ <models>
81
+ <magemicrosoft>
82
+ <class>Thylak_Magemicrosoft_Model</class>
83
+ </magemicrosoft>
84
+ </models>
85
+ <blocks>
86
+ <magemicrosoft>
87
+ <class>Thylak_Magemicrosoft_Block</class>
88
+ </magemicrosoft>
89
+ </blocks>
90
+ <helpers>
91
+ <magemicrosoft>
92
+ <class>Thylak_Magemicrosoft_Helper</class>
93
+ </magemicrosoft>
94
+ </helpers>
95
+ </global>
96
+ </config>
app/code/local/Thylak/Magesugar/Block/Adminhtml/Magesugar/Magesugar.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magesugar_Block_Adminhtml_Magesugar_Magesugar extends Mage_Adminhtml_Block_Widget_Form_Container
4
+ {
5
+ public function __construct()
6
+ {
7
+ $this->setTemplate('magesugar/magesugar.phtml');
8
+ }
9
+ }
10
+
11
+
12
+
app/code/local/Thylak/Magesugar/Block/Adminhtml/Magesugar/Thanks.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magesugar_Block_Adminhtml_Magesugar_Thanks extends Mage_Adminhtml_Block_Widget_Form_Container
4
+ {
5
+ public function __construct()
6
+ {
7
+ $this->setTemplate('magesugar/thanks.phtml');
8
+ }
9
+ }
10
+
11
+
12
+
app/code/local/Thylak/Magesugar/Helper/Data.php ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magesugar_Helper_Data extends Mage_Core_Helper_Abstract
4
+ {
5
+
6
+ }
app/code/local/Thylak/Magesugar/Model/Magesugar.php ADDED
@@ -0,0 +1,74 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magesugar_Model_Magesugar extends Mage_Core_Model_Abstract
4
+ {
5
+
6
+ //public function _construct()
7
+ //{
8
+ //parent::_construct();
9
+ //$this->_init('magesalesforce/magesalesforce');
10
+ //}
11
+
12
+ private $_url;
13
+ private $_email;
14
+ private $_fname;
15
+ private $_lname;
16
+
17
+ public function __construct($url,$email,$fname,$lname)
18
+ {
19
+ $this->_url = $url;
20
+ $this->_email = $email;
21
+ $this->_fname = $fname;
22
+ $this->_lname = $lname;
23
+ }
24
+
25
+ public function callCurl()
26
+ {
27
+ //$url = "http://173.15.158.230/timetracker/addlead.aspx?".$qrystr;
28
+ $ch = curl_init() or die(curl_error());
29
+ curl_setopt($ch, CURLOPT_URL,$this->_url);
30
+ curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
31
+ $data1=curl_exec($ch) or die(curl_error());
32
+ //echo "<font color=black face=verdana size=3>".$data1."</font>";
33
+ //echo curl_error($ch);
34
+ curl_close($ch);
35
+ return $data1;
36
+ }
37
+
38
+ public function sendEmail()
39
+ {
40
+ $fname = $this->_fname;
41
+ $lname = $this->_lname;
42
+ $name = $fname.' '.$lname;
43
+ $to = $this->_email;
44
+ $subject = 'Thanks for visiting our site';
45
+ // To send HTML mail, the Content-type header must be set
46
+ $headers = 'MIME-Version: 1.0' . "\r\n";
47
+ $headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
48
+ // Additional headers
49
+ $headers .= 'From: Thylak Soft <info@thylaksoft.com>' . "\r\n";
50
+ $headers .= 'To: '.$fname.'<'.$to.'>' . "\r\n";
51
+ $headers .= 'Cc: buyan@talktoaprogrammer.com; kris@talktoaprogrammer.com' . "\r\n";
52
+ $message = "<html>
53
+ <head>
54
+ <title>Magento to Sugar CRM</title>
55
+ </head>
56
+ <body>
57
+ <p>Dear ".$name.",</p><br>
58
+ Thanks for your interest in Magento to Sugar CRM Extension. We would appreciate if you could <br />answer the following questions which would help us to get this right away to you.
59
+ <br />1. What version of Sugar CRM do you use?<br />2. Could you please tell me a few words about yourself, your role in your company and what your company does?<br />3. What is the best time and number to get in touch with you?<br />We would be contacting you soon on your request.<br />Thanks<br />Please click on this link to read further information about this extension.<br />http://www.thylaksoft.com/Retail/MagentoSoln/MagentoEnterprise.aspx<br />http://www.thylaksoft.com/Retail/MagentoSoln/Magento2Salesforce.aspx<br />
60
+ Regards,<br />
61
+ The Thylaksoft Team<br />
62
+ 302-355-0449<br />
63
+ www.thylaksoft.com
64
+ </body>
65
+ </html>";
66
+ mail($to, $subject, $message, $headers);
67
+ }
68
+
69
+
70
+
71
+ }
72
+
73
+
74
+
app/code/local/Thylak/Magesugar/controllers/Adminhtml/MagesugarController.php ADDED
@@ -0,0 +1,57 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ class Thylak_Magesugar_Adminhtml_MagesugarController extends Mage_Adminhtml_Controller_action
4
+ {
5
+
6
+ public function indexAction()
7
+ {
8
+ $this->loadLayout()
9
+ ->_addContent($this->getLayout()->createBlock('magesugar/adminhtml_magesugar_magesugar'))
10
+ ->_setActiveMenu('magesugar/items')
11
+ ->renderLayout();
12
+ }
13
+
14
+ public function thanksAction()
15
+ {
16
+ $this->loadLayout()
17
+ ->_addContent($this->getLayout()->createBlock('magesugar/adminhtml_magesugar_thanks'))
18
+ ->_setActiveMenu('magesugar/items')
19
+ ->renderLayout();
20
+ }
21
+
22
+ public function savemagesugarAction()
23
+ {
24
+ $fname=$this->getRequest()->getPost('firstname');
25
+ $lname=$this->getRequest()->getPost('lastname');
26
+ $email=$this->getRequest()->getPost('email');
27
+ $company=$this->getRequest()->getPost('company');
28
+ $ph=$this->getRequest()->getPost('phoneno');
29
+ $productversion=$this->getRequest()->getPost('productversion');
30
+ $desc=$this->getRequest()->getPost('description');
31
+ $timetotalk=$this->getRequest()->getPost('timetotalk');
32
+
33
+ $qrystr = 'FirstName='.str_replace(" ","%20",$fname).'&LastName='.str_replace(" ","%20",$lname).'&Email='.str_replace(" ","%20",$email).'&CompanyName='.str_replace(" ","%20",$company).'&Phone1='.str_replace(" ","%20",$ph).'&ProductVersion='.str_replace(" ","%20",$productversion).'&TimetoTalk='.str_replace(" ","%20",$timetotalk).'&CloseLeadComment='.str_replace(" ","%20",$desc).'&CreatedBy=139&SourceID=42';
34
+
35
+ $url = "http://www.thylaksoft.com/addLead.aspx?".$qrystr;
36
+ $sugarcrm = new Thylak_Magesugar_Model_Magesugar($url,$email,$fname,$lname);
37
+ $res = $sugarcrm->callCurl();
38
+
39
+ if($res=='success')
40
+ {
41
+ //try{
42
+ //$salesforce->sendEmail();
43
+ //}
44
+ //catch(Exception $e){
45
+ //echo $ex;
46
+ //}
47
+ $this->getResponse()->setRedirect($this->getUrl('magesugar/adminhtml_magesugar/thanks/fname/'.$fname.'/lname/'.$lname, array('_secure'=>true)));
48
+ }
49
+ else
50
+ {
51
+ Mage::getSingleton('core/session')->addError('There was an Error occured. Please try after some time.');
52
+ $this->getResponse()->setRedirect($this->getUrl('magesugar/adminhtml_magesugar/index/', array('_secure'=>true)));
53
+ }
54
+ return;
55
+ }
56
+
57
+ }
app/code/local/Thylak/Magesugar/etc/config.xml ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+
3
+ <!-- Config file -->
4
+
5
+ <config>
6
+ <modules>
7
+ <Thylak_Magesugar>
8
+ <version>0.1.0</version>
9
+ </Thylak_Magesugar>
10
+ </modules>
11
+ <admin>
12
+ <routers>
13
+ <magesugar>
14
+ <use>admin</use>
15
+ <args>
16
+ <module>Thylak_Magesugar</module>
17
+ <frontName>magesugar</frontName>
18
+ </args>
19
+ </magesugar>
20
+ </routers>
21
+ </admin>
22
+ <adminhtml>
23
+ <menu>
24
+ <magesugar module="magesugar">
25
+ <title>Sugar CRM</title>
26
+ <sort_order>71</sort_order>
27
+ <children>
28
+ <items module="magesugar">
29
+ <title>Magento to Sugar CRM</title>
30
+ <action>magesugar/adminhtml_magesugar/index</action>
31
+ <sort_order>20</sort_order>
32
+ </items>
33
+ </children>
34
+ </magesugar>
35
+ </menu>
36
+ <acl>
37
+ <resources>
38
+ <all>
39
+ <title>Allow Everything</title>
40
+ </all>
41
+ <admin>
42
+ <children>
43
+ <Thylak_Magesugar>
44
+ <title>Magesugar Module</title>
45
+ <sort_order>10</sort_order>
46
+ </Thylak_Magesugar>
47
+ </children>
48
+ </admin>
49
+ </resources>
50
+ </acl>
51
+ <layout>
52
+ <updates>
53
+ <magesugar>
54
+ <file>magesugar.xml</file>
55
+ </magesugar>
56
+ </updates>
57
+ </layout>
58
+ </adminhtml>
59
+ <global>
60
+ <resources>
61
+ <magesugar_setup>
62
+ <setup>
63
+ <module>Thylak_Magesugar</module>
64
+ </setup>
65
+ <connection>
66
+ <use>core_setup</use>
67
+ </connection>
68
+ </magesugar_setup>
69
+ <magesugar_write>
70
+ <connection>
71
+ <use>core_write</use>
72
+ </connection>
73
+ </magesugar_write>
74
+ <magesugar_read>
75
+ <connection>
76
+ <use>core_read</use>
77
+ </connection>
78
+ </magesugar_read>
79
+ </resources>
80
+ <models>
81
+ <magesugar>
82
+ <class>Thylak_Magesugar_Model</class>
83
+ </magesugar>
84
+ </models>
85
+ <blocks>
86
+ <magesugar>
87
+ <class>Thylak_Magesugar_Block</class>
88
+ </magesugar>
89
+ </blocks>
90
+ <helpers>
91
+ <magesugar>
92
+ <class>Thylak_Magesugar_Helper</class>
93
+ </magesugar>
94
+ </helpers>
95
+ </global>
96
+ </config>
app/design/adminhtml/default/default/layout/magemicrosoft.xml ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+
3
+ <!-- This layout file is used to route the controller and actions -->
4
+
5
+ <layout version="0.1.0">
6
+ <magemicrosoft_adminhtml_magemicrosoft_index>
7
+ <reference name="content">
8
+ <block type="magemicrosoft/adminhtml_magemicrosoft" name="magemicrosoft" />
9
+ </reference>
10
+ </magemicrosoft_adminhtml_magemicrosoft_index>
11
+ <magemicrosoft_adminhtml_magemicrosoft_thanks>
12
+ <reference name="content">
13
+ <block type="magemicrosoft/adminhtml_magemicrosoft" name="magemicrosoft_thanks" />
14
+ </reference>
15
+ </magemicrosoft_adminhtml_magemicrosoft_thanks>
16
+ </layout>
app/design/adminhtml/default/default/template/magemicrosoft/magemicrosoft.phtml ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div class="content-header">
2
+ <table cellspacing="0">
3
+ <tr>
4
+ <td><h3><?php echo 'Magento To Microsoft Dynamic CRM' ?></h3></td>
5
+ </tr>
6
+ </table>
7
+ </div>
8
+ <!--<div><strong>You're one step away from getting this extension. Please contact us to serve you better.<strong></div><br />-->
9
+ <form name="magemicrosoftform" id="magemicrosoftform" method="post" action="<?php echo $this->getUrl('*/*/savemagemicrosoft'); ?>" enctype="multipart/form-data">
10
+ <input name="form_key" type="hidden" value="<?php echo Mage::getSingleton('core/session')->getFormKey() ?>" />
11
+
12
+ <div class="entry-edit" style="background-color:#6f8992;">
13
+ <h4 style="color:#ffffff;"><strong>Contact us for further information</strong></h4>
14
+ </div>
15
+ <div><strong>We have the extension already built and would like to show you a demo of the product to suit your needs. So please enter your contact information below.</strong></div><br />
16
+ <div class="fieldset " id="base_fieldset">
17
+ <div class="hor-scroll">
18
+ <table cellspacing="0" class="form-list" style="background-color:#fafafa;">
19
+ <tbody>
20
+ <tr>
21
+ <td class="label"><label for="firstname"><?php echo Mage::helper('adminhtml')->__('Enter First Name') ?><span style="color:#d40707;">*</span></label></td>
22
+ <td class="value"><input type="text" id="firstname" name="firstname" value="" class="required-entry input-text" /></td>
23
+ </tr>
24
+ <tr>
25
+ <td class="label"><label for="lastname"><?php echo Mage::helper('adminhtml')->__('Enter Last Name') ?></label></td>
26
+ <td class="value"><input type="text" id="lastname" name="lastname" value="" class="input-text" /></td>
27
+ </tr>
28
+ <tr>
29
+ <td class="label"><label for="email"><?php echo Mage::helper('adminhtml')->__('Enter Email Id') ?><span style="color:#d40707;">*</span></label></td>
30
+ <td class="value"><input type="text" id="email" name="email" value="" class="required-entry input-text validate-email" /></td>
31
+ </tr>
32
+ <tr>
33
+ <td class="label"><label for="company"><?php echo Mage::helper('adminhtml')->__('Enter Company Name') ?><span style="color:#d40707;">*</span></label></td>
34
+ <td class="value"><input type="text" id="company" name="company" value="" class="required-entry input-text" /></td>
35
+ </tr>
36
+ <tr>
37
+ <td class="label"><label for="phoneno"><?php echo Mage::helper('adminhtml')->__('Enter Phone Number') ?><span style="color:#d40707;">*</span></label></td>
38
+ <td class="value"><input type="text" id="phoneno" name="phoneno" value="" class="required-entry input-text" /></td>
39
+ </tr>
40
+ <tr>
41
+ <td class="label"><label for="productversion"><?php echo Mage::helper('adminhtml')->__('What version of Microsoft Dynamic CRM do you use?') ?><span style="color:#d40707;">*</span></label></td>
42
+ <td class="value"><input type="text" id="productversion" name="productversion" value="" class="required-entry input-text" /></td>
43
+ </tr>
44
+ <tr>
45
+ <td class="label"><label for="description"><?php echo Mage::helper('adminhtml')->__('Could you please tell me a few words about yourself, your role in your company and what your company does?') ?><span style="color:#d40707;">*</span></label></td>
46
+ <td class="value">
47
+ <textarea id="description" name="description" class="required-entry" ></textarea></td>
48
+ </tr>
49
+ <tr>
50
+ <td class="label"><label for="timetotalk"><?php echo Mage::helper('adminhtml')->__('What is the best time and number to get in touch with you?') ?><span style="color:#d40707;">*</span></label></td>
51
+ <td class="value"><input type="text" id="timetotalk" name="timetotalk" value="" class="required-entry input-text" /></td>
52
+ </tr>
53
+ <tr>
54
+ <td colspan = "2" align="right">
55
+ <div class="form-buttons"><input type="submit" id="magetomicrosoftform" name = "magetomicrosoftform" class="form-button" value="<?php echo 'Submit' ?>" title="<?php echo ' Submit' ?>" /></div>
56
+ </td>
57
+ </tr>
58
+ </tbody>
59
+ </table>
60
+ </div>
61
+ </div>
62
+ </form>
63
+
64
+ <script type="text/javascript">
65
+ var magemicrosoftform = new varienForm('magemicrosoftform');
66
+ </script>
67
+
68
+
69
+
app/design/adminhtml/default/default/template/magemicrosoft/thanks.phtml ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php $name = $this->getRequest()->getParam('fname').' '.$this->getRequest()->getParam('lname'); ?>
2
+ <div class="content-header">
3
+ <table cellspacing="0">
4
+ <tr>
5
+ <td><h3><?php echo 'Thank You Form' ?></h3></td>
6
+ </tr>
7
+ </table>
8
+ </div>
9
+ <div style="background-color:#fafafa;">
10
+ <p>Dear <?php echo $name; ?>,</p><br>
11
+ Thanks for your interest in Magento to Microsoft Dynamic CRM Extension. We would appreciate if you could <br />answer the following questions which would help us to get this right away to you.<br />
12
+ <br />1. What version of salesforce do you use?<br />2. Could you please tell me a few words about yourself, your role in your company and what your company does?<br />3. What is the best time and number to get in touch with you?<br /><br />We would be contacting you soon on your request.<br />Thanks<br /><br />Please click on this link to read further information about this extension.<br /><br /><a href="http://www.thylaksoft.com/Retail/MagentoSoln/MagentoEnterprise.aspx">http://www.thylaksoft.com/Retail/MagentoSoln/MagentoEnterprise.aspx</a><br /><a href="http://www.thylaksoft.com/Retail/MagentoSoln/Magento2Microsoftdynamiccrm.aspx">http://www.thylaksoft.com/Retail/MagentoSoln/Magento2Microsoftdynamiccrm.aspx</a><br /><br />
13
+ Regards,<br />
14
+ The Thylaksoft Team<br />
15
+ 302-355-0449<br />
16
+ www.thylaksoft.com
17
+ </div>
18
+ <!--<div style="background-color:#fafafa;">
19
+ <p>Dear <?php //echo $name; ?>,</p><br>
20
+
21
+ Thank you for expressing interest in learning about one of Thylaksoft's solutions. A member of our team will contact you soon to discuss your needs.<br />If you need to get in touch with us immediately, please call 302-355-0449 and ask for Buyan or Kris and we will be glad to help you rightaway.<br /><br />
22
+
23
+
24
+ Regards,<br />
25
+ The Thylaksoft Team<br />
26
+ 302-355-0449<br />
27
+ www.thylaksoft.com
28
+ </div>
29
+ --><!--<div class="form-buttons" align="right"><a href="" title="Back">Back</a></div>-->
app/etc/modules/Thylak_Magemicrosoft.xml ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+
3
+ <!-- Create a Artist module with the Namespace Thylak
4
+ Here active = true to enable the module and codepool = local
5
+ for notify that it was custom module created in local.-->
6
+
7
+ <config>
8
+ <modules>
9
+ <Thylak_Magemicrosoft>
10
+ <active>true</active>
11
+ <codePool>local</codePool>
12
+ </Thylak_Magemicrosoft>
13
+ </modules>
14
+ </config>
package.xml ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <package>
3
+ <name>SyncwithMicrosoftDynamicCrm</name>
4
+ <version>1.0</version>
5
+ <stability>stable</stability>
6
+ <license uri="http://www.opensource.org/licenses/osl-3.0.php">OSL v3.0</license>
7
+ <channel>community</channel>
8
+ <extends/>
9
+ <summary>This extension would post real time leads from magento to microsoftdynamiccrm automatically. This extension also has the capability to transfer abandoned shopping carts from Magento to microsoftdynamiccrm as opportunities which would allow your sales team to track the opportunity and convert to a sale. We also have a feature where once an opportunity is converted to a sale in microsoftdynamiccrm, it can create an order in magento. Please contact us at 302-355-0449 for further details or email me directly at _mailto:info@thylaksoft.com and _mailto:buyan@talktoaprogrammer.com for further information.</summary>
10
+ <description>This extension would post real time leads from magento to microsoftdynamiccrm automatically. This extension also has the capability to transfer abandoned shopping carts from Magento to microsoftdynamiccrm as opportunities which would allow your sales team to track the opportunity and convert to a sale. We also have a feature where once an opportunity is converted to a sale in microsoftdynamiccrm, it can create an order in magento. Please contact us at 302-355-0449 for further details or email me directly at _mailto:info@thylaksoft.com and _mailto:buyan@talktoaprogrammer.com for further information.</description>
11
+ <notes>This extension would post real time leads from magento to salesforce automatically. This extension also has the capability to transfer abandoned shopping carts from Magento to salesforce as opportunities which would allow your sales team to track the opportunity and convert to a sale. We also have a feature where once an opportunity is converted to a sale in salesforce, it can create an order in magento. Please contact us at 302-355-0449 for further details or email me directly at _mailto:info@thylaksoft.com and _mailto:buyan@talktoaprogrammer.com for further information.</notes>
12
+ <authors><author><name>thylaksoft</name><user>auto-converted</user><email>buyan@talktoaprogrammer.com</email></author></authors>
13
+ <date>2010-06-28</date>
14
+ <time>13:18:10</time>
15
+ <contents><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="magemicrosoft.xml" hash="63935dc7251921e0441e57f2476bd50e"/></dir><dir name="template"><dir name="magemicrosoft"><file name="magemicrosoft.phtml" hash="9f3bc3b5ecb3bc6a2621331ad62569b2"/><file name="thanks.phtml" hash="fe86effafb1826e0beefc88fed06e2d0"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Thylak_Magemicrosoft.xml" hash="f3f053d9cfb7dea7c9f664e026c8170c"/></dir></target><target name="magelocal"><dir name="Thylak"><dir name="Magemicrosoft"><dir name="Block"><dir name="Adminhtml"><dir name="Magemicrosoft"><file name="Magemicrosoft.php" hash="8ed8347a4b9d028c8a2ae27520050971"/><file name="Thanks.php" hash="eb59e3a5e755c11dfd1d348640922767"/></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="MagemicrosoftController.php" hash="a650c1056b40ab7bf0c2a5b52921d921"/></dir></dir><dir name="etc"><file name="config.xml" hash="b27d7c2aac9aee90d8c7a2c3858a6a18"/></dir><dir name="Helper"><file name="Data.php" hash="a552e103918aec7bf7e9507e2836cb19"/></dir><dir name="Model"><file name="Magemicrosoft.php" hash="9139327b129b8dc233984df7c4937058"/></dir></dir><dir name="Magesugar"><dir name="Block"><dir name="Adminhtml"><dir name="Magesugar"><file name="Magesugar.php" hash="a723ceb2896f4ebbc40dc263a1ae1966"/><file name="Thanks.php" hash="1cbdd65065b3933f0016546b13b233d8"/></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="MagesugarController.php" hash="e1918d5754c09374030da665e9e70339"/></dir></dir><dir name="etc"><file name="config.xml" hash="547f073f43791e51ff7fa4122372b428"/></dir><dir name="Helper"><file name="Data.php" hash="5b4e970625ab6139c2d349caa878372a"/></dir><dir name="Model"><file name="Magesugar.php" hash="9e606804822d538837fad1c5a7910be8"/></dir></dir></dir></target></contents>
16
+ <compatible/>
17
+ <dependencies/>
18
+ </package>