Version Notes
Install/uninstall issue fix
Download this release
Release Info
Developer | EasyAds |
Extension | Advertentieplanet |
Version | 0.0.8 |
Comparing to | |
See all releases |
Version 0.0.8
- app/code/community/Advertentieplanet/Api/Block/Adminhtml/System/Config/Fieldset/Hint.php +14 -0
- app/code/community/Advertentieplanet/Api/Block/System/Config/Form/Field/State.php +21 -0
- app/code/community/Advertentieplanet/Api/Helper/Data.php +8 -0
- app/code/community/Advertentieplanet/Api/Model/Access.php +102 -0
- app/code/community/Advertentieplanet/Api/Model/Api.php +106 -0
- app/code/community/Advertentieplanet/Api/controllers/ConfigController.php +31 -0
- app/code/community/Advertentieplanet/Api/etc/api.xml +50 -0
- app/code/community/Advertentieplanet/Api/etc/config.xml +69 -0
- app/code/community/Advertentieplanet/Api/etc/system.xml +47 -0
- app/design/adminhtml/default/default/template/advertentieplanet/system/config/fieldset/hint.phtml +10 -0
- app/etc/modules/Advertentieplanet_Api.xml +9 -0
- app/locale/nl_NL/Advertentieplanet_Api.csv +9 -0
- package.xml +214 -0
- skin/adminhtml/default/default/images/advertentieplanet/connected.png +0 -0
- skin/adminhtml/default/default/images/advertentieplanet/disconnected.png +0 -0
- skin/adminhtml/default/default/images/advertentieplanet/logo.png +0 -0
app/code/community/Advertentieplanet/Api/Block/Adminhtml/System/Config/Fieldset/Hint.php
ADDED
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class Advertentieplanet_Api_Block_Adminhtml_System_Config_Fieldset_Hint
|
4 |
+
extends Mage_Adminhtml_Block_Abstract
|
5 |
+
implements Varien_Data_Form_Element_Renderer_Interface
|
6 |
+
{
|
7 |
+
protected $_template = 'advertentieplanet/system/config/fieldset/hint.phtml';
|
8 |
+
|
9 |
+
public function render(Varien_Data_Form_Element_Abstract $element)
|
10 |
+
{
|
11 |
+
return $this->toHtml();
|
12 |
+
}
|
13 |
+
}
|
14 |
+
|
app/code/community/Advertentieplanet/Api/Block/System/Config/Form/Field/State.php
ADDED
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Advertentieplanet_Api_Block_System_Config_Form_Field_State extends Mage_Adminhtml_Block_System_Config_Form_Field
|
3 |
+
{
|
4 |
+
protected function _getElementHtml(Varien_Data_Form_Element_Abstract $element)
|
5 |
+
{
|
6 |
+
$guid = Mage::getStoreConfig("advertentieplanet/api/register_guid", 0);
|
7 |
+
$name = Mage::getStoreConfig("advertentieplanet/api/register_name", 0);
|
8 |
+
|
9 |
+
$style = '<style type="text/css">#row_easyads_api_state .scope-label {display:none;}</style>';
|
10 |
+
|
11 |
+
if ($guid == "" || !Mage::getModel('easyads_api/access')->allExists()) {
|
12 |
+
|
13 |
+
$url = Mage::helper('adminhtml')->getUrl('admin_advertentieplanetapi/config/connect');
|
14 |
+
return '<img style="float:left;margin: 1px 5px 0 0;" src="'.$this->getSkinUrl('images/advertentieplanet/disconnected.png').'"/><a style="float:left;width:275px;" target="_blank" href="' . $url . '">' . $this->__('Disconnected, click to connect') . '</a><div style="clear:both;width:1px;height:1px;overflow:hidden;font-size:1px;"> </div>'.$style;
|
15 |
+
} else {
|
16 |
+
|
17 |
+
$url = Mage::helper('adminhtml')->getUrl('admin_advertentieplanetapi/config/disconnect');
|
18 |
+
return '<img style="float:left;margin: 1px 5px 0 0;" src="'.$this->getSkinUrl('images/advertentieplanet/connected.png').'"/> <a style="float:left;width:275px;" target="_blank" href="' . $url . '">' . $this->__("Connected with account '%s',<br/>click to disconnect", $name) . '</a><div style="clear:both;width:1px;height:1px;overflow:hidden;font-size:1px;"> </div>'.$style;
|
19 |
+
}
|
20 |
+
}
|
21 |
+
}
|
app/code/community/Advertentieplanet/Api/Helper/Data.php
ADDED
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Advertentieplanet_Api_Helper_Data extends Mage_Core_Helper_Data
|
3 |
+
{
|
4 |
+
public function getExtensionVersion()
|
5 |
+
{
|
6 |
+
return (string) Mage::getConfig()->getNode()->modules->Advertentieplanet_Api->version;
|
7 |
+
}
|
8 |
+
}
|
app/code/community/Advertentieplanet/Api/Model/Access.php
ADDED
@@ -0,0 +1,102 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Advertentieplanet_Api_Model_Access {
|
3 |
+
|
4 |
+
private $username = "Advertentieplanet";
|
5 |
+
private $rolename = "Advertentieplanet_Product_Exporter";
|
6 |
+
|
7 |
+
public function allExists() {
|
8 |
+
|
9 |
+
return ($this->userExists() && $this->roleExists());
|
10 |
+
}
|
11 |
+
|
12 |
+
public function createUser() {
|
13 |
+
|
14 |
+
//chars
|
15 |
+
$chars = Mage_Core_Helper_Data::CHARS_PASSWORD_LOWERS
|
16 |
+
. Mage_Core_Helper_Data::CHARS_PASSWORD_UPPERS
|
17 |
+
. Mage_Core_Helper_Data::CHARS_PASSWORD_DIGITS;
|
18 |
+
|
19 |
+
//generate new API key
|
20 |
+
$api_key = Mage::helper('core')->getRandomString(24, $chars);
|
21 |
+
|
22 |
+
//create user
|
23 |
+
$userapi = $this->getUser();
|
24 |
+
if (!$userapi->getId()) {
|
25 |
+
$userapi = Mage::getModel('api/user')->setData(array(
|
26 |
+
'username' => $this->username,
|
27 |
+
'firstname' => $this->username,
|
28 |
+
'lastname' => 'API',
|
29 |
+
'email' => 'api@advertentieplanet.nl',
|
30 |
+
'api_key' => $api_key,
|
31 |
+
'api_key_confirmation' => $api_key,
|
32 |
+
'is_active' => 1));
|
33 |
+
$userapi->save();
|
34 |
+
} else {
|
35 |
+
$userapi->setApiKey($api_key);
|
36 |
+
$userapi->setApiKeyConfirmation($api_key);
|
37 |
+
$userapi->setIsActive(1);
|
38 |
+
$userapi->save();
|
39 |
+
}
|
40 |
+
|
41 |
+
//
|
42 |
+
$userapi->setRoleIds(array($this->getRole()->getId())) // your created custom role
|
43 |
+
->setRoleUserId($userapi->getUserId())
|
44 |
+
->saveRelations();
|
45 |
+
|
46 |
+
//return credentials
|
47 |
+
return array(
|
48 |
+
"api_key" => $api_key,
|
49 |
+
"username" => $this->username);
|
50 |
+
}
|
51 |
+
|
52 |
+
public function userExists() {
|
53 |
+
|
54 |
+
return ($this->getUser()->getId() != false);
|
55 |
+
}
|
56 |
+
|
57 |
+
public function createRole() {
|
58 |
+
|
59 |
+
//create role when not exists
|
60 |
+
if (!$this->roleExists()) {
|
61 |
+
$role = Mage::getModel('api/roles')
|
62 |
+
->setName($this->rolename)
|
63 |
+
->setPid(false)
|
64 |
+
->setRoleType('G')
|
65 |
+
->save();
|
66 |
+
}
|
67 |
+
|
68 |
+
//attach rule to role
|
69 |
+
Mage::getModel("api/rules")
|
70 |
+
->setRoleId($this->getRole()->getId())
|
71 |
+
->setResources(array('all'))
|
72 |
+
->saveRel();
|
73 |
+
}
|
74 |
+
|
75 |
+
public function roleExists() {
|
76 |
+
|
77 |
+
return ($this->getRole()->getId() != false);
|
78 |
+
}
|
79 |
+
|
80 |
+
public function removeUserAndRole() {
|
81 |
+
|
82 |
+
//remove user
|
83 |
+
$user = $this->getUser();
|
84 |
+
if ($user->getId() != false)
|
85 |
+
$user->delete();
|
86 |
+
|
87 |
+
//remove role
|
88 |
+
$role = $this->getRole();
|
89 |
+
if ($role->getId() != false)
|
90 |
+
$role->delete();
|
91 |
+
}
|
92 |
+
|
93 |
+
private function getUser() {
|
94 |
+
|
95 |
+
return Mage::getModel('api/user')->load($this->username, 'username');
|
96 |
+
}
|
97 |
+
|
98 |
+
private function getRole() {
|
99 |
+
|
100 |
+
return Mage::getModel('api/roles')->load($this->rolename, 'role_name');
|
101 |
+
}
|
102 |
+
}
|
app/code/community/Advertentieplanet/Api/Model/Api.php
ADDED
@@ -0,0 +1,106 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Advertentieplanet_Api_Model_Api extends Mage_Api_Model_Resource_Abstract {
|
3 |
+
|
4 |
+
public function register($name, $guid) {
|
5 |
+
|
6 |
+
try {
|
7 |
+
|
8 |
+
$config = new Mage_Core_Model_Config();
|
9 |
+
$config ->saveConfig("advertentieplanet/api/register_name", $name, 'default', 0);
|
10 |
+
$config ->saveConfig("advertentieplanet/api/register_guid", $guid, 'default', 0);
|
11 |
+
Mage::app()->cleanCache();
|
12 |
+
}
|
13 |
+
catch (Exception $e) {
|
14 |
+
$this->_fault('general_error', $e->getMessage());
|
15 |
+
}
|
16 |
+
|
17 |
+
return true;
|
18 |
+
}
|
19 |
+
|
20 |
+
public function unregister() {
|
21 |
+
|
22 |
+
try {
|
23 |
+
|
24 |
+
//remove from config
|
25 |
+
$config = new Mage_Core_Model_Config();
|
26 |
+
$config ->saveConfig("advertentieplanet/api/register_name", '', 'default', 0);
|
27 |
+
$config ->saveConfig("advertentieplanet/api/register_guid", '', 'default', 0);
|
28 |
+
|
29 |
+
//remove api user
|
30 |
+
Mage::getModel('easyads_api/access')->removeUserAndRole();
|
31 |
+
Mage::app()->cleanCache();
|
32 |
+
}
|
33 |
+
catch (Exception $e) {
|
34 |
+
$this->_fault('general_error', $e->getMessage());
|
35 |
+
}
|
36 |
+
|
37 |
+
return true;
|
38 |
+
}
|
39 |
+
|
40 |
+
public function productlist($store_id, $limit, $page) {
|
41 |
+
|
42 |
+
//result object
|
43 |
+
$productResult = new StdClass();
|
44 |
+
$productResult->total = 0;
|
45 |
+
$productResult->products = array();
|
46 |
+
|
47 |
+
|
48 |
+
//set collection
|
49 |
+
$productCollection = Mage::getModel('catalog/product')
|
50 |
+
->getCollection()
|
51 |
+
->addAttributeToSelect('*')
|
52 |
+
// removing attribute
|
53 |
+
->removeAttributeToSelect('stock_item')
|
54 |
+
->removeAttributeToSelect('custom_layout_update')
|
55 |
+
->removeAttributeToSelect('request_path')
|
56 |
+
->removeAttributeToSelect('media_gallery')
|
57 |
+
// visibility not equil "Not Visible Individually"
|
58 |
+
->addAttributeToFilter('visibility', array('neq' => 1))
|
59 |
+
->addAttributeToFilter('status', 1)
|
60 |
+
->setPageSize($limit)
|
61 |
+
->setCurPage($page);
|
62 |
+
|
63 |
+
if ($store_id != 0) {
|
64 |
+
$productCollection->setStoreId($store_id);
|
65 |
+
}
|
66 |
+
|
67 |
+
$imageBaseUrl = Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA) . 'catalog/product';
|
68 |
+
|
69 |
+
//loop products
|
70 |
+
foreach ($productCollection as $product) {
|
71 |
+
|
72 |
+
//get product data and remove un necessary data
|
73 |
+
$productData = $product->getData();
|
74 |
+
|
75 |
+
//add product categories
|
76 |
+
$productData["category_ids"] = $product->getCategoryIds();
|
77 |
+
|
78 |
+
//add product images
|
79 |
+
$productData["images"] = array();
|
80 |
+
$productData["images_excluded"] = array();
|
81 |
+
|
82 |
+
// load the Media Images
|
83 |
+
$product->load('media_gallery');
|
84 |
+
foreach ($product->getMediaGallery('images') as $image) {
|
85 |
+
|
86 |
+
// check if image is disabled
|
87 |
+
if($image["disabled"] == 1) {
|
88 |
+
$productData["images_excluded"][] = $imageBaseUrl.$image['file'];
|
89 |
+
} else {
|
90 |
+
$productData["images"][] = $imageBaseUrl.$image['file'];
|
91 |
+
}
|
92 |
+
}
|
93 |
+
|
94 |
+
|
95 |
+
//add to result
|
96 |
+
$productResult->products[] = $productData;
|
97 |
+
|
98 |
+
}
|
99 |
+
|
100 |
+
//set total
|
101 |
+
$productResult->total = $productCollection->getSize();
|
102 |
+
|
103 |
+
return $productResult;
|
104 |
+
|
105 |
+
}
|
106 |
+
}
|
app/code/community/Advertentieplanet/Api/controllers/ConfigController.php
ADDED
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Advertentieplanet_Api_ConfigController extends Mage_Adminhtml_Controller_Action
|
3 |
+
{
|
4 |
+
public function connectAction()
|
5 |
+
{
|
6 |
+
//create role
|
7 |
+
Mage::getModel('easyads_api/access')->createRole();
|
8 |
+
|
9 |
+
//create user
|
10 |
+
$credentials = Mage::getModel('easyads_api/access')->createUser();
|
11 |
+
|
12 |
+
$params = array();
|
13 |
+
$params["username"] = $credentials["username"];
|
14 |
+
$params["api_key"] = $credentials["api_key"];
|
15 |
+
$params["mage_version"] = Mage::getVersion();
|
16 |
+
$params["plugin_version"] = Mage::helper('easyads_api')->getExtensionVersion();
|
17 |
+
$params["api"] = Mage::getBaseUrl() . "api/xmlrpc/";
|
18 |
+
Mage::app()->cleanCache();
|
19 |
+
|
20 |
+
$this->_redirectUrl("https://app.advertentieplanet.nl/link/magento?" . http_build_query($params,PHP_QUERY_RFC3986,'&'));
|
21 |
+
}
|
22 |
+
|
23 |
+
public function disconnectAction() {
|
24 |
+
|
25 |
+
$params = array();
|
26 |
+
$params["guid"] = Mage::getStoreConfig("advertentieplanet/api/register_guid", 0);
|
27 |
+
Mage::app()->cleanCache();
|
28 |
+
|
29 |
+
$this->_redirectUrl("https://app.advertentieplanet.nl/unlink/magento?" . http_build_query($params,PHP_QUERY_RFC3986,'&'));
|
30 |
+
}
|
31 |
+
}
|
app/code/community/Advertentieplanet/Api/etc/api.xml
ADDED
@@ -0,0 +1,50 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<api>
|
4 |
+
<resources>
|
5 |
+
<easyads_api translate="title" module="easyads_api">
|
6 |
+
<title>Advertentieplanet Resource</title>
|
7 |
+
<model>easyads_api/api</model>
|
8 |
+
<acl>easyads_api</acl>
|
9 |
+
<methods>
|
10 |
+
<register translate="title" module="easyads_api">
|
11 |
+
<title>Register</title>
|
12 |
+
<acl>easyads_api/register</acl>
|
13 |
+
</register>
|
14 |
+
<unregister translate="title" module="easyads_api">
|
15 |
+
<title>Unregister</title>
|
16 |
+
<acl>easyads_api/unregister</acl>
|
17 |
+
</unregister>
|
18 |
+
<productlist translate="title" module="easyads_api">
|
19 |
+
<title>Productlist</title>
|
20 |
+
<acl>easyads_api/productlist</acl>
|
21 |
+
</productlist>
|
22 |
+
</methods>
|
23 |
+
<faults module="easyads_api">
|
24 |
+
<general_error>
|
25 |
+
<code>100</code>
|
26 |
+
<message>General error</message>
|
27 |
+
</general_error>
|
28 |
+
</faults>
|
29 |
+
</easyads_api>
|
30 |
+
</resources>
|
31 |
+
<acl>
|
32 |
+
<resources>
|
33 |
+
<easyads_api translate="title" module="easyads_api">
|
34 |
+
<title>Markteed Api</title>
|
35 |
+
<register translate="title" module="easyads_api">
|
36 |
+
<title>Register</title>
|
37 |
+
</register>
|
38 |
+
<unregister translate="title" module="easyads_api">
|
39 |
+
<title>Unregister</title>
|
40 |
+
</unregister>
|
41 |
+
<productlist translate="title" module="easyads_api">
|
42 |
+
<title>Productlist</title>
|
43 |
+
</productlist>
|
44 |
+
</easyads_api>
|
45 |
+
<all>
|
46 |
+
</all>
|
47 |
+
</resources>
|
48 |
+
</acl>
|
49 |
+
</api>
|
50 |
+
</config>
|
app/code/community/Advertentieplanet/Api/etc/config.xml
ADDED
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<modules>
|
4 |
+
<Advertentieplanet_Api>
|
5 |
+
<version>0.2.0</version>
|
6 |
+
</Advertentieplanet_Api>
|
7 |
+
</modules>
|
8 |
+
<admin>
|
9 |
+
<routers>
|
10 |
+
<admin_advertentieplanetapi>
|
11 |
+
<use>admin</use>
|
12 |
+
<args>
|
13 |
+
<module>Advertentieplanet_Api</module>
|
14 |
+
<frontName>admin_advertentieplanetapi</frontName>
|
15 |
+
</args>
|
16 |
+
</admin_advertentieplanetapi>
|
17 |
+
</routers>
|
18 |
+
</admin>
|
19 |
+
<adminhtml>
|
20 |
+
<acl>
|
21 |
+
<resources>
|
22 |
+
<all>
|
23 |
+
<title>Allow Everything</title>
|
24 |
+
</all>
|
25 |
+
<admin>
|
26 |
+
<children>
|
27 |
+
<system>
|
28 |
+
<children>
|
29 |
+
<config>
|
30 |
+
<children>
|
31 |
+
<advertentieplanet>
|
32 |
+
<title>Advertentieplanet - All</title>
|
33 |
+
</advertentieplanet>
|
34 |
+
</children>
|
35 |
+
</config>
|
36 |
+
</children>
|
37 |
+
</system>
|
38 |
+
</children>
|
39 |
+
</admin>
|
40 |
+
</resources>
|
41 |
+
</acl>
|
42 |
+
<translate>
|
43 |
+
<modules>
|
44 |
+
<Advertentieplanet_Api>
|
45 |
+
<files>
|
46 |
+
<default>Advertentieplanet_Api.csv</default>
|
47 |
+
</files>
|
48 |
+
</Advertentieplanet_Api>
|
49 |
+
</modules>
|
50 |
+
</translate>
|
51 |
+
</adminhtml>
|
52 |
+
<global>
|
53 |
+
<models>
|
54 |
+
<easyads_api>
|
55 |
+
<class>Advertentieplanet_Api_Model</class>
|
56 |
+
</easyads_api>
|
57 |
+
</models>
|
58 |
+
<blocks>
|
59 |
+
<easyads_api>
|
60 |
+
<class>Advertentieplanet_Api_Block</class>
|
61 |
+
</easyads_api>
|
62 |
+
</blocks>
|
63 |
+
<helpers>
|
64 |
+
<easyads_api>
|
65 |
+
<class>Advertentieplanet_Api_Helper</class>
|
66 |
+
</easyads_api>
|
67 |
+
</helpers>
|
68 |
+
</global>
|
69 |
+
</config>
|
app/code/community/Advertentieplanet/Api/etc/system.xml
ADDED
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
+
<config>
|
3 |
+
<tabs>
|
4 |
+
<advertentieplanet translate="label" module="easyads_api">
|
5 |
+
<label>Advertentieplanet</label>
|
6 |
+
<sort_order>100</sort_order>
|
7 |
+
</advertentieplanet>
|
8 |
+
</tabs>
|
9 |
+
<sections>
|
10 |
+
<advertentieplanet translate="label" module="easyads_api">
|
11 |
+
<label>API settings</label>
|
12 |
+
<tab>advertentieplanet</tab>
|
13 |
+
<sort_order>1000</sort_order>
|
14 |
+
<show_in_default>1</show_in_default>
|
15 |
+
<show_in_website>1</show_in_website>
|
16 |
+
<show_in_store>1</show_in_store>
|
17 |
+
<groups>
|
18 |
+
|
19 |
+
<hint>
|
20 |
+
<frontend_model>easyads_api/adminhtml_system_config_fieldset_hint</frontend_model>
|
21 |
+
<sort_order>0</sort_order>
|
22 |
+
<show_in_default>1</show_in_default>
|
23 |
+
<show_in_website>1</show_in_website>
|
24 |
+
<show_in_store>1</show_in_store>
|
25 |
+
</hint>
|
26 |
+
<api translate="label" module="easyads_api">
|
27 |
+
<expanded>1</expanded>
|
28 |
+
<label>API settings</label>
|
29 |
+
<frontend_type>text</frontend_type>
|
30 |
+
<sort_order>1000</sort_order>
|
31 |
+
<show_in_default>1</show_in_default>
|
32 |
+
<show_in_website>1</show_in_website>
|
33 |
+
<show_in_store>1</show_in_store>
|
34 |
+
<fields>
|
35 |
+
<state translate="label">
|
36 |
+
<label>State</label>
|
37 |
+
<frontend_type>text</frontend_type>
|
38 |
+
<sort_order>10</sort_order>
|
39 |
+
<show_in_default>1</show_in_default>
|
40 |
+
<frontend_model>easyads_api/system_config_form_field_state</frontend_model>
|
41 |
+
</state>
|
42 |
+
</fields>
|
43 |
+
</api>
|
44 |
+
</groups>
|
45 |
+
</advertentieplanet>
|
46 |
+
</sections>
|
47 |
+
</config>
|
app/design/adminhtml/default/default/template/advertentieplanet/system/config/fieldset/hint.phtml
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<div class="box">
|
2 |
+
<img src="<?php echo $this->getSkinUrl('images/advertentieplanet/logo.png'); ?>" style="float:left;margin: 18px 30px 0 10px;"/>
|
3 |
+
<p>
|
4 |
+
Plaats, beheer, analyseer je producten en verkopen eenvoudig op alle marktplaatsen, shoppingsites en verkoopkanalen.
|
5 |
+
AdvertentiePlanet is een gebruiksvriendelijke multi-channel tool voor webshophouders en marketeers.
|
6 |
+
</p>
|
7 |
+
|
8 |
+
<p>Voor documentatie en ondersteuning zie <a href="http://www.advertentieplanet.nl" target="_blank">advertentieplanet.nl</a></p>
|
9 |
+
<div style="clear:both;width:1px;height:1px;font-size:1px;overflow:hidden;"> </div>
|
10 |
+
</div>
|
app/etc/modules/Advertentieplanet_Api.xml
ADDED
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
+
<config>
|
3 |
+
<modules>
|
4 |
+
<Advertentieplanet_Api>
|
5 |
+
<active>true</active>
|
6 |
+
<codePool>community</codePool>
|
7 |
+
</Advertentieplanet_Api>
|
8 |
+
</modules>
|
9 |
+
</config>
|
app/locale/nl_NL/Advertentieplanet_Api.csv
ADDED
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
"API settings", "Koppeling instellingen"
|
2 |
+
"API", "API"
|
3 |
+
"Advertentieplanet", "Advertentieplanet"
|
4 |
+
"State", "Status"
|
5 |
+
"Connect", "Verbinding"
|
6 |
+
"Advertentieplanet - All", "Advertentieplanet - Alles"
|
7 |
+
"Reconnect", "Opnieuw verbinding maken"
|
8 |
+
"Disconnected, click to connect", "Verbinding verboken, klik om verbinding te maken"
|
9 |
+
"Connected with account '%s',<br/>click to disconnect", "Verbonden met account '%s',<br/>klik om de verbinding te verbreken"
|
package.xml
ADDED
@@ -0,0 +1,214 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<package>
|
3 |
+
<name>Advertentieplanet</name>
|
4 |
+
<version>0.0.8</version>
|
5 |
+
<stability>stable</stability>
|
6 |
+
<license uri="http://www.opensource.org/licenses/mit-license.php">MIT License</license>
|
7 |
+
<channel>community</channel>
|
8 |
+
<extends/>
|
9 |
+
<summary>Publish, manage, analyze your products and sell them on all major sales channels with AdvertentiePlanet!</summary>
|
10 |
+
<description><p>
|
11 |
+
<a href="https://www.advertentieplanet.nl">AdvertentiePlanet</a> enables Magento shops to publish, manage, analyze products and sell them easily on all market places, shopping sites and sales channels. AdvertentiePlanet is an easy to use multichannel tool for shop owners and marketing professionals. Prices start at €39/ month and an AdvertentiePlanet account is required. <strong>Try AdvertentiePlanet 30 days for free!</strong> <a href="https://youtu.be/XB_BKpPak-M">Watch our video</a></p>
|
12 |
+
<h3>
|
13 |
+
Main features</h3>
|
14 |
+
<ul>
|
15 |
+
<li>Automatic publishing, managing and analyzing of your ads on all relevant sales channels</li>
|
16 |
+
<li>Optimization, maintenance and monitoring by the AdvertentiePlanet team</li>
|
17 |
+
<li>Detailed overview of your ads, cost and sales</li>
|
18 |
+
</ul>
|
19 |
+
|
20 |
+
<h3>
|
21 |
+
The tool for online marketplaces</h3>
|
22 |
+
<p>
|
23 |
+
With AdvertentiePlanet you can advertise on all relevant free, paid and international sales channels. AdvertentiePlanet has extensive real-time integrations and you can connect it easily with your online store. In the dashboard, you can manage your placements and understand statistics.</p>
|
24 |
+
<h3>
|
25 |
+
1.	Full service</h3>
|
26 |
+
<p>AdvertentiePlanet does the set-up for you. Free of charge!</p>
|
27 |
+
<h3>
|
28 |
+
2.	Free, paid and international sales channels</h3>
|
29 |
+
<p>Publish your products automatically on all major sales channels such as Marktplaats.nl, bol.com, Google Shopping, Beslist and Kieskeurig. Do you sell abroad and do you have an international online shop? Use one of the many European sales channels like Amazon, eBay, Rakuten or Kelkoo. Besides the paid marketplaces and shopping sites, AdvertentiePlanet has unique links with many relevant free sales channels to supplement your paid campaigns.</p>
|
30 |
+
<h3>
|
31 |
+
3.	Measure your performance</h3>
|
32 |
+
<p>See how your ads perform individually and collectively; apply filters and check out the past performance of your products.</p>
|
33 |
+
<h3>
|
34 |
+
4.	All the tools you need</h3>
|
35 |
+
<p>A system that everyone understands, but what you can do anything with it? AdvertentiePlanet is designed for shop owners, but also for marketeers who want to optimize their campaigns.</p>
|
36 |
+
<h3>
|
37 |
+
5.	Risk-Free Trial</h3>
|
38 |
+
<ul>
|
39 |
+
	<li>- Free, paid and international marketplaces</li>
|
40 |
+
	<li>- Advanced data feed management</li>
|
41 |
+
	<li>- Extensive reporting of your ad performance per sales channel</li>
|
42 |
+
	<li>- 30 days free (including free setup)</li>
|
43 |
+
	<li>- No set-up fees or notice periods and no contracts</li>
|
44 |
+
</ul>
|
45 |
+
|
46 |
+
<h3>
|
47 |
+
About partner</h3>
|
48 |
+
<p>AdvertentiePlanet is a brand of EasyAds. We are the experts when it comes to connections with online marketplaces and sales channels. We support online shop owners with selling their products efficiently and fast.</p>
|
49 |
+
|
50 |
+
<h3>
|
51 |
+
Support</h3>
|
52 |
+
<p>The AdvertentiePlanet team is happy to answer all your questions. You can either mail to support@advertentieplanet.nl or give us call us on 088 4800 800 (local Dutch number) or +31 (0) 346 712 461 (when you’re calling from outside the Netherlands).</p>
|
53 |
+
<hr />
|
54 |
+
<h2>
|
55 |
+
<a href="https://www.advertentieplanet.nl">AdvertentiePlanet</a> – Plaats je producten eenvoudig op alle grote verkoopkanalen</h2>
|
56 |
+
<p>
|
57 |
+
Plaats, beheer, analyseer je producten en verkopen eenvoudig op alle marktplaatsen, shoppingsites en verkoopkanalen. AdvertentiePlanet is een gebruiksvriendelijke multi-channel tool voor webshophouders en marketeers. <strong>Probeer AdvertentiePlanet nu 30 dagen gratis uit!</strong> <a href="https://youtu.be/XB_BKpPak-M">Bekijk onze video</a></p>
|
58 |
+
<h3>
|
59 |
+
Belangrijkste functies</h3>
|
60 |
+
<ul>
|
61 |
+
<li>Automatisch plaatsen, beheren en analyseren van je advertenties</li>
|
62 |
+
<li>Optimalisatie, onderhoud en monitoring door het AdvertentiePlanet team </li>
|
63 |
+
<li>Duidelijke overzicht van je advertenties, kosten en statistieken</li>
|
64 |
+
</ul>
|
65 |
+
|
66 |
+
<h3>
|
67 |
+
Dé tool voor online marktplaatsen</h3>
|
68 |
+
<p>
|
69 |
+
AdvertentiePlanet is een multi-channel tool die onderdeel is van EasyAds B.V. We onderhouden koppelingen met alle grote verkoopkanalen en bieden full service productplaatsingen aan voor het MKB en webshops in Nederland.</p>
|
70 |
+
<h3>
|
71 |
+
Op alle belangrijke verkoopkanalen adverteren met één tool</h3>
|
72 |
+
<p>
|
73 |
+
AdvertentiePlanet is een multi-channel tool die onderdeel is van EasyAds B.V. We onderhouden koppelingen met alle grote verkoopkanalen en bieden full service productplaatsingen aan voor het MKB en webshops in Nederland.</p>
|
74 |
+
<h3>
|
75 |
+
1.	Full service</h3>
|
76 |
+
<p>AdvertentiePlanet regelt gratis de eerste instellingen en koppelt initieel al je producten voor je, zodat je daarna meteen van start kan.</p>
|
77 |
+
<h3>
|
78 |
+
2.	Cost control Marktplaats Admarkt</h3>
|
79 |
+
<p>Bepaal wat je maximaal wilt uitgeven per maand voor alle advertenties. Geen verrassingen meer!</p>
|
80 |
+
<h3>
|
81 |
+
3.	Gratis, betaald en internationaal verkopen</h3>
|
82 |
+
<p>Plaats je producten eenvoudig op alle bekende Nederlandse verkoopkanalen zoals Marktplaats.nl, Bol.com, Google Shopping, Beslist en Kieskeurig. Verkoop je ook in het buitenland en heb je een internationale webshop? Gebruik dan één van de vele Europese verkoopkanalen zoals Amazon, eBay, Rakuten of Kelkoo. Naast betaalde marktplaatsen en shoppingsites, heeft AdvertentiePlanet unieke koppelingen met veel relevante GRATIS verkoopkanalen als aanvulling op je betaalde campagnes.</p>
|
83 |
+
<h3>
|
84 |
+
4.	Performance meten</h3>
|
85 |
+
<p>Bekijk hoe je advertenties het individueel en collectief doen met demogelijkheid om uitgebreid te filteren en de historie op te vragen.</p>
|
86 |
+
<h3>
|
87 |
+
5.	Risicoloos proberen</h3>
|
88 |
+
<ul>
|
89 |
+
	<li>- Gratis, betaalde en internationale marktplaatsen</li>
|
90 |
+
	<li>- Uitgebreid datafeed management</li>
|
91 |
+
	<li>- Uitgebreide rapportage over je advertenties, de prestaties van je advertenties en de actieve verkoopkanalen</li>
|
92 |
+
	<li>- Cost control Marktplaats Admarkt</li>
|
93 |
+
	<li>- 30 dagen gratis testen</li>
|
94 |
+
	<li>- Geen set-up kosten of opzegtermijnen en geen contracten</li>
|
95 |
+
</ul>
|
96 |
+
|
97 |
+
<h3>
|
98 |
+
Over partner</h3>
|
99 |
+
<p>AdvertentiePlanet is een innovatieve tool die onderdeel is van EasyAds. We zijn marktleider op gebied van geautomatiseerde advertentieplaatsingen.</p>
|
100 |
+
|
101 |
+
<h3>
|
102 |
+
Support</h3>
|
103 |
+
<p>Bel of mail het AdvertentiePlanet team, we helpen je graag verder! support@advertentieplanet.nl - een beller is sneller via 088 4800 800.</p></description>
|
104 |
+
<notes>Install/uninstall issue fix</notes>
|
105 |
+
<authors>
|
106 |
+
<author>
|
107 |
+
<name>EasyAds</name>
|
108 |
+
<user>MAG002936376</user>
|
109 |
+
<email>development@easyads.eu</email>
|
110 |
+
</author>
|
111 |
+
</authors>
|
112 |
+
<date>2016-09-08</date>
|
113 |
+
<time>21:20:30</time>
|
114 |
+
<contents>
|
115 |
+
<target name="magecommunity">
|
116 |
+
<dir name="Advertentieplanet">
|
117 |
+
<dir name="Api">
|
118 |
+
<dir>
|
119 |
+
<dir name="Block">
|
120 |
+
<dir name="Adminhtml">
|
121 |
+
<dir name="System">
|
122 |
+
<dir name="Config">
|
123 |
+
<dir name="Fieldset">
|
124 |
+
<file name="Hint.php" hash="4fad0e8a5ce782980266e56c40fbd72b" />
|
125 |
+
</dir>
|
126 |
+
</dir>
|
127 |
+
</dir>
|
128 |
+
</dir>
|
129 |
+
<dir name="System">
|
130 |
+
<dir name="Config">
|
131 |
+
<dir name="Form">
|
132 |
+
<dir name="Field">
|
133 |
+
<file name="State.php" hash="6fe8b8065ba92b495781274f1761a1bd" />
|
134 |
+
</dir>
|
135 |
+
</dir>
|
136 |
+
</dir>
|
137 |
+
</dir>
|
138 |
+
</dir>
|
139 |
+
<dir name="Helper">
|
140 |
+
<file name="Data.php" hash="21c201914e6ae4003f284e8ef8beeecc" />
|
141 |
+
</dir>
|
142 |
+
<dir name="Model">
|
143 |
+
<file name="Access.php" hash="cfb795ce38f5fe176871e5d2396538f1" />
|
144 |
+
<file name="Api.php" hash="5da96e1d73b2c29eb5e862634e566a59" />
|
145 |
+
</dir>
|
146 |
+
<dir name="controllers">
|
147 |
+
<file name="ConfigController.php" hash="9f8276e262f80239e881dc1195d4de11" />
|
148 |
+
</dir>
|
149 |
+
<dir name="etc">
|
150 |
+
<file name="api.xml" hash="ab48b25688c46bf31dccd2a2efbd68d9" />
|
151 |
+
<file name="config.xml" hash="ecc36c8699e1a916fc1d39a6309a9c37" />
|
152 |
+
<file name="system.xml" hash="bd38176e97b0a2697e2bdadd853ad77f" />
|
153 |
+
</dir>
|
154 |
+
</dir>
|
155 |
+
</dir>
|
156 |
+
</dir>
|
157 |
+
</target>
|
158 |
+
<target name="mageetc">
|
159 |
+
<dir name="modules">
|
160 |
+
<file name="Advertentieplanet_Api.xml" hash="88d987b66ea13147cc928574f556acae" />
|
161 |
+
</dir>
|
162 |
+
</target>
|
163 |
+
<target name="mageskin">
|
164 |
+
<dir name="adminhtml">
|
165 |
+
<dir name="default">
|
166 |
+
<dir name="default">
|
167 |
+
<dir name="images">
|
168 |
+
<dir name="advertentieplanet">
|
169 |
+
<file name="connected.png" hash="b4ea92038d64fe62aaf9ccd78214d026" />
|
170 |
+
<file name="disconnected.png" hash="b48ea8cabc59712048c74ed72728dedc" />
|
171 |
+
<file name="logo.png" hash="ce3cb3bdce3ef16e744d1af04b49b0c5" />
|
172 |
+
</dir>
|
173 |
+
</dir>
|
174 |
+
</dir>
|
175 |
+
</dir>
|
176 |
+
</dir>
|
177 |
+
</target>
|
178 |
+
<target name="magelocale">
|
179 |
+
<dir name="nl_NL">
|
180 |
+
<file name="Advertentieplanet_Api.csv" hash="37f44855ab4779a50fc92543c56ec623" />
|
181 |
+
</dir>
|
182 |
+
</target>
|
183 |
+
<target name="magedesign">
|
184 |
+
<dir name="adminhtml">
|
185 |
+
<dir name="default">
|
186 |
+
<dir name="default">
|
187 |
+
<dir name="template">
|
188 |
+
<dir name="advertentieplanet">
|
189 |
+
<dir>
|
190 |
+
<dir name="system">
|
191 |
+
<dir name="config">
|
192 |
+
<dir name="fieldset">
|
193 |
+
<file name="hint.phtml" hash="490fcd9622d81289904c3cbb42744f87" />
|
194 |
+
</dir>
|
195 |
+
</dir>
|
196 |
+
</dir>
|
197 |
+
</dir>
|
198 |
+
</dir>
|
199 |
+
</dir>
|
200 |
+
</dir>
|
201 |
+
</dir>
|
202 |
+
</dir>
|
203 |
+
</target>
|
204 |
+
</contents>
|
205 |
+
<compatible/>
|
206 |
+
<dependencies>
|
207 |
+
<required>
|
208 |
+
<php>
|
209 |
+
<min>5.2.0</min>
|
210 |
+
<max>7.1.0</max>
|
211 |
+
</php>
|
212 |
+
</required>
|
213 |
+
</dependencies>
|
214 |
+
</package>
|
skin/adminhtml/default/default/images/advertentieplanet/connected.png
ADDED
Binary file
|
skin/adminhtml/default/default/images/advertentieplanet/disconnected.png
ADDED
Binary file
|
skin/adminhtml/default/default/images/advertentieplanet/logo.png
ADDED
Binary file
|