J2t_Payplug - Version 1.0.10

Version Notes

Introduction of sandbox feature

Download this release

Release Info

Developer J2T DESIGN
Extension J2t_Payplug
Version 1.0.10
Comparing to
See all releases


Code changes from version 1.0.9 to 1.0.10

app/code/community/J2t/Payplug/.DS_Store DELETED
Binary file
app/code/community/J2t/Payplug/Block/Info.php CHANGED
@@ -37,13 +37,6 @@ class J2t_Payplug_Block_Info extends Mage_Payment_Block_Info
37
  {
38
  return $this->getInfo()->getMethodInstance()->getCode();
39
  }
40
-
41
-
42
- public function toPdf()
43
- {
44
- $this->setTemplate('j2tpayplug/pdf/info.phtml');
45
- return $this->toHtml();
46
- }
47
 
48
 
49
  }
37
  {
38
  return $this->getInfo()->getMethodInstance()->getCode();
39
  }
 
 
 
 
 
 
 
40
 
41
 
42
  }
app/code/community/J2t/Payplug/Model/Feed.php DELETED
@@ -1,104 +0,0 @@
1
- <?php
2
- Class J2t_Payplug_Model_Feed extends Mage_AdminNotification_Model_Feed {
3
-
4
- const XML_FEED_URL_PATH_J2T = 'system/j2t_all/feed_url_j2t';
5
-
6
- protected $_feedUrlJ2t;
7
-
8
- public function checkUpdate()
9
- {
10
- if (($this->getFrequency() + $this->getLastUpdate()) > time()) {
11
- return $this;
12
- }
13
-
14
- $feedData = array();
15
-
16
- $feedXml = $this->getFeedData();
17
-
18
- if ($feedXml && $feedXml->channel && $feedXml->channel->item) {
19
- foreach ($feedXml->channel->item as $item) {
20
- $feedData[] = array(
21
- 'severity' => (int)$item->severity,
22
- 'date_added' => $this->getDate((string)$item->pubDate),
23
- 'title' => (string)$item->title,
24
- 'description' => (string)$item->description,
25
- 'url' => (string)$item->link,
26
- );
27
- }
28
-
29
-
30
- if ($feedData) {
31
- Mage::getModel('adminnotification/inbox')->parse(array_reverse($feedData));
32
- }
33
-
34
- }
35
-
36
- $this->setLastUpdate();
37
-
38
- return $this;
39
- }
40
-
41
-
42
- /**
43
- * Retrieve Last update time
44
- *
45
- * @return int
46
- */
47
- public function getLastUpdate()
48
- {
49
- return Mage::app()->loadCache('j2t_notifications_lastcheck');
50
- }
51
-
52
- /**
53
- * Set last update time (now)
54
- *
55
- * @return Mage_AdminNotification_Model_Feed
56
- */
57
- public function setLastUpdate()
58
- {
59
- Mage::app()->saveCache(time(), 'j2t_notifications_lastcheck');
60
- return $this;
61
- }
62
-
63
-
64
-
65
- public function getFeedUrl()
66
- {
67
- if (is_null($this->_feedUrlJ2t)) {
68
- $this->_feedUrlJ2t = (Mage::getStoreConfigFlag(self::XML_USE_HTTPS_PATH) ? 'https://' : 'http://')
69
- . Mage::getStoreConfig(self::XML_FEED_URL_PATH_J2T);
70
- }
71
- return $this->_feedUrlJ2t;
72
- }
73
-
74
-
75
- public function getFeedData()
76
- {
77
- $curl = new Varien_Http_Adapter_Curl();
78
- $curl->setConfig(array(
79
- 'timeout' => 3
80
- ));
81
-
82
- $curl->write(Zend_Http_Client::GET, $this->getFeedUrl(), '1.0');
83
- $data = $curl->read();
84
- if ($data === false) {
85
- return false;
86
- }
87
- $data = preg_split('/^\r?$/m', $data, 2);
88
- $data = trim($data[1]);
89
- $curl->close();
90
-
91
- try {
92
- $xml = new SimpleXMLElement($data);
93
- }
94
- catch (Exception $e) {
95
- return false;
96
- }
97
-
98
- return $xml;
99
- }
100
-
101
- }
102
-
103
-
104
- ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
app/code/community/J2t/Payplug/Model/Observer.php CHANGED
@@ -3,8 +3,19 @@
3
  class J2t_Payplug_Model_Observer extends Mage_Core_Model_Session_Abstract
4
  {
5
  const URL_AUTOCONFIG = 'https://www.payplug.fr/portal/ecommerce/autoconfig';
 
6
  protected function createCertFile($user, $pass){
7
- $process = curl_init(self::URL_AUTOCONFIG);
 
 
 
 
 
 
 
 
 
 
8
 
9
  curl_setopt($process, CURLOPT_USERPWD, $user.':'.$pass);
10
  curl_setopt($process, CURLOPT_RETURNTRANSFER, TRUE);
@@ -13,6 +24,7 @@ class J2t_Payplug_Model_Observer extends Mage_Core_Model_Session_Abstract
13
 
14
  $errorCurl = curl_errno($process);
15
 
 
16
  curl_close($process);
17
  if($errorCurl == 0) {
18
  $jsonAnswer = json_decode($answer);
@@ -91,16 +103,5 @@ class J2t_Payplug_Model_Observer extends Mage_Core_Model_Session_Abstract
91
  $this->createCertFile($user, $pwd);
92
  }
93
  }
94
-
95
- public function preDispatch(Varien_Event_Observer $observer)
96
- {
97
- if (Mage::getSingleton('admin/session')->isLoggedIn()) {
98
- $feedModel = Mage::getModel('j2tpayplug/feed');
99
- /* @var $feedModel Mage_AdminNotification_Model_Feed */
100
-
101
- $feedModel->checkUpdate();
102
- }
103
-
104
- }
105
  }
106
 
3
  class J2t_Payplug_Model_Observer extends Mage_Core_Model_Session_Abstract
4
  {
5
  const URL_AUTOCONFIG = 'https://www.payplug.fr/portal/ecommerce/autoconfig';
6
+ const URL_AUTOCONFIG_TEST = 'https://www.payplug.fr/portal/test/ecommerce/autoconfig';
7
  protected function createCertFile($user, $pass){
8
+ $url = self::URL_AUTOCONFIG;
9
+ if (($groups = Mage::app()->getRequest()->getPost('groups'))) {
10
+ if (isset($groups['j2tpayplug']) && isset($groups['j2tpayplug']['fields'])
11
+ && isset($groups['j2tpayplug']['fields']['sandbox']) && isset($groups['j2tpayplug']['fields']['sandbox']['value'])
12
+ && $groups['j2tpayplug']['fields']['sandbox']['value']){
13
+ $url = self::URL_AUTOCONFIG_TEST;
14
+ }
15
+ }
16
+
17
+ $process = curl_init($url);
18
+ //$process = curl_init(self::URL_AUTOCONFIG);
19
 
20
  curl_setopt($process, CURLOPT_USERPWD, $user.':'.$pass);
21
  curl_setopt($process, CURLOPT_RETURNTRANSFER, TRUE);
24
 
25
  $errorCurl = curl_errno($process);
26
 
27
+
28
  curl_close($process);
29
  if($errorCurl == 0) {
30
  $jsonAnswer = json_decode($answer);
103
  $this->createCertFile($user, $pwd);
104
  }
105
  }
 
 
 
 
 
 
 
 
 
 
 
106
  }
107
 
app/code/community/J2t/Payplug/Model/PaymentMethod.php CHANGED
@@ -128,7 +128,7 @@ class J2t_Payplug_Model_PaymentMethod extends Mage_Payment_Model_Method_Abstract
128
  $url_payment= Mage::getStoreConfig('payment/j2tpayplug/module_url', $this->getQuote()->getStoreId());
129
 
130
  $params = array(
131
- 'amount' => ($order->getBaseGrandTotal()*100),
132
  'custom_data' => $order->getStoreId(),
133
  'origin' => 'Magento '.Mage::getVersion().' module '.Mage::getConfig()->getModuleConfig("J2t_Payplug")->version,
134
  'currency' => $order->getOrderCurrencyCode(),
@@ -138,17 +138,17 @@ class J2t_Payplug_Model_PaymentMethod extends Mage_Payment_Model_Method_Abstract
138
  'email' => $order->getCustomerEmail(),
139
  'firstname' => $order->getCustomerFirstname(),
140
  'lastname' => $order->getCustomerLastname(),
141
- 'first_name' => $order->getCustomerFirstname(),
142
- 'last_name' => $order->getCustomerLastname(),
143
  //'order' => $this->getQuote()->getId(),
144
  'order' => $orderIncrementId,
145
  'customer' => $order->getCustomerId()
146
  );
147
 
148
- if(Mage::getStoreConfig('payment/j2tpayplug/sandbox', $this->getQuote()->getStoreId())){
 
149
  $params['is_test'] = 'true';
150
  }
151
 
 
152
  $url_params = http_build_query($params);
153
  $privatekey = Mage::getStoreConfig('payment/j2tpayplug/private_key', $this->getQuote()->getStoreId());
154
  openssl_sign($url_params, $signature, $privatekey, $signature_alg = OPENSSL_ALGO_SHA1);
@@ -161,13 +161,13 @@ class J2t_Payplug_Model_PaymentMethod extends Mage_Payment_Model_Method_Abstract
161
 
162
  public function isAvailable($quote = null)
163
  {
164
- $min = Mage::getStoreConfig('payment/j2tpayplug/min_amount', $quote ? $quote->getStoreId() : null);
165
- $max = Mage::getStoreConfig('payment/j2tpayplug/max_amount', $quote ? $quote->getStoreId() : null);
166
- if (parent::isAvailable($quote) && $quote && $quote->getGrandTotal() >= $min && $quote->getGrandTotal() <= $max
167
- && Mage::getStoreConfig('payment/j2tpayplug/private_key', $quote ? $quote->getStoreId() : null)
168
- && Mage::getStoreConfig('payment/j2tpayplug/public_key', $quote ? $quote->getStoreId() : null)
169
- && Mage::getStoreConfig('payment/j2tpayplug/module_url', $quote ? $quote->getStoreId() : null)
170
- && Mage::getStoreConfig('payment/j2tpayplug/currencies', $quote ? $quote->getStoreId() : null)
171
  ) {
172
  return true;
173
  }
128
  $url_payment= Mage::getStoreConfig('payment/j2tpayplug/module_url', $this->getQuote()->getStoreId());
129
 
130
  $params = array(
131
+ 'amount' => ($order->getGrandTotal()*100),
132
  'custom_data' => $order->getStoreId(),
133
  'origin' => 'Magento '.Mage::getVersion().' module '.Mage::getConfig()->getModuleConfig("J2t_Payplug")->version,
134
  'currency' => $order->getOrderCurrencyCode(),
138
  'email' => $order->getCustomerEmail(),
139
  'firstname' => $order->getCustomerFirstname(),
140
  'lastname' => $order->getCustomerLastname(),
 
 
141
  //'order' => $this->getQuote()->getId(),
142
  'order' => $orderIncrementId,
143
  'customer' => $order->getCustomerId()
144
  );
145
 
146
+ $sandbox = Mage::getStoreConfig('payment/j2tpayplug/sandbox', $this->getQuote()->getStoreId());
147
+ if($sandbox){
148
  $params['is_test'] = 'true';
149
  }
150
 
151
+
152
  $url_params = http_build_query($params);
153
  $privatekey = Mage::getStoreConfig('payment/j2tpayplug/private_key', $this->getQuote()->getStoreId());
154
  openssl_sign($url_params, $signature, $privatekey, $signature_alg = OPENSSL_ALGO_SHA1);
161
 
162
  public function isAvailable($quote = null)
163
  {
164
+ $min = Mage::getStoreConfig('payment/j2tpayplug/min_amount', $quote->getStoreId());
165
+ $max = Mage::getStoreConfig('payment/j2tpayplug/max_amount', $quote->getStoreId());
166
+ if (parent::isAvailable($quote) && $quote->getGrandTotal() >= $min && $quote->getGrandTotal() <= $max
167
+ && Mage::getStoreConfig('payment/j2tpayplug/private_key', $quote->getStoreId())
168
+ && Mage::getStoreConfig('payment/j2tpayplug/public_key', $quote->getStoreId())
169
+ && Mage::getStoreConfig('payment/j2tpayplug/module_url', $quote->getStoreId())
170
+ && Mage::getStoreConfig('payment/j2tpayplug/currencies', $quote->getStoreId())
171
  ) {
172
  return true;
173
  }
app/code/community/J2t/Payplug/controllers/PaymentController.php CHANGED
@@ -30,33 +30,6 @@ class J2t_Payplug_PaymentController extends Mage_Core_Controller_Front_Action
30
  $this->_redirectUrl($url);
31
  }
32
 
33
-
34
- protected function _createInvoice($order)
35
- {
36
- if (!$order->canInvoice()) {
37
- return;
38
- }
39
- /*$invoice = $order->prepareInvoice();
40
- $invoice->register()->capture();
41
- $order->addRelatedObject($invoice);*/
42
-
43
- ////////////////
44
-
45
- $invoice = $order->prepareInvoice();
46
- if (!$invoice->getTotalQty()) {
47
- Mage::throwException(Mage::helper('j2tpayplug')->__('Cannot create an invoice without products.'));
48
- }
49
-
50
- $invoice->setRequestedCaptureCase(Mage_Sales_Model_Order_Invoice::CAPTURE_OFFLINE);
51
- $invoice->register();
52
- /*$transactionSave = Mage::getModel('core/resource_transaction')
53
- ->addObject($invoice)
54
- ->addObject($invoice->getOrder());
55
-
56
- $transactionSave->save();*/
57
- $order->addRelatedObject($invoice);
58
- }
59
-
60
  public function ipnAction()
61
  {
62
  $headers = array();
@@ -110,28 +83,14 @@ class J2t_Payplug_PaymentController extends Mage_Core_Controller_Front_Action
110
  }
111
  // If order state is payment in progress by payplug
112
  elseif($order->getState() == Mage::getStoreConfig('payment/j2tpayplug/new_order_status', $data['custom_data'])){
113
- /*$order->setState(Mage::getStoreConfig('payment/j2tpayplug/complete_order_status', $data['custom_data']));
114
  $order->setStatus(Mage::getStoreConfig('payment/j2tpayplug/complete_order_status', $data['custom_data']));
115
  $order->addStatusHistoryComment(Mage::helper('j2tpayplug')->__('Payment has been captured by Payment Gateway. Transaction id: %s', $data['id_transaction']));
116
- $order->save();*/
117
-
118
- $order->setState(Mage_Sales_Model_Order::STATE_PROCESSING, true, Mage::helper('j2tpayplug')->__('Payment has been captured by Payment Gateway. Transaction id: %s', $data['id_transaction']));
119
- // save transaction ID
120
- $order->getPayment()->setLastTransId($data['id_transaction']);
121
- // send new order email
122
- $order->sendNewOrderEmail();
123
- $order->setEmailSent(true);
124
-
125
- if (Mage::getStoreConfig('payment/j2tpayplug/invoice', $data['custom_data'])){
126
- $this->_createInvoice($order);
127
- }
128
-
129
  $order->save();
130
 
131
- /*if (Mage::getStoreConfig('payment/j2tpayplug/invoice', $data['custom_data'])){
132
  //generate invoice
133
  try {
134
-
135
  if(!$order->canInvoice())
136
  {
137
  Mage::throwException(Mage::helper('j2tpayplug')->__('Cannot create an invoice.'));
@@ -152,16 +111,11 @@ class J2t_Payplug_PaymentController extends Mage_Core_Controller_Front_Action
152
  catch (Mage_Core_Exception $e) {
153
 
154
  }
155
- }*/
156
 
157
  }
158
  } // If status refund
159
- else if($status == self::PAYMENT_STATUS_CANCEL){
160
- $order->cancel();
161
- $order->addStatusToHistory(Mage_Sales_Model_Order::STATE_CANCELED, Mage::helper('j2tpayplug')->__('Payment canceled by Payment Gateway. Transaction id: %s', $data['id_transaction']));
162
- $order->save();
163
- }
164
- else if($status == self::PAYMENT_STATUS_REFUND){
165
  $invoices = array();
166
  foreach ($order->getInvoiceCollection() as $invoice) {
167
  if ($invoice->canRefund()) {
@@ -172,14 +126,11 @@ class J2t_Payplug_PaymentController extends Mage_Core_Controller_Front_Action
172
  foreach ($invoices as $invoice) {
173
  $creditmemo = $service->prepareInvoiceCreditmemo($invoice);
174
  $creditmemo->refund();
175
- $creditmemo->getInvoice()->save();
176
- $creditmemo->save();
177
  }
178
  //if (!sizeof($invoices)){
179
  $order->setState(Mage::getStoreConfig('payment/j2tpayplug/cancel_order_status', $data['custom_data']));
180
  $order->setStatus(Mage::getStoreConfig('payment/j2tpayplug/cancel_order_status', $data['custom_data']));
181
- $order->addStatusToHistory(Mage_Sales_Model_Order::STATE_CLOSED, Mage::helper('j2tpayplug')->__('Payment refunded by Payment Gateway. Transaction id: %s', $data['id_transaction']));
182
- //$order->addStatusHistoryComment(Mage::helper('j2tpayplug')->__('Payment refunded by Payment Gateway. Transaction id: %s', $data['id_transaction']));
183
  $order->save();
184
  //}
185
  }
30
  $this->_redirectUrl($url);
31
  }
32
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
33
  public function ipnAction()
34
  {
35
  $headers = array();
83
  }
84
  // If order state is payment in progress by payplug
85
  elseif($order->getState() == Mage::getStoreConfig('payment/j2tpayplug/new_order_status', $data['custom_data'])){
86
+ $order->setState(Mage::getStoreConfig('payment/j2tpayplug/complete_order_status', $data['custom_data']));
87
  $order->setStatus(Mage::getStoreConfig('payment/j2tpayplug/complete_order_status', $data['custom_data']));
88
  $order->addStatusHistoryComment(Mage::helper('j2tpayplug')->__('Payment has been captured by Payment Gateway. Transaction id: %s', $data['id_transaction']));
 
 
 
 
 
 
 
 
 
 
 
 
 
89
  $order->save();
90
 
91
+ if (Mage::getStoreConfig('payment/j2tpayplug/invoice', $data['custom_data'])){
92
  //generate invoice
93
  try {
 
94
  if(!$order->canInvoice())
95
  {
96
  Mage::throwException(Mage::helper('j2tpayplug')->__('Cannot create an invoice.'));
111
  catch (Mage_Core_Exception $e) {
112
 
113
  }
114
+ }
115
 
116
  }
117
  } // If status refund
118
+ else if($status == self::PAYMENT_STATUS_REFUND || $status == self::PAYMENT_STATUS_CANCEL){
 
 
 
 
 
119
  $invoices = array();
120
  foreach ($order->getInvoiceCollection() as $invoice) {
121
  if ($invoice->canRefund()) {
126
  foreach ($invoices as $invoice) {
127
  $creditmemo = $service->prepareInvoiceCreditmemo($invoice);
128
  $creditmemo->refund();
 
 
129
  }
130
  //if (!sizeof($invoices)){
131
  $order->setState(Mage::getStoreConfig('payment/j2tpayplug/cancel_order_status', $data['custom_data']));
132
  $order->setStatus(Mage::getStoreConfig('payment/j2tpayplug/cancel_order_status', $data['custom_data']));
133
+ $order->addStatusHistoryComment(Mage::helper('j2tpayplug')->__('Payment canceled/refunded by Payment Gateway. Transaction id: %s', $data['id_transaction']));
 
134
  $order->save();
135
  //}
136
  }
app/code/community/J2t/Payplug/etc/config.xml CHANGED
@@ -2,7 +2,7 @@
2
  <config>
3
  <modules>
4
  <J2t_Payplug>
5
- <version>1.0.9</version>
6
  </J2t_Payplug>
7
  </modules>
8
 
@@ -24,13 +24,21 @@
24
  <class>J2t_Payplug_Model</class>
25
  <resourceModel>j2tpayplug_resource</resourceModel>
26
  </j2tpayplug>
 
 
 
 
 
 
 
 
 
27
  </models>
28
  <resources>
29
  <j2tpayplug_setup>
30
  <setup>
31
  <module>J2t_Payplug</module>
32
- <!--<class>Mage_Paypal_Model_Resource_Setup</class>-->
33
- <class>Mage_Sales_Model_Mysql4_Setup</class>
34
  </setup>
35
  <connection>
36
  <use>core_setup</use>
@@ -76,51 +84,30 @@
76
 
77
  <translate>
78
  <modules>
79
- <J2t_Payplug>
80
  <files>
81
  <default>j2t_payplug.csv</default>
82
  </files>
83
- </J2t_Payplug>
84
  </modules>
85
  </translate>
86
  </frontend>
87
  <adminhtml>
88
  <translate>
89
  <modules>
90
- <J2t_Payplug>
91
  <files>
92
  <default>j2t_payplug.csv</default>
93
  </files>
94
- </J2t_Payplug>
95
  </modules>
96
  </translate>
97
-
98
- <layout>
99
- <updates>
100
- <j2t_all module="j2tpayplug">
101
- <file>j2tpayplug.xml</file>
102
- </j2t_all>
103
- </updates>
104
- </layout>
105
-
106
- <events>
107
- <controller_action_predispatch>
108
- <observers>
109
- <j2tpayplug_predispatch>
110
- <class>J2t_Payplug_Model_Observer</class>
111
- <method>preDispatch</method>
112
- </j2tpayplug_predispatch>
113
- </observers>
114
- </controller_action_predispatch>
115
- </events>
116
-
117
  </adminhtml>
118
 
119
  <default>
120
  <payment>
121
  <j2tpayplug>
122
  <active>0</active>
123
- <sandbox>0</sandbox>
124
  <model>j2tpayplug/paymentMethod</model>
125
  <new_order_status>pending</new_order_status>
126
  <complete_order_status>processing</complete_order_status>
@@ -129,12 +116,8 @@
129
  <title>PayPlug - Payment by Visa or Mastercard</title>
130
  <payment_action>authorize</payment_action>
131
  <allowspecific>0</allowspecific>
 
132
  </j2tpayplug>
133
- </payment>
134
- <system>
135
- <j2t_all>
136
- <feed_url_j2t>j2t-design.net/notifications.rss</feed_url_j2t>
137
- </j2t_all>
138
- </system>
139
  </default>
140
- </config>
2
  <config>
3
  <modules>
4
  <J2t_Payplug>
5
+ <version>1.0.10</version>
6
  </J2t_Payplug>
7
  </modules>
8
 
24
  <class>J2t_Payplug_Model</class>
25
  <resourceModel>j2tpayplug_resource</resourceModel>
26
  </j2tpayplug>
27
+ <j2tpayplug_resource>
28
+ <class>J2t_Payplug_Model_Resource</class>
29
+ <deprecatedNode>j2tpayplug_mysql4</deprecatedNode>
30
+ <entities>
31
+ <cert>
32
+ <table>payplug_cert</table>
33
+ </cert>
34
+ </entities>
35
+ </j2tpayplug_resource>
36
  </models>
37
  <resources>
38
  <j2tpayplug_setup>
39
  <setup>
40
  <module>J2t_Payplug</module>
41
+ <class>Mage_Paypal_Model_Resource_Setup</class>
 
42
  </setup>
43
  <connection>
44
  <use>core_setup</use>
84
 
85
  <translate>
86
  <modules>
87
+ <j2tpayplug>
88
  <files>
89
  <default>j2t_payplug.csv</default>
90
  </files>
91
+ </j2tpayplug>
92
  </modules>
93
  </translate>
94
  </frontend>
95
  <adminhtml>
96
  <translate>
97
  <modules>
98
+ <j2tpayplug>
99
  <files>
100
  <default>j2t_payplug.csv</default>
101
  </files>
102
+ </j2tpayplug>
103
  </modules>
104
  </translate>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
105
  </adminhtml>
106
 
107
  <default>
108
  <payment>
109
  <j2tpayplug>
110
  <active>0</active>
 
111
  <model>j2tpayplug/paymentMethod</model>
112
  <new_order_status>pending</new_order_status>
113
  <complete_order_status>processing</complete_order_status>
116
  <title>PayPlug - Payment by Visa or Mastercard</title>
117
  <payment_action>authorize</payment_action>
118
  <allowspecific>0</allowspecific>
119
+ <sandbox>0</sandbox>
120
  </j2tpayplug>
121
+ </payment>
 
 
 
 
 
122
  </default>
123
+ </config>
app/code/community/J2t/Payplug/etc/system.xml CHANGED
@@ -1,256 +1,209 @@
1
  <?xml version="1.0"?>
2
  <config>
3
- <tabs>
4
- <j2t_all>
5
- <label>J2T Modules</label>
6
- <class>j2t-all-area</class>
7
- <sort_order>100</sort_order>
8
- </j2t_all>
9
- </tabs>
10
- <sections>
11
- <j2t_all translate="label comment" module="j2tpayplug">
12
- <tab>j2t_all</tab>
13
- <class>j2t-all-tab</class>
14
- <label>Our Products...</label>
15
- <frontend_type>text</frontend_type>
16
- <sort_order>1000</sort_order>
17
- <show_in_default>1</show_in_default>
18
- <show_in_website>1</show_in_website>
19
- <show_in_store>1</show_in_store>
20
  <groups>
21
- <default translate="label comment" module="j2tpayplug">
22
- <label>J2T DESIGN</label>
 
 
 
 
23
 
24
  <comment><![CDATA[
25
- <script type="text/javascript">
26
- document.observe("dom:loaded", function() {
27
- $$('.content-header .form-buttons').invoke('hide');
28
- $$('.middle .main-col-inner')[0].style.height = '1400px';
29
- var url_j2t = ('https:' == document.location.protocol ? 'https://' : 'http://') + 'www.j2t-design.net/index.php/j2t-products?limit=25';
30
- $$('.middle .entry-edit')[0].replace('<iframe src="'+url_j2t+'" style="width:100%; height:1400px; border:none;"></iframe>');
31
- });
32
- </script>
 
 
 
 
 
 
 
33
  ]]>
34
  </comment>
35
 
36
 
37
- <frontend_type>text</frontend_type>
38
- <sort_order>10</sort_order>
39
- <show_in_default>1</show_in_default>
40
- <show_in_website>1</show_in_website>
41
- <show_in_store>1</show_in_store>
42
-
43
- <fields>
44
- <j2t_all translate="label">
45
- <label>All Modules</label>
46
- <frontend_type>select</frontend_type>
47
- <source_model>adminhtml/system_config_source_yesno</source_model>
48
- <sort_order>10</sort_order>
49
- <show_in_default>1</show_in_default>
50
- <show_in_website>1</show_in_website>
51
- <show_in_store>1</show_in_store>
52
- <comment><![CDATA[Activate/deactivate all modules.]]></comment>
53
- </j2t_all>
54
- </fields>
55
- </default>
56
-
57
- </groups>
58
- </j2t_all>
59
- <payment>
60
- <groups>
61
- <j2tpayplug translate="label" module="j2tpayplug">
62
- <label>Pay Plug</label>
63
- <sort_order>670</sort_order>
64
- <show_in_default>1</show_in_default>
65
- <show_in_website>1</show_in_website>
66
- <show_in_store>0</show_in_store>
67
- <comment><![CDATA[In order to use this payment method, it is necessary to create an account on <a target='_blank' href='http://www.payplug.fr/inscription?sponsor=83'>PayPlug</a>.]]></comment>
68
  <fields>
69
  <active translate="label">
70
  <label>Enabled</label>
71
  <frontend_type>select</frontend_type>
72
  <source_model>adminhtml/system_config_source_yesno</source_model>
73
- <sort_order>10</sort_order>
74
  <show_in_default>1</show_in_default>
75
  <show_in_website>1</show_in_website>
76
- <show_in_store>0</show_in_store>
77
- <comment><![CDATA[
78
- <script type="text/javascript">
79
- hideAll = function(){
80
- $('payment_j2tpayplug_private_key').up(1).hide();
81
- $('payment_j2tpayplug_public_key').up(1).hide();
82
- $('payment_j2tpayplug_module_url').up(1).hide();
83
- $('payment_j2tpayplug_min_amount').up(1).hide();
84
- $('payment_j2tpayplug_max_amount').up(1).hide();
85
- $('payment_j2tpayplug_currencies').up(1).hide();
86
- };
87
-
88
- Event.observe(window, 'load', function() {
89
- hideAll();
90
- });
91
- </script>
92
- ]]></comment>
93
  </active>
94
-
95
  <sandbox translate="label">
96
  <label>Sandbox</label>
97
  <frontend_type>select</frontend_type>
98
  <source_model>adminhtml/system_config_source_yesno</source_model>
99
- <sort_order>20</sort_order>
100
  <show_in_default>1</show_in_default>
101
  <show_in_website>1</show_in_website>
102
  <show_in_store>1</show_in_store>
103
- <comment><![CDATA[Set yes to use sandbox mode.]]></comment>
104
  </sandbox>
105
-
106
  <title translate="label">
107
  <label>Title</label>
108
  <frontend_type>text</frontend_type>
109
- <sort_order>30</sort_order>
110
  <show_in_default>1</show_in_default>
111
  <show_in_website>1</show_in_website>
112
- <show_in_store>0</show_in_store>
113
  </title>
114
 
115
  <account_details translate="label">
116
  <label>Account details</label>
117
  <frontend_type>text</frontend_type>
118
  <frontend_model>j2tpayplug/adminhtml_system_config_accountdetails</frontend_model>
119
- <sort_order>40</sort_order>
120
  <show_in_default>1</show_in_default>
121
  <show_in_website>1</show_in_website>
122
- <show_in_store>0</show_in_store>
123
  </account_details>
124
 
125
 
126
  <private_key translate="label">
127
  <label>Private Key</label>
128
  <frontend_type>textarea</frontend_type>
129
- <sort_order>50</sort_order>
130
  <show_in_default>1</show_in_default>
131
  <show_in_website>1</show_in_website>
132
- <show_in_store>0</show_in_store>
133
  </private_key>
134
  <public_key translate="label">
135
  <label>Public Key</label>
136
  <frontend_type>textarea</frontend_type>
137
- <sort_order>60</sort_order>
138
  <show_in_default>1</show_in_default>
139
  <show_in_website>1</show_in_website>
140
- <show_in_store>0</show_in_store>
141
  </public_key>
142
  <module_url translate="label">
143
  <label>Module URL</label>
144
  <frontend_type>text</frontend_type>
145
- <sort_order>70</sort_order>
146
  <show_in_default>1</show_in_default>
147
  <show_in_website>1</show_in_website>
148
- <show_in_store>0</show_in_store>
149
  </module_url>
150
  <min_amount translate="label">
151
  <label>Min Amount</label>
152
  <frontend_type>text</frontend_type>
153
- <sort_order>80</sort_order>
154
  <show_in_default>1</show_in_default>
155
  <show_in_website>1</show_in_website>
156
- <show_in_store>0</show_in_store>
157
  </min_amount>
158
  <max_amount translate="label">
159
  <label>Max Amount</label>
160
  <frontend_type>text</frontend_type>
161
- <sort_order>90</sort_order>
162
  <show_in_default>1</show_in_default>
163
  <show_in_website>1</show_in_website>
164
- <show_in_store>0</show_in_store>
165
  </max_amount>
166
  <currencies translate="label">
167
  <label>Currencies</label>
168
  <frontend_type>text</frontend_type>
169
- <sort_order>100</sort_order>
170
  <show_in_default>1</show_in_default>
171
  <show_in_website>1</show_in_website>
172
- <show_in_store>0</show_in_store>
173
  </currencies>
174
 
175
  <user translate="label">
176
  <label>User</label>
177
  <frontend_type>text</frontend_type>
178
- <sort_order>110</sort_order>
179
  <show_in_default>1</show_in_default>
180
  <show_in_website>1</show_in_website>
 
181
  </user>
182
  <pwd translate="label">
183
  <label>Password</label>
184
  <frontend_type>obscure</frontend_type>
185
  <backend_model>adminhtml/system_config_backend_encrypted</backend_model>
186
- <sort_order>120</sort_order>
187
  <show_in_default>1</show_in_default>
188
  <show_in_website>1</show_in_website>
 
189
  </pwd>
190
 
191
  <new_order_status translate="label">
192
  <label>New order status</label>
193
  <frontend_type>select</frontend_type>
194
  <source_model>adminhtml/system_config_source_order_status_newprocessing</source_model>
195
- <sort_order>130</sort_order>
196
  <show_in_default>1</show_in_default>
197
  <show_in_website>1</show_in_website>
 
198
  </new_order_status>
199
 
200
  <complete_order_status translate="label">
201
  <label>Approved order status</label>
202
  <frontend_type>select</frontend_type>
203
  <source_model>adminhtml/system_config_source_order_status_processing</source_model>
204
- <sort_order>140</sort_order>
205
  <show_in_default>1</show_in_default>
206
  <show_in_website>1</show_in_website>
 
207
  </complete_order_status>
208
 
209
  <cancel_order_status translate="label">
210
  <label>Rejected order status</label>
211
  <frontend_type>select</frontend_type>
212
  <source_model>adminhtml/system_config_source_order_status</source_model>
213
- <sort_order>150</sort_order>
214
  <show_in_default>1</show_in_default>
215
  <show_in_website>1</show_in_website>
 
216
  </cancel_order_status>
217
 
218
  <invoice translate="label">
219
  <label>Invoice when complete</label>
220
  <frontend_type>select</frontend_type>
221
  <source_model>adminhtml/system_config_source_yesno</source_model>
222
- <sort_order>160</sort_order>
223
  <show_in_default>1</show_in_default>
224
  <show_in_website>1</show_in_website>
 
225
  </invoice>
226
 
227
  <allowspecific translate="label">
228
  <label>Payment from Applicable Countries</label>
229
  <frontend_type>allowspecific</frontend_type>
230
- <sort_order>170</sort_order>
231
  <source_model>adminhtml/system_config_source_payment_allspecificcountries</source_model>
232
  <show_in_default>1</show_in_default>
233
  <show_in_website>1</show_in_website>
234
- <show_in_store>0</show_in_store>
235
  </allowspecific>
236
  <specificcountry translate="label">
237
  <label>Payment from Specific Countries</label>
238
  <frontend_type>multiselect</frontend_type>
239
- <sort_order>180</sort_order>
240
  <source_model>adminhtml/system_config_source_country</source_model>
241
  <show_in_default>1</show_in_default>
242
  <show_in_website>1</show_in_website>
243
- <show_in_store>0</show_in_store>
244
  <can_be_empty>1</can_be_empty>
245
  </specificcountry>
246
 
247
  <sort_order translate="label">
248
  <label>Sort Order</label>
249
  <frontend_type>text</frontend_type>
250
- <sort_order>190</sort_order>
251
  <show_in_default>1</show_in_default>
252
  <show_in_website>1</show_in_website>
253
- <show_in_store>0</show_in_store>
254
  <frontend_class>validate-number</frontend_class>
255
  </sort_order>
256
 
1
  <?xml version="1.0"?>
2
  <config>
3
+ <sections>
4
+ <payment>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5
  <groups>
6
+ <j2tpayplug translate="label" module="paygate">
7
+ <label>Pay Plug</label>
8
+ <sort_order>670</sort_order>
9
+ <show_in_default>1</show_in_default>
10
+ <show_in_website>1</show_in_website>
11
+ <show_in_store>1</show_in_store>
12
 
13
  <comment><![CDATA[
14
+ <script type="text/javascript">
15
+
16
+ hideAll = function(){
17
+ $('payment_j2tpayplug_private_key').up(1).hide();
18
+ $('payment_j2tpayplug_public_key').up(1).hide();
19
+ $('payment_j2tpayplug_module_url').up(1).hide();
20
+ $('payment_j2tpayplug_min_amount').up(1).hide();
21
+ $('payment_j2tpayplug_max_amount').up(1).hide();
22
+ $('payment_j2tpayplug_currencies').up(1).hide();
23
+ };
24
+
25
+ Event.observe(window, 'load', function() {
26
+ hideAll();
27
+ });
28
+ </script>
29
  ]]>
30
  </comment>
31
 
32
 
33
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  <fields>
35
  <active translate="label">
36
  <label>Enabled</label>
37
  <frontend_type>select</frontend_type>
38
  <source_model>adminhtml/system_config_source_yesno</source_model>
39
+ <sort_order>1</sort_order>
40
  <show_in_default>1</show_in_default>
41
  <show_in_website>1</show_in_website>
42
+ <show_in_store>1</show_in_store>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
43
  </active>
 
44
  <sandbox translate="label">
45
  <label>Sandbox</label>
46
  <frontend_type>select</frontend_type>
47
  <source_model>adminhtml/system_config_source_yesno</source_model>
48
+ <sort_order>2</sort_order>
49
  <show_in_default>1</show_in_default>
50
  <show_in_website>1</show_in_website>
51
  <show_in_store>1</show_in_store>
 
52
  </sandbox>
 
53
  <title translate="label">
54
  <label>Title</label>
55
  <frontend_type>text</frontend_type>
56
+ <sort_order>3</sort_order>
57
  <show_in_default>1</show_in_default>
58
  <show_in_website>1</show_in_website>
59
+ <show_in_store>1</show_in_store>
60
  </title>
61
 
62
  <account_details translate="label">
63
  <label>Account details</label>
64
  <frontend_type>text</frontend_type>
65
  <frontend_model>j2tpayplug/adminhtml_system_config_accountdetails</frontend_model>
66
+ <sort_order>4</sort_order>
67
  <show_in_default>1</show_in_default>
68
  <show_in_website>1</show_in_website>
69
+ <show_in_store>1</show_in_store>
70
  </account_details>
71
 
72
 
73
  <private_key translate="label">
74
  <label>Private Key</label>
75
  <frontend_type>textarea</frontend_type>
76
+ <sort_order>5</sort_order>
77
  <show_in_default>1</show_in_default>
78
  <show_in_website>1</show_in_website>
79
+ <show_in_store>1</show_in_store>
80
  </private_key>
81
  <public_key translate="label">
82
  <label>Public Key</label>
83
  <frontend_type>textarea</frontend_type>
84
+ <sort_order>6</sort_order>
85
  <show_in_default>1</show_in_default>
86
  <show_in_website>1</show_in_website>
87
+ <show_in_store>1</show_in_store>
88
  </public_key>
89
  <module_url translate="label">
90
  <label>Module URL</label>
91
  <frontend_type>text</frontend_type>
92
+ <sort_order>7</sort_order>
93
  <show_in_default>1</show_in_default>
94
  <show_in_website>1</show_in_website>
95
+ <show_in_store>1</show_in_store>
96
  </module_url>
97
  <min_amount translate="label">
98
  <label>Min Amount</label>
99
  <frontend_type>text</frontend_type>
100
+ <sort_order>8</sort_order>
101
  <show_in_default>1</show_in_default>
102
  <show_in_website>1</show_in_website>
103
+ <show_in_store>1</show_in_store>
104
  </min_amount>
105
  <max_amount translate="label">
106
  <label>Max Amount</label>
107
  <frontend_type>text</frontend_type>
108
+ <sort_order>9</sort_order>
109
  <show_in_default>1</show_in_default>
110
  <show_in_website>1</show_in_website>
111
+ <show_in_store>1</show_in_store>
112
  </max_amount>
113
  <currencies translate="label">
114
  <label>Currencies</label>
115
  <frontend_type>text</frontend_type>
116
+ <sort_order>10</sort_order>
117
  <show_in_default>1</show_in_default>
118
  <show_in_website>1</show_in_website>
119
+ <show_in_store>1</show_in_store>
120
  </currencies>
121
 
122
  <user translate="label">
123
  <label>User</label>
124
  <frontend_type>text</frontend_type>
125
+ <sort_order>11</sort_order>
126
  <show_in_default>1</show_in_default>
127
  <show_in_website>1</show_in_website>
128
+ <show_in_store>1</show_in_store>
129
  </user>
130
  <pwd translate="label">
131
  <label>Password</label>
132
  <frontend_type>obscure</frontend_type>
133
  <backend_model>adminhtml/system_config_backend_encrypted</backend_model>
134
+ <sort_order>20</sort_order>
135
  <show_in_default>1</show_in_default>
136
  <show_in_website>1</show_in_website>
137
+ <show_in_store>1</show_in_store>
138
  </pwd>
139
 
140
  <new_order_status translate="label">
141
  <label>New order status</label>
142
  <frontend_type>select</frontend_type>
143
  <source_model>adminhtml/system_config_source_order_status_newprocessing</source_model>
144
+ <sort_order>30</sort_order>
145
  <show_in_default>1</show_in_default>
146
  <show_in_website>1</show_in_website>
147
+ <show_in_store>1</show_in_store>
148
  </new_order_status>
149
 
150
  <complete_order_status translate="label">
151
  <label>Approved order status</label>
152
  <frontend_type>select</frontend_type>
153
  <source_model>adminhtml/system_config_source_order_status_processing</source_model>
154
+ <sort_order>40</sort_order>
155
  <show_in_default>1</show_in_default>
156
  <show_in_website>1</show_in_website>
157
+ <show_in_store>1</show_in_store>
158
  </complete_order_status>
159
 
160
  <cancel_order_status translate="label">
161
  <label>Rejected order status</label>
162
  <frontend_type>select</frontend_type>
163
  <source_model>adminhtml/system_config_source_order_status</source_model>
164
+ <sort_order>50</sort_order>
165
  <show_in_default>1</show_in_default>
166
  <show_in_website>1</show_in_website>
167
+ <show_in_store>1</show_in_store>
168
  </cancel_order_status>
169
 
170
  <invoice translate="label">
171
  <label>Invoice when complete</label>
172
  <frontend_type>select</frontend_type>
173
  <source_model>adminhtml/system_config_source_yesno</source_model>
174
+ <sort_order>60</sort_order>
175
  <show_in_default>1</show_in_default>
176
  <show_in_website>1</show_in_website>
177
+ <show_in_store>1</show_in_store>
178
  </invoice>
179
 
180
  <allowspecific translate="label">
181
  <label>Payment from Applicable Countries</label>
182
  <frontend_type>allowspecific</frontend_type>
183
+ <sort_order>70</sort_order>
184
  <source_model>adminhtml/system_config_source_payment_allspecificcountries</source_model>
185
  <show_in_default>1</show_in_default>
186
  <show_in_website>1</show_in_website>
187
+ <show_in_store>1</show_in_store>
188
  </allowspecific>
189
  <specificcountry translate="label">
190
  <label>Payment from Specific Countries</label>
191
  <frontend_type>multiselect</frontend_type>
192
+ <sort_order>71</sort_order>
193
  <source_model>adminhtml/system_config_source_country</source_model>
194
  <show_in_default>1</show_in_default>
195
  <show_in_website>1</show_in_website>
196
+ <show_in_store>1</show_in_store>
197
  <can_be_empty>1</can_be_empty>
198
  </specificcountry>
199
 
200
  <sort_order translate="label">
201
  <label>Sort Order</label>
202
  <frontend_type>text</frontend_type>
203
+ <sort_order>100</sort_order>
204
  <show_in_default>1</show_in_default>
205
  <show_in_website>1</show_in_website>
206
+ <show_in_store>1</show_in_store>
207
  <frontend_class>validate-number</frontend_class>
208
  </sort_order>
209
 
app/code/community/J2t/Payplug/sql/j2tpayplug_setup/install-1.0.0.php ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /** @var $installer Mage_Paypal_Model_Resource_Setup */
4
+ $installer = $this;
5
+
6
+ /**
7
+ * Prepare database for install
8
+ */
9
+ $installer->startSetup();
10
+
11
+
12
+ /**
13
+ * Create table 'paypal/cert'
14
+ */
15
+ $table = $installer->getConnection()
16
+ ->newTable($installer->getTable('j2tpayplug/cert'))
17
+ ->addColumn('cert_id', Varien_Db_Ddl_Table::TYPE_SMALLINT, null, array(
18
+ 'identity' => true,
19
+ 'unsigned' => true,
20
+ 'nullable' => false,
21
+ 'primary' => true,
22
+ ), 'Cert Id')
23
+ ->addColumn('website_id', Varien_Db_Ddl_Table::TYPE_SMALLINT, null, array(
24
+ 'unsigned' => true,
25
+ 'nullable' => false,
26
+ 'default' => '0'
27
+ ), 'Website Id')
28
+ ->addColumn('content', Varien_Db_Ddl_Table::TYPE_TEXT, '64K', array(
29
+ ), 'Content')
30
+ ->addColumn('updated_at', Varien_Db_Ddl_Table::TYPE_TIMESTAMP, null, array(
31
+ ), 'Updated At')
32
+ ->addIndex($installer->getIdxName('j2tpayplug/cert', array('website_id')),
33
+ array('website_id'))
34
+ ->addForeignKey($installer->getFkName('j2tpayplug/cert', 'website_id', 'core/website', 'website_id'),
35
+ 'website_id', $installer->getTable('core/website'), 'website_id',
36
+ Varien_Db_Ddl_Table::ACTION_CASCADE, Varien_Db_Ddl_Table::ACTION_CASCADE)
37
+ ->setComment('Payplug Certificate Table');
38
+ $installer->getConnection()->createTable($table);
39
+
40
+
41
+ /**
42
+ * Prepare database after install
43
+ */
44
+ $installer->endSetup();
45
+
app/design/adminhtml/default/default/layout/j2tpayplug.xml DELETED
@@ -1,10 +0,0 @@
1
- <?xml version="1.0"?>
2
- <layout>
3
- <default>
4
- <reference name="head">
5
- <action method="addCss">
6
- <name>j2t_all_admin_1.css</name>
7
- </action>
8
- </reference>
9
- </default>
10
- </layout>
 
 
 
 
 
 
 
 
 
 
app/design/adminhtml/default/default/template/j2tpayplug/info.phtml DELETED
@@ -1,26 +0,0 @@
1
- <?php
2
- /**
3
- * Magento
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 so we can send you a copy immediately.
14
- *
15
- * @category design
16
- * @package default_default
17
- * @copyright Copyright (c) 2013 Phoenix Medien GmbH & Co. KG (http://www.phoenix-medien.de)
18
- * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
19
- */
20
- ?>
21
- <?php echo $this->escapeHtml($this->getMethod()->getTitle()) ?><br />
22
- <?php if ($this->getInfo()->getLastTransId() == ''): ?>
23
- <?php echo Mage::helper('j2tpayplug')->__('No transaction ID recorded.') ?><br />
24
- <?php else: ?>
25
- <?php echo Mage::helper('j2tpayplug')->__('PayPlug Transaction ID: %s', $this->escapeHtml($this->getInfo()->getLastTransId())) ?><br />
26
- <?php endif; ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
app/design/adminhtml/default/default/template/j2tpayplug/pdf/info.phtml DELETED
@@ -1,24 +0,0 @@
1
- <?php
2
- /**
3
- * Magento
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 so we can send you a copy immediately.
14
- *
15
- * @category design
16
- * @package default_default
17
- * @copyright Copyright (c) 2013 Phoenix Medien GmbH & Co. KG (http://www.phoenix-medien.de)
18
- * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
19
- */
20
- ?>
21
- <?php echo $this->escapeHtml($this->getMethod()->getTitle()) ?>
22
- {{pdf_row_separator}}
23
- <?php echo Mage::helper('j2tpayplug')->__('PayPlug Transaction ID: %s', $this->escapeHtml($this->getInfo()->getLastTransId())) ?>
24
- {{pdf_row_separator}}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
app/design/frontend/base/default/template/j2tpayplug/form.phtml CHANGED
@@ -30,12 +30,4 @@
30
  <?php echo $this->__('You will be redirected to our secure payment page when you place an order.') ?>
31
  </li>
32
  </ul>
33
- <ul>
34
- <li>
35
- <div style="padding:10px 15px 15px;">
36
- <img src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA)?>icon_accepted_cards_payplug.gif" alt="<?php echo $this->__('Payment by visa or mastercard'); ?>"><br>
37
- </div>
38
- </li>
39
- </ul>
40
-
41
 
30
  <?php echo $this->__('You will be redirected to our secure payment page when you place an order.') ?>
31
  </li>
32
  </ul>
 
 
 
 
 
 
 
 
33
 
app/locale/fr_FR/j2t_payplug.csv DELETED
@@ -1,30 +0,0 @@
1
- "User: %s","Utilisateur : %s"
2
- "Min allowed amount: %s %s","Montant minimum autorisé : %s %s"
3
- "Max allowed amount: %s %s","Montant maximum autorisé : %s %s"
4
- "Currency: %s","Devise supportée : %s"
5
- "Not configured yet","En attente de configuration"
6
- "Unable to retrieve account details.","Impossible de récupérer les informations du compte."
7
- "CURL error %s","Erreur CURL %s"
8
- "Both username and password must be defined.","Nom d'utilisateur et mot de passe obligatoires."
9
- "Invalid signature","Signature invalide"
10
- "Error while checking signature","Erreur lors de la vérification de la signature"
11
- "Payment has been captured by Payment Gateway. Transaction id: %s","Le paiement a été capturé par le serveur de paiement. Transaction : %s"
12
- "Cannot create an invoice.","Impossible de créer la facture."
13
- "Cannot create an invoice without products.","Impossible de créer une facture sans produits."
14
- "Payment canceled/refunded by Payment Gateway. Transaction id: %s","Le paiement a été annulée/remboursé par le serveur de paiement. Transaction : %s"
15
- "Error: missing or wrong parameters.","Erreur : paramètres manquants"
16
- "There has been a problem during the payment.","Il y a eu un problème lors du paiement."
17
- "You will be redirected to our secure payment page when you place an order.","Vous serez redirigé ver les serveur de paiement sécurisé lors de la finalisation de votre commande."
18
- "Account details","Détails du compte"
19
- "User","Utilisateur"
20
- "Password","Mot de passe"
21
- "New order status","Statut nouvelle commande"
22
- "Approved order status","Statut commande approuvée"
23
- "Rejected order status","Statut commande rejetée"
24
- "Invoice when complete","Facturer les commandes valides"
25
- "In order to use this payment method, it is necessary to create an account on <a target='_blank' href='http://www.payplug.fr/inscription?sponsor=83'>PayPlug</a>.","Afin de pouvoir utiliser ce mode de paiement, il est nécessaire de créer un compte sur <a target='_blank' href='http://www.payplug.fr/inscription?sponsor=83'>PayPlug</a>."
26
- "Enabled","Activé"
27
- "Title","Titre"
28
- "Payment from Applicable Countries","Paiement applicable depuis les pays"
29
- "Payment from Specific Countries","Paiement disponible pour les pays"
30
- "Sort Order","Ordre"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
media/icon_accepted_cards_payplug.gif DELETED
Binary file
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>J2t_Payplug</name>
4
- <version>1.0.9</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/OSL-3.0">OSL v3.0</license>
7
  <channel>community</channel>
@@ -10,9 +10,9 @@
10
  <description>It allows to pay with PayPlug</description>
11
  <notes>Introduction of sandbox feature</notes>
12
  <authors><author><name>J2T Design</name><user>j2tdesign</user><email>j2tdesign.net@gmail.com</email></author></authors>
13
- <date>2015-04-13</date>
14
- <time>07:19:17</time>
15
- <contents><target name="magecommunity"><dir name="J2t"><dir name="Payplug"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><file name="Accountdetails.php" hash="c89acdccd51f392dac8dfd032013683f"/></dir></dir></dir><file name="Form.php" hash="0c89710b2d4e94d76e9cc4b37ae3e7a6"/><file name="Info.php" hash="1879d72dca0d0762afa48d7039d07925"/></dir><dir name="Helper"><file name="Data.php" hash="123d5de46cd1577e867e8ab9b0236d09"/></dir><dir name="Model"><file name="Feed.php" hash="a7a040e81827020e74f22f760b8f3f64"/><file name="Observer.php" hash="b385fea0af6f8765f296a2b213b3f10c"/><file name="PaymentMethod.php" hash="c57e3ee3f1c22d2261369bdf3c1af331"/></dir><dir name="controllers"><file name="PaymentController.php" hash="cfb478f2726e775ac35c80ad0defc0f8"/></dir><dir name="etc"><file name="config.xml" hash="c4099f65e19234f9c7013c522ad93148"/><file name="system.xml" hash="1f942f50f54301e077328760f5cbc652"/></dir><file name=".DS_Store" hash="b2038aed8e98a37c493a010ca2c67fbc"/></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="j2tpayplug"><file name="form.phtml" hash="6edeec68d52f962cfe43b703d9925302"/><file name="info.phtml" hash="7270ac2591cb0ad18915d8f5e92bef69"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="j2tpayplug.xml" hash="b4f4d0cbe73cbd00bff554680f531741"/></dir><dir name="template"><dir name="j2tpayplug"><file name="info.phtml" hash="f6aa9ac4ef5ec0aa207e4b5a03666bd1"/><dir name="pdf"><file name="info.phtml" hash="007c81c2ae9e9b16522924a8073294ef"/></dir></dir></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="J2t_Payplug.xml" hash="dccffdae1d3e6bae6c2e01ed7ec0cff3"/></dir></target><target name="magelocale"><dir><dir name="fr_FR"><file name="j2t_payplug.csv" hash="e460bf539b3b0dc1632a1a7f616bcdfa"/></dir></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><file name="j2t_all_admin_1.css" hash="6d64fbd2a114cd820c11017c61bd0897"/><dir name="images"><file name="j2t_all_1.png" hash="19abc9040d74479f19eeb0c686f84766"/></dir></dir></dir></dir></target><target name="magemedia"><dir name="."><file name="icon_accepted_cards_payplug.gif" hash="5270a1ef6a85f679504849cdb1dccb2a"/></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>J2t_Payplug</name>
4
+ <version>1.0.10</version>
5
  <stability>stable</stability>
6
  <license uri="http://opensource.org/licenses/OSL-3.0">OSL v3.0</license>
7
  <channel>community</channel>
10
  <description>It allows to pay with PayPlug</description>
11
  <notes>Introduction of sandbox feature</notes>
12
  <authors><author><name>J2T Design</name><user>j2tdesign</user><email>j2tdesign.net@gmail.com</email></author></authors>
13
+ <date>2016-12-26</date>
14
+ <time>16:30:35</time>
15
+ <contents><target name="magecommunity"><dir name="J2t"><dir name="Payplug"><dir name="Block"><dir name="Adminhtml"><dir name="System"><dir name="Config"><file name="Accountdetails.php" hash="c89acdccd51f392dac8dfd032013683f"/></dir></dir></dir><file name="Form.php" hash="0c89710b2d4e94d76e9cc4b37ae3e7a6"/><file name="Info.php" hash="6e5e03ae417efe6d538b6437d5c99f87"/></dir><dir name="Helper"><file name="Data.php" hash="123d5de46cd1577e867e8ab9b0236d09"/></dir><dir name="Model"><file name="Observer.php" hash="8a5b8ac4ea934167cb03aac0af8f3822"/><file name="PaymentMethod.php" hash="dda6ff53374e6656ce1bcee68992c384"/></dir><dir name="controllers"><file name="PaymentController.php" hash="195a5069f5041ba5a5c528ccd9df5791"/></dir><dir name="etc"><file name="config.xml" hash="99f3dbba953d973970a33421c6d42930"/><file name="system.xml" hash="bfb3f1cb7466f1c893847ba660549842"/></dir><dir name="sql"><dir name="j2tpayplug_setup"><file name="install-1.0.0.php" hash="38cd84e5305bf53bca042f3a325523e5"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="template"><dir name="j2tpayplug"><file name="form.phtml" hash="cacf102de2ad4d183c502ad85d309439"/><file name="info.phtml" hash="7270ac2591cb0ad18915d8f5e92bef69"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="j2tpayplug.xml" hash=""/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="J2t_Payplug.xml" hash="dccffdae1d3e6bae6c2e01ed7ec0cff3"/></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><file name="j2t_all_admin_1.css" hash=""/><dir name="images"><file name="j2t_all_1.png" hash=""/></dir></dir></dir></dir></target><target name="magemedia"><dir name="."><file name="icon_accepted_cards_payplug.gif" hash=""/></dir></target></contents>
16
  <compatible/>
17
  <dependencies><required><php><min>5.1.0</min><max>6.0.0</max></php></required></dependencies>
18
  </package>
skin/adminhtml/default/default/images/j2t_all_1.png DELETED
Binary file
skin/adminhtml/default/default/j2t_all_admin_1.css DELETED
@@ -1,78 +0,0 @@
1
- ul.tabs a.j2t-all-tab span, ul.tabs a.j2t-all-tab:hover span {
2
- background: url("./images/j2t_all_1.png") no-repeat scroll 0 0 transparent;
3
- height: 0;
4
- overflow: hidden;
5
- padding: 21px 0 0;
6
- width: 192px;
7
- }
8
-
9
- ul.tabs a.j2t-all-tab, ul.tabs a.j2t-all-tab:hover {
10
- background: url("../../images/tabs_span_bg.gif") repeat-x scroll 0 100% transparent;
11
- border-bottom: medium none;
12
- padding: 0.5em 0.5em 0.28em 1.5em;
13
- }
14
-
15
- ul.tabs a.j2t-ajaxcart-module span, ul.tabs a.j2t-ajaxcart-module:hover span {
16
- background: url("./images/j2t/ajax_cart.png") no-repeat scroll 0 0 transparent;
17
- padding: 0 20px 0;
18
- }
19
- ul.tabs a.j2t-rewardpoints-module span, ul.tabs a.j2t-rewardpoints-module:hover span {
20
- background: url("./images/j2t/reward_points.png") no-repeat scroll 0 0 transparent;
21
- padding: 0 20px 0;
22
- }
23
- ul.tabs a.j2t-autoadd-module span, ul.tabs a.j2t-autoadd-module:hover span {
24
- background: url("./images/j2t/auto_add.png") no-repeat scroll 0 0 transparent;
25
- padding: 0 20px 0;
26
- }
27
- ul.tabs a.j2t-onecheckout-module span, ul.tabs a.j2t-onecheckout-module:hover span {
28
- background: url("./images/j2t/one_checkout.png") no-repeat scroll 0 0 transparent;
29
- padding: 0 20px 0;
30
- }
31
-
32
- ul.tabs a.j2t-socialconnect-module span, ul.tabs a.j2t-socialconnect-module:hover span {
33
- background: url("./images/j2t/social_connect.png") no-repeat scroll 0 0 transparent;
34
- padding: 0 20px 0;
35
- }
36
-
37
- ul.tabs a.j2t-producthold-module span, ul.tabs a.j2t-producthold-module:hover span {
38
- background: url("./images/j2t/product_hold.png") no-repeat scroll 0 0 transparent;
39
- padding: 0 20px 0;
40
- }
41
-
42
- ul.tabs a.j2t-giftwrap-module span, ul.tabs a.j2t-giftwrap-module:hover span {
43
- background: url("./images/j2t/gift_wrap.png") no-repeat scroll 0 0 transparent;
44
- padding: 0 20px 0;
45
- }
46
-
47
- ul.tabs a.j2t-giftvoucher-module span, ul.tabs a.j2t-giftvoucher-module:hover span {
48
- background: url("./images/j2t/gift_voucher.png") no-repeat scroll 0 0 transparent;
49
- padding: 0 20px 0;
50
- }
51
-
52
- ul.tabs a.j2t-ajaxcart-module, ul.tabs a.j2t-ajaxcart-module:hover,
53
- ul.tabs a.j2t-rewardpoints-module, ul.tabs a.j2t-rewardpoints-module:hover,
54
- ul.tabs a.j2t-autoadd-module, ul.tabs a.j2t-autoadd-module:hover,
55
- ul.tabs a.j2t-onecheckout-module, ul.tabs a.j2t-onecheckout-module:hover,
56
- ul.tabs a.j2t-socialconnect-module, ul.tabs a.j2t-socialconnect-module:hover,
57
- ul.tabs a.j2t-producthold-module, ul.tabs a.j2t-producthold-module:hover,
58
- ul.tabs a.j2t-giftwrap-module, ul.tabs a.j2t-giftwrap-module:hover,
59
- ul.tabs a.j2t-giftvoucher-module, ul.tabs a.j2t-giftvoucher-module:hover
60
- {
61
- padding: 0.5em 0.5em 0.28em 1.5em;
62
- border-bottom: dotted 1px #c0c0c0;
63
- }
64
-
65
- ul.tabs a.j2t-ajaxcart-module.active, ul.tabs a.j2t-ajaxcart-module.active:hover,
66
- ul.tabs a.j2t-rewardpoints-module.active, ul.tabs a.j2t-rewardpoints-module.active:hover,
67
- ul.tabs a.j2t-autoadd-module.active, ul.tabs a.j2t-autoadd-module.active:hover,
68
- ul.tabs a.j2t-onecheckout-module.active, ul.tabs a.j2t-onecheckout-module.active:hover,
69
- ul.tabs a.j2t-all-tab.active, ul.tabs a.j2t-all-tab.active:hover,
70
- ul.tabs a.j2t-socialconnect-module.active, ul.tabs a.j2t-socialconnect-module.active:hover,
71
- ul.tabs a.j2t-producthold-module.active, ul.tabs a.j2t-producthold-module.active:hover,
72
- ul.tabs a.j2t-giftwrap-module.active, ul.tabs a.j2t-giftwrap-module.active:hover,
73
- ul.tabs a.j2t-giftvoucher-module.active, ul.tabs a.j2t-giftvoucher-module.active:hover
74
- {
75
- background-color: #FFFFFF;
76
- }
77
-
78
- ul.tabs a.j2t-all-tab, ul.tabs a.j2t-all-tab {border:none;}