Mailingwork_Sync - Version 1.0.1

Version Notes

First Stable Extension Release

Download this release

Release Info

Developer mailingwork GmbH
Extension Mailingwork_Sync
Version 1.0.1
Comparing to
See all releases


Version 1.0.1

app/design/adminhtml/default/default/template/mailingwork/customermap.phtml ADDED
@@ -0,0 +1,91 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * mailignwork GmbH
4
+ *
5
+ * NOTICE OF LICENSE
6
+ *
7
+ * This source file is subject to the Open Software License (OSL 3.0)
8
+ * that is bundled with this package in the file LICENSE.txt.
9
+ * It is also available through the world-wide-web at this URL:
10
+ * http://opensource.org/licenses/osl-3.0.php
11
+ * If you did not receive a copy of the license and are unable to
12
+ * obtain it through the world-wide-web, please send an email
13
+ * to license@magentocommerce.com and you will be sent a copy immediately.
14
+ *
15
+ * @category mailingwork
16
+ * @package Mailingwork_Sync
17
+ * @copyright Copyright (c) 2016 mailingwork GmbH (http://mailingwork.de)
18
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
19
+ */
20
+
21
+ $_htmlId = $this->getHtmlId() ? $this->getHtmlId() : '_' . uniqid();
22
+
23
+ $_colspan = 2;
24
+ if (!$this->_addAfter) {
25
+ $_colspan -= 1;
26
+ }
27
+ $_colspan = $_colspan > 1 ? 'colspan="' . $_colspan . '"' : '';
28
+ ?>
29
+
30
+ <div class="grid" id="grid<?php echo $_htmlId ?>">
31
+ <table cellpadding="0" cellspacing="0" class="border" style="width:400px;">
32
+ <tbody>
33
+
34
+ <tr class="headings" id="headings<?php echo $_htmlId ?>">
35
+ <?php foreach ($this->_columns as $columnName => $column):?>
36
+ <th>
37
+ <?php echo $column['label'] ?>
38
+ </th>
39
+ <?php endforeach;?>
40
+ </tr>
41
+
42
+ <?php foreach ($this->getFieldsForMapping() as $mageFieldGroupKey => $mageFieldGroup): ?>
43
+
44
+ <tr>
45
+ <td colspan="2" style="text-align:center;">
46
+ <b>
47
+ <?php echo $this->__($mageFieldGroupKey); ?>
48
+ </b>
49
+ </td>
50
+ </tr>
51
+ <?php foreach ($mageFieldGroup as $mageField): ?>
52
+ <tr>
53
+ <?php foreach ($this->_columns as $columnName => $column): ?>
54
+ <td>
55
+ <?php
56
+ if ($columnName == 'magento') {
57
+ echo $this->__($mageField);
58
+ } else {
59
+ echo $this->renderMwCellTemplate($columnName, $mageField, $mageFieldGroupKey);
60
+ }
61
+ ?>
62
+ </td>
63
+ <?php endforeach;?>
64
+ </tr>
65
+ <?php endforeach;?>
66
+ <?php endforeach;?>
67
+ </tbody>
68
+ </table>
69
+ <input type="hidden" name="<?php echo $this->getElement()->getName() ?>[__empty]" value="" />
70
+ </div>
71
+ <script>
72
+ var messageType = "<?php echo $this->getMessageType() ?>";
73
+ var message = "<?php echo $this->getMessage() ?>";
74
+ document.addEventListener("DOMContentLoaded", function(event) {
75
+ if (typeof messageType != 'undefined' && messageType == 'error') {
76
+ mt = document.createTextNode(message);
77
+ ul1 = document.createElement('ul');
78
+ ul1.setAttribute('class', "messages");
79
+ li1 = document.createElement('li');
80
+ li1.setAttribute('class', "error-msg");
81
+ ul2 = document.createElement('ul');
82
+ li2 = document.createElement('li');
83
+ li2.appendChild(mt);
84
+ ul2.appendChild(li2);
85
+ li1.appendChild(ul2);
86
+ ul1.appendChild(li1);
87
+ fs = document.getElementById('newsletter_mailingwork_sync');
88
+ fs.insertBefore(ul1, fs.childNodes[1]);
89
+ }
90
+ });
91
+ </script>
app/design/adminhtml/default/default/template/mailingwork/hint.phtml ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * mailignwork GmbH
4
+ *
5
+ * NOTICE OF LICENSE
6
+ *
7
+ * This source file is subject to the Open Software License (OSL 3.0)
8
+ * that is bundled with this package in the file LICENSE.txt.
9
+ * It is also available through the world-wide-web at this URL:
10
+ * http://opensource.org/licenses/osl-3.0.php
11
+ * If you did not receive a copy of the license and are unable to
12
+ * obtain it through the world-wide-web, please send an email
13
+ * to license@magentocommerce.com and you will be sent a copy immediately.
14
+ *
15
+ * @category mailingwork
16
+ * @package Mailingwork_Sync
17
+ * @copyright Copyright (c) 2016 mailingwork GmbH (http://mailingwork.de)
18
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
19
+ */
20
+ ?>
21
+ <div style="background:#EAF0EE;border:1px solid #CCCCCC;margin-bottom:10px;padding:11px 0 0 10px;">
22
+ <h4>
23
+ <img src="https://mailingwork.de/fileadmin/prototyp/img/mailingwork_logo.svg"/><br><br>
24
+ <div style="padding-left: 30px;">
25
+ <p> <strong style="color:#EA7601;">mailingwork v<?php echo $this->getVersion() ?> by</strong> <a target="_blank" href="http://mailingwork.de"><strong>mailingwork</strong></a></p>
26
+ </div>
27
+ </h4>
28
+ </div>
app/design/adminhtml/default/default/template/mailingwork/initialimport.phtml ADDED
@@ -0,0 +1,91 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * mailignwork GmbH
4
+ *
5
+ * NOTICE OF LICENSE
6
+ *
7
+ * This source file is subject to the Open Software License (OSL 3.0)
8
+ * that is bundled with this package in the file LICENSE.txt.
9
+ * It is also available through the world-wide-web at this URL:
10
+ * http://opensource.org/licenses/osl-3.0.php
11
+ * If you did not receive a copy of the license and are unable to
12
+ * obtain it through the world-wide-web, please send an email
13
+ * to license@magentocommerce.com and you will be sent a copy immediately.
14
+ *
15
+ * @category mailingwork
16
+ * @package Mailingwork_Sync
17
+ * @copyright Copyright (c) 2016 mailingwork GmbH (http://mailingwork.de)
18
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
19
+ */
20
+ ?>
21
+ <script>
22
+ //<![CDATA[
23
+ function startInitialImport() {
24
+ var elem = document.getElementById("newsletter_mwsyncimport_message");
25
+ if (elem) {
26
+ elem.parentNode.removeChild(elem);
27
+ }
28
+
29
+ params = {
30
+ importlist: $('<?php /* @escapeNotVerified */ echo $this->getImportListField(); ?>').value,
31
+ storeid: '<?php echo $this->getStoreId(); ?>'
32
+
33
+ };
34
+
35
+ new Ajax.Request('<?php /* @escapeNotVerified */ echo $this->getAjaxUrl() ?>', {
36
+ parameters: params,
37
+ onSuccess: function(response) {
38
+ console.log(response);
39
+ var result = '<?php /* @escapeNotVerified */ echo __('Fehler beim Import!') ?>';
40
+ try {
41
+ console.log(response);
42
+ console.log(response.responseText);
43
+ console.log(response.responseText.isJSON());
44
+ if (response.responseText.isJSON()) {
45
+ response = response.responseText.evalJSON();
46
+ result = response.message;
47
+ console.log(response);
48
+ console.log(result);
49
+ }
50
+ if (response.valid == 1) {
51
+ showMessage(false, result);
52
+ } else {
53
+ showMessage(true, result);
54
+ }
55
+ } catch (e) {
56
+ showMessage(true, result);
57
+ }
58
+ }
59
+ });
60
+ }
61
+
62
+ function showMessage(error, message) {
63
+ console.log(error, message);
64
+ var mt = document.createTextNode(message);
65
+ var ul1 = document.createElement('ul');
66
+ ul1.setAttribute('class', "messages");
67
+ ul1.setAttribute('id', "newsletter_mwsyncimport_message");
68
+ var li1 = document.createElement('li');
69
+ if (error) {
70
+ li1.setAttribute('class', "error-msg");
71
+ } else {
72
+ li1.setAttribute('class', "success-msg");
73
+ }
74
+ var ul2 = document.createElement('ul');
75
+ var li2 = document.createElement('li');
76
+ li2.appendChild(mt);
77
+ ul2.appendChild(li2);
78
+ li1.appendChild(ul2);
79
+ ul1.appendChild(li1);
80
+ var fs = document.getElementById('newsletter_mailingwork_syncimport');
81
+ fs.insertBefore(ul1, fs.childNodes[1]);
82
+ }
83
+
84
+ window.startInitialImport = startInitialImport;
85
+ window.showMessage = showMessage;
86
+ //]]>
87
+
88
+ </script>
89
+
90
+
91
+ <?php echo $this->getButtonHtml() ?>
app/etc/modules/Mailingwork_Sync.xml ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <!--
3
+ /**
4
+ * mailignwork GmbH
5
+ *
6
+ * NOTICE OF LICENSE
7
+ *
8
+ * This source file is subject to the Open Software License (OSL 3.0)
9
+ * that is bundled with this package in the file LICENSE.txt.
10
+ * It is also available through the world-wide-web at this URL:
11
+ * http://opensource.org/licenses/osl-3.0.php
12
+ * If you did not receive a copy of the license and are unable to
13
+ * obtain it through the world-wide-web, please send an email
14
+ * to license@magentocommerce.com and you will be sent a copy immediately.
15
+ *
16
+ * @category mailingwork
17
+ * @package Mailingwork_Sync
18
+ * @copyright Copyright (c) 2016 mailingwork GmbH (http://mailingwork.de)
19
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
20
+ */
21
+ -->
22
+ <config>
23
+ <modules>
24
+ <Mailingwork_Sync>
25
+ <active>true</active>
26
+ <codePool>community</codePool>
27
+ </Mailingwork_Sync>
28
+ </modules>
29
+ </config>
app/locale/de_DE/Mailingwork_Sync.csv ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "username","Benutzername"
2
+ "password","Passwort"
3
+ "list_id","Abonnenten Liste"
4
+ "optin_setup_id_new","Optin-Setup (Neuanmeldung)"
5
+ "optin_setup_id_customer","Optin-Setup (Kunde)"
6
+ "optout_setup_id","Optout-Setup"
7
+ "field_mapping","Feldzuordnung"
8
+ "subscriberdata","Abonnentendaten"
9
+ "customerdata","Kundendaten"
10
+ "billingaddress","Rechnungsanschrift"
11
+ "shippingaddress","Lieferanschrift"
12
+ "orderdata","Bestelldaten"
13
+ "email","E-Mail"
14
+ "is_customer","ist Kunde"
15
+ "store_id","Store ID"
16
+ "prefix","Anrede"
17
+ "firstname","Vorname"
18
+ "lastname","Nachname"
19
+ "last_login_at","letzter Login"
20
+ "group","Kundengruppe"
21
+ "company","Firma"
22
+ "street","Straße"
23
+ "postcode","PLZ"
24
+ "city","Ort"
25
+ "country","Land"
26
+ "telephone","Telefon"
27
+ "count_orders","Anzahl Bestellungen"
28
+ "last_order_at","Datum letzte Bestellung"
29
+ "last_order_amount","Wert letzte Bestellung"
30
+ "all_order_amount","Gesamtwert aller Bestellungen"
31
+ "average_order_amount","durchschnittlicher Bestellwert"
32
+ "last_abandoned_cart","Datum letzter Warenkorbabbruch"
33
+ "mailingwork_initial_import_headline","Mailingwork Initialimport (übertragen der Kundendaten nach Mailingwork)"
34
+ "mailingwork_list_initial_import","Mailingwork Abonnentenliste für Initialimport"
35
+ "mailingwork_initial_import_descr","Nach Klick auf den Button werden die Daten der Newsletterabonennten initial nach Mailingwork übertragen. Dies kann je nach Datenbestand etwas länger dauern. Der Abgleich erfolgt an Hand der E-Mailadresse, es können hierbei ggf. Daten in Mailngwork überschrieben werden!"
app/locale/en_US/Mailingwork_Sync.csv ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "username","Benutzername"
2
+ "password","Passwort"
3
+ "list_id","Abonnenten Liste"
4
+ "optin_setup_id_new","Optin-Setup (Neuanmeldung)"
5
+ "optin_setup_id_customer","Optin-Setup (Kunde)"
6
+ "optout_setup_id","Optout-Setup"
7
+ "field_mapping","Feldzuordnung"
8
+ "subscriberdata","Abonnentendaten"
9
+ "customerdata","Kundendaten"
10
+ "billingaddress","Rechnungsanschrift"
11
+ "shippingaddress","Lieferanschrift"
12
+ "orderdata","Bestelldaten"
13
+ "email","E-Mail"
14
+ "is_customer","ist Kunde"
15
+ "store_id","Store ID"
16
+ "prefix","Anrede"
17
+ "firstname","Vorname"
18
+ "lastname","Nachname"
19
+ "last_login_at","letzter Login"
20
+ "group","Kundengruppe"
21
+ "company","Firma"
22
+ "street","Straße"
23
+ "postcode","PLZ"
24
+ "city","Ort"
25
+ "country","Land"
26
+ "telephone","Telefon"
27
+ "count_orders","Anzahl Bestellungen"
28
+ "last_order_at","Datum letzte Bestellung"
29
+ "last_order_amount","Wert letzte Bestellung"
30
+ "all_order_amount","Gesamtwert aller Bestellungen"
31
+ "average_order_amount","durchschnittlicher Bestellwert"
32
+ "last_abandoned_cart","Datum letzter Warenkorbabbruch"
33
+ "mailingwork_initial_import_headline","Mailingwork Initialimport (übertragen der Kundendaten nach Mailingwork)"
34
+ "mailingwork_list_initial_import","Mailingwork Abonnentenlisten für Initialimport"
35
+ "mailingwork_initial_import_descr","Nach Klick auf den Button werden die Daten der Newsletterabonennten initial nach Mailingwork übertragen. Dies kann je nach Datenbestand etwas länger dauern. Der Abgleich erfolgt an Hand der E-Mailadresse, es können hierbei ggf. Daten in Mailngwork überschrieben werden!"
package.xml ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0"?>
2
+ <package>
3
+ <name>Mailingwork_Sync</name>
4
+ <version>1.0.1</version>
5
+ <stability>stable</stability>
6
+ <license uri="https://opensource.org/licenses/OSL-3.0">OSL-3.0</license>
7
+ <channel>community</channel>
8
+ <extends/>
9
+ <summary>mailingwork E-Mailmarketing connection to Magento</summary>
10
+ <description>Plugin to connect Magento with mailingwork to use mailingwork E-Mail marketing service</description>
11
+ <notes>First Stable Extension Release</notes>
12
+ <authors><author><name>mailingwork GmbH</name><user>mailingwork</user><email>magento@mailingwork.de</email></author></authors>
13
+ <date>2016-09-09</date>
14
+ <time>12:48:13</time>
15
+ <contents><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="template"><dir name="mailingwork"><file name="customermap.phtml" hash="68230b8942d497d2ec55f3b2a3c36f22"/><file name="hint.phtml" hash="45ef33edd0e5e5b8a458b4f213a50924"/><file name="initialimport.phtml" hash="f6790aa1da6d12d5c2dc0400541d2ba6"/></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Mailingwork_Sync.xml" hash="d685fac8dd99b04f24a1b2ec52e83310"/></dir></target><target name="magelocale"><dir name="de_DE"><file name="Mailingwork_Sync.csv" hash="fb2ed931c1045784f313e8858a98f5e2"/></dir><dir name="en_US"><file name="Mailingwork_Sync.csv" hash="70a91df3fa881282c6b9da35802b3766"/></dir></target></contents>
16
+ <compatible/>
17
+ <dependencies><required><php><min>5.3.0</min><max>5.6.24</max></php></required></dependencies>
18
+ </package>