Version Notes
keine
Download this release
Release Info
Developer | Magento Core Team |
Extension | symmetrics_cashticket |
Version | 0.1.4 |
Comparing to | |
See all releases |
Version 0.1.4
- app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config.php +26 -0
- app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Edit.php +59 -0
- app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Edit/Form.php +145 -0
- app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Grid.php +117 -0
- app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Renderer.php +29 -0
- app/code/community/Symmetrics/CashTicket/Block/Error.php +34 -0
- app/code/community/Symmetrics/CashTicket/Block/Form.php +23 -0
- app/code/community/Symmetrics/CashTicket/Block/Info.php +124 -0
- app/code/community/Symmetrics/CashTicket/Helper/Data.php +13 -0
- app/code/community/Symmetrics/CashTicket/Model/Api.php +357 -0
- app/code/community/Symmetrics/CashTicket/Model/Cashticket.php +237 -0
- app/code/community/Symmetrics/CashTicket/Model/Item.php +44 -0
- app/code/community/Symmetrics/CashTicket/Model/Mysql4/Item.php +16 -0
- app/code/community/Symmetrics/CashTicket/Model/Mysql4/Item/Collection.php +17 -0
- app/code/community/Symmetrics/CashTicket/Model/Source/Businesstype.php +24 -0
- app/code/community/Symmetrics/CashTicket/Model/Source/Currency.php +31 -0
- app/code/community/Symmetrics/CashTicket/Model/Source/Locale.php +26 -0
- app/code/community/Symmetrics/CashTicket/controllers/Adminhtml/CashticketController.php +121 -0
- app/code/community/Symmetrics/CashTicket/controllers/Adminhtml/ConfigController.php +173 -0
- app/code/community/Symmetrics/CashTicket/controllers/ProcessingController.php +200 -0
- app/code/community/Symmetrics/CashTicket/etc/config.xml +146 -0
- app/code/community/Symmetrics/CashTicket/etc/system.xml +103 -0
- app/code/community/Symmetrics/CashTicket/sql/cashticket_setup/mysql4-install-0.1.0.php +36 -0
- app/design/adminhtml/default/default/layout/cashticket.xml +22 -0
- app/design/adminhtml/default/default/template/cashticket/info.phtml +55 -0
- app/design/frontend/default/default/template/cashticket/form.phtml +19 -0
- app/design/frontend/default/default/template/cashticket/info.phtml +11 -0
- app/etc/modules/Symmetrics_CashTicket.xml +12 -0
- js/symmetrics/adminhtml/cashticket.js +38 -0
- package.xml +18 -0
- skin/frontend/default/default/images/cashticket/cashticket-logo.png +0 -0
- var/cashticket/paysafecard-CA.pem +227 -0
app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config.php
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Adminhtml_Config extends Mage_Adminhtml_Block_Widget_Grid_Container
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Prepare the page with
|
14 |
+
* the grid on it
|
15 |
+
*
|
16 |
+
* @return object
|
17 |
+
*/
|
18 |
+
public function __construct()
|
19 |
+
{
|
20 |
+
$this->_controller = 'adminhtml_config';
|
21 |
+
$this->_blockGroup = 'cashticket';
|
22 |
+
$this->_headerText = Mage::helper('cashticket')->__('Cash-Ticket Configuration');
|
23 |
+
$this->_addButtonLabel = Mage::helper('cashticket')->__('Add Item');
|
24 |
+
parent::__construct();
|
25 |
+
}
|
26 |
+
}
|
app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Edit.php
ADDED
@@ -0,0 +1,59 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Adminhtml_Config_Edit extends Mage_Adminhtml_Block_Widget_Form_Container
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Add buttons to the edit form
|
14 |
+
*
|
15 |
+
* @return void
|
16 |
+
*/
|
17 |
+
public function __construct()
|
18 |
+
{
|
19 |
+
parent::__construct();
|
20 |
+
|
21 |
+
$this->_objectId = 'id';
|
22 |
+
$this->_blockGroup = 'cashticket';
|
23 |
+
$this->_controller = 'adminhtml_config';
|
24 |
+
|
25 |
+
$this->_updateButton('save', 'label', Mage::helper('cashticket')->__('Save'));
|
26 |
+
$this->_updateButton('delete', 'label', Mage::helper('cashticket')->__('Delete'));
|
27 |
+
|
28 |
+
// add "save and continue" button
|
29 |
+
$this->_addButton('saveandcontinue', array(
|
30 |
+
'label' => Mage::helper('adminhtml')->__('Save And Continue Edit'),
|
31 |
+
'onclick' => 'saveAndContinueEdit()',
|
32 |
+
'class' => 'save',
|
33 |
+
), -100);
|
34 |
+
|
35 |
+
// js needed for "save and continue"
|
36 |
+
$this->_formScripts[] = "
|
37 |
+
function saveAndContinueEdit(){
|
38 |
+
editForm.submit($('edit_form').action+'back/edit/');
|
39 |
+
}
|
40 |
+
";
|
41 |
+
}
|
42 |
+
|
43 |
+
/**
|
44 |
+
* Set page header
|
45 |
+
*
|
46 |
+
* @return string
|
47 |
+
*/
|
48 |
+
public function getHeaderText()
|
49 |
+
{
|
50 |
+
// if editing an item - set "Edit" as a page header
|
51 |
+
if (Mage::registry('cashticket_data') && Mage::registry('cashticket_data')->getId()) {
|
52 |
+
return Mage::helper('cashticket')->__('Edit Item "%s"', $this->htmlEscape(Mage::registry('cashticket_data')->getCurrencyCode()));
|
53 |
+
}
|
54 |
+
else {
|
55 |
+
// ohterwise set "Add"
|
56 |
+
return Mage::helper('cashticket')->__('Add Item');
|
57 |
+
}
|
58 |
+
}
|
59 |
+
}
|
app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Edit/Form.php
ADDED
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Adminhtml_Config_Edit_Form extends Mage_Adminhtml_Block_Widget_Form
|
11 |
+
{
|
12 |
+
public function __construct()
|
13 |
+
{
|
14 |
+
parent::__construct();
|
15 |
+
$this->setId('editForm');
|
16 |
+
}
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Preparing the form and adding
|
20 |
+
* fields to it
|
21 |
+
*
|
22 |
+
* @return object
|
23 |
+
*/
|
24 |
+
protected function _prepareForm()
|
25 |
+
{
|
26 |
+
$form = new Varien_Data_Form(array(
|
27 |
+
'id' => 'edit_form',
|
28 |
+
'action' => $this->getUrl('*/*/save', array('id' => $this->getRequest()->getParam('id'))),
|
29 |
+
'method' => 'post',
|
30 |
+
'enctype' => 'multipart/form-data'
|
31 |
+
));
|
32 |
+
|
33 |
+
$fieldset = $form->addFieldset('cashticket_form', array(
|
34 |
+
'legend' => Mage::helper('cashticket')->__('Cash-Ticket Configuration'))
|
35 |
+
);
|
36 |
+
|
37 |
+
if ($this->getRequest()->getParam('id')) {
|
38 |
+
$fieldset->addField('item_id', 'hidden', array(
|
39 |
+
'name' => 'item_id',
|
40 |
+
));
|
41 |
+
}
|
42 |
+
|
43 |
+
$fieldset->addField('enable', 'select', array(
|
44 |
+
'label' => Mage::helper('cashticket')->__('Enable'),
|
45 |
+
'class' => 'required-entry',
|
46 |
+
'required' => true,
|
47 |
+
'name' => 'enable',
|
48 |
+
'options' => array(
|
49 |
+
0 => Mage::helper('cashticket')->__('No'),
|
50 |
+
1 => Mage::helper('cashticket')->__('Yes'),
|
51 |
+
)
|
52 |
+
));
|
53 |
+
|
54 |
+
$fieldset->addField('currency_code', 'select', array(
|
55 |
+
'label' => Mage::helper('cashticket')->__('Currency'),
|
56 |
+
'class' => 'required-entry',
|
57 |
+
'required' => true,
|
58 |
+
'name' => 'currency_code',
|
59 |
+
'options' => Mage::getModel('cashticket/source_currency')->getOptionArray()
|
60 |
+
));
|
61 |
+
|
62 |
+
$fieldset->addField('merchant_id', 'text', array(
|
63 |
+
'label' => Mage::helper('cashticket')->__('Merchant ID'),
|
64 |
+
'class' => 'required-entry',
|
65 |
+
'required' => true,
|
66 |
+
'name' => 'merchant_id',
|
67 |
+
));
|
68 |
+
|
69 |
+
$fieldset->addField('business_type', 'select', array(
|
70 |
+
'label' => Mage::helper('cashticket')->__('Business Type'),
|
71 |
+
'class' => 'required-entry',
|
72 |
+
'required' => true,
|
73 |
+
'name' => 'business_type',
|
74 |
+
'options' => Mage::getModel('cashticket/source_businesstype')->getOptionArray()
|
75 |
+
));
|
76 |
+
|
77 |
+
$fieldset->addField('reporting_criteria', 'text', array(
|
78 |
+
'label' => Mage::helper('cashticket')->__('Reporting Criteria'),
|
79 |
+
'required' => false,
|
80 |
+
'name' => 'reporting_criteria',
|
81 |
+
));
|
82 |
+
|
83 |
+
$fieldset->addField('locale', 'select', array(
|
84 |
+
'label' => Mage::helper('cashticket')->__('Language'),
|
85 |
+
'class' => 'required-entry',
|
86 |
+
'required' => true,
|
87 |
+
'name' => 'locale',
|
88 |
+
'options' => Mage::getModel('cashticket/source_locale')->getOptionArray()
|
89 |
+
));
|
90 |
+
|
91 |
+
$fieldset->addField('path_pem_test', 'text', array(
|
92 |
+
'label' => Mage::helper('cashticket')->__('Path to PEM Certificate (Test)'),
|
93 |
+
'class' => 'required-entry',
|
94 |
+
'required' => true,
|
95 |
+
'name' => 'path_pem_test',
|
96 |
+
));
|
97 |
+
|
98 |
+
$fieldset->addField('path_pem_live', 'text', array(
|
99 |
+
'label' => Mage::helper('cashticket')->__('Path to PEM Certificate (Live)'),
|
100 |
+
'class' => 'required-entry',
|
101 |
+
'required' => true,
|
102 |
+
'name' => 'path_pem_live',
|
103 |
+
));
|
104 |
+
|
105 |
+
$fieldset->addField('path_cert', 'text', array(
|
106 |
+
'label' => Mage::helper('cashticket')->__('Path to the Server Certificate'),
|
107 |
+
'class' => 'required-entry',
|
108 |
+
'required' => true,
|
109 |
+
'name' => 'path_cert',
|
110 |
+
));
|
111 |
+
|
112 |
+
$fieldset->addField('sslcert_pass', 'text', array(
|
113 |
+
'label' => Mage::helper('cashticket')->__('Keyring Password'),
|
114 |
+
'class' => 'required-entry',
|
115 |
+
'required' => true,
|
116 |
+
'name' => 'sslcert_pass',
|
117 |
+
));
|
118 |
+
|
119 |
+
$fieldset->addField('sandbox', 'select', array(
|
120 |
+
'label' => Mage::helper('cashticket')->__('Sandbox'),
|
121 |
+
'class' => 'required-entry',
|
122 |
+
'required' => true,
|
123 |
+
'name' => 'sandbox',
|
124 |
+
'options' => array(
|
125 |
+
0 => Mage::helper('cashticket')->__('No'),
|
126 |
+
1 => Mage::helper('cashticket')->__('Yes'),
|
127 |
+
)
|
128 |
+
));
|
129 |
+
|
130 |
+
// get form values from the session
|
131 |
+
if (Mage::getSingleton('adminhtml/session')->getCashticketData()) {
|
132 |
+
$form->setValues(Mage::getSingleton('adminhtml/session')->getCashticketData());
|
133 |
+
Mage::getSingleton('adminhtml/session')->setCashticketData(null);
|
134 |
+
}
|
135 |
+
elseif (Mage::registry('cashticket_data')) {
|
136 |
+
$form->setValues(Mage::registry('cashticket_data')->getData());
|
137 |
+
}
|
138 |
+
|
139 |
+
$form->setAction($this->getUrl('*/*/save'));
|
140 |
+
$form->setUseContainer(true);
|
141 |
+
$this->setForm($form);
|
142 |
+
|
143 |
+
return parent::_prepareForm();
|
144 |
+
}
|
145 |
+
}
|
app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Grid.php
ADDED
@@ -0,0 +1,117 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Adminhtml_Config_Grid extends Mage_Adminhtml_Block_Widget_Grid
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Prepare the grid
|
14 |
+
*
|
15 |
+
* @return void
|
16 |
+
*/
|
17 |
+
public function __construct()
|
18 |
+
{
|
19 |
+
parent::__construct();
|
20 |
+
|
21 |
+
$this->setId('cashticketGrid');
|
22 |
+
$this->setDefaultSort('currency_id');
|
23 |
+
$this->setDefaultDir('ASC');
|
24 |
+
$this->setSaveParametersInSession(true);
|
25 |
+
}
|
26 |
+
|
27 |
+
/**
|
28 |
+
* Get collection of config items
|
29 |
+
* and set it into the grid object
|
30 |
+
*
|
31 |
+
* @return string
|
32 |
+
*/
|
33 |
+
protected function _prepareCollection()
|
34 |
+
{
|
35 |
+
$collection = Mage::getModel('cashticket/item')->getCollection();
|
36 |
+
|
37 |
+
$this->setCollection($collection);
|
38 |
+
return parent::_prepareCollection();
|
39 |
+
}
|
40 |
+
|
41 |
+
/**
|
42 |
+
* Set grid columns
|
43 |
+
*
|
44 |
+
* @return object
|
45 |
+
*/
|
46 |
+
protected function _prepareColumns()
|
47 |
+
{
|
48 |
+
$this->addColumn('enable', array(
|
49 |
+
'header' => Mage::helper('cashticket')->__('Enabled'),
|
50 |
+
'type' => 'options',
|
51 |
+
'index' => 'enable',
|
52 |
+
'sortable' => true,
|
53 |
+
'options' => array(
|
54 |
+
'1' => Mage::helper('cashticket')->__('Yes'),
|
55 |
+
'0' => Mage::helper('cashticket')->__('No')
|
56 |
+
),
|
57 |
+
'width' => '100px'
|
58 |
+
));
|
59 |
+
|
60 |
+
$this->addColumn('currency_code', array(
|
61 |
+
'header' => Mage::helper('cashticket')->__('Currency'),
|
62 |
+
'type' => 'text',
|
63 |
+
'index' => 'currency_code',
|
64 |
+
'sortable' => true
|
65 |
+
));
|
66 |
+
|
67 |
+
$this->addColumn('merchant_id', array(
|
68 |
+
'header' => Mage::helper('cashticket')->__('Merchant ID'),
|
69 |
+
'type' => 'text',
|
70 |
+
'index' => 'merchant_id',
|
71 |
+
'sortable' => true
|
72 |
+
));
|
73 |
+
|
74 |
+
$this->addColumn('sandbox', array(
|
75 |
+
'header' => Mage::helper('cashticket')->__('Sanbox'),
|
76 |
+
'type' => 'options',
|
77 |
+
'index' => 'sandbox',
|
78 |
+
'sortable' => true,
|
79 |
+
'options' => array(
|
80 |
+
'1' => Mage::helper('cashticket')->__('Yes'),
|
81 |
+
'0' => Mage::helper('cashticket')->__('No')
|
82 |
+
),
|
83 |
+
'width' => '100px'
|
84 |
+
));
|
85 |
+
|
86 |
+
// add "edit" link into the action column
|
87 |
+
$this->addColumn('action',
|
88 |
+
array(
|
89 |
+
'header' => Mage::helper('cashticket')->__('Action'),
|
90 |
+
'type' => 'action',
|
91 |
+
'getter' => 'getId',
|
92 |
+
'actions' => array(array(
|
93 |
+
'caption' => Mage::helper('catalog')->__('Edit'),
|
94 |
+
'url' => array(
|
95 |
+
'base' => '*/*/edit'
|
96 |
+
),
|
97 |
+
'field' => 'id'
|
98 |
+
)),
|
99 |
+
'filter' => false,
|
100 |
+
'sortable' => false,
|
101 |
+
'index' => 'config',
|
102 |
+
'width' => '100px'
|
103 |
+
));
|
104 |
+
|
105 |
+
return parent::_prepareColumns();
|
106 |
+
}
|
107 |
+
|
108 |
+
/**
|
109 |
+
* Set the edit url
|
110 |
+
*
|
111 |
+
* @return string
|
112 |
+
*/
|
113 |
+
public function getRowUrl($row)
|
114 |
+
{
|
115 |
+
return $this->getUrl('*/*/edit', array('id' => $row->getId()));
|
116 |
+
}
|
117 |
+
}
|
app/code/community/Symmetrics/CashTicket/Block/Adminhtml/Config/Renderer.php
ADDED
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Adminhtml_Config_Renderer extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Rendering of the grid column
|
14 |
+
*
|
15 |
+
* @return string
|
16 |
+
*/
|
17 |
+
public function render(Varien_Object $row)
|
18 |
+
{
|
19 |
+
$values = array();
|
20 |
+
foreach (Mage::getModel('cashticket/item')->getSizeOptions() as $option) {
|
21 |
+
foreach ($option as $key => $val) {
|
22 |
+
if ($val['value'] == $row->getSize()) {
|
23 |
+
return $val['label'];
|
24 |
+
$values[$val['value']] = $val['label'];
|
25 |
+
}
|
26 |
+
}
|
27 |
+
}
|
28 |
+
}
|
29 |
+
}
|
app/code/community/Symmetrics/CashTicket/Block/Error.php
ADDED
@@ -0,0 +1,34 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Error extends Mage_Core_Block_Abstract
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* This block is shown when the customer
|
14 |
+
* cancels the payment process from
|
15 |
+
* CashTicket page
|
16 |
+
*
|
17 |
+
* @return string
|
18 |
+
*/
|
19 |
+
protected function _toHtml()
|
20 |
+
{
|
21 |
+
$url = Mage::getUrl('checkout/onepage');
|
22 |
+
|
23 |
+
$html = '';
|
24 |
+
|
25 |
+
$html .= '<p>'.Mage::helper('cashticket')->__('Cash-Ticket payment was canceled. Redirecting to checkout...').'</p>';
|
26 |
+
$html .= '<p><a href="'.$url.'">'.Mage::helper('cashticket')->__('Click here to return to checkout').'</a></p>';
|
27 |
+
|
28 |
+
$html .= '<script language="javascript">';
|
29 |
+
$html .= 'document.location.href="'.$url.'";';
|
30 |
+
$html .= '</script>';
|
31 |
+
|
32 |
+
return $html;
|
33 |
+
}
|
34 |
+
}
|
app/code/community/Symmetrics/CashTicket/Block/Form.php
ADDED
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Form extends Mage_Payment_Block_Form
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Set template for payment info
|
14 |
+
* below the radio selector
|
15 |
+
*
|
16 |
+
* @return object
|
17 |
+
*/
|
18 |
+
protected function _construct()
|
19 |
+
{
|
20 |
+
$this->setTemplate('cashticket/form.phtml');
|
21 |
+
parent::_construct();
|
22 |
+
}
|
23 |
+
}
|
app/code/community/Symmetrics/CashTicket/Block/Info.php
ADDED
@@ -0,0 +1,124 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Block_Info extends Mage_Payment_Block_Info
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Result of the API call
|
14 |
+
*
|
15 |
+
* @var object
|
16 |
+
*/
|
17 |
+
protected $_response;
|
18 |
+
|
19 |
+
/**
|
20 |
+
* API object
|
21 |
+
*
|
22 |
+
* @var object
|
23 |
+
*/
|
24 |
+
protected $_api;
|
25 |
+
|
26 |
+
/**
|
27 |
+
* Set template for payment info
|
28 |
+
* on the right side of the
|
29 |
+
* checkout page
|
30 |
+
*
|
31 |
+
* @return void
|
32 |
+
*/
|
33 |
+
protected function _construct()
|
34 |
+
{
|
35 |
+
parent::_construct();
|
36 |
+
$this->setTemplate('cashticket/info.phtml');
|
37 |
+
}
|
38 |
+
|
39 |
+
/**
|
40 |
+
* Get the API object
|
41 |
+
*
|
42 |
+
* @return object
|
43 |
+
*/
|
44 |
+
public function getApi($transactionId)
|
45 |
+
{
|
46 |
+
if (is_null($this->_api)) {
|
47 |
+
$cashticketModel = Mage::getModel('cashticket/cashticket');
|
48 |
+
$this->_api = $cashticketModel->getApi($transactionId);
|
49 |
+
$this->_api->setOrder($this->getInfo()->getOrder());
|
50 |
+
}
|
51 |
+
return $this->_api;
|
52 |
+
}
|
53 |
+
|
54 |
+
/**
|
55 |
+
* Get disposition state from Cash-Ticket
|
56 |
+
* and set the response for later use
|
57 |
+
*
|
58 |
+
* @return object
|
59 |
+
*/
|
60 |
+
public function callGetSerialNumbers()
|
61 |
+
{
|
62 |
+
if (is_null($this->_response)) {
|
63 |
+
$this->_response = $this->_api->call('GetSerialNumbers', array());
|
64 |
+
|
65 |
+
if ($this->_response->errCode != '0') {
|
66 |
+
Mage::throwException(Mage::helper('cashticket')->__('Error getting Cash-Ticket status.'));
|
67 |
+
return $this;
|
68 |
+
}
|
69 |
+
}
|
70 |
+
return $this->_response;
|
71 |
+
}
|
72 |
+
|
73 |
+
/**
|
74 |
+
* Map status codes to strings
|
75 |
+
*
|
76 |
+
* @return string
|
77 |
+
*/
|
78 |
+
public function getPaymentStatus()
|
79 |
+
{
|
80 |
+
if (is_null($this->_response)) {
|
81 |
+
return $this;
|
82 |
+
}
|
83 |
+
|
84 |
+
switch ($this->_response->TransactionState) {
|
85 |
+
case 'R':
|
86 |
+
$status = $this->helper('cashticket')->__('Created (R)');
|
87 |
+
break;
|
88 |
+
case 'S':
|
89 |
+
$status = $this->helper('cashticket')->__('Disposed (S)');
|
90 |
+
break;
|
91 |
+
case 'E':
|
92 |
+
$status = $this->helper('cashticket')->__('Debited (E)');
|
93 |
+
break;
|
94 |
+
case 'O':
|
95 |
+
$status = $this->helper('cashticket')->__('Consumed (O)');
|
96 |
+
break;
|
97 |
+
case 'L':
|
98 |
+
$status = $this->helper('cashticket')->__('Canceled (L)');
|
99 |
+
break;
|
100 |
+
case 'I':
|
101 |
+
$status = $this->helper('cashticket')->__('Invalid (I)');
|
102 |
+
break;
|
103 |
+
case 'X':
|
104 |
+
$status = $this->helper('cashticket')->__('Expired (X)');
|
105 |
+
break;
|
106 |
+
default:
|
107 |
+
$status = $this->helper('cashticket')->__(sprintf(Mage::helper('cashticket')->__('Unknown status (%s)'), $response->TransactionState));
|
108 |
+
break;
|
109 |
+
}
|
110 |
+
|
111 |
+
return $status;
|
112 |
+
}
|
113 |
+
|
114 |
+
/**
|
115 |
+
* Get status codes allowed to
|
116 |
+
* continue transactions and debiting
|
117 |
+
*
|
118 |
+
* @return array
|
119 |
+
*/
|
120 |
+
public function getAllowedStats()
|
121 |
+
{
|
122 |
+
return array('R', 'S', 'E');
|
123 |
+
}
|
124 |
+
}
|
app/code/community/Symmetrics/CashTicket/Helper/Data.php
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Helper_Data extends Mage_Core_Helper_Abstract
|
11 |
+
{
|
12 |
+
|
13 |
+
}
|
app/code/community/Symmetrics/CashTicket/Model/Api.php
ADDED
@@ -0,0 +1,357 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_Api extends Varien_Http_Adapter_Curl
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Id of the Cash-Ticket transaction
|
14 |
+
*
|
15 |
+
* @var string
|
16 |
+
*/
|
17 |
+
protected $_transactionId = '';
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Use testing server or not
|
21 |
+
*
|
22 |
+
* @var boolean
|
23 |
+
*/
|
24 |
+
protected $_sandbox = null;
|
25 |
+
|
26 |
+
/**
|
27 |
+
* Current order
|
28 |
+
*
|
29 |
+
* @var object
|
30 |
+
*/
|
31 |
+
protected $_order = null;
|
32 |
+
|
33 |
+
/**
|
34 |
+
* Configuration array
|
35 |
+
*
|
36 |
+
* @var array
|
37 |
+
*/
|
38 |
+
protected $_config = null;
|
39 |
+
|
40 |
+
/**
|
41 |
+
* Main method for calling API functions
|
42 |
+
* on Cash-Ticket
|
43 |
+
*
|
44 |
+
* @return object
|
45 |
+
*/
|
46 |
+
public function call($functionName, array $params)
|
47 |
+
{
|
48 |
+
$callParams = '';
|
49 |
+
|
50 |
+
// merge set params with standard params
|
51 |
+
$params = array_merge(array(
|
52 |
+
'currency' => $this->getConfigValue('currency_code'),
|
53 |
+
'mid' => $this->getConfigValue('merchant_id'),
|
54 |
+
'businesstype' => $this->getConfigValue('business_type'),
|
55 |
+
'reportingcriteria' => $this->getConfigValue('reporting_criteria'),
|
56 |
+
'okurl' => Mage::getUrl('cashticket/processing/success'),
|
57 |
+
'nokurl' => Mage::getUrl('cashticket/processing/error'),
|
58 |
+
'locale' => $this->getConfigValue('locale'),
|
59 |
+
'outputFormat' => 'xml_v1',
|
60 |
+
'mtid' => $this->getTransactionId()
|
61 |
+
), $params);
|
62 |
+
|
63 |
+
// format params for curl
|
64 |
+
foreach ($params as $key => $value) {
|
65 |
+
$callParams .= '&'.$key.'='.urlencode($value);
|
66 |
+
}
|
67 |
+
|
68 |
+
try {
|
69 |
+
// do curl post
|
70 |
+
$this->write(Zend_Http_Client::POST, $this->getCashTicketUrl().$functionName . 'Servlet', '1.1', array(), $callParams);
|
71 |
+
|
72 |
+
// read response and convert it to XML
|
73 |
+
$response = $this->read();
|
74 |
+
$response = new Varien_Simplexml_Element($response);
|
75 |
+
}
|
76 |
+
catch (Exception $e) {
|
77 |
+
Mage::throwException(Mage::helper('cashticket')->__('CURL connection failed. Reason: ') . $e->getMessage());
|
78 |
+
}
|
79 |
+
|
80 |
+
return $response;
|
81 |
+
}
|
82 |
+
|
83 |
+
/**
|
84 |
+
* Writing a method to curl api
|
85 |
+
*
|
86 |
+
* @return string
|
87 |
+
*/
|
88 |
+
public function write($method, $url, $http_ver = '1.1', $headers = array(), $body = '')
|
89 |
+
{
|
90 |
+
// get keyring password
|
91 |
+
$sslpass = $this->getConfigValue('sslcert_pass');
|
92 |
+
|
93 |
+
// can not process if no keyring password is set
|
94 |
+
if (empty($sslpass)) {
|
95 |
+
Mage::throwException(Mage::helper('cashticket')->__('SSL Certificate Password is empty. Please set the passwort in the configuration settings.'));
|
96 |
+
}
|
97 |
+
// if testing
|
98 |
+
if ($this->isSandbox()) {
|
99 |
+
// set PEM certificate of the test server
|
100 |
+
$pemCert = Mage::getBaseDir() . $this->getConfigValue('path_pem_test');
|
101 |
+
}
|
102 |
+
else {
|
103 |
+
// set PEM certificate of the live server
|
104 |
+
$pemCert = Mage::getBaseDir() . $this->getConfigValue('path_pem_live');
|
105 |
+
}
|
106 |
+
// if PEM certificate not found
|
107 |
+
if (!file_exists($pemCert)) {
|
108 |
+
Mage::throwException(Mage::helper('cashticket')->__('File with PEM Certificate does not exist'));
|
109 |
+
}
|
110 |
+
// if server certificate not found
|
111 |
+
if (!file_exists(Mage::getBaseDir() . $this->getConfigValue('path_cert'))) {
|
112 |
+
Mage::throwException(Mage::helper('cashticket')->__('File with Server Certificate does not exist'));
|
113 |
+
}
|
114 |
+
|
115 |
+
// set curl connection options
|
116 |
+
curl_setopt($this->_getResource(), CURLOPT_URL, $url);
|
117 |
+
curl_setopt($this->_getResource(), CURLOPT_POST, true);
|
118 |
+
curl_setopt($this->_getResource(), CURLOPT_POSTFIELDS, $body);
|
119 |
+
curl_setopt($this->_getResource(), CURLOPT_FOLLOWLOCATION, false);
|
120 |
+
curl_setopt($this->_getResource(), CURLOPT_RETURNTRANSFER, true);
|
121 |
+
curl_setopt($this->_getResource(), CURLOPT_TIMEOUT, 30);
|
122 |
+
curl_setopt($this->_getResource(), CURLOPT_SSLCERT, $pemCert);
|
123 |
+
curl_setopt($this->_getResource(), CURLOPT_SSLCERTTYPE, 'PEM');
|
124 |
+
curl_setopt($this->_getResource(), CURLOPT_SSLCERTPASSWD, $sslpass);
|
125 |
+
curl_setopt($this->_getResource(), CURLOPT_SSL_VERIFYPEER, 1);
|
126 |
+
curl_setopt($this->_getResource(), CURLOPT_SSL_VERIFYHOST, 2);
|
127 |
+
curl_setopt($this->_getResource(), CURLOPT_CAINFO, Mage::getBaseDir() . $this->getConfigValue('path_cert'));
|
128 |
+
|
129 |
+
return $body;
|
130 |
+
}
|
131 |
+
|
132 |
+
/**
|
133 |
+
* Exec curl function and
|
134 |
+
* get the response
|
135 |
+
*
|
136 |
+
* @return resource
|
137 |
+
*/
|
138 |
+
public function read()
|
139 |
+
{
|
140 |
+
$response = curl_exec($this->_getResource());
|
141 |
+
return $response;
|
142 |
+
}
|
143 |
+
|
144 |
+
/**
|
145 |
+
* Get Cash-Ticket API URL
|
146 |
+
*
|
147 |
+
* @return string
|
148 |
+
*/
|
149 |
+
public function getCashTicketUrl()
|
150 |
+
{
|
151 |
+
// if testing server
|
152 |
+
if ($this->isSandbox()) {
|
153 |
+
// return URL for the testing server
|
154 |
+
return $this->getDefaultConfigValue('url_test');
|
155 |
+
}
|
156 |
+
// otherwise return live URL
|
157 |
+
return $this->getDefaultConfigValue('url_live');
|
158 |
+
}
|
159 |
+
|
160 |
+
/**
|
161 |
+
* Get URL to redirect the customer
|
162 |
+
* after finishing the order
|
163 |
+
*
|
164 |
+
* @return string
|
165 |
+
*/
|
166 |
+
public function getCustomerRedirectUrl(array $params)
|
167 |
+
{
|
168 |
+
// if testing
|
169 |
+
if ($this->isSandbox()) {
|
170 |
+
// get test url
|
171 |
+
$url = $this->getDefaultConfigValue('customer_url_test');
|
172 |
+
}
|
173 |
+
else {
|
174 |
+
// get live url
|
175 |
+
$url = $this->getDefaultConfigValue('customer_url_live');
|
176 |
+
}
|
177 |
+
|
178 |
+
$url .= 'GetCustomerPanelServlet?';
|
179 |
+
$urlParams = '';
|
180 |
+
|
181 |
+
// merge set and standard params
|
182 |
+
$params = array_merge(array(
|
183 |
+
'currency' => $this->getConfigValue('currency_code'),
|
184 |
+
'mid' => $this->getConfigValue('merchant_id'),
|
185 |
+
'locale' => $this->getConfigValue('locale'),
|
186 |
+
'mtid' => $this->getTransactionId()
|
187 |
+
), $params);
|
188 |
+
|
189 |
+
// format params for curl call
|
190 |
+
foreach ($params as $key => $value) {
|
191 |
+
$urlParams .= '&' . $key . '=' . urlencode($value);
|
192 |
+
}
|
193 |
+
|
194 |
+
return $url . $urlParams;
|
195 |
+
}
|
196 |
+
|
197 |
+
/**
|
198 |
+
* Set transactionId
|
199 |
+
*
|
200 |
+
* @return void
|
201 |
+
*/
|
202 |
+
public function setTransactionId($id)
|
203 |
+
{
|
204 |
+
$this->_transactionId = $id;
|
205 |
+
}
|
206 |
+
|
207 |
+
/**
|
208 |
+
* Get transactionId
|
209 |
+
*
|
210 |
+
* @return string
|
211 |
+
*/
|
212 |
+
public function getTransactionId()
|
213 |
+
{
|
214 |
+
return $this->_transactionId;
|
215 |
+
}
|
216 |
+
|
217 |
+
/**
|
218 |
+
* Set order
|
219 |
+
*
|
220 |
+
* @return void
|
221 |
+
*/
|
222 |
+
public function setOrder($order)
|
223 |
+
{
|
224 |
+
$this->_order = $order;
|
225 |
+
}
|
226 |
+
|
227 |
+
/**
|
228 |
+
* Get order
|
229 |
+
*
|
230 |
+
* @return object
|
231 |
+
*/
|
232 |
+
public function getOrder()
|
233 |
+
{
|
234 |
+
return $this->_order;
|
235 |
+
}
|
236 |
+
|
237 |
+
/**
|
238 |
+
* Check if woring on
|
239 |
+
* the test server
|
240 |
+
*
|
241 |
+
* @return boolean
|
242 |
+
*/
|
243 |
+
public function isSandbox()
|
244 |
+
{
|
245 |
+
// check if testing flag has been set
|
246 |
+
if (is_null($this->_sandbox)) {
|
247 |
+
// check if testing flag has been set in current
|
248 |
+
// configuration and set the flag for this api instance
|
249 |
+
if ($this->getConfigValue('sandbox')) {
|
250 |
+
$this->_sandbox = true;
|
251 |
+
}
|
252 |
+
else {
|
253 |
+
$this->_sandbox = false;
|
254 |
+
}
|
255 |
+
}
|
256 |
+
if ($this->_sandbox == true) {
|
257 |
+
return true;
|
258 |
+
}
|
259 |
+
return false;
|
260 |
+
}
|
261 |
+
|
262 |
+
/**
|
263 |
+
* Get value from active configuration
|
264 |
+
* for current currency
|
265 |
+
*
|
266 |
+
* @return string
|
267 |
+
*/
|
268 |
+
public function getConfigValue($key)
|
269 |
+
{
|
270 |
+
$config = $this->getItemConfig();
|
271 |
+
|
272 |
+
try {
|
273 |
+
// if not set load from db
|
274 |
+
if (is_null($config)) {
|
275 |
+
// get model
|
276 |
+
$model = Mage::getModel('cashticket/item');
|
277 |
+
// load configuration for current currency
|
278 |
+
$collection = $model->getItemsCollection($this->getCurrency());
|
279 |
+
// if no active configurations found ..
|
280 |
+
if ($collection->getSize() <= 0) {
|
281 |
+
// throw error
|
282 |
+
Mage::throwException(Mage::helper('cashticket')->__('No active configuration for this currency.'));
|
283 |
+
}
|
284 |
+
// if more then 1 active configuration found ..
|
285 |
+
if ($collection->getSize() > 1) {
|
286 |
+
// throw error
|
287 |
+
Mage::throwException(Mage::helper('cashticket')->__('Multiply active configuration for this currency.'));
|
288 |
+
}
|
289 |
+
// set the config with loaded data
|
290 |
+
$this->_config = $model->getConfigItem($this->getCurrency());
|
291 |
+
$value = $this->_config[$key];
|
292 |
+
}
|
293 |
+
// if already set - load from model
|
294 |
+
elseif (is_array($config)) {
|
295 |
+
$value = $config[$key];
|
296 |
+
}
|
297 |
+
else {
|
298 |
+
$value = null;
|
299 |
+
}
|
300 |
+
} catch (Exception $e) {
|
301 |
+
Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
|
302 |
+
return;
|
303 |
+
}
|
304 |
+
|
305 |
+
return $value;
|
306 |
+
}
|
307 |
+
|
308 |
+
/**
|
309 |
+
* Get configuration from XML
|
310 |
+
*
|
311 |
+
* @return string
|
312 |
+
*/
|
313 |
+
public function getDefaultConfigValue($key)
|
314 |
+
{
|
315 |
+
return Mage::getStoreConfig('payment/cashticket/' . $key);
|
316 |
+
}
|
317 |
+
|
318 |
+
/**
|
319 |
+
* Get current currency code
|
320 |
+
*
|
321 |
+
* @return string
|
322 |
+
*/
|
323 |
+
public function getCurrency()
|
324 |
+
{
|
325 |
+
$order = $this->getOrder();
|
326 |
+
// get currency info from current order
|
327 |
+
$currency = $order->getData('order_currency_code');
|
328 |
+
// if no currency set for the order - get currency info from store
|
329 |
+
if (empty($currency)) {
|
330 |
+
$currency = Mage::app()->getStore()->getCurrentCurrencyCode();
|
331 |
+
}
|
332 |
+
|
333 |
+
return $currency;
|
334 |
+
}
|
335 |
+
|
336 |
+
/**
|
337 |
+
* Get config array
|
338 |
+
*
|
339 |
+
* @return array
|
340 |
+
*/
|
341 |
+
public function getItemConfig()
|
342 |
+
{
|
343 |
+
return $this->_config;
|
344 |
+
}
|
345 |
+
|
346 |
+
/**
|
347 |
+
* Format price for Cash-Ticket (format 0.00)
|
348 |
+
*
|
349 |
+
* @return string
|
350 |
+
*/
|
351 |
+
public function formatPrice($amount)
|
352 |
+
{
|
353 |
+
$formatted = number_format($amount, 2, '.', '');
|
354 |
+
$formatted = sprintf('%.2f', $formatted);
|
355 |
+
return $formatted;
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 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_CashTicket extends Mage_Payment_Model_Method_Abstract
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Internal payment code
|
14 |
+
*
|
15 |
+
* @var string
|
16 |
+
*/
|
17 |
+
protected $_code = 'cashticket';
|
18 |
+
|
19 |
+
/**
|
20 |
+
* If gateway
|
21 |
+
*
|
22 |
+
* @var boolean
|
23 |
+
*/
|
24 |
+
protected $_isGateway = true;
|
25 |
+
|
26 |
+
/**
|
27 |
+
* If use authorization
|
28 |
+
*
|
29 |
+
* @var boolean
|
30 |
+
*/
|
31 |
+
protected $_canAuthorize = true;
|
32 |
+
|
33 |
+
/**
|
34 |
+
* If use capturing
|
35 |
+
*
|
36 |
+
* @var boolean
|
37 |
+
*/
|
38 |
+
protected $_canCapture = true;
|
39 |
+
|
40 |
+
/**
|
41 |
+
* If capture partial amounts
|
42 |
+
*
|
43 |
+
* @var boolean
|
44 |
+
*/
|
45 |
+
protected $_canCapturePartial = false;
|
46 |
+
|
47 |
+
/**
|
48 |
+
* If using refund
|
49 |
+
*
|
50 |
+
* @var boolean
|
51 |
+
*/
|
52 |
+
protected $_canRefund = false;
|
53 |
+
|
54 |
+
/**
|
55 |
+
* If can void
|
56 |
+
*
|
57 |
+
* @var boolean
|
58 |
+
*/
|
59 |
+
protected $_canVoid = false;
|
60 |
+
|
61 |
+
/**
|
62 |
+
* If using for internal
|
63 |
+
*
|
64 |
+
* @var boolean
|
65 |
+
*/
|
66 |
+
protected $_canUseInternal = true;
|
67 |
+
|
68 |
+
/**
|
69 |
+
* If using on checkout
|
70 |
+
*
|
71 |
+
* @var boolean
|
72 |
+
*/
|
73 |
+
protected $_canUseCheckout = true;
|
74 |
+
|
75 |
+
/**
|
76 |
+
* If using on multishipping
|
77 |
+
*
|
78 |
+
* @var boolean
|
79 |
+
*/
|
80 |
+
protected $_canUseForMultishipping = true;
|
81 |
+
|
82 |
+
/**
|
83 |
+
* If saving creditcards
|
84 |
+
*
|
85 |
+
* @var boolean
|
86 |
+
*/
|
87 |
+
protected $_canSaveCc = false;
|
88 |
+
|
89 |
+
/**
|
90 |
+
* If validating
|
91 |
+
*
|
92 |
+
* @var boolean
|
93 |
+
*/
|
94 |
+
protected $_canValidate = true;
|
95 |
+
|
96 |
+
/**
|
97 |
+
* Define block for payment form
|
98 |
+
*
|
99 |
+
* @var string
|
100 |
+
*/
|
101 |
+
protected $_formBlockType = 'cashticket/form';
|
102 |
+
|
103 |
+
/**
|
104 |
+
* Define block for payment info
|
105 |
+
*
|
106 |
+
* @var string
|
107 |
+
*/
|
108 |
+
protected $_infoBlockType = 'cashticket/info';
|
109 |
+
|
110 |
+
/**
|
111 |
+
* Id of the transaction for
|
112 |
+
* current API call
|
113 |
+
*
|
114 |
+
* @var string
|
115 |
+
*/
|
116 |
+
protected $_transactionId = '';
|
117 |
+
|
118 |
+
public function _construct()
|
119 |
+
{
|
120 |
+
parent::_construct();
|
121 |
+
$this->_init('cashticket/item');
|
122 |
+
}
|
123 |
+
|
124 |
+
/**
|
125 |
+
* Get API object
|
126 |
+
*
|
127 |
+
* @return object
|
128 |
+
*/
|
129 |
+
public function getApi($transactionId)
|
130 |
+
{
|
131 |
+
$api = Mage::getModel('cashticket/api');
|
132 |
+
$api->setTransactionId($transactionId);
|
133 |
+
$api->setOrder($this->getQuote());
|
134 |
+
|
135 |
+
return $api;
|
136 |
+
}
|
137 |
+
|
138 |
+
/**
|
139 |
+
* Get checkout from session
|
140 |
+
*
|
141 |
+
* @return object
|
142 |
+
*/
|
143 |
+
public function getCheckout()
|
144 |
+
{
|
145 |
+
return Mage::getModel('checkout/session');
|
146 |
+
}
|
147 |
+
|
148 |
+
/**
|
149 |
+
* Get session for Cash-Ticket
|
150 |
+
*
|
151 |
+
* @return object
|
152 |
+
*/
|
153 |
+
public function getSession()
|
154 |
+
{
|
155 |
+
return Mage::getModel('cashticket/session');
|
156 |
+
}
|
157 |
+
|
158 |
+
/**
|
159 |
+
* Get quote
|
160 |
+
*
|
161 |
+
* @return object
|
162 |
+
*/
|
163 |
+
public function getQuote()
|
164 |
+
{
|
165 |
+
return $this->getCheckout()->getQuote();
|
166 |
+
}
|
167 |
+
|
168 |
+
/**
|
169 |
+
* Check if payment method is available
|
170 |
+
*
|
171 |
+
* @return bool
|
172 |
+
*/
|
173 |
+
public function isAvailable($quote = null)
|
174 |
+
{
|
175 |
+
// if quote is not set - something went wrong
|
176 |
+
if (is_null($quote)) {
|
177 |
+
return false;
|
178 |
+
}
|
179 |
+
|
180 |
+
// if cart value > 1000 - cancel
|
181 |
+
// cash-ticket does not support orders
|
182 |
+
// with value > 1000 at this time
|
183 |
+
if (Mage::app()->getStore()->roundPrice($quote->getGrandTotal()) <= 1000) {
|
184 |
+
return true;
|
185 |
+
}
|
186 |
+
|
187 |
+
return false;
|
188 |
+
}
|
189 |
+
|
190 |
+
/**
|
191 |
+
* Create disposition on Cash-Ticket
|
192 |
+
*
|
193 |
+
* @return object
|
194 |
+
*/
|
195 |
+
public function authorize(Varien_Object $payment, $amount)
|
196 |
+
{
|
197 |
+
// generate random transaction number (number from 100 to 999 + orderid)
|
198 |
+
$transactionId = rand(100, 999) . $payment->getOrder()->increment_id;
|
199 |
+
$api = $this->getApi($transactionId);
|
200 |
+
|
201 |
+
// override the amount to get the really order amount
|
202 |
+
// needed for currency operations
|
203 |
+
$amount = $api->formatPrice($this->getQuote()->getGrandTotal());
|
204 |
+
|
205 |
+
$params = array(
|
206 |
+
'amount' => $amount
|
207 |
+
);
|
208 |
+
|
209 |
+
// save transactionid in payment data
|
210 |
+
$payment->setAdditionalData($transactionId);
|
211 |
+
|
212 |
+
// get response from api
|
213 |
+
$response = $api->call('CreateDisposition', $params);
|
214 |
+
|
215 |
+
// if response could be parsed and no error happened
|
216 |
+
if (is_object($response) && $response->errCode == '0')
|
217 |
+
{
|
218 |
+
return $this;
|
219 |
+
}
|
220 |
+
else {
|
221 |
+
// TODO: Translate
|
222 |
+
Mage::throwException(Mage::helper('cashticket')->__('Bei der Bezahlung ist ein Fehler aufgetreten. Vermutlich ist dies ein temporärer Fehler und die Bezahlung kann durch Neu-Laden der Seite abgeschlossen werden. Falls dieses Problem weiterhin besteht, kontaktieren Sie bitte unseren Support.'));
|
223 |
+
}
|
224 |
+
|
225 |
+
return $this;
|
226 |
+
}
|
227 |
+
|
228 |
+
/**
|
229 |
+
* Get redirect URL
|
230 |
+
*
|
231 |
+
* @return string
|
232 |
+
*/
|
233 |
+
public function getOrderPlaceRedirectUrl()
|
234 |
+
{
|
235 |
+
return Mage::getUrl('cashticket/processing/redirect');
|
236 |
+
}
|
237 |
+
}
|
app/code/community/Symmetrics/CashTicket/Model/Item.php
ADDED
@@ -0,0 +1,44 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_Item extends Mage_Core_Model_Abstract
|
11 |
+
{
|
12 |
+
public function _construct()
|
13 |
+
{
|
14 |
+
parent::_construct();
|
15 |
+
$this->_init('cashticket/item');
|
16 |
+
}
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Get config item object
|
20 |
+
* and load by currency
|
21 |
+
*
|
22 |
+
* @return string
|
23 |
+
*/
|
24 |
+
public function getConfigItem($currency)
|
25 |
+
{
|
26 |
+
$ids = $this->getItemsCollection($currency)->getAllIds();
|
27 |
+
return $this->load($ids[0])->toArray();
|
28 |
+
}
|
29 |
+
|
30 |
+
/**
|
31 |
+
* Get all enabled config items
|
32 |
+
* for current currency
|
33 |
+
*
|
34 |
+
* @return string
|
35 |
+
*/
|
36 |
+
public function getItemsCollection($currency)
|
37 |
+
{
|
38 |
+
$collection = $this->getCollection()
|
39 |
+
->addFieldToFilter('currency_code', $currency)
|
40 |
+
->addFieldToFilter('enable', 1);
|
41 |
+
|
42 |
+
return $collection;
|
43 |
+
}
|
44 |
+
}
|
app/code/community/Symmetrics/CashTicket/Model/Mysql4/Item.php
ADDED
@@ -0,0 +1,16 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_Mysql4_Item extends Mage_Core_Model_Mysql4_Abstract
|
11 |
+
{
|
12 |
+
public function _construct()
|
13 |
+
{
|
14 |
+
$this->_init('cashticket/item', 'item_id');
|
15 |
+
}
|
16 |
+
}
|
app/code/community/Symmetrics/CashTicket/Model/Mysql4/Item/Collection.php
ADDED
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_Mysql4_Item_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
|
11 |
+
{
|
12 |
+
public function _construct()
|
13 |
+
{
|
14 |
+
parent::_construct();
|
15 |
+
$this->_init('cashticket/item');
|
16 |
+
}
|
17 |
+
}
|
app/code/community/Symmetrics/CashTicket/Model/Source/Businesstype.php
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_Source_BusinessType
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Get possible business types
|
14 |
+
*
|
15 |
+
* @return array
|
16 |
+
*/
|
17 |
+
public function getOptionArray()
|
18 |
+
{
|
19 |
+
return array(
|
20 |
+
'T' => Mage::helper('cashticket')->__('Tangible'),
|
21 |
+
'I' => Mage::helper('cashticket')->__('Intangible')
|
22 |
+
);
|
23 |
+
}
|
24 |
+
}
|
app/code/community/Symmetrics/CashTicket/Model/Source/Currency.php
ADDED
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_Source_Currency
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Get possible currencies
|
14 |
+
*
|
15 |
+
* @return array
|
16 |
+
*/
|
17 |
+
public function getOptionArray()
|
18 |
+
{
|
19 |
+
return array(
|
20 |
+
'CHF' => 'CHF',
|
21 |
+
'DKK' => 'DKK',
|
22 |
+
'SEK' => 'SEK',
|
23 |
+
'SEK' => 'SEK',
|
24 |
+
'PLN' => 'PLN',
|
25 |
+
'GBP' => 'GBP',
|
26 |
+
'EUR' => 'EUR',
|
27 |
+
'USD' => 'USD',
|
28 |
+
'CZK' => 'CZK'
|
29 |
+
);
|
30 |
+
}
|
31 |
+
}
|
app/code/community/Symmetrics/CashTicket/Model/Source/Locale.php
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Model_Source_Locale
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Get locales
|
14 |
+
*
|
15 |
+
* @return array
|
16 |
+
*/
|
17 |
+
public function getOptionArray()
|
18 |
+
{
|
19 |
+
return array(
|
20 |
+
'de_de' => Mage::helper('cashticket')->__('German Germany'),
|
21 |
+
'de_at' => Mage::helper('cashticket')->__('German Austria'),
|
22 |
+
'en_uk' => Mage::helper('cashticket')->__('British English'),
|
23 |
+
'en_us' => Mage::helper('cashticket')->__('American English')
|
24 |
+
);
|
25 |
+
}
|
26 |
+
}
|
app/code/community/Symmetrics/CashTicket/controllers/Adminhtml/CashticketController.php
ADDED
@@ -0,0 +1,121 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Adminhtml_CashticketController extends Mage_Adminhtml_Controller_Action
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Default action called by pressing
|
14 |
+
* the "send" button in order info
|
15 |
+
* performed by AJAX
|
16 |
+
*
|
17 |
+
* @return object
|
18 |
+
*/
|
19 |
+
public function defaultAction()
|
20 |
+
{
|
21 |
+
$postParams = $this->getRequest()->getParams();
|
22 |
+
// get action variable from post
|
23 |
+
$action = $postParams['cashticketAction'];
|
24 |
+
// get order by id
|
25 |
+
$order = $this->getOrder($postParams['orderId']);
|
26 |
+
// get api and set the transaction id
|
27 |
+
$api = $this->getApi($postParams['transactionId']);
|
28 |
+
// get entered amount
|
29 |
+
$amount = $api->formatPrice($postParams['amount']);
|
30 |
+
|
31 |
+
// if entered amount is less then zero by modifying transaction
|
32 |
+
if ($amount <= 0 && $action == 'modify') {
|
33 |
+
// return error message
|
34 |
+
Mage::getSingleton('adminhtml/session')->addError(Mage::helper('cashticket')->__('Debit amount must be greater then zero.'));
|
35 |
+
return $this;
|
36 |
+
}
|
37 |
+
|
38 |
+
// switch between two functions (debit and modify) selected from order info box
|
39 |
+
if ($action == 'debit') {
|
40 |
+
// get disposition state from Cash-Ticket
|
41 |
+
$response = $api->call('GetDispositionState', array());
|
42 |
+
// if allow to debit
|
43 |
+
if (is_object($response) && $response->errCode == '0' && $response->Amount > 0 && $response->TransactionState == 'D') {
|
44 |
+
$params = array(
|
45 |
+
'amount' => $amount,
|
46 |
+
'close' => '0',
|
47 |
+
);
|
48 |
+
// call Cash-Ticket debit function with entered amount
|
49 |
+
$debitResponse = $api->call('Debit', $params);
|
50 |
+
if ($debitResponse->errCode == '0') {
|
51 |
+
// if everything was ok - save the new status and add info to order history
|
52 |
+
$order->addStatusToHistory(Mage_Sales_Model_Order::STATE_PROCESSING, sprintf(Mage::helper('cashticket')->__('Amount %s %s was successfully captured from customers Cash-Tickets.'), $amount, $api->getCurrency()));
|
53 |
+
$order->save();
|
54 |
+
|
55 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('cashticket')->__(sprintf(Mage::helper('cashticket')->__('Amount of %s %s was successfully debited.'), $amount, $api->getCurrency())));
|
56 |
+
return $this;
|
57 |
+
}
|
58 |
+
else {
|
59 |
+
$errorMessage = preg_replace('/&/', '', $debitResponse->errMessage);
|
60 |
+
$errorMessage = preg_replace('/;/', '', $errorMessage);
|
61 |
+
Mage::getSingleton('adminhtml/session')->addError($errorMessage);
|
62 |
+
return $this;
|
63 |
+
}
|
64 |
+
}
|
65 |
+
else {
|
66 |
+
// if can not process debit
|
67 |
+
Mage::getSingleton('adminhtml/session')->addError(Mage::helper('cashticket')->__('Error processing the Cash-Ticket request.'));
|
68 |
+
return $this;
|
69 |
+
}
|
70 |
+
}
|
71 |
+
elseif ($action == 'modify') {
|
72 |
+
// call Cash-Ticket modify function and modify the transaction amount
|
73 |
+
$response = $api->call('ModifyDisposition', array('amount' => $amount));
|
74 |
+
|
75 |
+
if (is_object($response) && $response->errCode == '0') {
|
76 |
+
// if everything was ok - save the new status and add info to order history
|
77 |
+
$order->addStatusToHistory(Mage_Sales_Model_Order::STATE_PROCESSING, sprintf('Disposition modified. New value: %s %s', $amount, $api->getCurrency()));
|
78 |
+
$order->save();
|
79 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('cashticket')->__(sprintf('Disposition was successfully modified (%s %s).', $amount, $api->getCurrency())));
|
80 |
+
return $this;
|
81 |
+
}
|
82 |
+
else {
|
83 |
+
Mage::getSingleton('adminhtml/session')->addError(Mage::helper('cashticket')->__('Error processing the Cash-Ticket request.'));
|
84 |
+
return $this;
|
85 |
+
}
|
86 |
+
}
|
87 |
+
|
88 |
+
return $this;
|
89 |
+
}
|
90 |
+
|
91 |
+
/**
|
92 |
+
* Get order object and load
|
93 |
+
* order by id
|
94 |
+
*
|
95 |
+
* @return object
|
96 |
+
*/
|
97 |
+
public function getOrder($orderId = null)
|
98 |
+
{
|
99 |
+
$order = Mage::getModel('sales/order');
|
100 |
+
$order->load($orderId);
|
101 |
+
|
102 |
+
return $order;
|
103 |
+
}
|
104 |
+
|
105 |
+
/**
|
106 |
+
* Get API object and set
|
107 |
+
* the transaction
|
108 |
+
*
|
109 |
+
* @return object
|
110 |
+
*/
|
111 |
+
public function getApi($transactionId = null)
|
112 |
+
{
|
113 |
+
$postParams = $this->getRequest()->getParams();
|
114 |
+
$cashTicketModel = Mage::getModel('cashticket/cashticket');
|
115 |
+
$api = $cashTicketModel->getApi($transactionId);
|
116 |
+
$api->setTransactionId($transactionId);
|
117 |
+
$api->setOrder($this->getOrder($postParams['orderId']));
|
118 |
+
|
119 |
+
return $api;
|
120 |
+
}
|
121 |
+
}
|
app/code/community/Symmetrics/CashTicket/controllers/Adminhtml/ConfigController.php
ADDED
@@ -0,0 +1,173 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_Adminhtml_ConfigController extends Mage_Adminhtml_Controller_Action
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Initialize the controller
|
14 |
+
*
|
15 |
+
* @return object
|
16 |
+
*/
|
17 |
+
protected function _initAction()
|
18 |
+
{
|
19 |
+
$this->loadLayout()
|
20 |
+
->_setActiveMenu('cashticket/items')
|
21 |
+
->_addBreadcrumb(Mage::helper('adminhtml')->__('Items Manager'), Mage::helper('adminhtml')->__('Item Manager'));
|
22 |
+
|
23 |
+
return $this;
|
24 |
+
}
|
25 |
+
|
26 |
+
/**
|
27 |
+
* Default action
|
28 |
+
*
|
29 |
+
* @return void
|
30 |
+
*/
|
31 |
+
public function indexAction()
|
32 |
+
{
|
33 |
+
$this->_initAction()->renderLayout();
|
34 |
+
}
|
35 |
+
|
36 |
+
/**
|
37 |
+
* Redirect to edit action
|
38 |
+
*
|
39 |
+
* @return void
|
40 |
+
*/
|
41 |
+
public function newAction()
|
42 |
+
{
|
43 |
+
$this->_forward('edit');
|
44 |
+
}
|
45 |
+
|
46 |
+
/**
|
47 |
+
* Edit form action
|
48 |
+
*
|
49 |
+
* @return string
|
50 |
+
*/
|
51 |
+
public function editAction()
|
52 |
+
{
|
53 |
+
$id = $this->getRequest()->getParam('id');
|
54 |
+
// load the item model by id
|
55 |
+
$model = Mage::getModel('cashticket/item')->load($id);
|
56 |
+
// if id was found
|
57 |
+
if ($model->getId() || $id == 0) {
|
58 |
+
$data = Mage::getSingleton('adminhtml/session')->getFormData(true);
|
59 |
+
|
60 |
+
if (!empty($data)) {
|
61 |
+
$model->setData($data);
|
62 |
+
}
|
63 |
+
|
64 |
+
// set the model to register for later use
|
65 |
+
Mage::register('cashticket_data', $model);
|
66 |
+
|
67 |
+
$this->loadLayout();
|
68 |
+
$this->_setActiveMenu('cashticket/items');
|
69 |
+
|
70 |
+
$this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item Manager'), Mage::helper('adminhtml')->__('Item Manager'));
|
71 |
+
$this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item News'), Mage::helper('adminhtml')->__('Item News'));
|
72 |
+
|
73 |
+
$this->getLayout()->getBlock('head')->setCanLoadExtJs(true);
|
74 |
+
|
75 |
+
$this->_addContent($this->getLayout()->createBlock('cashticket/adminhtml_config_edit'));
|
76 |
+
|
77 |
+
$this->renderLayout();
|
78 |
+
}
|
79 |
+
else {
|
80 |
+
// otherwise show error
|
81 |
+
Mage::getSingleton('adminhtml/session')->addError(Mage::helper('cashticket')->__('Item does not exist'));
|
82 |
+
$this->_redirect('*/*/');
|
83 |
+
}
|
84 |
+
}
|
85 |
+
|
86 |
+
/**
|
87 |
+
* Save form action
|
88 |
+
*
|
89 |
+
* @return
|
90 |
+
*/
|
91 |
+
public function saveAction()
|
92 |
+
{
|
93 |
+
// if have data in post
|
94 |
+
if ($data = $this->getRequest()->getPost()) {
|
95 |
+
// load the config item model and set the id
|
96 |
+
$model = Mage::getModel('cashticket/item');
|
97 |
+
$model->setData($data)->setId($this->getRequest()->getParam('item_id'));
|
98 |
+
|
99 |
+
try {
|
100 |
+
// get all enabled configs for the currency
|
101 |
+
$collection = Mage::getModel('cashticket/item')->getCollection()
|
102 |
+
->addFilter('currency_code', $model->getCurrencyCode())
|
103 |
+
->addFilter('enable', 1);
|
104 |
+
|
105 |
+
$size = $collection->getSize();
|
106 |
+
$ids = $collection->getAllIds();
|
107 |
+
|
108 |
+
// if there are already saved active config items
|
109 |
+
if ($size > 0 && $ids[0] != $model->getItemId()) {
|
110 |
+
// throw error
|
111 |
+
Mage::throwException(Mage::helper('cashticket')->__(sprintf('You have already an active configuration for currency %s.', $model->getCurrencyCode())));
|
112 |
+
}
|
113 |
+
|
114 |
+
// set update and creation time to now if saving the new item
|
115 |
+
if ($model->getCreatedTime == NULL || $model->getUpdateTime() == NULL) {
|
116 |
+
$model->setCreatedTime(now())->setUpdateTime(now());
|
117 |
+
}
|
118 |
+
else {
|
119 |
+
$model->setUpdateTime(now());
|
120 |
+
}
|
121 |
+
|
122 |
+
$model->save();
|
123 |
+
|
124 |
+
// add success message
|
125 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('cashticket')->__(sprintf('Configuration for %s was successfully saved', $model->getData('currency_code'))));
|
126 |
+
Mage::getSingleton('adminhtml/session')->setFormData(false);
|
127 |
+
|
128 |
+
// if save and continue
|
129 |
+
if ($this->getRequest()->getParam('back')) {
|
130 |
+
// redirect to the edit form with the same id
|
131 |
+
$this->_redirect('*/*/edit', array('id' => $model->getId()));
|
132 |
+
return;
|
133 |
+
}
|
134 |
+
|
135 |
+
$this->_redirect('*/*/');
|
136 |
+
return;
|
137 |
+
|
138 |
+
} catch (Exception $e) {
|
139 |
+
Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
|
140 |
+
Mage::getSingleton('adminhtml/session')->setFormData($data);
|
141 |
+
$this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('item_id')));
|
142 |
+
return;
|
143 |
+
}
|
144 |
+
}
|
145 |
+
Mage::getSingleton('adminhtml/session')->addError(Mage::helper('cashticket')->__('Unable to find item to save'));
|
146 |
+
$this->_redirect('*/*/');
|
147 |
+
}
|
148 |
+
|
149 |
+
/**
|
150 |
+
* Delete action
|
151 |
+
*
|
152 |
+
* @return
|
153 |
+
*/
|
154 |
+
public function deleteAction()
|
155 |
+
{
|
156 |
+
// if id is set
|
157 |
+
if ($this->getRequest()->getParam('id') > 0) {
|
158 |
+
try {
|
159 |
+
// delete config item
|
160 |
+
$model = Mage::getModel('cashticket/item');
|
161 |
+
$model->setId($this->getRequest()->getParam('id'))
|
162 |
+
->delete();
|
163 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Item was successfully deleted'));
|
164 |
+
$this->_redirect('*/*/');
|
165 |
+
} catch (Exception $e) {
|
166 |
+
Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
|
167 |
+
$this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
|
168 |
+
}
|
169 |
+
}
|
170 |
+
// redirect to back to grid
|
171 |
+
$this->_redirect('*/*/');
|
172 |
+
}
|
173 |
+
}
|
app/code/community/Symmetrics/CashTicket/controllers/ProcessingController.php
ADDED
@@ -0,0 +1,200 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
class Symmetrics_CashTicket_ProcessingController extends Mage_Core_Controller_Front_Action
|
11 |
+
{
|
12 |
+
/**
|
13 |
+
* Standard expire ajax function
|
14 |
+
*
|
15 |
+
* @return void
|
16 |
+
*/
|
17 |
+
protected function _expireAjax()
|
18 |
+
{
|
19 |
+
if (!Mage::getSingleton('checkout/session')->getQuote()->hasItems()) {
|
20 |
+
$this->getResponse()->setHeader('HTTP/1.1', '403 Session Expired');
|
21 |
+
exit;
|
22 |
+
}
|
23 |
+
}
|
24 |
+
|
25 |
+
/**
|
26 |
+
* Get the checkout object
|
27 |
+
*
|
28 |
+
* @return object
|
29 |
+
*/
|
30 |
+
public function getCheckout()
|
31 |
+
{
|
32 |
+
return Mage::getSingleton('checkout/session');
|
33 |
+
}
|
34 |
+
|
35 |
+
/**
|
36 |
+
* Get the API object and
|
37 |
+
* set transaction
|
38 |
+
*
|
39 |
+
* @return object
|
40 |
+
*/
|
41 |
+
public function getApi($transactionId = null)
|
42 |
+
{
|
43 |
+
$cashTicketModel = Mage::getModel('cashticket/cashticket');
|
44 |
+
$api = $cashTicketModel->getApi($transactionId);
|
45 |
+
$api->setTransactionId($transactionId);
|
46 |
+
|
47 |
+
return $api;
|
48 |
+
}
|
49 |
+
|
50 |
+
/**
|
51 |
+
* Get the order object and
|
52 |
+
* load by id
|
53 |
+
*
|
54 |
+
* @return object
|
55 |
+
*/
|
56 |
+
public function getOrder($orderId = null)
|
57 |
+
{
|
58 |
+
$order = Mage::getModel('sales/order');
|
59 |
+
$order->loadByIncrementId($orderId);
|
60 |
+
|
61 |
+
return $order;
|
62 |
+
}
|
63 |
+
|
64 |
+
/**
|
65 |
+
* Action called when customer finishes
|
66 |
+
* the checkout process
|
67 |
+
*
|
68 |
+
* @return object
|
69 |
+
*/
|
70 |
+
public function redirectAction()
|
71 |
+
{
|
72 |
+
$checkout = $this->getCheckout();
|
73 |
+
$order = $this->getOrder($checkout->getLastRealOrderId());
|
74 |
+
$payment = $order->getPayment();
|
75 |
+
$api = $this->getApi($payment->getAdditionalData());
|
76 |
+
|
77 |
+
// get order total price and format it for the Cash-Ticket API
|
78 |
+
$params = array(
|
79 |
+
'amount' => $api->formatPrice(Mage::app()->getStore()->roundPrice($order->getGrandTotal()))
|
80 |
+
);
|
81 |
+
|
82 |
+
// set new order status and save info for order history
|
83 |
+
$order->addStatusToHistory(
|
84 |
+
$order->getStatus(),
|
85 |
+
sprintf(Mage::helper('cashticket')->__('Customer was redirected to Cash-Ticket. Transaction ID: %s', $payment->getAdditionalData())));
|
86 |
+
|
87 |
+
$order->save();
|
88 |
+
|
89 |
+
// unset the quoteId
|
90 |
+
$checkout->unsQuoteId();
|
91 |
+
|
92 |
+
// redirect customer to the Cash-Ticket page
|
93 |
+
$this->getResponse()->setRedirect($api->getCustomerRedirectUrl($params));
|
94 |
+
|
95 |
+
return $this;
|
96 |
+
}
|
97 |
+
|
98 |
+
/**
|
99 |
+
* Action called when customer
|
100 |
+
* returns from the Cash-Ticket page
|
101 |
+
*
|
102 |
+
* @return object
|
103 |
+
*/
|
104 |
+
public function successAction()
|
105 |
+
{
|
106 |
+
$checkout = $this->getCheckout();
|
107 |
+
$order = $this->getOrder($checkout->getLastRealOrderId());
|
108 |
+
$payment = $order->getPayment();
|
109 |
+
$api = $this->getApi($payment->getAdditionalData());
|
110 |
+
|
111 |
+
// get disposition state
|
112 |
+
$response = $api->call('GetSerialNumbers', array());
|
113 |
+
|
114 |
+
if (is_object($response) && $response->errCode == '0') {
|
115 |
+
// s = cash tickets successfully assigned to disposition
|
116 |
+
if ($response->TransactionState == 'S') {
|
117 |
+
$amount = Mage::app()->getStore()->roundPrice($order->getGrandTotal());
|
118 |
+
// if intangible
|
119 |
+
if ($api->getConfigValue('business_type') == 'I') {
|
120 |
+
// further debits not possible
|
121 |
+
// close transaction and debit the full amount
|
122 |
+
$cashTicketAmount = $amount;
|
123 |
+
$closeFlag = '1';
|
124 |
+
}
|
125 |
+
// if tangible
|
126 |
+
else {
|
127 |
+
// further debits are possible
|
128 |
+
// enable manual debiting
|
129 |
+
$cashTicketAmount = '0.00';
|
130 |
+
$closeFlag = '0';
|
131 |
+
}
|
132 |
+
|
133 |
+
$params = array(
|
134 |
+
'amount' => $api->formatPrice($cashTicketAmount),
|
135 |
+
'close' => $closeFlag,
|
136 |
+
);
|
137 |
+
|
138 |
+
// call the debit function on Cash-Ticket
|
139 |
+
$response = $api->call('Debit', $params);
|
140 |
+
|
141 |
+
if (is_object($response) && $response->errCode == '0') {
|
142 |
+
if ($api->getConfigValue('business_type') == 'I') {
|
143 |
+
$statusMessage = Mage::helper('cashticket')->__(sprintf('Transaction successful. %s %s debited', $cashTicketAmount, $api->getCurrency()));
|
144 |
+
}
|
145 |
+
else {
|
146 |
+
$statusMessage = Mage::helper('cashticket')->__(sprintf('Cash-Ticket cards were successfully assigned to disposition. The amount of %s %s can be debited.', $amount, $api->getCurrency()));
|
147 |
+
}
|
148 |
+
|
149 |
+
// set the new order status and save comment
|
150 |
+
$newOrderStatus = $api->getDefaultConfigValue('order_status', $order->getStoreId());
|
151 |
+
if (empty($newOrderStatus)) {
|
152 |
+
$newOrderStatus = Mage_Sales_Model_Order::STATE_PROCESSING;
|
153 |
+
}
|
154 |
+
|
155 |
+
$order->addStatusToHistory($newOrderStatus, $statusMessage);
|
156 |
+
$order->save();
|
157 |
+
|
158 |
+
$checkout->getQuote()->setIsActive(false)->save();
|
159 |
+
|
160 |
+
// redirect to success page
|
161 |
+
$this->_redirect('checkout/onepage/success', array('_secure'=>true));
|
162 |
+
return $this;
|
163 |
+
}
|
164 |
+
else {
|
165 |
+
// debit was not successful
|
166 |
+
Mage::throwException($response->errMessage);
|
167 |
+
return $this;
|
168 |
+
}
|
169 |
+
}
|
170 |
+
else {
|
171 |
+
// do not process payment because something went wrong on the Cash-Ticket page
|
172 |
+
Mage::throwException(Mage::helper('cashticket')->__('Error processing payment. It could have following reasons: no cards assigned to disposition, disposition already debited, disposition canceled by customer or expired by Cash-Ticket.'));
|
173 |
+
return $this;
|
174 |
+
}
|
175 |
+
}
|
176 |
+
else {
|
177 |
+
Mage::throwException($response->errMessage);
|
178 |
+
return $this;
|
179 |
+
}
|
180 |
+
}
|
181 |
+
|
182 |
+
/**
|
183 |
+
* Action called when customer hits
|
184 |
+
* cancel button on the Cash-Ticket
|
185 |
+
* page
|
186 |
+
*
|
187 |
+
* @return string
|
188 |
+
*/
|
189 |
+
public function errorAction()
|
190 |
+
{
|
191 |
+
// show error block
|
192 |
+
$this->getResponse()->setBody(
|
193 |
+
$this->getLayout()
|
194 |
+
->createBlock('cashticket/error')
|
195 |
+
->toHtml()
|
196 |
+
);
|
197 |
+
|
198 |
+
return $this;
|
199 |
+
}
|
200 |
+
}
|
app/code/community/Symmetrics/CashTicket/etc/config.xml
ADDED
@@ -0,0 +1,146 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* @category Symmetrics
|
5 |
+
* @package Symmetrics_CashTicket
|
6 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
7 |
+
* @copyright symmetrics gmbh
|
8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
9 |
+
*/
|
10 |
+
-->
|
11 |
+
<config>
|
12 |
+
<modules>
|
13 |
+
<Symmetrics_CashTicket>
|
14 |
+
<version>0.1.4</version>
|
15 |
+
<depends>
|
16 |
+
<Mage_Payment />
|
17 |
+
</depends>
|
18 |
+
</Symmetrics_CashTicket>
|
19 |
+
</modules>
|
20 |
+
<global>
|
21 |
+
<models>
|
22 |
+
<cashticket>
|
23 |
+
<class>Symmetrics_CashTicket_Model</class>
|
24 |
+
<resourceModel>cashticket_mysql4</resourceModel>
|
25 |
+
</cashticket>
|
26 |
+
<cashticket_mysql4>
|
27 |
+
<class>Symmetrics_CashTicket_Model_Mysql4</class>
|
28 |
+
<entities>
|
29 |
+
<item>
|
30 |
+
<table>symmetrics_cashticket</table>
|
31 |
+
</item>
|
32 |
+
</entities>
|
33 |
+
</cashticket_mysql4>
|
34 |
+
</models>
|
35 |
+
<blocks>
|
36 |
+
<cashticket>
|
37 |
+
<class>Symmetrics_CashTicket_Block</class>
|
38 |
+
</cashticket>
|
39 |
+
</blocks>
|
40 |
+
<helpers>
|
41 |
+
<cashticket>
|
42 |
+
<class>Symmetrics_CashTicket_Helper</class>
|
43 |
+
</cashticket>
|
44 |
+
</helpers>
|
45 |
+
<resources>
|
46 |
+
<cashticket_setup>
|
47 |
+
<setup>
|
48 |
+
<module>Symmetrics_CashTicket</module>
|
49 |
+
</setup>
|
50 |
+
<connection>
|
51 |
+
<use>core_setup</use>
|
52 |
+
</connection>
|
53 |
+
</cashticket_setup>
|
54 |
+
<cashticket_write>
|
55 |
+
<connection>
|
56 |
+
<use>core_write</use>
|
57 |
+
</connection>
|
58 |
+
</cashticket_write>
|
59 |
+
<cashticket_read>
|
60 |
+
<connection>
|
61 |
+
<use>core_read</use>
|
62 |
+
</connection>
|
63 |
+
</cashticket_read>
|
64 |
+
</resources>
|
65 |
+
</global>
|
66 |
+
<admin>
|
67 |
+
<routers>
|
68 |
+
<cashticket>
|
69 |
+
<use>admin</use>
|
70 |
+
<args>
|
71 |
+
<module>Symmetrics_CashTicket</module>
|
72 |
+
<frontName>cashticket</frontName>
|
73 |
+
</args>
|
74 |
+
</cashticket>
|
75 |
+
</routers>
|
76 |
+
</admin>
|
77 |
+
<frontend>
|
78 |
+
<routers>
|
79 |
+
<cashticket>
|
80 |
+
<use>standard</use>
|
81 |
+
<args>
|
82 |
+
<module>Symmetrics_Cashticket</module>
|
83 |
+
<frontName>cashticket</frontName>
|
84 |
+
</args>
|
85 |
+
</cashticket>
|
86 |
+
</routers>
|
87 |
+
</frontend>
|
88 |
+
<adminhtml>
|
89 |
+
<layout>
|
90 |
+
<updates>
|
91 |
+
<cashticket>
|
92 |
+
<file>cashticket.xml</file>
|
93 |
+
</cashticket>
|
94 |
+
</updates>
|
95 |
+
</layout>
|
96 |
+
<acl>
|
97 |
+
<resources>
|
98 |
+
<all>
|
99 |
+
<title>Allow Everything</title>
|
100 |
+
</all>
|
101 |
+
<admin>
|
102 |
+
<children>
|
103 |
+
<Symmetrics_CashTicket>
|
104 |
+
<title>Cash-Ticket</title>
|
105 |
+
<sort_order>10</sort_order>
|
106 |
+
<action>cashticket/adminhtml_config</action>
|
107 |
+
</Symmetrics_CashTicket>
|
108 |
+
</children>
|
109 |
+
</admin>
|
110 |
+
</resources>
|
111 |
+
</acl>
|
112 |
+
<menu>
|
113 |
+
<sales>
|
114 |
+
<children>
|
115 |
+
<cashticket translate="title" module="cashticket">
|
116 |
+
<title>Cash-Ticket</title>
|
117 |
+
<sort_order>20</sort_order>
|
118 |
+
<action>cashticket/adminhtml_config</action>
|
119 |
+
</cashticket>
|
120 |
+
</children>
|
121 |
+
</sales>
|
122 |
+
</menu>
|
123 |
+
</adminhtml>
|
124 |
+
<default>
|
125 |
+
<payment>
|
126 |
+
<cashticket>
|
127 |
+
<active>1</active>
|
128 |
+
<model>cashticket/cashticket</model>
|
129 |
+
<order_status>pending</order_status>
|
130 |
+
<title>Cash-Ticket</title>
|
131 |
+
<payment_action>authorize</payment_action>
|
132 |
+
<allowspecific>0</allowspecific>
|
133 |
+
<merchant_id>0000000000</merchant_id>
|
134 |
+
<business_type>I</business_type>
|
135 |
+
<reporting_criteria>3</reporting_criteria>
|
136 |
+
<locale>en_us</locale>
|
137 |
+
<url_live>https://shops.cc.at.paysafecard.com/pscmerchant/</url_live>
|
138 |
+
<url_test>https://shops.test.at.paysafecard.com/pscmerchant/</url_test>
|
139 |
+
<customer_url_live>https://customer.cc.at.cash-ticket.com/ctcustomer/</customer_url_live>
|
140 |
+
<customer_url_test>https://customer.test.at.cash-ticket.com/ctcustomer/</customer_url_test>
|
141 |
+
<sandbox>1</sandbox>
|
142 |
+
<currencies>CHF,DKK,SEK,PLN,GBP,EUR,USD,CZK</currencies>
|
143 |
+
</cashticket>
|
144 |
+
</payment>
|
145 |
+
</default>
|
146 |
+
</config>
|
app/code/community/Symmetrics/CashTicket/etc/system.xml
ADDED
@@ -0,0 +1,103 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* @category Symmetrics
|
5 |
+
* @package Symmetrics_CashTicket
|
6 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
7 |
+
* @copyright symmetrics gmbh
|
8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
9 |
+
*/
|
10 |
+
-->
|
11 |
+
<config>
|
12 |
+
<sections>
|
13 |
+
<payment>
|
14 |
+
<groups>
|
15 |
+
<cashticket translate="label">
|
16 |
+
<label>Cash-Ticket</label>
|
17 |
+
<sort_order>1</sort_order>
|
18 |
+
<show_in_default>1</show_in_default>
|
19 |
+
<show_in_website>1</show_in_website>
|
20 |
+
<show_in_store>1</show_in_store>
|
21 |
+
<fields>
|
22 |
+
<active translate="label">
|
23 |
+
<label>Enabled</label>
|
24 |
+
<frontend_type>select</frontend_type>
|
25 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
26 |
+
<sort_order>10</sort_order>
|
27 |
+
<show_in_default>1</show_in_default>
|
28 |
+
<show_in_website>1</show_in_website>
|
29 |
+
<show_in_store>1</show_in_store>
|
30 |
+
</active>
|
31 |
+
<url_test translate="label">
|
32 |
+
<label>Cash-Ticket URL (Test)</label>
|
33 |
+
<frontend_type>text</frontend_type>
|
34 |
+
<sort_order>20</sort_order>
|
35 |
+
<show_in_default>1</show_in_default>
|
36 |
+
<show_in_website>1</show_in_website>
|
37 |
+
<show_in_store>1</show_in_store>
|
38 |
+
</url_test>
|
39 |
+
<url_live translate="label">
|
40 |
+
<label>Cash-Ticket URL (Live)</label>
|
41 |
+
<frontend_type>text</frontend_type>
|
42 |
+
<sort_order>30</sort_order>
|
43 |
+
<show_in_default>1</show_in_default>
|
44 |
+
<show_in_website>1</show_in_website>
|
45 |
+
<show_in_store>1</show_in_store>
|
46 |
+
</url_live>
|
47 |
+
<customer_url_test translate="label">
|
48 |
+
<label>Customer URL (Test)</label>
|
49 |
+
<frontend_type>text</frontend_type>
|
50 |
+
<sort_order>40</sort_order>
|
51 |
+
<show_in_default>1</show_in_default>
|
52 |
+
<show_in_website>1</show_in_website>
|
53 |
+
<show_in_store>1</show_in_store>
|
54 |
+
</customer_url_test>
|
55 |
+
<customer_url_live translate="label">
|
56 |
+
<label>Customer URL (Live)</label>
|
57 |
+
<frontend_type>text</frontend_type>
|
58 |
+
<sort_order>50</sort_order>
|
59 |
+
<show_in_default>1</show_in_default>
|
60 |
+
<show_in_website>1</show_in_website>
|
61 |
+
<show_in_store>1</show_in_store>
|
62 |
+
</customer_url_live>
|
63 |
+
<order_status translate="label">
|
64 |
+
<label>New order status</label>
|
65 |
+
<frontend_type>select</frontend_type>
|
66 |
+
<source_model>adminhtml/system_config_source_order_status</source_model>
|
67 |
+
<sort_order>60</sort_order>
|
68 |
+
<show_in_default>1</show_in_default>
|
69 |
+
<show_in_website>1</show_in_website>
|
70 |
+
<show_in_store>0</show_in_store>
|
71 |
+
</order_status>
|
72 |
+
<allowspecific translate="label">
|
73 |
+
<label>Payment from applicable countries</label>
|
74 |
+
<frontend_type>allowspecific</frontend_type>
|
75 |
+
<sort_order>70</sort_order>
|
76 |
+
<source_model>adminhtml/system_config_source_payment_allspecificcountries</source_model>
|
77 |
+
<show_in_default>1</show_in_default>
|
78 |
+
<show_in_website>1</show_in_website>
|
79 |
+
<show_in_store>0</show_in_store>
|
80 |
+
</allowspecific>
|
81 |
+
<specificcountry translate="label">
|
82 |
+
<label>Payment from Specific countries</label>
|
83 |
+
<frontend_type>multiselect</frontend_type>
|
84 |
+
<sort_order>80</sort_order>
|
85 |
+
<source_model>adminhtml/system_config_source_country</source_model>
|
86 |
+
<show_in_default>1</show_in_default>
|
87 |
+
<show_in_website>1</show_in_website>
|
88 |
+
<show_in_store>0</show_in_store>
|
89 |
+
</specificcountry>
|
90 |
+
<sort_order translate="label">
|
91 |
+
<label>Sort order</label>
|
92 |
+
<frontend_type>text</frontend_type>
|
93 |
+
<sort_order>90</sort_order>
|
94 |
+
<show_in_default>1</show_in_default>
|
95 |
+
<show_in_website>1</show_in_website>
|
96 |
+
<show_in_store>1</show_in_store>
|
97 |
+
</sort_order>
|
98 |
+
</fields>
|
99 |
+
</cashticket>
|
100 |
+
</groups>
|
101 |
+
</payment>
|
102 |
+
</sections>
|
103 |
+
</config>
|
app/code/community/Symmetrics/CashTicket/sql/cashticket_setup/mysql4-install-0.1.0.php
ADDED
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
$installer = $this;
|
11 |
+
|
12 |
+
$installer->startSetup();
|
13 |
+
|
14 |
+
// create table for saving cashticket configurations
|
15 |
+
$installer->run("
|
16 |
+
DROP TABLE IF EXISTS {$this->getTable('symmetrics_cashticket')};
|
17 |
+
CREATE TABLE {$this->getTable('symmetrics_cashticket')} (
|
18 |
+
`item_id` int(11) NOT NULL auto_increment,
|
19 |
+
`enable` tinyint NOT NULL,
|
20 |
+
`currency_code` varchar(3) NOT NULL,
|
21 |
+
`merchant_id` varchar(20) NOT NULL,
|
22 |
+
`business_type` varchar(5) NOT NULL,
|
23 |
+
`reporting_criteria` varchar(8) NOT NULL,
|
24 |
+
`locale` varchar(10) NOT NULL,
|
25 |
+
`path_pem_test` varchar(255) NOT NULL,
|
26 |
+
`path_pem_live` varchar(255) NOT NULL,
|
27 |
+
`path_cert` varchar(255) NOT NULL,
|
28 |
+
`sslcert_pass` varchar(255) NOT NULL,
|
29 |
+
`sandbox` enum('1', '0') NOT NULL,
|
30 |
+
`created_time` datetime default NULL,
|
31 |
+
`update_time` datetime default NULL,
|
32 |
+
PRIMARY KEY (`item_id`)
|
33 |
+
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
34 |
+
");
|
35 |
+
|
36 |
+
$installer->endSetup();
|
app/design/adminhtml/default/default/layout/cashticket.xml
ADDED
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* @category Symmetrics
|
5 |
+
* @package Symmetrics_CashTicket
|
6 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
7 |
+
* @copyright symmetrics gmbh
|
8 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
9 |
+
*/
|
10 |
+
-->
|
11 |
+
<layout>
|
12 |
+
<default>
|
13 |
+
<reference name="head">
|
14 |
+
<action method="addJs"><script>symmetrics/adminhtml/cashticket.js</script></action>
|
15 |
+
</reference>
|
16 |
+
</default>
|
17 |
+
<cashticket_adminhtml_config_index>
|
18 |
+
<reference name="content">
|
19 |
+
<block type="cashticket/adminhtml_config" name="cashticket.config" />
|
20 |
+
</reference>
|
21 |
+
</cashticket_adminhtml_config_index>
|
22 |
+
</layout>
|
app/design/adminhtml/default/default/template/cashticket/info.phtml
ADDED
@@ -0,0 +1,55 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
|
10 |
+
// Get current order
|
11 |
+
$_order = $this->getInfo()->getOrder();
|
12 |
+
// Get api instance and set transaction id from current order
|
13 |
+
$_api = $this->getApi($_order->getPayment()->getAdditionalData());
|
14 |
+
// Get a response from api
|
15 |
+
$response = $this->callGetSerialNumbers();
|
16 |
+
// Get amount debited from Cash-Ticket
|
17 |
+
$debitedAmount = (float)$response->Amount;
|
18 |
+
// Get order amount and format it for the API call
|
19 |
+
$orderAmount = (float)number_format($_order->getGrandTotal(), 2, '.', '');
|
20 |
+
// Get all allowed stats of current transaction
|
21 |
+
$allowedStatus = $this->getAllowedStats();
|
22 |
+
?>
|
23 |
+
|
24 |
+
<p><?php echo $this->htmlEscape($this->getMethod()->getTitle()) ?></p>
|
25 |
+
<p><?php echo $this->helper('cashticket')->__('Status - ') ?><strong><?php echo $this->getPaymentStatus() ?></strong></p>
|
26 |
+
<p><?php echo $this->helper('cashticket')->__('Already debited or modified:') ?> <strong><?php echo ($orderAmount - $debitedAmount) ?> <?php echo $_api->getCurrency() ?></strong></p>
|
27 |
+
|
28 |
+
<?php if($debitedAmount > 0 && in_array($response->TransactionState, $allowedStatus)) : ?>
|
29 |
+
<div class="grid">
|
30 |
+
<table cellspacing="0" class="data" id="cashticket_debit_table">
|
31 |
+
<thead>
|
32 |
+
<tr class="headings">
|
33 |
+
<th><?php echo $this->helper('cashticket')->__('Debit / Modify outstanding amount') ?></th>
|
34 |
+
</tr>
|
35 |
+
</thead>
|
36 |
+
<tbody>
|
37 |
+
<tr>
|
38 |
+
<td>
|
39 |
+
<input type="text" id="cashticket_amount" value="<?php echo $debitedAmount ?>" /> <?php echo $_api->getCurrency() ?> <?php echo $this->helper('cashticket')->__('of') ?> <strong><?php echo Mage::app()->getStore()->roundPrice($debitedAmount) ?> <?php echo $_api->getCurrency() ?></strong>
|
40 |
+
<select id="cashticket_action">
|
41 |
+
<option value="debit"><?php echo $this->helper('cashticket')->__('Debit amount') ?></option>
|
42 |
+
<option value="modify"><?php echo $this->helper('cashticket')->__('Modify disposition') ?></option>
|
43 |
+
</select>
|
44 |
+
<button type="button" class="f-right" onclick="symmetrics_cashticket.doCashTicketAction($F('cashticket_action'));" style=""><span><?php echo $this->helper('cashticket')->__('Send') ?></span></button>
|
45 |
+
</td>
|
46 |
+
</tr>
|
47 |
+
</tbody>
|
48 |
+
</table>
|
49 |
+
</div>
|
50 |
+
<input type="hidden" id="cashticket_order_id" value="<?php echo $_order->getId() ?>" />
|
51 |
+
<input type="hidden" id="cashticket_disposition_total" value="<?php echo $debitedAmount ?>" />
|
52 |
+
<input type="hidden" id="cashticket_transaction_id" value="<?php echo $_api->getTransactionId() ?>" />
|
53 |
+
<?php else : ?>
|
54 |
+
<p><em><?php echo $this->__('No Cash-Ticket actions are possible') ?></em></p>
|
55 |
+
<?php endif; ?>
|
app/design/frontend/default/default/template/cashticket/form.phtml
ADDED
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
?>
|
10 |
+
|
11 |
+
<fieldset class="form-list">
|
12 |
+
<?php $_code = $this->getMethodCode() ?>
|
13 |
+
<ul id="payment_form_<?php echo $_code ?>" style="display:none">
|
14 |
+
<li>
|
15 |
+
<p><a href="http://www.cash-ticket.com" target="_blank"><img src="<?php echo $this->getSkinUrl() ?>/images/cashticket/cashticket-logo.png" /></a></p>
|
16 |
+
<p><?php echo $this->__('You will be redirected to Cash-Ticket website when you place an order.') ?></p>
|
17 |
+
</li>
|
18 |
+
</ul>
|
19 |
+
</fieldset>
|
app/design/frontend/default/default/template/cashticket/info.phtml
ADDED
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* @category Symmetrics
|
4 |
+
* @package Symmetrics_CashTicket
|
5 |
+
* @author symmetrics gmbh <info@symmetrics.de>, Eugen Gitin <eg@symmetrics.de>
|
6 |
+
* @copyright symmetrics gmbh
|
7 |
+
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
8 |
+
*/
|
9 |
+
?>
|
10 |
+
|
11 |
+
<p><?php echo $this->getMethod()->getTitle() ?></p>
|
app/etc/modules/Symmetrics_CashTicket.xml
ADDED
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<modules>
|
4 |
+
<Symmetrics_CashTicket>
|
5 |
+
<active>true</active>
|
6 |
+
<codePool>community</codePool>
|
7 |
+
<depends>
|
8 |
+
<Mage_Payment />
|
9 |
+
</depends>
|
10 |
+
</Symmetrics_CashTicket>
|
11 |
+
</modules>
|
12 |
+
</config>
|
js/symmetrics/adminhtml/cashticket.js
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
var SymmetricsCashTicket = Class.create();
|
2 |
+
// Create a new prototype class
|
3 |
+
SymmetricsCashTicket.prototype = {
|
4 |
+
initialize: function(name) {
|
5 |
+
this.name = name;
|
6 |
+
// Get base url from blank_img path
|
7 |
+
this.baseUrl = BLANK_IMG.substr (0, BLANK_IMG.length-13);
|
8 |
+
// Define action url
|
9 |
+
this.actionUrl = 'index.php/cashticket/adminhtml_cashticket/default/';
|
10 |
+
},
|
11 |
+
// Post an ajax request with selected values
|
12 |
+
doCashTicketAction: function(action) {
|
13 |
+
var url = this.baseUrl + this.actionUrl;
|
14 |
+
var postData = {
|
15 |
+
// Value from selectbox - modify or debit
|
16 |
+
'cashticketAction': $F('cashticket_action'),
|
17 |
+
// Amount to be modified or debited
|
18 |
+
'amount': $('cashticket_amount').getValue(),
|
19 |
+
// Current order ID
|
20 |
+
'orderId': $('cashticket_order_id').getValue(),
|
21 |
+
// Current transaction ID
|
22 |
+
'transactionId': $('cashticket_transaction_id').getValue(),
|
23 |
+
// Total disposition value
|
24 |
+
'totalDispo': $('cashticket_disposition_total').getValue()
|
25 |
+
};
|
26 |
+
// Post the request and reload the page on success
|
27 |
+
new Ajax.Request(url, {
|
28 |
+
method: 'post',
|
29 |
+
parameters: postData,
|
30 |
+
onSuccess: function() {
|
31 |
+
window.location.reload()
|
32 |
+
}
|
33 |
+
}
|
34 |
+
);
|
35 |
+
}
|
36 |
+
}
|
37 |
+
|
38 |
+
var symmetrics_cashticket = new SymmetricsCashTicket();
|
package.xml
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<package>
|
3 |
+
<name>symmetrics_cashticket</name>
|
4 |
+
<version>0.1.4</version>
|
5 |
+
<stability>stable</stability>
|
6 |
+
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL 3.0</license>
|
7 |
+
<channel>community</channel>
|
8 |
+
<extends/>
|
9 |
+
<summary>Payment Gateway Cash-Ticket</summary>
|
10 |
+
<description>Payment Gateway for Cash-Ticket</description>
|
11 |
+
<notes>keine</notes>
|
12 |
+
<authors><author><name>Boris Lokschin</name><user>auto-converted</user><email>bl@symmetrics.de</email></author><author><name>Eugen Gitin</name><user>auto-converted</user><email>eg@symmetrics.de</email></author></authors>
|
13 |
+
<date>2009-10-30</date>
|
14 |
+
<time>23:54:36</time>
|
15 |
+
<contents><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="cashticket.xml" hash="517ee82fda047a77bd1aac0eec6fe13c"/></dir><dir name="template"><dir name="cashticket"><file name="info.phtml" hash="168f860600142dc4b730dcd05912ad0a"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="default"><dir name="default"><dir name="template"><dir name="cashticket"><file name="form.phtml" hash="47ee3374f66bf07c1d7939ba53b3bc19"/><file name="info.phtml" hash="339455fe8872a71feec8c707a65072d7"/></dir></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="default"><dir name="default"><dir name="images"><dir name="cashticket"><file name="cashticket-logo.png" hash="1feb49eb4493530107dfd9fd0a19eefe"/></dir></dir></dir></dir></dir></target><target name="mageweb"><dir name="js"><dir name="symmetrics"><dir name="adminhtml"><file name="cashticket.js" hash="1a907ecac3076b1553780efaab46f336"/></dir></dir></dir><dir name="var"><dir name="cashticket"><file name="paysafecard-CA.pem" hash="1cc27c5763294f6c99cdb37f0b8ad528"/></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Symmetrics_CashTicket.xml" hash="ec86cfd342d3c978144735cbf543f056"/></dir></target><target name="magecommunity"><dir name="Symmetrics"><dir name="CashTicket"><dir name="Block"><file name="Error.php" hash="64f7842274232fed92a25848933d09d1"/><file name="Form.php" hash="e4af33eb0afd4e81a7dc329a23f861f9"/><file name="Info.php" hash="30a26959337457765b6c34e80c722fdb"/><dir name="Adminhtml"><file name="Config.php" hash="daa7f93fcc46aaf2fb2b2a4430d67b55"/><dir name="Config"><file name="Edit.php" hash="8a33b119f83816cc8f66db959e12f029"/><file name="Grid.php" hash="c02adcee871db3e97a8373360a5ca57d"/><file name="Renderer.php" hash="db327725ffef45574312cf2170bbd763"/><dir name="Edit"><file name="Form.php" hash="cbbd69a0f1c93c9d00cab9bb3d60021a"/></dir></dir></dir></dir><dir name="controllers"><file name="ProcessingController.php" hash="0a580e59af0baa6b6e6ec9c8a1c23530"/><dir name="Adminhtml"><file name="CashticketController.php" hash="102e6fcfb4fc6c48e423c787bbeff0b4"/><file name="ConfigController.php" hash="707d9649ccbb4f56923f82c57b7da4a1"/></dir></dir><dir name="etc"><file name="config.xml" hash="23f1f021750d515ffd895a491ddf5769"/><file name="system.xml" hash="bde51f891edd77cfae4afe855ce0e976"/></dir><dir name="Helper"><file name="Data.php" hash="22a6518029af102ba0e65182b9f9340b"/></dir><dir name="Model"><file name="Api.php" hash="52ed134166c5335181fe9ba52c27efbb"/><file name="Cashticket.php" hash="e1753d23301568172262ada4a96b65e9"/><file name="Item.php" hash="6fffa0acb8a8f5335ec9ea45500824ed"/><dir name="Mysql4"><file name="Item.php" hash="7d5f7fa5bdb4b7b3e097cc1972a42809"/><dir name="Item"><file name="Collection.php" hash="b6fccb231212da2eaf9ad98c608e099d"/></dir></dir><dir name="Source"><file name="Businesstype.php" hash="5fe80229d3b67b38952fd3c3de35a6ac"/><file name="Currency.php" hash="14f70b66f41ac84ddefa513bade4a24e"/><file name="Locale.php" hash="87ef49c2d7028ee0a0a2e756778894fa"/></dir></dir><dir name="sql"><dir name="cashticket_setup"><file name="mysql4-install-0.1.0.php" hash="305fa391662ceb32e6b2b5630c62cefe"/></dir></dir></dir></dir></target></contents>
|
16 |
+
<compatible/>
|
17 |
+
<dependencies/>
|
18 |
+
</package>
|
skin/frontend/default/default/images/cashticket/cashticket-logo.png
ADDED
Binary file
|
var/cashticket/paysafecard-CA.pem
ADDED
@@ -0,0 +1,227 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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mozFyD4lt5SZu5IycQfwhl7tUCemDaYj+bvLpgcUQg==
|
193 |
+
-----END CERTIFICATE-----
|
194 |
+
-----BEGIN CERTIFICATE-----
|
195 |
+
MIICPDCCAaUCEHC65B0Q2Sk0tjjKewPMur8wDQYJKoZIhvcNAQECBQAwXzELMAkG
|
196 |
+
A1UEBhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTcwNQYDVQQLEy5DbGFz
|
197 |
+
cyAzIFB1YmxpYyBQcmltYXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTk2
|
198 |
+
MDEyOTAwMDAwMFoXDTI4MDgwMTIzNTk1OVowXzELMAkGA1UEBhMCVVMxFzAVBgNV
|
199 |
+
BAoTDlZlcmlTaWduLCBJbmMuMTcwNQYDVQQLEy5DbGFzcyAzIFB1YmxpYyBQcmlt
|
200 |
+
YXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIGfMA0GCSqGSIb3DQEBAQUAA4GN
|
201 |
+
ADCBiQKBgQDJXFme8huKARS0EN8EQNvjV69qRUCPhAwL0TPZ2RHP7gJYHyX3KqhE
|
202 |
+
BarsAx94f56TuZoAqiN91qyFomNFx3InzPRMxnVx0jnvT0Lwdd8KkMaOIG+YD/is
|
203 |
+
I19wKTakyYbnsZogy1Olhec9vn2a/iRFM9x2Fe0PonFkTGUugWhFpwIDAQABMA0G
|
204 |
+
CSqGSIb3DQEBAgUAA4GBALtMEivPLCYATxQT3ab7/AoRhIzzKBxnki98tsX63/Do
|
205 |
+
lbwdj2wsqFHMc9ikwFPwTtYmwHYBV4GSXiHx0bH/59AhWM1pF+NEHJwZRDmJXNyc
|
206 |
+
AA9WjQKZ7aKQRUzkuxCkPfAyAw7xzvjoyVGM5mKf5p/AfbdynMk2OmufTqj/ZA1k
|
207 |
+
-----END CERTIFICATE-----
|
208 |
+
-----BEGIN CERTIFICATE-----
|
209 |
+
MIIDhjCCAu+gAwIBAgIQeO5I3hhbIHHJycO1HXv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