Version Notes
Subscribe Pro Extension Release
Download this release
Release Info
Developer | StoreFront Consulting |
Extension | SFC_Autoship |
Version | 1.3.1.14 |
Comparing to | |
See all releases |
Version 1.3.1.14
- app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Edit.php +63 -0
- app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Edit/Form.php +37 -0
- app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Edit/Tab/Form.php +218 -0
- app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Edit/Tabs.php +39 -0
- app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Paymentprofile.php +282 -0
- app/code/local/SFC/Autoship/Block/Adminhtml/Sales/Order/Create/Jsonp.php +66 -0
- app/code/local/SFC/Autoship/Block/Adminhtml/System/Config/Form/TestConnectionButton.php +75 -0
- app/code/local/SFC/Autoship/Block/Cart/Product/Subscription.php +113 -0
- app/code/local/SFC/Autoship/Block/Checkout/Jsonp.php +54 -0
- app/code/local/SFC/Autoship/Block/Checkout/Onepage/Payment/Methods.php +105 -0
- app/code/local/SFC/Autoship/Block/Mysubscriptions.php +117 -0
- app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription.php +110 -0
- app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription/Form/Billing.php +26 -0
- app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription/Form/Payment.php +26 -0
- app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription/Form/Shipping.php +26 -0
- app/code/local/SFC/Autoship/Block/Newsubscription.php +55 -0
- app/code/local/SFC/Autoship/Block/Newsubscription/Form/Billing.php +36 -0
- app/code/local/SFC/Autoship/Block/Newsubscription/Form/Payment.php +35 -0
- app/code/local/SFC/Autoship/Block/Newsubscription/Form/Shipping.php +35 -0
- app/code/local/SFC/Autoship/Block/Payment/Form/Cc.php +186 -0
- app/code/local/SFC/Autoship/Block/Payment/Form/Cc/Saved.php +56 -0
- app/code/local/SFC/Autoship/Block/Payment/Info/Cc.php +112 -0
- app/code/local/SFC/Autoship/Block/Payment/Profile/Edit.php +201 -0
- app/code/local/SFC/Autoship/Block/Payment/Profile/Grid.php +37 -0
- app/code/local/SFC/Autoship/Block/Product/Subscribe.php +44 -0
- app/code/local/SFC/Autoship/Block/Product/View.php +93 -0
- app/code/local/SFC/Autoship/Block/Product/View/Type/Grouped/Subscribe.php +125 -0
- app/code/local/SFC/Autoship/Block/Subscription/Abstract.php +135 -0
- app/code/local/SFC/Autoship/Block/Subscription/Form/Address.php +162 -0
- app/code/local/SFC/Autoship/Block/Subscription/Form/Payment.php +296 -0
- app/code/local/SFC/Autoship/Helper/Adminorder.php +123 -0
- app/code/local/SFC/Autoship/Helper/Api.php +290 -0
- app/code/local/SFC/Autoship/Helper/Data.php +42 -0
- app/code/local/SFC/Autoship/Helper/Payment.php +105 -0
- app/code/local/SFC/Autoship/Helper/PaymentError.php +67 -0
- app/code/local/SFC/Autoship/Helper/PaymentError/Exception.php +24 -0
- app/code/local/SFC/Autoship/Helper/Platform.php +340 -0
- app/code/local/SFC/Autoship/Helper/Product.php +70 -0
- app/code/local/SFC/Autoship/Helper/Quote.php +270 -0
- app/code/local/SFC/Autoship/Helper/Schedule.php +48 -0
- app/code/local/SFC/Autoship/Helper/Subscription.php +215 -0
- app/code/local/SFC/Autoship/Helper/Vault.php +266 -0
- app/code/local/SFC/Autoship/Model/Checkout/Cart/Api.php +62 -0
- app/code/local/SFC/Autoship/Model/Checkout/Cart/Payment/Api.php +57 -0
- app/code/local/SFC/Autoship/Model/Checkout/Cart/Product/Api.php +106 -0
- app/code/local/SFC/Autoship/Model/Mysql4/Subscription.php +24 -0
- app/code/local/SFC/Autoship/Model/Mysql4/Subscription/Collection.php +24 -0
- app/code/local/SFC/Autoship/Model/Observer.php +281 -0
- app/code/local/SFC/Autoship/Model/Payment/Method.php +267 -0
- app/code/local/SFC/Autoship/Model/Payment/Profile.php +88 -0
- app/code/local/SFC/Autoship/Model/Payment/Profile/Address.php +58 -0
- app/code/local/SFC/Autoship/Model/Payment/Profile/Collection.php +66 -0
- app/code/local/SFC/Autoship/Model/Paypal/Express.php +47 -0
- app/code/local/SFC/Autoship/Model/Platform/Product.php +32 -0
- app/code/local/SFC/Autoship/Model/Quote/Address.php +68 -0
- app/code/local/SFC/Autoship/Model/SalesRule/Rule/Condition/Product.php +75 -0
- app/code/local/SFC/Autoship/Model/SalesRule/Validator.php +107 -0
- app/code/local/SFC/Autoship/Model/Subscription.php +114 -0
- app/code/local/SFC/Autoship/Model/System/Config/Source/Cartrulediscountcombinetype.php +57 -0
- app/code/local/SFC/Autoship/Model/System/Config/Source/Cctype.php +97 -0
- app/code/local/SFC/Autoship/Model/System/Config/Source/Month.php +84 -0
- app/code/local/SFC/Autoship/Model/System/Config/Source/Nextorderdatemode.php +51 -0
- app/code/local/SFC/Autoship/Model/System/Config/Source/Shippingmethods.php +34 -0
- app/code/local/SFC/Autoship/Model/System/Config/Source/Year.php +88 -0
- app/code/local/SFC/Autoship/controllers/Adminhtml/PaymentprofileController.php +269 -0
- app/code/local/SFC/Autoship/controllers/Adminhtml/TestconnectionbuttonController.php +83 -0
- app/code/local/SFC/Autoship/controllers/MycreditcardsController.php +246 -0
- app/code/local/SFC/Autoship/controllers/MysubscriptionsController.php +690 -0
- app/code/local/SFC/Autoship/controllers/NewsubscriptionController.php +558 -0
- app/code/local/SFC/Autoship/etc/adminhtml.xml +44 -0
- app/code/local/SFC/Autoship/etc/config.xml +324 -0
- app/code/local/SFC/Autoship/etc/system.xml +415 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-install-1.3.1.8.php +101 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-uninstall-1.3.1.4.php +51 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.1.0-1.1.1.php +51 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.1.2-1.2.0.php +93 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.2.2.1-1.2.2.2.php +46 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.2.3-1.2.4.php +77 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.2.4.6-1.2.4.7.php +46 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.0.1-1.3.0.2.php +48 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.0.5-1.3.1.0.php +36 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.1.3-1.3.1.4.php +47 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.1.4-1.3.1.5.php +38 -0
- app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.1.7-1.3.1.8.php +43 -0
- app/design/adminhtml/default/default/layout/autoship.xml +43 -0
- app/design/adminhtml/default/default/template/autoship/payment/form/cc.phtml +73 -0
- app/design/adminhtml/default/default/template/autoship/payment/form/cc_saved.phtml +58 -0
- app/design/adminhtml/default/default/template/autoship/sales/create_order/jsonp.phtml +23 -0
- app/design/adminhtml/default/default/template/autoship/system/config/test_connection_button.phtml +24 -0
- app/design/frontend/base/default/layout/autoship.xml +254 -0
- app/design/frontend/base/default/template/autoship/cart/product/subscription.phtml +75 -0
- app/design/frontend/base/default/template/autoship/checkout/jsonp.phtml +26 -0
- app/design/frontend/base/default/template/autoship/checkout/serversideapi.phtml +65 -0
- app/design/frontend/base/default/template/autoship/checkout/success.phtml +32 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions.phtml +120 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions/subscription.phtml +34 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/actions.phtml +115 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/billing_address.phtml +54 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/payment.phtml +49 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/product_info.phtml +39 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/shipping_address.phtml +54 -0
- app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/subscription_info.phtml +95 -0
- app/design/frontend/base/default/template/autoship/newsubscription.phtml +75 -0
- app/design/frontend/base/default/template/autoship/newsubscription/ajax_update.phtml +38 -0
- app/design/frontend/base/default/template/autoship/newsubscription/billing_address.phtml +51 -0
- app/design/frontend/base/default/template/autoship/newsubscription/delivery_date.phtml +43 -0
- app/design/frontend/base/default/template/autoship/newsubscription/delivery_frequency.phtml +44 -0
- app/design/frontend/base/default/template/autoship/newsubscription/payment.phtml +77 -0
- app/design/frontend/base/default/template/autoship/newsubscription/product_info.phtml +36 -0
- app/design/frontend/base/default/template/autoship/newsubscription/shipping_address.phtml +51 -0
- app/design/frontend/base/default/template/autoship/newsubscription/summary.phtml +69 -0
- app/design/frontend/base/default/template/autoship/payment/form/cc.phtml +95 -0
- app/design/frontend/base/default/template/autoship/payment/form/cc_saved.phtml +68 -0
- app/design/frontend/base/default/template/autoship/payment/profile/edit.phtml +207 -0
- app/design/frontend/base/default/template/autoship/payment/profile/grid.phtml +89 -0
- app/design/frontend/base/default/template/autoship/payment/profile/new.phtml +218 -0
- app/design/frontend/base/default/template/autoship/product/subscribe.phtml +80 -0
- app/design/frontend/base/default/template/autoship/product/view/addtocart.phtml +47 -0
- app/design/frontend/base/default/template/autoship/product/view/type/grouped/subscribe.phtml +65 -0
- app/design/frontend/base/default/template/autoship/subscription/form/billing.phtml +188 -0
- app/design/frontend/base/default/template/autoship/subscription/form/payment.phtml +64 -0
- app/design/frontend/base/default/template/autoship/subscription/form/shipping.phtml +175 -0
- app/design/frontend/enterprise/default/layout/autoship.xml +254 -0
- app/etc/modules/SFC_Autoship.xml +11 -0
- lib/OAuth2/Client.php +540 -0
- lib/OAuth2/GrantType/AuthorizationCode.php +41 -0
- lib/OAuth2/GrantType/ClientCredentials.php +25 -0
- lib/OAuth2/GrantType/IGrantType.php +15 -0
- lib/OAuth2/GrantType/Password.php +41 -0
- lib/OAuth2/GrantType/RefreshToken.php +34 -0
- lib/OAuth2/README +117 -0
- package.xml +18 -0
- shell/autoship_prod_sync.php +61 -0
- skin/adminhtml/default/default/js/autoship/jquery/jquery-1.10.1.min.js +6 -0
- skin/adminhtml/default/default/js/autoship/jquery/noconflict.js +31 -0
- skin/adminhtml/default/default/js/autoship/sales_create_order.js +156 -0
- skin/frontend/base/default/css/autoship.css +290 -0
- skin/frontend/base/default/images/autoship/bkg_active-step.gif +0 -0
- skin/frontend/base/default/images/autoship/bkg_block.gif +0 -0
- skin/frontend/base/default/images/autoship/bkg_btn-co.gif +0 -0
- skin/frontend/base/default/images/autoship/bkg_thead.gif +0 -0
- skin/frontend/base/default/images/autoship/calendar_icon.png +0 -0
- skin/frontend/base/default/images/autoship/white_trans.png +0 -0
- skin/frontend/base/default/js/autoship/checkout.js +121 -0
- skin/frontend/base/default/js/autoship/jquery/jquery-1.10.1.min.js +6 -0
- skin/frontend/base/default/js/autoship/jquery/noconflict.js +31 -0
- skin/frontend/base/default/js/autoship/jquery/ui/jquery.ui.core.min.js +4 -0
- skin/frontend/base/default/js/autoship/jquery/ui/jquery.ui.datepicker.min.js +5 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/animated-overlay.gif +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_222222_256x240.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_2e83ff_256x240.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_454545_256x240.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_888888_256x240.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_cd0a0a_256x240.png +0 -0
- skin/frontend/base/default/js/autoship/jquery/ui/theme/jquery-ui.css +1188 -0
- skin/frontend/base/default/js/autoship/mysubscription.js +213 -0
- skin/frontend/base/default/js/autoship/newsubscription.js +166 -0
app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Edit.php
ADDED
@@ -0,0 +1,63 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Adminhtml_Customer_Paymentprofiles_Edit extends Mage_Adminhtml_Block_Widget_Form_Container
|
19 |
+
{
|
20 |
+
|
21 |
+
public function __construct()
|
22 |
+
{
|
23 |
+
// Call parent
|
24 |
+
parent::__construct();
|
25 |
+
// Make some adjustments to the form container
|
26 |
+
$this->_objectId = 'id';
|
27 |
+
$this->_blockGroup = 'autoship';
|
28 |
+
$this->_controller = 'adminhtml_customer_paymentprofiles';
|
29 |
+
$this->_updateButton('save', 'label', Mage::helper('autoship')->__('Save Card'));
|
30 |
+
$this->_removeButton('delete');
|
31 |
+
$this->_removeButton('reset');
|
32 |
+
}
|
33 |
+
|
34 |
+
public function getHeaderText()
|
35 |
+
{
|
36 |
+
if (Mage::registry('paymentprofile_data') && Mage::registry('paymentprofile_data')->getId()) {
|
37 |
+
// Editing existing card
|
38 |
+
return Mage::helper('autoship')->__(
|
39 |
+
"Edit Saved Credit Card %s",
|
40 |
+
Mage::registry('paymentprofile_data')->getData('creditcard_number'));
|
41 |
+
}
|
42 |
+
else {
|
43 |
+
// Creating new card
|
44 |
+
// Load customer record
|
45 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
46 |
+
$customer = Mage::getModel('customer/customer')->load(Mage::registry('customer_id'));
|
47 |
+
// Build title
|
48 |
+
return Mage::helper('autoship')->__('New Saved Credit Card - ' . $customer->getName());
|
49 |
+
}
|
50 |
+
}
|
51 |
+
|
52 |
+
/**
|
53 |
+
* Return URL to customer edit page
|
54 |
+
*
|
55 |
+
* @return string
|
56 |
+
*/
|
57 |
+
public function getBackUrl()
|
58 |
+
{
|
59 |
+
return $this->getUrl('adminhtml/customer/edit/tab/customer_info_tabs_paymentprofile',
|
60 |
+
array('id' => Mage::registry('customer_id')));
|
61 |
+
}
|
62 |
+
|
63 |
+
}
|
app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Edit/Form.php
ADDED
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Adminhtml_Customer_Paymentprofiles_Edit_Form extends Mage_Adminhtml_Block_Widget_Form
|
19 |
+
{
|
20 |
+
/**
|
21 |
+
* Prepare edit form
|
22 |
+
*/
|
23 |
+
protected function _prepareForm()
|
24 |
+
{
|
25 |
+
$form = new Varien_Data_Form(array(
|
26 |
+
'id' => 'edit_form',
|
27 |
+
'action' => $this->getUrl('*/*/save', array('id' => $this->getRequest()->getParam('id'))),
|
28 |
+
'method' => 'post',
|
29 |
+
'enctype' => 'multipart/form-data',
|
30 |
+
));
|
31 |
+
|
32 |
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
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
class SFC_Autoship_Block_Adminhtml_Customer_Paymentprofiles_Edit_Tab_Form extends Mage_Adminhtml_Block_Widget_Form
|
19 |
+
{
|
20 |
+
/**
|
21 |
+
* Prepare edit form
|
22 |
+
*
|
23 |
+
* @SuppressWarnings(PHPMD.ExcessiveMethodLength)
|
24 |
+
*/
|
25 |
+
protected function _prepareForm()
|
26 |
+
{
|
27 |
+
// Get payment profile from registry
|
28 |
+
$model = Mage::registry('paymentprofile_data');
|
29 |
+
|
30 |
+
// Create form
|
31 |
+
$form = new Varien_Data_Form();
|
32 |
+
|
33 |
+
// New Fieldset
|
34 |
+
$fieldset = $form->addFieldset(
|
35 |
+
'autoship_form_customer',
|
36 |
+
array(
|
37 |
+
'legend' => Mage::helper('autoship')->__('Customer')
|
38 |
+
));
|
39 |
+
|
40 |
+
$fieldset->addField('id', 'hidden', array(
|
41 |
+
'label' => Mage::helper('autoship')->__('Payment Profile ID'),
|
42 |
+
'class' => '',
|
43 |
+
'required' => false,
|
44 |
+
'name' => 'id',
|
45 |
+
));
|
46 |
+
|
47 |
+
$fieldset->addField('magento_customer_id', 'hidden', array(
|
48 |
+
'label' => Mage::helper('autoship')->__('Magento Customer ID'),
|
49 |
+
'class' => '',
|
50 |
+
'required' => false,
|
51 |
+
'name' => 'magento_customer_id',
|
52 |
+
));
|
53 |
+
|
54 |
+
$fieldset->addField('customer_email', 'hidden', array(
|
55 |
+
'label' => Mage::helper('autoship')->__('Customer Email'),
|
56 |
+
'class' => '',
|
57 |
+
'required' => false,
|
58 |
+
'name' => 'customer_email',
|
59 |
+
));
|
60 |
+
|
61 |
+
$fieldset->addField('payment_token', 'hidden', array(
|
62 |
+
'label' => Mage::helper('autoship')->__('Payment Token'),
|
63 |
+
'class' => '',
|
64 |
+
'required' => false,
|
65 |
+
'name' => 'payment_token',
|
66 |
+
));
|
67 |
+
|
68 |
+
$fieldset->addField('customer_id_readonly', 'label', array(
|
69 |
+
'label' => Mage::helper('autoship')->__('Customer ID'),
|
70 |
+
'class' => '',
|
71 |
+
'required' => false,
|
72 |
+
'readonly' => true,
|
73 |
+
'name' => 'customer_id_readonly',
|
74 |
+
));
|
75 |
+
|
76 |
+
$fieldset->addField('email_readonly', 'label', array(
|
77 |
+
'label' => Mage::helper('autoship')->__('Email'),
|
78 |
+
'class' => '',
|
79 |
+
'required' => false,
|
80 |
+
'readonly' => true,
|
81 |
+
'name' => 'email_readonly',
|
82 |
+
));
|
83 |
+
|
84 |
+
// New Fieldset
|
85 |
+
$fieldset = $form->addFieldset(
|
86 |
+
'autoship_form_creditcard',
|
87 |
+
array(
|
88 |
+
'legend' => Mage::helper('autoship')->__('Card Details')
|
89 |
+
));
|
90 |
+
|
91 |
+
if (strlen($model->getId())) {
|
92 |
+
$fieldset->addField('creditcard_number', 'text', array(
|
93 |
+
'label' => Mage::helper('autoship')->__('Credit Card'),
|
94 |
+
'class' => 'required-entry',
|
95 |
+
'readonly' => 'readonly',
|
96 |
+
'disabled' => true,
|
97 |
+
'required' => true,
|
98 |
+
'name' => 'creditcard_number',
|
99 |
+
));
|
100 |
+
}
|
101 |
+
else {
|
102 |
+
$fieldset->addField('creditcard_number', 'text', array(
|
103 |
+
'label' => Mage::helper('autoship')->__('Credit Card'),
|
104 |
+
'class' => 'required-entry',
|
105 |
+
'required' => true,
|
106 |
+
'name' => 'creditcard_number',
|
107 |
+
));
|
108 |
+
}
|
109 |
+
|
110 |
+
|
111 |
+
$fieldset->addField('creditcard_month', 'select', array(
|
112 |
+
'label' => Mage::helper('autoship')->__('Expiration Month'),
|
113 |
+
'class' => '',
|
114 |
+
'required' => false,
|
115 |
+
'values' => Mage::getModel('autoship/system_config_source_month')->toOptionArray(),
|
116 |
+
'name' => 'creditcard_month',
|
117 |
+
));
|
118 |
+
|
119 |
+
$fieldset->addField('creditcard_year', 'select', array(
|
120 |
+
'label' => Mage::helper('autoship')->__('Expiration Year'),
|
121 |
+
'class' => '',
|
122 |
+
'required' => false,
|
123 |
+
'values' => Mage::getModel('autoship/system_config_source_year')->toOptionArray(),
|
124 |
+
'name' => 'creditcard_year',
|
125 |
+
));
|
126 |
+
|
127 |
+
// New Fieldset
|
128 |
+
$fieldset = $form->addFieldset(
|
129 |
+
'autoship_form_billing',
|
130 |
+
array(
|
131 |
+
'legend' => Mage::helper('autoship')->__('Billing Address')
|
132 |
+
));
|
133 |
+
|
134 |
+
// customer first name
|
135 |
+
$fieldset->addField('billing_first_name', 'text', array(
|
136 |
+
'label' => Mage::helper('autoship')->__('First Name'),
|
137 |
+
'class' => 'required-entry',
|
138 |
+
'required' => true,
|
139 |
+
'name' => 'billing_first_name',
|
140 |
+
));
|
141 |
+
|
142 |
+
// customer last name
|
143 |
+
$fieldset->addField('billing_last_name', 'text', array(
|
144 |
+
'label' => Mage::helper('autoship')->__('Last Name'),
|
145 |
+
'class' => 'required-entry',
|
146 |
+
'required' => true,
|
147 |
+
'name' => 'billing_last_name',
|
148 |
+
));
|
149 |
+
|
150 |
+
// street1
|
151 |
+
$fieldset->addField('billing_street1', 'text', array(
|
152 |
+
'label' => Mage::helper('autoship')->__('Street Address 1'),
|
153 |
+
'class' => '',
|
154 |
+
'required' => false,
|
155 |
+
'name' => 'billing_street1',
|
156 |
+
));
|
157 |
+
|
158 |
+
// street2
|
159 |
+
$fieldset->addField('billing_street2', 'text', array(
|
160 |
+
'label' => Mage::helper('autoship')->__('Street Address 2'),
|
161 |
+
'class' => '',
|
162 |
+
'required' => false,
|
163 |
+
'name' => 'billing_street2',
|
164 |
+
));
|
165 |
+
|
166 |
+
// city
|
167 |
+
$fieldset->addField('billing_city', 'text', array(
|
168 |
+
'label' => Mage::helper('autoship')->__('City'),
|
169 |
+
'class' => '',
|
170 |
+
'required' => false,
|
171 |
+
'name' => 'billing_city',
|
172 |
+
));
|
173 |
+
|
174 |
+
// region
|
175 |
+
$fieldset->addField('billing_region', 'text', array(
|
176 |
+
'label' => Mage::helper('autoship')->__('State'),
|
177 |
+
'class' => '',
|
178 |
+
'required' => false,
|
179 |
+
'name' => 'billing_region',
|
180 |
+
));
|
181 |
+
|
182 |
+
// postcode
|
183 |
+
$fieldset->addField('billing_postcode', 'text', array(
|
184 |
+
'label' => Mage::helper('autoship')->__('Zip/Postal Code'),
|
185 |
+
'class' => '',
|
186 |
+
'required' => false,
|
187 |
+
'name' => 'billing_postcode',
|
188 |
+
));
|
189 |
+
|
190 |
+
// country_id
|
191 |
+
$fieldset->addField('billing_country', 'text', array(
|
192 |
+
'label' => Mage::helper('autoship')->__('Country'),
|
193 |
+
'class' => '',
|
194 |
+
'required' => false,
|
195 |
+
'name' => 'billing_country',
|
196 |
+
));
|
197 |
+
|
198 |
+
// phone number
|
199 |
+
$fieldset->addField('billing_phone', 'text', array(
|
200 |
+
'label' => Mage::helper('autoship')->__('Phone Number'),
|
201 |
+
'class' => '',
|
202 |
+
'required' => false,
|
203 |
+
'name' => 'billing_phone',
|
204 |
+
));
|
205 |
+
|
206 |
+
// Tweak model with extra fields
|
207 |
+
$model->setData('customer_id_readonly', $model->getData('magento_customer_id'));
|
208 |
+
$model->setData('email_readonly', $model->getData('customer_email'));
|
209 |
+
$model->setData('payment_token_readonly', $model->getData('payment_token'));
|
210 |
+
// Set values for form
|
211 |
+
$form->setValues($model->getData());
|
212 |
+
// Set form on this widget
|
213 |
+
$this->setForm($form);
|
214 |
+
|
215 |
+
return parent::_prepareForm();
|
216 |
+
}
|
217 |
+
|
218 |
+
}
|
app/code/local/SFC/Autoship/Block/Adminhtml/Customer/Paymentprofiles/Edit/Tabs.php
ADDED
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Adminhtml_Customer_Paymentprofiles_Edit_Tabs extends Mage_Adminhtml_Block_Widget_Tabs
|
19 |
+
{
|
20 |
+
public function __construct()
|
21 |
+
{
|
22 |
+
parent::__construct();
|
23 |
+
$this->setId('paymentprofile_tabs');
|
24 |
+
$this->setDestElementId('edit_form');
|
25 |
+
$this->setTitle(Mage::helper('autoship')->__('Saved Credit Card'));
|
26 |
+
}
|
27 |
+
|
28 |
+
protected function _beforeToHtml()
|
29 |
+
{
|
30 |
+
$this->addTab('form_section', array(
|
31 |
+
'label' => Mage::helper('autoship')->__('Information'),
|
32 |
+
'title' => Mage::helper('autoship')->__('Information'),
|
33 |
+
'content' => $this->getLayout()->createBlock('autoship/adminh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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Adminhtml_Customer_Paymentprofiles_Paymentprofile
|
19 |
+
extends Mage_Adminhtml_Block_Widget_Grid
|
20 |
+
implements Mage_Adminhtml_Block_Widget_Tab_Interface
|
21 |
+
{
|
22 |
+
|
23 |
+
/**
|
24 |
+
* Construct
|
25 |
+
*/
|
26 |
+
protected function _construct()
|
27 |
+
{
|
28 |
+
parent::_construct();
|
29 |
+
$this->setId('paymentprofile');
|
30 |
+
$this->setDefaultSort('id');
|
31 |
+
$this->setDefaultDir('DESC');
|
32 |
+
$this->setSaveParametersInSession(true);
|
33 |
+
$this->setUseAjax(true);
|
34 |
+
$this->setFilterVisibility(false);
|
35 |
+
}
|
36 |
+
|
37 |
+
/**
|
38 |
+
* Prepare collection
|
39 |
+
*
|
40 |
+
* @return Mage_Adminhtml_Block_Widget_Grid::_prepareCollection()
|
41 |
+
*/
|
42 |
+
protected function _prepareCollection()
|
43 |
+
{
|
44 |
+
// Get cur customer
|
45 |
+
$customer = $this->getCustomer();
|
46 |
+
// Create collection
|
47 |
+
$collection = Mage::getModel('autoship/payment_profile')->getCollection();
|
48 |
+
if ($this->canShowTab()) {
|
49 |
+
// Get collection filtered by the current customer id
|
50 |
+
/** @var Varien_Data_Collection $collection */
|
51 |
+
$collection->addFilter('customer_email', $customer->getData('email'));
|
52 |
+
}
|
53 |
+
// set collection
|
54 |
+
$this->setCollection($collection);
|
55 |
+
|
56 |
+
return parent::_prepareCollection();
|
57 |
+
}
|
58 |
+
|
59 |
+
/**
|
60 |
+
* Prepare layout. Create buttons for grid (New CC, Export, etc)
|
61 |
+
*
|
62 |
+
* @return Mage_Core_Block_Abstract|void
|
63 |
+
*/
|
64 |
+
protected function _prepareLayout()
|
65 |
+
{
|
66 |
+
// Build URL to add new payment profile
|
67 |
+
$urlString = 'autoship_admin/adminhtml_paymentprofile/new';
|
68 |
+
$url = $this->getUrl($urlString, array('customer_id' => Mage::registry('current_customer')->getId()));
|
69 |
+
|
70 |
+
$button = $this->getLayout()->createBlock('adminhtml/widget_button');
|
71 |
+
$button->setData(array(
|
72 |
+
'label' => Mage::helper('autoship')->__('New Credit Card'),
|
73 |
+
'onclick' => 'setLocation(\'' . $url . '\')',
|
74 |
+
));
|
75 |
+
$this->setChild('payment_profile_button', $button);
|
76 |
+
|
77 |
+
$button = $this->getLayout()->createBlock('adminhtml/widget_button');
|
78 |
+
$button->setData(array(
|
79 |
+
'label' => Mage::helper('adminhtml')->__('Export'),
|
80 |
+
'onclick' => $this->getJsObjectName() . '.doExport()',
|
81 |
+
'class' => 'task'
|
82 |
+
));
|
83 |
+
$this->setChild('export_button', $button);
|
84 |
+
|
85 |
+
$button = $this->getLayout()->createBlock('adminhtml/widget_button');
|
86 |
+
$button->setData(array(
|
87 |
+
'label' => Mage::helper('adminhtml')->__('Reset Filter'),
|
88 |
+
'onclick' => $this->getJsObjectName() . '.resetFilter()',
|
89 |
+
));
|
90 |
+
$this->setChild('reset_filter_button', $button);
|
91 |
+
|
92 |
+
$button = $this->getLayout()->createBlock('adminhtml/widget_button');
|
93 |
+
$button->setData(array(
|
94 |
+
'label' => Mage::helper('adminhtml')->__('Search'),
|
95 |
+
'onclick' => $this->getJsObjectName() . '.doFilter()',
|
96 |
+
'class' => 'task'
|
97 |
+
));
|
98 |
+
$this->setChild('search_button', $button);
|
99 |
+
|
100 |
+
// Now call parent implementation
|
101 |
+
parent::_prepareLayout();
|
102 |
+
}
|
103 |
+
|
104 |
+
/**
|
105 |
+
* Generate the html for out new payment profile button
|
106 |
+
*
|
107 |
+
* @return string
|
108 |
+
*/
|
109 |
+
public function getSearchButtonHtml()
|
110 |
+
{
|
111 |
+
return parent::getSearchButtonHtml() . $this->getChildHtml('payment_profile_button');
|
112 |
+
}
|
113 |
+
|
114 |
+
/**
|
115 |
+
* Generate grid columns
|
116 |
+
*
|
117 |
+
* @return Mage_Adminhtml_Block_Widget_Grid::_prepareColumns()
|
118 |
+
*/
|
119 |
+
protected function _prepareColumns()
|
120 |
+
{
|
121 |
+
// payment profile id
|
122 |
+
$this->addColumn('id', array(
|
123 |
+
'header' => Mage::helper('autoship')->__('Id'),
|
124 |
+
'align' => 'left',
|
125 |
+
'width' => '30px',
|
126 |
+
'type' => 'number',
|
127 |
+
'index' => 'id',
|
128 |
+
'filter' => false,
|
129 |
+
));
|
130 |
+
|
131 |
+
$this->addColumn('billing_name', array(
|
132 |
+
'header' => Mage::helper('autoship')->__('Customer Name'),
|
133 |
+
'index' => 'billing_name',
|
134 |
+
'type' => 'text',
|
135 |
+
));
|
136 |
+
|
137 |
+
$this->addColumn('creditcard_type', array(
|
138 |
+
'header' => Mage::helper('autoship')->__('Card Type'),
|
139 |
+
'index' => 'creditcard_type',
|
140 |
+
'type' => 'options',
|
141 |
+
'options' => Mage::getModel('autoship/system_config_source_cctype')->getCcAllTypesSubscribeProFormat(),
|
142 |
+
));
|
143 |
+
|
144 |
+
$this->addColumn('creditcard_number', array(
|
145 |
+
'header' => Mage::helper('autoship')->__('Card Number'),
|
146 |
+
'index' => 'creditcard_number',
|
147 |
+
'type' => 'text'
|
148 |
+
));
|
149 |
+
|
150 |
+
$this->addColumn('creditcard_exp_date', array(
|
151 |
+
'header' => Mage::helper('autoship')->__('Expiration Date'),
|
152 |
+
'index' => 'creditcard_exp_date',
|
153 |
+
'type' => 'text'
|
154 |
+
));
|
155 |
+
|
156 |
+
$this->addColumn('payment_token', array(
|
157 |
+
'header' => Mage::helper('autoship')->__('Payment Token'),
|
158 |
+
'index' => 'payment_token',
|
159 |
+
'type' => 'text'
|
160 |
+
));
|
161 |
+
|
162 |
+
return parent::_prepareColumns();
|
163 |
+
}
|
164 |
+
|
165 |
+
/**
|
166 |
+
* Get URL to view the payment profile
|
167 |
+
*
|
168 |
+
* @param SFC_Autoship_Model_Payment_Profile $row
|
169 |
+
* @return string
|
170 |
+
*/
|
171 |
+
public function getRowUrl($row)
|
172 |
+
{
|
173 |
+
return $this->getUrl(
|
174 |
+
'autoship_admin/adminhtml_paymentprofile/edit',
|
175 |
+
array(
|
176 |
+
'id' => $row->getId(),
|
177 |
+
'customer_id' => $row->getData('magento_customer_id')
|
178 |
+
));
|
179 |
+
}
|
180 |
+
|
181 |
+
/**
|
182 |
+
* Get the url for this grid. Used for ajax calls.
|
183 |
+
*
|
184 |
+
* @return string
|
185 |
+
*/
|
186 |
+
public function getGridUrl()
|
187 |
+
{
|
188 |
+
return $this->getUrl('autoship_admin/adminhtml_paymentprofile/grid', array('_current' => true));
|
189 |
+
}
|
190 |
+
|
191 |
+
/**
|
192 |
+
* Delete multiple items from grid
|
193 |
+
*
|
194 |
+
* @return $this|Mage_Adminhtml_Block_Widget_Grid
|
195 |
+
*/
|
196 |
+
protected function _prepareMassaction()
|
197 |
+
{
|
198 |
+
// Get cur customer
|
199 |
+
$customer = $this->getCustomer();
|
200 |
+
// Setup mass action block details
|
201 |
+
$this->setMassactionIdField('id');
|
202 |
+
$this->getMassactionBlock()->setFormFieldName('ids');
|
203 |
+
$this->getMassactionBlock()->setUseSelectAll(true);
|
204 |
+
$this->getMassactionBlock()->addItem('remove_profile', array(
|
205 |
+
'label' => Mage::helper('autoship')->__('Delete Credit Card(s)'),
|
206 |
+
'url' => $this->getUrl(
|
207 |
+
'autoship_admin/adminhtml_paymentprofile/massRemove',
|
208 |
+
array(
|
209 |
+
'customer_id' => $customer->getId(),
|
210 |
+
)),
|
211 |
+
'confirm' => Mage::helper('autoship')->__('Are you sure?')
|
212 |
+
));
|
213 |
+
|
214 |
+
return $this;
|
215 |
+
}
|
216 |
+
|
217 |
+
public function getTabLabel()
|
218 |
+
{
|
219 |
+
return $this->__('Credit Cards (Subscribe Pro Vault)');
|
220 |
+
}
|
221 |
+
|
222 |
+
public function getTabTitle()
|
223 |
+
{
|
224 |
+
return $this->__('Credit Cards (Subscribe Pro Vault)');
|
225 |
+
}
|
226 |
+
|
227 |
+
public function canShowTab()
|
228 |
+
{
|
229 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
230 |
+
$platformHelper = Mage::helper('autoship/platform');
|
231 |
+
|
232 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
233 |
+
$customer = $this->getCustomer();
|
234 |
+
// Check customer
|
235 |
+
if ($customer == null || !strlen($customer->getId())) {
|
236 |
+
return false;
|
237 |
+
}
|
238 |
+
// Get store from cur customer website
|
239 |
+
$store = $customer->getStore();
|
240 |
+
// Check config enabled
|
241 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $store) != '1') {
|
242 |
+
return false;
|
243 |
+
}
|
244 |
+
// Check configured payment method
|
245 |
+
$paymentMethodCode = $platformHelper->getConfiguredPaymentMethodCode();
|
246 |
+
if ($paymentMethodCode != SFC_Autoship_Model_Payment_Method::METHOD_CODE) {
|
247 |
+
return false;
|
248 |
+
}
|
249 |
+
|
250 |
+
return true;
|
251 |
+
}
|
252 |
+
|
253 |
+
public function isHidden()
|
254 |
+
{
|
255 |
+
return false;
|
256 |
+
}
|
257 |
+
|
258 |
+
/**
|
259 |
+
* Get the current customer, for which we're showing the grid of credit cards
|
260 |
+
*
|
261 |
+
* @return Mage_Customer_Model_Customer
|
262 |
+
*/
|
263 |
+
public function getCustomer()
|
264 |
+
{
|
265 |
+
// Cur customer
|
266 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
267 |
+
$customer = Mage::registry('current_customer');
|
268 |
+
|
269 |
+
// If we found customer, set config store for API calls from customer website / store
|
270 |
+
if ($customer != null) {
|
271 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
272 |
+
$apiHelper = Mage::helper('autoship/api');
|
273 |
+
// Get store from cur customer website
|
274 |
+
$store = $customer->getStore();
|
275 |
+
// Set store on api helper
|
276 |
+
$apiHelper->setConfigStore($store);
|
277 |
+
}
|
278 |
+
|
279 |
+
return $customer;
|
280 |
+
}
|
281 |
+
|
282 |
+
}
|
app/code/local/SFC/Autoship/Block/Adminhtml/Sales/Order/Create/Jsonp.php
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Adminhtml_Sales_Order_Create_Jsonp extends Mage_Checkout_Block_Onepage_Abstract
|
19 |
+
{
|
20 |
+
|
21 |
+
protected function _construct()
|
22 |
+
{
|
23 |
+
parent::_construct();
|
24 |
+
$this->setTemplate('autoship/sales/create_order/jsonp.phtml');
|
25 |
+
}
|
26 |
+
|
27 |
+
protected function getStore()
|
28 |
+
{
|
29 |
+
// If we are in admin store, try to find correct store from current quote
|
30 |
+
/** @var Mage_Adminhtml_Model_Session_Quote $adminhtmlQuoteSession */
|
31 |
+
$adminhtmlQuoteSession = Mage::getSingleton('adminhtml/session_quote');
|
32 |
+
$quote = $adminhtmlQuoteSession->getQuote();
|
33 |
+
$store = $quote->getStore();
|
34 |
+
|
35 |
+
return $store;
|
36 |
+
}
|
37 |
+
|
38 |
+
public function showJsonp()
|
39 |
+
{
|
40 |
+
$spPayMethodActive = Mage::getStoreConfig('payment/subscribe_pro/active', $this->getStore()) == '1';
|
41 |
+
|
42 |
+
return $spPayMethodActive;
|
43 |
+
}
|
44 |
+
|
45 |
+
public function getEnvironmentKey()
|
46 |
+
{
|
47 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
48 |
+
$platformHelper = Mage::helper('autoship/platform');
|
49 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
50 |
+
$apiHelper = Mage::helper('autoship/api');
|
51 |
+
// Set store on api helper
|
52 |
+
$apiHelper->setConfigStore($this->getStore());
|
53 |
+
// Lookup payment method code based on SP config
|
54 |
+
$accountConfig = $platformHelper->getAccountConfig();
|
55 |
+
// Get env key
|
56 |
+
$environmentKey = $accountConfig['transparent_redirect_environment_key'];
|
57 |
+
|
58 |
+
return $environmentKey;
|
59 |
+
}
|
60 |
+
|
61 |
+
public function getJSONPUrl()
|
62 |
+
{
|
63 |
+
return 'https://core.spreedly.com/v1/payment_methods.js';
|
64 |
+
}
|
65 |
+
|
66 |
+
}
|
app/code/local/SFC/Autoship/Block/Adminhtml/System/Config/Form/TestConnectionButton.php
ADDED
@@ -0,0 +1,75 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
|
19 |
+
class SFC_Autoship_Block_Adminhtml_System_Config_Form_TestConnectionButton extends Mage_Adminhtml_Block_System_Config_Form_Field
|
20 |
+
{
|
21 |
+
/*
|
22 |
+
* Set template
|
23 |
+
*/
|
24 |
+
protected function _construct()
|
25 |
+
{
|
26 |
+
parent::_construct();
|
27 |
+
$this->setTemplate('autoship/system/config/test_connection_button.phtml');
|
28 |
+
}
|
29 |
+
|
30 |
+
/**
|
31 |
+
* Return element html
|
32 |
+
*
|
33 |
+
* @param Varien_Data_Form_Element_Abstract $element
|
34 |
+
* @return string
|
35 |
+
*/
|
36 |
+
protected function _getElementHtml(Varien_Data_Form_Element_Abstract $element)
|
37 |
+
{
|
38 |
+
return $this->_toHtml();
|
39 |
+
}
|
40 |
+
|
41 |
+
/**
|
42 |
+
* Return ajax url for button
|
43 |
+
*
|
44 |
+
* @return string
|
45 |
+
*/
|
46 |
+
public function getAjaxCheckUrl()
|
47 |
+
{
|
48 |
+
return Mage::helper('adminhtml')->getUrl(
|
49 |
+
'autoship_admin/adminhtml_testconnectionbutton/test',
|
50 |
+
array(
|
51 |
+
'website' => $this->getRequest()->getParam('website'),
|
52 |
+
));
|
53 |
+
}
|
54 |
+
|
55 |
+
/**
|
56 |
+
* Generate button html
|
57 |
+
*
|
58 |
+
* @return string
|
59 |
+
*/
|
60 |
+
public function getButtonHtml()
|
61 |
+
{
|
62 |
+
// Set button details
|
63 |
+
$button = $this->getLayout()->createBlock('adminhtml/widget_button')
|
64 |
+
->setData(array(
|
65 |
+
'id' => 'sfc_autoship_test_connection_button',
|
66 |
+
'label' => $this->helper('adminhtml')->__('Test Connection'),
|
67 |
+
'onclick' => 'javascript:testConnection(); return false;'
|
68 |
+
));
|
69 |
+
// Get button html
|
70 |
+
$buttonHtml = $button->toHtml();
|
71 |
+
// Append our extra span
|
72 |
+
$finalHtml = $buttonHtml . '<span id="test_connection_result"></span>';
|
73 |
+
return $finalHtml;
|
74 |
+
}
|
75 |
+
}
|
app/code/local/SFC/Autoship/Block/Cart/Product/Subscription.php
ADDED
@@ -0,0 +1,113 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Cart_Product_Subscription extends Mage_Core_Block_Template
|
19 |
+
{
|
20 |
+
|
21 |
+
public function __construct()
|
22 |
+
{
|
23 |
+
}
|
24 |
+
|
25 |
+
/**
|
26 |
+
* Get quote item for this block
|
27 |
+
*
|
28 |
+
* @return Mage_Sales_Model_Quote_Item|null
|
29 |
+
*/
|
30 |
+
public function getQuoteItem()
|
31 |
+
{
|
32 |
+
// Get quote item from parent block
|
33 |
+
/** @var Mage_Sales_Model_Quote_Item $quoteItem */
|
34 |
+
$quoteItem = $this->getParentBlock()->getData('item');
|
35 |
+
|
36 |
+
return $quoteItem;
|
37 |
+
}
|
38 |
+
|
39 |
+
/**
|
40 |
+
* @return Mage_Catalog_Model_Product
|
41 |
+
*/
|
42 |
+
public function getProduct()
|
43 |
+
{
|
44 |
+
return Mage::helper('autoship/quote')->getRelevantProductFromQuoteItem($this->getQuoteItem());
|
45 |
+
}
|
46 |
+
|
47 |
+
/**
|
48 |
+
* Return the product profile for the current product
|
49 |
+
*
|
50 |
+
* @return SFC_Autoship_Model_Platform_Product The Magento product profile entity object for the current product
|
51 |
+
*/
|
52 |
+
public function getPlatformProduct()
|
53 |
+
{
|
54 |
+
return Mage::helper('autoship/platform')->getPlatformProduct($this->getProduct());
|
55 |
+
}
|
56 |
+
|
57 |
+
/**
|
58 |
+
* Indicates whether this product is eligible for subscription or not
|
59 |
+
*
|
60 |
+
* @return bool
|
61 |
+
*/
|
62 |
+
public function isItemSubscriptionEligible()
|
63 |
+
{
|
64 |
+
// Check config to see if extension functionality is enabled
|
65 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled') != '1') {
|
66 |
+
return false;
|
67 |
+
}
|
68 |
+
|
69 |
+
$platformProduct = $this->getPlatformProduct();
|
70 |
+
|
71 |
+
return $platformProduct->getEnabled();
|
72 |
+
}
|
73 |
+
|
74 |
+
/**
|
75 |
+
* @return bool
|
76 |
+
*/
|
77 |
+
public function isItemFlaggedToCreateNewSubscription()
|
78 |
+
{
|
79 |
+
// Check config to see if extension functionality is enabled
|
80 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled') != '1') {
|
81 |
+
return false;
|
82 |
+
}
|
83 |
+
|
84 |
+
// Get quote item
|
85 |
+
$quoteItem = $this->getQuoteItem();
|
86 |
+
// Return subscription flag
|
87 |
+
return $quoteItem->getData('create_new_subscription_at_checkout');
|
88 |
+
}
|
89 |
+
|
90 |
+
/**
|
91 |
+
* Get new subscription interval set on current quote item
|
92 |
+
*
|
93 |
+
* @return string
|
94 |
+
*/
|
95 |
+
public function getNewSubscriptionInterval()
|
96 |
+
{
|
97 |
+
// Get quote item
|
98 |
+
$quoteItem = $this->getQuoteItem();
|
99 |
+
// Return subscription flag
|
100 |
+
return $quoteItem->getData('new_subscription_interval');
|
101 |
+
}
|
102 |
+
|
103 |
+
/**
|
104 |
+
* Return eligible subscription intervals for this product
|
105 |
+
*
|
106 |
+
* @return array Array of eligible subscription interval strings (for example: One Month, Two Months, etc)
|
107 |
+
*/
|
108 |
+
public function getIntervals()
|
109 |
+
{
|
110 |
+
return $this->getPlatformProduct()->getIntervals();
|
111 |
+
}
|
112 |
+
|
113 |
+
}
|
app/code/local/SFC/Autoship/Block/Checkout/Jsonp.php
ADDED
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Checkout_Jsonp extends Mage_Checkout_Block_Onepage_Abstract
|
19 |
+
{
|
20 |
+
|
21 |
+
protected function _construct()
|
22 |
+
{
|
23 |
+
parent::_construct();
|
24 |
+
$this->setTemplate('autoship/checkout/jsonp.phtml');
|
25 |
+
}
|
26 |
+
|
27 |
+
public function getEnvironmentKey()
|
28 |
+
{
|
29 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
30 |
+
$platformHelper = Mage::helper('autoship/platform');
|
31 |
+
// Lookup payment method code based on SP config
|
32 |
+
$accountConfig = $platformHelper->getAccountConfig();
|
33 |
+
// Get env key
|
34 |
+
$environmentKey = $accountConfig['transparent_redirect_environment_key'];
|
35 |
+
|
36 |
+
return $environmentKey;
|
37 |
+
}
|
38 |
+
|
39 |
+
public function getJSONPUrl()
|
40 |
+
{
|
41 |
+
return 'https://core.spreedly.com/v1/payment_methods.js';
|
42 |
+
}
|
43 |
+
|
44 |
+
public function getBillingAddress()
|
45 |
+
{
|
46 |
+
return $this->getQuote()->getBillingAddress();
|
47 |
+
}
|
48 |
+
|
49 |
+
public function getCustomer()
|
50 |
+
{
|
51 |
+
return $this->getQuote()->getCustomer();
|
52 |
+
}
|
53 |
+
|
54 |
+
}
|
app/code/local/SFC/Autoship/Block/Checkout/Onepage/Payment/Methods.php
ADDED
@@ -0,0 +1,105 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Special code to make us compatible with AW_Points module
|
20 |
+
*/
|
21 |
+
if (file_exists(realpath(dirname(__FILE__)) . '/../../../AW/Points/Block/Checkout/Onepage/Payment/Methods.php') &&
|
22 |
+
class_exists('AW_Points_Block_Checkout_Onepage_Payment_Methods'))
|
23 |
+
{
|
24 |
+
class SFC_Autoship_Block_Checkout_Onepage_Payment_Methods_Base extends AW_Points_Block_Checkout_Onepage_Payment_Methods
|
25 |
+
{
|
26 |
+
}
|
27 |
+
}
|
28 |
+
else
|
29 |
+
{
|
30 |
+
class SFC_Autoship_Block_Checkout_Onepage_Payment_Methods_Base extends Mage_Checkout_Block_Onepage_Payment_Methods
|
31 |
+
{
|
32 |
+
}
|
33 |
+
}
|
34 |
+
|
35 |
+
class SFC_Autoship_Block_Checkout_Onepage_Payment_Methods extends SFC_Autoship_Block_Checkout_Onepage_Payment_Methods_Base
|
36 |
+
{
|
37 |
+
|
38 |
+
protected function _canUseMethod($method)
|
39 |
+
{
|
40 |
+
Mage::log('SFC_Autoship_Block_Checkout_Onepage_Payment_Methods::_canUseMethod', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
41 |
+
// Get cart, quote and quote item
|
42 |
+
/** @var Mage_Checkout_Model_Cart $cart */
|
43 |
+
$cart = Mage::getSingleton('checkout/cart');
|
44 |
+
// Get quote
|
45 |
+
$quote = $cart->getQuote();
|
46 |
+
Mage::log('Quote store: ' . $quote->getStore()->getCode() . ' id: ' . $quote->getStore()->getId(), Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
47 |
+
|
48 |
+
// Check config to see if extension functionality is enabled
|
49 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $quote->getStore()) != '1') {
|
50 |
+
return parent::_canUseMethod($method);
|
51 |
+
}
|
52 |
+
|
53 |
+
/** @var Mage_Payment_Model_Method_Abstract $method*/
|
54 |
+
// Check if New Subscription page is enabled, or if we should create subscriptions in checkout
|
55 |
+
if(Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page', $quote->getStore()) == '1') {
|
56 |
+
return parent::_canUseMethod($method);
|
57 |
+
}
|
58 |
+
else {
|
59 |
+
// We should create subs during checkout, and we are checking a payment method other than Authorize.Net CIM
|
60 |
+
// If other payment method being used, only allow this when there are no subscriptions to create
|
61 |
+
// Get quote helper
|
62 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
63 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
64 |
+
// Check if quote has any subscriptions in it
|
65 |
+
if(!$quoteHelper->hasProductsToCreateNewSubscription()) {
|
66 |
+
// Quote has no subscriptions,
|
67 |
+
// Check config setting for subscribe pro vault pay method
|
68 |
+
if (0 === strpos($method->getCode(), SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SUBSCRIBE_PRO_VAULT) &&
|
69 |
+
$method->getConfigData('active_non_subscription') != '1'
|
70 |
+
) {
|
71 |
+
// This is SP vault pay method and "Enabled for Non-Subscription" is set to No
|
72 |
+
return false;
|
73 |
+
}
|
74 |
+
else {
|
75 |
+
// Go through normal qualification process for payment methods
|
76 |
+
return parent::_canUseMethod($method);
|
77 |
+
}
|
78 |
+
}
|
79 |
+
else {
|
80 |
+
// Quote has subscriptions, only allow payment methods compatible with subscriptions
|
81 |
+
// Get helper
|
82 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
83 |
+
$platformHelper = Mage::helper('autoship/platform');
|
84 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
85 |
+
$apiHelper = Mage::helper('autoship/api');
|
86 |
+
$apiHelper->setConfigStore($quote->getStore());
|
87 |
+
// Lookup payment method code based on SP config
|
88 |
+
$configuredMethodCode = $platformHelper->getConfiguredPaymentMethodCode();
|
89 |
+
// Check for configured payment method code
|
90 |
+
if(0 === strpos($method->getCode(), $configuredMethodCode)) {
|
91 |
+
// This is the pay method which is allowed by Subscribe Pro config
|
92 |
+
// Run normal check
|
93 |
+
return parent::_canUseMethod($method);
|
94 |
+
}
|
95 |
+
else {
|
96 |
+
// This is some other payment method, not allowed when checking out and creating subscriptions
|
97 |
+
return false;
|
98 |
+
}
|
99 |
+
|
100 |
+
}
|
101 |
+
}
|
102 |
+
}
|
103 |
+
|
104 |
+
|
105 |
+
}
|
app/code/local/SFC/Autoship/Block/Mysubscriptions.php
ADDED
@@ -0,0 +1,117 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Mysubscriptions extends Mage_Core_Block_Template
|
19 |
+
{
|
20 |
+
private $_activeSubscriptions = null;
|
21 |
+
private $_inactiveSubscriptions = null;
|
22 |
+
|
23 |
+
protected function _prepareLayout()
|
24 |
+
{
|
25 |
+
parent::_prepareLayout();
|
26 |
+
}
|
27 |
+
|
28 |
+
public function getActiveSubscriptions()
|
29 |
+
{
|
30 |
+
if ($this->_activeSubscriptions == null) {
|
31 |
+
// Get current customer from session
|
32 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
33 |
+
// Query for subscriptions
|
34 |
+
$allSubscriptions = Mage::helper('autoship/platform')->getSubscriptions(
|
35 |
+
$customer,
|
36 |
+
array()
|
37 |
+
);
|
38 |
+
// Iterate and filter out Active subs, building inactive subs array
|
39 |
+
$this->_activeSubscriptions = array();
|
40 |
+
foreach ($allSubscriptions as $subscription) {
|
41 |
+
if ($subscription->getStatus() == 'Active' || $subscription->getStatus() == 'Failed' || $subscription->getStatus() == 'Retry') {
|
42 |
+
$this->_activeSubscriptions[] = $subscription;
|
43 |
+
}
|
44 |
+
}
|
45 |
+
|
46 |
+
// Sort subscriptions
|
47 |
+
usort($this->_activeSubscriptions, function($a, $b) {
|
48 |
+
// 1st compare by next order date reversed
|
49 |
+
$dateResult = (0 - strcmp($a->getData('next_order_date'), $b->getData('next_order_date')));
|
50 |
+
if($dateResult != 0) {
|
51 |
+
return $dateResult;
|
52 |
+
}
|
53 |
+
else {
|
54 |
+
// Next, compare by shipping address
|
55 |
+
return strcmp($a->getData('shipping_address_id'), $b->getData('shipping_address_id'));
|
56 |
+
}
|
57 |
+
});
|
58 |
+
|
59 |
+
}
|
60 |
+
|
61 |
+
return $this->_activeSubscriptions;
|
62 |
+
}
|
63 |
+
|
64 |
+
public function getInactiveSubscriptions()
|
65 |
+
{
|
66 |
+
if ($this->_inactiveSubscriptions == null) {
|
67 |
+
// Get current customer from session
|
68 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
69 |
+
// Query for subscriptions
|
70 |
+
$allSubscriptions = Mage::helper('autoship/platform')->getSubscriptions(
|
71 |
+
$customer,
|
72 |
+
array()
|
73 |
+
);
|
74 |
+
// Iterate and filter out Active subs, building inactive subs array
|
75 |
+
$this->_inactiveSubscriptions = array();
|
76 |
+
foreach ($allSubscriptions as $subscription) {
|
77 |
+
if ($subscription->getStatus() != 'Active' && $subscription->getStatus() != 'Failed' && $subscription->getStatus() != 'Retry') {
|
78 |
+
$this->_inactiveSubscriptions[] = $subscription;
|
79 |
+
}
|
80 |
+
}
|
81 |
+
|
82 |
+
// Sort subscriptions
|
83 |
+
usort($this->_inactiveSubscriptions, function($a, $b) {
|
84 |
+
// 1st compare by next order date reversed
|
85 |
+
$dateResult = (0 - strcmp($a->getData('next_order_date'), $b->getData('next_order_date')));
|
86 |
+
if($dateResult != 0) {
|
87 |
+
return $dateResult;
|
88 |
+
}
|
89 |
+
else {
|
90 |
+
// Next, compare by shipping address
|
91 |
+
return strcmp($a->getData('shipping_address_id'), $b->getData('shipping_address_id'));
|
92 |
+
}
|
93 |
+
});
|
94 |
+
|
95 |
+
}
|
96 |
+
|
97 |
+
return $this->_inactiveSubscriptions;
|
98 |
+
}
|
99 |
+
|
100 |
+
public function getActiveSubscriptionsCount()
|
101 |
+
{
|
102 |
+
return count($this->getActiveSubscriptions());
|
103 |
+
}
|
104 |
+
|
105 |
+
public function getIn_activeSubscriptionsCount()
|
106 |
+
{
|
107 |
+
return count($this->getInactiveSubscriptions());
|
108 |
+
}
|
109 |
+
|
110 |
+
public function getNextOrderDateMode()
|
111 |
+
{
|
112 |
+
$nextOrderDateMode = Mage::getStoreConfig('autoship_subscription/options/next_order_date_mode');
|
113 |
+
|
114 |
+
return $nextOrderDateMode;
|
115 |
+
}
|
116 |
+
|
117 |
+
}
|
app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription.php
ADDED
@@ -0,0 +1,110 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Block to display each individual subscription on My Subscriptions Page
|
20 |
+
*/
|
21 |
+
class SFC_Autoship_Block_Mysubscriptions_Subscription extends SFC_Autoship_Block_Subscription_Abstract
|
22 |
+
{
|
23 |
+
|
24 |
+
public function createChildSubscriptionBlock($templateName)
|
25 |
+
{
|
26 |
+
$block = $this->getLayout()->createBlock('autoship/mysubscriptions_subscription');
|
27 |
+
$block->setParentBlock($this);
|
28 |
+
$block->setTemplate('autoship/mysubscriptions/subscription/' . $templateName);
|
29 |
+
$block->setSubscription($this->getSubscription());
|
30 |
+
|
31 |
+
return $block;
|
32 |
+
}
|
33 |
+
|
34 |
+
/**
|
35 |
+
* Returns a formatted version of the shipping address for this subscription, ready for display on page
|
36 |
+
*
|
37 |
+
* @return string Formatted version of shipping address
|
38 |
+
*/
|
39 |
+
public function getFormattedShippingAddress()
|
40 |
+
{
|
41 |
+
$address = $this->getSubscription()->getShippingAddress();
|
42 |
+
$addressText = '';
|
43 |
+
foreach ($address->getStreet() as $curStreetComponent) {
|
44 |
+
$addressText .= ' ' . $curStreetComponent;
|
45 |
+
}
|
46 |
+
$addressText = substr($addressText, 1);
|
47 |
+
|
48 |
+
return $addressText;
|
49 |
+
}
|
50 |
+
|
51 |
+
/**
|
52 |
+
* Retrieve given media attribute label or product name if no label
|
53 |
+
*
|
54 |
+
* @param Mage_Catalog_Model_Product $product
|
55 |
+
* @param string $mediaAttributeCode
|
56 |
+
*
|
57 |
+
* @return string
|
58 |
+
*/
|
59 |
+
public function getImageLabel($product = null, $mediaAttributeCode = 'image')
|
60 |
+
{
|
61 |
+
if (is_null($product)) {
|
62 |
+
$product = $this->getProduct();
|
63 |
+
}
|
64 |
+
|
65 |
+
$label = $product->getData($mediaAttributeCode . '_label');
|
66 |
+
if (empty($label)) {
|
67 |
+
$label = $product->getName();
|
68 |
+
}
|
69 |
+
|
70 |
+
return $label;
|
71 |
+
}
|
72 |
+
|
73 |
+
public function showBillingAddressBlock()
|
74 |
+
{
|
75 |
+
/** @var SFC_Autoship_Helper_Platform $helperPlatform */
|
76 |
+
$helperPlatform = Mage::helper('autoship/platform');
|
77 |
+
// Check if using the SP Vault
|
78 |
+
if ($helperPlatform->getConfiguredPaymentMethodCode() == SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SUBSCRIBE_PRO_VAULT) {
|
79 |
+
return false;
|
80 |
+
}
|
81 |
+
else {
|
82 |
+
return true;
|
83 |
+
}
|
84 |
+
}
|
85 |
+
|
86 |
+
public function getNewCardUrl()
|
87 |
+
{
|
88 |
+
/** @var SFC_Autoship_Helper_Platform $helperPlatform */
|
89 |
+
$helperPlatform = Mage::helper('autoship/platform');
|
90 |
+
switch($helperPlatform->getConfiguredPaymentMethodCode())
|
91 |
+
{
|
92 |
+
default:
|
93 |
+
return '';
|
94 |
+
|
95 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_PARADOX_TRANSARMOR:
|
96 |
+
return $this->getUrl('transarmor/manage/');
|
97 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM_10XX:
|
98 |
+
return $this->getUrl('creditcards/index/new');
|
99 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM:
|
100 |
+
return $this->getUrl('creditcards/index/new');
|
101 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CYBERSOURCE:
|
102 |
+
return $this->getUrl('creditcards/index/new');
|
103 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SUBSCRIBE_PRO_VAULT:
|
104 |
+
return $this->getUrl('subscriptions/mycreditcards/new/');
|
105 |
+
|
106 |
+
}
|
107 |
+
}
|
108 |
+
|
109 |
+
}
|
110 |
+
|
app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription/Form/Billing.php
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Mysubscriptions_Subscription_Form_Billing extends SFC_Autoship_Block_Subscription_Form_Address
|
19 |
+
{
|
20 |
+
|
21 |
+
public function getSubmitUrl()
|
22 |
+
{
|
23 |
+
return $this->getUrl('autoship/mysubscriptions/billingsave');
|
24 |
+
}
|
25 |
+
|
26 |
+
}
|
app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription/Form/Payment.php
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Mysubscriptions_Subscription_Form_Payment extends SFC_Autoship_Block_Subscription_Form_Payment
|
19 |
+
{
|
20 |
+
|
21 |
+
public function getSubmitUrl()
|
22 |
+
{
|
23 |
+
return $this->getUrl('autoship/mysubscriptions/paymentsave');
|
24 |
+
}
|
25 |
+
|
26 |
+
}
|
app/code/local/SFC/Autoship/Block/Mysubscriptions/Subscription/Form/Shipping.php
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Mysubscriptions_Subscription_Form_Shipping extends SFC_Autoship_Block_Subscription_Form_Address
|
19 |
+
{
|
20 |
+
|
21 |
+
public function getSubmitUrl()
|
22 |
+
{
|
23 |
+
return $this->getUrl('autoship/mysubscriptions/shippingsave');
|
24 |
+
}
|
25 |
+
|
26 |
+
}
|
app/code/local/SFC/Autoship/Block/Newsubscription.php
ADDED
@@ -0,0 +1,55 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Newsubscription extends SFC_Autoship_Block_Subscription_Abstract
|
19 |
+
{
|
20 |
+
|
21 |
+
public function _prepareLayout()
|
22 |
+
{
|
23 |
+
// Set subscription on block
|
24 |
+
$this->setSubscription(Mage::getSingleton('customer/session')->getNewSubscription());
|
25 |
+
|
26 |
+
// Call parent
|
27 |
+
parent::_prepareLayout();
|
28 |
+
}
|
29 |
+
|
30 |
+
public function getSummary()
|
31 |
+
{
|
32 |
+
try {
|
33 |
+
$summary = Mage::helper('autoship/subscription')->estimateSubscriptionOrderTotals(
|
34 |
+
Mage::getSingleton('customer/session')->getCustomer(),
|
35 |
+
$this->getSubscription(),
|
36 |
+
$this->getPlatformProduct(),
|
37 |
+
$this->getProduct());
|
38 |
+
|
39 |
+
// Return summary data
|
40 |
+
return $summary;
|
41 |
+
}
|
42 |
+
catch (Exception $e) {
|
43 |
+
Mage::log('Error calculating estimated order summary: ' . $e->getMessage());
|
44 |
+
Mage::logException($e);
|
45 |
+
|
46 |
+
return 'Error estimating tax and shipping!';
|
47 |
+
}
|
48 |
+
}
|
49 |
+
|
50 |
+
public function getPostActionUrl()
|
51 |
+
{
|
52 |
+
return $this->getUrl('autoship/newsubscription/createpost');
|
53 |
+
}
|
54 |
+
|
55 |
+
}
|
app/code/local/SFC/Autoship/Block/Newsubscription/Form/Billing.php
ADDED
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Newsubscription_Form_Billing extends SFC_Autoship_Block_Subscription_Form_Address
|
19 |
+
{
|
20 |
+
|
21 |
+
public function _prepareLayout()
|
22 |
+
{
|
23 |
+
// Set subscription on block
|
24 |
+
$this->setSubscription(Mage::getSingleton('customer/session')->getNewSubscription());
|
25 |
+
|
26 |
+
// Call parent
|
27 |
+
parent::_prepareLayout();
|
28 |
+
}
|
29 |
+
|
30 |
+
public function getSubmitUrl()
|
31 |
+
{
|
32 |
+
return $this->getUrl('autoship/newsubscription/billingsave');
|
33 |
+
}
|
34 |
+
|
35 |
+
|
36 |
+
}
|
app/code/local/SFC/Autoship/Block/Newsubscription/Form/Payment.php
ADDED
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Newsubscription_Form_Payment extends SFC_Autoship_Block_Subscription_Form_Payment
|
19 |
+
{
|
20 |
+
|
21 |
+
public function _prepareLayout()
|
22 |
+
{
|
23 |
+
// Set subscription on block
|
24 |
+
$this->setSubscription(Mage::getSingleton('customer/session')->getNewSubscription());
|
25 |
+
|
26 |
+
// Call parent
|
27 |
+
parent::_prepareLayout();
|
28 |
+
}
|
29 |
+
|
30 |
+
public function getSubmitUrl()
|
31 |
+
{
|
32 |
+
return $this->getUrl('autoship/newsubscription/paymentsave');
|
33 |
+
}
|
34 |
+
|
35 |
+
}
|
app/code/local/SFC/Autoship/Block/Newsubscription/Form/Shipping.php
ADDED
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Newsubscription_Form_Shipping extends SFC_Autoship_Block_Subscription_Form_Address
|
19 |
+
{
|
20 |
+
|
21 |
+
public function _prepareLayout()
|
22 |
+
{
|
23 |
+
// Set subscription on block
|
24 |
+
$this->setSubscription(Mage::getSingleton('customer/session')->getNewSubscription());
|
25 |
+
|
26 |
+
// Call parent
|
27 |
+
parent::_prepareLayout();
|
28 |
+
}
|
29 |
+
|
30 |
+
public function getSubmitUrl()
|
31 |
+
{
|
32 |
+
return $this->getUrl('autoship/newsubscription/shippingsave');
|
33 |
+
}
|
34 |
+
|
35 |
+
}
|
app/code/local/SFC/Autoship/Block/Payment/Form/Cc.php
ADDED
@@ -0,0 +1,186 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Payment_Form_Cc extends Mage_Payment_Block_Form
|
19 |
+
{
|
20 |
+
protected function _construct()
|
21 |
+
{
|
22 |
+
parent::_construct();
|
23 |
+
$this->setTemplate('autoship/payment/form/cc.phtml');
|
24 |
+
}
|
25 |
+
|
26 |
+
/**
|
27 |
+
* Retrieve payment configuration object
|
28 |
+
*
|
29 |
+
* @return Mage_Payment_Model_Config
|
30 |
+
*/
|
31 |
+
protected function _getConfig()
|
32 |
+
{
|
33 |
+
return Mage::getSingleton('payment/config');
|
34 |
+
}
|
35 |
+
|
36 |
+
/**
|
37 |
+
* Retrieve available credit card types
|
38 |
+
*
|
39 |
+
* @return array
|
40 |
+
*/
|
41 |
+
public function getCcAvailableTypes()
|
42 |
+
{
|
43 |
+
return Mage::getModel('autoship/system_config_source_cctype')->getCcAvailableTypes();
|
44 |
+
}
|
45 |
+
|
46 |
+
/**
|
47 |
+
* Retrieve available credit card types in Subscribe Pro format
|
48 |
+
*
|
49 |
+
* @return array
|
50 |
+
*/
|
51 |
+
public function getCcAvailableTypesSubscribeProFormat()
|
52 |
+
{
|
53 |
+
return Mage::getModel('autoship/system_config_source_cctype')->getCcAvailableTypesSubscribeProFormat();
|
54 |
+
}
|
55 |
+
|
56 |
+
/**
|
57 |
+
* Retrieve credit card expire months
|
58 |
+
*
|
59 |
+
* @return array
|
60 |
+
*/
|
61 |
+
public function getCcMonths()
|
62 |
+
{
|
63 |
+
$months = $this->getData('cc_months');
|
64 |
+
if (is_null($months)) {
|
65 |
+
$months[0] = $this->__('Month');
|
66 |
+
$months = array_merge($months, $this->_getConfig()->getMonths());
|
67 |
+
$this->setData('cc_months', $months);
|
68 |
+
}
|
69 |
+
|
70 |
+
return $months;
|
71 |
+
}
|
72 |
+
|
73 |
+
/**
|
74 |
+
* Retrieve credit card expire years
|
75 |
+
*
|
76 |
+
* @return array
|
77 |
+
*/
|
78 |
+
public function getCcYears()
|
79 |
+
{
|
80 |
+
$years = $this->getData('cc_years');
|
81 |
+
if (is_null($years)) {
|
82 |
+
$years = $this->_getConfig()->getYears();
|
83 |
+
$years = array(0 => $this->__('Year')) + $years;
|
84 |
+
$this->setData('cc_years', $years);
|
85 |
+
}
|
86 |
+
|
87 |
+
return $years;
|
88 |
+
}
|
89 |
+
|
90 |
+
/**
|
91 |
+
* Retrieve additional information field value data from payment info object
|
92 |
+
*
|
93 |
+
* @param string $field
|
94 |
+
* @return mixed
|
95 |
+
*/
|
96 |
+
public function getAdditionalInfo($field)
|
97 |
+
{
|
98 |
+
return $this->htmlEscape($this->getMethod()->getInfoInstance()->getAdditionalInformation($field));
|
99 |
+
}
|
100 |
+
|
101 |
+
/**
|
102 |
+
* Retrive has verification configuration
|
103 |
+
*
|
104 |
+
* @return boolean
|
105 |
+
*/
|
106 |
+
public function hasVerification()
|
107 |
+
{
|
108 |
+
if ($this->getMethod()) {
|
109 |
+
$configData = $this->getMethod()->getConfigData('useccv');
|
110 |
+
if (is_null($configData)) {
|
111 |
+
return true;
|
112 |
+
}
|
113 |
+
|
114 |
+
return (bool)$configData;
|
115 |
+
}
|
116 |
+
|
117 |
+
return true;
|
118 |
+
}
|
119 |
+
|
120 |
+
public function useSaveCardCheckbox()
|
121 |
+
{
|
122 |
+
$checkoutSaveCardCheckbox = (bool) $this->getMethod()->getConfigData('checkout_save_card_checkbox');
|
123 |
+
$isGuestCheckout = ($this->getQuote()->getCheckoutMethod() == Mage_Sales_Model_Quote::CHECKOUT_METHOD_GUEST);
|
124 |
+
|
125 |
+
return $checkoutSaveCardCheckbox && !$isGuestCheckout && !$this->forceSaveCard();
|
126 |
+
}
|
127 |
+
|
128 |
+
public function forceSaveCard()
|
129 |
+
{
|
130 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
131 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
132 |
+
// Check if quote has any subscriptions in it
|
133 |
+
if($quoteHelper->hasProductsToCreateNewSubscription()) {
|
134 |
+
return true;
|
135 |
+
}
|
136 |
+
else {
|
137 |
+
return false;
|
138 |
+
}
|
139 |
+
}
|
140 |
+
|
141 |
+
/**
|
142 |
+
* Render block HTML
|
143 |
+
*
|
144 |
+
* @return string
|
145 |
+
*/
|
146 |
+
protected function _toHtml()
|
147 |
+
{
|
148 |
+
Mage::dispatchEvent('payment_form_block_to_html_before', array(
|
149 |
+
'block' => $this
|
150 |
+
));
|
151 |
+
|
152 |
+
return parent::_toHtml();
|
153 |
+
}
|
154 |
+
|
155 |
+
/**
|
156 |
+
* Retrieve checkout session model
|
157 |
+
*
|
158 |
+
* @return Mage_Checkout_Model_Session
|
159 |
+
*/
|
160 |
+
public function getCheckout()
|
161 |
+
{
|
162 |
+
if (empty($this->_checkout)) {
|
163 |
+
$this->_checkout = Mage::getSingleton('checkout/session');
|
164 |
+
}
|
165 |
+
return $this->_checkout;
|
166 |
+
}
|
167 |
+
|
168 |
+
/**
|
169 |
+
* Retrieve sales quote model
|
170 |
+
*
|
171 |
+
* @return Mage_Sales_Model_Quote
|
172 |
+
*/
|
173 |
+
public function getQuote()
|
174 |
+
{
|
175 |
+
if (empty($this->_quote)) {
|
176 |
+
$this->_quote = $this->getCheckout()->getQuote();
|
177 |
+
}
|
178 |
+
return $this->_quote;
|
179 |
+
}
|
180 |
+
|
181 |
+
public function getBillingAddress()
|
182 |
+
{
|
183 |
+
return $this->getQuote()->getBillingAddress();
|
184 |
+
}
|
185 |
+
|
186 |
+
}
|
app/code/local/SFC/Autoship/Block/Payment/Form/Cc/Saved.php
ADDED
@@ -0,0 +1,56 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Payment_Form_Cc_Saved extends SFC_Autoship_Block_Payment_Form_Cc
|
19 |
+
{
|
20 |
+
|
21 |
+
protected function _construct()
|
22 |
+
{
|
23 |
+
parent::_construct();
|
24 |
+
$this->setTemplate('autoship/payment/form/cc_saved.phtml');
|
25 |
+
}
|
26 |
+
|
27 |
+
/**
|
28 |
+
* @return SFC_Autoship_Model_Payment_Profile
|
29 |
+
*/
|
30 |
+
public function getSavedPaymentProfile()
|
31 |
+
{
|
32 |
+
/** @var SFC_Autoship_Model_Payment_Method $method */
|
33 |
+
$method = $this->getMethod();
|
34 |
+
$paymentProfile = $method->getSavedPaymentProfile();
|
35 |
+
|
36 |
+
return $paymentProfile;
|
37 |
+
}
|
38 |
+
|
39 |
+
public function getObscuredCardNumber()
|
40 |
+
{
|
41 |
+
$paymentProfile = $this->getSavedPaymentProfile();
|
42 |
+
|
43 |
+
return $paymentProfile->getData('creditcard_first_digits') . 'XXXXXX' . $paymentProfile->getData('creditcard_last_digits');
|
44 |
+
}
|
45 |
+
|
46 |
+
public function getMagentoCardType()
|
47 |
+
{
|
48 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
49 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
50 |
+
// Get payment profile
|
51 |
+
$paymentProfile = $this->getSavedPaymentProfile();
|
52 |
+
|
53 |
+
return $vaultHelper->mapSubscribeProCardTypeToMagento($paymentProfile->getData('creditcard_type'), false);
|
54 |
+
}
|
55 |
+
|
56 |
+
}
|
app/code/local/SFC/Autoship/Block/Payment/Info/Cc.php
ADDED
@@ -0,0 +1,112 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Credit card generic payment info
|
20 |
+
*/
|
21 |
+
class SFC_Autoship_Block_Payment_Info_Cc extends Mage_Payment_Block_Info
|
22 |
+
{
|
23 |
+
/**
|
24 |
+
* Retrieve credit card type name
|
25 |
+
*
|
26 |
+
* @return string
|
27 |
+
*/
|
28 |
+
public function getCcTypeName()
|
29 |
+
{
|
30 |
+
$types = Mage::getSingleton('payment/config')->getCcTypes();
|
31 |
+
$ccType = $this->getInfo()->getCcType();
|
32 |
+
if (isset($types[$ccType])) {
|
33 |
+
return $types[$ccType];
|
34 |
+
}
|
35 |
+
|
36 |
+
return (empty($ccType)) ? Mage::helper('payment')->__('N/A') : $ccType;
|
37 |
+
}
|
38 |
+
|
39 |
+
/**
|
40 |
+
* Whether current payment method has credit card expiration info
|
41 |
+
*
|
42 |
+
* @return bool
|
43 |
+
*/
|
44 |
+
public function hasCcExpDate()
|
45 |
+
{
|
46 |
+
return (int)$this->getInfo()->getCcExpMonth() || (int)$this->getInfo()->getCcExpYear();
|
47 |
+
}
|
48 |
+
|
49 |
+
/**
|
50 |
+
* Retrieve CC expiration month
|
51 |
+
*
|
52 |
+
* @return string
|
53 |
+
*/
|
54 |
+
public function getCcExpMonth()
|
55 |
+
{
|
56 |
+
$month = $this->getInfo()->getCcExpMonth();
|
57 |
+
if ($month < 10) {
|
58 |
+
$month = '0' . $month;
|
59 |
+
}
|
60 |
+
|
61 |
+
return $month;
|
62 |
+
}
|
63 |
+
|
64 |
+
/**
|
65 |
+
* Retrieve CC expiration date
|
66 |
+
*
|
67 |
+
* @return Zend_Date
|
68 |
+
*/
|
69 |
+
public function getCcExpDate()
|
70 |
+
{
|
71 |
+
$date = Mage::app()->getLocale()->date(0);
|
72 |
+
$date->setYear($this->getInfo()->getCcExpYear());
|
73 |
+
$date->setMonth($this->getInfo()->getCcExpMonth());
|
74 |
+
|
75 |
+
return $date;
|
76 |
+
}
|
77 |
+
|
78 |
+
/**
|
79 |
+
* Prepare credit card related payment info
|
80 |
+
*
|
81 |
+
* @param Varien_Object|array $transport
|
82 |
+
* @return Varien_Object
|
83 |
+
*/
|
84 |
+
protected function _prepareSpecificInformation($transport = null)
|
85 |
+
{
|
86 |
+
if (null !== $this->_paymentSpecificInformation) {
|
87 |
+
return $this->_paymentSpecificInformation;
|
88 |
+
}
|
89 |
+
$transport = parent::_prepareSpecificInformation($transport);
|
90 |
+
$data = array();
|
91 |
+
if ($ccType = $this->getCcTypeName()) {
|
92 |
+
$data[Mage::helper('payment')->__('Credit Card Type')] = $ccType;
|
93 |
+
}
|
94 |
+
if ($this->getInfo()->getCcLast4()) {
|
95 |
+
$data[Mage::helper('payment')->__('Credit Card Number')] = sprintf('xxxx-%s', $this->getInfo()->getCcLast4());
|
96 |
+
}
|
97 |
+
|
98 |
+
return $transport->setData(array_merge($data, $transport->getData()));
|
99 |
+
}
|
100 |
+
|
101 |
+
/**
|
102 |
+
* Format year/month on the credit card
|
103 |
+
*
|
104 |
+
* @param string $year
|
105 |
+
* @param string $month
|
106 |
+
* @return string
|
107 |
+
*/
|
108 |
+
protected function _formatCardDate($year, $month)
|
109 |
+
{
|
110 |
+
return sprintf('%s/%s', sprintf('%02d', $month), $year);
|
111 |
+
}
|
112 |
+
}
|
app/code/local/SFC/Autoship/Block/Payment/Profile/Edit.php
ADDED
@@ -0,0 +1,201 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Payment_Profile_Edit extends Mage_Adminhtml_Block_Template
|
19 |
+
{
|
20 |
+
|
21 |
+
protected function _prepareLayout()
|
22 |
+
{
|
23 |
+
parent::_prepareLayout();
|
24 |
+
}
|
25 |
+
|
26 |
+
public function getEnvironmentKey()
|
27 |
+
{
|
28 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
29 |
+
$platformHelper = Mage::helper('autoship/platform');
|
30 |
+
// Lookup payment method code based on SP config
|
31 |
+
$accountConfig = $platformHelper->getAccountConfig();
|
32 |
+
// Get env key
|
33 |
+
$environmentKey = $accountConfig['transparent_redirect_environment_key'];
|
34 |
+
|
35 |
+
return $environmentKey;
|
36 |
+
}
|
37 |
+
|
38 |
+
public function getIsNewProfile()
|
39 |
+
{
|
40 |
+
return !(strlen($this->getCimProfile()->getId()));
|
41 |
+
}
|
42 |
+
|
43 |
+
public function getTitle()
|
44 |
+
{
|
45 |
+
if ($this->getIsNewProfile()) {
|
46 |
+
// Creating a new profile
|
47 |
+
return ' Enter New Credit Card ';
|
48 |
+
}
|
49 |
+
else {
|
50 |
+
// Editing an existing profile
|
51 |
+
return ' Edit Saved Credit Card XXXX' . $this->getData('cim_profile')->getData('creditcard_last_digits');
|
52 |
+
}
|
53 |
+
}
|
54 |
+
|
55 |
+
public function getRedirectUrl()
|
56 |
+
{
|
57 |
+
return $this->getUrl('subscriptions/mycreditcards/redirect/', array('_secure' => true));
|
58 |
+
}
|
59 |
+
|
60 |
+
public function getRedirectPostUrl()
|
61 |
+
{
|
62 |
+
return 'https://core.spreedly.com/v1/payment_methods';
|
63 |
+
}
|
64 |
+
|
65 |
+
public function getBackUrl()
|
66 |
+
{
|
67 |
+
return $this->getUrl('subscriptions/mycreditcards/', array('_secure' => true));
|
68 |
+
}
|
69 |
+
|
70 |
+
public function getSaveUrl()
|
71 |
+
{
|
72 |
+
return $this->getUrl('subscriptions/mycreditcards/save/', array('_secure' => true));
|
73 |
+
}
|
74 |
+
|
75 |
+
/**
|
76 |
+
* Retrieve payment configuration object
|
77 |
+
*
|
78 |
+
* @return Mage_Payment_Model_Config
|
79 |
+
*/
|
80 |
+
protected function _getConfig()
|
81 |
+
{
|
82 |
+
return Mage::getSingleton('payment/config');
|
83 |
+
}
|
84 |
+
|
85 |
+
/**
|
86 |
+
* Retrieve credit card expire months
|
87 |
+
*
|
88 |
+
* @return array
|
89 |
+
*/
|
90 |
+
public function getCcMonths()
|
91 |
+
{
|
92 |
+
$months = $this->getData('cc_months');
|
93 |
+
$output = array();
|
94 |
+
if (is_null($months)) {
|
95 |
+
$months[0] = $this->__('Month');
|
96 |
+
$months = array_merge($months, $this->_getConfig()->getMonths());
|
97 |
+
foreach ($months as $k => $v) {
|
98 |
+
if (strlen($k) == 1 && $k != 0) {
|
99 |
+
$value = '0' . $k;
|
100 |
+
$output[$value] = $v;
|
101 |
+
}
|
102 |
+
elseif ($v != 'Month') {
|
103 |
+
$output[$k] = $v;
|
104 |
+
}
|
105 |
+
}
|
106 |
+
$this->setData('cc_months', $months);
|
107 |
+
}
|
108 |
+
|
109 |
+
return $output;
|
110 |
+
}
|
111 |
+
|
112 |
+
/**
|
113 |
+
* Retrieve credit card expire years
|
114 |
+
*
|
115 |
+
* @return array
|
116 |
+
*/
|
117 |
+
public function getCcYears()
|
118 |
+
{
|
119 |
+
$years = $this->getData('cc_years');
|
120 |
+
if (is_null($years)) {
|
121 |
+
$years = $this->_getConfig()->getYears();
|
122 |
+
$this->setData('cc_years', $years);
|
123 |
+
}
|
124 |
+
|
125 |
+
return $years;
|
126 |
+
}
|
127 |
+
|
128 |
+
public function getCcTypeInCyberSourceFormat()
|
129 |
+
{
|
130 |
+
$ccType = $this->getCimProfile()->getData('cc_type');
|
131 |
+
if(strlen($ccType)) {
|
132 |
+
return Mage::helper('sfc_cybersource/gateway')->mapMagentoCardTypeToCyberSource($ccType);
|
133 |
+
}
|
134 |
+
else {
|
135 |
+
return '';
|
136 |
+
}
|
137 |
+
}
|
138 |
+
|
139 |
+
/**
|
140 |
+
* Retrieve information from payment configuration
|
141 |
+
*
|
142 |
+
* @param string $field
|
143 |
+
* @param int|string|null|Mage_Core_Model_Store $storeId
|
144 |
+
*
|
145 |
+
* @return mixed
|
146 |
+
*/
|
147 |
+
public function getConfigData($field, $storeId = null)
|
148 |
+
{
|
149 |
+
if (null === $storeId) {
|
150 |
+
$storeId = Mage::app()->getStore();
|
151 |
+
}
|
152 |
+
$path = 'payment/' . SFC_Autoship_Model_Payment_Method::METHOD_CODE . '/' . $field;
|
153 |
+
|
154 |
+
return Mage::getStoreConfig($path, $storeId);
|
155 |
+
}
|
156 |
+
|
157 |
+
/**
|
158 |
+
* Retrieve use verification configuration
|
159 |
+
*
|
160 |
+
* @return boolean
|
161 |
+
*/
|
162 |
+
public function useVerification()
|
163 |
+
{
|
164 |
+
if (!$this->getIsNewProfile()) {
|
165 |
+
return false;
|
166 |
+
}
|
167 |
+
|
168 |
+
$configData = $this->getConfigData('useccv');
|
169 |
+
if (is_null($configData)) {
|
170 |
+
return true;
|
171 |
+
}
|
172 |
+
|
173 |
+
return (bool)$configData;
|
174 |
+
}
|
175 |
+
|
176 |
+
/**
|
177 |
+
* Retrieve available credit card types
|
178 |
+
*
|
179 |
+
* @return array
|
180 |
+
*/
|
181 |
+
public function getCcAvailableTypes()
|
182 |
+
{
|
183 |
+
return Mage::getModel('autoship/system_config_source_cctype')->getCcAvailableTypes();
|
184 |
+
}
|
185 |
+
|
186 |
+
/**
|
187 |
+
* Retrieve available credit card types in Subscribe Pro format
|
188 |
+
*
|
189 |
+
* @return array
|
190 |
+
*/
|
191 |
+
public function getCcAvailableTypesSubscribeProFormat()
|
192 |
+
{
|
193 |
+
return Mage::getModel('autoship/system_config_source_cctype')->getCcAvailableTypesSubscribeProFormat();
|
194 |
+
}
|
195 |
+
|
196 |
+
public function getLocaleLanguage()
|
197 |
+
{
|
198 |
+
return locale_get_primary_language(Mage::app()->getLocale()->getLocaleCode());
|
199 |
+
}
|
200 |
+
|
201 |
+
}
|
app/code/local/SFC/Autoship/Block/Payment/Profile/Grid.php
ADDED
@@ -0,0 +1,37 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Payment_Profile_Grid extends Mage_Adminhtml_Block_Template
|
19 |
+
{
|
20 |
+
|
21 |
+
protected function _prepareLayout()
|
22 |
+
{
|
23 |
+
parent::_prepareLayout();
|
24 |
+
}
|
25 |
+
|
26 |
+
public function getPaymentProfiles()
|
27 |
+
{
|
28 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
29 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
30 |
+
|
31 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
32 |
+
$collection = $vaultHelper->getPaymentProfilesForCustomer($customer->getData('email'));
|
33 |
+
|
34 |
+
return $collection;
|
35 |
+
}
|
36 |
+
|
37 |
+
}
|
app/code/local/SFC/Autoship/Block/Product/Subscribe.php
ADDED
@@ -0,0 +1,44 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Product page Subscribe block
|
20 |
+
*/
|
21 |
+
class SFC_Autoship_Block_Product_Subscribe extends SFC_Autoship_Block_Product_View
|
22 |
+
{
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Return eligible subscription intervals for this product
|
26 |
+
*
|
27 |
+
* @return array Array of eligible subscription interval strings (for example: One Month, Two Months, etc)
|
28 |
+
*/
|
29 |
+
public function getIntervals()
|
30 |
+
{
|
31 |
+
return $this->getPlatformProduct()->getIntervals();
|
32 |
+
}
|
33 |
+
|
34 |
+
/**
|
35 |
+
* Return the discount text for display on product page
|
36 |
+
*
|
37 |
+
* @return string Discount text for product page
|
38 |
+
*/
|
39 |
+
public function getDiscountText()
|
40 |
+
{
|
41 |
+
return Mage::helper('autoship/subscription')->getSubscriptionPriceText($this->getPlatformProduct(), $this->getProduct(), $this->getProductDefaultQty($this->getProduct()));
|
42 |
+
}
|
43 |
+
|
44 |
+
}
|
app/code/local/SFC/Autoship/Block/Product/View.php
ADDED
@@ -0,0 +1,93 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Product View block - Override the Magento catalog block
|
20 |
+
*
|
21 |
+
*/
|
22 |
+
class SFC_Autoship_Block_Product_View extends Mage_Catalog_Block_Product_View
|
23 |
+
{
|
24 |
+
private $_platformProduct = null;
|
25 |
+
|
26 |
+
/**
|
27 |
+
* Return true if product has options
|
28 |
+
*
|
29 |
+
* @return bool
|
30 |
+
*/
|
31 |
+
public function hasOptions()
|
32 |
+
{
|
33 |
+
if ($this->isProductAutoshipEligible()) {
|
34 |
+
return true;
|
35 |
+
}
|
36 |
+
else {
|
37 |
+
return parent::hasOptions();
|
38 |
+
}
|
39 |
+
}
|
40 |
+
|
41 |
+
/**
|
42 |
+
* Return the product profile for the current product
|
43 |
+
*
|
44 |
+
* @return SFC_Autoship_Model_Platform_Product The Magento product profile entity object for the current product
|
45 |
+
*/
|
46 |
+
public function getPlatformProduct()
|
47 |
+
{
|
48 |
+
if ($this->_platformProduct == null) {
|
49 |
+
$this->_platformProduct = Mage::helper('autoship/platform')->getPlatformProduct($this->getProduct());
|
50 |
+
}
|
51 |
+
|
52 |
+
return $this->_platformProduct;
|
53 |
+
}
|
54 |
+
|
55 |
+
/**
|
56 |
+
* Indicates whether this product is eligible for autoship or not
|
57 |
+
*
|
58 |
+
* @return bool
|
59 |
+
*/
|
60 |
+
public function isProductAutoshipEligible()
|
61 |
+
{
|
62 |
+
// Get product
|
63 |
+
$product = $this->getProduct();
|
64 |
+
// Lookup whether product enabled / disabled for subscription
|
65 |
+
$isProductEnabled = Mage::helper('autoship/product')->isAvailableForSubscription($product);
|
66 |
+
|
67 |
+
return $isProductEnabled;
|
68 |
+
}
|
69 |
+
|
70 |
+
/**
|
71 |
+
* Return the price for purchasing the current product as a one time purchase, optionally format the returned price
|
72 |
+
*
|
73 |
+
* @param bool $formatted True to return the price formatted, false to return the raw price number
|
74 |
+
* @return string Price of product, either formatted or as a raw number
|
75 |
+
*/
|
76 |
+
public function getOneTimePurchasePrice($formatted = false)
|
77 |
+
{
|
78 |
+
return Mage::helper('autoship/subscription')
|
79 |
+
->getOneTimePurchasePrice($this->getProduct(), $this->getProductDefaultQty($this->getProduct()), $formatted);
|
80 |
+
}
|
81 |
+
|
82 |
+
/**
|
83 |
+
* Return the price for purchasing the product with a subscription, optionally format the returned price
|
84 |
+
*
|
85 |
+
* @param bool $formatted True to return the price formatted, false to return the raw price number
|
86 |
+
* @return string Price of product, either formatted or as a raw number
|
87 |
+
*/
|
88 |
+
public function getSubscriptionPrice($formatted = false)
|
89 |
+
{
|
90 |
+
return Mage::helper('autoship/subscription')->getSubscriptionPrice($this->getPlatformProduct(), $this->getProduct(), $this->getProductDefaultQty($this->getProduct()), $formatted);
|
91 |
+
}
|
92 |
+
|
93 |
+
}
|
app/code/local/SFC/Autoship/Block/Product/View/Type/Grouped/Subscribe.php
ADDED
@@ -0,0 +1,125 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Product page Subscribe block
|
20 |
+
*/
|
21 |
+
class SFC_Autoship_Block_Product_View_Type_Grouped_Subscribe extends Mage_Core_Block_Template
|
22 |
+
{
|
23 |
+
private $_platformProduct = null;
|
24 |
+
private $_product = null;
|
25 |
+
|
26 |
+
public function setProduct($product)
|
27 |
+
{
|
28 |
+
$this->_product = $product;
|
29 |
+
|
30 |
+
return $this;
|
31 |
+
}
|
32 |
+
|
33 |
+
public function getProduct()
|
34 |
+
{
|
35 |
+
return $this->_product;
|
36 |
+
}
|
37 |
+
|
38 |
+
/**
|
39 |
+
* Return true if product has options
|
40 |
+
*
|
41 |
+
* @return bool
|
42 |
+
*/
|
43 |
+
public function hasOptions()
|
44 |
+
{
|
45 |
+
if ($this->isProductAutoshipEligible()) {
|
46 |
+
return true;
|
47 |
+
}
|
48 |
+
else {
|
49 |
+
return parent::hasOptions();
|
50 |
+
}
|
51 |
+
}
|
52 |
+
|
53 |
+
/**
|
54 |
+
* Return the product profile for the current product
|
55 |
+
*
|
56 |
+
* @return SFC_Autoship_Model_Platform_Product The Magento product profile entity object for the current product
|
57 |
+
*/
|
58 |
+
public function getPlatformProduct()
|
59 |
+
{
|
60 |
+
if ($this->_platformProduct == null) {
|
61 |
+
$this->_platformProduct = Mage::helper('autoship/platform')->getPlatformProduct($this->getProduct());
|
62 |
+
}
|
63 |
+
|
64 |
+
return $this->_platformProduct;
|
65 |
+
}
|
66 |
+
|
67 |
+
/**
|
68 |
+
* Indicates whether this product is eligible for autoship or not
|
69 |
+
*
|
70 |
+
* @return bool
|
71 |
+
*/
|
72 |
+
public function isProductAutoshipEligible()
|
73 |
+
{
|
74 |
+
// Get product
|
75 |
+
$product = $this->getProduct();
|
76 |
+
// Lookup whether product enabled / disabled for subscription
|
77 |
+
$isProductEnabled = Mage::helper('autoship/product')->isAvailableForSubscription($product);
|
78 |
+
|
79 |
+
return $isProductEnabled;
|
80 |
+
}
|
81 |
+
|
82 |
+
/**
|
83 |
+
* Return the price for purchasing the current product as a one time purchase, optionally format the returned price
|
84 |
+
*
|
85 |
+
* @param bool $formatted True to return the price formatted, false to return the raw price number
|
86 |
+
* @return string Price of product, either formatted or as a raw number
|
87 |
+
*/
|
88 |
+
public function getOneTimePurchasePrice($formatted = false)
|
89 |
+
{
|
90 |
+
return Mage::helper('autoship/subscription')
|
91 |
+
->getOneTimePurchasePrice($this->getProduct(), $this->getProductDefaultQty($this->getProduct()), $formatted);
|
92 |
+
}
|
93 |
+
|
94 |
+
/**
|
95 |
+
* Return the price for purchasing the product with a subscription, optionally format the returned price
|
96 |
+
*
|
97 |
+
* @param bool $formatted True to return the price formatted, false to return the raw price number
|
98 |
+
* @return string Price of product, either formatted or as a raw number
|
99 |
+
*/
|
100 |
+
public function getSubscriptionPrice($formatted = false)
|
101 |
+
{
|
102 |
+
return Mage::helper('autoship/subscription')->getSubscriptionPrice($this->getPlatformProduct(), $this->getProduct(), $this->getProductDefaultQty($this->getProduct()), $formatted);
|
103 |
+
}
|
104 |
+
|
105 |
+
/**
|
106 |
+
* Return eligible subscription intervals for this product
|
107 |
+
*
|
108 |
+
* @return array Array of eligible subscription interval strings (for example: One Month, Two Months, etc)
|
109 |
+
*/
|
110 |
+
public function getIntervals()
|
111 |
+
{
|
112 |
+
return $this->getPlatformProduct()->getIntervals();
|
113 |
+
}
|
114 |
+
|
115 |
+
/**
|
116 |
+
* Return the discount text for display on product page
|
117 |
+
*
|
118 |
+
* @return string Discount text for product page
|
119 |
+
*/
|
120 |
+
public function getDiscountText()
|
121 |
+
{
|
122 |
+
return Mage::helper('autoship/subscription')->getSubscriptionPriceText($this->getPlatformProduct(), $this->getProduct(), $this->getProductDefaultQty($this->getProduct()));
|
123 |
+
}
|
124 |
+
|
125 |
+
}
|
app/code/local/SFC/Autoship/Block/Subscription/Abstract.php
ADDED
@@ -0,0 +1,135 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Abstract block, acts as base class for any block that displays 1 subscription
|
20 |
+
*/
|
21 |
+
class SFC_Autoship_Block_Subscription_Abstract extends Mage_Core_Block_Template
|
22 |
+
{
|
23 |
+
private $_subscription = null;
|
24 |
+
|
25 |
+
/**
|
26 |
+
* @param SFC_Autoship_Model_Subscription $subscription
|
27 |
+
* @return $this
|
28 |
+
*/
|
29 |
+
public function setSubscription(SFC_Autoship_Model_Subscription $subscription)
|
30 |
+
{
|
31 |
+
$this->_subscription = $subscription;
|
32 |
+
|
33 |
+
return $this;
|
34 |
+
}
|
35 |
+
|
36 |
+
/**
|
37 |
+
* @return null|SFC_Autoship_Model_Subscription
|
38 |
+
*/
|
39 |
+
public function getSubscription()
|
40 |
+
{
|
41 |
+
return $this->_subscription;
|
42 |
+
}
|
43 |
+
|
44 |
+
/**
|
45 |
+
* Get the product for this subscription
|
46 |
+
*
|
47 |
+
* @return Mage_Catalog_Model_Product The Magento product for this subscription
|
48 |
+
*/
|
49 |
+
public function getProduct()
|
50 |
+
{
|
51 |
+
return $this->getSubscription()->getProduct();
|
52 |
+
}
|
53 |
+
|
54 |
+
/**
|
55 |
+
* Get the product profile for this subscription
|
56 |
+
*
|
57 |
+
* @return SFC_Autoship_Model_Platform_Product The product product model object for this subscription
|
58 |
+
*/
|
59 |
+
public function getPlatformProduct()
|
60 |
+
{
|
61 |
+
return $this->getSubscription()->getPlatformProduct();
|
62 |
+
}
|
63 |
+
|
64 |
+
/**
|
65 |
+
* Return eligible subscription intervals for the subscription product
|
66 |
+
*
|
67 |
+
* @return array Array of eligible subscription interval strings (for example: One Month, Two Months, etc)
|
68 |
+
*/
|
69 |
+
public function getIntervals()
|
70 |
+
{
|
71 |
+
// Lookup intervals from product and subscription
|
72 |
+
$productIntervals = $this->getPlatformProduct()->getData('intervals');
|
73 |
+
$subscriptionInterval = $this->getSubscription()->getData('interval');
|
74 |
+
// Add product interval if not present
|
75 |
+
if (!is_array($productIntervals)) {
|
76 |
+
return array($subscriptionInterval);
|
77 |
+
}
|
78 |
+
else if (!in_array($subscriptionInterval, $productIntervals)) {
|
79 |
+
return array_merge(array($subscriptionInterval), $productIntervals);
|
80 |
+
}
|
81 |
+
else {
|
82 |
+
return $productIntervals;
|
83 |
+
}
|
84 |
+
}
|
85 |
+
|
86 |
+
/**
|
87 |
+
* Return the price for purchasing the current product as a one time pruchase, optionally format the returned price
|
88 |
+
*
|
89 |
+
* @param bool $formatted True to return the price formatted, false to return the raw price number
|
90 |
+
* @return string Price of product, either formatted or as a raw number
|
91 |
+
*/
|
92 |
+
public function getOneTimePurchasePrice($formatted = false)
|
93 |
+
{
|
94 |
+
return Mage::helper('autoship/subscription')
|
95 |
+
->getOneTimePurchasePrice($this->getProduct(), $this->getSubscription()->getQty(), $formatted);
|
96 |
+
}
|
97 |
+
|
98 |
+
/**
|
99 |
+
* Return the price for purchasing the product with a subscription, optionally format the returned price
|
100 |
+
*
|
101 |
+
* @param bool $formatted True to return the price formatted, false to return the raw price number
|
102 |
+
* @return string Price of product, either formatted or as a raw number
|
103 |
+
*/
|
104 |
+
public function getSubscriptionPrice($formatted = false)
|
105 |
+
{
|
106 |
+
return Mage::helper('autoship/subscription')
|
107 |
+
->getSubscriptionPrice($this->getPlatformProduct(), $this->getProduct(), $this->getSubscription()->getQty(), $formatted);
|
108 |
+
}
|
109 |
+
|
110 |
+
/**
|
111 |
+
* Return the price for purchasing the product with a subscription, formatted and with text indicating the discount amount
|
112 |
+
*
|
113 |
+
* @return string Price of product, formatted and with text indicating the discount
|
114 |
+
*/
|
115 |
+
public function getSubscriptionPriceText()
|
116 |
+
{
|
117 |
+
return Mage::helper('autoship/subscription')
|
118 |
+
->getSubscriptionPriceText($this->getPlatformProduct(), $this->getProduct(), $this->getSubscription()->getQty());
|
119 |
+
}
|
120 |
+
|
121 |
+
public function useCouponCode()
|
122 |
+
{
|
123 |
+
$allowCouponConfig = Mage::getStoreConfig('autoship_subscription/options/allow_coupon');
|
124 |
+
|
125 |
+
return ($allowCouponConfig == 1);
|
126 |
+
}
|
127 |
+
|
128 |
+
public function getNextOrderDateMode()
|
129 |
+
{
|
130 |
+
$nextOrderDateMode = Mage::getStoreConfig('autoship_subscription/options/next_order_date_mode');
|
131 |
+
|
132 |
+
return $nextOrderDateMode;
|
133 |
+
}
|
134 |
+
|
135 |
+
}
|
app/code/local/SFC/Autoship/Block/Subscription/Form/Address.php
ADDED
@@ -0,0 +1,162 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Subscription_Form_Address extends SFC_Autoship_Block_Subscription_Abstract
|
19 |
+
{
|
20 |
+
|
21 |
+
protected $_customer;
|
22 |
+
protected $_countryCollection;
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Get logged in customer
|
26 |
+
*
|
27 |
+
* @return Mage_Customer_Model_Customer
|
28 |
+
*/
|
29 |
+
public function getCustomer()
|
30 |
+
{
|
31 |
+
if (empty($this->_customer)) {
|
32 |
+
$this->_customer = Mage::getSingleton('customer/session')->getCustomer();
|
33 |
+
}
|
34 |
+
|
35 |
+
return $this->_customer;
|
36 |
+
}
|
37 |
+
|
38 |
+
public function isCustomerLoggedIn()
|
39 |
+
{
|
40 |
+
return Mage::getSingleton('customer/session')->isLoggedIn();
|
41 |
+
}
|
42 |
+
|
43 |
+
/**
|
44 |
+
* Return Sales Quote Address model (shipping address)
|
45 |
+
*
|
46 |
+
* @param $type
|
47 |
+
* @return Mage_Sales_Model_Quote_Address
|
48 |
+
*/
|
49 |
+
public function getAddress($type = 'billing')
|
50 |
+
{
|
51 |
+
switch ($type) {
|
52 |
+
case 'billing':
|
53 |
+
default:
|
54 |
+
if ($this->getSubscription() != null && $this->getSubscription()->getData('billing_address_id')) {
|
55 |
+
return $this->getSubscription()->getBillingAddress();
|
56 |
+
}
|
57 |
+
else {
|
58 |
+
return $this->getCustomer()->getDefaultBillingAddress();
|
59 |
+
}
|
60 |
+
|
61 |
+
case 'shipping':
|
62 |
+
if ($this->getSubscription() != null && $this->getSubscription()->getData('shipping_address_id')) {
|
63 |
+
return $this->getSubscription()->getShippingAddress();
|
64 |
+
}
|
65 |
+
else {
|
66 |
+
return $this->getCustomer()->getDefaultShippingAddress();
|
67 |
+
}
|
68 |
+
}
|
69 |
+
}
|
70 |
+
|
71 |
+
public function getCountryCollection()
|
72 |
+
{
|
73 |
+
if (!$this->_countryCollection) {
|
74 |
+
$this->_countryCollection = Mage::getSingleton('directory/country')->getResourceCollection()
|
75 |
+
->loadByStore();
|
76 |
+
}
|
77 |
+
|
78 |
+
return $this->_countryCollection;
|
79 |
+
}
|
80 |
+
|
81 |
+
public function customerHasAddresses()
|
82 |
+
{
|
83 |
+
return count($this->getCustomer()->getAddresses());
|
84 |
+
}
|
85 |
+
|
86 |
+
public function getAddressesHtmlSelect($type, $id = null)
|
87 |
+
{
|
88 |
+
if ($this->isCustomerLoggedIn()) {
|
89 |
+
$options = array();
|
90 |
+
foreach ($this->getCustomer()->getAddresses() as $address) {
|
91 |
+
$options[] = array(
|
92 |
+
'value' => $address->getId(),
|
93 |
+
'label' => $address->format('oneline')
|
94 |
+
);
|
95 |
+
}
|
96 |
+
|
97 |
+
$addressId = $this->getAddress($type)->getId();
|
98 |
+
|
99 |
+
$select = $this->getLayout()->createBlock('core/html_select')
|
100 |
+
->setName($type . '_address_id')
|
101 |
+
->setId($type . '-address-select-' . $id)
|
102 |
+
->setClass($type . '-address-select')
|
103 |
+
->setValue($addressId)
|
104 |
+
->setOptions($options);
|
105 |
+
|
106 |
+
$select->addOption('', Mage::helper('checkout')->__('New Address'));
|
107 |
+
|
108 |
+
return $select->getHtml();
|
109 |
+
}
|
110 |
+
|
111 |
+
return '';
|
112 |
+
}
|
113 |
+
|
114 |
+
public function getCountryHtmlSelect($type, $id = null)
|
115 |
+
{
|
116 |
+
if($this->getAddress($type)) {
|
117 |
+
$countryId = $this->getAddress($type)->getCountryId();
|
118 |
+
}
|
119 |
+
if (is_null($countryId)) {
|
120 |
+
$countryId = Mage::helper('core')->getDefaultCountry();
|
121 |
+
}
|
122 |
+
$select = $this->getLayout()->createBlock('core/html_select')
|
123 |
+
->setName($type . '[country_id]')
|
124 |
+
->setId($id . ':' . $type . ':country_id')
|
125 |
+
->setTitle(Mage::helper('checkout')->__('Country'))
|
126 |
+
->setClass('validate-select')
|
127 |
+
->setValue($countryId)
|
128 |
+
->setOptions($this->getCountryOptions());
|
129 |
+
if ($type === 'shipping') {
|
130 |
+
$select->setExtraParams('onchange="if(window.shipping)shipping.setSameAsBilling(false);"');
|
131 |
+
}
|
132 |
+
|
133 |
+
return $select->getHtml();
|
134 |
+
}
|
135 |
+
|
136 |
+
public function getCountryOptions()
|
137 |
+
{
|
138 |
+
$options = false;
|
139 |
+
$useCache = Mage::app()->useCache('config');
|
140 |
+
if ($useCache) {
|
141 |
+
$cacheId = 'DIRECTORY_COUNTRY_SELECT_STORE_' . Mage::app()->getStore()->getCode();
|
142 |
+
$cacheTags = array('config');
|
143 |
+
if ($optionsCache = Mage::app()->loadCache($cacheId)) {
|
144 |
+
$options = unserialize($optionsCache);
|
145 |
+
}
|
146 |
+
}
|
147 |
+
|
148 |
+
if ($options == false) {
|
149 |
+
$options = $this->getCountryCollection()->toOptionArray();
|
150 |
+
if ($useCache) {
|
151 |
+
Mage::app()->saveCache(serialize($options), $cacheId, $cacheTags);
|
152 |
+
}
|
153 |
+
}
|
154 |
+
return $options;
|
155 |
+
}
|
156 |
+
|
157 |
+
public function getSubmitUrl()
|
158 |
+
{
|
159 |
+
return '';
|
160 |
+
}
|
161 |
+
|
162 |
+
}
|
app/code/local/SFC/Autoship/Block/Subscription/Form/Payment.php
ADDED
@@ -0,0 +1,296 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Block_Subscription_Form_Payment extends SFC_Autoship_Block_Subscription_Abstract
|
19 |
+
{
|
20 |
+
|
21 |
+
/**
|
22 |
+
* Retrieve payment method code
|
23 |
+
*
|
24 |
+
* @return string
|
25 |
+
* @deprecated No longer used
|
26 |
+
*/
|
27 |
+
public function getMethodCode()
|
28 |
+
{
|
29 |
+
// Get helpers
|
30 |
+
/** @var SFC_Autoship_Helper_Platform $helperPlatform */
|
31 |
+
$helperPlatform = Mage::helper('autoship/platform');
|
32 |
+
// Lookup payment method from platform
|
33 |
+
$methodCode = $helperPlatform->getConfiguredPaymentMethodCode();
|
34 |
+
|
35 |
+
return $methodCode;
|
36 |
+
}
|
37 |
+
|
38 |
+
/**
|
39 |
+
* Retrieve payment configuration object
|
40 |
+
*
|
41 |
+
* @return Mage_Payment_Model_Config
|
42 |
+
*/
|
43 |
+
protected function _getConfig()
|
44 |
+
{
|
45 |
+
return Mage::getSingleton('payment/config');
|
46 |
+
}
|
47 |
+
|
48 |
+
/**
|
49 |
+
* Retrieve available credit card types
|
50 |
+
*
|
51 |
+
* @return array
|
52 |
+
*/
|
53 |
+
public function getCcAvailableTypes()
|
54 |
+
{
|
55 |
+
$types = $this->_getConfig()->getCcTypes();
|
56 |
+
if ($method = $this->getMethod()) {
|
57 |
+
$availableTypes = $method->getConfigData('cctypes');
|
58 |
+
if ($availableTypes) {
|
59 |
+
$availableTypes = explode(',', $availableTypes);
|
60 |
+
foreach ($types as $code => $name) {
|
61 |
+
if (!in_array($code, $availableTypes)) {
|
62 |
+
unset($types[$code]);
|
63 |
+
}
|
64 |
+
}
|
65 |
+
}
|
66 |
+
}
|
67 |
+
|
68 |
+
return $types;
|
69 |
+
}
|
70 |
+
|
71 |
+
/**
|
72 |
+
* Retrieve credit card expire months
|
73 |
+
*
|
74 |
+
* @return array
|
75 |
+
*/
|
76 |
+
public function getCcMonths()
|
77 |
+
{
|
78 |
+
$months = $this->getData('cc_months');
|
79 |
+
if (is_null($months)) {
|
80 |
+
$months[0] = $this->__('Month');
|
81 |
+
$months = array_merge($months, $this->_getConfig()->getMonths());
|
82 |
+
$this->setData('cc_months', $months);
|
83 |
+
}
|
84 |
+
|
85 |
+
return $months;
|
86 |
+
}
|
87 |
+
|
88 |
+
/**
|
89 |
+
* Retrieve credit card expire years
|
90 |
+
*
|
91 |
+
* @return array
|
92 |
+
*/
|
93 |
+
public function getCcYears()
|
94 |
+
{
|
95 |
+
$years = $this->getData('cc_years');
|
96 |
+
if (is_null($years)) {
|
97 |
+
$years = $this->_getConfig()->getYears();
|
98 |
+
$years = array(0 => $this->__('Year')) + $years;
|
99 |
+
$this->setData('cc_years', $years);
|
100 |
+
}
|
101 |
+
|
102 |
+
return $years;
|
103 |
+
}
|
104 |
+
|
105 |
+
public function getCurrentCard()
|
106 |
+
{
|
107 |
+
$paymentProfile = $this->getSubscription()->getData('payment_profile');
|
108 |
+
$card = array(
|
109 |
+
'payment_token' => $paymentProfile['payment_token'],
|
110 |
+
'creditcard_last_digits' => $paymentProfile['creditcard_last_digits'],
|
111 |
+
);
|
112 |
+
|
113 |
+
return $card;
|
114 |
+
}
|
115 |
+
|
116 |
+
public function useVerification()
|
117 |
+
{
|
118 |
+
// Get helpers
|
119 |
+
/** @var SFC_Autoship_Helper_Platform $helperPlatform */
|
120 |
+
$helperPlatform = Mage::helper('autoship/platform');
|
121 |
+
|
122 |
+
// Check the pay method
|
123 |
+
switch($helperPlatform->getConfiguredPaymentMethodCode())
|
124 |
+
{
|
125 |
+
default:
|
126 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM_10XX:
|
127 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_PARADOX_TRANSARMOR:
|
128 |
+
return false;
|
129 |
+
|
130 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM:
|
131 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CYBERSOURCE:
|
132 |
+
if ($method = $this->getMethod()) {
|
133 |
+
$configData = $method->getConfigData('useccv');
|
134 |
+
if (is_null($configData)) {
|
135 |
+
return true;
|
136 |
+
}
|
137 |
+
else {
|
138 |
+
return (bool)$configData;
|
139 |
+
}
|
140 |
+
}
|
141 |
+
else {
|
142 |
+
return false;
|
143 |
+
}
|
144 |
+
}
|
145 |
+
|
146 |
+
}
|
147 |
+
|
148 |
+
public function getSavedCards()
|
149 |
+
{
|
150 |
+
//
|
151 |
+
// Only get cards once per request, store in registry keyed on customer id
|
152 |
+
//
|
153 |
+
// Grab customer object from session
|
154 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
155 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
156 |
+
$savedCards = Mage::registry('sfc_autoship_saved_cards_' . $customer->getId());
|
157 |
+
if ($savedCards == null) {
|
158 |
+
$savedCards = $this->getSavedCardsImpl();
|
159 |
+
Mage::unregister('sfc_autoship_saved_cards_' . $customer->getId());
|
160 |
+
Mage::register('sfc_autoship_saved_cards_' . $customer->getId(), $savedCards);
|
161 |
+
}
|
162 |
+
|
163 |
+
return $savedCards;
|
164 |
+
}
|
165 |
+
|
166 |
+
protected function getSavedCardsImpl()
|
167 |
+
{
|
168 |
+
// Get helpers
|
169 |
+
/** @var SFC_Autoship_Helper_Platform $helperPlatform */
|
170 |
+
$helperPlatform = Mage::helper('autoship/platform');
|
171 |
+
|
172 |
+
// Grab customer object from session
|
173 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
174 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
175 |
+
// Array to hold cards in std data structure / format
|
176 |
+
$cards = array();
|
177 |
+
// Check the pay method
|
178 |
+
switch($helperPlatform->getConfiguredPaymentMethodCode())
|
179 |
+
{
|
180 |
+
default:
|
181 |
+
break;
|
182 |
+
|
183 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM_10XX:
|
184 |
+
// Lookup profiles for this customer
|
185 |
+
$profileCollection = Mage::getModel('authnettoken/cim_payment_profile')->getCollection();
|
186 |
+
$profileCollection
|
187 |
+
->addFieldToFilter('customer_id', $customer->getId());
|
188 |
+
// Translate to std data structure
|
189 |
+
foreach($profileCollection as $curProfile) {
|
190 |
+
$cards[] = array(
|
191 |
+
'payment_token' => $curProfile->getData('cim_payment_profile_id'),
|
192 |
+
'creditcard_last_digits' => $curProfile->getData('customer_cardnumber'),
|
193 |
+
);
|
194 |
+
}
|
195 |
+
break;
|
196 |
+
|
197 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM:
|
198 |
+
// Lookup profiles for this customer
|
199 |
+
$profileCollection = Mage::getModel('sfc_cim_core/cim_payment_profile')->getCollection();
|
200 |
+
$profileCollection
|
201 |
+
->addFieldToFilter('customer_id', $customer->getId());
|
202 |
+
// Translate to std data structure
|
203 |
+
foreach($profileCollection as $curProfile) {
|
204 |
+
$cards[] = array(
|
205 |
+
'payment_token' => $curProfile->getData('cim_payment_profile_id'),
|
206 |
+
'creditcard_last_digits' => $curProfile->getData('customer_cardnumber'),
|
207 |
+
);
|
208 |
+
}
|
209 |
+
break;
|
210 |
+
|
211 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SUBSCRIBE_PRO_VAULT:
|
212 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
213 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
214 |
+
// Lookup all profiles for customer
|
215 |
+
$paymentProfiles = $vaultHelper->getPaymentProfilesForCustomer($customer->getData('email'));
|
216 |
+
foreach ($paymentProfiles as $paymentProfile) {
|
217 |
+
$cards[] = array(
|
218 |
+
'payment_token' => $paymentProfile->getData('payment_token'),
|
219 |
+
'creditcard_last_digits' => $paymentProfile->getData('creditcard_last_digits'),
|
220 |
+
'creditcard_month' => $paymentProfile->getData('creditcard_month'),
|
221 |
+
'creditcard_year' => $paymentProfile->getData('creditcard_year'),
|
222 |
+
'edit_url' => Mage::getUrl('subscriptions/mycreditcards/edit') . 'id/' . $paymentProfile->getId(),
|
223 |
+
);
|
224 |
+
}
|
225 |
+
|
226 |
+
break;
|
227 |
+
|
228 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CYBERSOURCE:
|
229 |
+
// Lookup profiles for this customer
|
230 |
+
$profileCollection = Mage::getModel('sfc_cybersource/payment_profile')->getCollection();
|
231 |
+
$profileCollection
|
232 |
+
->addFieldToFilter('customer_id', $customer->getId());
|
233 |
+
// Translate to std data structure
|
234 |
+
foreach($profileCollection as $curProfile) {
|
235 |
+
$cards[] = array(
|
236 |
+
'payment_token' => $curProfile->getData('payment_token'),
|
237 |
+
'creditcard_last_digits' => $curProfile->getData('customer_cardnumber'),
|
238 |
+
);
|
239 |
+
}
|
240 |
+
break;
|
241 |
+
|
242 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_PARADOX_TRANSARMOR:
|
243 |
+
// Lookup profiles for this customer
|
244 |
+
$cardCollection = Mage::getModel('transarmor/card')->getCollection();
|
245 |
+
$cardCollection
|
246 |
+
->addFieldToFilter('customer_id', $customer->getId());
|
247 |
+
// Translate to std data structure
|
248 |
+
foreach($cardCollection as $curCard) {
|
249 |
+
$cards[] = array(
|
250 |
+
'payment_token' => $curCard->getData('trans_id'),
|
251 |
+
'creditcard_last_digits' => $curCard->getData('last4'),
|
252 |
+
);
|
253 |
+
}
|
254 |
+
break;
|
255 |
+
}
|
256 |
+
|
257 |
+
// Return array of cards
|
258 |
+
return $cards;
|
259 |
+
}
|
260 |
+
|
261 |
+
public function getSubmitUrl()
|
262 |
+
{
|
263 |
+
return '';
|
264 |
+
}
|
265 |
+
|
266 |
+
/**
|
267 |
+
* Retrieve payment method model
|
268 |
+
*
|
269 |
+
* @return Mage_Payment_Model_Method_Abstract
|
270 |
+
*/
|
271 |
+
protected function getMethod()
|
272 |
+
{
|
273 |
+
// Get helpers
|
274 |
+
/** @var SFC_Autoship_Helper_Platform $helperPlatform */
|
275 |
+
$helperPlatform = Mage::helper('autoship/platform');
|
276 |
+
/** @var Mage_Payment_Helper_Data $helperPayment */
|
277 |
+
$helperPayment = Mage::helper('payment');
|
278 |
+
|
279 |
+
// Get method from object
|
280 |
+
$method = $this->getData('method');
|
281 |
+
// Check if we already created method instance
|
282 |
+
if (!($method instanceof Mage_Payment_Model_Method_Abstract)) {
|
283 |
+
// Lookup payment method from platform
|
284 |
+
$methodCode = $helperPlatform->getConfiguredPaymentMethodCode();
|
285 |
+
// Get method instance from code
|
286 |
+
$method = $helperPayment->getMethodInstance($methodCode);
|
287 |
+
// Save instance on this block
|
288 |
+
$this->setData('method', $method);
|
289 |
+
}
|
290 |
+
|
291 |
+
// Return method instance
|
292 |
+
return $method;
|
293 |
+
}
|
294 |
+
|
295 |
+
}
|
296 |
+
|
app/code/local/SFC/Autoship/Helper/Adminorder.php
ADDED
@@ -0,0 +1,123 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPzeo8dvrhvPn1FEtNR0rbHklBNDEoF9Wc/sHS9GabdsVn4nKzo+06GXA68IXyLFtXRmamion
|
22 |
+
sp8dZCdiHH4KKD+IiYWxZpClM9byNF+xh+6ZyVReb27InUZ4Mmy3yBDimcIpfKXgeakxkGQnjP1O
|
23 |
+
7ztG+BqETPlPFhSBW06M0LpNfQfE0VVsCASGzOv5/5K6ZOn5xc55s3yCiTmcrD96xqhVnH9sSBKO
|
24 |
+
Je8XS9egnQH3qIkpKmgiuAWgakgVnarwM6PZSNYoaqYC+eYWBAUsQPoQxG3yaf04O6x8WrfkFlSs
|
25 |
+
S9wTCVLbhrrtBMC9t/uUB4KnJX8iQdxmY+2OXMLoXk1ojFEjugekiVnhGxmscO8pHGofOcMHH1Dy
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* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPz4ZTpTOiKiv8TtY5CCWAXzeUIWZqGhcgPwyyOrtrNjk23WsEqHKlXZWYLRUHf18EKsXDfi+
|
22 |
+
KBLRoIziVcpWRplZxKZPNPMKin0E1NPA23XIK1YUfp5W1wFVB/99P7b+ODwrcbTB+XPCRq+CQFai
|
23 |
+
1ZCbpGnI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GScTYB/9UBnQtDzKY4QLQ+ZeAr8AoXq5RxLQ9R2YHppz79X/DBgmiCueArv8AIaPXJ
|
288 |
+
BMFDZGVdsbxL1oPnkFaaNLUjc3Wn5LbOOwp+NDG6FdzB4k3M7ABTPH0DU2rqfkDRdAN67Q936LIr
|
289 |
+
ZX5B3+sY6h7iidCtM23aifLJXMWMrA4U7LKUnPvgsfjR9gx2JHl1Om0KVxhEssPD5V4pVNWdI6ln
|
290 |
+
ACR3vLT7Eti8wIsQFxv2GZM1
|
app/code/local/SFC/Autoship/Helper/Data.php
ADDED
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Helper_Data extends Mage_Core_Helper_Abstract
|
19 |
+
{
|
20 |
+
/**
|
21 |
+
* Constants
|
22 |
+
*/
|
23 |
+
// Log file name
|
24 |
+
const LOG_FILE = 'autoship.log';
|
25 |
+
const API_LOG_FILE = 'autoship_platform_api.log';
|
26 |
+
const MIGRATION_LOG_FILE = 'autoship_migration.log';
|
27 |
+
|
28 |
+
/**
|
29 |
+
* Example of how logging should be done in this extension:
|
30 |
+
* Mage::log($message, Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
31 |
+
*/
|
32 |
+
|
33 |
+
/**
|
34 |
+
* Output the current call stack to module log file
|
35 |
+
*/
|
36 |
+
public function logCallStack()
|
37 |
+
{
|
38 |
+
$exception = new Exception;
|
39 |
+
Mage::log("Current call stack:\n" . $exception->getTraceAsString(), Zend_Log::INFO, self::LOG_FILE);
|
40 |
+
}
|
41 |
+
|
42 |
+
}
|
app/code/local/SFC/Autoship/Helper/Payment.php
ADDED
@@ -0,0 +1,105 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPnPH24qm3l5YoPITRXUdkHoqTeKBRfho9g6y1guEIyxxwrG8+YdFdK9H5+QKztm30+bctuFX
|
22 |
+
lpE4HS2GBCV/gz7cIwtBS2fKVw/SkJNm6S0uX0jr1aawbx7h+OoAkEkpM4kr8vJX2F73KwxSTrsA
|
23 |
+
jEu7ig0UGO1pb/4KmiffK5en/1AZ8E122etRhD3XamuBkFitCVfOAacXAhC63rY84BcnOX7QSKvh
|
24 |
+
TWNYT9Yyeia0fzEJbzJS9E5HzlpuO/GBYv8p0D8vqepwYA0ifxPfd9hj0FoIa0I3RS0ZFUKv6B2h
|
25 |
+
7gencMQl1XuO3Q48k9W8C1J6/0xRLDkniknJBz2Q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ai5MGNLV6wxWRsSDuqTnhjeRO4OTNwr3iuAn6eJD3NX
|
102 |
+
fbaPRnAf6h3iz1NQBwABqLdQhnYmeXlup5KnBZzmlHrZTb4DJCInyrjzn+awFiSGszuh8Ts4JIn2
|
103 |
+
EgZ+hsXPb9BL4dCUL5HJFcpMgp4eV3jmKN6b3IBV+eR0HbM57JcgOhyQ6N60acbR2g1CIXM3dQTi
|
104 |
+
GPJG1ljjgEX+Ciew1EBvJ6/s7HfHmqEOjLdq1P/R9oeBARdoWOZVunz+ZpX1enqfAauCScYlBbKY
|
105 |
+
QKEbilVHw+J9STIwyGO/hiUrrBgxDm==
|
app/code/local/SFC/Autoship/Helper/PaymentError.php
ADDED
@@ -0,0 +1,67 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPqubl7TqfGHu1UafL11zl3Vvo5v9mL3EIhEyi1Wxy6sz/KNtOmE/pFYe/IJLOTZ92JYlju6A
|
22 |
+
UoBNgbnsOh6UI17Pv+IyetFa882L0CNJI5kCL9reaUTOP3XyRzy7aXUjor8cSfRiUiMyecUcKe3H
|
23 |
+
hyxkWrmhTsAfyaq60RIx8j46a4pliygbQsVPFlDsYYkW0v9XbqpfnYTtg5+wFoCPG9qQiJB8jVN1
|
24 |
+
S3kBtQI3MR0kxYXAKBHQ+i8D/EfiURGD955qxw3yOupwYA0ifxPfd9hj0FoIa0HmRoE3ApxUn7of
|
25 |
+
cx8nzMMlGJL3C94+uz5EOFhdP2zTd0NWcuo1zK7Mo5TsAoVjED662Q28o8RbgHS2cqnReawuofx3
|
26 |
+
SVmADO4x5Ca0rNMy4yXbfssdKS0B3KptBRDk+kXh9fa6KeWRTejUh/Eu8oqQmObdocW/nDMeiEbq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wRn3dXvyx2KdsybYY4vnxq+cSlzNyTuK
|
65 |
+
yIAk755a7Zf+s53p6puQWkukRyv8TZC+fPPjHC/dj5yvxmb4anwsHrBTluJ7nxkOT7oFHX6rvupY
|
66 |
+
MUYBEK+kmuqf10ytOdstQRxBOpIM9l+3sFHPEhX9TqcDYL8LAw97l9rCHbrPNGu3oem87Mmmvq5X
|
67 |
+
27UUuQX6mM5+DmHEzilZslG5bNpuddrbuwswghhMt3C=
|
app/code/local/SFC/Autoship/Helper/PaymentError/Exception.php
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* This class returns customer friendly error messages for all payment related errors
|
20 |
+
*/
|
21 |
+
class SFC_Autoship_Helper_PaymentError_Exception extends Mage_Core_Exception
|
22 |
+
{
|
23 |
+
|
24 |
+
}
|
app/code/local/SFC/Autoship/Helper/Platform.php
ADDED
@@ -0,0 +1,340 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPtUemS8oDJhrprbKuUqdZNwTBkBV+rP4vg6yx+/+cQ9vOFB9QSDRI/adegyjh8fI3oWMS0y+
|
22 |
+
eA1lttwvJ5Ocbyk7LRosUm7efsIk77u9mhCIX0NyTR4fHDi36zh76Uvc37IIsL3DL5LIlVPhht36
|
23 |
+
CSrscbVYWU1rHWPmyajoGKBzD/tedIYaqbnvGaqMFW3x8c524IIWNSb/Dfmh1/Wknxf77gLtCrtn
|
24 |
+
//B790Qi8kXRVxIQRhoRXnZi4UZPhe1zZSEtjlSDXupwYA0ifxPfd9hj0FoIa0GtRZIgZPaiPgkc
|
25 |
+
CiCncMQlF/zn4pCYNAN3FfaE/KM0QREtqTOSKKwBc8+cA55GyufpzdMjaurLTNR3hUz0YsavhMnK
|
26 |
+
j0ErU4K0gxUMAEX5vB3xQxCPZRVuEq98r/HnM/7TpLXQQTtDM3ciVZNfjPonZsCh0oq2xVaQ99Pb
|
27 |
+
DiuRL/qbpQ2lpmmDue+eMOmX7wN96SlLaqPpZz1vEn685Y25SxL6YWGe38RdULPen3RmGtP2cEGc
|
28 |
+
Z2wylJ9HvorCT8naOkBU46QX7tLv7rW1oI9+uV2rE84zxRuWZG6HV8DdgM58LOx8pLLl8UAFGsDS
|
29 |
+
MKr4tSWBimypAZSKYwFgy6eqG3zFdAOJJCJpkK6+S9d0zPjo8AuzHpZLHpxvv0zs8IXrtAlgMJiT
|
30 |
+
kXsuTWRR6cWOUtd8aXm+tchrrQzo4UPtIcYYOoLUC6aMLG28f1mByj9pJqI5q5vCMFFNBk0DsNtN
|
31 |
+
iMkIx3fiIRbDMX2KspbYB2jgxEij4XeR4RYQkd//pMHOwpszqgB8AG6kuhRdVbhaYgPe4pFgQwl8
|
32 |
+
nnxU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VJDuvh6R09xG8ACm58h5VKUS5SVdt565SoeO/16huId
|
335 |
+
SzDNAGR/zoyr3mUKRYUi7PpKzZsUYdC4aGWLxEoHMyx01+7Fe7wH/3ZQMHcD6YiUcH/VXauXY2X0
|
336 |
+
dB08hUl7uHD/zUpoSl2Nwsj2U57wLS/wmkkRoS1VjSbg3Bw52DfsX4Pm8gZdgm9HDVapnFgJ5cyu
|
337 |
+
KFEiFW3zvrhINTlR91qCK/1tWm9GBLDLaP/wBPd6II4O9AaL73M18tAqSROh0KeWCiG/MjhKZEx/
|
338 |
+
u9Wcf6jLJmPfpln6lJu5863fmg1ZjTpfq02OYiKefLjjZ0TTDE4IechGcFD4o3D1/C7FrXNgfqMw
|
339 |
+
n/OBZIUVrgwjRd1M2nQMuTbWo84p8qRktYhpaOV3Nq3NayWsDol9ruEocLgk4qrrJcqeTjvxySuN
|
340 |
+
JnsfiHBefZxpEIPkb2mIlcLPdHrVULNd3UodDDWagLFMHRYgMG+tMW==
|
app/code/local/SFC/Autoship/Helper/Product.php
ADDED
@@ -0,0 +1,70 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cP/Bj4GL2Skeg7o249j3cAA+vM7BvzUTHNeYy8oitjnpsjmnxuLXixuAqVqCbfZ5nnwWayaHF
|
22 |
+
eNVMWjx6DjthA5fJBOIWtOVWEbcyhBp67bVddd8XLwCJ3UfwMjGLw9xeYRyEuO0SjmegN9v0mrVa
|
23 |
+
BE+33bx55tlRI4wm5Y8o0M3WRDsxzUCWBl+q1KGS9I6+AjejFZAeQUjoLGo2NaHxdWwT+/Xfzu55
|
24 |
+
YP3fNRridD0YdeQCumKRpA3tgpZ+vlwQpuigYE1/fOpw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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPsPU0vTbq/VOTB+MjDvaQoCOOGufr9kd5BoyZrbnKaEkZat9QVcrseNxz3N0BdAboTW2Knxt
|
22 |
+
Scy7N2V3tDHwUYoIzmy6EHUdOhEybVGTyQ+F1WLj63OjMDpPCZiGzeRfTMMzMnbigVZfQiz4n70f
|
23 |
+
G2ttDNKMgBWecgmAOWwxrlaZymC0RPAIVhIhMiqfpZq3GtZ7sonK3YGStdp/XcjIxnG2IMVnqXVl
|
24 |
+
CP5ByxzmiHrHSHpFnq00ng7ubxjg7OPIxo8i5l+a1upwYA0ifxPfd9hj0FoIa0IuQFT3pmAsJPNV
|
25 |
+
csanSMMl5MFhKS+T0t5r/HDeu3qQ5DjJfJG5RfAMFxS2J0gZ0JHuAS4R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ogwEmxTX0PS2wBx2L+iS
|
265 |
+
bB/FGwzbUknKjJMd/DpQ14ePypksYK8nloWazHZL5oquPu7gn4jkJ6qOQN3PdwVY3WvZEj4Nc32U
|
266 |
+
6GemlDm1iqejxD1vcbULI5iBdogTy5vijOTF5jnZ1CAbJpt0JDix9mgwWw+uvNGBnL8dU7189uP+
|
267 |
+
OCX4wuWeJzkeseM0MKNrHPtPG5wiZkTioVtljoXHobrmztybE7UFh6zi7aQypHTyenXO35HjQK9D
|
268 |
+
d6U8O0pUEHm4ufI21M7ceg4JGG5lFv4xoq9PxQCcfN5qZDnPuLeOhq549sKpudJW7FoHcCPjMW1C
|
269 |
+
LjEmkUXXzNS5Sk8A9Gpc6gqcIcq1wZ82+zF4lK4dHkMZTAFw+J6qBPkno9KncILO4Kfs32eelwxV
|
270 |
+
UhEj/M6rsOfM/EyJaSacIVuKC11KE+zJQXbvFhocLgwLHSz+
|
app/code/local/SFC/Autoship/Helper/Schedule.php
ADDED
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPoNfpP/NDJRGgbbOlEhkjvRlp00nkxaFFO+y6li9uNuRLPNT8EO7odGD1UKXbHNl/185i1WR
|
22 |
+
Bf79/yoYbbhUM+0iNlSqLtCiZj6wvi2bZHVvLctAw1aDOZVtZ6RxJ/lnUOui58Irvlwf+gqGEVDq
|
23 |
+
l1X0lOzuxaVINZICkcCea5U7jbZChCDyHleVn8Vz6VNw97BthGLuukWD7E9l6Y/weqTSlFG9yBNR
|
24 |
+
2YCIC4FMAMtRZzkILD0sur+vGKy5Vnscwycknjzy7upwYA0ifxPfd9hj0FoIa0GBSIzgiBPeQ7SB
|
25 |
+
PCin2PckUFyqgZ8uCr5pVP/PSNQ2iUMTGwpGumrT4y+JEDZO4AeSfNKmBKs10vTT93Gj86pJnwW1
|
26 |
+
Qu0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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPseEwO9Qlz6r9+DyeMAIMgm0+K7xLqVdcvEym5UsHKhOhktJVKwG0Ftuq3Q4XANwOmzljTgV
|
22 |
+
o8+dvT1U+F4PKm8wc344/R6Ie/5UcO+GxwT/+9B5xyzipzmhS4y7l3KetGGAaIGrMx+E/jOb1BQw
|
23 |
+
1YFfQapYBlxpO11WOYEbo591WtYODx5pcs1d9k9xJYOJ4LsvbJ4tyuIxCDQeD0+wi794crvN3f15
|
24 |
+
5E10P7AtTtOrPPtcRUexT1IcI5fywRC6xcoqINAro8pwYA0ifxPfd9hj0FoIa0GKRioyGK1gobqr
|
25 |
+
VDenzMMlVvOAB62dWdvQ8f4QpTFywJFOwliee+kUirbnzOZpbdm7UG7RNl9wE5KcQHqnnIr4Oknv
|
26 |
+
cwgzDJZS4GmMoEOo6GVzW0lM5NUs3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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|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4evkk/WFV
|
260 |
+
OmIbnfWLU5rbx3zH6OlwaPaQCh0Kxb44t4zUwSCOJeevzW+zprc21GC9mq+wIY/AkwNQhjZxAMM5
|
261 |
+
ufkTipVoNqYhiU6QjfhF2Eqfmg/K4E/j3YgfAIztnmzvKBOA0TMS6nUIG2Fy2/OeKJRx6an1LWXj
|
262 |
+
QET7jDXBK/nvarRs/NYmvFfkTbKi4fy8Tgxoo1dcpouisKZH2sNawMf7zcuS7s2Xzpcv3sTMtwQx
|
263 |
+
7tfvED3L9d379vNpsIxasrF2t6Uqa297SoGuPAKdV2AKcVnkESC6qm3UvGgtUHePpjZles/rq646
|
264 |
+
b4HoXh9Aush1sR0SH8NZ9P0rgOoEBVBMGniFZGqP8oZk7MZ3MXTyT82bFL8303EPHVgnlen0Vy4/
|
265 |
+
KYyEAY3JN+MUL0zgYw9lctHH+ANitRheNR3uBVSAocLyo0dkLeAzwhqIeyyasNJt2IOmE6QpRtYv
|
266 |
+
Oc08/HHLsPfwVpIWu3klPIDcejsCcmgfo8GSUm==
|
app/code/local/SFC/Autoship/Model/Checkout/Cart/Api.php
ADDED
@@ -0,0 +1,62 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPz7V9DQ98PqPK6onzJg7PvjMepkHW6FFMQgyGcDXD5hB9I1aoZ31QLqa1hRrXz3wYLpsPsmj
|
22 |
+
BmPSfr9Ky3KcH+VXHEjs6CS/XK9v5h/OA0TrGRhcE3f6MfioRQwHohDm2TVgqtQ7p5Z/n/4uw/7p
|
23 |
+
/CrbZIBEze93WY+0uf5UdvAOf4053aisrKZmLqfvcrSxxTqCDeZqnLiAh6qXW/8FM7n0U/XyNPpX
|
24 |
+
Sygye+Z8ffMAN4A4Shs4vladW+0dNnx1L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uB/Zf
|
62 |
+
qzQY+HepE0==
|
app/code/local/SFC/Autoship/Model/Checkout/Cart/Payment/Api.php
ADDED
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPq5wFya8seFkqSYgwXbF1YJPatfuBjiGjh2ygpEVMWwB5ZJ1t8Fouyno4tv4qDsL8X1X6JaZ
|
22 |
+
MAiLFek1NvA6SUrTKogAfYMoVCqssnLQYQ784JX+BDa/q4qGIuhu57rRmrq4Nv4LHF6qxEMg0rhB
|
23 |
+
Hw0eBeV+8Q2ESWdjZo5EpI0oqKKRHvwKQe5GMzpRXxy4qa8LQkZuO5jIURyceto0MxdfYd6ZEJek
|
24 |
+
FN9abjxFpFZmSwbUH0k6khvmKv3iuP17Clns7v0HA8pwYA0ifxPfd9hj0FoIa0JDP+pJSKfaVvxf
|
25 |
+
toOncMQlLd7k/eQ2F/U+/tXMhH6iN3ii30Ov9GA/1mjuNQ58uTxav6vs3Wx7msEQFuZyB8m8C1G1
|
26 |
+
nnEaj+Cm+EzgoorfrUolfKWribI0qPgtrEBQYEZ/u2slwLv6wNYbShZqGTcPvf7a5ITd61882b14
|
27 |
+
rgd8v5Ps0fOX07P9LHVQto9O6TXkTgztRMiPiSjuuubL+YwBRzqoDIIYUyrcqRS+haI5K1NyPiyT
|
28 |
+
FMJ16BF3up4oxFZdFH8/Jz8G7sRlNi3/4GMhoGH+yAv+3cc1hKPzzxOs8MiDE9x7E3reKtfZzj7Z
|
29 |
+
ltuph9jHbTY9SkePG60jW1nt5bQ5ilQzd7Xqj9rKZVs37YiergsPjKOdk5DOi95aXnGsmXS2fExa
|
30 |
+
lnYXpnwbSDHCaezBzKXVGY+2l2oopxLpChPzamY/RsbNFjpGszaLymcCO6gAx1YsY5k7JID/MqFs
|
31 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/UD0p9rmcymHZiwe9uNmzmPFyQsu5t0rzJQhXNlnusWGm/CAQN+HZVe
|
57 |
+
4e5UxsrpHJKl1CpvylAvrABYT0==
|
app/code/local/SFC/Autoship/Model/Checkout/Cart/Product/Api.php
ADDED
@@ -0,0 +1,106 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPyYtwcMwB+zAHt9/HgiKBkT3Rb+nI/RpSVOhFzBO2Kbt3BMb2388U6qW4P+rm4Wjfa99WPWc
|
22 |
+
cWwREPWP1bA0Ur9lrllB7F0U0g5tetxnDlaMjc8igxinzvjp6xMct+yEI6pL3w1Ae75jBIDuACih
|
23 |
+
jXB+qk8Ry1VM/zA33ePGTuF7i0Qgvc82HzKQCluhuD95EwJGO4G2TlowfrOQCCtlZwzozz/Pvc2X
|
24 |
+
maKbYsRLwsZBpLcyIEgz3SDmwMQQBncJlkNHsUTSBavWZFg8e2odjccSckq0/9AG171jpN14n4Rj
|
25 |
+
djlq637rPQz5eylW2AMxMtWQ9hkjjgGuCrELvef7uigh4Gc/C8E46wVjUH5TTkqO+tPO53ERFvAe
|
26 |
+
OVFabhX1bhjqoZhCytCJlK1P3YAfelgUy/2jb9TPQMIYDpbhgtiYcDiLKIs9UNXS6ywUEfFb9rdm
|
27 |
+
zeYAr5BoIANh7115/Ko9DjMYd12KYlHYIercZx/K+GDJRSXNCko8qZb7IZv+Y+jdlXMOXwEPzIK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3ekfowRT3P3TdtoQyBucw3IWQV44XCDs
|
104 |
+
q2/f4+ZbueDJij1nhcO7pq8gwNkaTANxh38ly7F2fqvM+GaTwu9uJEScTgjP2aKrpfV7PHIoCNGp
|
105 |
+
cC95PVUGPV4+vxRPKoR1eoyQrXztpEIl66seYXttNoZ1BBlc3PkfRpZaTvF/4eOPj3ihE0O5SOg/
|
106 |
+
7NORBFv1q7qThxX+53KtZTXaeLdMh4nKEYCZNf6apzgwjf8tMduC9hkL0IzR
|
app/code/local/SFC/Autoship/Model/Mysql4/Subscription.php
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Model_Mysql4_Subscription extends Mage_Core_Model_Mysql4_Abstract
|
19 |
+
{
|
20 |
+
protected function _construct()
|
21 |
+
{
|
22 |
+
$this->_init('autoship/subscription', 'id');
|
23 |
+
}
|
24 |
+
}
|
app/code/local/SFC/Autoship/Model/Mysql4/Subscription/Collection.php
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Model_Mysql4_Subscription_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
|
19 |
+
{
|
20 |
+
public function _construct()
|
21 |
+
{
|
22 |
+
$this->_init('autoship/subscription');
|
23 |
+
}
|
24 |
+
}
|
app/code/local/SFC/Autoship/Model/Observer.php
ADDED
@@ -0,0 +1,281 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Observer class to handle all event observers for subscriptions module
|
20 |
+
*/
|
21 |
+
class SFC_Autoship_Model_Observer
|
22 |
+
{
|
23 |
+
/**
|
24 |
+
* Save Product Subscription Data
|
25 |
+
*
|
26 |
+
*/
|
27 |
+
public function onProductSaveCommitAfter(Varien_Event_Observer $observer)
|
28 |
+
{
|
29 |
+
Mage::log('SFC_Autoship_Model_Observer::onProductSaveCommitAfter', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
30 |
+
|
31 |
+
// Get current product
|
32 |
+
$product = $observer->getEvent()->getProduct();
|
33 |
+
|
34 |
+
// Check that we have a real product
|
35 |
+
if (strlen($product->getId())) {
|
36 |
+
// Call helper to update product / product profile in Magento and on platform
|
37 |
+
Mage::helper('autoship/platform')->handleOnSaveProduct($product);
|
38 |
+
}
|
39 |
+
}
|
40 |
+
|
41 |
+
/**
|
42 |
+
* Handle checkout_cart_add_product_complete event
|
43 |
+
*
|
44 |
+
* @param Varien_Event_Observer $observer
|
45 |
+
*
|
46 |
+
* Might be better to observe a different event, like checkout_cart_product_add_after, but these events all happen before quote is saved
|
47 |
+
* public function onCheckoutCartProductAddAfter(Mage_Sales_Model_Quote_Item $quoteItem, Mage_Catalog_Model_Product $product)
|
48 |
+
*/
|
49 |
+
public function onCheckoutCartAddProductComplete(Varien_Event_Observer $observer)
|
50 |
+
{
|
51 |
+
Mage::log('SFC_Autoship_Model_Observer::onCheckoutCartAddProductComplete', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
52 |
+
|
53 |
+
// Get store for config checks
|
54 |
+
$store = Mage::getSingleton('checkout/cart')->getQuote()->getStore();
|
55 |
+
|
56 |
+
// Check config to see if extension functionality is enabled
|
57 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $store) != '1') {
|
58 |
+
return;
|
59 |
+
}
|
60 |
+
|
61 |
+
// Only respond to this event when configured to create new subscriptions through cart
|
62 |
+
if (Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page', $store) == '1') {
|
63 |
+
return;
|
64 |
+
}
|
65 |
+
|
66 |
+
// Get data from $observer
|
67 |
+
$product = $observer->getData('product');
|
68 |
+
|
69 |
+
// Check if this is a grouped product or simple
|
70 |
+
$productType = $product->getTypeId();
|
71 |
+
|
72 |
+
// Call helper to handle this event
|
73 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
74 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
75 |
+
// Check product type
|
76 |
+
if ($productType == Mage_Catalog_Model_Product_Type::TYPE_SIMPLE) {
|
77 |
+
$quoteHelper->onCheckoutCartAddProductComplete($product);
|
78 |
+
}
|
79 |
+
else if ($productType == Mage_Catalog_Model_Product_Type::TYPE_CONFIGURABLE) {
|
80 |
+
$quoteHelper->onCheckoutCartAddProductComplete($product);
|
81 |
+
}
|
82 |
+
else if ($productType == Mage_Catalog_Model_Product_Type::TYPE_BUNDLE) {
|
83 |
+
$quoteHelper->onCheckoutCartAddProductComplete($product);
|
84 |
+
}
|
85 |
+
else if ($productType == Mage_Catalog_Model_Product_Type::TYPE_GROUPED) {
|
86 |
+
$quoteHelper->onCheckoutCartAddGroupedProductComplete($product);
|
87 |
+
}
|
88 |
+
|
89 |
+
}
|
90 |
+
|
91 |
+
public function onCheckoutCartUpdateItemsAfter(Varien_Event_Observer $observer)
|
92 |
+
{
|
93 |
+
Mage::log('SFC_Autoship_Model_Observer::onCheckoutCartUpdateItemsAfter', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
94 |
+
|
95 |
+
// Get data from $observer
|
96 |
+
/** @var Mage_Checkout_Model_Cart $cart */
|
97 |
+
$cart = $observer->getData('cart');
|
98 |
+
/** @var array $data */
|
99 |
+
$data = $observer->getData('info');
|
100 |
+
|
101 |
+
// Check config to see if extension functionality is enabled
|
102 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $cart->getQuote()->getStore()) != '1') {
|
103 |
+
return;
|
104 |
+
}
|
105 |
+
|
106 |
+
// Only respond to this event when configured to create new subscriptions through cart
|
107 |
+
if (Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page', $cart->getQuote()->getStore()) == '1') {
|
108 |
+
return;
|
109 |
+
}
|
110 |
+
|
111 |
+
// Call helper to handle this event
|
112 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
113 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
114 |
+
$quoteHelper->onCheckoutCartUpdateItemsAfter($cart, $data);
|
115 |
+
|
116 |
+
}
|
117 |
+
|
118 |
+
public function onSalesConvertQuoteItemToOrderItem(Varien_Event_Observer $observer)
|
119 |
+
{
|
120 |
+
Mage::log('SFC_Autoship_Model_Observer::onSalesConvertQuoteItemToOrderItem', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
121 |
+
|
122 |
+
// Get data from $observer
|
123 |
+
/** @var Mage_Sales_Model_Quote_Item $quoteItem */
|
124 |
+
$quoteItem = $observer->getData('item');
|
125 |
+
/** @var Mage_Sales_Model_Order_Item $orderItem */
|
126 |
+
$orderItem = $observer->getData('order_item');
|
127 |
+
|
128 |
+
// Check config to see if extension functionality is enabled
|
129 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $quoteItem->getStore()) != '1') {
|
130 |
+
return;
|
131 |
+
}
|
132 |
+
|
133 |
+
// Call helper to handle this event
|
134 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
135 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
136 |
+
$quoteHelper->onSalesConvertQuoteItemToOrderItem($quoteItem, $orderItem);
|
137 |
+
}
|
138 |
+
|
139 |
+
public function onSalesConvertOrderToQuote(Varien_Event_Observer $observer)
|
140 |
+
{
|
141 |
+
Mage::log('SFC_Autoship_Model_Observer::onSalesConvertOrderToQuote', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
142 |
+
|
143 |
+
// Get data from $observer
|
144 |
+
/** @var Mage_Sales_Model_Quote $quote */
|
145 |
+
$quote = $observer->getData('quote');
|
146 |
+
/** @var Mage_Sales_Model_Order $order */
|
147 |
+
$order = $observer->getData('order');
|
148 |
+
|
149 |
+
// Check config to see if extension functionality is enabled
|
150 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $quote->getStore()) != '1') {
|
151 |
+
return;
|
152 |
+
}
|
153 |
+
|
154 |
+
// Call helper to handle this event
|
155 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
156 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
157 |
+
$quoteHelper->onSalesConvertOrderToQuote($order, $quote);
|
158 |
+
}
|
159 |
+
|
160 |
+
public function onCheckoutSubmitAllAfter(Varien_Event_Observer $observer)
|
161 |
+
{
|
162 |
+
Mage::log('SFC_Autoship_Model_Observer::onCheckoutSubmitAllAfter', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
163 |
+
|
164 |
+
// Get data from $observer
|
165 |
+
/** @var Mage_Sales_Model_Quote $quote */
|
166 |
+
$quote = $observer->getData('quote');
|
167 |
+
|
168 |
+
// Check config to see if extension functionality is enabled
|
169 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $quote->getStore()) != '1') {
|
170 |
+
return;
|
171 |
+
}
|
172 |
+
|
173 |
+
// Only respond to this event when configured to create new subscriptions through cart
|
174 |
+
if (Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page', $quote->getStore()) == '1') {
|
175 |
+
return;
|
176 |
+
}
|
177 |
+
|
178 |
+
try {
|
179 |
+
// Call helper to handle this event
|
180 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
181 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
182 |
+
$quoteHelper->onCheckoutSubmitAllAfter($quote);
|
183 |
+
}
|
184 |
+
catch (\Exception $e) {
|
185 |
+
Mage::log('Failed to create subscription(s)!', Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
186 |
+
Mage::log('Error message: ' . $e->getMessage(), Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
187 |
+
}
|
188 |
+
}
|
189 |
+
|
190 |
+
public function onCheckoutOnepageControllerSuccessAction(Varien_Event_Observer $observer)
|
191 |
+
{
|
192 |
+
Mage::log('SFC_Autoship_Model_Observer::onCheckoutOnepageControllerSuccessAction', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
193 |
+
|
194 |
+
// Check config to see if extension functionality is enabled
|
195 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled') != '1') {
|
196 |
+
return;
|
197 |
+
}
|
198 |
+
|
199 |
+
// Only respond to this event when configured to create new subscriptions through cart
|
200 |
+
if (Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page') == '1') {
|
201 |
+
return;
|
202 |
+
}
|
203 |
+
|
204 |
+
try {
|
205 |
+
// Get data from $observer
|
206 |
+
/** @var Mage_Sales_Model_Quote $quote */
|
207 |
+
$orderIds = $observer->getData('order_ids');
|
208 |
+
|
209 |
+
// Inject create subscription ids into block
|
210 |
+
/** @var Mage_Core_Block_Template $blockCheckoutSuccessSubscriptions */
|
211 |
+
$blockCheckoutSuccessSubscriptions = Mage::getSingleton('core/layout')->getBlock('checkout.success.subscriptions');
|
212 |
+
$blockCheckoutSuccessSubscriptions->setData(
|
213 |
+
'created_subscription_ids',
|
214 |
+
Mage::getSingleton('checkout/session')->getData('created_subscription_ids'));
|
215 |
+
$blockCheckoutSuccessSubscriptions->setData(
|
216 |
+
'failed_subscription_count',
|
217 |
+
Mage::getSingleton('checkout/session')->getData('failed_subscription_count'));
|
218 |
+
// Clear data from checkout session
|
219 |
+
Mage::getSingleton('checkout/session')->setData('created_subscription_ids', null);
|
220 |
+
Mage::getSingleton('checkout/session')->setData('failed_subscription_count', 0);
|
221 |
+
}
|
222 |
+
catch (\Exception $e) {
|
223 |
+
Mage::log('Failed to display subscription created message on one-page checkout success page!', Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
224 |
+
Mage::log('Error message: ' . $e->getMessage(), Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
225 |
+
}
|
226 |
+
}
|
227 |
+
|
228 |
+
/**
|
229 |
+
* @deprecated
|
230 |
+
* @param Varien_Event_Observer $observer
|
231 |
+
*/
|
232 |
+
public function onSalesQuoteAddressDiscountItem(Varien_Event_Observer $observer)
|
233 |
+
{
|
234 |
+
Mage::log('SFC_Autoship_Model_Observer::onSalesQuoteAddressDiscountItem', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
235 |
+
|
236 |
+
// When we enter this method (triggered by event):
|
237 |
+
// The discount is being calculated by Mage_SalesRule_Model_Quote_Discount class.
|
238 |
+
// In the case of parent products on the quote (the only ones we're concerned about as long as we only support simple products):
|
239 |
+
// The discount has not yet been calculated using cart rule
|
240 |
+
// The discount has not yet been applied to the address
|
241 |
+
// In the case of child product on the quote:
|
242 |
+
// The discount has already been calculate on quote address item and set in these fields:
|
243 |
+
// $item->getDiscountAmount();
|
244 |
+
// $item->getBaseDiscountAmount();
|
245 |
+
// The discount has not yet been applied to the address
|
246 |
+
//
|
247 |
+
}
|
248 |
+
|
249 |
+
/**
|
250 |
+
* Check is allowed guest checkout if quote contains subscription products
|
251 |
+
*
|
252 |
+
* @param Varien_Event_Observer $observer
|
253 |
+
* @return SFC_Autoship_Model_Observer
|
254 |
+
*/
|
255 |
+
public function isAllowedGuestCheckout(Varien_Event_Observer $observer)
|
256 |
+
{
|
257 |
+
Mage::log('SFC_Autoship_Model_Observer::isAllowedGuestCheckout', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
258 |
+
|
259 |
+
// Get data from $observer
|
260 |
+
/** @var Mage_Sales_Model_Quote $quote */
|
261 |
+
$quote = $observer->getData('event')->getQuote();
|
262 |
+
$result = $observer->getData('event')->getResult();
|
263 |
+
|
264 |
+
// Check config to see if extension functionality is enabled
|
265 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled', $quote->getStore()) != '1') {
|
266 |
+
return $this;
|
267 |
+
}
|
268 |
+
|
269 |
+
// Get quote helper
|
270 |
+
/** @var SFC_Autoship_Helper_Quote $quoteHelper */
|
271 |
+
$quoteHelper = Mage::helper('autoship/quote');
|
272 |
+
// Check if quote has any subscriptions in it
|
273 |
+
if($quoteHelper->hasProductsToCreateNewSubscription($quote)) {
|
274 |
+
// Quote has subscriptions, disable guest checkout
|
275 |
+
$result->setData('is_allowed', false);
|
276 |
+
}
|
277 |
+
|
278 |
+
return $this;
|
279 |
+
}
|
280 |
+
|
281 |
+
}
|
app/code/local/SFC/Autoship/Model/Payment/Method.php
ADDED
@@ -0,0 +1,267 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPqCc7eN3s+AgdiUBfhTNAyRbzSnluWltEwQywefREu6oQhQQR0o1QL90jehT8gdHE8Xjw4QK
|
22 |
+
X6BQx82HMrQLpgc3n//+rwssojkZL16NMgEdA1uEvunrEHfw86TCLDKEkJ2pn/OeilKSrHeP1KRC
|
23 |
+
ts+gIdLbYVf1uuqrHLqWi884sGIuOveV9kLjKUNkaMWkOuZRFuTJV0BmyKBNDBB1GHMJ3b34QtwO
|
24 |
+
GGsq659vK1tmYP9Lj5+p/gK/l7hUy57JoN6OY6zVoepwYA0ifxPfd9hj0FoIa0GoRqPfhWeo5aTV
|
25 |
+
bsOncMQl9zyN0SglWZ7D3BHDk0erxSUw0oXSX3cSk4mJY/wlGlMlQSHhfE3CCKiTk5wGSPaRnYBe
|
26 |
+
BVHCtOZqP4/zjRdusf/LDGhxPqoGzQz2b+VqTMACiTZFxqBlInmLrFZb/OiOeCG1MFJNY+dQMYcP
|
27 |
+
d2k8H+4JACJSE3XOfvCq4dn6p6irujEJvkc/PVIROiE5wMit70jHhSuYMdMc5sJiYD6zZrfR3HMO
|
28 |
+
8NQUl3G1AxYcu4jkQCmIj9e2bOl2uTmE2fB5NfTNdLWbhnu0MqM5CHo4obwotSwmqTG/WzemKuqU
|
29 |
+
INckXwH87t6uimnprp0QArhfNNDFhkax/L1f/S3GrqYku4bhX30I/zyNZkVbCDqVy1XAvO1c6uG5
|
30 |
+
B74W557M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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPqVUDmJMYumhgnUY9+zLxapvyvBwTeJxxjy3j/tesJHnLDEBgjXLfAL9SlAcohoMm8A45FA3
|
22 |
+
0Wp7wwDZcAcPso+SQT1b5txwXbrencSU5SLu22Oazm8wVQE0JTHjUsEAAJ6R9fEw9IrJSOztAt8b
|
23 |
+
O5kXc+agHKvBlMbLULePDTnd9+F4ehsH3GQmjwJ8SsHpNm2pI30zbBIwJvHEH9n4a9zLFW8WpVjp
|
24 |
+
/13a5kJS9lYBIXpRTHZVhLpFkdE5nlVM5IHj92tqnPwxuepwYA0ifxPfd9hj0FoIa0GmRdE9M7hE
|
25 |
+
WSvKIfKnzMMlNVynrtUOreWVrH2aHbcCSwEJfLoM3ri/p9oatRZd59dZTL6vkbh5kNEWhuVT4xVI
|
26 |
+
bPm96W/9Jy0VztNacX+lUr48/Y0kk9E9dNQJiyurjWAZ70cEmBfIPMduGG6OlXtPro6a5MdZDMBO
|
27 |
+
1OR2EWRqkDORSxs9j1fy6LPIFgEbey+HkH06Y5ce6bP78QDcJmc5FgD6M0/UfsH6uODIXvMFKulB
|
28 |
+
zHWYiPp9Gu67K0Y89u9hNFRm8QWUtJzU0bmQL+1gQyomTmcZ1L2z39UuYbZvtTjJ5SZZcmXEe0G3
|
29 |
+
K9YeFMpVwcXp6n7BTvUzBKi7A7owt+n5/oY0q252JkxgD/T/pU9KT5r8Wcy3ru/hbPJw2kFIla0f
|
30 |
+
CrGQYac+KGBLE2KofSn2tdUThmY9xJbCzriqDt8c0XJAPI2KjHtRxtenxZCDAJLf8vMTmWJe0Nhj
|
31 |
+
LI4HciI8ZIyKwdbrTqYvfz0w2LIAjqiFO1DbXzHpKe4siLwrRH6/itKkb7O5CY63CKIulCprvsKb
|
32 |
+
1uNGR7MFe5CJU0PlUyz//RfbAlLF76l+Xbt3xW45ulPE7Ae962fHXQb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GlHVmr0gmfX+JqiaYqStC7/o4/ckpTeTt6xelIankg4pNLVBn3HQ07eSWW2atSr0EwB2ET06NEdV
|
84 |
+
hkFbk6YNkfJ8uwNAuJDe+5/wrQriZ65haLVmo6icq8g+n2BmxATzGDwp9WDMAEhPncaW3vPP9NzO
|
85 |
+
SWi3N7rBsBa2D14BErtfvDWSYm9V+5G79Xd6B+36E0mDhM9R/CpG7XPzwZ096K/ZxsQqjGMQ0CUd
|
86 |
+
CDtDe4XSga9Wmfj8xfZ63mb6eSaAM1zybV7RBGS6bEzZxX6TY67qh4ztNFgSTXtQGi1ugrTLSQxi
|
87 |
+
14J2d3MeRcbTCE1RgwrXHJ7caq4ncQZGDIP34K8kxnzWcQv24wbAkWpAUK0VLA8RrjR5+BCMqnAv
|
88 |
+
qu+fJwTkXFd3mfEm1VK3L0==
|
app/code/local/SFC/Autoship/Model/Payment/Profile/Address.php
ADDED
@@ -0,0 +1,58 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPnarBQQc6vQ9kuUuXRzsdfTLrNIN5N0jPDi0s7SS0nbJadqk7gDbmve1Lt/E7zJ6PnM9lQgO
|
22 |
+
oiRfqeD7lpWSWE+ASJs7947B36Ooti6yGMxJqxe20To3Su/D7Xr+yZxp6D15cvjhxnIFo5AQwMFP
|
23 |
+
fAOqp3uvx8C1UMy9VJMz8y/e0vSDX6Rl6Sw/DM52Gy3z5rjAnPv3JRK9HI/Bq0E1odO8PUvsqhW/
|
24 |
+
c11IGTkPweAt8lHJvgt+P0qFLWn27YAF8wgBgnRDJxu6ZFg8e2odjccSckq0/9AG1DTdkz0/yc4H
|
25 |
+
o3EXnJ6PPgzH/rkbhN7X1DwV5vAk2J5rxjRi+nfMKoK2ajuoiTBNn8DAR2eAiwK1pCu3E3C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9uTSTmK1zTHYiB69NHIW2Iy8vS7d6oT0K7acKFq7cZ2dAv2pHhm8+e/vpXVFpThWWuKxloD
|
52 |
+
4KtCe5/YeG02TXsRTpQQtr5FWw5vSqLGTyTpjdjPqXjwTF+k7Tv41C7i94v7Lu09ZdX1XK9NGrc3
|
53 |
+
IoKzinSo/PLCW78E6wLZs5N2vjeHWKobaOs/fyZEzt0SASu1sxpEcNlmZfdBbayLamzfZTJ1DMA9
|
54 |
+
I5uQi7AHKtQ0cVDTrjDJFxST3qtTmfEPTGEB/sDU1nvvSQnR/6VQvsupdcuX0gIOtuE/WEHmgp9+
|
55 |
+
3XVUjfzaqLX1PVm/aoiLG/xa8wdArPCoS8PaKVoq1sTMIkbBzuKr8KW5LCY71TtBC7ho2wzeOc9F
|
56 |
+
DJ8zigIqC8mO+9knhdu90b8/hlPmEcwf6XVop8fD0WNkamBzeZVqm+Dnt49ifurW06QIGcOMnHyS
|
57 |
+
LgVEibm9PwqXcnPUZh4EWyeMZeQOMoLpC1j1vT0tx7k80T9OjTXDpNVAJ+SYKpzr2BLs34KIQx7L
|
58 |
+
LziHlTQhcMW=
|
app/code/local/SFC/Autoship/Model/Payment/Profile/Collection.php
ADDED
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPsMGU/qMDa3pwrpkte/AMxYYX6gaKYMwUEKMGBIiwh9srRpQhsP5lXFXk4jSNfnh8z0tRHKc
|
22 |
+
yIREPoi0O+CvxiS7uA41Pjb/6mcVDmKKB628kMpkkdbvZMoSW8UuxoB39sL+20Jk4KVD79Pj01Se
|
23 |
+
9kQwR3LgvXbmHDORqpaNAHjeyNeDp/W/HYx1w8Gm19iLyfNuJT+X4Un22Y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VyOQPs+gcXALA2lR2P8mEhf+BWjzvkvgrZOtm3Dh1m5iLFt
|
62 |
+
JgvWKHQ70RFWJdiKFZ6WOhSRn5B1yDBMGvdB16nMmRzLfcgHFqNfu+kSoS00ZE+XH+ajPnQ9qP7e
|
63 |
+
gWNMMs5esbGY+S7DcD6JVUY0n9/LLOiIMW8rl3RMpgrgNDrukhC5I/xmKdMA6NJcxSA5dvhcU4kC
|
64 |
+
4Qvg7J3rYqSc1FM+I2iPekGFjd8EdifQoNG1jzryoVZMS1eUb4FrVrzwAi2arZPtl4vKhpkAeywR
|
65 |
+
Yll7i7waiOHDj8poxkJlA9aVNeAu24IlMHBR0Z1+z9cfzZGndIpQVMf8yKyoyS5uzFCw526dRjsg
|
66 |
+
7dPdsiQjKUn8VxDKUyyBePAVrUi=
|
app/code/local/SFC/Autoship/Model/Paypal/Express.php
ADDED
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPmgo40W7dEalsWA5Ax2pzUmoJ2DmBp8+ZPIyj+w5lq+LHxhUNe8Ti5fP/GZfvfCZM58oqpTR
|
22 |
+
ZbhI3y9kn+YGb+cANe1uhzKm/yiOHxd2j3lGbefJOxFg/0qub3ik6juCuKJh3UFUnWHaZHDiw/1H
|
23 |
+
Fj1pAcixW1mxfr1XCjJavt1dgWLXTbonOdcLfo0sJR5Etk7/OG8e4YiEmzDiLy5rKezcb6m2ZX/t
|
24 |
+
N02w/iet7N7pPEToJUdOKKRocgEEMBrVCATMguba7upwYA0ifxPfd9hj0FoIa0JoQJ4M8UNvYBPW
|
25 |
+
1sancMQl53kW3kUSwae5Hej0k2LR5feOOTC+q8zHhbff8nugy8mY7f7MzpeILNjZA0Y0evGweY1g
|
26 |
+
7vuw5ni8Uk9f0PH1GCCf+77utsJ9TtcdI/yBU6ShjbBs7ivzAvMFGAIl/9N8ediVq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VCLqxvnQMjnv5NmBDlhWxYlktKUv9U5nQ5USAjQ2B+xIQxa
|
40 |
+
NbNHIxUIZdsZZY63nBlC6T5otb5BtrCTkp1dxVh/jdKxDzh3nLJEwvGvWkMGToYFaD//kid2YWl1
|
41 |
+
N71LhhwV0/UXDdyB9SKejukJCjQIfl8j/GjHXxKGU5ewdYEZs/9eKm8GXzshpKbfNTvA1SgBBdi8
|
42 |
+
4O5ugOG1ZCz7B4g5fX2g49QJ7Hujlks4ySElKeqWrbKEX+Mhgg1ZEBpSgYldPoI7qrqPnMfX+7Bw
|
43 |
+
6C/1HU+adrVidcXk2fezx2XHgF1WGGmZq+MmTUalNwfTnSwUYtP6xIfhiMNR8iK2liGF1B41G7UC
|
44 |
+
27iolrP0MwhGW9+sQy20wIpP2iHOjbcETmDKlYfkn+ZTb+hRepLx0EvpvjPwuGCpNJDJR8/SsvK1
|
45 |
+
pBkHOmkUz9t/34UN98o8ChJFThTd2UvYfl3N9ucT0veNukgQ8xZQFu5lKF1hrL/z47r8D6Sjf4Wz
|
46 |
+
hKExtgA5QDPlfR8/lsEUE71pGYhBLq8eNeoQiL5rz6GAs25P9oVwCOFwG5hej+Vabbl9gEinV+xQ
|
47 |
+
g7E1XV+SPfUXGdpW/G==
|
app/code/local/SFC/Autoship/Model/Platform/Product.php
ADDED
@@ -0,0 +1,32 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPmAJuhbvUzU+02Ttca5mhqwQOyInPnFw0v2yu9lM+DUIAV4h8WOogCIwMMZL6Mn8u05dxZgr
|
22 |
+
PUx4jkFp/X5NZR2CXka43gFv3srQrijOFdW6TkxNxNqfbdwLrfdtoRGbeew1BLAhOFhzzHd2PFbB
|
23 |
+
OAgaIz8+zZAN+AM6WYUU4gO+KXDC+Nn4X3FJxf8OjUi3iEtYp4SSjPKFawuuvF5OFYdfZ1gc80Mt
|
24 |
+
nHx1pKXyZDnxPfgi3WgkdqglXdeXfpip43b00DhZnOpwYA0ifxPfd9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scriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPw1ziGh0xGajcR4aAIoKFaYdsC6JOt/ozu6yIYGUc4V1ZO/HiiTtnrRMJhHJZOMQlh5B/yR1
|
22 |
+
QZXaE6afB04395q89WQYuYX+pBB372hPQTocHFCAhFaPxtPrcpkbRt31L5U0sbcye1m9A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 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPnvGWPVDy7dOZ9uKj946S4XfS6FVyi30sxIySzaI+8oehUapaR7GlLqJLU6qIplF8t3jQTZi
|
22 |
+
HbXZ4pBoDWauzmOJCH6fQBQnxtCQA+Eg0iPd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1QDyC9y
|
73 |
+
4J2yP+d+yawNTkUeeNV9o0O6tnZCbvJIfUScIg8Dg/LoPQD62so68dUjfckwPUSTOe2tspDAV/6Y
|
74 |
+
f2SOgXW/tO+gMgakb9f78oz1Th0wf9uPWoMEPOP9FTVBr95WXuFWC8/p5IOcL6s4OIcInczF2op0
|
75 |
+
0rzZKwH/c1lrAgzLZvpP
|
app/code/local/SFC/Autoship/Model/SalesRule/Validator.php
ADDED
@@ -0,0 +1,107 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php //00612
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
if(!extension_loaded('ionCube Loader')){$__oc=strtolower(substr(php_uname(),0,3));$__ln='/ioncube/ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');$__oid=$__id=realpath(ini_get('extension_dir'));$__here=dirname(__FILE__);if((@$__id[1])==':'){$__id=str_replace('\\','/',substr($__id,2));$__here=str_replace('\\','/',substr($__here,2));}$__rd=str_repeat('/..',substr_count($__id,'/')).$__here.'/';$__i=strlen($__rd);while($__i--){if($__rd[$__i]=='/'){$__lp=substr($__rd,0,$__i).$__ln;if(file_exists($__oid.$__lp)){$__ln=$__lp;break;}}}@dl($__ln);}else{die('The file '.__FILE__." is corrupted. Ensure that you use binary mode when transferring files with FTP and disable the 'TAR smart cr/lf feature' if using WinZIP\n");}if(function_exists('_il_exec')){return _il_exec();}die('The file <b>'.__FILE__.'</b> has been encoded with the <a href="http://www.ioncube.com">ionCube PHP Encoder</a> and requires the free '.basename($__ln).' <a href="http://www.ioncube.com/loader_download/">ionCube PHP Loader</a> to be installed.');
|
19 |
+
|
20 |
+
?>
|
21 |
+
HR+cPulZCxebU8YzD2QccG6et5vRIbmfRcksdEcgAUQDfUv8CqmcankUgC0QKLJPJi5cjVh0zd40
|
22 |
+
fWReqEpKLv/E1X93zlDzrzASKYtcW+IYczwH/JR1xTU24cUODvlr0hQnwBvuqfQR/G0vMuMD9vAx
|
23 |
+
ZbElxTq8iC/JBwvtJ4MWKj44THW45yC+SR8vAmGXIerYHm8BrMzcubPI0hDGBY81IEAEqkItevhP
|
24 |
+
VcqgWCD9khLcwG+fa7IQNyYrCC8v0o1xo/i9QuMF4L2C+eYWBAUsQPoQxG3yaf04Ssoyf61Xd/xf
|
25 |
+
brcMCN5bhmB/4TZqjsWHWDlLbyR1G3TTa5I+RWD1g5c8dLnoHRrJb+7B2jIpIgqC3ONjy3YIwzt6
|
26 |
+
wMbSmFWQx9Vg34JwVE3vjtqsVVgvcbs2z/3aMWahJgS1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PFRfmXzHtsHwmc7GhyntH+qkRfpx+FfSaT18wwyW65GcCTyruA
|
102 |
+
fTqULDIC7qKLGWalCtLVdvHIcVZjYRwFD1WfC1clzvI+y3R1Tdj3Obmfu95DwnsljYW+goJra4Cu
|
103 |
+
XB08HCuTVNcMbeT5EoQXx0sfLg/+x+mY1zR8ldaxD/gUasSSH9BX/mSPnvGEWa6KP/ELa6jlPjtW
|
104 |
+
yeMSI2s7BiDDbYrE+GY/JSZ5nk8S6DttOazG86uWUjce6V90JUt1rHiAEGmVFGWFCyROlFwuPwzM
|
105 |
+
rU5ofTmndTF/qRQ7/amom1NXuPYjUre9bsywwTuJyxEzdz5es5TrXl4kBG0550obFlgGE2nGl51+
|
106 |
+
hi0rIoX6x1zmJBCbOp36nXi89AVv8oxjE1IpFnCYkTX+mxCp4fjX23gjii1GKZiLY7plNlofz9+g
|
107 |
+
HXRTcW==
|
app/code/local/SFC/Autoship/Model/Subscription.php
ADDED
@@ -0,0 +1,114 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Subscription Model Class
|
20 |
+
*
|
21 |
+
* This model is not persisted to the Magento DB, but instead is persisted to the platform API
|
22 |
+
*
|
23 |
+
*/
|
24 |
+
class SFC_Autoship_Model_Subscription extends Mage_Core_Model_Abstract
|
25 |
+
{
|
26 |
+
/**
|
27 |
+
* Constants
|
28 |
+
*/
|
29 |
+
// Subscription statuses
|
30 |
+
const STATUS_ACTIVE = 'Active';
|
31 |
+
const STATUS_CANCELLED = 'Cancelled';
|
32 |
+
const STATUS_PAUSED = 'Paused';
|
33 |
+
const STATUS_FAILED = 'Failed';
|
34 |
+
|
35 |
+
// Members
|
36 |
+
private $_platformProduct = null;
|
37 |
+
private $_paymentProfile = null;
|
38 |
+
|
39 |
+
protected function _construct()
|
40 |
+
{
|
41 |
+
parent::_construct();
|
42 |
+
// Set default
|
43 |
+
$this->setData('send_customer_notification', true);
|
44 |
+
}
|
45 |
+
|
46 |
+
public function getCustomer()
|
47 |
+
{
|
48 |
+
$customer = Mage::getModel('customer/customer')->load($this->getCustomerId());
|
49 |
+
|
50 |
+
return $customer;
|
51 |
+
}
|
52 |
+
|
53 |
+
public function getBillingAddress()
|
54 |
+
{
|
55 |
+
$address = Mage::getModel('customer/address')->load($this->getBillingAddressId());
|
56 |
+
|
57 |
+
return $address;
|
58 |
+
}
|
59 |
+
|
60 |
+
public function getShippingAddress()
|
61 |
+
{
|
62 |
+
$address = Mage::getModel('customer/address')->load($this->getShippingAddressId());
|
63 |
+
|
64 |
+
return $address;
|
65 |
+
}
|
66 |
+
|
67 |
+
public function getPaymentProfile()
|
68 |
+
{
|
69 |
+
if($this->_paymentProfile == null || $this->_paymentProfile->getData('cim_payment_profile_id') != $this->getData('cim_payment_profile_id')) {
|
70 |
+
$this->_paymentProfile = Mage::getModel('authnettoken/cim_payment_profile')->getCollection()
|
71 |
+
->addFieldToFilter('cim_payment_profile_id', $this->getData('cim_payment_profile_id'))
|
72 |
+
->getFirstItem();
|
73 |
+
}
|
74 |
+
|
75 |
+
return $this->_paymentProfile;
|
76 |
+
}
|
77 |
+
|
78 |
+
public function getProduct()
|
79 |
+
{
|
80 |
+
return Mage::getModel('catalog/product')->load($this->getData('product_id'));
|
81 |
+
}
|
82 |
+
|
83 |
+
public function getPlatformProduct()
|
84 |
+
{
|
85 |
+
if($this->_platformProduct == null || $this->_platformProduct->getData('product_id') != $this->getData('product_id')) {
|
86 |
+
$this->_platformProduct = Mage::helper('autoship/platform')->getPlatformProduct($this->getProduct());
|
87 |
+
}
|
88 |
+
|
89 |
+
return $this->_platformProduct;
|
90 |
+
}
|
91 |
+
|
92 |
+
public function getIntervalText()
|
93 |
+
{
|
94 |
+
return $this->getInterval();
|
95 |
+
}
|
96 |
+
|
97 |
+
public function getQtyText()
|
98 |
+
{
|
99 |
+
if (substr($this->getQty(), -5) === '.0000') {
|
100 |
+
return substr($this->getQty(), 0, -5);
|
101 |
+
}
|
102 |
+
else {
|
103 |
+
return $this->getQty();
|
104 |
+
}
|
105 |
+
}
|
106 |
+
|
107 |
+
public function getNextOrderDateText()
|
108 |
+
{
|
109 |
+
$date = date_create_from_format('Y-m-d', $this->getNextOrderDate());
|
110 |
+
|
111 |
+
return date_format($date, 'm/d/y');
|
112 |
+
}
|
113 |
+
|
114 |
+
}
|
app/code/local/SFC/Autoship/Model/System/Config/Source/Cartrulediscountcombinetype.php
ADDED
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Model_System_Config_Source_Cartrulediscountcombinetype
|
19 |
+
{
|
20 |
+
|
21 |
+
const TYPE_APPLY_GREATEST = 0;
|
22 |
+
const TYPE_APPLY_LEAST = 1;
|
23 |
+
const TYPE_APPLY_CART_DISCOUNT = 2;
|
24 |
+
const TYPE_APPLY_SUBSCRIPTION = 3;
|
25 |
+
const TYPE_COMBINE_SUBSCRIPTION = 4;
|
26 |
+
|
27 |
+
/**
|
28 |
+
* Options getter
|
29 |
+
*
|
30 |
+
* @return array
|
31 |
+
*/
|
32 |
+
public function toOptionArray()
|
33 |
+
{
|
34 |
+
return array(
|
35 |
+
array('value' => self::TYPE_COMBINE_SUBSCRIPTION, 'label'=>Mage::helper('adminhtml')->__('Combine Subscription Discount With Other Discounts')),
|
36 |
+
array('value' => self::TYPE_APPLY_GREATEST, 'label'=>Mage::helper('adminhtml')->__('Apply Greatest Discount')),
|
37 |
+
array('value' => self::TYPE_APPLY_LEAST, 'label'=>Mage::helper('adminhtml')->__('Apply Least Discount')),
|
38 |
+
array('value' => self::TYPE_APPLY_CART_DISCOUNT, 'label'=>Mage::helper('adminhtml')->__('Always Apply Cart Rule Discount')),
|
39 |
+
array('value' => self::TYPE_APPLY_SUBSCRIPTION, 'label'=>Mage::helper('adminhtml')->__('Always Apply Subscription Discount')),
|
40 |
+
);
|
41 |
+
}
|
42 |
+
|
43 |
+
/**
|
44 |
+
* Get options in "key-value" format
|
45 |
+
*
|
46 |
+
* @return array
|
47 |
+
*/
|
48 |
+
public function toArray()
|
49 |
+
{
|
50 |
+
$valueArray = array();
|
51 |
+
foreach($this->toOptionArray() as $curElement) {
|
52 |
+
$valueArray[$curElement['value']] = $curElement['label'];
|
53 |
+
}
|
54 |
+
return $valueArray;
|
55 |
+
}
|
56 |
+
|
57 |
+
}
|
app/code/local/SFC/Autoship/Model/System/Config/Source/Cctype.php
ADDED
@@ -0,0 +1,97 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Model_System_Config_Source_Cctype extends Mage_Payment_Model_Source_Cctype
|
19 |
+
{
|
20 |
+
public function getAllowedTypes()
|
21 |
+
{
|
22 |
+
// Lookup available types in payment method config
|
23 |
+
$availableTypes = Mage::getStoreConfig('payment/' . SFC_Autoship_Model_Payment_Method::METHOD_CODE . '/cctypes');
|
24 |
+
// Explode available types
|
25 |
+
$availableTypes = explode(',', $availableTypes);
|
26 |
+
|
27 |
+
return $availableTypes;
|
28 |
+
}
|
29 |
+
|
30 |
+
public function getCcAvailableTypes()
|
31 |
+
{
|
32 |
+
// Use parent to get option array
|
33 |
+
$optionArray = $this->toOptionArray();
|
34 |
+
// Parse option array into simple hash
|
35 |
+
$availableTypes = array();
|
36 |
+
foreach ($optionArray as $option) {
|
37 |
+
$availableTypes[$option['value']] = $option['label'];
|
38 |
+
}
|
39 |
+
|
40 |
+
return $availableTypes;
|
41 |
+
}
|
42 |
+
|
43 |
+
public function getCcAvailableTypesSubscribeProFormat()
|
44 |
+
{
|
45 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
46 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
47 |
+
|
48 |
+
// Use parent to get option array
|
49 |
+
$optionArray = $this->toOptionArray();
|
50 |
+
// Parse option array into simple hash
|
51 |
+
$availableTypes = array();
|
52 |
+
foreach ($optionArray as $option) {
|
53 |
+
$ccType = $vaultHelper->mapMagentoCardTypeToSubscribePro($option['value'], false);
|
54 |
+
if (strlen($ccType)) {
|
55 |
+
$availableTypes[$ccType] = $option['label'];
|
56 |
+
}
|
57 |
+
}
|
58 |
+
|
59 |
+
return $availableTypes;
|
60 |
+
}
|
61 |
+
|
62 |
+
public function getCcAllTypesSubscribeProFormat()
|
63 |
+
{
|
64 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
65 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
66 |
+
|
67 |
+
// Parse option array into simple hash
|
68 |
+
$availableTypes = array();
|
69 |
+
foreach (Mage::getSingleton('payment/config')->getCcTypes() as $code => $name) {
|
70 |
+
try {
|
71 |
+
$availableTypes[$vaultHelper->mapMagentoCardTypeToSubscribePro($code)] = $name;
|
72 |
+
}
|
73 |
+
catch(\Exception $e) {
|
74 |
+
|
75 |
+
}
|
76 |
+
}
|
77 |
+
|
78 |
+
return $availableTypes;
|
79 |
+
}
|
80 |
+
|
81 |
+
public function toOptionArraySubscribeProFormat()
|
82 |
+
{
|
83 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
84 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
85 |
+
|
86 |
+
// Use parent to get option array
|
87 |
+
$optionArray = $this->toOptionArray();
|
88 |
+
foreach ($optionArray as $option) {
|
89 |
+
$ccType = $vaultHelper->mapMagentoCardTypeToSubscribePro($option['value'], false);
|
90 |
+
if (strlen($ccType)) {
|
91 |
+
$option['value'] = $ccType;
|
92 |
+
}
|
93 |
+
}
|
94 |
+
|
95 |
+
return $optionArray;
|
96 |
+
}
|
97 |
+
}
|
app/code/local/SFC/Autoship/Model/System/Config/Source/Month.php
ADDED
@@ -0,0 +1,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
*/
|
20 |
+
class SFC_Autoship_Model_System_Config_Source_Month
|
21 |
+
{
|
22 |
+
/**
|
23 |
+
* Retrieve Check Type Option array
|
24 |
+
*
|
25 |
+
* @return array
|
26 |
+
*/
|
27 |
+
public function toOptionArray()
|
28 |
+
{
|
29 |
+
return array(
|
30 |
+
array(
|
31 |
+
'value' => '01',
|
32 |
+
'label' => Mage::helper('autoship')->__('01 - January')
|
33 |
+
),
|
34 |
+
array(
|
35 |
+
'value' => '01',
|
36 |
+
'label' => Mage::helper('autoship')->__('01 - January')
|
37 |
+
),
|
38 |
+
array(
|
39 |
+
'value' => '02',
|
40 |
+
'label' => Mage::helper('autoship')->__('02 - February')
|
41 |
+
),
|
42 |
+
array(
|
43 |
+
'value' => '03',
|
44 |
+
'label' => Mage::helper('autoship')->__('03 - March')
|
45 |
+
),
|
46 |
+
array(
|
47 |
+
'value' => '04',
|
48 |
+
'label' => Mage::helper('autoship')->__('04 - April')
|
49 |
+
),
|
50 |
+
array(
|
51 |
+
'value' => '05',
|
52 |
+
'label' => Mage::helper('autoship')->__('05 - May')
|
53 |
+
),
|
54 |
+
array(
|
55 |
+
'value' => '06',
|
56 |
+
'label' => Mage::helper('autoship')->__('06 - June')
|
57 |
+
),
|
58 |
+
array(
|
59 |
+
'value' => '07',
|
60 |
+
'label' => Mage::helper('autoship')->__('07 - July')
|
61 |
+
),
|
62 |
+
array(
|
63 |
+
'value' => '08',
|
64 |
+
'label' => Mage::helper('autoship')->__('08 - August')
|
65 |
+
),
|
66 |
+
array(
|
67 |
+
'value' => '09',
|
68 |
+
'label' => Mage::helper('autoship')->__('09 - September')
|
69 |
+
),
|
70 |
+
array(
|
71 |
+
'value' => '10',
|
72 |
+
'label' => Mage::helper('autoship')->__('10 - October')
|
73 |
+
),
|
74 |
+
array(
|
75 |
+
'value' => '11',
|
76 |
+
'label' => Mage::helper('autoship')->__('11 - November')
|
77 |
+
),
|
78 |
+
array(
|
79 |
+
'value' => '12',
|
80 |
+
'label' => Mage::helper('autoship')->__('12 - December')
|
81 |
+
),
|
82 |
+
);
|
83 |
+
}
|
84 |
+
}
|
app/code/local/SFC/Autoship/Model/System/Config/Source/Nextorderdatemode.php
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Model_System_Config_Source_Nextorderdatemode
|
19 |
+
{
|
20 |
+
|
21 |
+
const MODE_SINGLE_DATE = 0;
|
22 |
+
const MODE_MULTIPLE_DATES = 1;
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Options getter
|
26 |
+
*
|
27 |
+
* @return array
|
28 |
+
*/
|
29 |
+
public function toOptionArray()
|
30 |
+
{
|
31 |
+
return array(
|
32 |
+
array('value' => self::MODE_SINGLE_DATE, 'label'=>Mage::helper('adminhtml')->__('Force Single Date')),
|
33 |
+
array('value' => self::MODE_MULTIPLE_DATES, 'label'=>Mage::helper('adminhtml')->__('Allow Multiple Dates')),
|
34 |
+
);
|
35 |
+
}
|
36 |
+
|
37 |
+
/**
|
38 |
+
* Get options in "key-value" format
|
39 |
+
*
|
40 |
+
* @return array
|
41 |
+
*/
|
42 |
+
public function toArray()
|
43 |
+
{
|
44 |
+
$valueArray = array();
|
45 |
+
foreach($this->toOptionArray() as $curElement) {
|
46 |
+
$valueArray[$curElement['value']] = $curElement['label'];
|
47 |
+
}
|
48 |
+
return $valueArray;
|
49 |
+
}
|
50 |
+
|
51 |
+
}
|
app/code/local/SFC/Autoship/Model/System/Config/Source/Shippingmethods.php
ADDED
@@ -0,0 +1,34 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Model_System_Config_Source_Shippingmethods extends Mage_Adminhtml_Model_System_Config_Source_Shipping_Allmethods
|
19 |
+
{
|
20 |
+
|
21 |
+
/**
|
22 |
+
* Return all allowed shipping methods, only the active ones
|
23 |
+
*
|
24 |
+
* @param bool $isActiveOnlyFlag Flag is ignored, only included to make method signature compatible with parent
|
25 |
+
* @return array
|
26 |
+
*/
|
27 |
+
// @codingStandardsIgnoreStart
|
28 |
+
public function toOptionArray($isActiveOnlyFlag = false)
|
29 |
+
{
|
30 |
+
// Regardless of flag, only include active shipping carriers / methods
|
31 |
+
return parent::toOptionArray(true);
|
32 |
+
}
|
33 |
+
// @codingStandardsIgnoreEnd
|
34 |
+
}
|
app/code/local/SFC/Autoship/Model/System/Config/Source/Year.php
ADDED
@@ -0,0 +1,88 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* StoreFront CyberSource Tokenized Payment Extension for Magento
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of StoreFront Consulting, Inc.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_CyberSource
|
11 |
+
* @author Garth Brantley <garth@storefrontconsulting.com>
|
12 |
+
* @copyright 2009-2013 StoreFront Consulting, Inc. All Rights Reserved.
|
13 |
+
* @license http://www.storefrontconsulting.com/media/downloads/ExtensionLicense.pdf StoreFront Consulting Commercial License
|
14 |
+
* @link http://www.storefrontconsulting.com/cybersource-saved-credit-cards-extension-for-magento/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
*/
|
20 |
+
class SFC_Autoship_Model_System_Config_Source_Year
|
21 |
+
{
|
22 |
+
/**
|
23 |
+
* Retrieve Option array
|
24 |
+
*
|
25 |
+
* @return array
|
26 |
+
*/
|
27 |
+
public function toOptionArray()
|
28 |
+
{
|
29 |
+
$years = $this->_getConfig()->getYears();
|
30 |
+
$yearOptionArray = array();
|
31 |
+
foreach ($years as $year) {
|
32 |
+
$yearOptionArray[] = array(
|
33 |
+
'value' => $year,
|
34 |
+
'label' => Mage::helper('autoship')->__($year)
|
35 |
+
);
|
36 |
+
|
37 |
+
}
|
38 |
+
|
39 |
+
return $yearOptionArray;
|
40 |
+
}
|
41 |
+
|
42 |
+
/**
|
43 |
+
* Retrieve payment configuration object
|
44 |
+
*
|
45 |
+
* @return Mage_Payment_Model_Config
|
46 |
+
*/
|
47 |
+
protected function _getConfig()
|
48 |
+
{
|
49 |
+
return Mage::getSingleton('payment/config');
|
50 |
+
}
|
51 |
+
|
52 |
+
}
|
53 |
+
|
54 |
+
/**
|
55 |
+
*/
|
56 |
+
class SFC_CyberSource_Model_Source_Year
|
57 |
+
{
|
58 |
+
/**
|
59 |
+
* Retrieve Option array
|
60 |
+
*
|
61 |
+
* @return array
|
62 |
+
*/
|
63 |
+
public function toOptionArray()
|
64 |
+
{
|
65 |
+
$years = $this->_getConfig()->getYears();
|
66 |
+
$yearOptionArray = array();
|
67 |
+
foreach ($years as $year) {
|
68 |
+
$yearOptionArray[] = array(
|
69 |
+
'value' => $year,
|
70 |
+
'label' => Mage::helper('autoship')->__($year)
|
71 |
+
);
|
72 |
+
|
73 |
+
}
|
74 |
+
|
75 |
+
return $yearOptionArray;
|
76 |
+
}
|
77 |
+
|
78 |
+
/**
|
79 |
+
* Retrieve payment configuration object
|
80 |
+
*
|
81 |
+
* @return Mage_Payment_Model_Config
|
82 |
+
*/
|
83 |
+
protected function _getConfig()
|
84 |
+
{
|
85 |
+
return Mage::getSingleton('payment/config');
|
86 |
+
}
|
87 |
+
|
88 |
+
}
|
app/code/local/SFC/Autoship/controllers/Adminhtml/PaymentprofileController.php
ADDED
@@ -0,0 +1,269 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Adminhtml_PaymentprofileController extends Mage_Adminhtml_Controller_Action
|
19 |
+
{
|
20 |
+
|
21 |
+
/**
|
22 |
+
* Set admin breadcrumbs
|
23 |
+
*/
|
24 |
+
protected function _initAction()
|
25 |
+
{
|
26 |
+
$this->loadLayout();
|
27 |
+
$this->_setActiveMenu('customers/paymentprofile');
|
28 |
+
$this->_addBreadcrumb(
|
29 |
+
Mage::helper('adminhtml')->__('Payment Profile Manager'),
|
30 |
+
Mage::helper('adminhtml')->__('Payment Profile Manager'));
|
31 |
+
|
32 |
+
return $this;
|
33 |
+
}
|
34 |
+
|
35 |
+
/**
|
36 |
+
* Edit existing payment profile
|
37 |
+
*/
|
38 |
+
public function editAction()
|
39 |
+
{
|
40 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
41 |
+
$apiHelper = Mage::helper('autoship/api');
|
42 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
43 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
44 |
+
|
45 |
+
$this->_initAction();
|
46 |
+
|
47 |
+
$this->_title($this->__('Subscribe Pro'));
|
48 |
+
$this->_title($this->__('Customer'));
|
49 |
+
$this->_title($this->__('Edit Item'));
|
50 |
+
|
51 |
+
try {
|
52 |
+
// Get profile and customer IDs from request
|
53 |
+
$profileId = $this->getRequest()->getParam('id');
|
54 |
+
$customerId = $this->getRequest()->getParam('customer_id');
|
55 |
+
|
56 |
+
// Load customer
|
57 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
58 |
+
$customer = Mage::getModel('customer/customer')->load($customerId);
|
59 |
+
|
60 |
+
// Set store on api helper
|
61 |
+
$store = $customer->getStore();
|
62 |
+
$apiHelper->setConfigStore($store);
|
63 |
+
|
64 |
+
// Lookup profile via Subscribe Pro API
|
65 |
+
/** @var SFC_Autoship_Model_Payment_Profile $profile */
|
66 |
+
$profile = $vaultHelper->getPaymentProfile($profileId);
|
67 |
+
|
68 |
+
// Save profile in registry
|
69 |
+
Mage::register('paymentprofile_data', $profile);
|
70 |
+
Mage::register('customer_id', $customer->getId());
|
71 |
+
|
72 |
+
$this->loadLayout();
|
73 |
+
$this->_setActiveMenu('autoship/paymentprofile');
|
74 |
+
$this->_addBreadcrumb(Mage::helper('adminhtml')->__('Payment Profile'), Mage::helper('adminhtml')->__('Payment Profile'));
|
75 |
+
$this->_addBreadcrumb(Mage::helper('adminhtml')->__('Payment Profile'), Mage::helper('adminhtml')->__('Information'));
|
76 |
+
$this->getLayout()->getBlock('head')->setCanLoadExtJs(true);
|
77 |
+
$this->_addContent($this->getLayout()->createBlock('autoship/adminhtml_customer_paymentprofiles_edit'));
|
78 |
+
$this->_addLeft($this->getLayout()->createBlock('autoship/adminhtml_customer_paymentprofiles_edit_tabs'));
|
79 |
+
$this->renderLayout();
|
80 |
+
|
81 |
+
return;
|
82 |
+
}
|
83 |
+
catch(\Exception $e) {
|
84 |
+
Mage::getSingleton('adminhtml/session')->addError(Mage::helper('autoship')->__('Failed to find saved credit card.'));
|
85 |
+
$this->_redirect('*/*/');
|
86 |
+
}
|
87 |
+
}
|
88 |
+
|
89 |
+
/**
|
90 |
+
* Create new CIM payment profile
|
91 |
+
*/
|
92 |
+
public function newAction()
|
93 |
+
{
|
94 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
95 |
+
$apiHelper = Mage::helper('autoship/api');
|
96 |
+
|
97 |
+
$this->_title($this->__('Subscribe Pro'));
|
98 |
+
$this->_title($this->__('Payment Profile'));
|
99 |
+
$this->_title($this->__('New Payment Profile'));
|
100 |
+
|
101 |
+
// Get profile and customer IDs from request
|
102 |
+
$customerId = $this->getRequest()->getParam('customer_id');
|
103 |
+
|
104 |
+
// Load customer
|
105 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
106 |
+
$customer = Mage::getModel('customer/customer')->load($customerId);
|
107 |
+
|
108 |
+
// Set store on api helper
|
109 |
+
$store = $customer->getStore();
|
110 |
+
$apiHelper->setConfigStore($store);
|
111 |
+
|
112 |
+
// Create new model for editing & init with customer fields
|
113 |
+
/** @var SFC_Autoship_Model_Payment_Profile $profile */
|
114 |
+
$profile = Mage::getModel('autoship/payment_profile');
|
115 |
+
$profile->initProfileWithCustomerDefault($customer);
|
116 |
+
|
117 |
+
// Save profile in registry
|
118 |
+
Mage::register('paymentprofile_data', $profile);
|
119 |
+
Mage::register('customer_id', $customer->getId());
|
120 |
+
|
121 |
+
$this->loadLayout();
|
122 |
+
$this->_setActiveMenu('autoship/paymentprofile');
|
123 |
+
|
124 |
+
$this->getLayout()->getBlock('head')->setCanLoadExtJs(true);
|
125 |
+
|
126 |
+
$this->_addBreadcrumb(Mage::helper('autoship')->__('Payment Profile Manager'), Mage::helper('adminhtml')
|
127 |
+
->__('Payment Profile Manager'));
|
128 |
+
$this->_addBreadcrumb(Mage::helper('autoship')->__('Info'), Mage::helper('adminhtml')->__('info'));
|
129 |
+
|
130 |
+
|
131 |
+
$this->_addContent($this->getLayout()->createBlock('autoship/adminhtml_customer_paymentprofiles_edit'));
|
132 |
+
$this->_addLeft($this->getLayout()->createBlock('autoship/adminhtml_customer_paymentprofiles_edit_tabs'));
|
133 |
+
|
134 |
+
$this->renderLayout();
|
135 |
+
|
136 |
+
}
|
137 |
+
|
138 |
+
/**
|
139 |
+
* Save data to existing payment profile
|
140 |
+
*/
|
141 |
+
public function saveAction()
|
142 |
+
{
|
143 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
144 |
+
$apiHelper = Mage::helper('autoship/api');
|
145 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
146 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
147 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
148 |
+
$platformHelper = Mage::helper('autoship/platform');
|
149 |
+
|
150 |
+
$postData = $this->getRequest()->getPost();
|
151 |
+
|
152 |
+
if ($postData) {
|
153 |
+
try {
|
154 |
+
// Load customer
|
155 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
156 |
+
$customer = Mage::getModel('customer/customer')->load($postData['magento_customer_id']);
|
157 |
+
|
158 |
+
// Set store on api helper
|
159 |
+
$store = $customer->getStore();
|
160 |
+
$apiHelper->setConfigStore($store);
|
161 |
+
|
162 |
+
if ($profileId = $this->getRequest()->getParam('id')) {
|
163 |
+
// Get profile and customer IDs from request
|
164 |
+
$profileId = $postData['id'];
|
165 |
+
|
166 |
+
// Lookup profile via Subscribe Pro API
|
167 |
+
/** @var SFC_Autoship_Model_Payment_Profile $profile */
|
168 |
+
$profile = $vaultHelper->getPaymentProfile($profileId);
|
169 |
+
|
170 |
+
// Save post data to model
|
171 |
+
$profile->addData($postData);
|
172 |
+
$profile->unmapFlatFields();
|
173 |
+
|
174 |
+
// Call update method on API
|
175 |
+
$vaultHelper->updatePaymentProfile($profile);
|
176 |
+
}
|
177 |
+
else {
|
178 |
+
// Create new card
|
179 |
+
/** @var SFC_Autoship_Model_Payment_Profile $profile */
|
180 |
+
$profile = Mage::getModel('autoship/payment_profile');
|
181 |
+
$profile->initProfileWithCustomerDefault($customer);
|
182 |
+
|
183 |
+
// Save post data to model
|
184 |
+
$profile->addData($postData);
|
185 |
+
$profile->unmapFlatFields();
|
186 |
+
|
187 |
+
// Create or update customer and create pay profile
|
188 |
+
$platformHelper->createOrUpdateCustomer($customer);
|
189 |
+
$vaultHelper->createPaymentProfile($profile);
|
190 |
+
}
|
191 |
+
|
192 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Saved credit card.'));
|
193 |
+
Mage::getSingleton('adminhtml/session')->setCustomerData(false);
|
194 |
+
|
195 |
+
if ($this->getRequest()->getParam('back')) {
|
196 |
+
$this->_redirect('*/*/edit', array('id' => $profile->getId()));
|
197 |
+
|
198 |
+
return;
|
199 |
+
}
|
200 |
+
}
|
201 |
+
catch (Exception $e) {
|
202 |
+
Mage::getSingleton('adminhtml/session')->addError('Failed to save credit card!');
|
203 |
+
}
|
204 |
+
}
|
205 |
+
|
206 |
+
// Send customer back to saved credit cards grid
|
207 |
+
$this->_redirect('adminhtml/customer/edit/tab/customer_info_tabs_paymentprofile', array('id' => $postData['magento_customer_id']));
|
208 |
+
}
|
209 |
+
|
210 |
+
/**
|
211 |
+
* Delete multiple items
|
212 |
+
*/
|
213 |
+
public function massRemoveAction()
|
214 |
+
{
|
215 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
216 |
+
$apiHelper = Mage::helper('autoship/api');
|
217 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
218 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
219 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
220 |
+
$platformHelper = Mage::helper('autoship/platform');
|
221 |
+
|
222 |
+
// Get profile and customer IDs from request
|
223 |
+
$customerId = $this->getRequest()->getParam('customer_id');
|
224 |
+
|
225 |
+
try {
|
226 |
+
// Get list of profile ids to delete / redact
|
227 |
+
$profileIds = $this->getRequest()->getPost('ids', array());
|
228 |
+
|
229 |
+
// Load customer
|
230 |
+
/** @var Mage_Customer_Model_Customer $customer */
|
231 |
+
$customer = Mage::getModel('customer/customer')->load($customerId);
|
232 |
+
|
233 |
+
// Set store on api helper
|
234 |
+
$store = $customer->getStore();
|
235 |
+
$apiHelper->setConfigStore($store);
|
236 |
+
|
237 |
+
// Iterate each selected profile
|
238 |
+
foreach ($profileIds as $profileId) {
|
239 |
+
try {
|
240 |
+
$vaultHelper->redactPaymentProfileId($profileId);
|
241 |
+
}
|
242 |
+
catch (\Exception $e) {
|
243 |
+
$message =
|
244 |
+
'Failed to delete payment profile ID #' . $profileId;
|
245 |
+
Mage::getSingleton('adminhtml/session')->addError($message);
|
246 |
+
}
|
247 |
+
}
|
248 |
+
Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('autoship')->__('Deleted saved credit card(s).'));
|
249 |
+
}
|
250 |
+
catch (Exception $e) {
|
251 |
+
Mage::getSingleton('adminhtml/session')->addError('Failed to delete saved credit card!');
|
252 |
+
}
|
253 |
+
|
254 |
+
$this->_redirect('adminhtml/customer/edit/tab/customer_info_tabs_paymentprofile', array('id' => $customerId));
|
255 |
+
}
|
256 |
+
|
257 |
+
/**
|
258 |
+
* Profile grid for AJAX request
|
259 |
+
*/
|
260 |
+
public function gridAction()
|
261 |
+
{
|
262 |
+
$customer = Mage::getModel('customer/customer')->load($this->getRequest()->getParam('id'));
|
263 |
+
Mage::register('current_customer', $customer);
|
264 |
+
$this->getResponse()->setBody(
|
265 |
+
$this->getLayout()->createBlock('autoship/adminhtml_customer_paymentprofiles_paymentprofile')->toHtml()
|
266 |
+
);
|
267 |
+
}
|
268 |
+
|
269 |
+
}
|
app/code/local/SFC/Autoship/controllers/Adminhtml/TestconnectionbuttonController.php
ADDED
@@ -0,0 +1,83 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_Adminhtml_TestconnectionbuttonController extends Mage_Adminhtml_Controller_Action
|
19 |
+
{
|
20 |
+
|
21 |
+
public function testAction()
|
22 |
+
{
|
23 |
+
// Get platform helper
|
24 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
25 |
+
$platformHelper = Mage::helper('autoship/platform');
|
26 |
+
/** @var SFC_Autoship_Helper_Api $apiHelper */
|
27 |
+
$apiHelper = Mage::helper('autoship/api');
|
28 |
+
$store = $this->getStore();
|
29 |
+
// Set store on api helper
|
30 |
+
$apiHelper->setConfigStore($store);
|
31 |
+
// Log
|
32 |
+
Mage::log('Testing connection for website: ' . $store->getWebsite()->getCode() . ' and store: ' . $store->getCode(), Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
33 |
+
// Clear cache
|
34 |
+
Mage::app()->cleanCache(array(SFC_Autoship_Helper_Api::CACHE_TYPE_CONFIG, SFC_Autoship_Helper_Api::CACHE_TYPE_PRODUCTS));
|
35 |
+
// Update configuration
|
36 |
+
$this->updateStoreConfiguration();
|
37 |
+
// Call platform to get Account Configuration, just to test connection
|
38 |
+
try {
|
39 |
+
$platformHelper->getAccountConfig();
|
40 |
+
Mage::log('Connection test successful.', Zend_Log::INFO, SFC_Autoship_Helper_Data::LOG_FILE);
|
41 |
+
$result = 1;
|
42 |
+
}
|
43 |
+
catch(\Exception $e) {
|
44 |
+
Mage::logException($e);
|
45 |
+
Mage::log('Connection test failed!', Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
46 |
+
$result = 0;
|
47 |
+
}
|
48 |
+
// Return result
|
49 |
+
Mage::app()->getResponse()->setBody($result);
|
50 |
+
}
|
51 |
+
|
52 |
+
/**
|
53 |
+
* Save configuration values from ajax call. Only save them temporarily so we can test that they work.
|
54 |
+
* Don't save them permanently until user clicks Save Config button.
|
55 |
+
*/
|
56 |
+
protected function updateStoreConfiguration()
|
57 |
+
{
|
58 |
+
$store = $this->getStore();
|
59 |
+
$store->setConfig('autoship_general/platform_api/platform_host', $this->getRequest()->getParam('host'));
|
60 |
+
$store->setConfig('autoship_general/platform_api/client_id', Mage::helper('core')->encrypt($this->getRequest()->getParam('client_id'), $store));
|
61 |
+
$clientSecret = $this->getRequest()->getParam('client_secret');
|
62 |
+
if (strlen($clientSecret) && $clientSecret != '******') {
|
63 |
+
$store->setConfig('autoship_general/platform_api/client_secret', Mage::helper('core')->encrypt($this->getRequest()->getParam('client_secret'), $store));
|
64 |
+
}
|
65 |
+
}
|
66 |
+
|
67 |
+
/**
|
68 |
+
* @return Mage_Core_Model_Store
|
69 |
+
*/
|
70 |
+
protected function getStore()
|
71 |
+
{
|
72 |
+
$params = $this->getRequest()->getParams();
|
73 |
+
if (isset($params['website']) && strlen($params['website'])) {
|
74 |
+
$store = Mage::app()->getWebsite($params['website'])->getDefaultStore();
|
75 |
+
}
|
76 |
+
else {
|
77 |
+
$store = Mage::app()->getStore();
|
78 |
+
}
|
79 |
+
|
80 |
+
return $store;
|
81 |
+
}
|
82 |
+
|
83 |
+
}
|
app/code/local/SFC/Autoship/controllers/MycreditcardsController.php
ADDED
@@ -0,0 +1,246 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
class SFC_Autoship_MycreditcardsController extends Mage_Core_Controller_Front_Action
|
19 |
+
{
|
20 |
+
/**
|
21 |
+
* Authenticate customer
|
22 |
+
*/
|
23 |
+
public function preDispatch()
|
24 |
+
{
|
25 |
+
parent::preDispatch();
|
26 |
+
// Require logged in customer
|
27 |
+
if (!Mage::getSingleton('customer/session')->authenticate($this)) {
|
28 |
+
$this->setFlag('', 'no-dispatch', true);
|
29 |
+
}
|
30 |
+
// Check if payment vault payment method enabled
|
31 |
+
if (Mage::getStoreConfig('payment/' . SFC_Autoship_Model_Payment_Method::METHOD_CODE . '/active') != '1') {
|
32 |
+
// Send customer to 404 page
|
33 |
+
$this->_forward('defaultNoRoute');
|
34 |
+
return;
|
35 |
+
}
|
36 |
+
}
|
37 |
+
|
38 |
+
/**
|
39 |
+
* Authorize customer from session against the specified profile. This ensures customer is allowed to edit / update / delete profile.
|
40 |
+
*
|
41 |
+
* @param SFC_CyberSource_Model_payment_profile $paymentProfile Profile to authorize against current customer
|
42 |
+
* @throws SFC_CyberSource_Helper_Gateway_Exception
|
43 |
+
*/
|
44 |
+
protected function authorizeCustomerForProfile(SFC_CyberSource_Model_payment_profile $paymentProfile)
|
45 |
+
{
|
46 |
+
// Get customer session
|
47 |
+
/** @var Mage_Customer_Model_Session $customerSession */
|
48 |
+
$customerSession = Mage::getSingleton('customer/session');
|
49 |
+
// Authorize customer for this profile - in other words profile must belong to this customer
|
50 |
+
if ($customerSession->getCustomerId() != $paymentProfile->getData('customer_id')) {
|
51 |
+
throw new SFC_CyberSource_Helper_Gateway_Exception('Customer not authorized to edit this profile!');
|
52 |
+
}
|
53 |
+
}
|
54 |
+
|
55 |
+
/**
|
56 |
+
* Customer Dashboard, payment profile grid
|
57 |
+
*/
|
58 |
+
public function indexAction()
|
59 |
+
{
|
60 |
+
// Load layout
|
61 |
+
$this->loadLayout();
|
62 |
+
|
63 |
+
// Set page title
|
64 |
+
/** @var Mage_Page_Block_Html_Head $headBlock */
|
65 |
+
$headBlock = $this->getLayout()->getBlock('head');
|
66 |
+
$headBlock->setTitle($this->__('My Credit Cards'));
|
67 |
+
|
68 |
+
$this->renderLayout();
|
69 |
+
}
|
70 |
+
|
71 |
+
/**
|
72 |
+
* New payment profile
|
73 |
+
*/
|
74 |
+
public function newAction()
|
75 |
+
{
|
76 |
+
// Get core session
|
77 |
+
/** @var Mage_Core_Model_Session $coreSession */
|
78 |
+
$coreSession = Mage::getSingleton('core/session');
|
79 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
80 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
81 |
+
// Get customer session
|
82 |
+
/** @var Mage_Customer_Model_Session $customerSession */
|
83 |
+
$customerSession = Mage::getSingleton('customer/session');
|
84 |
+
|
85 |
+
// Load layout
|
86 |
+
$this->loadLayout();
|
87 |
+
|
88 |
+
// Set page title
|
89 |
+
/** @var Mage_Page_Block_Html_Head $headBlock */
|
90 |
+
$headBlock = $this->getLayout()->getBlock('head');
|
91 |
+
$headBlock->setTitle($this->__('Enter New Saved Credit Card'));
|
92 |
+
|
93 |
+
try {
|
94 |
+
// Create new profile
|
95 |
+
/** @var SFC_Autoship_Model_Payment_Profile $paymentProfile */
|
96 |
+
$paymentProfile = Mage::getModel('autoship/payment_profile');
|
97 |
+
// Init new cim profile with customer info
|
98 |
+
$paymentProfile->initProfileWithCustomerDefault($customerSession->getCustomerId());
|
99 |
+
// Pass fields to view for rendering
|
100 |
+
$this->getLayout()->getBlock('payment_profile_edit')->setData('cim_profile', $paymentProfile);
|
101 |
+
}
|
102 |
+
catch (Exception $e) {
|
103 |
+
$coreSession->addError('Failed to load new credit credit card page!');
|
104 |
+
// Send customer back to grid
|
105 |
+
$this->_redirect('creditcards/*/');
|
106 |
+
|
107 |
+
return;
|
108 |
+
}
|
109 |
+
|
110 |
+
// Render layout
|
111 |
+
$this->renderLayout();
|
112 |
+
}
|
113 |
+
|
114 |
+
/**
|
115 |
+
* Edit payment profile
|
116 |
+
*/
|
117 |
+
public function editAction()
|
118 |
+
{
|
119 |
+
// Get core session
|
120 |
+
/** @var Mage_Core_Model_Session $coreSession */
|
121 |
+
$coreSession = Mage::getSingleton('core/session');
|
122 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
123 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
124 |
+
|
125 |
+
// Load layout
|
126 |
+
$this->loadLayout();
|
127 |
+
|
128 |
+
// Set page title
|
129 |
+
/** @var Mage_Page_Block_Html_Head $headBlock */
|
130 |
+
$headBlock = $this->getLayout()->getBlock('head');
|
131 |
+
$headBlock->setTitle($this->__('Edit Saved Credit Card'));
|
132 |
+
|
133 |
+
try {
|
134 |
+
// Get profile ID & load the profile
|
135 |
+
$profileId = $this->getRequest()->getParam('id');
|
136 |
+
$paymentProfile = $vaultHelper->getPaymentProfile($profileId);
|
137 |
+
// Pass fields to view for rendering
|
138 |
+
$this->getLayout()->getBlock('payment_profile_edit')->setData('cim_profile', $paymentProfile);
|
139 |
+
}
|
140 |
+
catch (Exception $e) {
|
141 |
+
Mage::log('Error: ' . $e->getMessage(), Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
142 |
+
$coreSession->addError('Failed to retrieve credit card for edit!');
|
143 |
+
// Send customer back to grid
|
144 |
+
$this->_redirect('subscriptions/mycreditcards/');
|
145 |
+
|
146 |
+
return;
|
147 |
+
}
|
148 |
+
|
149 |
+
$this->renderLayout();
|
150 |
+
}
|
151 |
+
|
152 |
+
public function redirectAction()
|
153 |
+
{
|
154 |
+
// Get core session
|
155 |
+
/** @var Mage_Core_Model_Session $coreSession */
|
156 |
+
$coreSession = Mage::getSingleton('core/session');
|
157 |
+
// Get customer session
|
158 |
+
/** @var Mage_Customer_Model_Session $customerSession */
|
159 |
+
$customerSession = Mage::getSingleton('customer/session');
|
160 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
161 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
162 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
163 |
+
$platformHelper = Mage::helper('autoship/platform');
|
164 |
+
|
165 |
+
try {
|
166 |
+
// Get token
|
167 |
+
$token = $this->getRequest()->getParam('token');
|
168 |
+
// Create or update customer on platform
|
169 |
+
$platformHelper->createOrUpdateCustomer($customerSession->getCustomer());
|
170 |
+
// Store token
|
171 |
+
$vaultHelper->storeToken($customerSession->getCustomerId(), $token);
|
172 |
+
}
|
173 |
+
catch (Exception $e) {
|
174 |
+
Mage::log('Error: ' . $e->getMessage(), Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
175 |
+
$coreSession->addError('Failed to store credit card!');
|
176 |
+
}
|
177 |
+
|
178 |
+
// Send customer back to grid
|
179 |
+
$this->_redirect('subscriptions/mycreditcards/');
|
180 |
+
}
|
181 |
+
|
182 |
+
/**
|
183 |
+
* Save a payment profile which is being edited
|
184 |
+
*/
|
185 |
+
public function saveAction()
|
186 |
+
{
|
187 |
+
// Get core session
|
188 |
+
/** @var Mage_Core_Model_Session $coreSession */
|
189 |
+
$coreSession = Mage::getSingleton('core/session');
|
190 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
191 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
192 |
+
|
193 |
+
// Get post data
|
194 |
+
$postData = $this->getRequest()->getPost();
|
195 |
+
//print_r($postData);die;
|
196 |
+
|
197 |
+
try {
|
198 |
+
// Get profile ID & load the profile
|
199 |
+
$profileId = $postData['payment_profile_id'];
|
200 |
+
$paymentProfile = $vaultHelper->getPaymentProfile($profileId);
|
201 |
+
// Update payment profile with post data
|
202 |
+
$paymentProfile->updatePaymentProfileFromVaultData($postData);
|
203 |
+
// Update profile in vault
|
204 |
+
$vaultHelper->updatePaymentProfile($paymentProfile);
|
205 |
+
|
206 |
+
$coreSession->addSuccess('Credit card was successfully updated!');
|
207 |
+
}
|
208 |
+
catch (Exception $e) {
|
209 |
+
Mage::log('Error: ' . $e->getMessage(), Zend_Log::ERR, SFC_Autoship_Helper_Data::LOG_FILE);
|
210 |
+
$coreSession->addError('Failed to save credit card!');
|
211 |
+
}
|
212 |
+
|
213 |
+
// Send customer back to grid
|
214 |
+
$this->_redirect('subscriptions/mycreditcards/');
|
215 |
+
}
|
216 |
+
|
217 |
+
/**
|
218 |
+
* Delete payment profile
|
219 |
+
*/
|
220 |
+
public function deleteAction()
|
221 |
+
{
|
222 |
+
// Get core session
|
223 |
+
/** @var Mage_Core_Model_Session $coreSession */
|
224 |
+
$coreSession = Mage::getSingleton('core/session');
|
225 |
+
/** @var SFC_Autoship_Helper_Vault $vaultHelper */
|
226 |
+
$vaultHelper = Mage::helper('autoship/vault');
|
227 |
+
|
228 |
+
// Get id of profile to delete
|
229 |
+
$profileId = $this->getRequest()->getParam('id');
|
230 |
+
try {
|
231 |
+
// Get pay profile
|
232 |
+
$paymentProfile = $vaultHelper->getPaymentProfile($profileId);
|
233 |
+
// Redact profile in vault
|
234 |
+
$vaultHelper->redactPaymentProfile($paymentProfile);
|
235 |
+
|
236 |
+
$coreSession->addSuccess('Your credit card was deleted.');
|
237 |
+
}
|
238 |
+
catch (Exception $e) {
|
239 |
+
$coreSession->addError('Failed to delete saved credit card!');
|
240 |
+
}
|
241 |
+
|
242 |
+
// Send customer back to grid
|
243 |
+
$this->_redirect('subscriptions/mycreditcards/');
|
244 |
+
}
|
245 |
+
|
246 |
+
}
|
app/code/local/SFC/Autoship/controllers/MysubscriptionsController.php
ADDED
@@ -0,0 +1,690 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Controller to handle the My Subscriptions page in the customer account dashboard section of the frontend
|
21 |
+
*/
|
22 |
+
class SFC_Autoship_MysubscriptionsController extends Mage_Core_Controller_Front_Action
|
23 |
+
{
|
24 |
+
/**
|
25 |
+
* Authenticate customer
|
26 |
+
*/
|
27 |
+
public function preDispatch()
|
28 |
+
{
|
29 |
+
parent::preDispatch();
|
30 |
+
// Require logged in customer
|
31 |
+
if (!Mage::getSingleton('customer/session')->authenticate($this)) {
|
32 |
+
$this->setFlag('', 'no-dispatch', true);
|
33 |
+
}
|
34 |
+
// Check if extension enabled
|
35 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled') != '1') {
|
36 |
+
// Send customer to 404 page
|
37 |
+
$this->_forward('defaultNoRoute');
|
38 |
+
return;
|
39 |
+
}
|
40 |
+
}
|
41 |
+
|
42 |
+
/**
|
43 |
+
* Customer Dashboard - My Product Subscriptions page
|
44 |
+
*/
|
45 |
+
public function indexAction()
|
46 |
+
{
|
47 |
+
// Load layout from XML
|
48 |
+
$this->loadLayout();
|
49 |
+
|
50 |
+
// Set page title for this page
|
51 |
+
$this->getLayout()->getBlock('head')->setTitle($this->__('My Subscriptions'));
|
52 |
+
|
53 |
+
// Render the layout
|
54 |
+
$this->renderLayout();
|
55 |
+
}
|
56 |
+
|
57 |
+
/**
|
58 |
+
* Update interval, qty or next order date action
|
59 |
+
*/
|
60 |
+
public function changeAction()
|
61 |
+
{
|
62 |
+
try {
|
63 |
+
// Get POST data
|
64 |
+
$postData = $this->validateChangePostData();
|
65 |
+
|
66 |
+
// Get customer
|
67 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
68 |
+
// Call platform to get subscription(s)
|
69 |
+
if($postData['subscription_id'] == 'all_active') {
|
70 |
+
$subscriptions = Mage::helper('autoship/platform')->getSubscriptions(
|
71 |
+
$customer,
|
72 |
+
array(
|
73 |
+
'status' => 'Active',
|
74 |
+
));
|
75 |
+
$firstSubscription = $subscriptions[0];
|
76 |
+
}
|
77 |
+
else {
|
78 |
+
$firstSubscription = Mage::helper('autoship/platform')->getSubscription($postData['subscription_id']);
|
79 |
+
$subscriptions[] = $firstSubscription;
|
80 |
+
// Modify qty, interval
|
81 |
+
if (isset($postData['interval'])) {
|
82 |
+
$firstSubscription->setInterval($postData['interval']);
|
83 |
+
}
|
84 |
+
if (isset($postData['qty'])) {
|
85 |
+
$firstSubscription->setQty($postData['qty']);
|
86 |
+
}
|
87 |
+
}
|
88 |
+
|
89 |
+
// Modify next order date
|
90 |
+
if (isset($postData['delivery_date'])) {
|
91 |
+
foreach($subscriptions as $subscription) {
|
92 |
+
$subscription->setNextOrderDate($postData['delivery_date']);
|
93 |
+
}
|
94 |
+
}
|
95 |
+
// Send changes to platform
|
96 |
+
foreach($subscriptions as $subscription) {
|
97 |
+
$newSubscriptionId = Mage::helper('autoship/platform')->updateSubscription($subscription->getSubscriptionId(), $subscription);
|
98 |
+
}
|
99 |
+
// Return the rendered html for this new subscription state
|
100 |
+
if($postData['subscription_id'] == 'all_active') {
|
101 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions')
|
102 |
+
->setTemplate('autoship/mysubscriptions.phtml')
|
103 |
+
->toHtml();
|
104 |
+
}
|
105 |
+
else {
|
106 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
107 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
108 |
+
->setSubscription($firstSubscription)
|
109 |
+
->toHtml();
|
110 |
+
}
|
111 |
+
}
|
112 |
+
catch (Exception $e) {
|
113 |
+
$this->handleAjaxException($e);
|
114 |
+
}
|
115 |
+
}
|
116 |
+
|
117 |
+
/**
|
118 |
+
* Retrieve post data for changeAction and validate it
|
119 |
+
*/
|
120 |
+
protected function validateChangePostData()
|
121 |
+
{
|
122 |
+
$data = $this->getRequest()->getPost();
|
123 |
+
if (!is_array($data)) {
|
124 |
+
Mage::throwException('Failed to process POST data!');
|
125 |
+
}
|
126 |
+
// Validate POST data and return in array
|
127 |
+
$validatedPostData = array();
|
128 |
+
if (isset($data['id']) && strlen($data['id'])) {
|
129 |
+
$validatedPostData['subscription_id'] = $data['id'];
|
130 |
+
}
|
131 |
+
if (isset($data['delivery_qty']) && strlen($data['delivery_qty'])) {
|
132 |
+
if (!is_numeric($data['delivery_qty'])) {
|
133 |
+
Mage::throwException('Please specify a numeric value for subscription quantity!');
|
134 |
+
}
|
135 |
+
$validatedPostData['qty'] = $data['delivery_qty'];
|
136 |
+
}
|
137 |
+
if (isset($data['delivery_interval']) && strlen($data['delivery_interval'])) {
|
138 |
+
$validatedPostData['interval'] = $data['delivery_interval'];
|
139 |
+
}
|
140 |
+
if (isset($data['delivery_date']) && strlen($data['delivery_date'])) {
|
141 |
+
$validatedPostData['delivery_date'] = date('Y-m-d', strtotime($data['delivery_date']));
|
142 |
+
}
|
143 |
+
if (isset($data['shipping_address_id']) && strlen($data['shipping_address_id'])) {
|
144 |
+
if (is_numeric($data['shipping_address_id'])) {
|
145 |
+
$validatedPostData['shipping_address_id'] = $data['shipping_address_id'];
|
146 |
+
}
|
147 |
+
}
|
148 |
+
if (isset($data['billing_address_id']) && strlen($data['billing_address_id'])) {
|
149 |
+
if (is_numeric($data['billing_address_id'])) {
|
150 |
+
$validatedPostData['billing_address_id'] = $data['billing_address_id'];
|
151 |
+
}
|
152 |
+
}
|
153 |
+
if (isset($data['payment']) && is_array($data['payment'])) {
|
154 |
+
$validatedPostData['payment'] = $data['payment'];
|
155 |
+
}
|
156 |
+
if (isset($data['shipping']) && is_array($data['shipping'])) {
|
157 |
+
$validatedPostData['shipping'] = $data['shipping'];
|
158 |
+
}
|
159 |
+
if (isset($data['billing']) && is_array($data['billing'])) {
|
160 |
+
$validatedPostData['billing'] = $data['billing'];
|
161 |
+
}
|
162 |
+
|
163 |
+
// Return validate POST data
|
164 |
+
return $validatedPostData;
|
165 |
+
}
|
166 |
+
|
167 |
+
/**
|
168 |
+
* Save payment method action
|
169 |
+
*/
|
170 |
+
public function paymentsaveAction()
|
171 |
+
{
|
172 |
+
try {
|
173 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
174 |
+
$platformHelper = Mage::helper('autoship/platform');
|
175 |
+
// Get config setting
|
176 |
+
$nextOrderDateMode = Mage::getStoreConfig('autoship_subscription/options/next_order_date_mode');
|
177 |
+
// Get customer
|
178 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
179 |
+
// Get POST data
|
180 |
+
$postData = $this->validateChangePostData();
|
181 |
+
if($nextOrderDateMode != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES) {
|
182 |
+
$subscriptions = $platformHelper->getSubscriptions(
|
183 |
+
$customer,
|
184 |
+
array(
|
185 |
+
'status' => 'Active',
|
186 |
+
));
|
187 |
+
$firstSubscription = $subscriptions[0];
|
188 |
+
}
|
189 |
+
else {
|
190 |
+
$firstSubscription = $platformHelper->getSubscription($postData['subscription_id']);
|
191 |
+
$subscriptions[] = $firstSubscription;
|
192 |
+
}
|
193 |
+
|
194 |
+
// Get payment POST data
|
195 |
+
$data = $postData['payment'];
|
196 |
+
// switched saved card
|
197 |
+
if ($data['method'] != 'new_cc') {
|
198 |
+
$paymentToken = $data['method'];
|
199 |
+
$creditcardLastDigits = $data['creditcard_last_digits'][$data['method']];
|
200 |
+
}
|
201 |
+
else {
|
202 |
+
// Create and save new profile to CIM and DB
|
203 |
+
$result = $this->createNewPaymentProfile($firstSubscription, $data);
|
204 |
+
$paymentToken = $result['payment_token'];
|
205 |
+
$creditcardLastDigits = $result['creditcard_last_digits'];
|
206 |
+
}
|
207 |
+
// Now set profile id on subscription
|
208 |
+
// Set shipping address on subscriptions
|
209 |
+
foreach($subscriptions as $subscription) {
|
210 |
+
$subscription->setData('payment_method_code', $platformHelper->getConfiguredPaymentMethodCode());
|
211 |
+
$subscription->setData('payment_token', $paymentToken);
|
212 |
+
$subscription->setData('customer_cardnumber', $creditcardLastDigits);
|
213 |
+
$subscription->setData('creditcard_last_digits', $creditcardLastDigits);
|
214 |
+
}
|
215 |
+
|
216 |
+
// Send changes to platform
|
217 |
+
foreach($subscriptions as $subscription) {
|
218 |
+
$newSubscriptionId = $platformHelper->updateSubscription($subscription->getSubscriptionId(), $subscription);
|
219 |
+
}
|
220 |
+
// Return the rendered html for this new subscription state
|
221 |
+
if($nextOrderDateMode != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES) {
|
222 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions')
|
223 |
+
->setTemplate('autoship/mysubscriptions.phtml')
|
224 |
+
->toHtml();
|
225 |
+
}
|
226 |
+
else {
|
227 |
+
// Re-fetch subscription from platform
|
228 |
+
$updatedSubscription = $platformHelper->getSubscription($newSubscriptionId);
|
229 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
230 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
231 |
+
->setSubscription($updatedSubscription)
|
232 |
+
->toHtml();
|
233 |
+
}
|
234 |
+
}
|
235 |
+
catch (Exception $e) {
|
236 |
+
$this->handleAjaxException($e);
|
237 |
+
}
|
238 |
+
}
|
239 |
+
|
240 |
+
/**
|
241 |
+
* Save shipping address action
|
242 |
+
*/
|
243 |
+
public function shippingsaveAction()
|
244 |
+
{
|
245 |
+
try {
|
246 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
247 |
+
$platformHelper = Mage::helper('autoship/platform');
|
248 |
+
// Get config setting
|
249 |
+
$nextOrderDateMode = Mage::getStoreConfig('autoship_subscription/options/next_order_date_mode');
|
250 |
+
// Get customer
|
251 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
252 |
+
// Get POST data
|
253 |
+
$postData = $this->validateChangePostData();
|
254 |
+
if($nextOrderDateMode != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES) {
|
255 |
+
$subscriptions = $platformHelper->getSubscriptions(
|
256 |
+
$customer,
|
257 |
+
array(
|
258 |
+
'status' => 'Active',
|
259 |
+
));
|
260 |
+
$firstSubscription = $subscriptions[0];
|
261 |
+
}
|
262 |
+
else {
|
263 |
+
$firstSubscription = $platformHelper->getSubscription($postData['subscription_id']);
|
264 |
+
$subscriptions[] = $firstSubscription;
|
265 |
+
}
|
266 |
+
|
267 |
+
if (!empty($postData['shipping_address_id'])) {
|
268 |
+
// change saved address
|
269 |
+
$addressId = $postData['shipping_address_id'];
|
270 |
+
}
|
271 |
+
else {
|
272 |
+
// add new address
|
273 |
+
$addressId = $this->saveAddress($postData['shipping']);
|
274 |
+
}
|
275 |
+
if (!is_numeric($addressId)) {
|
276 |
+
Mage::throwException('Failed to save address!');
|
277 |
+
}
|
278 |
+
// Set shipping address on subscriptions
|
279 |
+
foreach($subscriptions as $subscription) {
|
280 |
+
$subscription->setShippingAddressId($addressId);
|
281 |
+
}
|
282 |
+
|
283 |
+
// Send changes to platform
|
284 |
+
foreach($subscriptions as $subscription) {
|
285 |
+
$newSubscriptionId = Mage::helper('autoship/platform')->updateSubscription($subscription->getSubscriptionId(), $subscription);
|
286 |
+
}
|
287 |
+
// Return the rendered html for this new subscription state
|
288 |
+
if($nextOrderDateMode != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES) {
|
289 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions')
|
290 |
+
->setTemplate('autoship/mysubscriptions.phtml')
|
291 |
+
->toHtml();
|
292 |
+
}
|
293 |
+
else {
|
294 |
+
// Re-fetch subscription from platform
|
295 |
+
$updatedSubscription = $platformHelper->getSubscription($newSubscriptionId);
|
296 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
297 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
298 |
+
->setSubscription($updatedSubscription)
|
299 |
+
->toHtml();
|
300 |
+
}
|
301 |
+
}
|
302 |
+
catch (Exception $e) {
|
303 |
+
$this->handleAjaxException($e);
|
304 |
+
}
|
305 |
+
}
|
306 |
+
|
307 |
+
/**
|
308 |
+
* Save billing address action
|
309 |
+
*/
|
310 |
+
public function billingsaveAction()
|
311 |
+
{
|
312 |
+
try {
|
313 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
314 |
+
$platformHelper = Mage::helper('autoship/platform');
|
315 |
+
// Get config setting
|
316 |
+
$nextOrderDateMode = Mage::getStoreConfig('autoship_subscription/options/next_order_date_mode');
|
317 |
+
// Get customer
|
318 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
319 |
+
// Get POST data
|
320 |
+
$postData = $this->validateChangePostData();
|
321 |
+
if($nextOrderDateMode != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES) {
|
322 |
+
$subscriptions = $platformHelper->getSubscriptions(
|
323 |
+
$customer,
|
324 |
+
array(
|
325 |
+
'status' => 'Active',
|
326 |
+
));
|
327 |
+
$firstSubscription = $subscriptions[0];
|
328 |
+
}
|
329 |
+
else {
|
330 |
+
$firstSubscription = $platformHelper->getSubscription($postData['subscription_id']);
|
331 |
+
$subscriptions[] = $firstSubscription;
|
332 |
+
}
|
333 |
+
|
334 |
+
if (!empty($postData['billing_address_id'])) {
|
335 |
+
// change saved address
|
336 |
+
$addressId = $postData['billing_address_id'];
|
337 |
+
}
|
338 |
+
else {
|
339 |
+
// add new address
|
340 |
+
$addressId = $this->saveAddress($postData['billing']);
|
341 |
+
}
|
342 |
+
if (!is_numeric($addressId)) {
|
343 |
+
Mage::throwException('Failed to save address!');
|
344 |
+
}
|
345 |
+
// Set billing_address_id address on subscriptions
|
346 |
+
foreach($subscriptions as $subscription) {
|
347 |
+
$subscription->setBillingAddressId($addressId);
|
348 |
+
}
|
349 |
+
|
350 |
+
// Send changes to platform
|
351 |
+
foreach($subscriptions as $subscription) {
|
352 |
+
$newSubscriptionId = $platformHelper->updateSubscription($subscription->getSubscriptionId(), $subscription);
|
353 |
+
}
|
354 |
+
// Return the rendered html for this new subscription state
|
355 |
+
if($nextOrderDateMode != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES) {
|
356 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions')
|
357 |
+
->setTemplate('autoship/mysubscriptions.phtml')
|
358 |
+
->toHtml();
|
359 |
+
}
|
360 |
+
else {
|
361 |
+
// Re-fetch subscription from platform
|
362 |
+
$updatedSubscription = $platformHelper->getSubscription($newSubscriptionId);
|
363 |
+
// Output subscription block for this subscription only
|
364 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
365 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
366 |
+
->setSubscription($updatedSubscription)
|
367 |
+
->toHtml();
|
368 |
+
}
|
369 |
+
|
370 |
+
}
|
371 |
+
catch (Exception $e) {
|
372 |
+
$this->handleAjaxException($e);
|
373 |
+
}
|
374 |
+
}
|
375 |
+
|
376 |
+
/**
|
377 |
+
* Skip the next delivery action
|
378 |
+
*/
|
379 |
+
public function skipAction()
|
380 |
+
{
|
381 |
+
try {
|
382 |
+
// Get subscription id from request
|
383 |
+
$subscriptionId = $this->getRequest()->getParam('id');
|
384 |
+
// Call API to delete subscription
|
385 |
+
Mage::helper('autoship/platform')->skipSubscription($subscriptionId);
|
386 |
+
// Now call platform to get subscription again
|
387 |
+
$subscription = Mage::helper('autoship/platform')->getSubscription($subscriptionId);
|
388 |
+
// Return the rendered html for this new subscription state
|
389 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
390 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
391 |
+
->setSubscription($subscription)
|
392 |
+
->toHtml();
|
393 |
+
}
|
394 |
+
catch (Exception $e) {
|
395 |
+
$this->handleAjaxException($e);
|
396 |
+
}
|
397 |
+
}
|
398 |
+
|
399 |
+
/**
|
400 |
+
* Cancel subscription action
|
401 |
+
*
|
402 |
+
*/
|
403 |
+
public function cancelAction()
|
404 |
+
{
|
405 |
+
try {
|
406 |
+
// Get subscription id from request
|
407 |
+
$subscriptionId = $this->getRequest()->getParam('id');
|
408 |
+
// Call API to delete subscription
|
409 |
+
Mage::helper('autoship/platform')->cancelSubscription($subscriptionId);
|
410 |
+
// Now call platform to get subscription again
|
411 |
+
$subscription = Mage::helper('autoship/platform')->getSubscription($subscriptionId);
|
412 |
+
// Return the rendered html for this new subscription state
|
413 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
414 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
415 |
+
->setSubscription($subscription)
|
416 |
+
->toHtml();
|
417 |
+
}
|
418 |
+
catch (Exception $e) {
|
419 |
+
$this->handleAjaxException($e);
|
420 |
+
}
|
421 |
+
}
|
422 |
+
|
423 |
+
/**
|
424 |
+
* Restart subscription action
|
425 |
+
*
|
426 |
+
*/
|
427 |
+
public function restartAction()
|
428 |
+
{
|
429 |
+
try {
|
430 |
+
// Get subscription id from request
|
431 |
+
$subscriptionId = $this->getRequest()->getParam('id');
|
432 |
+
// Call API to delete subscription
|
433 |
+
Mage::helper('autoship/platform')->restartSubscription($subscriptionId);
|
434 |
+
// Now call platform to get subscription again
|
435 |
+
$subscription = Mage::helper('autoship/platform')->getSubscription($subscriptionId);
|
436 |
+
// Return the rendered html for this new subscription state
|
437 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
438 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
439 |
+
->setSubscription($subscription)
|
440 |
+
->toHtml();
|
441 |
+
}
|
442 |
+
catch (Exception $e) {
|
443 |
+
$this->handleAjaxException($e);
|
444 |
+
}
|
445 |
+
}
|
446 |
+
|
447 |
+
/**
|
448 |
+
* Create a new gateway payment profile in Magento DB and on gateway
|
449 |
+
*
|
450 |
+
* @param SFC_Autoship_Model_Subscription $subscription Subscription for which to create payment profile
|
451 |
+
* @param array $data Array of profile details from POST
|
452 |
+
* @return SFC_AuthnetToken_Model_Cim_Payment_Profile Newly created payment profile
|
453 |
+
*/
|
454 |
+
protected function createNewPaymentProfile(SFC_Autoship_Model_Subscription $subscription, array $data)
|
455 |
+
{
|
456 |
+
// Get helpers
|
457 |
+
/** @var SFC_Autoship_Helper_Platform $helperPlatform */
|
458 |
+
$helperPlatform = Mage::helper('autoship/platform');
|
459 |
+
|
460 |
+
// Get customer
|
461 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
462 |
+
// Check the pay method
|
463 |
+
switch($helperPlatform->getConfiguredPaymentMethodCode())
|
464 |
+
{
|
465 |
+
default:
|
466 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_BRAINTREE:
|
467 |
+
return array(
|
468 |
+
'payment_token' => null,
|
469 |
+
'creditcard_last_digits' => null,
|
470 |
+
);
|
471 |
+
|
472 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM:
|
473 |
+
// Create new payment profile model
|
474 |
+
$model = Mage::getModel('sfc_cim_core/cim_payment_profile');
|
475 |
+
// Init profile with customer defaults
|
476 |
+
$model->initCimProfileWithCustomerDefault($customer->getId());
|
477 |
+
// Adjust the exp fields to the proper format
|
478 |
+
$data['exp_date'] = $data['cc_exp_year'] . '-' . sprintf('%02d', $data['cc_exp_month']);
|
479 |
+
// Put other fields into proper field names for savCimProfileData method
|
480 |
+
$data['customer_cardnumber'] = $data['cc_number'];
|
481 |
+
// If customer has selected billing address, add billing address data to new CIM profile
|
482 |
+
if (strlen($subscription->getBillingAddressId())) {
|
483 |
+
$billingAddress = Mage::getModel('customer/address')->load($subscription->getBillingAddressId());
|
484 |
+
$model->setBillingAddressFields($billingAddress);
|
485 |
+
}
|
486 |
+
// Set attributes that can be saved in our DB & Authorize.Net CIM
|
487 |
+
$model->addData($data);
|
488 |
+
try {
|
489 |
+
// Now try to save payment profile to Auth.net CIM
|
490 |
+
$model->saveCimProfileData(true);
|
491 |
+
// Save our profile model to DB
|
492 |
+
$model->save();
|
493 |
+
}
|
494 |
+
catch (Exception $e) {
|
495 |
+
Mage::throwException('Failed to save credit card!');
|
496 |
+
}
|
497 |
+
|
498 |
+
// Return new model
|
499 |
+
return array(
|
500 |
+
'payment_token' => $model->getData('cim_payment_profile_id'),
|
501 |
+
'creditcard_last_digits' => $model->getData('customer_cardnumber'),
|
502 |
+
);
|
503 |
+
|
504 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CIM_10XX:
|
505 |
+
// Create new payment profile model
|
506 |
+
$model = Mage::getModel('authnettoken/cim_payment_profile');
|
507 |
+
// Init profile with customer defaults
|
508 |
+
$model->initCimProfileWithCustomerDefault($customer->getId());
|
509 |
+
// Adjust the exp fields to the proper format
|
510 |
+
$data['exp_date'] = $data['cc_exp_year'] . '-' . sprintf('%02d', $data['cc_exp_month']);
|
511 |
+
// Put other fields into proper field names for savCimProfileData method
|
512 |
+
$data['customer_cardnumber'] = $data['cc_number'];
|
513 |
+
// If customer has selected billing address, add billing address data to new CIM profile
|
514 |
+
if (strlen($subscription->getBillingAddressId())) {
|
515 |
+
$billingAddress = Mage::getModel('customer/address')->load($subscription->getBillingAddressId());
|
516 |
+
$model->setBillingAddressFields($billingAddress);
|
517 |
+
}
|
518 |
+
// Set attributes that can be saved in our DB & Authorize.Net CIM
|
519 |
+
$model->addData($data);
|
520 |
+
try {
|
521 |
+
// Now try to save payment profile to Auth.net CIM
|
522 |
+
$model->saveCimProfileData(true);
|
523 |
+
// Save our profile model to DB
|
524 |
+
$model->save();
|
525 |
+
}
|
526 |
+
catch (Exception $e) {
|
527 |
+
Mage::throwException('Failed to save credit card!');
|
528 |
+
}
|
529 |
+
|
530 |
+
// Return new model
|
531 |
+
return array(
|
532 |
+
'payment_token' => $model->getData('cim_payment_profile_id'),
|
533 |
+
'creditcard_last_digits' => $model->getData('customer_cardnumber'),
|
534 |
+
);
|
535 |
+
|
536 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SUBSCRIBE_PRO_VAULT:
|
537 |
+
// TO DO: Implement this
|
538 |
+
// Return new details
|
539 |
+
return array(
|
540 |
+
'payment_token' => 'XXXXXX',
|
541 |
+
'creditcard_last_digits' => 'XXXX',
|
542 |
+
);
|
543 |
+
|
544 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_SFC_CYBERSOURCE:
|
545 |
+
// Create new payment profile model
|
546 |
+
$model = Mage::getModel('sfc_cybersource/payment_profile');
|
547 |
+
// Init profile with customer defaults
|
548 |
+
$model->initProfileWithCustomerDefault($customer->getId());
|
549 |
+
// Put fields into proper field names for save method
|
550 |
+
$data['customer_cardnumber'] = $data['cc_number'];
|
551 |
+
// If customer has selected billing address, add billing address data to new profile
|
552 |
+
if (strlen($subscription->getBillingAddressId())) {
|
553 |
+
$billingAddress = Mage::getModel('customer/address')->load($subscription->getBillingAddressId());
|
554 |
+
$model->setBillingAddressFields($billingAddress);
|
555 |
+
}
|
556 |
+
// Set attributes that can be saved in our DB & Gateway
|
557 |
+
$model->addData($data);
|
558 |
+
try {
|
559 |
+
// Now try to save payment profile to Gateway
|
560 |
+
$model->saveProfileData();
|
561 |
+
// Save our profile model to DB
|
562 |
+
$model->save();
|
563 |
+
}
|
564 |
+
catch (Exception $e) {
|
565 |
+
Mage::throwException('Failed to save credit card!');
|
566 |
+
}
|
567 |
+
|
568 |
+
// Return new model
|
569 |
+
return array(
|
570 |
+
'payment_token' => $model->getData('payment_token'),
|
571 |
+
'creditcard_last_digits' => $model->getData('customer_cardnumber'),
|
572 |
+
);
|
573 |
+
|
574 |
+
case SFC_Autoship_Helper_Platform::PAY_METHOD_CODE_PARADOX_TRANSARMOR:
|
575 |
+
// Create payment using paradox ext
|
576 |
+
$payment = array(
|
577 |
+
'firstname' => $customer->getData('firstname'),
|
578 |
+
'lastname' => $customer->getData('lastname'),
|
579 |
+
'cc_type' => $data['cc_type'],
|
580 |
+
'cc_type' => $data['cc_type'],
|
581 |
+
'cc_number' => $data['cc_number'],
|
582 |
+
'cc_exp_month' => $data['cc_exp_month'],
|
583 |
+
'cc_exp_year' => $data['cc_exp_year'],
|
584 |
+
);
|
585 |
+
// If customer has selected billing address, add billing address data to new CIM profile
|
586 |
+
if (strlen($subscription->getBillingAddressId())) {
|
587 |
+
$billingAddress = Mage::getModel('customer/address')->load($subscription->getBillingAddressId());
|
588 |
+
$payment['address1'] = $billingAddress->getStreet(1);
|
589 |
+
$payment['city'] = $billingAddress->getData('city');
|
590 |
+
$payment['state'] = $billingAddress->getData('region');
|
591 |
+
$payment['zip'] = $billingAddress->getData('postcode');
|
592 |
+
$payment['country'] = $billingAddress->getData('country_id');
|
593 |
+
}
|
594 |
+
$paymentId = Mage::getModel('transarmor/payment')->createCustomerPaymentProfile( $payment, $customer );
|
595 |
+
$paymentProfile = Mage::getModel('transarmor/payment')->getPaymentInfoById($paymentId);
|
596 |
+
|
597 |
+
// Return new model
|
598 |
+
return array(
|
599 |
+
'payment_token' => $paymentProfile->getData('trans_id'),
|
600 |
+
'creditcard_last_digits' => $paymentProfile->getData('last4'),
|
601 |
+
);
|
602 |
+
|
603 |
+
}
|
604 |
+
}
|
605 |
+
|
606 |
+
/**
|
607 |
+
* Save a customer address to customer address book in Magento DB
|
608 |
+
* @param array $addressData
|
609 |
+
* @return mixed|string
|
610 |
+
*/
|
611 |
+
protected function saveAddress(array $addressData)
|
612 |
+
{
|
613 |
+
// Array to hold errors
|
614 |
+
$errors = array();
|
615 |
+
// Get customer from session
|
616 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
617 |
+
/* @var $address Mage_Customer_Model_Address */
|
618 |
+
$address = Mage::getModel('customer/address');
|
619 |
+
/* @var $addressForm Mage_Customer_Model_Form */
|
620 |
+
$addressForm = Mage::getModel('customer/form');
|
621 |
+
$addressForm->setFormCode('customer_address_edit')
|
622 |
+
->setEntity($address);
|
623 |
+
$addressErrors = $addressForm->validateData($addressData);
|
624 |
+
if ($addressErrors !== true) {
|
625 |
+
$errors = $addressErrors;
|
626 |
+
}
|
627 |
+
// Compact address data and set customer id
|
628 |
+
$addressForm->compactData($addressData);
|
629 |
+
$address->setCustomerId($customer->getId());
|
630 |
+
// Validate address and collect errors
|
631 |
+
$addressErrors = $address->validate();
|
632 |
+
if ($addressErrors !== true && is_array($addressErrors)) {
|
633 |
+
$errors = array_merge($errors, $addressErrors);
|
634 |
+
}
|
635 |
+
// Check error count
|
636 |
+
// If no errors, save address, otherwise return errors
|
637 |
+
if (count($errors) === 0) {
|
638 |
+
// Save address
|
639 |
+
$address->save();
|
640 |
+
$addressId = $address->getId();
|
641 |
+
|
642 |
+
// Now return the id of created address
|
643 |
+
return $addressId;
|
644 |
+
}
|
645 |
+
else {
|
646 |
+
$html = '';
|
647 |
+
foreach ($errors as $error) {
|
648 |
+
$html .= '<li class="error">' . $error . '</li>';
|
649 |
+
}
|
650 |
+
|
651 |
+
return $html;
|
652 |
+
}
|
653 |
+
|
654 |
+
}
|
655 |
+
|
656 |
+
/**
|
657 |
+
* Method logs exception and outputs message for display to customer
|
658 |
+
*
|
659 |
+
*/
|
660 |
+
protected function handleAjaxException(Exception $e)
|
661 |
+
{
|
662 |
+
// Log exception
|
663 |
+
Mage::log($e->getMessage() . "\n" . $e->getTraceAsString());
|
664 |
+
Mage::logException($e);
|
665 |
+
// Output error message formatted for display
|
666 |
+
echo '<li class="error">' . $e->getMessage() . '</li>';
|
667 |
+
}
|
668 |
+
|
669 |
+
/**
|
670 |
+
* Get customer facing error message text based on error code in Authorize.Net CIM exception
|
671 |
+
*/
|
672 |
+
protected function addErrorFromCimException(SFC_AuthnetToken_Helper_Cim_Exception $eCim)
|
673 |
+
{
|
674 |
+
switch ($eCim->getResponse()->getMessageCode()) {
|
675 |
+
case 'E00014':
|
676 |
+
return ('A required field was not entered for credit card!');
|
677 |
+
break;
|
678 |
+
case 'E00039':
|
679 |
+
return ('Credit card number is already saved in your account!');
|
680 |
+
break;
|
681 |
+
case 'E00042':
|
682 |
+
return ('You have already saved the maximum number of credit cards!');
|
683 |
+
break;
|
684 |
+
default:
|
685 |
+
return ('Failed to save credit card with gateway!');
|
686 |
+
break;
|
687 |
+
}
|
688 |
+
}
|
689 |
+
|
690 |
+
}
|
app/code/local/SFC/Autoship/controllers/NewsubscriptionController.php
ADDED
@@ -0,0 +1,558 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Controller to handle the New Subscription page and subscription creation
|
21 |
+
*
|
22 |
+
* Save the subscription object which is being built in customer session with code like this:
|
23 |
+
* <code>Mage::getSingleton('customer/session')->setNewSubscription($subscription);</code>
|
24 |
+
*
|
25 |
+
*/
|
26 |
+
class SFC_Autoship_NewsubscriptionController extends Mage_Core_Controller_Front_Action
|
27 |
+
{
|
28 |
+
/**
|
29 |
+
* Authenticate customer for all pages and ajax routes supported by this controller
|
30 |
+
*/
|
31 |
+
public function preDispatch()
|
32 |
+
{
|
33 |
+
parent::preDispatch();
|
34 |
+
// Require logged in customer
|
35 |
+
if (!Mage::getSingleton('customer/session')->authenticate($this)) {
|
36 |
+
$this->setFlag('', 'no-dispatch', true);
|
37 |
+
}
|
38 |
+
// Check if extension enabled
|
39 |
+
if (Mage::getStoreConfig('autoship_general/general/enabled') != '1') {
|
40 |
+
// Send customer to 404 page
|
41 |
+
$this->_forward('defaultNoRoute');
|
42 |
+
return;
|
43 |
+
}
|
44 |
+
}
|
45 |
+
|
46 |
+
/**
|
47 |
+
* Render the Create New Subscription page
|
48 |
+
*
|
49 |
+
* Accept query parameters for product id / sku, quantity and interval
|
50 |
+
*/
|
51 |
+
public function indexAction()
|
52 |
+
{
|
53 |
+
// Check if extension enabled
|
54 |
+
// Check if New Sub page enabled
|
55 |
+
if (Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page') != '1') {
|
56 |
+
// Send customer to 404 page
|
57 |
+
$this->_forward('defaultNoRoute');
|
58 |
+
return;
|
59 |
+
}
|
60 |
+
try {
|
61 |
+
// Get query params
|
62 |
+
$processedParams = $this->processQueryParameters();
|
63 |
+
|
64 |
+
// Create subscription model
|
65 |
+
$subscription = $this->initNewSubscription($processedParams);
|
66 |
+
|
67 |
+
// Save subscription object in session
|
68 |
+
Mage::getSingleton('customer/session')->setNewSubscription($subscription);
|
69 |
+
|
70 |
+
// Load layout from XML
|
71 |
+
$this->loadLayout();
|
72 |
+
|
73 |
+
// Set page title for this page
|
74 |
+
$this->getLayout()->getBlock('head')->setTitle($this->__('Create New Product Subscription'));
|
75 |
+
|
76 |
+
// Render the layout
|
77 |
+
$this->renderLayout();
|
78 |
+
|
79 |
+
}
|
80 |
+
catch (Exception $e) {
|
81 |
+
// Send customer to 404 page
|
82 |
+
$this->_forward('defaultNoRoute');
|
83 |
+
}
|
84 |
+
|
85 |
+
}
|
86 |
+
|
87 |
+
/**
|
88 |
+
* Grab query parameters, escape and validate them
|
89 |
+
*
|
90 |
+
* Parameters Accepted:
|
91 |
+
* ---------------------
|
92 |
+
* product_id - One of product_id or product_sku is required to locate product
|
93 |
+
* product_sku - One of product_id or product_sku is required to locate product
|
94 |
+
* qty - Quantity of product for subscription
|
95 |
+
* interval - Subscription interval
|
96 |
+
* coupon - Coupon code to be applied to subscription
|
97 |
+
*/
|
98 |
+
protected function processQueryParameters()
|
99 |
+
{
|
100 |
+
// Build array to return
|
101 |
+
$processedParameters = array();
|
102 |
+
// Get params from request
|
103 |
+
$params = $this->getRequest()->getParams();
|
104 |
+
|
105 |
+
// Handle product, either by id or sku
|
106 |
+
if (strlen($params['product_id'])) {
|
107 |
+
$product = Mage::getModel('catalog/product')->load($params['product_id']);
|
108 |
+
}
|
109 |
+
else {
|
110 |
+
if (strlen($params['product_sku'])) {
|
111 |
+
$product = Mage::getModel('catalog/product')->load($params['product_sku'], 'sku');
|
112 |
+
}
|
113 |
+
else {
|
114 |
+
// No product identifying parameter passed
|
115 |
+
Mage::throwException('No product_id or product_sku parameter passed!');
|
116 |
+
}
|
117 |
+
}
|
118 |
+
// If there is no valid product, error out
|
119 |
+
if (!strlen($product->getId())) {
|
120 |
+
Mage::throwException('Invalid product requested!');
|
121 |
+
}
|
122 |
+
$processedParameters['product'] = $product;
|
123 |
+
$processedParameters['product_id'] = $product->getId();
|
124 |
+
$processedParameters['product_sku'] = $product->getSku();
|
125 |
+
|
126 |
+
// Handle quantity
|
127 |
+
$qty = $params['qty'];
|
128 |
+
// Handle qty param <= 0
|
129 |
+
// If qty is not supplied or is less than 1, default to 1
|
130 |
+
if ($qty <= 0) {
|
131 |
+
$qty = 1;
|
132 |
+
}
|
133 |
+
$processedParameters['qty'] = $qty;
|
134 |
+
|
135 |
+
// Handle interval
|
136 |
+
$interval = $params['interval'];
|
137 |
+
if (!strlen($interval)) {
|
138 |
+
$interval = '';
|
139 |
+
}
|
140 |
+
$processedParameters['interval'] = $interval;
|
141 |
+
|
142 |
+
// Coupon code
|
143 |
+
if(isset($params['coupon_code'])) {
|
144 |
+
$processedParameters['coupon_code'] = $params['coupon_code'];
|
145 |
+
}
|
146 |
+
else {
|
147 |
+
$processedParameters['coupon_code'] = '';
|
148 |
+
}
|
149 |
+
|
150 |
+
return $processedParameters;
|
151 |
+
}
|
152 |
+
|
153 |
+
/**
|
154 |
+
* Build a new subscription model object based on the (already processed) query parameters
|
155 |
+
*
|
156 |
+
* @param array $processedQueryParams Array of already validated and processed query parameters
|
157 |
+
*/
|
158 |
+
protected function initNewSubscription(array $processedQueryParams)
|
159 |
+
{
|
160 |
+
// Get current customer from session
|
161 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
162 |
+
// Lookup saved credit cards for customer
|
163 |
+
$paymentProfile = Mage::getModel('authnettoken/cim_payment_profile')->getCollection()
|
164 |
+
->addFieldToFilter('customer_id', $customer->getId())
|
165 |
+
->getFirstItem();
|
166 |
+
// Create default subscription
|
167 |
+
$subscription = Mage::getModel('autoship/subscription');
|
168 |
+
$subscription->setNextOrderDate(date('Y-m-d', strtotime('+2 days')));
|
169 |
+
$subscription->setProductId($processedQueryParams['product_id']);
|
170 |
+
// $subscription->setProduct($processedQueryParams['product']);
|
171 |
+
$subscription->setCustomerId($customer->getId());
|
172 |
+
$subscription->setBillingAddressId($customer->getDefaultBilling());
|
173 |
+
$subscription->setShippingAddressId($customer->getDefaultShipping());
|
174 |
+
$subscription->setShippingMethod(Mage::getStoreConfig('autoship_subscription/subscription/shipping_method'));
|
175 |
+
$subscription->setQty($processedQueryParams['qty']);
|
176 |
+
$subscription->setCimPaymentProfileId($paymentProfile->getData('cim_payment_profile_id'));
|
177 |
+
$subscription->setInterval($processedQueryParams['interval']);
|
178 |
+
|
179 |
+
// Check min / max qty
|
180 |
+
$product = Mage::getModel('catalog/product')->load($subscription->getData('product_id'));
|
181 |
+
$platformProduct = Mage::helper('autoship/platform')->getPlatformProduct($product);
|
182 |
+
if($subscription->getData('qty') < $platformProduct->getData('min_qty')) {
|
183 |
+
$subscription->setData('qty', $platformProduct->getData('min_qty'));
|
184 |
+
Mage::getSingleton('customer/session')->addError('Minimum quantity for subscription is ' . $platformProduct->getData('min_qty'));
|
185 |
+
}
|
186 |
+
if($subscription->getData('qty') > $platformProduct->getData('max_qty')) {
|
187 |
+
$subscription->setData('qty', $platformProduct->getData('max_qty'));
|
188 |
+
Mage::getSingleton('customer/session')->addError('Maximum quantity for subscription is ' . $platformProduct->getData('max_qty'));
|
189 |
+
}
|
190 |
+
|
191 |
+
// Return the new subscription model
|
192 |
+
return $subscription;
|
193 |
+
}
|
194 |
+
|
195 |
+
/**
|
196 |
+
* Save payment method action
|
197 |
+
*/
|
198 |
+
public function paymentsaveAction()
|
199 |
+
{
|
200 |
+
try {
|
201 |
+
// Get POST data
|
202 |
+
$data = $this->getRequest()->getParam('payment');
|
203 |
+
// Get cur customer and subscription models from session
|
204 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
205 |
+
$subscription = Mage::getSingleton('customer/session')->getNewSubscription();
|
206 |
+
// switched saved card
|
207 |
+
if (strpos($data['method'], '_cc4_') !== false) {
|
208 |
+
// Update selection of payment profile
|
209 |
+
$paymentProfile = Mage::getModel('authnettoken/cim_payment_profile')->load($data['payment_profile_id'][$data['method']]);
|
210 |
+
$subscription->setCimPaymentProfileId($paymentProfile->getData('cim_payment_profile_id'));
|
211 |
+
}
|
212 |
+
else {
|
213 |
+
// Create and save new profile to CIM and DB
|
214 |
+
$paymentProfile = $this->createNewPaymentProfile($subscription, $data);
|
215 |
+
// Now set profile id on subscription
|
216 |
+
$subscription->setCimPaymentProfileId($paymentProfile->getData('cim_payment_profile_id'));
|
217 |
+
}
|
218 |
+
// Save updated subscription model in customer session
|
219 |
+
Mage::getSingleton('customer/session')->setNewSubscription($subscription);
|
220 |
+
|
221 |
+
// Load and render layout to output updated summary block
|
222 |
+
$this->loadLayout(false);
|
223 |
+
$this->renderLayout();
|
224 |
+
}
|
225 |
+
catch (Exception $e) {
|
226 |
+
Mage::log($e->getMessage());
|
227 |
+
Mage::logException($e);
|
228 |
+
echo '<li class="error">' . $e->getMessage() . '</li>';
|
229 |
+
|
230 |
+
return;
|
231 |
+
}
|
232 |
+
}
|
233 |
+
|
234 |
+
/**
|
235 |
+
* Create a new Auth.Net CIM payment profile in Magento DB and on Auth.net CIM
|
236 |
+
*
|
237 |
+
* @param SFC_Autoship_Model_Subscription $subscription Subscription for which to create payment profile
|
238 |
+
* @param array $data Array of profile details from POST
|
239 |
+
* @return SFC_AuthnetToken_Model_Cim_Payment_Profile Newly created payment profile
|
240 |
+
*/
|
241 |
+
protected function createNewPaymentProfile(SFC_Autoship_Model_Subscription $subscription, array $data)
|
242 |
+
{
|
243 |
+
// Get customer
|
244 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
245 |
+
// Create new payment profile model
|
246 |
+
$model = Mage::getModel('authnettoken/cim_payment_profile');
|
247 |
+
// Init profile with customer defaults
|
248 |
+
$model->initCimProfileWithCustomerDefault($customer->getId());
|
249 |
+
// Adjust the exp fields to the proper format
|
250 |
+
$data['exp_date'] = $data['cc_exp_year'] . '-' . sprintf('%02d', $data['cc_exp_month']);
|
251 |
+
// Put other fields into proper field names for savCimProfileData method
|
252 |
+
$data['customer_cardnumber'] = $data['cc_number'];
|
253 |
+
// If customer has selected billing address, add billing address data to new CIM profile
|
254 |
+
if (strlen($subscription->getBillingAddressId())) {
|
255 |
+
$billingAddress = Mage::getModel('customer/address')->load($subscription->getBillingAddressId());
|
256 |
+
$model->setBillingAddressFields($billingAddress);
|
257 |
+
}
|
258 |
+
// Set attributes that can be saved in our DB & Authorize.Net CIM
|
259 |
+
$model->addData($data);
|
260 |
+
try {
|
261 |
+
// Now try to save payment profile to Auth.net CIM
|
262 |
+
$model->saveCimProfileData(true);
|
263 |
+
// Save our profile model to DB
|
264 |
+
$model->save();
|
265 |
+
}
|
266 |
+
catch (SFC_AuthnetToken_Helper_Cim_Exception $eCim) {
|
267 |
+
Mage::throwException($this->addErrorFromCimException($eCim));
|
268 |
+
}
|
269 |
+
catch (Exception $e) {
|
270 |
+
Mage::throwException('Failed to save credit card!');
|
271 |
+
}
|
272 |
+
|
273 |
+
// Return new model
|
274 |
+
return $model;
|
275 |
+
}
|
276 |
+
|
277 |
+
/**
|
278 |
+
* Update CIM payment profile with billing address
|
279 |
+
*
|
280 |
+
* @param SFC_Autoship_Model_Subscription $subscription Subscription for which to update payment profile
|
281 |
+
* @return SFC_AuthnetToken_Model_Cim_Payment_Profile Updated payment profile
|
282 |
+
*/
|
283 |
+
protected function updateCimPaymentProfileBillingAddress(SFC_Autoship_Model_Subscription $subscription)
|
284 |
+
{
|
285 |
+
// Check that we have a payment profile and billing address selected
|
286 |
+
if (!strlen($subscription->getCimPaymentProfileId()) || !strlen($subscription->getBillingAddressId())) {
|
287 |
+
return;
|
288 |
+
}
|
289 |
+
$paymentProfile = $subscription->getPaymentProfile();
|
290 |
+
$paymentProfile->retrieveCimProfileData();
|
291 |
+
$billingAddress = $subscription->getBillingAddress();
|
292 |
+
$paymentProfile->setBillingAddressFields($billingAddress);
|
293 |
+
$paymentProfile->save();
|
294 |
+
$paymentProfile->saveCimProfileData();
|
295 |
+
|
296 |
+
// Return new profile
|
297 |
+
return $paymentProfile;
|
298 |
+
}
|
299 |
+
|
300 |
+
/**
|
301 |
+
* Save billing address action
|
302 |
+
*/
|
303 |
+
public function billingsaveAction()
|
304 |
+
{
|
305 |
+
try {
|
306 |
+
// Get POST data
|
307 |
+
$data = $this->getRequest()->getParams();
|
308 |
+
// Get current subscription
|
309 |
+
$subscription = Mage::getSingleton('customer/session')->getNewSubscription();
|
310 |
+
if (!empty($data['billing_address_id'])) {
|
311 |
+
// change saved address
|
312 |
+
$addressId = $data['billing_address_id'];
|
313 |
+
}
|
314 |
+
else {
|
315 |
+
// add new address
|
316 |
+
$addressId = $this->saveAddress($data['billing']);
|
317 |
+
}
|
318 |
+
if (!is_numeric($addressId)) {
|
319 |
+
Mage::throwException('Failed to save address!');
|
320 |
+
}
|
321 |
+
// Set billing address on subscription
|
322 |
+
$subscription->setBillingAddressId($addressId);
|
323 |
+
Mage::getSingleton('customer/session')->setNewSubscription($subscription);
|
324 |
+
// Check if customer already has default address
|
325 |
+
// If not, set this as default
|
326 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
327 |
+
if (strlen($customer->getDefaultBilling()) == 0) {
|
328 |
+
$customer->setDefaultBilling($addressId);
|
329 |
+
$customer->save();
|
330 |
+
}
|
331 |
+
// Check if there is no shipping address set
|
332 |
+
if (!strlen($subscription->getShippingAddressId())) {
|
333 |
+
// Set shipping to same address as billing
|
334 |
+
$subscription->setShippingAddressId($addressId);
|
335 |
+
// Check if there was no default shipping address set on customer
|
336 |
+
// If not, set this as default
|
337 |
+
if (strlen($customer->getDefaultShipping()) == 0) {
|
338 |
+
$customer->setDefaultShipping($addressId);
|
339 |
+
$customer->save();
|
340 |
+
}
|
341 |
+
}
|
342 |
+
}
|
343 |
+
catch (Exception $e) {
|
344 |
+
Mage::log($e->getMessage());
|
345 |
+
Mage::logException($e);
|
346 |
+
echo '<li class="error">' . $e->getMessage() . '</li>';
|
347 |
+
|
348 |
+
return;
|
349 |
+
}
|
350 |
+
|
351 |
+
// Load and render layout
|
352 |
+
$this->loadLayout(false);
|
353 |
+
$this->renderLayout();
|
354 |
+
}
|
355 |
+
|
356 |
+
/**
|
357 |
+
* Save shipping address action
|
358 |
+
*/
|
359 |
+
public function shippingsaveAction()
|
360 |
+
{
|
361 |
+
try {
|
362 |
+
// Get POST data
|
363 |
+
$data = $this->getRequest()->getParams();
|
364 |
+
// Get current subscription
|
365 |
+
$subscription = Mage::getSingleton('customer/session')->getNewSubscription();
|
366 |
+
if (!empty($data['shipping_address_id'])) {
|
367 |
+
// change saved address
|
368 |
+
$addressId = $data['shipping_address_id'];
|
369 |
+
}
|
370 |
+
else {
|
371 |
+
// add new address
|
372 |
+
$addressId = $this->saveAddress($data['shipping']);
|
373 |
+
}
|
374 |
+
if (!is_numeric($addressId)) {
|
375 |
+
Mage::throwException('Failed to save address!');
|
376 |
+
}
|
377 |
+
// Set shipping address on subscription
|
378 |
+
$subscription->setShippingAddressId($addressId);
|
379 |
+
Mage::getSingleton('customer/session')->setNewSubscription($subscription);
|
380 |
+
// Check if customer already has default address
|
381 |
+
// If not, set this as default
|
382 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
383 |
+
if (strlen($customer->getDefaultShipping()) == 0) {
|
384 |
+
$customer->setDefaultShipping($addressId);
|
385 |
+
$customer->save();
|
386 |
+
}
|
387 |
+
// Check if there is no billing address set
|
388 |
+
if (!strlen($subscription->getBillingAddressId())) {
|
389 |
+
// Set billing to same address as shipping
|
390 |
+
$subscription->setBillingAddressId($addressId);
|
391 |
+
// Check if there was no default billing address set on customer
|
392 |
+
// If not, set this as default
|
393 |
+
if (strlen($customer->getDefaultBilling()) == 0) {
|
394 |
+
$customer->setDefaultBilling($addressId);
|
395 |
+
$customer->save();
|
396 |
+
}
|
397 |
+
}
|
398 |
+
}
|
399 |
+
catch (Exception $e) {
|
400 |
+
Mage::log($e->getMessage());
|
401 |
+
Mage::logException($e);
|
402 |
+
echo '<li class="error">' . $e->getMessage() . '</li>';
|
403 |
+
|
404 |
+
return;
|
405 |
+
}
|
406 |
+
|
407 |
+
// Load and render layout
|
408 |
+
$this->loadLayout(false);
|
409 |
+
$this->renderLayout();
|
410 |
+
}
|
411 |
+
|
412 |
+
/**
|
413 |
+
* Update subscription params action
|
414 |
+
*/
|
415 |
+
public function updateAction()
|
416 |
+
{
|
417 |
+
$data = $this->getRequest()->getPost();
|
418 |
+
try {
|
419 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
420 |
+
$subscription = Mage::getSingleton('customer/session')->getNewSubscription();
|
421 |
+
$subscription
|
422 |
+
->setQty($data['qty'])
|
423 |
+
->setInterval($data['interval']);
|
424 |
+
Mage::getSingleton('customer/session')->setNewSubscription($subscription);
|
425 |
+
}
|
426 |
+
catch (Exception $e) {
|
427 |
+
Mage::log($e->getMessage() . '\n' . $e->getTraceAsString());
|
428 |
+
echo '<li class="error">' . $e->getMessage() . '</li>';
|
429 |
+
}
|
430 |
+
// Load and render layout
|
431 |
+
$this->loadLayout(false);
|
432 |
+
$this->renderLayout();
|
433 |
+
}
|
434 |
+
|
435 |
+
/**
|
436 |
+
* Create subscription action
|
437 |
+
*/
|
438 |
+
public function createPostAction()
|
439 |
+
{
|
440 |
+
if (!$this->getRequest()->isPost()) {
|
441 |
+
return;
|
442 |
+
}
|
443 |
+
|
444 |
+
try {
|
445 |
+
// Get post data
|
446 |
+
$postData = $this->getRequest()->getPost();
|
447 |
+
|
448 |
+
// Update subscription from post data
|
449 |
+
$subscription = Mage::getSingleton('customer/session')->getNewSubscription();
|
450 |
+
/*
|
451 |
+
* TODO: add ajax action to set next order date on subscription object in customer session when it is changed,
|
452 |
+
* so we don't have to stuff it in the create POST
|
453 |
+
*/
|
454 |
+
$subscription->setNextOrderDate(date_format(date_create_from_format('m/d/y', $postData['delivery_date']),
|
455 |
+
'Y-m-d 00:00:00'));
|
456 |
+
// TODO: Use ajax to update and save coupon code as / when it is entered so we don't have to stuff it in postData
|
457 |
+
if(isset($postData['coupon_code'])) {
|
458 |
+
$subscription->setCouponCode($postData['coupon_code']);
|
459 |
+
}
|
460 |
+
|
461 |
+
// Update billing address on payment profile, if one exists already
|
462 |
+
$this->updateCimPaymentProfileBillingAddress($subscription);
|
463 |
+
// Set last 4 digits of cc number on subscription
|
464 |
+
$subscription->setData('customer_cardnumber', $subscription->getPaymentProfile()->getData('customer_cardnumber'));
|
465 |
+
// Create subscription via API
|
466 |
+
Mage::helper('autoship/platform')->createSubscription($subscription);
|
467 |
+
// Clear subscription in session
|
468 |
+
Mage::getSingleton('customer/session')->setNewSubscription(null);
|
469 |
+
|
470 |
+
// Return URL to redirect customer on successful sub creation
|
471 |
+
$successUrl = Mage::getUrl('*/mysubscriptions/index', array('_secure' => true));
|
472 |
+
echo $successUrl;
|
473 |
+
}
|
474 |
+
catch (Exception $e) {
|
475 |
+
Mage::log($e->getMessage());
|
476 |
+
Mage::logException($e);
|
477 |
+
if (strpos($e->getMessage(), '1062 Duplicate entry')) {
|
478 |
+
echo '<li class="error">You already have a subscription to this product.</li>';
|
479 |
+
}
|
480 |
+
else {
|
481 |
+
echo '<li class="error">' . $e->getMessage() . '</li>';
|
482 |
+
}
|
483 |
+
}
|
484 |
+
|
485 |
+
}
|
486 |
+
|
487 |
+
/**
|
488 |
+
* Save a customer address to customer address book in Magento DB
|
489 |
+
* @param array $addressData
|
490 |
+
* @return mixed|string
|
491 |
+
*/
|
492 |
+
protected function saveAddress(array $addressData)
|
493 |
+
{
|
494 |
+
// Array to hold errors
|
495 |
+
$errors = array();
|
496 |
+
// Get customer from session
|
497 |
+
$customer = Mage::getSingleton('customer/session')->getCustomer();
|
498 |
+
/* @var $address Mage_Customer_Model_Address */
|
499 |
+
$address = Mage::getModel('customer/address');
|
500 |
+
/* @var $addressForm Mage_Customer_Model_Form */
|
501 |
+
$addressForm = Mage::getModel('customer/form');
|
502 |
+
$addressForm->setFormCode('customer_address_edit')
|
503 |
+
->setEntity($address);
|
504 |
+
$addressErrors = $addressForm->validateData($addressData);
|
505 |
+
if ($addressErrors !== true) {
|
506 |
+
$errors = $addressErrors;
|
507 |
+
}
|
508 |
+
// Compact address data and set customer id
|
509 |
+
$addressForm->compactData($addressData);
|
510 |
+
$address->setCustomerId($customer->getId());
|
511 |
+
// Validate address and collect errors
|
512 |
+
$addressErrors = $address->validate();
|
513 |
+
if ($addressErrors !== true && is_array($addressErrors)) {
|
514 |
+
$errors = array_merge($errors, $addressErrors);
|
515 |
+
}
|
516 |
+
// Check error count
|
517 |
+
// If no errors, save address, otherwise return errors
|
518 |
+
if (count($errors) === 0) {
|
519 |
+
// Save address
|
520 |
+
$address->save();
|
521 |
+
$addressId = $address->getId();
|
522 |
+
|
523 |
+
// Now return the id of created address
|
524 |
+
return $addressId;
|
525 |
+
}
|
526 |
+
else {
|
527 |
+
$html = '';
|
528 |
+
foreach ($errors as $error) {
|
529 |
+
$html .= '<li class="error">' . $error . '</li>';
|
530 |
+
}
|
531 |
+
|
532 |
+
return $html;
|
533 |
+
}
|
534 |
+
|
535 |
+
}
|
536 |
+
|
537 |
+
/**
|
538 |
+
* Get customer facing error message text based on error code in Authorize.Net CIM exception
|
539 |
+
*/
|
540 |
+
protected function addErrorFromCimException(SFC_AuthnetToken_Helper_Cim_Exception $eCim)
|
541 |
+
{
|
542 |
+
switch ($eCim->getResponse()->getMessageCode()) {
|
543 |
+
case 'E00014':
|
544 |
+
return ('A required field was not entered for credit card!');
|
545 |
+
break;
|
546 |
+
case 'E00039':
|
547 |
+
return ('Credit card number is already saved in your account!');
|
548 |
+
break;
|
549 |
+
case 'E00042':
|
550 |
+
return ('You have already saved the maximum number of credit cards!');
|
551 |
+
break;
|
552 |
+
default:
|
553 |
+
return ('Failed to save credit card with gateway!');
|
554 |
+
break;
|
555 |
+
}
|
556 |
+
}
|
557 |
+
|
558 |
+
}
|
app/code/local/SFC/Autoship/etc/adminhtml.xml
ADDED
@@ -0,0 +1,44 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
-->
|
19 |
+
<config>
|
20 |
+
<acl>
|
21 |
+
<resources>
|
22 |
+
<admin>
|
23 |
+
<children>
|
24 |
+
<system>
|
25 |
+
<children>
|
26 |
+
<config>
|
27 |
+
<children>
|
28 |
+
<autoship_general translate="title" module="autoship">
|
29 |
+
<title>General Section</title>
|
30 |
+
<sort_order>100</sort_order>
|
31 |
+
</autoship_general>
|
32 |
+
<autoship_subscription translate="title" module="autoship">
|
33 |
+
<title>Subscriptions Section</title>
|
34 |
+
<sort_order>200</sort_order>
|
35 |
+
</autoship_subscription>
|
36 |
+
</children>
|
37 |
+
</config>
|
38 |
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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
-->
|
19 |
+
<config>
|
20 |
+
<modules>
|
21 |
+
<SFC_Autoship>
|
22 |
+
<version>1.3.1.14</version>
|
23 |
+
</SFC_Autoship>
|
24 |
+
</modules>
|
25 |
+
<global>
|
26 |
+
<helpers>
|
27 |
+
<autoship>
|
28 |
+
<class>SFC_Autoship_Helper</class>
|
29 |
+
</autoship>
|
30 |
+
<payment>
|
31 |
+
<rewrite>
|
32 |
+
<data>SFC_Autoship_Helper_Payment</data>
|
33 |
+
</rewrite>
|
34 |
+
</payment>
|
35 |
+
</helpers>
|
36 |
+
<blocks>
|
37 |
+
<autoship>
|
38 |
+
<class>SFC_Autoship_Block</class>
|
39 |
+
</autoship>
|
40 |
+
|
41 |
+
<!-- Block overrides -->
|
42 |
+
<catalog>
|
43 |
+
<rewrite>
|
44 |
+
<product_view>SFC_Autoship_Block_Product_View</product_view>
|
45 |
+
</rewrite>
|
46 |
+
</catalog>
|
47 |
+
<checkout>
|
48 |
+
<rewrite>
|
49 |
+
<onepage_payment_methods>SFC_Autoship_Block_Checkout_Onepage_Payment_Methods</onepage_payment_methods>
|
50 |
+
</rewrite>
|
51 |
+
</checkout>
|
52 |
+
|
53 |
+
|
54 |
+
</blocks>
|
55 |
+
<models>
|
56 |
+
<autoship>
|
57 |
+
<class>SFC_Autoship_Model</class>
|
58 |
+
<resourceModel>autoship_mysql4</resourceModel>
|
59 |
+
</autoship>
|
60 |
+
<autoship_mysql4>
|
61 |
+
<class>SFC_Autoship_Model_Mysql4</class>
|
62 |
+
<entities>
|
63 |
+
<!-- Legacy entities. These aren't used from version 1.3.1.4 forward, but definitions are needed
|
64 |
+
to make older upgrade scripts work. -->
|
65 |
+
<subscription_order>
|
66 |
+
<table>sfc_autoship_subscription_order</table>
|
67 |
+
</subscription_order>
|
68 |
+
<legacy_product_profile>
|
69 |
+
<table>sfc_autoship_product_profile</table>
|
70 |
+
</legacy_product_profile>
|
71 |
+
<migrated_cimProfile>
|
72 |
+
<table>sfc_autoship_migrated_cim_profile</table>
|
73 |
+
</migrated_cimProfile>
|
74 |
+
<migrated_subscription>
|
75 |
+
<table>sfc_autoship_migrated_subscription</table>
|
76 |
+
</migrated_subscription>
|
77 |
+
<migrated_subscription_item>
|
78 |
+
<table>sfc_autoship_migrated_subscription_item</table>
|
79 |
+
</migrated_subscription_item>
|
80 |
+
<adapter_ordergroove_row>
|
81 |
+
<table>sfc_autoship_og_subscription</table>
|
82 |
+
</adapter_ordergroove_row>
|
83 |
+
<!-- End of Legacy entities. -->
|
84 |
+
</entities>
|
85 |
+
</autoship_mysql4>
|
86 |
+
|
87 |
+
<!-- Model rewrites -->
|
88 |
+
<checkout>
|
89 |
+
<rewrite>
|
90 |
+
<cart_product_api>SFC_Autoship_Model_Checkout_Cart_Product_Api</cart_product_api>
|
91 |
+
</rewrite>
|
92 |
+
<rewrite>
|
93 |
+
<cart_payment_api>SFC_Autoship_Model_Checkout_Cart_Payment_Api</cart_payment_api>
|
94 |
+
</rewrite>
|
95 |
+
<rewrite>
|
96 |
+
<cart_api>SFC_Autoship_Model_Checkout_Cart_Api</cart_api>
|
97 |
+
</rewrite>
|
98 |
+
</checkout>
|
99 |
+
<sales>
|
100 |
+
<rewrite>
|
101 |
+
<quote_address>SFC_Autoship_Model_Quote_Address</quote_address>
|
102 |
+
</rewrite>
|
103 |
+
</sales>
|
104 |
+
<salesrule>
|
105 |
+
<rewrite>
|
106 |
+
<validator>SFC_Autoship_Model_SalesRule_Validator</validator>
|
107 |
+
<rule_condition_product>SFC_Autoship_Model_SalesRule_Rule_Condition_Product</rule_condition_product>
|
108 |
+
</rewrite>
|
109 |
+
</salesrule>
|
110 |
+
<paypal>
|
111 |
+
<rewrite>
|
112 |
+
<express>SFC_Autoship_Model_Paypal_Express</express>
|
113 |
+
</rewrite>
|
114 |
+
</paypal>
|
115 |
+
</models>
|
116 |
+
|
117 |
+
<resources>
|
118 |
+
<sfc_autoship_setup>
|
119 |
+
<setup>
|
120 |
+
<module>SFC_Autoship</module>
|
121 |
+
<class>Mage_Sales_Model_Mysql4_Setup</class>
|
122 |
+
<connection>
|
123 |
+
<use>core_setup</use>
|
124 |
+
</connection>
|
125 |
+
</setup>
|
126 |
+
</sfc_autoship_setup>
|
127 |
+
</resources>
|
128 |
+
|
129 |
+
<cache>
|
130 |
+
<types>
|
131 |
+
<subscribe_pro_config>
|
132 |
+
<label>Subscribe Pro Configuration</label>
|
133 |
+
<description>API credentials and configuration settings from the Subscribe Pro platform.</description>
|
134 |
+
<tags>SP_CONFIG</tags>
|
135 |
+
</subscribe_pro_config>
|
136 |
+
<subscribe_pro_products>
|
137 |
+
<label>Subscribe Pro Product Data</label>
|
138 |
+
<description>Product subscription attributes from the Subscribe Pro platform. For example, intervals, subscription discount, etc.</description>
|
139 |
+
<tags>SP_PRODUCTS</tags>
|
140 |
+
</subscribe_pro_products>
|
141 |
+
</types>
|
142 |
+
</cache>
|
143 |
+
|
144 |
+
<events>
|
145 |
+
<catalog_product_save_commit_after>
|
146 |
+
<observers>
|
147 |
+
<subscription_product_save_commit_after>
|
148 |
+
<type>singleton</type>
|
149 |
+
<class>autoship/observer</class>
|
150 |
+
<method>onProductSaveCommitAfter</method>
|
151 |
+
</subscription_product_save_commit_after>
|
152 |
+
</observers>
|
153 |
+
</catalog_product_save_commit_after>
|
154 |
+
|
155 |
+
<checkout_cart_add_product_complete>
|
156 |
+
<observers>
|
157 |
+
<subscription_checkout_cart_add_product_complete>
|
158 |
+
<type>singleton</type>
|
159 |
+
<class>autoship/observer</class>
|
160 |
+
<method>onCheckoutCartAddProductComplete</method>
|
161 |
+
</subscription_checkout_cart_add_product_complete>
|
162 |
+
</observers>
|
163 |
+
</checkout_cart_add_product_complete>
|
164 |
+
<checkout_cart_update_items_after>
|
165 |
+
<observers>
|
166 |
+
<subscription_checkout_cart_update_items_after>
|
167 |
+
<type>singleton</type>
|
168 |
+
<class>autoship/observer</class>
|
169 |
+
<method>onCheckoutCartUpdateItemsAfter</method>
|
170 |
+
</subscription_checkout_cart_update_items_after>
|
171 |
+
</observers>
|
172 |
+
</checkout_cart_update_items_after>
|
173 |
+
<sales_convert_quote_item_to_order_item>
|
174 |
+
<observers>
|
175 |
+
<subscription_sales_convert_quote_item_to_order_item>
|
176 |
+
<type>singleton</type>
|
177 |
+
<class>autoship/observer</class>
|
178 |
+
<method>onSalesConvertQuoteItemToOrderItem</method>
|
179 |
+
</subscription_sales_convert_quote_item_to_order_item>
|
180 |
+
</observers>
|
181 |
+
</sales_convert_quote_item_to_order_item>
|
182 |
+
<sales_convert_order_to_quote>
|
183 |
+
<observers>
|
184 |
+
<subscription_sales_convert_order_to_quote>
|
185 |
+
<type>singleton</type>
|
186 |
+
<class>autoship/observer</class>
|
187 |
+
<method>onSalesConvertOrderToQuote</method>
|
188 |
+
</subscription_sales_convert_order_to_quote>
|
189 |
+
</observers>
|
190 |
+
</sales_convert_order_to_quote>
|
191 |
+
<checkout_submit_all_after>
|
192 |
+
<observers>
|
193 |
+
<subscription_checkout_submit_all_after>
|
194 |
+
<type>singleton</type>
|
195 |
+
<class>autoship/observer</class>
|
196 |
+
<method>onCheckoutSubmitAllAfter</method>
|
197 |
+
</subscription_checkout_submit_all_after>
|
198 |
+
</observers>
|
199 |
+
</checkout_submit_all_after>
|
200 |
+
<checkout_onepage_controller_success_action>
|
201 |
+
<observers>
|
202 |
+
<subscription_checkout_onepage_controller_success_action>
|
203 |
+
<type>singleton</type>
|
204 |
+
<class>autoship/observer</class>
|
205 |
+
<method>onCheckoutOnepageControllerSuccessAction</method>
|
206 |
+
</subscription_checkout_onepage_controller_success_action>
|
207 |
+
</observers>
|
208 |
+
</checkout_onepage_controller_success_action>
|
209 |
+
<checkout_allow_guest>
|
210 |
+
<observers>
|
211 |
+
<checkout_allow_guest>
|
212 |
+
<class>autoship/observer</class>
|
213 |
+
<method>isAllowedGuestCheckout</method>
|
214 |
+
</checkout_allow_guest>
|
215 |
+
</observers>
|
216 |
+
</checkout_allow_guest>
|
217 |
+
</events>
|
218 |
+
|
219 |
+
</global>
|
220 |
+
|
221 |
+
<!-- Frontend layout XML updates and routers -->
|
222 |
+
<frontend>
|
223 |
+
<secure_url>
|
224 |
+
<autoship>/subscriptions</autoship>
|
225 |
+
</secure_url>
|
226 |
+
<routers>
|
227 |
+
<autoship>
|
228 |
+
<use>standard</use>
|
229 |
+
<args>
|
230 |
+
<module>SFC_Autoship</module>
|
231 |
+
<frontName>subscriptions</frontName>
|
232 |
+
</args>
|
233 |
+
</autoship>
|
234 |
+
</routers>
|
235 |
+
<layout>
|
236 |
+
<updates>
|
237 |
+
<autoship module="SFC_Autoship">
|
238 |
+
<file>autoship.xml</file>
|
239 |
+
</autoship>
|
240 |
+
</updates>
|
241 |
+
</layout>
|
242 |
+
</frontend>
|
243 |
+
<!-- Frontend layout XML updates -->
|
244 |
+
|
245 |
+
<!-- Admin panel routers -->
|
246 |
+
<admin>
|
247 |
+
<routers>
|
248 |
+
<autoship_admin>
|
249 |
+
<use>admin</use>
|
250 |
+
<args>
|
251 |
+
<module>SFC_Autoship</module>
|
252 |
+
<frontName>subscriptions_admin</frontName>
|
253 |
+
</args>
|
254 |
+
</autoship_admin>
|
255 |
+
</routers>
|
256 |
+
</admin>
|
257 |
+
<!-- Admin panel html changes -->
|
258 |
+
<adminhtml>
|
259 |
+
<layout>
|
260 |
+
<updates>
|
261 |
+
<autoship>
|
262 |
+
<file>autoship.xml</file>
|
263 |
+
</autoship>
|
264 |
+
</updates>
|
265 |
+
</layout>
|
266 |
+
</adminhtml>
|
267 |
+
|
268 |
+
<!-- Cron job schedules -->
|
269 |
+
<crontab>
|
270 |
+
<jobs>
|
271 |
+
</jobs>
|
272 |
+
</crontab>
|
273 |
+
|
274 |
+
<!-- Default configuration settings -->
|
275 |
+
<default>
|
276 |
+
<autoship_general>
|
277 |
+
<general>
|
278 |
+
<enabled>0</enabled>
|
279 |
+
</general>
|
280 |
+
<platform_api>
|
281 |
+
<platform_host>api.subscribepro.com</platform_host>
|
282 |
+
<log_request>0</log_request>
|
283 |
+
</platform_api>
|
284 |
+
<advanced>
|
285 |
+
<cache_lifetime>300</cache_lifetime>
|
286 |
+
</advanced>
|
287 |
+
<!-- These config settings are intended to be overridden with installation-specific values in
|
288 |
+
app/etc/local.xml file -->
|
289 |
+
<developer>
|
290 |
+
<!-- allow_custom_options - default = 0 = false -->
|
291 |
+
<allow_custom_options>0</allow_custom_options>
|
292 |
+
</developer>
|
293 |
+
</autoship_general>
|
294 |
+
<autoship_subscription>
|
295 |
+
<options>
|
296 |
+
<next_order_date_mode>1</next_order_date_mode>
|
297 |
+
</options>
|
298 |
+
<subscription>
|
299 |
+
<shipping_method>flatrate_flatrate</shipping_method>
|
300 |
+
<shipping_method_onetime_enabled>1</shipping_method_onetime_enabled>
|
301 |
+
</subscription>
|
302 |
+
<discount>
|
303 |
+
<!-- Default to combine subscription discount with other discounts -->
|
304 |
+
<cartrule_combine_type>4</cartrule_combine_type>
|
305 |
+
</discount>
|
306 |
+
</autoship_subscription>
|
307 |
+
<payment>
|
308 |
+
<subscribe_pro>
|
309 |
+
<active>0</active>
|
310 |
+
<active_non_subscription>0</active_non_subscription>
|
311 |
+
<model>autoship/payment_method</model>
|
312 |
+
<title>Subscribe Pro Vault</title>
|
313 |
+
<allowspecific>0</allowspecific>
|
314 |
+
<cctypes>AE,VI,MC,DI</cctypes>
|
315 |
+
<payment_action>authorize_capture</payment_action>
|
316 |
+
<order_status>processing</order_status>
|
317 |
+
<currency>USD</currency>
|
318 |
+
<allow_guest_checkout>1</allow_guest_checkout>
|
319 |
+
<use_transparent_redirect>0</use_transparent_redirect>
|
320 |
+
</subscribe_pro>
|
321 |
+
</payment>
|
322 |
+
</default>
|
323 |
+
|
324 |
+
</config>
|
app/code/local/SFC/Autoship/etc/system.xml
ADDED
@@ -0,0 +1,415 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
-->
|
19 |
+
<config>
|
20 |
+
<tabs>
|
21 |
+
<autoship translate="label" module="autoship">
|
22 |
+
<label>Subscribe Pro</label>
|
23 |
+
<sort_order>200</sort_order>
|
24 |
+
</autoship>
|
25 |
+
</tabs>
|
26 |
+
<sections>
|
27 |
+
<autoship_general translate="label" module="autoship">
|
28 |
+
<label>General</label>
|
29 |
+
<tab>autoship</tab>
|
30 |
+
<frontend_type>text</frontend_type>
|
31 |
+
<sort_order>100</sort_order>
|
32 |
+
<show_in_default>1</show_in_default>
|
33 |
+
<show_in_website>1</show_in_website>
|
34 |
+
<show_in_store>1</show_in_store>
|
35 |
+
<groups>
|
36 |
+
<general translate="label">
|
37 |
+
<label>General</label>
|
38 |
+
<sort_order>100</sort_order>
|
39 |
+
<show_in_default>1</show_in_default>
|
40 |
+
<show_in_website>1</show_in_website>
|
41 |
+
<show_in_store>0</show_in_store>
|
42 |
+
<fields>
|
43 |
+
<enabled translate="label">
|
44 |
+
<label>Subscription Features Enabled</label>
|
45 |
+
<frontend_type>select</frontend_type>
|
46 |
+
<source_model>adminhtml/system_config_source_enabledisable</source_model>
|
47 |
+
<sort_order>100</sort_order>
|
48 |
+
<show_in_default>1</show_in_default>
|
49 |
+
<show_in_website>1</show_in_website>
|
50 |
+
<show_in_store>0</show_in_store>
|
51 |
+
<comment>Enable/Disable Subscriptions features.</comment>
|
52 |
+
</enabled>
|
53 |
+
</fields>
|
54 |
+
</general>
|
55 |
+
<platform_api translate="label">
|
56 |
+
<label>Subscribe Pro Platform API Connection</label>
|
57 |
+
<sort_order>300</sort_order>
|
58 |
+
<show_in_default>1</show_in_default>
|
59 |
+
<show_in_website>1</show_in_website>
|
60 |
+
<show_in_store>0</show_in_store>
|
61 |
+
<fields>
|
62 |
+
<test_connection translate="label">
|
63 |
+
<label>Test Connection</label>
|
64 |
+
<frontend_type>button</frontend_type>
|
65 |
+
<frontend_model>autoship/adminhtml_system_config_form_testConnectionButton</frontend_model>
|
66 |
+
<sort_order>0</sort_order>
|
67 |
+
<show_in_default>1</show_in_default>
|
68 |
+
<show_in_website>1</show_in_website>
|
69 |
+
<show_in_store>0</show_in_store>
|
70 |
+
</test_connection>
|
71 |
+
<platform_host translate="label">
|
72 |
+
<label>Platform Hostname</label>
|
73 |
+
<frontend_type>text</frontend_type>
|
74 |
+
<sort_order>1</sort_order>
|
75 |
+
<show_in_default>1</show_in_default>
|
76 |
+
<show_in_website>1</show_in_website>
|
77 |
+
<show_in_store>0</show_in_store>
|
78 |
+
</platform_host>
|
79 |
+
<client_id translate="label">
|
80 |
+
<label>Client Id</label>
|
81 |
+
<frontend_type>text</frontend_type>
|
82 |
+
<backend_model>adminhtml/system_config_backend_encrypted</backend_model>
|
83 |
+
<sort_order>10</sort_order>
|
84 |
+
<show_in_default>1</show_in_default>
|
85 |
+
<show_in_website>1</show_in_website>
|
86 |
+
<show_in_store>0</show_in_store>
|
87 |
+
</client_id>
|
88 |
+
<client_secret translate="label">
|
89 |
+
<label>Client Secret</label>
|
90 |
+
<frontend_type>obscure</frontend_type>
|
91 |
+
<backend_model>adminhtml/system_config_backend_encrypted</backend_model>
|
92 |
+
<sort_order>20</sort_order>
|
93 |
+
<show_in_default>1</show_in_default>
|
94 |
+
<show_in_website>1</show_in_website>
|
95 |
+
<show_in_store>0</show_in_store>
|
96 |
+
</client_secret>
|
97 |
+
<log_request translate="label">
|
98 |
+
<label>Log Platform API Requests</label>
|
99 |
+
<frontend_type>select</frontend_type>
|
100 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
101 |
+
<sort_order>60</sort_order>
|
102 |
+
<show_in_default>1</show_in_default>
|
103 |
+
<show_in_website>1</show_in_website>
|
104 |
+
<show_in_store>0</show_in_store>
|
105 |
+
<comment>When this settings is enabled, you should also enable Magento's general logging under System > Configuration > Developer > Log Settings. NOTE: This should only be enabled on non-production systems. The request data can include sensitive customer data and your account credentials!</comment>
|
106 |
+
</log_request>
|
107 |
+
</fields>
|
108 |
+
</platform_api>
|
109 |
+
<advanced translate="label">
|
110 |
+
<label>Advanced</label>
|
111 |
+
<sort_order>500</sort_order>
|
112 |
+
<show_in_default>1</show_in_default>
|
113 |
+
<show_in_website>1</show_in_website>
|
114 |
+
<show_in_store>1</show_in_store>
|
115 |
+
<fields>
|
116 |
+
<cache_lifetime translate="label">
|
117 |
+
<label>API Data Cache Lifetime</label>
|
118 |
+
<frontend_type>text</frontend_type>
|
119 |
+
<sort_order>100</sort_order>
|
120 |
+
<show_in_default>1</show_in_default>
|
121 |
+
<show_in_website>1</show_in_website>
|
122 |
+
<show_in_store>0</show_in_store>
|
123 |
+
<comment>Enter cache lifetime value in seconds. DEFAULT: 300 seconds</comment>
|
124 |
+
</cache_lifetime>
|
125 |
+
</fields>
|
126 |
+
</advanced>
|
127 |
+
</groups>
|
128 |
+
</autoship_general>
|
129 |
+
<autoship_subscription translate="label" module="autoship">
|
130 |
+
<label>Subscriptions</label>
|
131 |
+
<tab>autoship</tab>
|
132 |
+
<frontend_type>text</frontend_type>
|
133 |
+
<sort_order>200</sort_order>
|
134 |
+
<show_in_default>1</show_in_default>
|
135 |
+
<show_in_website>1</show_in_website>
|
136 |
+
<show_in_store>1</show_in_store>
|
137 |
+
<groups>
|
138 |
+
<options translate="label">
|
139 |
+
<label>Subscription Mode</label>
|
140 |
+
<frontend_type>text</frontend_type>
|
141 |
+
<sort_order>100</sort_order>
|
142 |
+
<show_in_default>1</show_in_default>
|
143 |
+
<show_in_website>1</show_in_website>
|
144 |
+
<show_in_store>1</show_in_store>
|
145 |
+
<fields>
|
146 |
+
<next_order_date_mode translate="label">
|
147 |
+
<label>Allow Single or Multiple Subscription Order Dates</label>
|
148 |
+
<frontend_type>select</frontend_type>
|
149 |
+
<source_model>autoship/system_config_source_nextorderdatemode</source_model>
|
150 |
+
<sort_order>20</sort_order>
|
151 |
+
<show_in_default>1</show_in_default>
|
152 |
+
<show_in_website>1</show_in_website>
|
153 |
+
<show_in_store>1</show_in_store>
|
154 |
+
<comment>Should customer be allowed to place subscriptions on multiple days or should all subscriptions be
|
155 |
+
combined to a single order date.
|
156 |
+
</comment>
|
157 |
+
</next_order_date_mode>
|
158 |
+
<allow_coupon translate="label">
|
159 |
+
<label>Save Coupons With Subscriptions</label>
|
160 |
+
<frontend_type>select</frontend_type>
|
161 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
162 |
+
<sort_order>40</sort_order>
|
163 |
+
<show_in_default>1</show_in_default>
|
164 |
+
<show_in_website>1</show_in_website>
|
165 |
+
<show_in_store>1</show_in_store>
|
166 |
+
<comment>Allow coupons to be added when a customer creates a new subscription using the New Subscription
|
167 |
+
page and saved with subscriptions created during the checkout process.
|
168 |
+
</comment>
|
169 |
+
</allow_coupon>
|
170 |
+
</fields>
|
171 |
+
</options>
|
172 |
+
<discount translate="label">
|
173 |
+
<label>Subscription Discount</label>
|
174 |
+
<frontend_type>text</frontend_type>
|
175 |
+
<sort_order>110</sort_order>
|
176 |
+
<show_in_default>1</show_in_default>
|
177 |
+
<show_in_website>1</show_in_website>
|
178 |
+
<show_in_store>1</show_in_store>
|
179 |
+
<fields>
|
180 |
+
<apply_discount_to_catalog_price translate="label">
|
181 |
+
<label>Apply Discount To Catalog Price</label>
|
182 |
+
<frontend_type>select</frontend_type>
|
183 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
184 |
+
<sort_order>10</sort_order>
|
185 |
+
<show_in_default>1</show_in_default>
|
186 |
+
<show_in_website>1</show_in_website>
|
187 |
+
<show_in_store>1</show_in_store>
|
188 |
+
<comment>Apply subscription discount when catalog price rule or special price discount is in effect.
|
189 |
+
</comment>
|
190 |
+
</apply_discount_to_catalog_price>
|
191 |
+
<cartrule_combine_type translate="label">
|
192 |
+
<label>Cart Rule Combine Type</label>
|
193 |
+
<frontend_type>select</frontend_type>
|
194 |
+
<source_model>autoship/system_config_source_cartrulediscountcombinetype</source_model>
|
195 |
+
<sort_order>20</sort_order>
|
196 |
+
<show_in_default>1</show_in_default>
|
197 |
+
<show_in_website>1</show_in_website>
|
198 |
+
<show_in_store>1</show_in_store>
|
199 |
+
<comment>Specify how to combine the subscription discount with any shopping cart price rules or coupon code
|
200 |
+
discounts.
|
201 |
+
</comment>
|
202 |
+
</cartrule_combine_type>
|
203 |
+
</fields>
|
204 |
+
</discount>
|
205 |
+
<subscription translate="label">
|
206 |
+
<label>New Subscription Page</label>
|
207 |
+
<frontend_type>text</frontend_type>
|
208 |
+
<sort_order>120</sort_order>
|
209 |
+
<show_in_default>1</show_in_default>
|
210 |
+
<show_in_website>1</show_in_website>
|
211 |
+
<show_in_store>1</show_in_store>
|
212 |
+
<comment>DO NOT USE NEW SUBSCRIPTION PAGE UNLESS INSTRUCTED TO DO SO BY SUBSCRIBE PRO SUPPORT! This is a legacy feature only.</comment>
|
213 |
+
<fields>
|
214 |
+
<use_new_subscription_page translate="label">
|
215 |
+
<label>Use New Subscription Page</label>
|
216 |
+
<frontend_type>select</frontend_type>
|
217 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
218 |
+
<sort_order>0</sort_order>
|
219 |
+
<show_in_default>1</show_in_default>
|
220 |
+
<show_in_website>1</show_in_website>
|
221 |
+
<show_in_store>1</show_in_store>
|
222 |
+
<comment>Use the New Subscription page as the default method for customers to create new subscriptions.
|
223 |
+
"Create Subscription" button will appear on product details page, button will redirect customers to New
|
224 |
+
Subscription page.
|
225 |
+
</comment>
|
226 |
+
</use_new_subscription_page>
|
227 |
+
<shipping_method translate="label">
|
228 |
+
<label>Subscription Shipping Method</label>
|
229 |
+
<frontend_type>select</frontend_type>
|
230 |
+
<source_model>autoship/system_config_source_shippingmethods</source_model>
|
231 |
+
<sort_order>10</sort_order>
|
232 |
+
<show_in_default>1</show_in_default>
|
233 |
+
<show_in_website>1</show_in_website>
|
234 |
+
<show_in_store>1</show_in_store>
|
235 |
+
<comment>Select the single shipping method which shall be used for Subscribe Pro subscription orders placed
|
236 |
+
via the New Subscription page. NOTE: Order placed through cart / checkout ordering process will be
|
237 |
+
eligible for any shipping method available in the Magento checkout process.
|
238 |
+
</comment>
|
239 |
+
</shipping_method>
|
240 |
+
<shipping_method_onetime_enabled translate="label">
|
241 |
+
<label>Allow Method for One-Time Purchases</label>
|
242 |
+
<frontend_type>select</frontend_type>
|
243 |
+
<source_model>adminhtml/system_config_source_enabledisable</source_model>
|
244 |
+
<sort_order>20</sort_order>
|
245 |
+
<show_in_default>1</show_in_default>
|
246 |
+
<show_in_website>1</show_in_website>
|
247 |
+
<show_in_store>1</show_in_store>
|
248 |
+
<comment>Should the shipping method selected above for subscription orders be enabled or disabled for
|
249 |
+
one-time purchase checkouts by customers?
|
250 |
+
</comment>
|
251 |
+
</shipping_method_onetime_enabled>
|
252 |
+
</fields>
|
253 |
+
</subscription>
|
254 |
+
</groups>
|
255 |
+
</autoship_subscription>
|
256 |
+
<payment>
|
257 |
+
<groups>
|
258 |
+
<subscribe_pro translate="label" module="autoship">
|
259 |
+
<label>Subscribe Pro Vault</label>
|
260 |
+
<frontend_type>text</frontend_type>
|
261 |
+
<sort_order>10</sort_order>
|
262 |
+
<show_in_default>1</show_in_default>
|
263 |
+
<show_in_website>1</show_in_website>
|
264 |
+
<show_in_store>1</show_in_store>
|
265 |
+
<comment></comment>
|
266 |
+
<fields>
|
267 |
+
<active translate="label">
|
268 |
+
<label>Enabled</label>
|
269 |
+
<frontend_type>select</frontend_type>
|
270 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
271 |
+
<sort_order>0</sort_order>
|
272 |
+
<show_in_default>1</show_in_default>
|
273 |
+
<show_in_website>1</show_in_website>
|
274 |
+
<show_in_store>0</show_in_store>
|
275 |
+
</active>
|
276 |
+
<active_non_subscription translate="label">
|
277 |
+
<label>Enabled for Non-Subscription Transactions</label>
|
278 |
+
<frontend_type>select</frontend_type>
|
279 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
280 |
+
<sort_order>0</sort_order>
|
281 |
+
<show_in_default>1</show_in_default>
|
282 |
+
<show_in_website>1</show_in_website>
|
283 |
+
<show_in_store>0</show_in_store>
|
284 |
+
</active_non_subscription>
|
285 |
+
<title translate="label">
|
286 |
+
<label>Title</label>
|
287 |
+
<frontend_type>text</frontend_type>
|
288 |
+
<sort_order>2</sort_order>
|
289 |
+
<show_in_default>1</show_in_default>
|
290 |
+
<show_in_website>1</show_in_website>
|
291 |
+
<show_in_store>1</show_in_store>
|
292 |
+
</title>
|
293 |
+
<payment_action translate="label">
|
294 |
+
<label>Payment Action</label>
|
295 |
+
<frontend_type>select</frontend_type>
|
296 |
+
<source_model>paygate/authorizenet_source_paymentAction</source_model>
|
297 |
+
<sort_order>3</sort_order>
|
298 |
+
<show_in_default>1</show_in_default>
|
299 |
+
<show_in_website>1</show_in_website>
|
300 |
+
<show_in_store>0</show_in_store>
|
301 |
+
</payment_action>
|
302 |
+
<order_status translate="label">
|
303 |
+
<label>New Order Status</label>
|
304 |
+
<frontend_type>select</frontend_type>
|
305 |
+
<source_model>adminhtml/system_config_source_order_status_processing</source_model>
|
306 |
+
<sort_order>4</sort_order>
|
307 |
+
<show_in_default>1</show_in_default>
|
308 |
+
<show_in_website>1</show_in_website>
|
309 |
+
<show_in_store>0</show_in_store>
|
310 |
+
</order_status>
|
311 |
+
<cctypes translate="label">
|
312 |
+
<label>Credit Card Types</label>
|
313 |
+
<frontend_type>multiselect</frontend_type>
|
314 |
+
<source_model>paygate/authorizenet_source_cctype</source_model>
|
315 |
+
<sort_order>45</sort_order>
|
316 |
+
<show_in_default>1</show_in_default>
|
317 |
+
<show_in_website>1</show_in_website>
|
318 |
+
<show_in_store>0</show_in_store>
|
319 |
+
</cctypes>
|
320 |
+
<useccv translate="label">
|
321 |
+
<label>Credit Card Verification (CVV) Field Enabled</label>
|
322 |
+
<frontend_type>select</frontend_type>
|
323 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
324 |
+
<sort_order>46</sort_order>
|
325 |
+
<show_in_default>1</show_in_default>
|
326 |
+
<show_in_website>1</show_in_website>
|
327 |
+
<show_in_store>0</show_in_store>
|
328 |
+
<comment>NOTE: CVV field is always shown in Admin panel ordering interface. This configuration setting turns the CVV field on and off for the customer-facing frontend features.</comment>
|
329 |
+
</useccv>
|
330 |
+
<currency translate="label">
|
331 |
+
<label>Accepted Currency</label>
|
332 |
+
<frontend_type>select</frontend_type>
|
333 |
+
<source_model>adminhtml/system_config_source_currency</source_model>
|
334 |
+
<sort_order>49</sort_order>
|
335 |
+
<show_in_default>1</show_in_default>
|
336 |
+
<show_in_website>1</show_in_website>
|
337 |
+
<show_in_store>0</show_in_store>
|
338 |
+
<comment>One currency per Magento website must be selected. NOTE: Magento's currency conversion feature can be used to display values in multiple currencies, but payment transactions and orders will only be placed in the single base currency for the website.</comment>
|
339 |
+
</currency>
|
340 |
+
<allowspecific translate="label">
|
341 |
+
<label>Payment from Applicable Countries</label>
|
342 |
+
<frontend_type>allowspecific</frontend_type>
|
343 |
+
<sort_order>50</sort_order>
|
344 |
+
<source_model>adminhtml/system_config_source_payment_allspecificcountries</source_model>
|
345 |
+
<show_in_default>1</show_in_default>
|
346 |
+
<show_in_website>1</show_in_website>
|
347 |
+
<show_in_store>0</show_in_store>
|
348 |
+
</allowspecific>
|
349 |
+
<specificcountry translate="label">
|
350 |
+
<label>Payment from Specific Countries</label>
|
351 |
+
<frontend_type>multiselect</frontend_type>
|
352 |
+
<sort_order>51</sort_order>
|
353 |
+
<source_model>adminhtml/system_config_source_country</source_model>
|
354 |
+
<show_in_default>1</show_in_default>
|
355 |
+
<show_in_website>1</show_in_website>
|
356 |
+
<show_in_store>0</show_in_store>
|
357 |
+
</specificcountry>
|
358 |
+
<min_order_total translate="label">
|
359 |
+
<label>Minimum Order Total</label>
|
360 |
+
<frontend_type>text</frontend_type>
|
361 |
+
<sort_order>98</sort_order>
|
362 |
+
<show_in_default>1</show_in_default>
|
363 |
+
<show_in_website>1</show_in_website>
|
364 |
+
<show_in_store>0</show_in_store>
|
365 |
+
</min_order_total>
|
366 |
+
<max_order_total translate="label">
|
367 |
+
<label>Maximum Order Total</label>
|
368 |
+
<frontend_type>text</frontend_type>
|
369 |
+
<sort_order>99</sort_order>
|
370 |
+
<show_in_default>1</show_in_default>
|
371 |
+
<show_in_website>1</show_in_website>
|
372 |
+
<show_in_store>0</show_in_store>
|
373 |
+
</max_order_total>
|
374 |
+
<sort_order translate="label">
|
375 |
+
<label>Sort Order</label>
|
376 |
+
<frontend_type>text</frontend_type>
|
377 |
+
<sort_order>100</sort_order>
|
378 |
+
<show_in_default>1</show_in_default>
|
379 |
+
<show_in_website>1</show_in_website>
|
380 |
+
<show_in_store>0</show_in_store>
|
381 |
+
</sort_order>
|
382 |
+
<allow_guest_checkout translate="label">
|
383 |
+
<label>Allow Guest Checkout</label>
|
384 |
+
<frontend_type>select</frontend_type>
|
385 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
386 |
+
<sort_order>110</sort_order>
|
387 |
+
<show_in_default>1</show_in_default>
|
388 |
+
<show_in_website>1</show_in_website>
|
389 |
+
<show_in_store>0</show_in_store>
|
390 |
+
</allow_guest_checkout>
|
391 |
+
<checkout_save_card_checkbox translate="label">
|
392 |
+
<label>Enable "Save Card" Checkbox during Checkout</label>
|
393 |
+
<frontend_type>select</frontend_type>
|
394 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
395 |
+
<sort_order>130</sort_order>
|
396 |
+
<show_in_default>1</show_in_default>
|
397 |
+
<show_in_website>1</show_in_website>
|
398 |
+
<show_in_store>0</show_in_store>
|
399 |
+
</checkout_save_card_checkbox>
|
400 |
+
<use_transparent_redirect translate="label">
|
401 |
+
<label>Use Transparent Redirect / JSONP For Checkout</label>
|
402 |
+
<frontend_type>select</frontend_type>
|
403 |
+
<source_model>adminhtml/system_config_source_yesno</source_model>
|
404 |
+
<sort_order>150</sort_order>
|
405 |
+
<show_in_default>1</show_in_default>
|
406 |
+
<show_in_website>1</show_in_website>
|
407 |
+
<show_in_store>0</show_in_store>
|
408 |
+
<comment>If this feature is disabled, it can significantly increase your PCI compliance requirements since sensitive cardholder data will be touching your servers.</comment>
|
409 |
+
</use_transparent_redirect>
|
410 |
+
</fields>
|
411 |
+
</subscribe_pro>
|
412 |
+
</groups>
|
413 |
+
</payment>
|
414 |
+
</sections>
|
415 |
+
</config>
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-install-1.3.1.8.php
ADDED
@@ -0,0 +1,101 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Installer
|
20 |
+
*/
|
21 |
+
$installer = $this;
|
22 |
+
$installer->startSetup();
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Add product attributes to track subscription products
|
26 |
+
*/
|
27 |
+
if (!$installer->getAttributeId('catalog_product', 'subscription_enabled')) {
|
28 |
+
$installer->addAttribute('catalog_product', 'subscription_enabled', array(
|
29 |
+
'group' => 'Subscribe Pro',
|
30 |
+
'label' => 'Subscription Enabled',
|
31 |
+
'type' => 'int',
|
32 |
+
'input' => 'select',
|
33 |
+
'default' => '0',
|
34 |
+
'class' => '',
|
35 |
+
'backend' => '',
|
36 |
+
'frontend' => '',
|
37 |
+
'source' => 'eav/entity_attribute_source_boolean',
|
38 |
+
'global' => Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_WEBSITE,
|
39 |
+
'visible' => true,
|
40 |
+
'required' => false,
|
41 |
+
'apply_to' => 'simple,bundle,configurable',
|
42 |
+
'user_defined' => false,
|
43 |
+
'searchable' => false,
|
44 |
+
'filterable' => false,
|
45 |
+
'comparable' => false,
|
46 |
+
'visible_on_front' => false,
|
47 |
+
'visible_in_advanced_search' => false,
|
48 |
+
'unique' => false
|
49 |
+
));
|
50 |
+
}
|
51 |
+
|
52 |
+
/**
|
53 |
+
* Add attributes to quote and order items
|
54 |
+
*/
|
55 |
+
$installer->addAttribute('order_item', 'item_fulfils_subscription', array(
|
56 |
+
'type' => Varien_Db_Ddl_Table::TYPE_BOOLEAN,
|
57 |
+
'visible' => true,
|
58 |
+
'required' => false
|
59 |
+
));
|
60 |
+
$installer->addAttribute('order_item', 'subscription_id', array(
|
61 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
62 |
+
'visible' => true,
|
63 |
+
'required' => false
|
64 |
+
));
|
65 |
+
$installer->addAttribute('order_item', 'subscription_interval', array(
|
66 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
67 |
+
'visible' => true,
|
68 |
+
'required' => false
|
69 |
+
));
|
70 |
+
$installer->addAttribute('quote_item', 'item_fulfils_subscription', array(
|
71 |
+
'type' => Varien_Db_Ddl_Table::TYPE_BOOLEAN,
|
72 |
+
'visible' => true,
|
73 |
+
'required' => false
|
74 |
+
));
|
75 |
+
$installer->addAttribute('quote_item', 'subscription_id', array(
|
76 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
77 |
+
'visible' => true,
|
78 |
+
'required' => false
|
79 |
+
));
|
80 |
+
$installer->addAttribute('quote_item', 'subscription_interval', array(
|
81 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
82 |
+
'visible' => true,
|
83 |
+
'required' => false
|
84 |
+
));
|
85 |
+
|
86 |
+
$installer->addAttribute('quote_item', 'create_new_subscription_at_checkout', array(
|
87 |
+
'type' => Varien_Db_Ddl_Table::TYPE_BOOLEAN,
|
88 |
+
'visible' => true,
|
89 |
+
'required' => false
|
90 |
+
));
|
91 |
+
$installer->addAttribute('quote_item', 'new_subscription_interval', array(
|
92 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
93 |
+
'visible' => true,
|
94 |
+
'required' => false
|
95 |
+
));
|
96 |
+
|
97 |
+
/**
|
98 |
+
* Clean up installer
|
99 |
+
*/
|
100 |
+
$installer->endSetup();
|
101 |
+
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-uninstall-1.3.1.4.php
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Uninstall Script
|
21 |
+
* You can run the below PHP and SQL code to cleanup after the module is removed.
|
22 |
+
*/
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Installer
|
26 |
+
*/
|
27 |
+
$installer = $this;
|
28 |
+
$installer->startSetup();
|
29 |
+
|
30 |
+
$installer->removeAttribute('catalog_product', 'subscription_enabled');
|
31 |
+
|
32 |
+
$sql = <<<SQL
|
33 |
+
|
34 |
+
ALTER TABLE sales_flat_quote_item DROP new_subscription_interval;
|
35 |
+
ALTER TABLE sales_flat_quote_item DROP create_new_subscription_at_checkout;
|
36 |
+
ALTER TABLE sales_flat_quote_item DROP subscription_id;
|
37 |
+
ALTER TABLE sales_flat_quote_item DROP item_fulfils_subscription;
|
38 |
+
|
39 |
+
ALTER TABLE sales_flat_order_item DROP subscription_id;
|
40 |
+
ALTER TABLE sales_flat_order_item DROP item_fulfils_subscription;
|
41 |
+
|
42 |
+
DELETE FROM core_resource WHERE code = 'sfc_autoship_setup';
|
43 |
+
|
44 |
+
SQL;
|
45 |
+
|
46 |
+
$installer->run($sql);
|
47 |
+
|
48 |
+
/**
|
49 |
+
* Clean up installer
|
50 |
+
*/
|
51 |
+
$installer->endSetup();
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.1.0-1.1.1.php
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Installer
|
20 |
+
*/
|
21 |
+
$installer = $this;
|
22 |
+
$installer->startSetup();
|
23 |
+
|
24 |
+
$sql = <<<SQL
|
25 |
+
|
26 |
+
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
|
27 |
+
SET time_zone = "+00:00";
|
28 |
+
|
29 |
+
--
|
30 |
+
-- Table structure for table `sfc_autoship_migrated_subscription`
|
31 |
+
--
|
32 |
+
|
33 |
+
CREATE TABLE IF NOT EXISTS `{$this->getTable('autoship/migrated_subscription')}` (
|
34 |
+
`id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'ID',
|
35 |
+
`subscription_id` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'subscription_id',
|
36 |
+
`aw_subscription_id` int(11) NOT NULL COMMENT 'aw_subscription_id',
|
37 |
+
`migration_status` varchar(16) NOT NULL COMMENT 'migration_status',
|
38 |
+
`error_message` varchar(255) NULL COMMENT 'error_message',
|
39 |
+
PRIMARY KEY (`id`)
|
40 |
+
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Migrated Subscriptions Table' AUTO_INCREMENT=1 ;
|
41 |
+
|
42 |
+
SQL;
|
43 |
+
|
44 |
+
// Run script
|
45 |
+
$installer->run($sql);
|
46 |
+
|
47 |
+
/**
|
48 |
+
* Clean up installer
|
49 |
+
*/
|
50 |
+
$installer->endSetup();
|
51 |
+
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.1.2-1.2.0.php
ADDED
@@ -0,0 +1,93 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Installer
|
21 |
+
*/
|
22 |
+
$installer = $this;
|
23 |
+
$installer->startSetup();
|
24 |
+
|
25 |
+
/**
|
26 |
+
* Add attributes to quote and order items
|
27 |
+
*/
|
28 |
+
$installer->addAttribute('order_item', 'item_fulfils_subscription', array(
|
29 |
+
'type' => Varien_Db_Ddl_Table::TYPE_BOOLEAN,
|
30 |
+
'visible' => true,
|
31 |
+
'required' => false
|
32 |
+
));
|
33 |
+
$installer->addAttribute('order_item', 'subscription_id', array(
|
34 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
35 |
+
'visible' => true,
|
36 |
+
'required' => false
|
37 |
+
));
|
38 |
+
$installer->addAttribute('quote_item', 'item_fulfils_subscription', array(
|
39 |
+
'type' => Varien_Db_Ddl_Table::TYPE_BOOLEAN,
|
40 |
+
'visible' => true,
|
41 |
+
'required' => false
|
42 |
+
));
|
43 |
+
$installer->addAttribute('quote_item', 'subscription_id', array(
|
44 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
45 |
+
'visible' => true,
|
46 |
+
'required' => false
|
47 |
+
));
|
48 |
+
$installer->addAttribute('quote_item', 'create_new_subscription_at_checkout', array(
|
49 |
+
'type' => Varien_Db_Ddl_Table::TYPE_BOOLEAN,
|
50 |
+
'visible' => true,
|
51 |
+
'required' => false
|
52 |
+
));
|
53 |
+
$installer->addAttribute('quote_item', 'new_subscription_interval', array(
|
54 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
55 |
+
'visible' => true,
|
56 |
+
'required' => false
|
57 |
+
));
|
58 |
+
|
59 |
+
$sql = <<<SQL
|
60 |
+
|
61 |
+
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
|
62 |
+
SET time_zone = "+00:00";
|
63 |
+
|
64 |
+
ALTER TABLE `{$this->getTable('autoship/migrated_subscription')}` DROP COLUMN `subscription_id`;
|
65 |
+
|
66 |
+
--
|
67 |
+
-- Table structure for table `sfc_autoship_migrated_subscription_item`
|
68 |
+
--
|
69 |
+
CREATE TABLE IF NOT EXISTS `{$this->getTable('autoship/migrated_subscription_item')}` (
|
70 |
+
`id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'ID',
|
71 |
+
`migrated_subscription_id` int(10) unsigned NOT NULL COMMENT 'migrated_subscription_id',
|
72 |
+
`aw_subscription_item_id` int(11) NOT NULL COMMENT 'aw_subscription_item_id',
|
73 |
+
`platform_subscription_id` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'platform_subscription_id',
|
74 |
+
`migration_status` varchar(16) NOT NULL COMMENT 'migration_status',
|
75 |
+
`error_message` varchar(255) NULL COMMENT 'error_message',
|
76 |
+
INDEX (migrated_subscription_id),
|
77 |
+
INDEX (aw_subscription_item_id),
|
78 |
+
PRIMARY KEY (`id`),
|
79 |
+
CONSTRAINT `FK_SFC_AUTOSHIP_MIGRATED_SUB_ITEM` FOREIGN KEY (`migrated_subscription_id`)
|
80 |
+
REFERENCES `{$this->getTable('autoship/migrated_subscription')}` (`id`)
|
81 |
+
ON DELETE CASCADE
|
82 |
+
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Migrated Subscriptions Items Table' AUTO_INCREMENT=1 ;
|
83 |
+
|
84 |
+
SQL;
|
85 |
+
|
86 |
+
// Run script
|
87 |
+
$installer->run($sql);
|
88 |
+
|
89 |
+
/**
|
90 |
+
* Clean up installer
|
91 |
+
*/
|
92 |
+
$installer->endSetup();
|
93 |
+
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.2.2.1-1.2.2.2.php
ADDED
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Installer
|
21 |
+
*/
|
22 |
+
$installer = $this;
|
23 |
+
$installer->startSetup();
|
24 |
+
|
25 |
+
$sql = <<<SQL
|
26 |
+
|
27 |
+
SET SQL_MODE='NO_AUTO_VALUE_ON_ZERO';
|
28 |
+
SET time_zone = '+00:00';
|
29 |
+
|
30 |
+
CREATE TABLE IF NOT EXISTS `{$this->getTable('autoship/adapter_ordergroove_row')}` (
|
31 |
+
`row_id` int(11) unsigned NOT NULL AUTO_INCREMENT,
|
32 |
+
`status` varchar(25) DEFAULT '',
|
33 |
+
`error_message` text DEFAULT '',
|
34 |
+
`rowdata` blob,
|
35 |
+
PRIMARY KEY (`row_id`)
|
36 |
+
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
|
37 |
+
|
38 |
+
SQL;
|
39 |
+
|
40 |
+
// Run script
|
41 |
+
$installer->run($sql);
|
42 |
+
|
43 |
+
/**
|
44 |
+
* Clean up installer
|
45 |
+
*/
|
46 |
+
$installer->endSetup();
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.2.3-1.2.4.php
ADDED
@@ -0,0 +1,77 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Installer
|
21 |
+
*/
|
22 |
+
$installer = $this;
|
23 |
+
$installer->startSetup();
|
24 |
+
|
25 |
+
/**
|
26 |
+
* Add product attributes to track subscription products
|
27 |
+
*/
|
28 |
+
if (!$installer->getAttributeId('catalog_product', 'subscription_enabled')) {
|
29 |
+
$installer->addAttribute('catalog_product', 'subscription_enabled', array(
|
30 |
+
'group' => 'Subscribe Pro',
|
31 |
+
'label' => 'Subscription Enabled',
|
32 |
+
'type' => 'int',
|
33 |
+
'input' => 'select',
|
34 |
+
'default' => '0',
|
35 |
+
'class' => '',
|
36 |
+
'backend' => '',
|
37 |
+
'frontend' => '',
|
38 |
+
'source' => 'eav/entity_attribute_source_boolean',
|
39 |
+
'global' => Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_STORE,
|
40 |
+
'visible' => true,
|
41 |
+
'required' => false,
|
42 |
+
'apply_to' => 'simple,bundle,configurable',
|
43 |
+
'user_defined' => false,
|
44 |
+
'searchable' => false,
|
45 |
+
'filterable' => false,
|
46 |
+
'comparable' => false,
|
47 |
+
'visible_on_front' => false,
|
48 |
+
'visible_in_advanced_search' => false,
|
49 |
+
'unique' => false
|
50 |
+
));
|
51 |
+
}
|
52 |
+
|
53 |
+
$sql = <<<SQL
|
54 |
+
|
55 |
+
INSERT INTO `{$this->getTable('catalog_product_entity_int')}`
|
56 |
+
(entity_type_id, attribute_id, store_id, entity_id, value)
|
57 |
+
SELECT
|
58 |
+
(SELECT entity_type_id FROM `{$this->getTable('eav/entity_type')}` WHERE entity_type_code = 'catalog_product'),
|
59 |
+
(SELECT attribute_id FROM `{$this->getTable('eav/attribute')}` WHERE attribute_code = 'subscription_enabled'),
|
60 |
+
(SELECT store_id FROM `{$this->getTable('core/store')}` WHERE code = 'admin'),
|
61 |
+
product_id entity_id,
|
62 |
+
enabled `value`
|
63 |
+
FROM `{$this->getTable('autoship/legacy_product_profile')}`
|
64 |
+
;
|
65 |
+
|
66 |
+
DROP TABLE `{$this->getTable('autoship/legacy_product_profile')}`;
|
67 |
+
|
68 |
+
SQL;
|
69 |
+
|
70 |
+
// Run script
|
71 |
+
$installer->run($sql);
|
72 |
+
|
73 |
+
/**
|
74 |
+
* Clean up installer
|
75 |
+
*/
|
76 |
+
$installer->endSetup();
|
77 |
+
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.2.4.6-1.2.4.7.php
ADDED
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Installer
|
21 |
+
*/
|
22 |
+
$installer = $this;
|
23 |
+
$installer->startSetup();
|
24 |
+
|
25 |
+
$sql = <<<SQL
|
26 |
+
|
27 |
+
SET SQL_MODE='NO_AUTO_VALUE_ON_ZERO';
|
28 |
+
SET time_zone = '+00:00';
|
29 |
+
|
30 |
+
CREATE TABLE IF NOT EXISTS `{$this->getTable('autoship/adapter_ordergroove_row')}` (
|
31 |
+
`row_id` int(11) unsigned NOT NULL AUTO_INCREMENT,
|
32 |
+
`status` varchar(25) DEFAULT '',
|
33 |
+
`error_message` text DEFAULT '',
|
34 |
+
`rowdata` blob,
|
35 |
+
PRIMARY KEY (`row_id`)
|
36 |
+
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
|
37 |
+
|
38 |
+
SQL;
|
39 |
+
|
40 |
+
// Run script
|
41 |
+
$installer->run($sql);
|
42 |
+
|
43 |
+
/**
|
44 |
+
* Clean up installer
|
45 |
+
*/
|
46 |
+
$installer->endSetup();
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.0.1-1.3.0.2.php
ADDED
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Installer
|
20 |
+
*/
|
21 |
+
$installer = $this;
|
22 |
+
$installer->startSetup();
|
23 |
+
|
24 |
+
$sql = <<<SQL
|
25 |
+
|
26 |
+
SET SQL_MODE='NO_AUTO_VALUE_ON_ZERO';
|
27 |
+
SET time_zone = '+00:00';
|
28 |
+
|
29 |
+
CREATE TABLE IF NOT EXISTS `{$this->getTable('autoship/migrated_cimProfile')}` (
|
30 |
+
`id` int(11) unsigned NOT NULL AUTO_INCREMENT,
|
31 |
+
`cim_token` varchar(255),
|
32 |
+
`spreedly_token` varchar(255),
|
33 |
+
`status` varchar(25) DEFAULT '',
|
34 |
+
`error_message` text DEFAULT '',
|
35 |
+
PRIMARY KEY (`id`),
|
36 |
+
UNIQUE KEY `IDX_SFC_AUTOSHIP_CIM_PR_CIM_TOKEN` (`cim_token`),
|
37 |
+
UNIQUE KEY `IDX_SFC_AUTOSHIP_CIM_PR_SPREE_TOKEN` (`spreedly_token`)
|
38 |
+
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
|
39 |
+
|
40 |
+
SQL;
|
41 |
+
|
42 |
+
// Run script
|
43 |
+
$installer->run($sql);
|
44 |
+
|
45 |
+
/**
|
46 |
+
* Clean up installer
|
47 |
+
*/
|
48 |
+
$installer->endSetup();
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.0.5-1.3.1.0.php
ADDED
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Installer
|
20 |
+
*/
|
21 |
+
$installer = $this;
|
22 |
+
$installer->startSetup();
|
23 |
+
|
24 |
+
// Update subscription_enabled product attribute to move it to website scope
|
25 |
+
$installer->updateAttribute(
|
26 |
+
'catalog_product',
|
27 |
+
'subscription_enabled',
|
28 |
+
'is_global',
|
29 |
+
Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_WEBSITE
|
30 |
+
);
|
31 |
+
|
32 |
+
|
33 |
+
/**
|
34 |
+
* Clean up installer
|
35 |
+
*/
|
36 |
+
$installer->endSetup();
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.1.3-1.3.1.4.php
ADDED
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Installer
|
20 |
+
*/
|
21 |
+
$installer = $this;
|
22 |
+
$installer->startSetup();
|
23 |
+
|
24 |
+
// Update subscription_enabled product attribute to have it only apply to simple, config and bundle products
|
25 |
+
$installer->updateAttribute(
|
26 |
+
'catalog_product',
|
27 |
+
'subscription_enabled',
|
28 |
+
'apply_to',
|
29 |
+
'simple,configurable,bundle'
|
30 |
+
);
|
31 |
+
|
32 |
+
$sql = <<<SQL
|
33 |
+
|
34 |
+
DROP TABLE IF EXISTS sfc_autoship_migrated_subscription_item;
|
35 |
+
DROP TABLE IF EXISTS sfc_autoship_migrated_subscription;
|
36 |
+
DROP TABLE IF EXISTS sfc_autoship_migrated_cim_profile;
|
37 |
+
DROP TABLE IF EXISTS sfc_autoship_og_subscription;
|
38 |
+
DROP TABLE IF EXISTS sfc_autoship_subscription_order;
|
39 |
+
|
40 |
+
SQL;
|
41 |
+
|
42 |
+
$installer->run($sql);
|
43 |
+
|
44 |
+
/**
|
45 |
+
* Clean up installer
|
46 |
+
*/
|
47 |
+
$installer->endSetup();
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.1.4-1.3.1.5.php
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Installer
|
20 |
+
*/
|
21 |
+
$installer = $this;
|
22 |
+
$installer->startSetup();
|
23 |
+
|
24 |
+
$installer->addAttribute('order_item', 'subscription_interval', array(
|
25 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
26 |
+
'visible' => true,
|
27 |
+
'required' => false
|
28 |
+
));
|
29 |
+
$installer->addAttribute('quote_item', 'subscription_interval', array(
|
30 |
+
'type' => Varien_Db_Ddl_Table::TYPE_VARCHAR,
|
31 |
+
'visible' => true,
|
32 |
+
'required' => false
|
33 |
+
));
|
34 |
+
|
35 |
+
/**
|
36 |
+
* Clean up installer
|
37 |
+
*/
|
38 |
+
$installer->endSetup();
|
app/code/local/SFC/Autoship/sql/sfc_autoship_setup/mysql4-upgrade-1.3.1.7-1.3.1.8.php
ADDED
@@ -0,0 +1,43 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Installer
|
20 |
+
*/
|
21 |
+
$installer = $this;
|
22 |
+
$installer->startSetup();
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Remove all legacy tables
|
26 |
+
*/
|
27 |
+
$sql = <<<SQL
|
28 |
+
|
29 |
+
DROP TABLE IF EXISTS `{$this->getTable('autoship/migrated_subscription_item')}`;
|
30 |
+
DROP TABLE IF EXISTS `{$this->getTable('autoship/migrated_subscription')}`;
|
31 |
+
DROP TABLE IF EXISTS `{$this->getTable('autoship/migrated_cimProfile')}`;
|
32 |
+
DROP TABLE IF EXISTS `{$this->getTable('autoship/adapter_ordergroove_row')}`;
|
33 |
+
DROP TABLE IF EXISTS `{$this->getTable('autoship/subscription_order')}`;
|
34 |
+
DROP TABLE IF EXISTS `{$this->getTable('autoship/legacy_product_profile')}`;
|
35 |
+
|
36 |
+
SQL;
|
37 |
+
|
38 |
+
$installer->run($sql);
|
39 |
+
|
40 |
+
/**
|
41 |
+
* Clean up installer
|
42 |
+
*/
|
43 |
+
$installer->endSetup();
|
app/design/adminhtml/default/default/layout/autoship.xml
ADDED
@@ -0,0 +1,43 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
-->
|
19 |
+
|
20 |
+
<layout version="0.1.0">
|
21 |
+
|
22 |
+
<adminhtml_sales_order_create_index>
|
23 |
+
<reference name="head">
|
24 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/jquery-1.10.1.min.js</name></action>
|
25 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/noconflict.js</name></action>
|
26 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/sales_create_order.js</name></action>
|
27 |
+
</reference>
|
28 |
+
<reference name="js">
|
29 |
+
<block type="autoship/adminhtml_sales_order_create_jsonp" name="jsonp" template="autoship/sales/create_order/jsonp.phtml" after="-"/>
|
30 |
+
</reference>
|
31 |
+
</adminhtml_sales_order_create_index>
|
32 |
+
|
33 |
+
<!-- Saved Credit Cards tab in ADMIN > CUSTOMER > EDIT > GRID -->
|
34 |
+
<adminhtml_customer_edit>
|
35 |
+
<reference name="customer_edit_tabs">
|
36 |
+
<action method="addTab">
|
37 |
+
<name>paymentprofile</name>
|
38 |
+
<block>autoship/adminhtml_customer_paymentprofiles_paymentprofile</block>
|
39 |
+
</action>
|
40 |
+
</reference>
|
41 |
+
</adminhtml_customer_edit>
|
42 |
+
|
43 |
+
</layout>
|
app/design/adminhtml/default/default/template/autoship/payment/form/cc.phtml
ADDED
@@ -0,0 +1,73 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $_code = $this->getMethodCode() ?>
|
19 |
+
<ul class="form-list" id="payment_form_<?php echo $_code ?>" style="display:none;">
|
20 |
+
<input type="hidden" id="<?php echo $_code ?>_payment_token" name="payment[payment_token]" title="<?php echo $this->__('Payment Token') ?>" value="<?php echo $this->getAdditionalInfo('payment_token') ?>" />
|
21 |
+
<input type="hidden" id="<?php echo $_code ?>_is_new_card" name="payment[is_new_card]" title="<?php echo $this->__('Is New Card') ?>" value="1" />
|
22 |
+
<?php if($this->forceSaveCard()): ?>
|
23 |
+
<input type="hidden" id="<?php echo $_code ?>_save_card" name="payment[save_card]" title="<?php echo $this->__('Save Card') ?>" value="1" />
|
24 |
+
<?php endif; ?>
|
25 |
+
<li>
|
26 |
+
<div class="input-box">
|
27 |
+
<label for="<?php echo $_code ?>_cc_number"><?php echo Mage::helper('payment')->__('Credit Card Number') ?> <span class="required">*</span></label><br/>
|
28 |
+
<input type="text" id="<?php echo $_code ?>_cc_number" name="payment[cc_number]" title="<?php echo $this->__('Credit Card Number') ?>" class="input-text" value="<?php echo $this->getAdditionalInfo('obscured_cc_number') ?>" />
|
29 |
+
</div>
|
30 |
+
</li>
|
31 |
+
<li id="<?php echo $_code ?>_cc_type_exp_div">
|
32 |
+
<div class="input-box">
|
33 |
+
<label for="<?php echo $_code ?>_expiration"><?php echo Mage::helper('payment')->__('Expiration Date') ?> <span class="required">*</span></label><br/>
|
34 |
+
<select id="<?php echo $_code ?>_expiration" style="width:140px;" name="payment[cc_exp_month]" class="validate-cc-exp required-entry">
|
35 |
+
<?php $_ccExpMonth = $this->getInfoData('cc_exp_month') ?>
|
36 |
+
<?php foreach ($this->getCcMonths() as $k=>$v): ?>
|
37 |
+
<option value="<?php echo $k ?>" <?php if($k==$_ccExpMonth): ?>selected="selected"<?php endif ?>><?php echo $v ?></option>
|
38 |
+
<?php endforeach ?>
|
39 |
+
</select>
|
40 |
+
<?php $_ccExpYear = $this->getInfoData('cc_exp_year') ?>
|
41 |
+
<select id="<?php echo $_code ?>_expiration_yr" style="width:103px;" name="payment[cc_exp_year]" class="required-entry">
|
42 |
+
<?php foreach ($this->getCcYears() as $k=>$v): ?>
|
43 |
+
<option value="<?php echo $k ? $k : '' ?>" <?php if($k==$_ccExpYear): ?>selected="selected"<?php endif ?>><?php echo $v ?></option>
|
44 |
+
<?php endforeach ?>
|
45 |
+
</select>
|
46 |
+
</div>
|
47 |
+
</li>
|
48 |
+
<?php echo $this->getChildHtml() ?>
|
49 |
+
<li id="<?php echo $_code ?>_cc_type_cvv_div">
|
50 |
+
<label for="<?php echo $_code ?>_cc_cid" ><?php echo $this->__('Card Verification Number') ?></label>
|
51 |
+
<div class="input-box">
|
52 |
+
<div class="v-fix">
|
53 |
+
<input type="text" title="<?php echo $this->__('Card Verification Number') ?>"
|
54 |
+
class="input-text"
|
55 |
+
id="<?php echo $_code ?>_cc_cid"
|
56 |
+
name="payment[cc_cid]" />
|
57 |
+
</div>
|
58 |
+
</div>
|
59 |
+
</li>
|
60 |
+
<?php if($this->useSaveCardCheckbox()): ?>
|
61 |
+
<li id="<?php echo $_code ?>_cc_save_card_div">
|
62 |
+
<div class="input-box">
|
63 |
+
<label for="<?php echo $_code ?>_save_card"><?php echo Mage::helper('payment')->__('Save My Card') ?></label><br/>
|
64 |
+
<div class="v-fix">
|
65 |
+
<input type='hidden' value='0' name='payment[save_card]'/>
|
66 |
+
<input type="checkbox" title="<?php echo $this->__('Save Card') ?>" class="checkbox"
|
67 |
+
id="<?php echo $_code ?>_save_card" name="payment[save_card]"
|
68 |
+
value="1" <?php if($this->getAdditionalInfo('save_card')): ?>checked<?php endif; ?> />
|
69 |
+
</div>
|
70 |
+
</div>
|
71 |
+
</li>
|
72 |
+
<?php endif; ?>
|
73 |
+
</ul>
|
app/design/adminhtml/default/default/template/autoship/payment/form/cc_saved.phtml
ADDED
@@ -0,0 +1,58 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $_code = $this->getMethodCode() ?>
|
19 |
+
<?php $_paymentProfile = $this->getMethod()->getSavedPaymentProfile() ?>
|
20 |
+
<?php echo $this->getChildHtml() ?>
|
21 |
+
<ul id="payment_form_<?php echo $_code ?>" style="display:none;">
|
22 |
+
<input type="hidden" id="<?php echo $_code ?>_payment_token" name="payment[payment_token]"
|
23 |
+
title="<?php echo $this->__('Payment Token') ?>" value="<?php echo $_paymentProfile->getData('payment_token') ?>"/>
|
24 |
+
<input type="hidden" id="<?php echo $_code ?>_is_new_card" name="payment[is_new_card]"
|
25 |
+
title="<?php echo $this->__('Is New Card') ?>" value="0"/>
|
26 |
+
<input type="hidden" id="<?php echo $_code ?>_cc_number" name="payment[cc_number]"
|
27 |
+
title="<?php echo $this->__('Obscured Card Number') ?>" value="<?php echo $this->getObscuredCardNumber() ?>"/>
|
28 |
+
<input type="hidden" id="<?php echo $_code ?>_cc_type" name="payment[cc_type]" title="<?php echo $this->__('Card Type') ?>"
|
29 |
+
value="<?php echo $this->getMagentoCardType() ?>"/>
|
30 |
+
<li id="<?php echo $_code ?>_cc_type_exp_div">
|
31 |
+
<div class="input-box">
|
32 |
+
<label for="<?php echo $_code ?>_expiration"><?php echo Mage::helper('payment')->__('Expiration Date') ?> <span class="required">*</span></label><br/>
|
33 |
+
<select id="<?php echo $_code ?>_expiration" style="width:140px;" name="payment[cc_exp_month]" class="validate-cc-exp required-entry">
|
34 |
+
<?php $_ccExpMonth = $_paymentProfile->getData('creditcard_month') ?>
|
35 |
+
<?php foreach ($this->getCcMonths() as $k=>$v): ?>
|
36 |
+
<option value="<?php echo $k ?>" <?php if($k==$_ccExpMonth): ?>selected="selected"<?php endif ?>><?php echo $v ?></option>
|
37 |
+
<?php endforeach ?>
|
38 |
+
</select>
|
39 |
+
<?php $_ccExpYear = $_paymentProfile->getData('creditcard_year') ?>
|
40 |
+
<select id="<?php echo $_code ?>_expiration_yr" style="width:103px;" name="payment[cc_exp_year]" class="required-entry">
|
41 |
+
<?php foreach ($this->getCcYears() as $k=>$v): ?>
|
42 |
+
<option value="<?php echo $k ? $k : '' ?>" <?php if($k==$_ccExpYear): ?>selected="selected"<?php endif ?>><?php echo $v ?></option>
|
43 |
+
<?php endforeach ?>
|
44 |
+
</select>
|
45 |
+
</div>
|
46 |
+
</li>
|
47 |
+
<li id="<?php echo $_code ?>_cc_type_cvv_div">
|
48 |
+
<label for="<?php echo $_code ?>_cc_cid"><?php echo $this->__('Card Verification Number') ?>
|
49 |
+
</label>
|
50 |
+
|
51 |
+
<div class="input-box">
|
52 |
+
<div class="v-fix">
|
53 |
+
<input type="text" title="<?php echo $this->__('Card Verification Number') ?>" class="input-text"
|
54 |
+
id="<?php echo $_code ?>_cc_cid" name="payment[cc_cid]" value=""/>
|
55 |
+
</div>
|
56 |
+
</div>
|
57 |
+
</li>
|
58 |
+
</ul>
|
app/design/adminhtml/default/default/template/autoship/sales/create_order/jsonp.phtml
ADDED
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php if ($this->showJsonp()): ?>
|
19 |
+
<script type="text/javascript">
|
20 |
+
var jsonpEnvironmentKey = "<?php echo $this->getEnvironmentKey() ?>";
|
21 |
+
var jsonpUrl = "<?php echo $this->getJSONPUrl() ?>";
|
22 |
+
</script>
|
23 |
+
<?php endif; ?>
|
app/design/adminhtml/default/default/template/autoship/system/config/test_connection_button.phtml
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<script type="text/javascript">
|
2 |
+
//<![CDATA[
|
3 |
+
function testConnection() {
|
4 |
+
new Ajax.Request('<?php echo $this->getAjaxCheckUrl() ?>', {
|
5 |
+
method: 'post',
|
6 |
+
parameters: {
|
7 |
+
host: $('autoship_general_platform_api_platform_host').value,
|
8 |
+
client_id: $('autoship_general_platform_api_client_id').value,
|
9 |
+
client_secret: $('autoship_general_platform_api_client_secret').value
|
10 |
+
},
|
11 |
+
onSuccess: function(transport){
|
12 |
+
if (transport.responseText == 1){
|
13 |
+
$('test_connection_result').update('<span style="padding-left: 10px;color: #468847;"><strong>(Connected Successfully.)</strong></span>');
|
14 |
+
}
|
15 |
+
else {
|
16 |
+
$('test_connection_result').update('<span style="padding-left: 10px;color: #b94a48;"><strong>(Failed to connect to platform!)</strong></span>');
|
17 |
+
}
|
18 |
+
}
|
19 |
+
});
|
20 |
+
}
|
21 |
+
//]]>
|
22 |
+
</script>
|
23 |
+
|
24 |
+
<?php echo $this->getBut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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
-->
|
19 |
+
<layout version="0.1.0">
|
20 |
+
|
21 |
+
<!-- My Product Subscriptions page -->
|
22 |
+
<autoship_mysubscriptions_index>
|
23 |
+
<label>My Product Subscriptions</label>
|
24 |
+
<update handle="customer_account" />
|
25 |
+
|
26 |
+
<reference name="head">
|
27 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
28 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/jquery-1.10.1.min.js</name></action>
|
29 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.core.min.js</name></action>
|
30 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.datepicker.min.js</name></action>
|
31 |
+
<action method="addItem"><type>skin_css</type><name>js/autoship/jquery/ui/theme/jquery-ui.css</name></action>
|
32 |
+
|
33 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/noconflict.js</name></action>
|
34 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/mysubscription.js</name></action>
|
35 |
+
|
36 |
+
<action method="addItem"><type>js_css</type><name>calendar/calendar-win2k-1.css</name><params/><!--<if/><condition>can_load_calendar_js</condition>--></action>
|
37 |
+
<action method="addItem"><type>js</type><name>calendar/calendar.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
38 |
+
<action method="addItem"><type>js</type><name>calendar/calendar-setup.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
39 |
+
</reference>
|
40 |
+
|
41 |
+
<reference name="customer_account_navigation">
|
42 |
+
<action method="setActive"><path>autoship/mysubscriptions/</path></action>
|
43 |
+
</reference>
|
44 |
+
|
45 |
+
<reference name="my.account.wrapper">
|
46 |
+
<block type="autoship/mysubscriptions" name="mysubscriptions" template="autoship/mysubscriptions.phtml" />
|
47 |
+
</reference>
|
48 |
+
</autoship_mysubscriptions_index>
|
49 |
+
|
50 |
+
<!-- Customer dashboard link -->
|
51 |
+
<customer_account>
|
52 |
+
<reference name="customer_account_navigation">
|
53 |
+
<action method="addLink" translate="label" module="autoship" ifconfig="autoship_general/general/enabled">
|
54 |
+
<name>mysubscriptions</name>
|
55 |
+
<path>autoship/mysubscriptions/</path>
|
56 |
+
<label>My Product Subscriptions</label>
|
57 |
+
</action>
|
58 |
+
</reference>
|
59 |
+
</customer_account>
|
60 |
+
|
61 |
+
<!-- New Subscription page -->
|
62 |
+
<autoship_newsubscription_index>
|
63 |
+
<label>Create New Product Subscription</label>
|
64 |
+
|
65 |
+
<reference name="root">
|
66 |
+
<action method="setTemplate"><template>page/1column.phtml</template></action>
|
67 |
+
</reference>
|
68 |
+
|
69 |
+
<reference name="head">
|
70 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
71 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/jquery-1.10.1.min.js</name></action>
|
72 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.core.min.js</name></action>
|
73 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.datepicker.min.js</name></action>
|
74 |
+
<action method="addItem"><type>skin_css</type><name>js/autoship/jquery/ui/theme/jquery-ui.css</name></action>
|
75 |
+
|
76 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/noconflict.js</name></action>
|
77 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/newsubscription.js</name></action>
|
78 |
+
|
79 |
+
<action method="addItem"><type>js_css</type><name>calendar/calendar-win2k-1.css</name><params/><!--<if/><condition>can_load_calendar_js</condition>--></action>
|
80 |
+
<action method="addItem"><type>js</type><name>calendar/calendar.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
81 |
+
<action method="addItem"><type>js</type><name>calendar/calendar-setup.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
82 |
+
</reference>
|
83 |
+
|
84 |
+
<reference name="content">
|
85 |
+
<block type="autoship/newsubscription" name="newsubscription" template="autoship/newsubscription.phtml" >
|
86 |
+
<block type="autoship/newsubscription" name="newsubscription.product_info" template="autoship/newsubscription/product_info.phtml" />
|
87 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_date" template="autoship/newsubscription/delivery_date.phtml">
|
88 |
+
<block type="core/html_calendar" name="html_calendar" as="html_calendar" template="page/js/calendar.phtml"/>
|
89 |
+
</block>
|
90 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_frequency" template="autoship/newsubscription/delivery_frequency.phtml" />
|
91 |
+
<block type="autoship/newsubscription" name="newsubscription.payment" template="autoship/newsubscription/payment.phtml">
|
92 |
+
<block type="autoship/newsubscription_form_payment" name="payment" template="autoship/subscription/form/payment.phtml" />
|
93 |
+
</block>
|
94 |
+
<block type="autoship/newsubscription" name="newsubscription.billing_address" template="autoship/newsubscription/billing_address.phtml">
|
95 |
+
<block type="autoship/newsubscription_form_billing" name="billing_address_select" template="autoship/subscription/form/billing.phtml"/>
|
96 |
+
</block>
|
97 |
+
<block type="autoship/newsubscription" name="newsubscription.shipping_address" template="autoship/newsubscription/shipping_address.phtml">
|
98 |
+
<block type="autoship/newsubscription_form_shipping" name="shipping_address_select" template="autoship/subscription/form/shipping.phtml"/>
|
99 |
+
</block>
|
100 |
+
<block type="autoship/newsubscription" name="newsubscription.summary" template="autoship/newsubscription/summary.phtml" />
|
101 |
+
</block>
|
102 |
+
</reference>
|
103 |
+
|
104 |
+
</autoship_newsubscription_index>
|
105 |
+
|
106 |
+
<!-- This layout handle handles all ajax controllers that update new subscription page contents -->
|
107 |
+
<autoship_newsubscription_update>
|
108 |
+
<remove name="right"/>
|
109 |
+
<remove name="left"/>
|
110 |
+
|
111 |
+
<block type="autoship/newsubscription" name="root" output="toHtml" template="autoship/newsubscription/ajax_update.phtml">
|
112 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_date" template="autoship/newsubscription/delivery_date.phtml">
|
113 |
+
<block type="core/html_calendar" name="html_calendar" as="html_calendar" template="page/js/calendar.phtml"/>
|
114 |
+
</block>
|
115 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_frequency" template="autoship/newsubscription/delivery_frequency.phtml" />
|
116 |
+
<block type="autoship/newsubscription" name="newsubscription.payment" template="autoship/newsubscription/payment.phtml">
|
117 |
+
<block type="autoship/newsubscription_form_payment" name="payment" template="autoship/subscription/form/payment.phtml" />
|
118 |
+
</block>
|
119 |
+
<block type="autoship/newsubscription" name="newsubscription.billing_address" template="autoship/newsubscription/billing_address.phtml">
|
120 |
+
<block type="autoship/newsubscription_form_billing" name="billing_address_select" template="autoship/subscription/form/billing.phtml"/>
|
121 |
+
</block>
|
122 |
+
<block type="autoship/newsubscription" name="newsubscription.shipping_address" template="autoship/newsubscription/shipping_address.phtml">
|
123 |
+
<block type="autoship/newsubscription_form_shipping" name="shipping_address_select" template="autoship/subscription/form/shipping.phtml"/>
|
124 |
+
</block>
|
125 |
+
<block type="autoship/newsubscription" name="newsubscription.summary" template="autoship/newsubscription/summary.phtml" />
|
126 |
+
</block>
|
127 |
+
</autoship_newsubscription_update>
|
128 |
+
|
129 |
+
<autoship_newsubscription_paymentsave>
|
130 |
+
<update handle="autoship_newsubscription_update"/>
|
131 |
+
</autoship_newsubscription_paymentsave>
|
132 |
+
|
133 |
+
<autoship_newsubscription_billingsave>
|
134 |
+
<update handle="autoship_newsubscription_update"/>
|
135 |
+
</autoship_newsubscription_billingsave>
|
136 |
+
|
137 |
+
<autoship_newsubscription_shippingsave>
|
138 |
+
<update handle="autoship_newsubscription_update"/>
|
139 |
+
</autoship_newsubscription_shippingsave>
|
140 |
+
|
141 |
+
<!--
|
142 |
+
Product view
|
143 |
+
-->
|
144 |
+
|
145 |
+
<catalog_product_view>
|
146 |
+
<reference name="head">
|
147 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
148 |
+
</reference>
|
149 |
+
|
150 |
+
<!-- Create subscribe and autoship block in product info area -->
|
151 |
+
<reference name="product.info">
|
152 |
+
<block type="autoship/product_subscribe" name="product.info.subscribe" as="product.info.subscribe" template="autoship/product/subscribe.phtml"/>
|
153 |
+
</reference>
|
154 |
+
|
155 |
+
<!-- Insert block into correct location in product info with insert method -->
|
156 |
+
<reference name="product.info.options.wrapper.bottom">
|
157 |
+
<action method="insert"><block>product.info.subscribe</block><siblingName>product.info.addtocart</siblingName></action>
|
158 |
+
</reference>
|
159 |
+
|
160 |
+
<!-- Replace addtocart.phtml template with ours -->
|
161 |
+
<reference name="product.info.addtocart">
|
162 |
+
<action method="setTemplate"><template>autoship/product/view/addtocart.phtml</template></action>
|
163 |
+
</reference>
|
164 |
+
|
165 |
+
</catalog_product_view>
|
166 |
+
|
167 |
+
<!-- Add subscription features to cart page -->
|
168 |
+
<checkout_cart_index>
|
169 |
+
<reference name="head">
|
170 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
171 |
+
</reference>
|
172 |
+
<reference name="additional.product.info">
|
173 |
+
<block type="autoship/cart_product_subscription" name="autoship.product.subscription" template="autoship/cart/product/subscription.phtml"/>
|
174 |
+
</reference>
|
175 |
+
</checkout_cart_index>
|
176 |
+
|
177 |
+
<!-- Add message about subscriptions to checkout success page -->
|
178 |
+
<checkout_onepage_success translate="label">
|
179 |
+
<reference name="checkout.success">
|
180 |
+
<block type="core/template" name="checkout.success.subscriptions" template="autoship/checkout/success.phtml"/>
|
181 |
+
</reference>
|
182 |
+
</checkout_onepage_success>
|
183 |
+
|
184 |
+
<!-- Payment Profile grid-->
|
185 |
+
<autoship_mycreditcards_index>
|
186 |
+
<label>Payment Profiles</label>
|
187 |
+
<update handle="customer_account"/>
|
188 |
+
<reference name="customer_account_navigation">
|
189 |
+
<action method="setActive">
|
190 |
+
<path>subscriptions/mycreditcards/</path>
|
191 |
+
</action>
|
192 |
+
</reference>
|
193 |
+
<reference name="my.account.wrapper">
|
194 |
+
<block type="autoship/payment_profile_grid" name="payment_profile_index"
|
195 |
+
template="autoship/payment/profile/grid.phtml"/>
|
196 |
+
</reference>
|
197 |
+
</autoship_mycreditcards_index>
|
198 |
+
|
199 |
+
<!-- Payment Profile customer dashboard link -->
|
200 |
+
<customer_account>
|
201 |
+
<reference name="customer_account_navigation">
|
202 |
+
<action method="addLink" translate="label" module="autoship" ifconfig="payment/subscribe_pro/active">
|
203 |
+
<name>mycreditcards</name>
|
204 |
+
<path>subscriptions/mycreditcards/</path>
|
205 |
+
<label>My Credit Cards</label>
|
206 |
+
</action>
|
207 |
+
</reference>
|
208 |
+
</customer_account>
|
209 |
+
|
210 |
+
<!-- Edit Payment Profile -->
|
211 |
+
<autoship_mycreditcards_edit>
|
212 |
+
<label>Edit Payment Profile</label>
|
213 |
+
<update handle="customer_account"/>
|
214 |
+
<reference name="customer_account_navigation">
|
215 |
+
<action method="setActive">
|
216 |
+
<path>subscriptions/mycreditcards/</path>
|
217 |
+
</action>
|
218 |
+
</reference>
|
219 |
+
<reference name="my.account.wrapper">
|
220 |
+
<block type="autoship/payment_profile_edit" name="payment_profile_edit"
|
221 |
+
template="autoship/payment/profile/edit.phtml">
|
222 |
+
</block>
|
223 |
+
</reference>
|
224 |
+
</autoship_mycreditcards_edit>
|
225 |
+
|
226 |
+
<!-- New Payment Profile -->
|
227 |
+
<autoship_mycreditcards_new>
|
228 |
+
<label>New Payment Profile</label>
|
229 |
+
<update handle="customer_account"/>
|
230 |
+
<reference name="customer_account_navigation">
|
231 |
+
<action method="setActive">
|
232 |
+
<path>subscriptions/mycreditcards/</path>
|
233 |
+
</action>
|
234 |
+
</reference>
|
235 |
+
<reference name="my.account.wrapper">
|
236 |
+
<block type="autoship/payment_profile_edit" name="payment_profile_edit"
|
237 |
+
template="autoship/payment/profile/new.phtml">
|
238 |
+
</block>
|
239 |
+
</reference>
|
240 |
+
</autoship_mycreditcards_new>
|
241 |
+
|
242 |
+
<!-- Include transparent redirect javascript in one page checkout -->
|
243 |
+
<checkout_onepage_index>
|
244 |
+
<reference name="head">
|
245 |
+
<action method="addItem" ifconfig="payment/subscribe_pro/use_transparent_redirect"><type>skin_js</type><name>js/autoship/jquery/jquery-1.10.1.min.js</name></action>
|
246 |
+
<action method="addItem" ifconfig="payment/subscribe_pro/use_transparent_redirect"><type>skin_js</type><name>js/autoship/jquery/noconflict.js</name></action>
|
247 |
+
</reference>
|
248 |
+
<reference name="content">
|
249 |
+
<block type="autoship/checkout_jsonp" name="jsonp" template="autoship/checkout/jsonp.phtml" after="-"/>
|
250 |
+
<block type="autoship/checkout_jsonp" name="serversideapi" template="autoship/checkout/serversideapi.phtml" after="-"/>
|
251 |
+
</reference>
|
252 |
+
</checkout_onepage_index>
|
253 |
+
|
254 |
+
</layout>
|
app/design/frontend/base/default/template/autoship/cart/product/subscription.phtml
ADDED
@@ -0,0 +1,75 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php if(Mage::getStoreConfig('autoship_general/general/enabled') == '1'): ?>
|
20 |
+
<?php if(Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page') != '1'): ?>
|
21 |
+
<?php $quoteItem = $this->getQuoteItem(); ?>
|
22 |
+
<?php if ($this->isItemSubscriptionEligible()): ?>
|
23 |
+
<div class="subscription-product">
|
24 |
+
<p><?php echo $this->__('Would you like to receive regular shipments of this item?') ?></p>
|
25 |
+
<ul class="options-list">
|
26 |
+
<li>
|
27 |
+
<input type="radio" onclick="" class="radio"
|
28 |
+
onchange="this.form.submit();"
|
29 |
+
id="<?php echo $quoteItem->getId() ?>-delivery-option-one-time"
|
30 |
+
name="cart[<?php echo $quoteItem->getId() ?>][delivery-option]"
|
31 |
+
value="one-time-delivery"
|
32 |
+
<?php if (!$this->isItemFlaggedToCreateNewSubscription()): ?>checked="checked"<?php endif; ?>
|
33 |
+
/>
|
34 |
+
|
35 |
+
<div class="radio-text">
|
36 |
+
<span class=label>
|
37 |
+
<label for="delivery-option-one-time">One Time Delivery</label>
|
38 |
+
</span>
|
39 |
+
</div>
|
40 |
+
<div class="clearer"></div>
|
41 |
+
</li>
|
42 |
+
<li>
|
43 |
+
<input type="radio" onclick="" class="radio"
|
44 |
+
onchange="this.form.submit();"
|
45 |
+
id="<?php echo $quoteItem->getId() ?>-delivery-option-subscribe"
|
46 |
+
name="cart[<?php echo $quoteItem->getId() ?>][delivery-option]" value="subscribe"
|
47 |
+
<?php if ($this->isItemFlaggedToCreateNewSubscription()): ?>checked="checked"<?php endif; ?>
|
48 |
+
/>
|
49 |
+
|
50 |
+
<div class="radio-text">
|
51 |
+
<span class=label>
|
52 |
+
<label for="delivery-option-subscribe">Regular Delivery</label>
|
53 |
+
</span>
|
54 |
+
|
55 |
+
<p>
|
56 |
+
<label for="delivery-interval">Delivery every:</label><br/>
|
57 |
+
<select onchange=""
|
58 |
+
id="<?php echo $quoteItem->getId() ?>-delivery-interval"
|
59 |
+
name="cart[<?php echo $quoteItem->getId() ?>][delivery-interval]"
|
60 |
+
class="">
|
61 |
+
<?php foreach ($this->getIntervals() as $interval): ?>
|
62 |
+
<option value="<?php echo $interval ?>" <?php if($interval == $this->getNewSubscriptionInterval()): ?>selected="selected"<?php endif; ?>>
|
63 |
+
<?php echo $interval ?>
|
64 |
+
</option>
|
65 |
+
<?php endforeach; ?>
|
66 |
+
</select>
|
67 |
+
</p>
|
68 |
+
</div>
|
69 |
+
<div class="clearer"></div>
|
70 |
+
</li>
|
71 |
+
</ul>
|
72 |
+
</div>
|
73 |
+
<?php endif; ?>
|
74 |
+
<?php endif; ?>
|
75 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/checkout/jsonp.phtml
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php if (Mage::getStoreConfig('payment/subscribe_pro/active') == '1'): ?>
|
19 |
+
<?php if (Mage::getStoreConfig('payment/subscribe_pro/use_transparent_redirect') == '1'): ?>
|
20 |
+
<script type="text/javascript">
|
21 |
+
var jsonpEnvironmentKey = "<?php echo $this->getEnvironmentKey() ?>";
|
22 |
+
var jsonpUrl = "<?php echo $this->getJSONPUrl() ?>";
|
23 |
+
</script>
|
24 |
+
<script type="text/javascript" src="<?php echo $this->getSkinUrl('js/autoship/checkout.js') ?>"></script>
|
25 |
+
<?php endif; ?>
|
26 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/checkout/serversideapi.phtml
ADDED
@@ -0,0 +1,65 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php if (Mage::getStoreConfig('payment/subscribe_pro/active') == '1'): ?>
|
19 |
+
<?php if (Mage::getStoreConfig('payment/subscribe_pro/use_transparent_redirect') != '1'): ?>
|
20 |
+
<script type="text/javascript">
|
21 |
+
document.observe('dom:loaded', pageInit);
|
22 |
+
function pageInit() {
|
23 |
+
// Replace payment save function
|
24 |
+
payment.save = function () {
|
25 |
+
if (this.currentMethod != 'subscribe_pro') {
|
26 |
+
// Call original payment save function
|
27 |
+
return Payment.prototype.save.call(this);
|
28 |
+
}
|
29 |
+
// Save this ref so we can use to call original payment.save method
|
30 |
+
var paymentSaveThis = this;
|
31 |
+
// Check if we are already running and return immediately if so
|
32 |
+
if (checkout.loadWaiting != false)
|
33 |
+
return;
|
34 |
+
// Check if we already have a tokenized card
|
35 |
+
var cardAlreadyTokenized =
|
36 |
+
$('subscribe_pro_payment_token').value.length > 0 &&
|
37 |
+
$('subscribe_pro_cc_number').value.indexOf('XXXXXX') >= 0
|
38 |
+
;
|
39 |
+
// Check if card is already tokenized
|
40 |
+
if (cardAlreadyTokenized) {
|
41 |
+
// Card already tokenized, so skip js validation
|
42 |
+
// Turn on waiting indicator
|
43 |
+
checkout.setLoadWaiting('payment');
|
44 |
+
// Make payment save ajax call (without doing validation first)
|
45 |
+
var request = new Ajax.Request(
|
46 |
+
this.saveUrl,
|
47 |
+
{
|
48 |
+
method:'post',
|
49 |
+
onComplete: this.onComplete,
|
50 |
+
onSuccess: this.onSave,
|
51 |
+
onFailure: checkout.ajaxFailure.bind(checkout),
|
52 |
+
parameters: Form.serialize(this.form)
|
53 |
+
}
|
54 |
+
);
|
55 |
+
}
|
56 |
+
else {
|
57 |
+
// Call original payment save function
|
58 |
+
// Original method include js validation, then ajax POST to server
|
59 |
+
return Payment.prototype.save.call(this);
|
60 |
+
}
|
61 |
+
}
|
62 |
+
}
|
63 |
+
</script>
|
64 |
+
<?php endif; ?>
|
65 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/checkout/success.phtml
ADDED
@@ -0,0 +1,32 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php if(Mage::getStoreConfig('autoship_general/general/enabled') == '1'): ?>
|
20 |
+
<?php if(Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page') != '1'): ?>
|
21 |
+
<?php $createdSubscriptionIds = $this->getCreatedSubscriptionIds(); ?>
|
22 |
+
<?php if ($this->getFailedSubscriptionCount()): ?>
|
23 |
+
<?php // Output error message ?>
|
24 |
+
<p>Failed to create some of your product subscriptions! Please contact support for assistance.</p>
|
25 |
+
<?php endif; ?>
|
26 |
+
<?php if (is_array($createdSubscriptionIds) && count($createdSubscriptionIds)): ?>
|
27 |
+
<p>You will receive a separate email confirmation for your product subscription(s). Click here to <a
|
28 |
+
href="<?php echo $this->getUrl('autoship/mysubscriptions') ?>">manage your product subscriptions</a>.
|
29 |
+
</p>
|
30 |
+
<?php endif; ?>
|
31 |
+
<?php endif; ?>
|
32 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/mysubscriptions.phtml
ADDED
@@ -0,0 +1,120 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<div class="page-title">
|
20 |
+
<h1>My Product Subscriptions</h1>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div id="mysubscriptions">
|
24 |
+
<?php
|
25 |
+
if($this->getNextOrderDateMode() != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES
|
26 |
+
&& count($this->getActiveSubscriptions())):
|
27 |
+
?>
|
28 |
+
<?php
|
29 |
+
$activeSubscriptions = $this->getActiveSubscriptions();
|
30 |
+
$firstSubscription = $activeSubscriptions[0];
|
31 |
+
?>
|
32 |
+
<div class="subscription-more-details" id="all-subscriptions-details">
|
33 |
+
<form id="all-subscriptions-date-form" class="all-subscriptions-date-form" action="<?php echo Mage::getUrl('autoship/mysubscriptions/change', array('_secure' => true)) ?>">
|
34 |
+
<input type="hidden" name="id" id="subscription_id"
|
35 |
+
value="all_active"/>
|
36 |
+
<p>Next Ship Date:</p>
|
37 |
+
<div class="input-box">
|
38 |
+
<input type="text" id="delivery_date"
|
39 |
+
name="delivery_date"
|
40 |
+
value="<?php echo $firstSubscription->getNextOrderDateText() ?>"
|
41 |
+
title="<?php echo $this->__('Next Ship Date:') ?>" class="input-text delivery_date"/>
|
42 |
+
</div>
|
43 |
+
</form>
|
44 |
+
<?php
|
45 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
46 |
+
->setParentBlock($this)
|
47 |
+
->setTemplate('autoship/mysubscriptions/subscription/shipping_address.phtml')
|
48 |
+
->setSubscription($firstSubscription)
|
49 |
+
->toHtml();
|
50 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
51 |
+
->setParentBlock($this)
|
52 |
+
->setTemplate('autoship/mysubscriptions/subscription/billing_address.phtml')
|
53 |
+
->setSubscription($firstSubscription)
|
54 |
+
->toHtml();
|
55 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
56 |
+
->setParentBlock($this)
|
57 |
+
->setTemplate('autoship/mysubscriptions/subscription/payment.phtml')
|
58 |
+
->setSubscription($firstSubscription)
|
59 |
+
->toHtml();
|
60 |
+
?>
|
61 |
+
<div class="clearer"></div>
|
62 |
+
</div>
|
63 |
+
<?php endif; ?>
|
64 |
+
|
65 |
+
<div class="active-subscriptions">
|
66 |
+
<?php foreach($this->getActiveSubscriptions() as $subscription): ?>
|
67 |
+
<div class="subscription-block">
|
68 |
+
<?php echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
69 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
70 |
+
->setSubscription($subscription)
|
71 |
+
->toHtml() ?>
|
72 |
+
</div>
|
73 |
+
<?php endforeach; ?>
|
74 |
+
</div>
|
75 |
+
</div>
|
76 |
+
<div class="inactive-subscriptions">
|
77 |
+
<?php foreach($this->getInactiveSubscriptions() as $subscription): ?>
|
78 |
+
<div class="subscription-block">
|
79 |
+
<?php echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription')
|
80 |
+
->setTemplate('autoship/mysubscriptions/subscription.phtml')
|
81 |
+
->setSubscription($subscription)
|
82 |
+
->toHtml()
|
83 |
+
?>
|
84 |
+
</div>
|
85 |
+
<?php endforeach; ?>
|
86 |
+
</div>
|
87 |
+
<span class="please-wait" id="please-wait" style="display:none;">
|
88 |
+
<img src="<?php echo $this->getSkinUrl('images/opc-ajax-loader.gif') ?>" alt="<?php echo $this->__('Updating...') ?>" title="<?php echo $this->__('Updating...') ?>" class="v-middle" /> <?php echo $this->__('Updating...') ?>
|
89 |
+
</span>
|
90 |
+
<div class="buttons-set">
|
91 |
+
<p class="back-link"><a href="<?php echo Mage::getUrl('customer/account/'); ?>"><small>«</small> Back</a></p>
|
92 |
+
</div>
|
93 |
+
|
94 |
+
<script type="text/javascript">
|
95 |
+
//<![CDATA[
|
96 |
+
var regionsJson =
|
97 |
+
<?php echo $this->helper('directory')->getRegionJson() ?>
|
98 |
+
;
|
99 |
+
<?php if ($this->getNextOrderDateMode() == SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
100 |
+
var editMultipleSubscriptions = false;
|
101 |
+
<?php endif; ?>
|
102 |
+
<?php if ($this->getNextOrderDateMode() != SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
103 |
+
$j(function () {
|
104 |
+
$j("#delivery_date").datepicker({
|
105 |
+
minDate: 2,
|
106 |
+
showOn: "button",
|
107 |
+
buttonImage: "<?php echo $this->getSkinUrl('images/autoship/calendar_icon.png')?>",
|
108 |
+
buttonImageOnly: true,
|
109 |
+
buttonText: "Click to change date.",
|
110 |
+
dateFormat: "mm/dd/y",
|
111 |
+
onSelect: function () {
|
112 |
+
var form = $j(this).closest("form");
|
113 |
+
updateAllSubscriptions(form);
|
114 |
+
}
|
115 |
+
});
|
116 |
+
});
|
117 |
+
var editMultipleSubscriptions = true;
|
118 |
+
<?php endif; ?>
|
119 |
+
//]]>
|
120 |
+
</script>
|
app/design/frontend/base/default/template/autoship/mysubscriptions/subscription.phtml
ADDED
@@ -0,0 +1,34 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php $subscription = $this->getSubscription(); ?>
|
20 |
+
<ul class="messages"></ul>
|
21 |
+
<?php echo $this->createChildSubscriptionBlock('subscription_info.phtml')->toHtml() ?>
|
22 |
+
<?php echo $this->createChildSubscriptionBlock('product_info.phtml')->toHtml() ?>
|
23 |
+
<?php echo $this->createChildSubscriptionBlock('actions.phtml')->toHtml() ?>
|
24 |
+
<div class="clearer"></div>
|
25 |
+
<?php if($this->getNextOrderDateMode() == SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
26 |
+
<div class="subscription-more-details" style="display:none;" id="<?php echo $subscription->getSubscriptionId() ?>-more-details-div">
|
27 |
+
<?php echo $this->createChildSubscriptionBlock('shipping_address.phtml')->toHtml() ?>
|
28 |
+
<?php if ($this->showBillingAddressBlock()): ?>
|
29 |
+
<?php echo $this->createChildSubscriptionBlock('billing_address.phtml')->toHtml() ?>
|
30 |
+
<?php endif; ?>
|
31 |
+
<?php echo $this->createChildSubscriptionBlock('payment.phtml')->toHtml() ?>
|
32 |
+
</div>
|
33 |
+
<div class="clearer"></div>
|
34 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/actions.phtml
ADDED
@@ -0,0 +1,115 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$subscription = $this->getSubscription();
|
21 |
+
$product = $this->getProduct();
|
22 |
+
?>
|
23 |
+
<div class="subscription-actions">
|
24 |
+
<?php if ($subscription->getStatus() == 'Active'): ?>
|
25 |
+
<?php if ($this->getNextOrderDateMode() == SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
26 |
+
<button type="button" title="<?php echo $this->__('Skip Next Delivery') ?>" class="button change skip">
|
27 |
+
<span><span><?php echo $this->__('Skip Next Delivery') ?></span></span></button>
|
28 |
+
<?php endif; ?>
|
29 |
+
<div>
|
30 |
+
<p><a href="<?php echo $this->getUrl('autoship/mysubscriptions/cancel/id/' . $subscription->getSubscriptionId(),
|
31 |
+
array('_secure' => true)) ?>" class="change cancel"><?php echo $this->__('Cancel Subscription') ?></a></p>
|
32 |
+
|
33 |
+
<p><a href="<?php echo $product->getProductUrl() ?>">Need more immediately?</a></p>
|
34 |
+
|
35 |
+
<p> </p>
|
36 |
+
|
37 |
+
<?php if ($this->getNextOrderDateMode() == SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
38 |
+
<p><a href="<?php echo $subscription->getSubscriptionId() ?>-more-details-div"
|
39 |
+
class="link more details">More Details...</a></p>
|
40 |
+
<?php endif; ?>
|
41 |
+
</div>
|
42 |
+
<?php elseif ($subscription->getStatus() == 'Failed' || $subscription->getStatus() == 'Retry'): ?>
|
43 |
+
<p>Status:</p>
|
44 |
+
<p><span class="status"><strong><?php echo $subscription->getStatus() ?></strong></span></p>
|
45 |
+
<div>
|
46 |
+
<p><a href="<?php echo $this->getUrl('autoship/mysubscriptions/restart/id/' . $subscription->getSubscriptionId(),
|
47 |
+
array('_secure' => true)) ?>" class="change restart"><?php echo $this->__('Restart Subscription') ?></a></p>
|
48 |
+
|
49 |
+
<p> </p>
|
50 |
+
|
51 |
+
<?php if ($this->getNextOrderDateMode() == SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
52 |
+
<p><a href="<?php echo $subscription->getSubscriptionId() ?>-more-details-div"
|
53 |
+
class="link more details">More Details...</a></p>
|
54 |
+
<?php endif; ?>
|
55 |
+
</div>
|
56 |
+
<?php else: ?>
|
57 |
+
<p>Status:</p>
|
58 |
+
<p><span class="status"><strong><?php echo $subscription->getStatus() ?></strong></span></p>
|
59 |
+
<?php endif; ?>
|
60 |
+
</div>
|
61 |
+
<div class="change skip-delivery" style="display:none;">
|
62 |
+
<div class="block-title">
|
63 |
+
<h2>Skip Delivery?</h2>
|
64 |
+
</div>
|
65 |
+
<div class="block-content">
|
66 |
+
<p>Skipping delivery on <?php echo $subscription->getNextOrderDateText() ?>.</p>
|
67 |
+
|
68 |
+
<div class="buttons-set">
|
69 |
+
<button type="button" title="<?php echo $this->__('Okay') ?>" href="<?php echo Mage::getUrl('autoship/mysubscriptions/skip',
|
70 |
+
array(
|
71 |
+
'id' => $subscription->getSubscriptionId(),
|
72 |
+
'_secure' => true,
|
73 |
+
)) ?>" class="button skip_yes"><span><span><?php echo $this->__('Okay') ?></span></span></button>
|
74 |
+
<button type="button" title="<?php echo $this->__('Cancel') ?>" class="button no">
|
75 |
+
<span><span><?php echo $this->__('Cancel') ?></span></span></button>
|
76 |
+
</div>
|
77 |
+
</div>
|
78 |
+
</div>
|
79 |
+
<div class="change cancel" style="display:none;">
|
80 |
+
<div class="block-title">
|
81 |
+
<h2>Cancel Subscription?</h2>
|
82 |
+
</div>
|
83 |
+
<div class="block-content">
|
84 |
+
<p>Are you sure you want to cancel your subscription?</p>
|
85 |
+
|
86 |
+
<div class="buttons-set">
|
87 |
+
<button type="button" title="<?php echo $this->__('Yes') ?>"
|
88 |
+
href="<?php echo Mage::getUrl('autoship/mysubscriptions/cancel', array(
|
89 |
+
'id' => $subscription->getSubscriptionId(),
|
90 |
+
'_secure' => true
|
91 |
+
)) ?>" class="button cancel_yes"><span><span><?php echo $this->__('Yes') ?></span></span></button>
|
92 |
+
<button type="button" title="<?php echo $this->__('No') ?>" class="button no">
|
93 |
+
<span><span><?php echo $this->__('No') ?></span></span></button>
|
94 |
+
</div>
|
95 |
+
</div>
|
96 |
+
</div>
|
97 |
+
<div class="change restart" style="display:none;">
|
98 |
+
<div class="block-title">
|
99 |
+
<h2>Restart Subscription?</h2>
|
100 |
+
</div>
|
101 |
+
<div class="block-content">
|
102 |
+
<p>Are you sure you want to restart your subscription?</p>
|
103 |
+
|
104 |
+
<div class="buttons-set">
|
105 |
+
<button type="button" title="<?php echo $this->__('Yes') ?>"
|
106 |
+
href="<?php echo Mage::getUrl('autoship/mysubscriptions/restart', array(
|
107 |
+
'id' => $subscription->getSubscriptionId(),
|
108 |
+
'_secure' => true
|
109 |
+
)) ?>" class="button restart_yes"><span><span><?php echo $this->__('Yes') ?></span></span></button>
|
110 |
+
<button type="button" title="<?php echo $this->__('No') ?>" class="button no">
|
111 |
+
<span><span><?php echo $this->__('No') ?></span></span></button>
|
112 |
+
</div>
|
113 |
+
</div>
|
114 |
+
</div>
|
115 |
+
|
app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/billing_address.phtml
ADDED
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
$subscription = $this->getSubscription();
|
20 |
+
$billingAddress = $subscription->getBillingAddress();
|
21 |
+
?>
|
22 |
+
<div class="block subscription-billing-address">
|
23 |
+
<p><strong>Billing address:</strong> <a class="change" href="">(Change)</a></p>
|
24 |
+
<address>
|
25 |
+
<?php echo $billingAddress->getFirstname() ?> <?php echo $billingAddress->getLastname() ?><br/>
|
26 |
+
<?php if (strlen($billingAddress->getCompany())): ?>
|
27 |
+
<?php echo $billingAddress->getCompany() ?><br/>
|
28 |
+
<?php endif; ?>
|
29 |
+
<?php foreach ($billingAddress->getStreet() as $street): ?>
|
30 |
+
<?php echo $street ?><br/>
|
31 |
+
<?php endforeach; ?>
|
32 |
+
<?php echo $billingAddress->getCity() ?>
|
33 |
+
, <?php echo $billingAddress->getRegion() ?> <?php echo $billingAddress->getPostcode() ?><br/>
|
34 |
+
</address>
|
35 |
+
|
36 |
+
<input type="text" id="billing_address_id" name="billing_address_id" value="<?php echo $billingAddress->getId() ?>"
|
37 |
+
class="input-text" style="display:none;"/>
|
38 |
+
|
39 |
+
<div class="change" style="display: none;">
|
40 |
+
<div class="block-title">
|
41 |
+
<h2>Change Billing Address</h2>
|
42 |
+
</div>
|
43 |
+
<div class="block-content">
|
44 |
+
<?php
|
45 |
+
// Output payment form
|
46 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription_form_billing')
|
47 |
+
->setParentBlock($this)
|
48 |
+
->setTemplate('autoship/subscription/form/billing.phtml')
|
49 |
+
->setSubscription($this->getSubscription())
|
50 |
+
->toHtml();
|
51 |
+
?>
|
52 |
+
</div>
|
53 |
+
</div>
|
54 |
+
</div>
|
app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/payment.phtml
ADDED
@@ -0,0 +1,49 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$subscription = $this->getSubscription();
|
21 |
+
?>
|
22 |
+
<div class="block subscription-payment">
|
23 |
+
<p><strong>Payment Information:</strong></p>
|
24 |
+
<?php if (strlen($subscription->getData('payment_token'))): ?>
|
25 |
+
<p>Credit card ending in <?php echo $subscription->getData('creditcard_last_digits') ?> <a class="change" href="">(Change)</a></p>
|
26 |
+
<p><a href="<?php echo $this->getNewCardUrl() ?>">Add a new credit card</a></p>
|
27 |
+
<?php else: ?>
|
28 |
+
<p>Haven't saved a credit card yet? <a href="<?php echo $this->getNewCardUrl() ?>">Add one now</a>.</p>
|
29 |
+
<?php endif; ?>
|
30 |
+
|
31 |
+
<input type="text" id="payment_token" name="payment_token" value="<?php echo $subscription->getData('payment_token') ?>"
|
32 |
+
class="input-text" style="display:none;"/>
|
33 |
+
|
34 |
+
<div class="change" style="display:none;">
|
35 |
+
<div class="block-title">
|
36 |
+
<h2>Change Payment Method</h2>
|
37 |
+
</div>
|
38 |
+
<div class="block-content">
|
39 |
+
<?php
|
40 |
+
// Output payment form
|
41 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription_form_payment')
|
42 |
+
->setParentBlock($this)
|
43 |
+
->setTemplate('autoship/subscription/form/payment.phtml')
|
44 |
+
->setSubscription($this->getSubscription())
|
45 |
+
->toHtml();
|
46 |
+
?>
|
47 |
+
</div>
|
48 |
+
</div>
|
49 |
+
</div>
|
app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/product_info.phtml
ADDED
@@ -0,0 +1,39 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$subscription = $this->getSubscription();
|
21 |
+
$product = $this->getProduct();
|
22 |
+
?>
|
23 |
+
<div class="subscription-product">
|
24 |
+
<?php // Product Image ?>
|
25 |
+
<a href="<?php echo $product->getProductUrl() ?>"
|
26 |
+
title="<?php echo $this->stripTags($this->getImageLabel($product, 'small_image'), null, true) ?>" class="product-image"><img
|
27 |
+
src="<?php echo $this->helper('catalog/image')->init($product, 'small_image')->resize(80); ?>" width="80" height="80"
|
28 |
+
alt="<?php echo $this->stripTags($this->getImageLabel($product, 'small_image'), null, true) ?>"/></a>
|
29 |
+
<?php // Product Name ?>
|
30 |
+
<?php $_productNameStripped = $this->stripTags($product->getName(), null, true); ?>
|
31 |
+
<h2 class="product-name"><a href="<?php echo $product->getProductUrl() ?>"
|
32 |
+
title="<?php echo $_productNameStripped; ?>"><?php echo $product->getName() ?></a></h2>
|
33 |
+
|
34 |
+
<p><span class="product-original-price">One-Time Purchase Price: <?php echo $this->getOneTimePurchasePrice(true) ?></span><br/>
|
35 |
+
<span class="product-price"><?php echo $this->getSubscriptionPriceText() ?></span></p>
|
36 |
+
<?php if (strlen($subscription->getCouponCode())): ?>
|
37 |
+
<p>Applied coupon code: <?php echo $subscription->getCouponCode() ?></p>
|
38 |
+
<?php endif; ?>
|
39 |
+
</div>
|
app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/shipping_address.phtml
ADDED
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
$subscription = $this->getSubscription();
|
20 |
+
$shippingAddress = $subscription->getShippingAddress();
|
21 |
+
?>
|
22 |
+
<div class="block subscription-shipping-address">
|
23 |
+
<p><strong>Delivery address:</strong> <a class="change" href="">(Change)</a></p>
|
24 |
+
<address>
|
25 |
+
<?php echo $shippingAddress->getFirstname() ?> <?php echo $shippingAddress->getLastname() ?><br/>
|
26 |
+
<?php if (strlen($shippingAddress->getCompany())): ?>
|
27 |
+
<?php echo $shippingAddress->getCompany() ?><br/>
|
28 |
+
<?php endif; ?>
|
29 |
+
<?php foreach ($shippingAddress->getStreet() as $street): ?>
|
30 |
+
<?php echo $street ?><br/>
|
31 |
+
<?php endforeach; ?>
|
32 |
+
<?php echo $shippingAddress->getCity() ?>
|
33 |
+
, <?php echo $shippingAddress->getRegion() ?> <?php echo $shippingAddress->getPostcode() ?><br/>
|
34 |
+
</address>
|
35 |
+
|
36 |
+
<input type="text" id="shipping_address_id" name="shipping_address_id" value="<?php echo $shippingAddress->getId() ?>"
|
37 |
+
class="input-text" style="display:none;"/>
|
38 |
+
|
39 |
+
<div class="change" style="display: none;">
|
40 |
+
<div class="block-title">
|
41 |
+
<h2>Change Shipping Address</h2>
|
42 |
+
</div>
|
43 |
+
<div class="block-content">
|
44 |
+
<?php
|
45 |
+
// Output payment form
|
46 |
+
echo $this->getLayout()->createBlock('autoship/mysubscriptions_subscription_form_shipping')
|
47 |
+
->setParentBlock($this)
|
48 |
+
->setTemplate('autoship/subscription/form/shipping.phtml')
|
49 |
+
->setSubscription($this->getSubscription())
|
50 |
+
->toHtml();
|
51 |
+
?>
|
52 |
+
</div>
|
53 |
+
</div>
|
54 |
+
</div>
|
app/design/frontend/base/default/template/autoship/mysubscriptions/subscription/subscription_info.phtml
ADDED
@@ -0,0 +1,95 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$subscription = $this->getSubscription();
|
21 |
+
$platformProduct = $subscription->getPlatformProduct();
|
22 |
+
$qty = $subscription->getQty();
|
23 |
+
$intervals = $this->getIntervals();
|
24 |
+
?>
|
25 |
+
<div class="subscription-info">
|
26 |
+
<form class="interval" action="<?php echo Mage::getUrl('autoship/mysubscriptions/change', array('_secure' => true)) ?>">
|
27 |
+
<?php if ($this->getNextOrderDateMode() == SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
28 |
+
<p>Next Ship Date:</p>
|
29 |
+
<?php if ($subscription->getStatus() == 'Active' && $subscription->getNextOrderDate() >= date('Y-m-d', strtotime('+2 days'))
|
30 |
+
): ?>
|
31 |
+
<?php // Only allow change of next ship date if its more than 2 days in the future ?>
|
32 |
+
<div class="input-box">
|
33 |
+
<input type="text" id="delivery_date_<?php echo $subscription->getSubscriptionId() ?>"
|
34 |
+
name="delivery_date"
|
35 |
+
value="<?php echo $subscription->getNextOrderDateText() ?>"
|
36 |
+
title="<?php echo $this->__('Next Ship Date:') ?>" class="input-text delivery_date"/>
|
37 |
+
</div>
|
38 |
+
<?php
|
39 |
+
elseif ($subscription->getStatus() == 'Active' && $subscription->getNextOrderDate() < date('Y-m-d', strtotime('+2 days'))
|
40 |
+
): ?>
|
41 |
+
<p><span class="next-order-date"><strong><?php echo $subscription->getNextOrderDateText() ?></strong></span></p>
|
42 |
+
<?php
|
43 |
+
else: ?>
|
44 |
+
<p><span class="next-order-date"><strong><?php echo 'n/a' ?></strong></span></p>
|
45 |
+
<?php endif; ?>
|
46 |
+
<?php endif; ?>
|
47 |
+
<?php if ($subscription->getStatus() == 'Active' || $subscription->getStatus() == 'Failed' || $subscription->getStatus() == 'Retry'): ?>
|
48 |
+
<p>
|
49 |
+
<input type="hidden" name="id" id="subscription_id_<?php echo $subscription->getSubscriptionId() ?>"
|
50 |
+
value="<?php echo $subscription->getSubscriptionId() ?>"/>
|
51 |
+
<select id="delivery_qty_<?php echo $subscription->getSubscriptionId() ?>"
|
52 |
+
name="delivery_qty" class="delivery_qty" title="Quantity">
|
53 |
+
<?php if ($qty < $platformProduct->getMinQty()): ?>
|
54 |
+
<option value="<?php echo $qty ?>" selected="selected"><?php echo $qty ?></option>
|
55 |
+
<?php endif; ?>
|
56 |
+
<?php for ($i = $platformProduct->getMinQty(); $i <= $platformProduct->getMaxQty(); $i++): ?>
|
57 |
+
<option value="<?php echo $i ?>"
|
58 |
+
<?php if ($qty == $i): ?>selected="selected"<?php endif; ?>><?php echo $i ?></option>
|
59 |
+
<?php endfor; ?>
|
60 |
+
<?php if ($qty > $platformProduct->getMaxQty()): ?>
|
61 |
+
<option value="<?php echo $qty ?>" selected="selected"><?php echo $qty ?></option>
|
62 |
+
<?php endif; ?>
|
63 |
+
</select>
|
64 |
+
unit(s) every
|
65 |
+
<select id="delivery_interval_<?php echo $subscription->getSubscriptionId() ?>"
|
66 |
+
name="delivery_interval" class="delivery_interval" title="Delivery Interval">
|
67 |
+
<?php foreach ($intervals as $interval): ?>
|
68 |
+
<option value="<?php echo $interval ?>" <?php if ($interval ==
|
69 |
+
$subscription->getInterval()): ?>selected="selected"<?php endif; ?>><?php echo $interval ?></option>
|
70 |
+
<?php endforeach; ?>
|
71 |
+
</select>
|
72 |
+
</p>
|
73 |
+
<?php endif; ?>
|
74 |
+
</form>
|
75 |
+
</div>
|
76 |
+
<?php if ($this->getNextOrderDateMode() == SFC_Autoship_Model_System_Config_Source_Nextorderdatemode::MODE_MULTIPLE_DATES): ?>
|
77 |
+
<script type="text/javascript">
|
78 |
+
//<![CDATA[
|
79 |
+
$j(function () {
|
80 |
+
$j("#delivery_date_<?php echo $subscription->getSubscriptionId() ?>").datepicker({
|
81 |
+
minDate: 2,
|
82 |
+
showOn: "button",
|
83 |
+
buttonImage: "<?php echo $this->getSkinUrl('images/autoship/calendar_icon.png')?>",
|
84 |
+
buttonImageOnly: true,
|
85 |
+
buttonText: "Click to change date.",
|
86 |
+
dateFormat: "mm/dd/y",
|
87 |
+
onSelect: function () {
|
88 |
+
var form = $j(this).closest("form");
|
89 |
+
updateMySubscription(form);
|
90 |
+
}
|
91 |
+
})
|
92 |
+
});
|
93 |
+
//]]>
|
94 |
+
</script>
|
95 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/newsubscription.phtml
ADDED
@@ -0,0 +1,75 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
|
19 |
+
<div class="page-title">
|
20 |
+
<h1>Create New Product Subscription</h1>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="new-subscription subscription">
|
24 |
+
<div class="top-row">
|
25 |
+
<div class="product-info-block">
|
26 |
+
<?php echo $this->getChildHtml('newsubscription.product_info') ?>
|
27 |
+
</div>
|
28 |
+
<div class="block delivery-date-block">
|
29 |
+
<?php echo $this->getChildHtml('newsubscription.delivery_date') ?>
|
30 |
+
</div>
|
31 |
+
<div class="clearer"></div>
|
32 |
+
</div><!-- end top-row -->
|
33 |
+
<div class="bottom-row">
|
34 |
+
<div class="bottom-left">
|
35 |
+
<div class="bottom-top">
|
36 |
+
<div class="block frequency-block">
|
37 |
+
<?php echo $this->getChildHtml('newsubscription.delivery_frequency') ?>
|
38 |
+
</div>
|
39 |
+
<div class="block payment-block">
|
40 |
+
<?php echo $this->getChildHtml('newsubscription.payment') ?>
|
41 |
+
</div>
|
42 |
+
<div class="clearer"></div>
|
43 |
+
</div><!-- end bottom-top -->
|
44 |
+
<div class="bottom-bottom">
|
45 |
+
<div class="block billing-address-block">
|
46 |
+
<?php echo $this->getChildHtml('newsubscription.billing_address') ?>
|
47 |
+
</div>
|
48 |
+
<div class="block shipping-address-block">
|
49 |
+
<?php echo $this->getChildHtml('newsubscription.shipping_address') ?>
|
50 |
+
</div>
|
51 |
+
<div class="clearer"></div>
|
52 |
+
</div><!-- end bottom-bottom -->
|
53 |
+
</div><!-- end bottom-left -->
|
54 |
+
<div class="bottom-right">
|
55 |
+
<div class="block summary-block" id="newsubscription_summary">
|
56 |
+
<?php echo $this->getChildHtml('newsubscription.summary') ?>
|
57 |
+
</div>
|
58 |
+
</div><!-- end bottom-right -->
|
59 |
+
</div><!-- end bottom-row -->
|
60 |
+
<span class="please-wait" id="please-wait" style="display:none;">
|
61 |
+
<img src="<?php echo $this->getSkinUrl('images/opc-ajax-loader.gif') ?>" alt="<?php echo $this->__('Updating...') ?>" title="<?php echo $this->__('Updating...') ?>" class="v-middle" /> <?php echo $this->__('Updating...') ?>
|
62 |
+
</span>
|
63 |
+
</div><!-- end new-subscription -->
|
64 |
+
|
65 |
+
<div style="clear:both;"></div>
|
66 |
+
|
67 |
+
<div id="updated-subscription-content" style="display:none;"></div>
|
68 |
+
|
69 |
+
<script type="text/javascript">
|
70 |
+
//<![CDATA[
|
71 |
+
var regionsJson =
|
72 |
+
<?php echo $this->helper('directory')->getRegionJson() ?>
|
73 |
+
;
|
74 |
+
//]]>
|
75 |
+
</script>
|
app/design/frontend/base/default/template/autoship/newsubscription/ajax_update.phtml
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
|
19 |
+
<div class="block delivery-date-block">
|
20 |
+
<?php echo $this->getChildHtml('newsubscription.delivery_date') ?>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="block payment-block">
|
24 |
+
<?php echo $this->getChildHtml('newsubscription.payment') ?>
|
25 |
+
</div>
|
26 |
+
|
27 |
+
<div class="block billing-address-block">
|
28 |
+
<?php echo $this->getChildHtml('newsubscription.billing_address') ?>
|
29 |
+
</div>
|
30 |
+
|
31 |
+
<div class="block shipping-address-block">
|
32 |
+
<?php echo $this->getChildHtml('newsubscription.shipping_address') ?>
|
33 |
+
</div>
|
34 |
+
|
35 |
+
<div class="block summary-block" id="newsubscription_summary">
|
36 |
+
<?php echo $this->getChildHtml('newsubscription.summary') ?>
|
37 |
+
</div>
|
38 |
+
|
app/design/frontend/base/default/template/autoship/newsubscription/billing_address.phtml
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
$subscription = $this->getSubscription();
|
20 |
+
$billingAddress = $subscription->getBillingAddress();
|
21 |
+
?>
|
22 |
+
|
23 |
+
<div class="block-title">
|
24 |
+
<h2>Billing Address</h2>
|
25 |
+
</div>
|
26 |
+
|
27 |
+
<div class="box-padding">
|
28 |
+
<p>Please select the address associated with your payment method: <a class="change" href="">(Change)</a></p>
|
29 |
+
|
30 |
+
<address>
|
31 |
+
<?php echo $billingAddress->getFirstname() ?> <?php echo $billingAddress->getLastname() ?><br/>
|
32 |
+
<?php if(strlen($billingAddress->getCompany())): ?>
|
33 |
+
<?php echo $billingAddress->getCompany() ?><br/>
|
34 |
+
<?php endif; ?>
|
35 |
+
<?php foreach($billingAddress->getStreet() as $street): ?>
|
36 |
+
<?php echo $street ?><br/>
|
37 |
+
<?php endforeach; ?>
|
38 |
+
<?php echo $billingAddress->getCity() ?>, <?php echo $billingAddress->getRegion() ?> <?php echo $billingAddress->getPostcode() ?><br/>
|
39 |
+
</address>
|
40 |
+
|
41 |
+
<input type="text" id="billing_address_id" name="billing_address_id" value="<?php echo $billingAddress->getId() ?>" class="input-text" style="display:none;" />
|
42 |
+
|
43 |
+
<div class="change">
|
44 |
+
<div class="block-title">
|
45 |
+
<h2>Change Billing Address</h2>
|
46 |
+
</div>
|
47 |
+
<div class="block-content">
|
48 |
+
<?php echo $this->getChildHtml("billing_address_select") ?>
|
49 |
+
</div>
|
50 |
+
</div>
|
51 |
+
</div>
|
app/design/frontend/base/default/template/autoship/newsubscription/delivery_date.phtml
ADDED
@@ -0,0 +1,43 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
$subscription = $this->getSubscription();
|
20 |
+
?>
|
21 |
+
|
22 |
+
<div class="box-padding">
|
23 |
+
<div class="field">
|
24 |
+
<label for="delivery_date"><?php echo $this->__('Your first delivery will be shipped on:') ?></label>
|
25 |
+
<div class="input-box">
|
26 |
+
<input type="text" id="delivery_date" name="delivery_date" value="<?php echo $subscription->getNextOrderDateText() ?>" title="<?php echo $this->__('Your first delivery will be shipped on:') ?>" class="input-text" />
|
27 |
+
</div>
|
28 |
+
</div>
|
29 |
+
</div>
|
30 |
+
<script type="text/javascript">
|
31 |
+
//<![CDATA[
|
32 |
+
$j(function(){
|
33 |
+
$j("#delivery_date").datepicker({
|
34 |
+
minDate: 2,
|
35 |
+
showOn: "button",
|
36 |
+
buttonImage: "<?php echo $this->getSkinUrl('images/autoship/calendar_icon.png')?>",
|
37 |
+
buttonImageOnly: true,
|
38 |
+
buttonText: "Click to change date.",
|
39 |
+
dateFormat: "mm/dd/y"
|
40 |
+
});
|
41 |
+
});
|
42 |
+
//]]>
|
43 |
+
</script>
|
app/design/frontend/base/default/template/autoship/newsubscription/delivery_frequency.phtml
ADDED
@@ -0,0 +1,44 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
$subscription = $this->getSubscription();
|
20 |
+
$qty = $subscription->getQty();
|
21 |
+
$intervals = $this->getIntervals();
|
22 |
+
$platformProduct = $this->getPlatformProduct();
|
23 |
+
?>
|
24 |
+
|
25 |
+
<div class="block-title">
|
26 |
+
<h2>Delivery Frequency</h2>
|
27 |
+
</div>
|
28 |
+
|
29 |
+
<div class="box-padding">
|
30 |
+
<p>
|
31 |
+
<input type="hidden" id="frequency_form" value="<?php echo Mage::getUrl('autoship/newsubscription/update') ?>" />
|
32 |
+
<select id="delivery_qty" name="delivery_qty" class="" title="Quantity">
|
33 |
+
<?php for($i=$platformProduct->getMinQty(); $i<=$platformProduct->getMaxQty(); $i++): ?>
|
34 |
+
<option value="<?php echo $i ?>" <?php if($qty == $i): ?>selected="selected"<?php endif; ?>><?php echo $i ?></option>
|
35 |
+
<?php endfor; ?>
|
36 |
+
</select>
|
37 |
+
unit(s) every
|
38 |
+
<select id="delivery_interval" name="delivery_interval" class="" title="Delivery Interval">
|
39 |
+
<?php foreach($intervals as $interval): ?>
|
40 |
+
<option value="<?php echo $interval ?>" <?php if($interval == $subscription->getInterval()): ?>selected="selected"<?php endif; ?>><?php echo $interval ?></option>
|
41 |
+
<?php endforeach; ?>
|
42 |
+
</select>
|
43 |
+
</p>
|
44 |
+
</div>
|
app/design/frontend/base/default/template/autoship/newsubscription/payment.phtml
ADDED
@@ -0,0 +1,77 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$subscription = $this->getSubscription();
|
21 |
+
$paymentProfile = $subscription->getPaymentProfile();
|
22 |
+
?>
|
23 |
+
|
24 |
+
<div class="block-title">
|
25 |
+
<h2>Payment Method</h2>
|
26 |
+
</div>
|
27 |
+
|
28 |
+
<div class="box-padding">
|
29 |
+
<?php if($paymentProfile->getCustomerCardnumber()): ?>
|
30 |
+
<p>Credit card ending in <?php echo $paymentProfile->getCustomerCardnumber() ?>. <a class="change" href="">(Change)</a></p>
|
31 |
+
<?php else: ?>
|
32 |
+
<p>Haven't saved a credit card yet? <a class="change" href="">Add one now</a>.</p>
|
33 |
+
<?php endif; ?>
|
34 |
+
|
35 |
+
<?php if ($this->useCouponCode()): ?>
|
36 |
+
<br/>
|
37 |
+
|
38 |
+
<div class="field">
|
39 |
+
<label for="coupon_code"><?php echo $this->__('Enter coupon code:') ?></label>
|
40 |
+
<div class="input-box">
|
41 |
+
<input type="text" id="coupon_code" name="coupon_code" value="<?php echo $subscription->getCouponCode() ?>"
|
42 |
+
class="input-text"/>
|
43 |
+
</div>
|
44 |
+
</div>
|
45 |
+
<?php endif; ?>
|
46 |
+
|
47 |
+
<input type="text" id="cim_payment_profile_id" name="cim_payment_profile_id" value="<?php echo $paymentProfile->getId() ?>" class="input-text" style="display:none;" />
|
48 |
+
|
49 |
+
<div class="change" style="display:none;">
|
50 |
+
<div class="block-title">
|
51 |
+
<h2>Change Payment Method</h2>
|
52 |
+
</div>
|
53 |
+
<div class="block-content">
|
54 |
+
<?php echo $this->getChildHtml("payment") ?>
|
55 |
+
</div>
|
56 |
+
</div>
|
57 |
+
|
58 |
+
</div>
|
59 |
+
<script type="text/javascript">
|
60 |
+
//<![CDATA[
|
61 |
+
$j(function(){
|
62 |
+
if($j('input[name="payment[method]"]').size() == 1){
|
63 |
+
$j('input[name="payment[method]"]').parent('dt').hide();
|
64 |
+
$j('input[name="payment[method]"]').click();
|
65 |
+
}
|
66 |
+
$j('input[name="payment[method]"]').on('change', function(){
|
67 |
+
hideCcForm();
|
68 |
+
});
|
69 |
+
hideCcForm();
|
70 |
+
});
|
71 |
+
function hideCcForm(){
|
72 |
+
if($j("#p_method_authnettoken").is("input")){
|
73 |
+
$j(".new-cc-form-list").toggle($j("#p_method_authnettoken").is(":checked"));
|
74 |
+
}
|
75 |
+
}
|
76 |
+
//]]>
|
77 |
+
</script>
|
app/design/frontend/base/default/template/autoship/newsubscription/product_info.phtml
ADDED
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
// Get product and profile
|
20 |
+
$product = $this->getProduct();
|
21 |
+
$platformProduct = $this->getPlatformProduct();
|
22 |
+
?>
|
23 |
+
|
24 |
+
<div class="top-image">
|
25 |
+
<?php // Product Image ?>
|
26 |
+
<a href="<?php echo $product->getProductUrl() ?>" title="<?php echo $this->stripTags($this->getImageLabel($product, 'small_image'), null, true) ?>" class="product-image"><img src="<?php echo $this->helper('catalog/image')->init($product, 'small_image')->resize(80); ?>" width="80" height="80" alt="<?php echo $this->stripTags($this->getImageLabel($product, 'small_image'), null, true) ?>" /></a>
|
27 |
+
</div>
|
28 |
+
<div class="top-name">
|
29 |
+
<?php // Product Name ?>
|
30 |
+
<?php $_productNameStripped = $this->stripTags($product->getName(), null, true); ?>
|
31 |
+
<h2 class="product-name"><a href="<?php echo $product->getProductUrl() ?>" title="<?php echo $_productNameStripped; ?>"><?php echo $product->getName() ?></a></h2>
|
32 |
+
|
33 |
+
<input type="text" id="product_id" name="product_id" value="<?php echo $product->getId() ?>" class="input-text" style="display:none;" />
|
34 |
+
<input type="text" id="product_profile_id" name="product_profile_id" value="<?php echo $platformProduct->getId() ?>" class="input-text" style="display:none;" />
|
35 |
+
|
36 |
+
</div>
|
app/design/frontend/base/default/template/autoship/newsubscription/shipping_address.phtml
ADDED
@@ -0,0 +1,51 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
$subscription = $this->getSubscription();
|
20 |
+
$shippingAddress = $subscription->getShippingAddress();
|
21 |
+
?>
|
22 |
+
|
23 |
+
<div class="block-title">
|
24 |
+
<h2>Shipping Address</h2>
|
25 |
+
</div>
|
26 |
+
|
27 |
+
<div class="box-padding">
|
28 |
+
<p>Please select the address where your orders should be delivered: <a class="change" href="">(Change)</a></p>
|
29 |
+
|
30 |
+
<address>
|
31 |
+
<?php echo $shippingAddress->getFirstname() ?> <?php echo $shippingAddress->getLastname() ?><br/>
|
32 |
+
<?php if(strlen($shippingAddress->getCompany())): ?>
|
33 |
+
<?php echo $shippingAddress->getCompany() ?><br/>
|
34 |
+
<?php endif; ?>
|
35 |
+
<?php foreach($shippingAddress->getStreet() as $street): ?>
|
36 |
+
<?php echo $street ?><br/>
|
37 |
+
<?php endforeach; ?>
|
38 |
+
<?php echo $shippingAddress->getCity() ?>, <?php echo $shippingAddress->getRegion() ?> <?php echo $shippingAddress->getPostcode() ?><br/>
|
39 |
+
</address>
|
40 |
+
|
41 |
+
<input type="text" id="shipping_address_id" name="shipping_address_id" value="<?php echo $shippingAddress->getId() ?>" class="input-text" style="display:none;" />
|
42 |
+
|
43 |
+
<div class="change">
|
44 |
+
<div class="block-title">
|
45 |
+
<h2>Change Shipping Address</h2>
|
46 |
+
</div>
|
47 |
+
<div class="block-content">
|
48 |
+
<?php echo $this->getChildHtml("shipping_address_select") ?>
|
49 |
+
</div>
|
50 |
+
</div>
|
51 |
+
</div>
|
app/design/frontend/base/default/template/autoship/newsubscription/summary.phtml
ADDED
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php
|
19 |
+
$subscription = $this->getSubscription();
|
20 |
+
$summary = $this->getSummary();
|
21 |
+
$coreHelper = $this->helper('core');
|
22 |
+
?>
|
23 |
+
|
24 |
+
<div class="block-title">
|
25 |
+
<h2>Estimated Order Summary</h2>
|
26 |
+
</div>
|
27 |
+
<ul class="messages"></ul>
|
28 |
+
<div class="box-padding">
|
29 |
+
<?php // If $summary is an array, it has totals, otherwise it's a string with error message ?>
|
30 |
+
<?php if (is_array($summary)): ?>
|
31 |
+
<p>The following are the estimated costs for each of your shipments:</p>
|
32 |
+
<div class="subscription-summary-table">
|
33 |
+
<table>
|
34 |
+
<tbody>
|
35 |
+
<tr>
|
36 |
+
<td class="a-right">Product Total</td>
|
37 |
+
<td class="a-right"><?php echo $coreHelper->currency($summary['product_total'], true, false); ?></td>
|
38 |
+
</tr>
|
39 |
+
<tr>
|
40 |
+
<td class="a-right">Subscription Discount</td>
|
41 |
+
<td class="a-right"><?php echo $coreHelper->currency($summary['discount'], true, false); ?></td>
|
42 |
+
</tr>
|
43 |
+
<tr>
|
44 |
+
<td class="a-right">Shipping</td>
|
45 |
+
<td class="a-right"><?php echo $coreHelper->currency($summary['shipping'], true, false); ?></td>
|
46 |
+
</tr>
|
47 |
+
<tr>
|
48 |
+
<td class="a-right">Tax</td>
|
49 |
+
<td class="a-right"><?php echo $coreHelper->currency($summary['tax'], true, false); ?></td>
|
50 |
+
</tr>
|
51 |
+
</tbody>
|
52 |
+
<tfoot>
|
53 |
+
<tr>
|
54 |
+
<td class="a-right"><strong>Estimated Order Total</strong></td>
|
55 |
+
<td class="a-right"><strong><span class="price"><?php echo $coreHelper->currency($summary['total'], true, false); ?></span></strong></td>
|
56 |
+
</tr>
|
57 |
+
</tfoot>
|
58 |
+
</table>
|
59 |
+
</div><!-- subscription-summary-table -->
|
60 |
+
<div style="clear:both;"></div>
|
61 |
+
<?php // If $summary is an array, it has totals, otherwise it's a string with error message ?>
|
62 |
+
<?php else: ?>
|
63 |
+
<p><?php echo $summary ?></p>
|
64 |
+
<?php endif; ?>
|
65 |
+
</div><!-- end box-padding -->
|
66 |
+
<div class="subscribe-button-block">
|
67 |
+
<?php $buttonTitle = $this->__('Subscribe Now'); ?>
|
68 |
+
<button type="button" title="<?php echo $buttonTitle ?>" class="button btn-cart" id="subscribe" href="<?php echo $this->getPostActionUrl() ?>"><span><span><?php echo $buttonTitle ?></span></span></button>
|
69 |
+
</div><!-- end subscribe-button-block -->
|
app/design/frontend/base/default/template/autoship/payment/form/cc.phtml
ADDED
@@ -0,0 +1,95 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $_code = $this->getMethodCode() ?>
|
19 |
+
<?php $_billingAddress = $this->getBillingAddress() ?>
|
20 |
+
<ul class="form-list" id="payment_form_<?php echo $_code ?>" style="display:none;">
|
21 |
+
<input type="hidden" id="<?php echo $_code ?>_payment_token" name="payment[payment_token]" title="<?php echo $this->__('Payment Token') ?>" value="<?php echo $this->getAdditionalInfo('payment_token') ?>" />
|
22 |
+
<input type="hidden" id="<?php echo $_code ?>_is_new_card" name="payment[is_new_card]" title="<?php echo $this->__('Is New Card') ?>" value="1" />
|
23 |
+
<input type="hidden" id="<?php echo $_code ?>_firstname" name="payment[firstname]" title="<?php echo $this->__('firstname') ?>" value="<?php echo $_billingAddress->getData('firstname') ?>" />
|
24 |
+
<input type="hidden" id="<?php echo $_code ?>_lastname" name="payment[lastname]" title="<?php echo $this->__('lastname') ?>" value="<?php echo $_billingAddress->getData('lastname') ?>" />
|
25 |
+
<?php if($this->forceSaveCard()): ?>
|
26 |
+
<input type="hidden" id="<?php echo $_code ?>_save_card" name="payment[save_card]" title="<?php echo $this->__('Save Card') ?>" value="1" />
|
27 |
+
<?php endif; ?>
|
28 |
+
<li>
|
29 |
+
<label for="<?php echo $_code ?>_cc_type" class="required"><em>*</em><?php echo $this->__('Credit Card Type') ?></label>
|
30 |
+
<div class="input-box">
|
31 |
+
<select id="<?php echo $_code ?>_cc_type" name="payment[cc_type]" class="required-entry validate-cc-type-select">
|
32 |
+
<option value=""><?php echo $this->__('--Please Select--')?></option>
|
33 |
+
<?php $_ccType = $this->getInfoData('cc_type') ?>
|
34 |
+
<?php foreach ($this->getCcAvailableTypes() as $_typeCode => $_typeName): ?>
|
35 |
+
<option value="<?php echo $_typeCode ?>"<?php if($_typeCode==$_ccType): ?> selected="selected"<?php endif ?>><?php echo $_typeName ?></option>
|
36 |
+
<?php endforeach ?>
|
37 |
+
</select>
|
38 |
+
</div>
|
39 |
+
</li>
|
40 |
+
<li>
|
41 |
+
<label for="<?php echo $_code ?>_cc_number" class="required"><em>*</em><?php echo $this->__('Credit Card Number') ?></label>
|
42 |
+
<div class="input-box">
|
43 |
+
<input type="text" id="<?php echo $_code ?>_cc_number" name="payment[cc_number]" title="<?php echo $this->__('Credit Card Number') ?>" class="input-text validate-cc-number validate-cc-type" value="<?php echo $this->getAdditionalInfo('obscured_cc_number') ?>" />
|
44 |
+
</div>
|
45 |
+
</li>
|
46 |
+
<li id="<?php echo $_code ?>_cc_type_exp_div">
|
47 |
+
<label for="<?php echo $_code ?>_expiration" class="required"><em>*</em><?php echo $this->__('Expiration Date') ?></label>
|
48 |
+
<div class="input-box">
|
49 |
+
<div class="v-fix">
|
50 |
+
<select id="<?php echo $_code ?>_expiration" name="payment[cc_exp_month]" class="month validate-cc-exp required-entry">
|
51 |
+
<?php $_ccExpMonth = $this->getInfoData('cc_exp_month') ?>
|
52 |
+
<?php foreach ($this->getCcMonths() as $k=>$v): ?>
|
53 |
+
<option value="<?php echo $k?$k:'' ?>"<?php if($k==$_ccExpMonth): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
54 |
+
<?php endforeach ?>
|
55 |
+
</select>
|
56 |
+
</div>
|
57 |
+
<div class="v-fix">
|
58 |
+
<?php $_ccExpYear = $this->getInfoData('cc_exp_year') ?>
|
59 |
+
<select id="<?php echo $_code ?>_expiration_yr" name="payment[cc_exp_year]" class="year required-entry">
|
60 |
+
<?php foreach ($this->getCcYears() as $k=>$v): ?>
|
61 |
+
<option value="<?php echo $k?$k:'' ?>"<?php if($k==$_ccExpYear): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
62 |
+
<?php endforeach ?>
|
63 |
+
</select>
|
64 |
+
</div>
|
65 |
+
</div>
|
66 |
+
</li>
|
67 |
+
<?php echo $this->getChildHtml() ?>
|
68 |
+
<?php if($this->hasVerification()): ?>
|
69 |
+
<li id="<?php echo $_code ?>_cc_type_cvv_div">
|
70 |
+
<label for="<?php echo $_code ?>_cc_cid" class="required"><em>*</em><?php echo $this->__('Card Verification Number') ?></label>
|
71 |
+
<div class="input-box">
|
72 |
+
<div class="v-fix">
|
73 |
+
<input type="text" title="<?php echo $this->__('Card Verification Number') ?>"
|
74 |
+
class="input-text cvv required-entry validate-cc-cvn"
|
75 |
+
id="<?php echo $_code ?>_cc_cid"
|
76 |
+
name="payment[cc_cid]" value="<?php if(strlen($this->getAdditionalInfo('payment_token')) > 0): ?>XXX<?php endif; ?>" />
|
77 |
+
</div>
|
78 |
+
<a href="#" class="cvv-what-is-this"><?php echo $this->__('What is this?') ?></a>
|
79 |
+
</div>
|
80 |
+
</li>
|
81 |
+
<?php endif; ?>
|
82 |
+
<?php if($this->useSaveCardCheckbox()): ?>
|
83 |
+
<li id="<?php echo $_code ?>_cc_save_card_div">
|
84 |
+
<label for="<?php echo $_code ?>_save_card" class="required"><em>*</em><?php echo $this->__('Save My Card') ?></label>
|
85 |
+
<div class="input-box">
|
86 |
+
<div class="v-fix">
|
87 |
+
<input type='hidden' value='0' name='payment[save_card]'/>
|
88 |
+
<input type="checkbox" title="<?php echo $this->__('Save Card') ?>" class="checkbox"
|
89 |
+
id="<?php echo $_code ?>_save_card" name="payment[save_card]"
|
90 |
+
value="1" <?php if($this->getAdditionalInfo('save_card')): ?>checked<?php endif; ?> />
|
91 |
+
</div>
|
92 |
+
</div>
|
93 |
+
</li>
|
94 |
+
<?php endif; ?>
|
95 |
+
</ul>
|
app/design/frontend/base/default/template/autoship/payment/form/cc_saved.phtml
ADDED
@@ -0,0 +1,68 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $_code = $this->getMethodCode() ?>
|
19 |
+
<?php $_paymentProfile = $this->getMethod()->getSavedPaymentProfile() ?>
|
20 |
+
<?php echo $this->getChildHtml() ?>
|
21 |
+
<ul class="form-list" id="payment_form_<?php echo $_code ?>" style="display:none;">
|
22 |
+
<input type="hidden" id="<?php echo $_code ?>_payment_token" name="payment[payment_token]"
|
23 |
+
title="<?php echo $this->__('Payment Token') ?>" value="<?php echo $_paymentProfile->getData('payment_token') ?>"/>
|
24 |
+
<input type="hidden" id="<?php echo $_code ?>_is_new_card" name="payment[is_new_card]"
|
25 |
+
title="<?php echo $this->__('Is New Card') ?>" value="0"/>
|
26 |
+
<input type="hidden" id="<?php echo $_code ?>_cc_number" name="payment[cc_number]"
|
27 |
+
title="<?php echo $this->__('Obscured Card Number') ?>" value="<?php echo $this->getObscuredCardNumber() ?>"/>
|
28 |
+
<input type="hidden" id="<?php echo $_code ?>_cc_type" name="payment[cc_type]" title="<?php echo $this->__('Card Type') ?>"
|
29 |
+
value="<?php echo $this->getMagentoCardType() ?>"/>
|
30 |
+
<li id="<?php echo $_code ?>_cc_type_exp_div">
|
31 |
+
<label for="<?php echo $_code ?>_expiration" class="required"><em>*</em><?php echo $this->__('Expiration Date') ?></label>
|
32 |
+
|
33 |
+
<div class="input-box">
|
34 |
+
<div class="v-fix">
|
35 |
+
<select id="<?php echo $_code ?>_expiration" name="payment[cc_exp_month]" class="month validate-cc-exp required-entry">
|
36 |
+
<?php $_ccExpMonth = $_paymentProfile->getData('creditcard_month') ?>
|
37 |
+
<?php foreach ($this->getCcMonths() as $k => $v): ?>
|
38 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if ($k == $_ccExpMonth
|
39 |
+
): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
40 |
+
<?php endforeach ?>
|
41 |
+
</select>
|
42 |
+
</div>
|
43 |
+
<div class="v-fix">
|
44 |
+
<?php $_ccExpYear = $_paymentProfile->getData('creditcard_year') ?>
|
45 |
+
<select id="<?php echo $_code ?>_expiration_yr" name="payment[cc_exp_year]" class="year required-entry">
|
46 |
+
<?php foreach ($this->getCcYears() as $k => $v): ?>
|
47 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if ($k == $_ccExpYear
|
48 |
+
): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
49 |
+
<?php endforeach ?>
|
50 |
+
</select>
|
51 |
+
</div>
|
52 |
+
</div>
|
53 |
+
</li>
|
54 |
+
<?php if ($this->hasVerification()): ?>
|
55 |
+
<li id="<?php echo $_code ?>_cc_type_cvv_div">
|
56 |
+
<label for="<?php echo $_code ?>_cc_cid" class="required"><em>*</em><?php echo $this->__('Card Verification Number') ?>
|
57 |
+
</label>
|
58 |
+
|
59 |
+
<div class="input-box">
|
60 |
+
<div class="v-fix">
|
61 |
+
<input type="text" title="<?php echo $this->__('Card Verification Number') ?>" class="input-text cvv required-entry"
|
62 |
+
id="<?php echo $_code ?>_cc_cid" name="payment[cc_cid]" value=""/>
|
63 |
+
</div>
|
64 |
+
<a href="#" class="cvv-what-is-this"><?php echo $this->__('What is this?') ?></a>
|
65 |
+
</div>
|
66 |
+
</li>
|
67 |
+
<?php endif; ?>
|
68 |
+
</ul>
|
app/design/frontend/base/default/template/autoship/payment/profile/edit.phtml
ADDED
@@ -0,0 +1,207 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $paymentProfile = $this->getCimProfile(); ?>
|
19 |
+
<?php $billingAddress = $paymentProfile['billing_address']; ?>
|
20 |
+
<?php $countries = Mage::getResourceModel('directory/country_collection')->loadByStore()->toOptionArray(); ?>
|
21 |
+
|
22 |
+
<div class="page-title">
|
23 |
+
<h1><?php echo $this->getTitle(); ?></h1>
|
24 |
+
</div>
|
25 |
+
|
26 |
+
<form id="edit_form" accept-charset="UTF-8" action="<?php echo $this->getSaveUrl() ?>" method="POST">
|
27 |
+
<input name="payment_profile_id" type="hidden" value="<?php echo $paymentProfile->getId() ?>" />
|
28 |
+
|
29 |
+
<div class="fieldset">
|
30 |
+
<h2 class="legend">Cardholder Information</h2>
|
31 |
+
<ul class="form-list">
|
32 |
+
<li class="fields">
|
33 |
+
<div class="field name-firstname">
|
34 |
+
<label for="bill_to_forename" class="required"><em>*</em>First Name</label>
|
35 |
+
|
36 |
+
<div class="input-box">
|
37 |
+
<input type="text" id="bill_to_forename" name="billing_address[first_name]"
|
38 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('first_name')) ?>" title="First Name"
|
39 |
+
maxlength="255" class="input-text required-entry"/>
|
40 |
+
</div>
|
41 |
+
</div>
|
42 |
+
<div class="field name-lastname">
|
43 |
+
<label for="bill_to_surname" class="required"><em>*</em>Last Name</label>
|
44 |
+
|
45 |
+
<div class="input-box">
|
46 |
+
<input type="text" id="bill_to_surname" name="billing_address[last_name]"
|
47 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('last_name')) ?>" title="Last Name"
|
48 |
+
maxlength="255" class="input-text required-entry"/>
|
49 |
+
</div>
|
50 |
+
</div>
|
51 |
+
</li>
|
52 |
+
</ul>
|
53 |
+
</div>
|
54 |
+
|
55 |
+
<div class="fieldset">
|
56 |
+
<h2 class="legend">Billing Address</h2>
|
57 |
+
<ul class="form-list">
|
58 |
+
<li class="wide">
|
59 |
+
<div class="address">
|
60 |
+
<label for="bill_to_address_line1" class="required">Street Address</label>
|
61 |
+
|
62 |
+
<div class="input-box">
|
63 |
+
<input type="text" id="bill_to_address_line1" name="billing_address[street1]"
|
64 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('street1')) ?>" title="Address" maxlength="255"
|
65 |
+
class="input-text"/>
|
66 |
+
</div>
|
67 |
+
</div>
|
68 |
+
</li>
|
69 |
+
<li class="wide">
|
70 |
+
<div class="address">
|
71 |
+
<label for="bill_to_address_line2" class="required"></label>
|
72 |
+
|
73 |
+
<div class="input-box">
|
74 |
+
<input type="text" id="bill_to_address_line2" name="billing_address[street2]"
|
75 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('street2')) ?>" title="Address" maxlength="255"
|
76 |
+
class="input-text"/>
|
77 |
+
</div>
|
78 |
+
</div>
|
79 |
+
</li>
|
80 |
+
<li class="fields">
|
81 |
+
<div class="field name-firstname">
|
82 |
+
<label for="bill_to_address_city" class="required">City</label>
|
83 |
+
|
84 |
+
<div class="input-box">
|
85 |
+
<input type="text" id="bill_to_address_city" name="billing_address[city]" value="<?php echo $this->escapeHtml($billingAddress->getData('city')) ?>"
|
86 |
+
title="City" maxlength="255" class="input-text"/>
|
87 |
+
</div>
|
88 |
+
</div>
|
89 |
+
<div class="field name-lastname">
|
90 |
+
<label for="bill_to_address_state" class="required">State/Province</label>
|
91 |
+
|
92 |
+
<div class="input-box">
|
93 |
+
<input type="text" id="bill_to_address_state" name="billing_address[region]"
|
94 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('region')) ?>" title="State" maxlength="255"
|
95 |
+
class="input-text"/>
|
96 |
+
</div>
|
97 |
+
</div>
|
98 |
+
</li>
|
99 |
+
<li class="fields">
|
100 |
+
<div class="field name-firstname">
|
101 |
+
<label for="bill_to_address_postal_code" class="required">Zip/Postal Code</label>
|
102 |
+
|
103 |
+
<div class="input-box">
|
104 |
+
<input type="text" id="bill_to_address_postal_code" name="billing_address[postcode]"
|
105 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('postcode')) ?>" title="Zip" maxlength="255"
|
106 |
+
class="input-text"/>
|
107 |
+
</div>
|
108 |
+
</div>
|
109 |
+
</li>
|
110 |
+
<li class="wide">
|
111 |
+
<div class="country">
|
112 |
+
<label for="bill_to_address_country" class="required">Country</label>
|
113 |
+
|
114 |
+
<div class="input-box">
|
115 |
+
<select id="bill_to_address_country" name="billing_address[country]" title="Country" class="input-text">
|
116 |
+
<?php foreach ($countries as $country) : ?>
|
117 |
+
<option value="<?php echo $country['value']; ?>" <?php if ($country['value'] ==
|
118 |
+
$billingAddress->getData('country')
|
119 |
+
) {
|
120 |
+
echo 'selected="selected"';
|
121 |
+
} ?>><?php echo $country['label']; ?></option>
|
122 |
+
<?php endforeach; ?>
|
123 |
+
</select>
|
124 |
+
</div>
|
125 |
+
</div>
|
126 |
+
</li>
|
127 |
+
<li class="fields">
|
128 |
+
<div class="field name-firstname">
|
129 |
+
<label for="bill_to_phone" class="required">Telephone</label>
|
130 |
+
|
131 |
+
<div class="input-box">
|
132 |
+
<input type="text" id="bill_to_phone" name="billing_address[phone]"
|
133 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('phone')) ?>" title="Phone" maxlength="255"
|
134 |
+
class="input-text"/>
|
135 |
+
</div>
|
136 |
+
</div>
|
137 |
+
</li>
|
138 |
+
</ul>
|
139 |
+
</div>
|
140 |
+
|
141 |
+
<div class="fieldset">
|
142 |
+
<h2 class="legend">Payment Information</h2>
|
143 |
+
<ul class="form-list">
|
144 |
+
<li>
|
145 |
+
<label for="card_type" class="required"><em>*</em><?php echo $this->__('Credit Card Type') ?></label>
|
146 |
+
<div class="input-box">
|
147 |
+
<select id="card_type" name="card_type" disabled="disabled" style="background-color: rgb(235, 235, 228);">
|
148 |
+
<option value=""><?php echo $this->__('--Please Select--') ?></option>
|
149 |
+
<?php $_ccType = $paymentProfile->getData('creditcard_type'); ?>
|
150 |
+
<?php foreach ($this->getCcAvailableTypesSubscribeProFormat() as $_typeCode => $_typeName): ?>
|
151 |
+
<option value="<?php echo $_typeCode ?>"<?php if ($_typeCode == $_ccType
|
152 |
+
): ?> selected="selected"<?php endif ?>><?php echo $_typeName ?></option>
|
153 |
+
<?php endforeach ?>
|
154 |
+
</select>
|
155 |
+
</div>
|
156 |
+
</li>
|
157 |
+
<li class="wide">
|
158 |
+
<div class="">
|
159 |
+
<label for="card_number" class="required"><em>*</em>Card Number</label>
|
160 |
+
|
161 |
+
<div class="input-box">
|
162 |
+
<input type="text" id="card_number" name="credit_card[number]" disabled="disabled"
|
163 |
+
value="<?php echo $this->escapeHtml('XXXX' . $paymentProfile->getData('creditcard_last_digits')) ?>"
|
164 |
+
class="input-text" style="background-color: rgb(235, 235, 228);"/>
|
165 |
+
</div>
|
166 |
+
</div>
|
167 |
+
</li>
|
168 |
+
<li class="fields">
|
169 |
+
<div class="field name-firstname">
|
170 |
+
<label for="cc_exp_month" class="required"><em>*</em><?php echo $this->__('Expiration Month') ?></label>
|
171 |
+
|
172 |
+
<div class="input-box">
|
173 |
+
<select id="cc_exp_month" name="creditcard_month" class="validate-month required-entry">
|
174 |
+
<?php $_ccExpMonth = $paymentProfile->getData('creditcard_month') ?>
|
175 |
+
<?php foreach ($this->getCcMonths() as $k => $v): ?>
|
176 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if ($k == $_ccExpMonth
|
177 |
+
): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
178 |
+
<?php endforeach ?>
|
179 |
+
</select>
|
180 |
+
</div>
|
181 |
+
</div>
|
182 |
+
<div class="field name-lastname">
|
183 |
+
<label for="cc_exp_year" class="required"><em>*</em><?php echo $this->__('Expiration Year') ?></label>
|
184 |
+
|
185 |
+
<div class="input-box">
|
186 |
+
<?php $_ccExpYear = $paymentProfile->getData('creditcard_year') ?>
|
187 |
+
<select id="cc_exp_year" name="creditcard_year" class="year required-entry validate-year">
|
188 |
+
<?php foreach ($this->getCcYears() as $k => $v): ?>
|
189 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if ($k == $_ccExpYear
|
190 |
+
): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
191 |
+
<?php endforeach ?>
|
192 |
+
</select>
|
193 |
+
</div>
|
194 |
+
</div>
|
195 |
+
</li>
|
196 |
+
</ul>
|
197 |
+
</div>
|
198 |
+
|
199 |
+
<div class="buttons-set form-buttons">
|
200 |
+
<p class="back-link"><a href="<?php echo $this->getBackUrl() ?>">
|
201 |
+
<small>«</small>
|
202 |
+
Back</a></p>
|
203 |
+
<button type="submit" class="button" title="Save">
|
204 |
+
<span><span>Save Credit Card</span></span>
|
205 |
+
</button>
|
206 |
+
</div>
|
207 |
+
</form>
|
app/design/frontend/base/default/template/autoship/payment/profile/grid.phtml
ADDED
@@ -0,0 +1,89 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $paymentProfiles = $this->getPaymentProfiles() ?>
|
19 |
+
<div class="page-title">
|
20 |
+
<h1>My Credit Cards</h1>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<fieldset>
|
24 |
+
<div class="pager">
|
25 |
+
<p class="amount">
|
26 |
+
<?php echo count($paymentProfiles); ?> Item(s)
|
27 |
+
</p>
|
28 |
+
</div>
|
29 |
+
<table class="data-table" id="cc-table">
|
30 |
+
<thead>
|
31 |
+
<tr class="first last">
|
32 |
+
<th>Card Number</th>
|
33 |
+
<th>Billing Customer Name</th>
|
34 |
+
<th>Edit / Delete</th>
|
35 |
+
</tr>
|
36 |
+
</thead>
|
37 |
+
<tbody>
|
38 |
+
<?php $i= 0; ?>
|
39 |
+
<?php foreach($paymentProfiles as $profile) : ?>
|
40 |
+
<?php $billingAddress = $profile->getData('billing_address'); ?>
|
41 |
+
<?php if($i % 2 == 0) { $row = 'even'; } else { $row='odd'; } ?>
|
42 |
+
<tr class="<?php echo $row; ?>">
|
43 |
+
<td>
|
44 |
+
<?php $card = 'XXXX' . $profile->getData('creditcard_last_digits') ?>
|
45 |
+
<?php echo $card ?>
|
46 |
+
</td>
|
47 |
+
<td>
|
48 |
+
<?php echo $billingAddress->getData('first_name') . ' ' . $billingAddress->getData('last_name'); ?>
|
49 |
+
</td>
|
50 |
+
<td>
|
51 |
+
<span><a href="<?php echo Mage::getUrl('subscriptions/mycreditcards/edit'); ?>id/<?php echo $profile->getId() ?>"><b>Edit</b></a></span> |
|
52 |
+
<span><a href="#" class="link-reorder" onclick="confirmDelete(<?php echo $profile->getId() ?>)"> Delete</a></span>
|
53 |
+
</td>
|
54 |
+
</tr>
|
55 |
+
<?php $i++; ?>
|
56 |
+
<?php endforeach; ?>
|
57 |
+
</tbody>
|
58 |
+
</table>
|
59 |
+
<div class="pager">
|
60 |
+
<p class="amount">
|
61 |
+
<?php echo count($paymentProfiles); ?> Item(s)
|
62 |
+
</p>
|
63 |
+
</div>
|
64 |
+
</fieldset>
|
65 |
+
|
66 |
+
<br/>
|
67 |
+
|
68 |
+
<div class="buttons-set form-buttons">
|
69 |
+
<p class="back-link"><a href="<?php echo Mage::getUrl('customer/account/'); ?>"><small>«</small> Back</a></p>
|
70 |
+
<button type="submit" class="button" title="Save" onclick="window.location.href='<?php echo Mage::getUrl('subscriptions/mycreditcards/new'); ?>customerid/<?php echo Mage::getSingleton('customer/session')->getCustomer()->getId() ?>'">
|
71 |
+
<span><span>New Credit Card</span></span>
|
72 |
+
</button>
|
73 |
+
</div>
|
74 |
+
<script type="text/javascript">
|
75 |
+
function confirmDelete(id)
|
76 |
+
{
|
77 |
+
var x;
|
78 |
+
var r=confirm("Are you sure you want to delete this credit card?");
|
79 |
+
if (r==true)
|
80 |
+
{
|
81 |
+
window.location="<?php echo Mage::getUrl('subscriptions/mycreditcards/delete'); ?>id/" + id;
|
82 |
+
}
|
83 |
+
else
|
84 |
+
{
|
85 |
+
return false;
|
86 |
+
}
|
87 |
+
}
|
88 |
+
</script>
|
89 |
+
|
app/design/frontend/base/default/template/autoship/payment/profile/new.phtml
ADDED
@@ -0,0 +1,218 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $paymentProfile = $this->getCimProfile(); ?>
|
19 |
+
<?php $billingAddress = $paymentProfile['billing_address']; ?>
|
20 |
+
<?php $countries = Mage::getResourceModel('directory/country_collection')->loadByStore()->toOptionArray(); ?>
|
21 |
+
|
22 |
+
<div class="page-title">
|
23 |
+
<h1><?php echo $this->getTitle(); ?></h1>
|
24 |
+
</div>
|
25 |
+
|
26 |
+
<form id="edit_form" accept-charset="UTF-8" action="<?php echo $this->getRedirectPostUrl() ?>" method="POST">
|
27 |
+
<input name="redirect_url" type="hidden" value="<?php echo $this->getRedirectUrl() ?>" />
|
28 |
+
<input name="environment_key" type="hidden" value="<?php echo $this->getEnvironmentKey() ?>" />
|
29 |
+
<input name="utf8" type="hidden" value="✓" />
|
30 |
+
|
31 |
+
<div class="fieldset">
|
32 |
+
<h2 class="legend">Cardholder Information</h2>
|
33 |
+
<ul class="form-list">
|
34 |
+
<li class="fields">
|
35 |
+
<div class="field name-firstname">
|
36 |
+
<label for="bill_to_forename" class="required"><em>*</em>First Name</label>
|
37 |
+
|
38 |
+
<div class="input-box">
|
39 |
+
<input type="text" id="bill_to_forename" name="credit_card[first_name]"
|
40 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('first_name')) ?>" title="First Name"
|
41 |
+
maxlength="255" class="input-text required-entry"/>
|
42 |
+
</div>
|
43 |
+
</div>
|
44 |
+
<div class="field name-lastname">
|
45 |
+
<label for="bill_to_surname" class="required"><em>*</em>Last Name</label>
|
46 |
+
|
47 |
+
<div class="input-box">
|
48 |
+
<input type="text" id="bill_to_surname" name="credit_card[last_name]"
|
49 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('last_name')) ?>" title="Last Name"
|
50 |
+
maxlength="255" class="input-text required-entry"/>
|
51 |
+
</div>
|
52 |
+
</div>
|
53 |
+
</li>
|
54 |
+
</ul>
|
55 |
+
</div>
|
56 |
+
|
57 |
+
<div class="fieldset">
|
58 |
+
<h2 class="legend">Billing Address</h2>
|
59 |
+
<ul class="form-list">
|
60 |
+
<li class="wide">
|
61 |
+
<div class="address">
|
62 |
+
<label for="bill_to_address_line1" class="required">Street Address</label>
|
63 |
+
|
64 |
+
<div class="input-box">
|
65 |
+
<input type="text" id="bill_to_address_line1" name="credit_card[address1]"
|
66 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('street1')) ?>" title="Address" maxlength="255"
|
67 |
+
class="input-text"/>
|
68 |
+
</div>
|
69 |
+
</div>
|
70 |
+
</li>
|
71 |
+
<li class="wide">
|
72 |
+
<div class="address">
|
73 |
+
<label for="bill_to_address_line2" class="required"></label>
|
74 |
+
|
75 |
+
<div class="input-box">
|
76 |
+
<input type="text" id="bill_to_address_line2" name="credit_card[address2]"
|
77 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('street2')) ?>" title="Address" maxlength="255"
|
78 |
+
class="input-text"/>
|
79 |
+
</div>
|
80 |
+
</div>
|
81 |
+
</li>
|
82 |
+
<li class="fields">
|
83 |
+
<div class="field name-firstname">
|
84 |
+
<label for="bill_to_address_city" class="required">City</label>
|
85 |
+
|
86 |
+
<div class="input-box">
|
87 |
+
<input type="text" id="bill_to_address_city" name="credit_card[city]" value="<?php echo $this->escapeHtml($billingAddress->getData('city')) ?>"
|
88 |
+
title="City" maxlength="255" class="input-text"/>
|
89 |
+
</div>
|
90 |
+
</div>
|
91 |
+
<div class="field name-lastname">
|
92 |
+
<label for="bill_to_address_state" class="required">State/Province</label>
|
93 |
+
|
94 |
+
<div class="input-box">
|
95 |
+
<input type="text" id="bill_to_address_state" name="credit_card[state]"
|
96 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('region')) ?>" title="State" maxlength="255"
|
97 |
+
class="input-text"/>
|
98 |
+
</div>
|
99 |
+
</div>
|
100 |
+
</li>
|
101 |
+
<li class="fields">
|
102 |
+
<div class="field name-firstname">
|
103 |
+
<label for="bill_to_address_postal_code" class="required">Zip/Postal Code</label>
|
104 |
+
|
105 |
+
<div class="input-box">
|
106 |
+
<input type="text" id="bill_to_address_postal_code" name="credit_card[zip]"
|
107 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('postcode')) ?>" title="Zip" maxlength="255"
|
108 |
+
class="input-text"/>
|
109 |
+
</div>
|
110 |
+
</div>
|
111 |
+
</li>
|
112 |
+
<li class="wide">
|
113 |
+
<div class="country">
|
114 |
+
<label for="bill_to_address_country" class="required">Country</label>
|
115 |
+
|
116 |
+
<div class="input-box">
|
117 |
+
<select id="bill_to_address_country" name="credit_card[country]" title="Country" class="input-text">
|
118 |
+
<?php foreach ($countries as $country) : ?>
|
119 |
+
<option value="<?php echo $country['value']; ?>" <?php if ($country['value'] ==
|
120 |
+
$billingAddress->getData('country')
|
121 |
+
) {
|
122 |
+
echo 'selected="selected"';
|
123 |
+
} ?>><?php echo $country['label']; ?></option>
|
124 |
+
<?php endforeach; ?>
|
125 |
+
</select>
|
126 |
+
</div>
|
127 |
+
</div>
|
128 |
+
</li>
|
129 |
+
<li class="fields">
|
130 |
+
<div class="field name-firstname">
|
131 |
+
<label for="bill_to_phone" class="required">Telephone</label>
|
132 |
+
|
133 |
+
<div class="input-box">
|
134 |
+
<input type="text" id="bill_to_phone" name="credit_card[phone_number]"
|
135 |
+
value="<?php echo $this->escapeHtml($billingAddress->getData('phone')) ?>" title="Phone" maxlength="255"
|
136 |
+
class="input-text"/>
|
137 |
+
</div>
|
138 |
+
</div>
|
139 |
+
</li>
|
140 |
+
</ul>
|
141 |
+
</div>
|
142 |
+
|
143 |
+
<div class="fieldset">
|
144 |
+
<h2 class="legend">Payment Information</h2>
|
145 |
+
<ul class="form-list">
|
146 |
+
<li>
|
147 |
+
<label for="card_type" class="required"><em>*</em><?php echo $this->__('Credit Card Type') ?></label>
|
148 |
+
<div class="input-box">
|
149 |
+
<select id="card_type" name="credit_card[card_type]" class="required-entry validate-cc-type-select">
|
150 |
+
<option value=""><?php echo $this->__('--Please Select--') ?></option>
|
151 |
+
<?php $_ccType = $paymentProfile->getData('creditcard_type'); ?>
|
152 |
+
<?php foreach ($this->getCcAvailableTypesSubscribeProFormat() as $_typeCode => $_typeName): ?>
|
153 |
+
<option value="<?php echo $_typeCode ?>"<?php if ($_typeCode == $_ccType
|
154 |
+
): ?> selected="selected"<?php endif ?>><?php echo $_typeName ?></option>
|
155 |
+
<?php endforeach ?>
|
156 |
+
</select>
|
157 |
+
</div>
|
158 |
+
</li>
|
159 |
+
<li class="wide">
|
160 |
+
<div class="">
|
161 |
+
<label for="card_number" class="required"><em>*</em>Card Number</label>
|
162 |
+
|
163 |
+
<div class="input-box">
|
164 |
+
<input type="text" id="card_number" name="credit_card[number]"
|
165 |
+
value="<?php echo $this->escapeHtml('XXXX' . $paymentProfile->getData('creditcard_last_digits')) ?>"
|
166 |
+
class="input-text required-entry"/>
|
167 |
+
</div>
|
168 |
+
</div>
|
169 |
+
</li>
|
170 |
+
<?php if ($this->useVerification()): ?>
|
171 |
+
<li>
|
172 |
+
<label for="card_cvn" class="required"><em>*</em><?php echo $this->__('Card Verification Number') ?></label>
|
173 |
+
|
174 |
+
<div class="input-box">
|
175 |
+
<input type="text" title="<?php echo $this->__('Card Verification Number') ?>" class="input-text cvv required-entry validate-cc-cvn" id="card_cvn" name="credit_card[verification_value]" value="" />
|
176 |
+
</div>
|
177 |
+
</li>
|
178 |
+
<?php endif; ?>
|
179 |
+
<li class="fields">
|
180 |
+
<div class="field name-firstname">
|
181 |
+
<label for="cc_exp_month" class="required"><em>*</em><?php echo $this->__('Expiration Month') ?></label>
|
182 |
+
|
183 |
+
<div class="input-box">
|
184 |
+
<select id="cc_exp_month" name="credit_card[month]" class="validate-month required-entry">
|
185 |
+
<?php $_ccExpMonth = $paymentProfile->getData('creditcard_month') ?>
|
186 |
+
<?php foreach ($this->getCcMonths() as $k => $v): ?>
|
187 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if ($k == $_ccExpMonth
|
188 |
+
): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
189 |
+
<?php endforeach ?>
|
190 |
+
</select>
|
191 |
+
</div>
|
192 |
+
</div>
|
193 |
+
<div class="field name-lastname">
|
194 |
+
<label for="cc_exp_year" class="required"><em>*</em><?php echo $this->__('Expiration Year') ?></label>
|
195 |
+
|
196 |
+
<div class="input-box">
|
197 |
+
<?php $_ccExpYear = $paymentProfile->getData('creditcard_year') ?>
|
198 |
+
<select id="cc_exp_year" name="credit_card[year]" class="year required-entry validate-year">
|
199 |
+
<?php foreach ($this->getCcYears() as $k => $v): ?>
|
200 |
+
<option value="<?php echo $k ? $k : '' ?>"<?php if ($k == $_ccExpYear
|
201 |
+
): ?> selected="selected"<?php endif ?>><?php echo $v ?></option>
|
202 |
+
<?php endforeach ?>
|
203 |
+
</select>
|
204 |
+
</div>
|
205 |
+
</div>
|
206 |
+
</li>
|
207 |
+
</ul>
|
208 |
+
</div>
|
209 |
+
|
210 |
+
<div class="buttons-set form-buttons">
|
211 |
+
<p class="back-link"><a href="<?php echo $this->getBackUrl() ?>">
|
212 |
+
<small>«</small>
|
213 |
+
Back</a></p>
|
214 |
+
<button type="submit" class="button" title="Save">
|
215 |
+
<span><span>Save Credit Card</span></span>
|
216 |
+
</button>
|
217 |
+
</div>
|
218 |
+
</form>
|
app/design/frontend/base/default/template/autoship/product/subscribe.phtml
ADDED
@@ -0,0 +1,80 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php if(Mage::getStoreConfig('autoship_general/general/enabled') == '1'): ?>
|
20 |
+
<?php if($this->isProductAutoshipEligible()): ?>
|
21 |
+
<div class="subscription-product">
|
22 |
+
<ul class="options-list">
|
23 |
+
<li>
|
24 |
+
<input type="radio" onclick="" class="radio" id="delivery-option-one-time" name="delivery-option" value="one-time-delivery"/>
|
25 |
+
<div class="radio-text">
|
26 |
+
<span class=label>
|
27 |
+
<label for="delivery-option-one-time">One Time Delivery</label>
|
28 |
+
</span>
|
29 |
+
<p><span class="price">Price: <?php echo $this->getOneTimePurchasePrice(true) ?></span></p>
|
30 |
+
</div>
|
31 |
+
<div class="clearer"></div>
|
32 |
+
</li>
|
33 |
+
<li>
|
34 |
+
<input type="radio" onclick="" class="radio" id="delivery-option-subscribe" name="delivery-option" value="subscribe" checked="checked"/>
|
35 |
+
<span class=label>
|
36 |
+
<div class="radio-text">
|
37 |
+
<label for="delivery-option-subscribe">Regular Delivery</label>
|
38 |
+
</span>
|
39 |
+
<p><span class="product-price"><?php echo $this->getDiscountText() ?></span></p>
|
40 |
+
<p>
|
41 |
+
<label for="delivery-interval">Delivery every:</label><br />
|
42 |
+
<select onchange="" id="delivery-interval" name="delivery-interval" class="">
|
43 |
+
<?php foreach($this->getIntervals() as $interval): ?>
|
44 |
+
<option value="<?php echo $interval ?>"><?php echo $interval ?></option>
|
45 |
+
<?php endforeach; ?>
|
46 |
+
</select>
|
47 |
+
</p>
|
48 |
+
</div>
|
49 |
+
<div class="clearer"></div>
|
50 |
+
</li>
|
51 |
+
</ul>
|
52 |
+
</div>
|
53 |
+
<?php if(Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page') == '1'): ?>
|
54 |
+
<script type="text/javascript">
|
55 |
+
//<![CDATA[
|
56 |
+
$j = jQuery;
|
57 |
+
$j(document).ready(function () {
|
58 |
+
toggleAddToCart();
|
59 |
+
$j('input[name=delivery-option]').bind('change', function () {
|
60 |
+
toggleAddToCart();
|
61 |
+
});
|
62 |
+
$j('#subscribe_button').bind('click', function (e) {
|
63 |
+
e.preventDefault();
|
64 |
+
window.location = '<?php echo $this->getUrl('autoship/newsubscription/index') ?>product_id/<?php echo $this->getProduct()->getId() ?>/qty/' + $j('#qty').val() + '/interval/' + $j('#delivery-interval').val() + '/';
|
65 |
+
});
|
66 |
+
});
|
67 |
+
function toggleAddToCart() {
|
68 |
+
if ($j('#delivery-option-one-time').is(':checked')) {
|
69 |
+
$j('#add_to_cart').show();
|
70 |
+
$j('#subscribe').hide();
|
71 |
+
} else {
|
72 |
+
$j('#add_to_cart').hide();
|
73 |
+
$j('#subscribe').show();
|
74 |
+
}
|
75 |
+
}
|
76 |
+
//]]>
|
77 |
+
</script>
|
78 |
+
<?php endif; ?>
|
79 |
+
<?php endif; ?>
|
80 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/product/view/addtocart.phtml
ADDED
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
?>
|
18 |
+
<?php $_product = $this->getProduct(); ?>
|
19 |
+
<?php if(Mage::getStoreConfig('autoship_general/general/enabled') == '1'): ?>
|
20 |
+
<?php $_useNewSubPage = Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page') == '1'; ?>
|
21 |
+
<?php // Do autoship version of add to cart block? ?>
|
22 |
+
<?php if($_useNewSubPage && $this->isProductAutoshipEligible()): ?>
|
23 |
+
<?php $buttonTitle = $this->__('Subscribe Now'); ?>
|
24 |
+
<?php if($_product->isSaleable()): ?>
|
25 |
+
<div class="add-to-cart" id="subscribe" style="display:none;">
|
26 |
+
<?php if(!$_product->isGrouped()): ?>
|
27 |
+
<label for="qty"><?php echo $this->__('Qty:') ?></label>
|
28 |
+
<input type="text" name="qty" id="qty" maxlength="12" value="<?php echo $this->getProductDefaultQty() * 1 ?>" title="<?php echo $this->__('Qty') ?>" class="input-text qty" />
|
29 |
+
<?php endif; ?>
|
30 |
+
<button id="subscribe_button" type="button" title="<?php echo $buttonTitle ?>" class="button btn-cart" onclick=""><span><span><?php echo $buttonTitle ?></span></span></button>
|
31 |
+
<?php echo $this->getChildHtml('', true, true) ?>
|
32 |
+
</div>
|
33 |
+
<?php endif; ?>
|
34 |
+
<?php endif; ?>
|
35 |
+
<?php endif; ?>
|
36 |
+
<?php // Spit out regular version of add to cart block? ?>
|
37 |
+
<?php $buttonTitle = $this->__('Add to Cart'); ?>
|
38 |
+
<?php if($_product->isSaleable()): ?>
|
39 |
+
<div class="add-to-cart" id="add_to_cart">
|
40 |
+
<?php if(!$_product->isGrouped()): ?>
|
41 |
+
<label for="qty"><?php echo $this->__('Qty:') ?></label>
|
42 |
+
<input type="text" name="qty" id="qty" maxlength="12" value="<?php echo $this->getProductDefaultQty() * 1 ?>" title="<?php echo $this->__('Qty') ?>" class="input-text qty" />
|
43 |
+
<?php endif; ?>
|
44 |
+
<button type="button" title="<?php echo $buttonTitle ?>" class="button btn-cart" onclick="productAddToCartForm.submit(this)"><span><span><?php echo $buttonTitle ?></span></span></button>
|
45 |
+
<?php echo $this->getChildHtml('', true, true) ?>
|
46 |
+
</div>
|
47 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/product/view/type/grouped/subscribe.phtml
ADDED
@@ -0,0 +1,65 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$productId = $this->getProduct()->getId();
|
21 |
+
?>
|
22 |
+
<?php if (Mage::getStoreConfig('autoship_general/general/enabled') == '1'): ?>
|
23 |
+
<?php if (Mage::getStoreConfig('autoship_subscription/subscription/use_new_subscription_page') != '1'): ?>
|
24 |
+
<?php if ($this->isProductAutoshipEligible()): ?>
|
25 |
+
<div class="subscription-product">
|
26 |
+
<ul class="options-list">
|
27 |
+
<li>
|
28 |
+
<input type="radio" onclick="" class="radio" id="delivery-option-one-time" name="delivery-option[<?php echo $productId ?>]"
|
29 |
+
value="one-time-delivery"/>
|
30 |
+
|
31 |
+
<div class="radio-text">
|
32 |
+
<span class=label>
|
33 |
+
<label for="delivery-option-one-time">One Time Delivery</label>
|
34 |
+
</span>
|
35 |
+
|
36 |
+
<p><span class="price">Price: <?php echo $this->getOneTimePurchasePrice(true) ?></span></p>
|
37 |
+
</div>
|
38 |
+
<div class="clearer"></div>
|
39 |
+
</li>
|
40 |
+
<li>
|
41 |
+
<div class="radio-text">
|
42 |
+
<input type="radio" onclick="" class="radio" id="delivery-option-subscribe" name="delivery-option[<?php echo $productId ?>]"
|
43 |
+
value="subscribe" checked="checked"/>
|
44 |
+
<span class=label>
|
45 |
+
<label for="delivery-option-subscribe">Regular Delivery</label>
|
46 |
+
</span>
|
47 |
+
|
48 |
+
<p><span class="product-price"><?php echo $this->getDiscountText() ?></span></p>
|
49 |
+
|
50 |
+
<p>
|
51 |
+
<label for="delivery-interval">Delivery every:</label><br/>
|
52 |
+
<select onchange="" id="delivery-interval" name="delivery-interval[<?php echo $productId ?>]" class="">
|
53 |
+
<?php foreach ($this->getIntervals() as $interval): ?>
|
54 |
+
<option value="<?php echo $interval ?>"><?php echo $interval ?></option>
|
55 |
+
<?php endforeach; ?>
|
56 |
+
</select>
|
57 |
+
</p>
|
58 |
+
</div>
|
59 |
+
<div class="clearer"></div>
|
60 |
+
</li>
|
61 |
+
</ul>
|
62 |
+
</div>
|
63 |
+
<?php endif; ?>
|
64 |
+
<?php endif; ?>
|
65 |
+
<?php endif; ?>
|
app/design/frontend/base/default/template/autoship/subscription/form/billing.phtml
ADDED
@@ -0,0 +1,188 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$subscription = $this->getSubscription();
|
21 |
+
?>
|
22 |
+
<ul class="messages"></ul>
|
23 |
+
<form id="co-billing-form-<?php echo $subscription->getSubscriptionId() ?>" class="co-billing-form"
|
24 |
+
action="<?php echo $this->getSubmitUrl() ?>">
|
25 |
+
<input type="hidden" name="id" id="subscription_id_<?php echo $this->getSubscription()->getSubscriptionId() ?>"
|
26 |
+
value="<?php echo $this->getSubscription()->getSubscriptionId() ?>"/>
|
27 |
+
<ul class="form-list">
|
28 |
+
<?php if ($this->customerHasAddresses()): ?>
|
29 |
+
<li class="wide">
|
30 |
+
<label
|
31 |
+
for="billing-address-select-<?php echo $subscription->getSubscriptionId() ?>"><?php echo $this->__('Select a billing address from your address book or enter a new address.') ?></label>
|
32 |
+
|
33 |
+
<div class="input-box">
|
34 |
+
<?php echo $this->getAddressesHtmlSelect('billing', $subscription->getSubscriptionId()) ?>
|
35 |
+
</div>
|
36 |
+
</li>
|
37 |
+
<?php endif; ?>
|
38 |
+
<li id="billing-new-address-form-<?php echo $subscription->getSubscriptionId() ?>"
|
39 |
+
class="billing-new-address-form" <?php if ($this->customerHasAddresses()): ?> style="display:none;"<?php endif; ?>>
|
40 |
+
<fieldset>
|
41 |
+
<ul>
|
42 |
+
<li class="fields"><?php echo $this->getLayout()->createBlock('customer/widget_name')->setObject($this->getAddress('billing')
|
43 |
+
? $this->getAddress('billing') : $subscription->getCustomer())
|
44 |
+
->setForceUseCustomerRequiredAttributes(!$this->isCustomerLoggedIn())->setFieldIdFormat('billing:%s')
|
45 |
+
->setFieldNameFormat('billing[%s]')->toHtml() ?></li>
|
46 |
+
<li class="fields">
|
47 |
+
<div class="field">
|
48 |
+
<label
|
49 |
+
for="<?php echo $subscription->getSubscriptionId() ?>:billing:company"><?php echo $this->__('Company') ?></label>
|
50 |
+
|
51 |
+
<div class="input-box">
|
52 |
+
<input type="text" id="<?php echo $subscription->getSubscriptionId() ?>:billing:company"
|
53 |
+
name="billing[company]" title="<?php echo $this->__('Company') ?>"
|
54 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('company') ?>"/>
|
55 |
+
</div>
|
56 |
+
</div>
|
57 |
+
<?php if (!$this->isCustomerLoggedIn()): ?>
|
58 |
+
<div class="field">
|
59 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:billing:email"
|
60 |
+
class="required"><em>*</em><?php echo $this->__('Email Address') ?></label>
|
61 |
+
|
62 |
+
<div class="input-box">
|
63 |
+
<input type="text" name="billing[email]"
|
64 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:billing:email"
|
65 |
+
title="<?php echo $this->__('Email Address') ?>"
|
66 |
+
class="input-text validate-email required-entry"/>
|
67 |
+
</div>
|
68 |
+
</div>
|
69 |
+
<?php endif; ?>
|
70 |
+
</li>
|
71 |
+
<?php $_streetValidationClass =
|
72 |
+
' '; // Temp - disbale this class for 1.10.x compatibility // $this->helper('customer/address')->getAttributeValidationClass('street'); ?>
|
73 |
+
<li class="wide">
|
74 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:billing:street1"
|
75 |
+
class="required"><em>*</em><?php echo $this->__('Address') ?></label>
|
76 |
+
|
77 |
+
<div class="input-box">
|
78 |
+
<input type="text" title="<?php echo $this->__('Street Address') ?>" name="billing[street][]"
|
79 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:billing:street1"
|
80 |
+
class="input-text <?php echo $_streetValidationClass ?>"/>
|
81 |
+
</div>
|
82 |
+
</li>
|
83 |
+
<?php $_streetValidationClass = trim(str_replace('required-entry', '', $_streetValidationClass)); ?>
|
84 |
+
<?php for ($_i = 2, $_n = $this->helper('customer/address')->getStreetLines(); $_i <= $_n; $_i++): ?>
|
85 |
+
<li class="wide">
|
86 |
+
<div class="input-box">
|
87 |
+
<input type="text" title="<?php echo $this->__('Street Address %s', $_i) ?>" name="billing[street][]"
|
88 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:billing:street<?php echo $_i ?>"
|
89 |
+
class="input-text <?php echo $_streetValidationClass ?>"/>
|
90 |
+
</div>
|
91 |
+
</li>
|
92 |
+
<?php endfor; ?>
|
93 |
+
<li class="fields">
|
94 |
+
<div class="field">
|
95 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:billing:city"
|
96 |
+
class="required"><em>*</em><?php echo $this->__('City') ?></label>
|
97 |
+
|
98 |
+
<div class="input-box">
|
99 |
+
<input type="text" title="<?php echo $this->__('City') ?>" name="billing[city]"
|
100 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('city') ?>"
|
101 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:billing:city"/>
|
102 |
+
</div>
|
103 |
+
</div>
|
104 |
+
<div class="field">
|
105 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:billing:region_id"
|
106 |
+
class="required"><em>*</em><?php echo $this->__('State/Province') ?></label>
|
107 |
+
|
108 |
+
<div class="input-box">
|
109 |
+
<select id="<?php echo $subscription->getSubscriptionId() ?>:billing:region_id"
|
110 |
+
name="billing[region_id]" title="<?php echo $this->__('State/Province') ?>"
|
111 |
+
class="validate-select" style="display:none;">
|
112 |
+
<option value=""><?php echo $this->__('Please select region, state or province') ?></option>
|
113 |
+
</select>
|
114 |
+
<input type="text" id="<?php echo $subscription->getSubscriptionId() ?>:billing:region"
|
115 |
+
name="billing[region]" title="<?php echo $this->__('State/Province') ?>"
|
116 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('region') ?>"
|
117 |
+
style="display:none;"/>
|
118 |
+
</div>
|
119 |
+
</div>
|
120 |
+
</li>
|
121 |
+
<li class="fields">
|
122 |
+
<div class="field">
|
123 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:billing:postcode"
|
124 |
+
class="required"><em>*</em><?php echo $this->__('Zip/Postal Code') ?></label>
|
125 |
+
|
126 |
+
<div class="input-box">
|
127 |
+
<input type="text" title="<?php echo $this->__('Zip/Postal Code') ?>" name="billing[postcode]"
|
128 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:billing:postcode"
|
129 |
+
class="input-text validate-zip-international <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('postcode') ?>"/>
|
130 |
+
</div>
|
131 |
+
</div>
|
132 |
+
<div class="field">
|
133 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:billing:country_id"
|
134 |
+
class="required"><em>*</em><?php echo $this->__('Country') ?></label>
|
135 |
+
|
136 |
+
<div class="input-box">
|
137 |
+
<?php echo $this->getCountryHtmlSelect('billing', $subscription->getSubscriptionId()) ?>
|
138 |
+
</div>
|
139 |
+
</div>
|
140 |
+
</li>
|
141 |
+
<li class="fields">
|
142 |
+
<div class="field">
|
143 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:billing:telephone"
|
144 |
+
class="required"><em>*</em><?php echo $this->__('Telephone') ?></label>
|
145 |
+
|
146 |
+
<div class="input-box">
|
147 |
+
<input type="text" name="billing[telephone]" title="<?php echo $this->__('Telephone') ?>"
|
148 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('telephone') ?>"
|
149 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:billing:telephone"/>
|
150 |
+
</div>
|
151 |
+
</div>
|
152 |
+
<div class="field">
|
153 |
+
<label
|
154 |
+
for="<?php echo $subscription->getSubscriptionId() ?>:billing:fax"><?php echo $this->__('Fax') ?></label>
|
155 |
+
|
156 |
+
<div class="input-box">
|
157 |
+
<input type="text" name="billing[fax]" title="<?php echo $this->__('Fax') ?>"
|
158 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('fax') ?>"
|
159 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:billing:fax"/>
|
160 |
+
</div>
|
161 |
+
</div>
|
162 |
+
</li>
|
163 |
+
<li class="no-display"><input type="hidden" name="billing[save_in_address_book]" value="1"/></li>
|
164 |
+
</ul>
|
165 |
+
</fieldset>
|
166 |
+
</li>
|
167 |
+
</ul>
|
168 |
+
<div class="buttons-set" id="billing-buttons-container-<?php echo $subscription->getSubscriptionId() ?>">
|
169 |
+
<p class="required"><?php echo $this->__('* Required Fields') ?></p>
|
170 |
+
<button type="submit" title="<?php echo $this->__('Continue') ?>" class="button">
|
171 |
+
<span><span><?php echo $this->__('Continue') ?></span></span></button>
|
172 |
+
</div>
|
173 |
+
</form>
|
174 |
+
<script type="text/javascript">
|
175 |
+
//<![CDATA[
|
176 |
+
$j(document).ready(function () {
|
177 |
+
var billingForm<?php echo $subscription->getSubscriptionId() ?> = new VarienForm('co-billing-form-<?php echo $subscription->getSubscriptionId() ?>');
|
178 |
+
var billingAddressRegionUpdater<?php echo $subscription->getSubscriptionId() ?> = new RegionUpdater(
|
179 |
+
'<?php echo $subscription->getSubscriptionId() ?>:billing:country_id',
|
180 |
+
'<?php echo $subscription->getSubscriptionId() ?>:billing:region',
|
181 |
+
'<?php echo $subscription->getSubscriptionId() ?>:billing:region_id',
|
182 |
+
regionsJson,
|
183 |
+
undefined,
|
184 |
+
'<?php echo $subscription->getSubscriptionId() ?>:billing:postcode'
|
185 |
+
);
|
186 |
+
});
|
187 |
+
//]]>
|
188 |
+
</script>
|
app/design/frontend/base/default/template/autoship/subscription/form/payment.phtml
ADDED
@@ -0,0 +1,64 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
12 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<ul class="messages"></ul>
|
20 |
+
<form id="co-payment-form" class="payment-form" action="<?php echo $this->getSubmitUrl() ?>">
|
21 |
+
<input type="hidden" name="id" id="subscription_id_<?php echo $this->getSubscription()->getSubscriptionId() ?>"
|
22 |
+
value="<?php echo $this->getSubscription()->getSubscriptionId() ?>"/>
|
23 |
+
<fieldset>
|
24 |
+
<dl>
|
25 |
+
|
26 |
+
<?php
|
27 |
+
// Get saved credit cards
|
28 |
+
$savedCards = $this->getSavedCards();
|
29 |
+
$selectedCard = $this->getCurrentCard();
|
30 |
+
?>
|
31 |
+
<?php foreach ($savedCards as $card): ?>
|
32 |
+
<dt>
|
33 |
+
<?php $curMethodName = 'Use my Saved Card Ending in ' . $card['creditcard_last_digits']; ?>
|
34 |
+
<input
|
35 |
+
id="payment_token_<?php echo $card['payment_token'] ?>"
|
36 |
+
value="<?php echo $card['payment_token'] ?>"
|
37 |
+
type="radio" name="payment[method]"
|
38 |
+
title="<?php echo $this->htmlEscape($curMethodName) ?>"
|
39 |
+
onclick=""
|
40 |
+
class="radio"
|
41 |
+
<?php if($card['payment_token'] == $selectedCard['payment_token']): ?>checked="checked"<?php endif; ?> />
|
42 |
+
<label for="payment_token_<?php echo $card['payment_token'] ?>">
|
43 |
+
<?php echo $this->escapeHtml($curMethodName) ?><?php if (strlen($card['edit_url'])): ?> <a href="<?php echo $card['edit_url'] ?>">(Edit)</a><?php endif; ?>
|
44 |
+
</label>
|
45 |
+
</dt>
|
46 |
+
<dd>
|
47 |
+
<ul class="form-list" id="payment_form_<?php echo $card['payment_token'] ?>" style="display:none;">
|
48 |
+
<li>
|
49 |
+
<input type="hidden" id="<?php echo $card['payment_token'] ?>_creditcard_last_digits"
|
50 |
+
name="payment[creditcard_last_digits][<?php echo $card['payment_token'] ?>]"
|
51 |
+
value="<?php echo $card['creditcard_last_digits'] ?>" />
|
52 |
+
</li>
|
53 |
+
</ul>
|
54 |
+
</dd>
|
55 |
+
<?php endforeach; ?>
|
56 |
+
</dl>
|
57 |
+
<div class="buttons-set" id="billing-buttons-container">
|
58 |
+
<button type="submit" title="<?php echo $this->__('Continue') ?>" class="button"><span><span><?php echo $this->__('Continue') ?></span></span></button>
|
59 |
+
<span class="please-wait" id="billing-please-wait" style="display:none;">
|
60 |
+
<img src="<?php echo $this->getSkinUrl('images/opc-ajax-loader.gif') ?>" alt="<?php echo $this->__('Updating...') ?>" title="<?php echo $this->__('Updating...') ?>" class="v-middle" /> <?php echo $this->__('Updating...') ?>
|
61 |
+
</span>
|
62 |
+
</div>
|
63 |
+
</fieldset>
|
64 |
+
</form>
|
app/design/frontend/base/default/template/autoship/subscription/form/shipping.phtml
ADDED
@@ -0,0 +1,175 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
?>
|
19 |
+
<?php
|
20 |
+
$subscription = $this->getSubscription();
|
21 |
+
?>
|
22 |
+
<ul class="messages"></ul>
|
23 |
+
<form id="co-shipping-form-<?php echo $subscription->getSubscriptionId() ?>" class="co-shipping-form"
|
24 |
+
action="<?php echo $this->getSubmitUrl() ?>">
|
25 |
+
<input type="hidden" name="id" id="subscription_id_<?php echo $this->getSubscription()->getSubscriptionId() ?>"
|
26 |
+
value="<?php echo $this->getSubscription()->getSubscriptionId() ?>"/>
|
27 |
+
<ul class="form-list">
|
28 |
+
<?php if ($this->customerHasAddresses()): ?>
|
29 |
+
<li class="wide">
|
30 |
+
<label
|
31 |
+
for="shipping-address-select"><?php echo $this->__('Select a shipping address from your address book or enter a new address.') ?></label>
|
32 |
+
|
33 |
+
<div class="input-box">
|
34 |
+
<?php echo $this->getAddressesHtmlSelect('shipping') ?>
|
35 |
+
</div>
|
36 |
+
</li>
|
37 |
+
<?php endif; ?>
|
38 |
+
<li id="shipping-new-address-form-<?php echo $subscription->getSubscriptionId() ?>"
|
39 |
+
class="shipping-new-address-form" <?php if ($this->customerHasAddresses()): ?> style="display:none;"<?php endif; ?>>
|
40 |
+
<fieldset>
|
41 |
+
<ul>
|
42 |
+
<li class="fields"><?php echo $this->getLayout()->createBlock('customer/widget_name')->setObject($this->getAddress('shipping')
|
43 |
+
? $this->getAddress('shipping') : $subscription->getCustomer())
|
44 |
+
->setForceUseCustomerRequiredAttributes(!$this->isCustomerLoggedIn())->setFieldIdFormat('shipping:%s')
|
45 |
+
->setFieldNameFormat('shipping[%s]')->toHtml() ?></li>
|
46 |
+
<li class="fields">
|
47 |
+
<div class="field">
|
48 |
+
<label
|
49 |
+
for="<?php echo $subscription->getSubscriptionId() ?>:shipping:company"><?php echo $this->__('Company') ?></label>
|
50 |
+
|
51 |
+
<div class="input-box">
|
52 |
+
<input type="text" id="<?php echo $subscription->getSubscriptionId() ?>:shipping:company"
|
53 |
+
name="shipping[company]" title="<?php echo $this->__('Company') ?>"
|
54 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('company') ?>"/>
|
55 |
+
</div>
|
56 |
+
</div>
|
57 |
+
</li>
|
58 |
+
<?php $_streetValidationClass =
|
59 |
+
''; // Temp - disbale this class for 1.10.x compatibility // $this->helper('customer/address')->getAttributeValidationClass('street'); ?>
|
60 |
+
<li class="wide">
|
61 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:shipping:street1"
|
62 |
+
class="required"><em>*</em><?php echo $this->__('Address') ?></label>
|
63 |
+
|
64 |
+
<div class="input-box">
|
65 |
+
<input type="text" title="<?php echo $this->__('Street Address') ?>" name="shipping[street][]"
|
66 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:shipping:street1"
|
67 |
+
class="input-text <?php echo $_streetValidationClass ?>"/>
|
68 |
+
</div>
|
69 |
+
</li>
|
70 |
+
<?php $_streetValidationClass = trim(str_replace('required-entry', '', $_streetValidationClass)); ?>
|
71 |
+
<?php for ($_i = 2, $_n = $this->helper('customer/address')->getStreetLines(); $_i <= $_n; $_i++): ?>
|
72 |
+
<li class="wide">
|
73 |
+
<div class="input-box">
|
74 |
+
<input type="text" title="<?php echo $this->__('Street Address %s', $_i) ?>" name="shipping[street][]"
|
75 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:shipping:street<?php echo $_i ?>"
|
76 |
+
class="input-text <?php echo $_streetValidationClass ?>"/>
|
77 |
+
</div>
|
78 |
+
</li>
|
79 |
+
<?php endfor; ?>
|
80 |
+
<li class="fields">
|
81 |
+
<div class="field">
|
82 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:shipping:city"
|
83 |
+
class="required"><em>*</em><?php echo $this->__('City') ?></label>
|
84 |
+
|
85 |
+
<div class="input-box">
|
86 |
+
<input type="text" title="<?php echo $this->__('City') ?>" name="shipping[city]"
|
87 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('city') ?>"
|
88 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:shipping:city"/>
|
89 |
+
</div>
|
90 |
+
</div>
|
91 |
+
<div class="field">
|
92 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:shipping:region_id"
|
93 |
+
class="required"><em>*</em><?php echo $this->__('State/Province') ?></label>
|
94 |
+
|
95 |
+
<div class="input-box">
|
96 |
+
<select id="<?php echo $subscription->getSubscriptionId() ?>:shipping:region_id"
|
97 |
+
name="shipping[region_id]" title="<?php echo $this->__('State/Province') ?>"
|
98 |
+
class="validate-select" style="display:none;">
|
99 |
+
<option value=""><?php echo $this->__('Please select region, state or province') ?></option>
|
100 |
+
</select>
|
101 |
+
<input type="text" id="<?php echo $subscription->getSubscriptionId() ?>:shipping:region"
|
102 |
+
name="shipping[region]" title="<?php echo $this->__('State/Province') ?>"
|
103 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('region') ?>"
|
104 |
+
style="display:none;"/>
|
105 |
+
</div>
|
106 |
+
</div>
|
107 |
+
</li>
|
108 |
+
<li class="fields">
|
109 |
+
<div class="field">
|
110 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:shipping:postcode"
|
111 |
+
class="required"><em>*</em><?php echo $this->__('Zip/Postal Code') ?></label>
|
112 |
+
|
113 |
+
<div class="input-box">
|
114 |
+
<input type="text" title="<?php echo $this->__('Zip/Postal Code') ?>" name="shipping[postcode]"
|
115 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:shipping:postcode"
|
116 |
+
class="input-text validate-zip-international <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('postcode') ?>"/>
|
117 |
+
</div>
|
118 |
+
</div>
|
119 |
+
<div class="field">
|
120 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:shipping:country_id"
|
121 |
+
class="required"><em>*</em><?php echo $this->__('Country') ?></label>
|
122 |
+
|
123 |
+
<div class="input-box">
|
124 |
+
<?php echo $this->getCountryHtmlSelect('shipping', $subscription->getSubscriptionId()) ?>
|
125 |
+
</div>
|
126 |
+
</div>
|
127 |
+
</li>
|
128 |
+
<li class="fields">
|
129 |
+
<div class="field">
|
130 |
+
<label for="<?php echo $subscription->getSubscriptionId() ?>:shipping:telephone"
|
131 |
+
class="required"><em>*</em><?php echo $this->__('Telephone') ?></label>
|
132 |
+
|
133 |
+
<div class="input-box">
|
134 |
+
<input type="text" name="shipping[telephone]" title="<?php echo $this->__('Telephone') ?>"
|
135 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('telephone') ?>"
|
136 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:shipping:telephone"/>
|
137 |
+
</div>
|
138 |
+
</div>
|
139 |
+
<div class="field">
|
140 |
+
<label
|
141 |
+
for="<?php echo $subscription->getSubscriptionId() ?>:shipping:fax"><?php echo $this->__('Fax') ?></label>
|
142 |
+
|
143 |
+
<div class="input-box">
|
144 |
+
<input type="text" name="shipping[fax]" title="<?php echo $this->__('Fax') ?>"
|
145 |
+
class="input-text <?php // Temp - disbale this class for 1.10.x compatibility // echo $this->helper('customer/address')->getAttributeValidationClass('fax') ?>"
|
146 |
+
id="<?php echo $subscription->getSubscriptionId() ?>:shipping:fax"/>
|
147 |
+
</div>
|
148 |
+
</div>
|
149 |
+
</li>
|
150 |
+
<li class="no-display"><input type="hidden" name="shipping[save_in_address_book]" value="1"/></li>
|
151 |
+
</ul>
|
152 |
+
</fieldset>
|
153 |
+
</li>
|
154 |
+
</ul>
|
155 |
+
<div class="buttons-set" id="shipping-buttons-container-<?php echo $subscription->getSubscriptionId() ?>">
|
156 |
+
<p class="required"><?php echo $this->__('* Required Fields') ?></p>
|
157 |
+
<button type="submit" title="<?php echo $this->__('Continue') ?>" class="button">
|
158 |
+
<span><span><?php echo $this->__('Continue') ?></span></span></button>
|
159 |
+
</div>
|
160 |
+
</form>
|
161 |
+
<script type="text/javascript">
|
162 |
+
//<![CDATA[
|
163 |
+
$j(document).ready(function () {
|
164 |
+
var shippingForm<?php echo $subscription->getSubscriptionId() ?> = new VarienForm('co-shipping-form-<?php echo $subscription->getSubscriptionId() ?>');
|
165 |
+
var shippingAddressRegionUpdater<?php echo $subscription->getSubscriptionId() ?> = new RegionUpdater(
|
166 |
+
'<?php echo $subscription->getSubscriptionId() ?>:shipping:country_id',
|
167 |
+
'<?php echo $subscription->getSubscriptionId() ?>:shipping:region',
|
168 |
+
'<?php echo $subscription->getSubscriptionId() ?>:shipping:region_id',
|
169 |
+
regionsJson,
|
170 |
+
undefined,
|
171 |
+
'<?php echo $subscription->getSubscriptionId() ?>:shipping:postcode'
|
172 |
+
);
|
173 |
+
});
|
174 |
+
//]]>
|
175 |
+
</script>
|
app/design/frontend/enterprise/default/layout/autoship.xml
ADDED
@@ -0,0 +1,254 @@
|
|
|
|
|
|
|
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UTF-8"?>
|
2 |
+
<!--
|
3 |
+
/**
|
4 |
+
* Subscribe Pro - Subscriptions Management Extension
|
5 |
+
*
|
6 |
+
* PHP version 5
|
7 |
+
*
|
8 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
9 |
+
*
|
10 |
+
* @category SFC
|
11 |
+
* @package SFC_Autoship
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
-->
|
19 |
+
<layout version="0.1.0">
|
20 |
+
|
21 |
+
<!-- My Product Subscriptions page -->
|
22 |
+
<autoship_mysubscriptions_index>
|
23 |
+
<label>My Product Subscriptions</label>
|
24 |
+
<update handle="customer_account" />
|
25 |
+
|
26 |
+
<reference name="head">
|
27 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
28 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/jquery-1.10.1.min.js</name></action>
|
29 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.core.min.js</name></action>
|
30 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.datepicker.min.js</name></action>
|
31 |
+
<action method="addItem"><type>skin_css</type><name>js/autoship/jquery/ui/theme/jquery-ui.css</name></action>
|
32 |
+
|
33 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/noconflict.js</name></action>
|
34 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/mysubscription.js</name></action>
|
35 |
+
|
36 |
+
<action method="addItem"><type>js_css</type><name>calendar/calendar-win2k-1.css</name><params/><!--<if/><condition>can_load_calendar_js</condition>--></action>
|
37 |
+
<action method="addItem"><type>js</type><name>calendar/calendar.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
38 |
+
<action method="addItem"><type>js</type><name>calendar/calendar-setup.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
39 |
+
</reference>
|
40 |
+
|
41 |
+
<reference name="customer_account_navigation">
|
42 |
+
<action method="setActive"><path>autoship/mysubscriptions/</path></action>
|
43 |
+
</reference>
|
44 |
+
|
45 |
+
<reference name="my.account.wrapper">
|
46 |
+
<block type="autoship/mysubscriptions" name="mysubscriptions" template="autoship/mysubscriptions.phtml" />
|
47 |
+
</reference>
|
48 |
+
</autoship_mysubscriptions_index>
|
49 |
+
|
50 |
+
<!-- Customer dashboard link -->
|
51 |
+
<customer_account>
|
52 |
+
<reference name="customer_account_navigation">
|
53 |
+
<action method="addLink" translate="label" module="autoship" ifconfig="autoship_general/general/enabled">
|
54 |
+
<name>mysubscriptions</name>
|
55 |
+
<path>autoship/mysubscriptions/</path>
|
56 |
+
<label>My Product Subscriptions</label>
|
57 |
+
</action>
|
58 |
+
</reference>
|
59 |
+
</customer_account>
|
60 |
+
|
61 |
+
<!-- New Subscription page -->
|
62 |
+
<autoship_newsubscription_index>
|
63 |
+
<label>Create New Product Subscription</label>
|
64 |
+
|
65 |
+
<reference name="root">
|
66 |
+
<action method="setTemplate"><template>page/1column.phtml</template></action>
|
67 |
+
</reference>
|
68 |
+
|
69 |
+
<reference name="head">
|
70 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
71 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/jquery-1.10.1.min.js</name></action>
|
72 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.core.min.js</name></action>
|
73 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/ui/jquery.ui.datepicker.min.js</name></action>
|
74 |
+
<action method="addItem"><type>skin_css</type><name>js/autoship/jquery/ui/theme/jquery-ui.css</name></action>
|
75 |
+
|
76 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/jquery/noconflict.js</name></action>
|
77 |
+
<action method="addItem"><type>skin_js</type><name>js/autoship/newsubscription.js</name></action>
|
78 |
+
|
79 |
+
<action method="addItem"><type>js_css</type><name>calendar/calendar-win2k-1.css</name><params/><!--<if/><condition>can_load_calendar_js</condition>--></action>
|
80 |
+
<action method="addItem"><type>js</type><name>calendar/calendar.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
81 |
+
<action method="addItem"><type>js</type><name>calendar/calendar-setup.js</name><!--<params/><if/><condition>can_load_calendar_js</condition>--></action>
|
82 |
+
</reference>
|
83 |
+
|
84 |
+
<reference name="content">
|
85 |
+
<block type="autoship/newsubscription" name="newsubscription" template="autoship/newsubscription.phtml" >
|
86 |
+
<block type="autoship/newsubscription" name="newsubscription.product_info" template="autoship/newsubscription/product_info.phtml" />
|
87 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_date" template="autoship/newsubscription/delivery_date.phtml">
|
88 |
+
<block type="core/html_calendar" name="html_calendar" as="html_calendar" template="page/js/calendar.phtml"/>
|
89 |
+
</block>
|
90 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_frequency" template="autoship/newsubscription/delivery_frequency.phtml" />
|
91 |
+
<block type="autoship/newsubscription" name="newsubscription.payment" template="autoship/newsubscription/payment.phtml">
|
92 |
+
<block type="autoship/newsubscription_form_payment" name="payment" template="autoship/subscription/form/payment.phtml" />
|
93 |
+
</block>
|
94 |
+
<block type="autoship/newsubscription" name="newsubscription.billing_address" template="autoship/newsubscription/billing_address.phtml">
|
95 |
+
<block type="autoship/newsubscription_form_billing" name="billing_address_select" template="autoship/subscription/form/billing.phtml"/>
|
96 |
+
</block>
|
97 |
+
<block type="autoship/newsubscription" name="newsubscription.shipping_address" template="autoship/newsubscription/shipping_address.phtml">
|
98 |
+
<block type="autoship/newsubscription_form_shipping" name="shipping_address_select" template="autoship/subscription/form/shipping.phtml"/>
|
99 |
+
</block>
|
100 |
+
<block type="autoship/newsubscription" name="newsubscription.summary" template="autoship/newsubscription/summary.phtml" />
|
101 |
+
</block>
|
102 |
+
</reference>
|
103 |
+
|
104 |
+
</autoship_newsubscription_index>
|
105 |
+
|
106 |
+
<!-- This layout handle handles all ajax controllers that update new subscription page contents -->
|
107 |
+
<autoship_newsubscription_update>
|
108 |
+
<remove name="right"/>
|
109 |
+
<remove name="left"/>
|
110 |
+
|
111 |
+
<block type="autoship/newsubscription" name="root" output="toHtml" template="autoship/newsubscription/ajax_update.phtml">
|
112 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_date" template="autoship/newsubscription/delivery_date.phtml">
|
113 |
+
<block type="core/html_calendar" name="html_calendar" as="html_calendar" template="page/js/calendar.phtml"/>
|
114 |
+
</block>
|
115 |
+
<block type="autoship/newsubscription" name="newsubscription.delivery_frequency" template="autoship/newsubscription/delivery_frequency.phtml" />
|
116 |
+
<block type="autoship/newsubscription" name="newsubscription.payment" template="autoship/newsubscription/payment.phtml">
|
117 |
+
<block type="autoship/newsubscription_form_payment" name="payment" template="autoship/subscription/form/payment.phtml" />
|
118 |
+
</block>
|
119 |
+
<block type="autoship/newsubscription" name="newsubscription.billing_address" template="autoship/newsubscription/billing_address.phtml">
|
120 |
+
<block type="autoship/newsubscription_form_billing" name="billing_address_select" template="autoship/subscription/form/billing.phtml"/>
|
121 |
+
</block>
|
122 |
+
<block type="autoship/newsubscription" name="newsubscription.shipping_address" template="autoship/newsubscription/shipping_address.phtml">
|
123 |
+
<block type="autoship/newsubscription_form_shipping" name="shipping_address_select" template="autoship/subscription/form/shipping.phtml"/>
|
124 |
+
</block>
|
125 |
+
<block type="autoship/newsubscription" name="newsubscription.summary" template="autoship/newsubscription/summary.phtml" />
|
126 |
+
</block>
|
127 |
+
</autoship_newsubscription_update>
|
128 |
+
|
129 |
+
<autoship_newsubscription_paymentsave>
|
130 |
+
<update handle="autoship_newsubscription_update"/>
|
131 |
+
</autoship_newsubscription_paymentsave>
|
132 |
+
|
133 |
+
<autoship_newsubscription_billingsave>
|
134 |
+
<update handle="autoship_newsubscription_update"/>
|
135 |
+
</autoship_newsubscription_billingsave>
|
136 |
+
|
137 |
+
<autoship_newsubscription_shippingsave>
|
138 |
+
<update handle="autoship_newsubscription_update"/>
|
139 |
+
</autoship_newsubscription_shippingsave>
|
140 |
+
|
141 |
+
<!--
|
142 |
+
Product view
|
143 |
+
-->
|
144 |
+
|
145 |
+
<catalog_product_view>
|
146 |
+
<reference name="head">
|
147 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
148 |
+
</reference>
|
149 |
+
|
150 |
+
<!-- Create subscribe and autoship block in product info area -->
|
151 |
+
<reference name="product.info">
|
152 |
+
<block type="autoship/product_subscribe" name="product.info.subscribe" as="product.info.subscribe" template="autoship/product/subscribe.phtml"/>
|
153 |
+
</reference>
|
154 |
+
|
155 |
+
<!-- Insert block into correct location in product info with insert method -->
|
156 |
+
<reference name="product.info.options.wrapper.bottom">
|
157 |
+
<action method="insert"><block>product.info.subscribe</block><siblingName>product.info.addtocart</siblingName></action>
|
158 |
+
</reference>
|
159 |
+
|
160 |
+
<!-- Replace addtocart.phtml template with ours -->
|
161 |
+
<reference name="product.info.addtocart">
|
162 |
+
<action method="setTemplate"><template>autoship/product/view/addtocart.phtml</template></action>
|
163 |
+
</reference>
|
164 |
+
|
165 |
+
</catalog_product_view>
|
166 |
+
|
167 |
+
<!-- Add subscription features to cart page -->
|
168 |
+
<checkout_cart_index>
|
169 |
+
<reference name="head">
|
170 |
+
<action method="addCss"><stylesheet>css/autoship.css</stylesheet></action>
|
171 |
+
</reference>
|
172 |
+
<reference name="additional.product.info">
|
173 |
+
<block type="autoship/cart_product_subscription" name="autoship.product.subscription" template="autoship/cart/product/subscription.phtml"/>
|
174 |
+
</reference>
|
175 |
+
</checkout_cart_index>
|
176 |
+
|
177 |
+
<!-- Add message about subscriptions to checkout success page -->
|
178 |
+
<checkout_onepage_success translate="label">
|
179 |
+
<reference name="checkout.success">
|
180 |
+
<block type="core/template" name="checkout.success.subscriptions" template="autoship/checkout/success.phtml"/>
|
181 |
+
</reference>
|
182 |
+
</checkout_onepage_success>
|
183 |
+
|
184 |
+
<!-- Payment Profile grid-->
|
185 |
+
<autoship_mycreditcards_index>
|
186 |
+
<label>Payment Profiles</label>
|
187 |
+
<update handle="customer_account"/>
|
188 |
+
<reference name="customer_account_navigation">
|
189 |
+
<action method="setActive">
|
190 |
+
<path>subscriptions/mycreditcards/</path>
|
191 |
+
</action>
|
192 |
+
</reference>
|
193 |
+
<reference name="my.account.wrapper">
|
194 |
+
<block type="autoship/payment_profile_grid" name="payment_profile_index"
|
195 |
+
template="autoship/payment/profile/grid.phtml"/>
|
196 |
+
</reference>
|
197 |
+
</autoship_mycreditcards_index>
|
198 |
+
|
199 |
+
<!-- Payment Profile customer dashboard link -->
|
200 |
+
<customer_account>
|
201 |
+
<reference name="customer_account_navigation">
|
202 |
+
<action method="addLink" translate="label" module="autoship" ifconfig="payment/subscribe_pro/active">
|
203 |
+
<name>mycreditcards</name>
|
204 |
+
<path>subscriptions/mycreditcards/</path>
|
205 |
+
<label>My Credit Cards</label>
|
206 |
+
</action>
|
207 |
+
</reference>
|
208 |
+
</customer_account>
|
209 |
+
|
210 |
+
<!-- Edit Payment Profile -->
|
211 |
+
<autoship_mycreditcards_edit>
|
212 |
+
<label>Edit Payment Profile</label>
|
213 |
+
<update handle="customer_account"/>
|
214 |
+
<reference name="customer_account_navigation">
|
215 |
+
<action method="setActive">
|
216 |
+
<path>subscriptions/mycreditcards/</path>
|
217 |
+
</action>
|
218 |
+
</reference>
|
219 |
+
<reference name="my.account.wrapper">
|
220 |
+
<block type="autoship/payment_profile_edit" name="payment_profile_edit"
|
221 |
+
template="autoship/payment/profile/edit.phtml">
|
222 |
+
</block>
|
223 |
+
</reference>
|
224 |
+
</autoship_mycreditcards_edit>
|
225 |
+
|
226 |
+
<!-- New Payment Profile -->
|
227 |
+
<autoship_mycreditcards_new>
|
228 |
+
<label>New Payment Profile</label>
|
229 |
+
<update handle="customer_account"/>
|
230 |
+
<reference name="customer_account_navigation">
|
231 |
+
<action method="setActive">
|
232 |
+
<path>subscriptions/mycreditcards/</path>
|
233 |
+
</action>
|
234 |
+
</reference>
|
235 |
+
<reference name="my.account.wrapper">
|
236 |
+
<block type="autoship/payment_profile_edit" name="payment_profile_edit"
|
237 |
+
template="autoship/payment/profile/new.phtml">
|
238 |
+
</block>
|
239 |
+
</reference>
|
240 |
+
</autoship_mycreditcards_new>
|
241 |
+
|
242 |
+
<!-- Include transparent redirect javascript in one page checkout -->
|
243 |
+
<checkout_onepage_index>
|
244 |
+
<reference name="head">
|
245 |
+
<action method="addItem" ifconfig="payment/subscribe_pro/use_transparent_redirect"><type>skin_js</type><name>js/autoship/jquery/jquery-1.10.1.min.js</name></action>
|
246 |
+
<action method="addItem" ifconfig="payment/subscribe_pro/use_transparent_redirect"><type>skin_js</type><name>js/autoship/jquery/noconflict.js</name></action>
|
247 |
+
</reference>
|
248 |
+
<reference name="content">
|
249 |
+
<block type="autoship/checkout_jsonp" name="jsonp" template="autoship/checkout/jsonp.phtml" after="-"/>
|
250 |
+
<block type="autoship/checkout_jsonp" name="serversideapi" template="autoship/checkout/serversideapi.phtml" after="-"/>
|
251 |
+
</reference>
|
252 |
+
</checkout_onepage_index>
|
253 |
+
|
254 |
+
</layout>
|
app/etc/modules/SFC_Autoship.xml
ADDED
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<modules>
|
4 |
+
<SFC_Autoship>
|
5 |
+
<active>true</active>
|
6 |
+
<codePool>local</codePool>
|
7 |
+
<depends>
|
8 |
+
</depends>
|
9 |
+
</SFC_Autoship>
|
10 |
+
</modules>
|
11 |
+
</config>
|
lib/OAuth2/Client.php
ADDED
@@ -0,0 +1,540 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Note : Code is released under the GNU LGPL
|
4 |
+
*
|
5 |
+
* Please do not change the header of this file
|
6 |
+
*
|
7 |
+
* This library is free software; you can redistribute it and/or modify it under the terms of the GNU
|
8 |
+
* Lesser General Public License as published by the Free Software Foundation; either version 2 of
|
9 |
+
* the License, or (at your option) any later version.
|
10 |
+
*
|
11 |
+
* This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
12 |
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
13 |
+
*
|
14 |
+
* See the GNU Lesser General Public License for more details.
|
15 |
+
*/
|
16 |
+
|
17 |
+
/**
|
18 |
+
* Light PHP wrapper for the OAuth 2.0 protocol.
|
19 |
+
*
|
20 |
+
* This client is based on the OAuth2 specification draft v2.15
|
21 |
+
* http://tools.ietf.org/html/draft-ietf-oauth-v2-15
|
22 |
+
*
|
23 |
+
* @author Pierrick Charron <pierrick@webstart.fr>
|
24 |
+
* @author Anis Berejeb <anis.berejeb@gmail.com>
|
25 |
+
* @version 1.2-dev
|
26 |
+
*/
|
27 |
+
namespace OAuth2;
|
28 |
+
|
29 |
+
class Client
|
30 |
+
{
|
31 |
+
/**
|
32 |
+
* Different AUTH method
|
33 |
+
*/
|
34 |
+
const AUTH_TYPE_URI = 0;
|
35 |
+
const AUTH_TYPE_AUTHORIZATION_BASIC = 1;
|
36 |
+
const AUTH_TYPE_FORM = 2;
|
37 |
+
|
38 |
+
/**
|
39 |
+
* Different Access token type
|
40 |
+
*/
|
41 |
+
const ACCESS_TOKEN_URI = 0;
|
42 |
+
const ACCESS_TOKEN_BEARER = 1;
|
43 |
+
const ACCESS_TOKEN_OAUTH = 2;
|
44 |
+
const ACCESS_TOKEN_MAC = 3;
|
45 |
+
|
46 |
+
/**
|
47 |
+
* Different Grant types
|
48 |
+
*/
|
49 |
+
const GRANT_TYPE_AUTH_CODE = 'authorization_code';
|
50 |
+
const GRANT_TYPE_PASSWORD = 'password';
|
51 |
+
const GRANT_TYPE_CLIENT_CREDENTIALS = 'client_credentials';
|
52 |
+
const GRANT_TYPE_REFRESH_TOKEN = 'refresh_token';
|
53 |
+
|
54 |
+
/**
|
55 |
+
* HTTP Methods
|
56 |
+
*/
|
57 |
+
const HTTP_METHOD_GET = 'GET';
|
58 |
+
const HTTP_METHOD_POST = 'POST';
|
59 |
+
const HTTP_METHOD_PUT = 'PUT';
|
60 |
+
const HTTP_METHOD_DELETE = 'DELETE';
|
61 |
+
const HTTP_METHOD_HEAD = 'HEAD';
|
62 |
+
const HTTP_METHOD_PATCH = 'PATCH';
|
63 |
+
|
64 |
+
/**
|
65 |
+
* HTTP Form content types
|
66 |
+
*/
|
67 |
+
const HTTP_FORM_CONTENT_TYPE_APPLICATION = 0;
|
68 |
+
const HTTP_FORM_CONTENT_TYPE_MULTIPART = 1;
|
69 |
+
const HTTP_FORM_CONTENT_JSON = 2;
|
70 |
+
|
71 |
+
/**
|
72 |
+
* Client ID
|
73 |
+
*
|
74 |
+
* @var string
|
75 |
+
*/
|
76 |
+
protected $client_id = null;
|
77 |
+
|
78 |
+
/**
|
79 |
+
* Client Secret
|
80 |
+
*
|
81 |
+
* @var string
|
82 |
+
*/
|
83 |
+
protected $client_secret = null;
|
84 |
+
|
85 |
+
/**
|
86 |
+
* Client Authentication method
|
87 |
+
*
|
88 |
+
* @var int
|
89 |
+
*/
|
90 |
+
protected $client_auth = self::AUTH_TYPE_URI;
|
91 |
+
|
92 |
+
/**
|
93 |
+
* Access Token
|
94 |
+
*
|
95 |
+
* @var string
|
96 |
+
*/
|
97 |
+
protected $access_token = null;
|
98 |
+
|
99 |
+
/**
|
100 |
+
* Access Token Type
|
101 |
+
*
|
102 |
+
* @var int
|
103 |
+
*/
|
104 |
+
protected $access_token_type = self::ACCESS_TOKEN_URI;
|
105 |
+
|
106 |
+
/**
|
107 |
+
* Access Token Secret
|
108 |
+
*
|
109 |
+
* @var string
|
110 |
+
*/
|
111 |
+
protected $access_token_secret = null;
|
112 |
+
|
113 |
+
/**
|
114 |
+
* Access Token crypt algorithm
|
115 |
+
*
|
116 |
+
* @var string
|
117 |
+
*/
|
118 |
+
protected $access_token_algorithm = null;
|
119 |
+
|
120 |
+
/**
|
121 |
+
* Access Token Parameter name
|
122 |
+
*
|
123 |
+
* @var string
|
124 |
+
*/
|
125 |
+
protected $access_token_param_name = 'access_token';
|
126 |
+
|
127 |
+
/**
|
128 |
+
* The path to the certificate file to use for https connections
|
129 |
+
*
|
130 |
+
* @var string Defaults to .
|
131 |
+
*/
|
132 |
+
protected $certificate_file = null;
|
133 |
+
|
134 |
+
/**
|
135 |
+
* The path to log file to receive curl logging
|
136 |
+
* @var string
|
137 |
+
*/
|
138 |
+
protected $logFilePath = null;
|
139 |
+
|
140 |
+
/**
|
141 |
+
* cURL options
|
142 |
+
*
|
143 |
+
* @var array
|
144 |
+
*/
|
145 |
+
protected $curl_options = array();
|
146 |
+
|
147 |
+
/**
|
148 |
+
* Construct
|
149 |
+
*
|
150 |
+
* @param string $client_id Client ID
|
151 |
+
* @param string $client_secret Client Secret
|
152 |
+
* @param int $client_auth (AUTH_TYPE_URI, AUTH_TYPE_AUTHORIZATION_BASIC, AUTH_TYPE_FORM)
|
153 |
+
* @param string $certificate_file Indicates if we want to use a certificate file to trust the server. Optional, defaults to null.
|
154 |
+
* @return void
|
155 |
+
*/
|
156 |
+
public function __construct($client_id, $client_secret, $client_auth = self::AUTH_TYPE_URI, $certificate_file = null)
|
157 |
+
{
|
158 |
+
if (!extension_loaded('curl')) {
|
159 |
+
throw new Exception('The PHP extension curl must be installed to use this library.', Exception::CURL_NOT_FOUND);
|
160 |
+
}
|
161 |
+
|
162 |
+
$this->client_id = $client_id;
|
163 |
+
$this->client_secret = $client_secret;
|
164 |
+
$this->client_auth = $client_auth;
|
165 |
+
$this->certificate_file = $certificate_file;
|
166 |
+
if (!empty($this->certificate_file) && !is_file($this->certificate_file)) {
|
167 |
+
throw new InvalidArgumentException('The certificate file was not found', InvalidArgumentException::CERTIFICATE_NOT_FOUND);
|
168 |
+
}
|
169 |
+
}
|
170 |
+
|
171 |
+
public function setLogFilePath($logFilePath)
|
172 |
+
{
|
173 |
+
$this->logFilePath = $logFilePath;
|
174 |
+
}
|
175 |
+
|
176 |
+
/**
|
177 |
+
* Get the client Id
|
178 |
+
*
|
179 |
+
* @return string Client ID
|
180 |
+
*/
|
181 |
+
public function getClientId()
|
182 |
+
{
|
183 |
+
return $this->client_id;
|
184 |
+
}
|
185 |
+
|
186 |
+
/**
|
187 |
+
* Get the client Secret
|
188 |
+
*
|
189 |
+
* @return string Client Secret
|
190 |
+
*/
|
191 |
+
public function getClientSecret()
|
192 |
+
{
|
193 |
+
return $this->client_secret;
|
194 |
+
}
|
195 |
+
|
196 |
+
/**
|
197 |
+
* getAuthenticationUrl
|
198 |
+
*
|
199 |
+
* @param string $auth_endpoint Url of the authentication endpoint
|
200 |
+
* @param string $redirect_uri Redirection URI
|
201 |
+
* @param array $extra_parameters Array of extra parameters like scope or state (Ex: array('scope' => null, 'state' => ''))
|
202 |
+
* @return string URL used for authentication
|
203 |
+
*/
|
204 |
+
public function getAuthenticationUrl($auth_endpoint, $redirect_uri, array $extra_parameters = array())
|
205 |
+
{
|
206 |
+
$parameters = array_merge(array(
|
207 |
+
'response_type' => 'code',
|
208 |
+
'client_id' => $this->client_id,
|
209 |
+
'redirect_uri' => $redirect_uri
|
210 |
+
), $extra_parameters);
|
211 |
+
return $auth_endpoint . '?' . http_build_query($parameters, null, '&');
|
212 |
+
}
|
213 |
+
|
214 |
+
/**
|
215 |
+
* getAccessToken
|
216 |
+
*
|
217 |
+
* @param string $token_endpoint Url of the token endpoint
|
218 |
+
* @param int $grant_type Grant Type ('authorization_code', 'password', 'client_credentials', 'refresh_token', or a custom code (@see GrantType Classes)
|
219 |
+
* @param array $parameters Array sent to the server (depend on which grant type you're using)
|
220 |
+
* @return array Array of parameters required by the grant_type (CF SPEC)
|
221 |
+
*/
|
222 |
+
public function getAccessToken($token_endpoint, $grant_type, array $parameters)
|
223 |
+
{
|
224 |
+
if (!$grant_type) {
|
225 |
+
throw new InvalidArgumentException('The grant_type is mandatory.', InvalidArgumentException::INVALID_GRANT_TYPE);
|
226 |
+
}
|
227 |
+
$grantTypeClassName = $this->convertToCamelCase($grant_type);
|
228 |
+
$grantTypeClass = __NAMESPACE__ . '\\GrantType\\' . $grantTypeClassName;
|
229 |
+
if (!class_exists($grantTypeClass)) {
|
230 |
+
throw new InvalidArgumentException('Unknown grant type \'' . $grant_type . '\'', InvalidArgumentException::INVALID_GRANT_TYPE);
|
231 |
+
}
|
232 |
+
$grantTypeObject = new $grantTypeClass();
|
233 |
+
$grantTypeObject->validateParameters($parameters);
|
234 |
+
if (!defined($grantTypeClass . '::GRANT_TYPE')) {
|
235 |
+
throw new Exception('Unknown constant GRANT_TYPE for class ' . $grantTypeClassName, Exception::GRANT_TYPE_ERROR);
|
236 |
+
}
|
237 |
+
$parameters['grant_type'] = $grantTypeClass::GRANT_TYPE;
|
238 |
+
$http_headers = array();
|
239 |
+
switch ($this->client_auth) {
|
240 |
+
case self::AUTH_TYPE_URI:
|
241 |
+
case self::AUTH_TYPE_FORM:
|
242 |
+
$parameters['client_id'] = $this->client_id;
|
243 |
+
$parameters['client_secret'] = $this->client_secret;
|
244 |
+
break;
|
245 |
+
case self::AUTH_TYPE_AUTHORIZATION_BASIC:
|
246 |
+
$parameters['client_id'] = $this->client_id;
|
247 |
+
$http_headers['Authorization'] = 'Basic ' . base64_encode($this->client_id . ':' . $this->client_secret);
|
248 |
+
break;
|
249 |
+
default:
|
250 |
+
throw new Exception('Unknown client auth type.', Exception::INVALID_CLIENT_AUTHENTICATION_TYPE);
|
251 |
+
break;
|
252 |
+
}
|
253 |
+
|
254 |
+
return $this->executeRequest($token_endpoint, $parameters, self::HTTP_METHOD_POST, $http_headers, self::HTTP_FORM_CONTENT_TYPE_APPLICATION);
|
255 |
+
}
|
256 |
+
|
257 |
+
/**
|
258 |
+
* setToken
|
259 |
+
*
|
260 |
+
* @param string $token Set the access token
|
261 |
+
* @return void
|
262 |
+
*/
|
263 |
+
public function setAccessToken($token)
|
264 |
+
{
|
265 |
+
$this->access_token = $token;
|
266 |
+
}
|
267 |
+
|
268 |
+
/**
|
269 |
+
* Set the client authentication type
|
270 |
+
*
|
271 |
+
* @param string $client_auth (AUTH_TYPE_URI, AUTH_TYPE_AUTHORIZATION_BASIC, AUTH_TYPE_FORM)
|
272 |
+
* @return void
|
273 |
+
*/
|
274 |
+
public function setClientAuthType($client_auth)
|
275 |
+
{
|
276 |
+
$this->client_auth = $client_auth;
|
277 |
+
}
|
278 |
+
|
279 |
+
/**
|
280 |
+
* Set an option for the curl transfer
|
281 |
+
*
|
282 |
+
* @param int $option The CURLOPT_XXX option to set
|
283 |
+
* @param mixed $value The value to be set on option
|
284 |
+
* @return void
|
285 |
+
*/
|
286 |
+
public function setCurlOption($option, $value)
|
287 |
+
{
|
288 |
+
$this->curl_options[$option] = $value;
|
289 |
+
}
|
290 |
+
|
291 |
+
/**
|
292 |
+
* Set multiple options for a cURL transfer
|
293 |
+
*
|
294 |
+
* @param array $options An array specifying which options to set and their values
|
295 |
+
* @return void
|
296 |
+
*/
|
297 |
+
public function setCurlOptions($options)
|
298 |
+
{
|
299 |
+
$this->curl_options = array_merge($this->curl_options, $options);
|
300 |
+
}
|
301 |
+
|
302 |
+
/**
|
303 |
+
* Set the access token type
|
304 |
+
*
|
305 |
+
* @param int $type Access token type (ACCESS_TOKEN_BEARER, ACCESS_TOKEN_MAC, ACCESS_TOKEN_URI)
|
306 |
+
* @param string $secret The secret key used to encrypt the MAC header
|
307 |
+
* @param string $algorithm Algorithm used to encrypt the signature
|
308 |
+
* @return void
|
309 |
+
*/
|
310 |
+
public function setAccessTokenType($type, $secret = null, $algorithm = null)
|
311 |
+
{
|
312 |
+
$this->access_token_type = $type;
|
313 |
+
$this->access_token_secret = $secret;
|
314 |
+
$this->access_token_algorithm = $algorithm;
|
315 |
+
}
|
316 |
+
|
317 |
+
/**
|
318 |
+
* Fetch a protected ressource
|
319 |
+
*
|
320 |
+
* @param string $protected_ressource_url Protected resource URL
|
321 |
+
* @param array $parameters Array of parameters
|
322 |
+
* @param string $http_method HTTP Method to use (POST, PUT, GET, HEAD, DELETE)
|
323 |
+
* @param array $http_headers HTTP headers
|
324 |
+
* @param int $form_content_type HTTP form content type to use
|
325 |
+
* @return array
|
326 |
+
*/
|
327 |
+
public function fetch($protected_resource_url, $parameters = array(), $http_method = self::HTTP_METHOD_GET, array $http_headers = array(), $form_content_type = self::HTTP_FORM_CONTENT_TYPE_MULTIPART)
|
328 |
+
{
|
329 |
+
if ($this->access_token) {
|
330 |
+
switch ($this->access_token_type) {
|
331 |
+
case self::ACCESS_TOKEN_URI:
|
332 |
+
if (is_array($parameters)) {
|
333 |
+
$parameters[$this->access_token_param_name] = $this->access_token;
|
334 |
+
} else {
|
335 |
+
throw new InvalidArgumentException(
|
336 |
+
'You need to give parameters as array if you want to give the token within the URI.',
|
337 |
+
InvalidArgumentException::REQUIRE_PARAMS_AS_ARRAY
|
338 |
+
);
|
339 |
+
}
|
340 |
+
break;
|
341 |
+
case self::ACCESS_TOKEN_BEARER:
|
342 |
+
$http_headers['Authorization'] = 'Bearer ' . $this->access_token;
|
343 |
+
break;
|
344 |
+
case self::ACCESS_TOKEN_OAUTH:
|
345 |
+
$http_headers['Authorization'] = 'OAuth ' . $this->access_token;
|
346 |
+
break;
|
347 |
+
case self::ACCESS_TOKEN_MAC:
|
348 |
+
$http_headers['Authorization'] = 'MAC ' . $this->generateMACSignature($protected_resource_url, $parameters, $http_method);
|
349 |
+
break;
|
350 |
+
default:
|
351 |
+
throw new Exception('Unknown access token type.', Exception::INVALID_ACCESS_TOKEN_TYPE);
|
352 |
+
break;
|
353 |
+
}
|
354 |
+
}
|
355 |
+
return $this->executeRequest($protected_resource_url, $parameters, $http_method, $http_headers, $form_content_type);
|
356 |
+
}
|
357 |
+
|
358 |
+
/**
|
359 |
+
* Generate the MAC signature
|
360 |
+
*
|
361 |
+
* @param string $url Called URL
|
362 |
+
* @param array $parameters Parameters
|
363 |
+
* @param string $http_method Http Method
|
364 |
+
* @return string
|
365 |
+
*/
|
366 |
+
private function generateMACSignature($url, $parameters, $http_method)
|
367 |
+
{
|
368 |
+
$timestamp = time();
|
369 |
+
$nonce = uniqid();
|
370 |
+
$parsed_url = parse_url($url);
|
371 |
+
if (!isset($parsed_url['port']))
|
372 |
+
{
|
373 |
+
$parsed_url['port'] = ($parsed_url['scheme'] == 'https') ? 443 : 80;
|
374 |
+
}
|
375 |
+
if ($http_method == self::HTTP_METHOD_GET) {
|
376 |
+
if (is_array($parameters)) {
|
377 |
+
$parsed_url['path'] .= '?' . http_build_query($parameters, null, '&');
|
378 |
+
} elseif ($parameters) {
|
379 |
+
$parsed_url['path'] .= '?' . $parameters;
|
380 |
+
}
|
381 |
+
}
|
382 |
+
|
383 |
+
$signature = base64_encode(hash_hmac($this->access_token_algorithm,
|
384 |
+
$timestamp . "\n"
|
385 |
+
. $nonce . "\n"
|
386 |
+
. $http_method . "\n"
|
387 |
+
. $parsed_url['path'] . "\n"
|
388 |
+
. $parsed_url['host'] . "\n"
|
389 |
+
. $parsed_url['port'] . "\n\n"
|
390 |
+
, $this->access_token_secret, true));
|
391 |
+
|
392 |
+
return 'id="' . $this->access_token . '", ts="' . $timestamp . '", nonce="' . $nonce . '", mac="' . $signature . '"';
|
393 |
+
}
|
394 |
+
|
395 |
+
/**
|
396 |
+
* Execute a request (with curl)
|
397 |
+
*
|
398 |
+
* @param string $url URL
|
399 |
+
* @param mixed $parameters Array of parameters
|
400 |
+
* @param string $http_method HTTP Method
|
401 |
+
* @param array $http_headers HTTP Headers
|
402 |
+
* @param int $form_content_type HTTP form content type to use
|
403 |
+
* @return array
|
404 |
+
*/
|
405 |
+
private function executeRequest($url, $parameters = array(), $http_method = self::HTTP_METHOD_GET, array $http_headers = null, $form_content_type = self::HTTP_FORM_CONTENT_TYPE_MULTIPART)
|
406 |
+
{
|
407 |
+
$curl_options = array(
|
408 |
+
CURLOPT_RETURNTRANSFER => true,
|
409 |
+
CURLOPT_SSL_VERIFYPEER => true,
|
410 |
+
CURLOPT_CUSTOMREQUEST => $http_method
|
411 |
+
);
|
412 |
+
|
413 |
+
switch($http_method) {
|
414 |
+
case self::HTTP_METHOD_POST:
|
415 |
+
$curl_options[CURLOPT_POST] = true;
|
416 |
+
/* No break */
|
417 |
+
case self::HTTP_METHOD_PUT:
|
418 |
+
case self::HTTP_METHOD_PATCH:
|
419 |
+
|
420 |
+
/**
|
421 |
+
* Passing an array to CURLOPT_POSTFIELDS will encode the data as multipart/form-data,
|
422 |
+
* while passing a URL-encoded string will encode the data as application/x-www-form-urlencoded.
|
423 |
+
* http://php.net/manual/en/function.curl-setopt.php
|
424 |
+
*/
|
425 |
+
if(is_array($parameters) && self::HTTP_FORM_CONTENT_TYPE_APPLICATION === $form_content_type) {
|
426 |
+
$parameters = http_build_query($parameters, null, '&');
|
427 |
+
}
|
428 |
+
else if (self::HTTP_FORM_CONTENT_JSON === $form_content_type) {
|
429 |
+
$http_headers['Content-Type'] = 'application/json';
|
430 |
+
}
|
431 |
+
$curl_options[CURLOPT_POSTFIELDS] = $parameters;
|
432 |
+
break;
|
433 |
+
case self::HTTP_METHOD_HEAD:
|
434 |
+
$curl_options[CURLOPT_NOBODY] = true;
|
435 |
+
/* No break */
|
436 |
+
case self::HTTP_METHOD_DELETE:
|
437 |
+
case self::HTTP_METHOD_GET:
|
438 |
+
if (is_array($parameters)) {
|
439 |
+
$url .= '?' . http_build_query($parameters, null, '&');
|
440 |
+
} elseif ($parameters) {
|
441 |
+
$url .= '?' . $parameters;
|
442 |
+
}
|
443 |
+
break;
|
444 |
+
default:
|
445 |
+
break;
|
446 |
+
}
|
447 |
+
|
448 |
+
$curl_options[CURLOPT_URL] = $url;
|
449 |
+
|
450 |
+
if (is_array($http_headers)) {
|
451 |
+
$header = array();
|
452 |
+
foreach($http_headers as $key => $parsed_urlvalue) {
|
453 |
+
$header[] = "$key: $parsed_urlvalue";
|
454 |
+
}
|
455 |
+
$curl_options[CURLOPT_HTTPHEADER] = $header;
|
456 |
+
}
|
457 |
+
|
458 |
+
$ch = curl_init();
|
459 |
+
curl_setopt_array($ch, $curl_options);
|
460 |
+
// https handling
|
461 |
+
if (!empty($this->certificate_file)) {
|
462 |
+
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, true);
|
463 |
+
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
|
464 |
+
curl_setopt($ch, CURLOPT_CAINFO, $this->certificate_file);
|
465 |
+
} else {
|
466 |
+
// bypass ssl verification
|
467 |
+
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
|
468 |
+
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);
|
469 |
+
}
|
470 |
+
if (!empty($this->curl_options)) {
|
471 |
+
curl_setopt_array($ch, $this->curl_options);
|
472 |
+
}
|
473 |
+
$fh = null;
|
474 |
+
if (strlen($this->logFilePath)) {
|
475 |
+
$fh = fopen($this->logFilePath, "a+");
|
476 |
+
fwrite($fh, "Curl verbose output:\n");
|
477 |
+
curl_setopt($ch, CURLOPT_VERBOSE, true);
|
478 |
+
curl_setopt($ch, CURLOPT_STDERR, $fh);
|
479 |
+
}
|
480 |
+
$result = curl_exec($ch);
|
481 |
+
if (strlen($this->logFilePath)) {
|
482 |
+
fclose($fh);
|
483 |
+
}
|
484 |
+
$http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);
|
485 |
+
$content_type = curl_getinfo($ch, CURLINFO_CONTENT_TYPE);
|
486 |
+
if ($curl_error = curl_error($ch)) {
|
487 |
+
throw new Exception($curl_error, Exception::CURL_ERROR);
|
488 |
+
} else {
|
489 |
+
$json_decode = json_decode($result, true);
|
490 |
+
}
|
491 |
+
curl_close($ch);
|
492 |
+
|
493 |
+
return array(
|
494 |
+
'result' => (null === $json_decode) ? $result : $json_decode,
|
495 |
+
'code' => $http_code,
|
496 |
+
'content_type' => $content_type
|
497 |
+
);
|
498 |
+
}
|
499 |
+
|
500 |
+
/**
|
501 |
+
* Set the name of the parameter that carry the access token
|
502 |
+
*
|
503 |
+
* @param string $name Token parameter name
|
504 |
+
* @return void
|
505 |
+
*/
|
506 |
+
public function setAccessTokenParamName($name)
|
507 |
+
{
|
508 |
+
$this->access_token_param_name = $name;
|
509 |
+
}
|
510 |
+
|
511 |
+
/**
|
512 |
+
* Converts the class name to camel case
|
513 |
+
*
|
514 |
+
* @param mixed $grant_type the grant type
|
515 |
+
* @return string
|
516 |
+
*/
|
517 |
+
private function convertToCamelCase($grant_type)
|
518 |
+
{
|
519 |
+
$parts = explode('_', $grant_type);
|
520 |
+
array_walk($parts, function(&$item) { $item = ucfirst($item);});
|
521 |
+
return implode('', $parts);
|
522 |
+
}
|
523 |
+
}
|
524 |
+
|
525 |
+
class Exception extends \Exception
|
526 |
+
{
|
527 |
+
const CURL_NOT_FOUND = 0x01;
|
528 |
+
const CURL_ERROR = 0x02;
|
529 |
+
const GRANT_TYPE_ERROR = 0x03;
|
530 |
+
const INVALID_CLIENT_AUTHENTICATION_TYPE = 0x04;
|
531 |
+
const INVALID_ACCESS_TOKEN_TYPE = 0x05;
|
532 |
+
}
|
533 |
+
|
534 |
+
class InvalidArgumentException extends \InvalidArgumentException
|
535 |
+
{
|
536 |
+
const INVALID_GRANT_TYPE = 0x01;
|
537 |
+
const CERTIFICATE_NOT_FOUND = 0x02;
|
538 |
+
const REQUIRE_PARAMS_AS_ARRAY = 0x03;
|
539 |
+
const MISSING_PARAMETER = 0x04;
|
540 |
+
}
|
lib/OAuth2/GrantType/AuthorizationCode.php
ADDED
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
namespace OAuth2\GrantType;
|
3 |
+
|
4 |
+
use OAuth2\InvalidArgumentException;
|
5 |
+
|
6 |
+
/**
|
7 |
+
* Authorization code Grant Type Validator
|
8 |
+
*/
|
9 |
+
class AuthorizationCode implements IGrantType
|
10 |
+
{
|
11 |
+
/**
|
12 |
+
* Defines the Grant Type
|
13 |
+
*
|
14 |
+
* @var string Defaults to 'authorization_code'.
|
15 |
+
*/
|
16 |
+
const GRANT_TYPE = 'authorization_code';
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Adds a specific Handling of the parameters
|
20 |
+
*
|
21 |
+
* @return array of Specific parameters to be sent.
|
22 |
+
* @param mixed $parameters the parameters array (passed by reference)
|
23 |
+
*/
|
24 |
+
public function validateParameters(&$parameters)
|
25 |
+
{
|
26 |
+
if (!isset($parameters['code']))
|
27 |
+
{
|
28 |
+
throw new InvalidArgumentException(
|
29 |
+
'The \'code\' parameter must be defined for the Authorization Code grant type',
|
30 |
+
InvalidArgumentException::MISSING_PARAMETER
|
31 |
+
);
|
32 |
+
}
|
33 |
+
elseif (!isset($parameters['redirect_uri']))
|
34 |
+
{
|
35 |
+
throw new InvalidArgumentException(
|
36 |
+
'The \'redirect_uri\' parameter must be defined for the Authorization Code grant type',
|
37 |
+
InvalidArgumentException::MISSING_PARAMETER
|
38 |
+
);
|
39 |
+
}
|
40 |
+
}
|
41 |
+
}
|
lib/OAuth2/GrantType/ClientCredentials.php
ADDED
@@ -0,0 +1,25 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
namespace OAuth2\GrantType;
|
3 |
+
|
4 |
+
/**
|
5 |
+
* Client Credentials Parameters
|
6 |
+
*/
|
7 |
+
class ClientCredentials implements IGrantType
|
8 |
+
{
|
9 |
+
/**
|
10 |
+
* Defines the Grant Type
|
11 |
+
*
|
12 |
+
* @var string Defaults to 'client_credentials'.
|
13 |
+
*/
|
14 |
+
const GRANT_TYPE = 'client_credentials';
|
15 |
+
|
16 |
+
/**
|
17 |
+
* Adds a specific Handling of the parameters
|
18 |
+
*
|
19 |
+
* @return array of Specific parameters to be sent.
|
20 |
+
* @param mixed $parameters the parameters array (passed by reference)
|
21 |
+
*/
|
22 |
+
public function validateParameters(&$parameters)
|
23 |
+
{
|
24 |
+
}
|
25 |
+
}
|
lib/OAuth2/GrantType/IGrantType.php
ADDED
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
namespace OAuth2\GrantType;
|
3 |
+
/**
|
4 |
+
* Specific GrantType Interface
|
5 |
+
*/
|
6 |
+
interface IGrantType
|
7 |
+
{
|
8 |
+
/**
|
9 |
+
* Adds a specific Handling of the parameters
|
10 |
+
*
|
11 |
+
* @return array of Specific parameters to be sent.
|
12 |
+
* @param mixed $parameters the parameters array (passed by reference)
|
13 |
+
*/
|
14 |
+
public function validateParameters(&$parameters);
|
15 |
+
}
|
lib/OAuth2/GrantType/Password.php
ADDED
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
namespace OAuth2\GrantType;
|
3 |
+
|
4 |
+
use OAuth2\InvalidArgumentException;
|
5 |
+
|
6 |
+
/**
|
7 |
+
* Password Parameters
|
8 |
+
*/
|
9 |
+
class Password implements IGrantType
|
10 |
+
{
|
11 |
+
/**
|
12 |
+
* Defines the Grant Type
|
13 |
+
*
|
14 |
+
* @var string Defaults to 'password'.
|
15 |
+
*/
|
16 |
+
const GRANT_TYPE = 'password';
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Adds a specific Handling of the parameters
|
20 |
+
*
|
21 |
+
* @return array of Specific parameters to be sent.
|
22 |
+
* @param mixed $parameters the parameters array (passed by reference)
|
23 |
+
*/
|
24 |
+
public function validateParameters(&$parameters)
|
25 |
+
{
|
26 |
+
if (!isset($parameters['username']))
|
27 |
+
{
|
28 |
+
throw new InvalidArgumentException(
|
29 |
+
'The \'username\' parameter must be defined for the Password grant type',
|
30 |
+
InvalidArgumentException::MISSING_PARAMETER
|
31 |
+
);
|
32 |
+
}
|
33 |
+
elseif (!isset($parameters['password']))
|
34 |
+
{
|
35 |
+
throw new InvalidArgumentException(
|
36 |
+
'The \'password\' parameter must be defined for the Password grant type',
|
37 |
+
InvalidArgumentException::MISSING_PARAMETER
|
38 |
+
);
|
39 |
+
}
|
40 |
+
}
|
41 |
+
}
|
lib/OAuth2/GrantType/RefreshToken.php
ADDED
@@ -0,0 +1,34 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
namespace OAuth2\GrantType;
|
3 |
+
|
4 |
+
use OAuth2\InvalidArgumentException;
|
5 |
+
|
6 |
+
/**
|
7 |
+
* Refresh Token Parameters
|
8 |
+
*/
|
9 |
+
class RefreshToken implements IGrantType
|
10 |
+
{
|
11 |
+
/**
|
12 |
+
* Defines the Grant Type
|
13 |
+
*
|
14 |
+
* @var string Defaults to 'refresh_token'.
|
15 |
+
*/
|
16 |
+
const GRANT_TYPE = 'refresh_token';
|
17 |
+
|
18 |
+
/**
|
19 |
+
* Adds a specific Handling of the parameters
|
20 |
+
*
|
21 |
+
* @return array of Specific parameters to be sent.
|
22 |
+
* @param mixed $parameters the parameters array (passed by reference)
|
23 |
+
*/
|
24 |
+
public function validateParameters(&$parameters)
|
25 |
+
{
|
26 |
+
if (!isset($parameters['refresh_token']))
|
27 |
+
{
|
28 |
+
throw new InvalidArgumentException(
|
29 |
+
'The \'refresh_token\' parameter must be defined for the refresh token grant type',
|
30 |
+
InvalidArgumentException::MISSING_PARAMETER
|
31 |
+
);
|
32 |
+
}
|
33 |
+
}
|
34 |
+
}
|
lib/OAuth2/README
ADDED
@@ -0,0 +1,117 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
___________________________________
|
2 |
+
|
3 |
+
Light PHP wrapper for the OAuth 2.0
|
4 |
+
___________________________________
|
5 |
+
|
6 |
+
|
7 |
+
AUTHOR & CONTACT
|
8 |
+
================
|
9 |
+
|
10 |
+
Charron Pierrick
|
11 |
+
- pierrick@webstart.fr
|
12 |
+
|
13 |
+
Berejeb Anis
|
14 |
+
- anis.berejeb@gmail.com
|
15 |
+
|
16 |
+
|
17 |
+
DOCUMENTATION & DOWNLOAD
|
18 |
+
========================
|
19 |
+
|
20 |
+
Latest version is available on github at :
|
21 |
+
- https://github.com/adoy/PHP-OAuth2
|
22 |
+
|
23 |
+
Documentation can be found on :
|
24 |
+
- https://github.com/adoy/PHP-OAuth2
|
25 |
+
|
26 |
+
|
27 |
+
LICENSE
|
28 |
+
=======
|
29 |
+
|
30 |
+
This Code is released under the GNU LGPL
|
31 |
+
|
32 |
+
Please do not change the header of the file(s).
|
33 |
+
|
34 |
+
This library is free software; you can redistribute it and/or modify it
|
35 |
+
under the terms of the GNU Lesser General Public License as published
|
36 |
+
by the Free Software Foundation; either version 2 of the License, or
|
37 |
+
(at your option) any later version.
|
38 |
+
|
39 |
+
This library is distributed in the hope that it will be useful, but
|
40 |
+
WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
41 |
+
or FITNESS FOR A PARTICULAR PURPOSE.
|
42 |
+
|
43 |
+
See the GNU Lesser General Public License for more details.
|
44 |
+
|
45 |
+
|
46 |
+
How can I use it ?
|
47 |
+
==================
|
48 |
+
|
49 |
+
require('client.php');
|
50 |
+
require('GrantType/IGrantType.php');
|
51 |
+
require('GrantType/AuthorizationCode.php');
|
52 |
+
|
53 |
+
const CLIENT_ID = 'your client id';
|
54 |
+
const CLIENT_SECRET = 'your client secret';
|
55 |
+
|
56 |
+
const REDIRECT_URI = 'http://url/of/this.php';
|
57 |
+
const AUTHORIZATION_ENDPOINT = 'https://graph.facebook.com/oauth/authorize';
|
58 |
+
const TOKEN_ENDPOINT = 'https://graph.facebook.com/oauth/access_token';
|
59 |
+
|
60 |
+
$client = new OAuth2\Client(CLIENT_ID, CLIENT_SECRET);
|
61 |
+
if (!isset($_GET['code']))
|
62 |
+
{
|
63 |
+
$auth_url = $client->getAuthenticationUrl(AUTHORIZATION_ENDPOINT, REDIRECT_URI);
|
64 |
+
header('Location: ' . $auth_url);
|
65 |
+
die('Redirect');
|
66 |
+
}
|
67 |
+
else
|
68 |
+
{
|
69 |
+
$params = array('code' => $_GET['code'], 'redirect_uri' => REDIRECT_URI);
|
70 |
+
$response = $client->getAccessToken(TOKEN_ENDPOINT, 'authorization_code', $params);
|
71 |
+
parse_str($response['result'], $info);
|
72 |
+
$client->setAccessToken($info['access_token']);
|
73 |
+
$response = $client->fetch('https://graph.facebook.com/me');
|
74 |
+
var_dump($response, $response['result']);
|
75 |
+
}
|
76 |
+
|
77 |
+
How can I add a new Grant Type ?
|
78 |
+
================================
|
79 |
+
Simply write a new class in the namespace OAuth2\GrantType. You can place the class file under GrantType.
|
80 |
+
Here is an example :
|
81 |
+
|
82 |
+
namespace OAuth2\GrantType;
|
83 |
+
|
84 |
+
/**
|
85 |
+
* MyCustomGrantType Grant Type
|
86 |
+
*/
|
87 |
+
class MyCustomGrantType implements IGrantType
|
88 |
+
{
|
89 |
+
/**
|
90 |
+
* Defines the Grant Type
|
91 |
+
*
|
92 |
+
* @var string Defaults to 'my_custom_grant_type'.
|
93 |
+
*/
|
94 |
+
const GRANT_TYPE = 'my_custom_grant_type';
|
95 |
+
|
96 |
+
/**
|
97 |
+
* Adds a specific Handling of the parameters
|
98 |
+
*
|
99 |
+
* @return array of Specific parameters to be sent.
|
100 |
+
* @param mixed $parameters the parameters array (passed by reference)
|
101 |
+
*/
|
102 |
+
public function validateParameters(&$parameters)
|
103 |
+
{
|
104 |
+
if (!isset($parameters['first_mandatory_parameter']))
|
105 |
+
{
|
106 |
+
throw new \Exception('The \'first_mandatory_parameter\' parameter must be defined for the Password grant type');
|
107 |
+
}
|
108 |
+
elseif (!isset($parameters['second_mandatory_parameter']))
|
109 |
+
{
|
110 |
+
throw new \Exception('The \'seconde_mandatory_parameter\' parameter must be defined for the Password grant type');
|
111 |
+
}
|
112 |
+
}
|
113 |
+
}
|
114 |
+
|
115 |
+
call the OAuth client getAccessToken with the grantType you defined in the GRANT_TYPE constant, As following :
|
116 |
+
$response = $client->getAccessToken(TOKEN_ENDPOINT, 'my_custom_grant_type', $params);
|
117 |
+
|
package.xml
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<package>
|
3 |
+
<name>SFC_Autoship</name>
|
4 |
+
<version>1.3.1.14</version>
|
5 |
+
<stability>stable</stability>
|
6 |
+
<license uri="http://www.subscribepro.com/terms-of-service/">SFC Commercial Software License</license>
|
7 |
+
<channel>community</channel>
|
8 |
+
<extends/>
|
9 |
+
<summary>Manage your auto-ship program, customer subscription payments and recurring billing transactions to optimize customer retention and recurring revenue.</summary>
|
10 |
+
<description>Manage your auto-ship program, customer subscription payments and recurring billing transactions to optimize customer retention and recurring revenue. The Subscribe Pro Extension for Magento allows you to easily implement subscriptions and recurring billing on your Magento website. Our extension is fully integrated into Magento and allows you to acquire and manage subscription customers directly in the Magento admin panel.</description>
|
11 |
+
<notes>Subscribe Pro Extension Release</notes>
|
12 |
+
<authors><author><name>Subscribe Pro</name><user>SF_Consulting</user><email>support@subscribepro.com</email></author></authors>
|
13 |
+
<date>2015-03-16</date>
|
14 |
+
<time>12:57:34</time>
|
15 |
+
<contents><target name="magelocal"><dir name="SFC"><dir name="Autoship"><dir name="Block"><dir name="Adminhtml"><dir name="Customer"><dir name="Paymentprofiles"><dir name="Edit"><file name="Form.php" hash="c64c65b46cc2a3d8b11c5632dc3b169c"/><dir name="Tab"><file name="Form.php" hash="808488ab5e15da6d0461b7d61f687a78"/></dir><file name="Tabs.php" hash="e6dd26321da4e4bd5ab3614ed6c21478"/></dir><file name="Edit.php" hash="bd3f2cda0476d7ce51021e065c990588"/><file name="Paymentprofile.php" hash="20962c72c68599247da372120ed532de"/></dir></dir><dir name="Sales"><dir name="Order"><dir name="Create"><file name="Jsonp.php" hash="ffe4ba6b40a53fee4a9fafe775d58858"/></dir></dir></dir><dir name="System"><dir name="Config"><dir name="Form"><file name="TestConnectionButton.php" hash="50eb2f3f1938cdda0d50ae88aece3318"/></dir></dir></dir></dir><dir name="Cart"><dir name="Product"><file name="Subscription.php" hash="7717c4a4f95b8fa453cdf9b36f0a297b"/></dir></dir><dir name="Checkout"><file name="Jsonp.php" hash="9e061e2c21f8cfab1aad9993239d5f8e"/><dir name="Onepage"><dir name="Payment"><file name="Methods.php" hash="3ca6cf9fe1eee61f520d629682870e9c"/></dir></dir></dir><dir name="Mysubscriptions"><dir name="Subscription"><dir name="Form"><file name="Billing.php" hash="b5a13e45b069412c6b3f17f5fa0b92c0"/><file name="Payment.php" hash="3b04e1aafd85089add3c88ce78687825"/><file name="Shipping.php" hash="0bf4cd339016a265dc33344158d05858"/></dir></dir><file name="Subscription.php" hash="d1e46fae138f348622b90836a77d2110"/></dir><file name="Mysubscriptions.php" hash="14430c0eaa005a77af7baaab6611303f"/><dir name="Newsubscription"><dir name="Form"><file name="Billing.php" hash="5f6215847e07dcf70a72804b4e8d351c"/><file name="Payment.php" hash="dac0b8db0bd401f2a57ba81af7d0150d"/><file name="Shipping.php" hash="6fde0265466e927309a9085239c5f817"/></dir></dir><file name="Newsubscription.php" hash="6377f729e6df8c5485b32e042a2abb5c"/><dir name="Payment"><dir name="Form"><dir name="Cc"><file name="Saved.php" hash="316e6954dfabbc6d141cf16c49459cc6"/></dir><file name="Cc.php" hash="6ab5676c3419b474efb9723a5712cea2"/></dir><dir name="Info"><file name="Cc.php" hash="69d3cb6b421e60534797ddde9335d542"/></dir><dir name="Profile"><file name="Edit.php" hash="edd5ed6b9b8b3435406e4fbeb37fd0ae"/><file name="Grid.php" hash="5da491d7db12b5ccbe7a3bbcee33d057"/></dir></dir><dir name="Product"><file name="Subscribe.php" hash="19c516250680f6fe59e5e04270c02a6a"/><dir name="View"><dir name="Type"><dir name="Grouped"><file name="Subscribe.php" hash="8a2d2308b3f762a2b2921a6d19a413ab"/></dir></dir></dir><file name="View.php" hash="8e1a840a51f260ada0a2910abd425d70"/></dir><dir name="Subscription"><file name="Abstract.php" hash="1dc9227bf03ea0475da81e51965d6188"/><dir name="Form"><file name="Address.php" hash="644c0f94434001f8bd228ed0d80bfff9"/><file name="Payment.php" hash="48e9ab07da4c18d5322a839217a42d2f"/></dir></dir></dir><dir name="Helper"><file name="Adminorder.php" hash="5517124d31b890466cb4d97f04e1c2ce"/><file name="Api.php" hash="9e99b7fc579075b1701c2d99e6223ec1"/><file name="Data.php" hash="d13d83754c73ce649d4d069218a0e5a8"/><file name="Payment.php" hash="1ba8a44a7b2b9d73e3a6e306aac73f6c"/><dir name="PaymentError"><file name="Exception.php" hash="2e180a089c0b515541e5cb474d09287d"/></dir><file name="PaymentError.php" hash="4c41a5364947465f9aa49068dbb7914a"/><file name="Platform.php" hash="8dd3d61e2eedc80e76d25db2d57ec315"/><file name="Product.php" hash="6938f12f5819c8657b9fcc799fabd092"/><file name="Quote.php" hash="6d6659c4f88be2531e933d843b50a67b"/><file name="Schedule.php" hash="3e0deaad918d79faaf680f2bed5747a3"/><file name="Subscription.php" hash="584657fecca929b441cd7ba00207ed60"/><file name="Vault.php" hash="aa84e073ffd3d41894f3ec81cc61e579"/></dir><dir name="Model"><dir name="Checkout"><dir name="Cart"><file name="Api.php" hash="f9795a0c99c2280ab221966829b71fa4"/><dir name="Payment"><file name="Api.php" hash="acafac3a776ae2005c41cb0f2ca20d08"/></dir><dir name="Product"><file name="Api.php" hash="9a79b630a2775740abbf2e633fbae8f7"/></dir></dir></dir><dir name="Mysql4"><dir name="Subscription"><file name="Collection.php" hash="e566798b4e8e7326709653ff538b8ee7"/></dir><file name="Subscription.php" hash="65e44a52dd1d6aff8b6acd2675f07ec0"/></dir><file name="Observer.php" hash="b1f4414bf08bffde8e72f052f41bd39a"/><dir name="Payment"><file name="Method.php" hash="262483defd5f7d237d2a700c6d0176e0"/><dir name="Profile"><file name="Address.php" hash="e912f0fdc9708b6b0811f0f85ffe7074"/><file name="Collection.php" hash="b0a5b730b83d5f36eaf29e3a98a99451"/></dir><file name="Profile.php" hash="b7ee1d8e70c2d2f917c8c180837ce3e1"/></dir><dir name="Paypal"><file name="Express.php" hash="eaa56b097a3123966c4a79efb9c9d802"/></dir><dir name="Platform"><file name="Product.php" hash="f7a56c3d4ddef27f9b60509d045295b0"/></dir><dir name="Quote"><file name="Address.php" hash="d00635f5ace4229a8f05417d45c9dad7"/></dir><dir name="SalesRule"><dir name="Rule"><dir name="Condition"><file name="Product.php" hash="d02ad2a5f3048a2e032154a093e568a4"/></dir></dir><file name="Validator.php" hash="6339bb28a3605b724cf3f4b35c0fd471"/></dir><file name="Subscription.php" hash="398ff49ffa9db6b2f10c4eaa150f0f47"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Cartrulediscountcombinetype.php" hash="9cb608bce8527a96c84013b93eec08e9"/><file name="Cctype.php" hash="d6a6e9850f528b87a3195d857a101f88"/><file name="Month.php" hash="4e4a684bea68d309ffab906eb48be98b"/><file name="Nextorderdatemode.php" hash="0150cb3b0a67d81ccaf25e8c59aab91e"/><file name="Shippingmethods.php" hash="3db5dc237d86fdca4a81521aec0685d0"/><file name="Year.php" hash="f33a16ad0a463c89e260570b55bec4b5"/></dir></dir></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="PaymentprofileController.php" hash="7e91286582d52b2d1f2cd9cc7fb8512a"/><file name="TestconnectionbuttonController.php" hash="03825956ea5572502d0b7a55b89364a2"/></dir><file name="MycreditcardsController.php" hash="a6eb9bd3f26e6a3307fe68880e587eee"/><file name="MysubscriptionsController.php" hash="2f33c17252abc1f67397c0d5295ac6e9"/><file name="NewsubscriptionController.php" hash="7c086583a232d25005715bc3dc98bae9"/></dir><dir name="etc"><file name="adminhtml.xml" hash="c3d897eeddef7b2f04c8d35888b44f2a"/><file name="config.xml" hash="facbee8bf371decf9f3dc7545b641933"/><file name="system.xml" hash="dc040748842b21f3a283d82a223d0c8c"/></dir><dir name="sql"><dir name="sfc_autoship_setup"><file name="mysql4-install-1.3.1.8.php" hash="2b48c8075b4888b04251c98bb78ec002"/><file name="mysql4-uninstall-1.3.1.4.php" hash="1e00347d1040b76a65f34158bcc17874"/><file name="mysql4-upgrade-1.1.0-1.1.1.php" hash="975d72d3c954cd635e9ed71852eb604c"/><file name="mysql4-upgrade-1.1.2-1.2.0.php" hash="2a9f3c6d8043a7fd230fea8bb6e14f47"/><file name="mysql4-upgrade-1.2.2.1-1.2.2.2.php" hash="f1332f7a473196b790fb6a15b60801cd"/><file name="mysql4-upgrade-1.2.3-1.2.4.php" hash="86ab8f0f0ea4830dcc0c6f20cbece8b7"/><file name="mysql4-upgrade-1.2.4.6-1.2.4.7.php" hash="5ad183dfc8a53b84650e27701b296716"/><file name="mysql4-upgrade-1.3.0.1-1.3.0.2.php" hash="457a5611a2f927a376dfed3a3d5e40be"/><file name="mysql4-upgrade-1.3.0.5-1.3.1.0.php" hash="d21a249dd1986a61bd8198fe3dd9545d"/><file name="mysql4-upgrade-1.3.1.3-1.3.1.4.php" hash="a55cc5b8b023cb2f9fae602c7a087421"/><file name="mysql4-upgrade-1.3.1.4-1.3.1.5.php" hash="bd54231d4bff0371503799f1012926f9"/><file name="mysql4-upgrade-1.3.1.7-1.3.1.8.php" hash="d89e730e526d2667d7d18b3b1cb6ca5a"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="SFC_Autoship.xml" hash="35cd3f244a2b3249057c4c1790538f35"/></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="autoship.xml" hash="1a90fee16782ba0cd90fc7afbfaa0823"/></dir><dir name="template"><dir name="autoship"><dir name="cart"><dir name="product"><file name="subscription.phtml" hash="af3ccb36effdaf3915724fc37bf21f1e"/></dir></dir><dir name="checkout"><file name="jsonp.phtml" hash="4b4b0bcb1383e6a19079d8ed7b3e5461"/><file name="serversideapi.phtml" hash="ee841b58e10d5bad42f11086df8f1c21"/><file name="success.phtml" hash="3dcb75efb73cc6c60016489517e6e6bb"/></dir><dir name="mysubscriptions"><dir name="subscription"><file name="actions.phtml" hash="40b91f8fe968cc28bb4d3b7b8bc76806"/><file name="billing_address.phtml" hash="c73fb08c44aac3d1518f26fa91489697"/><file name="payment.phtml" hash="2ac49da7dff23c54e4bbc8d2deee48f2"/><file name="product_info.phtml" hash="d036cbd12a4e754131ca25ea17ca1bb3"/><file name="shipping_address.phtml" hash="00c06e51b6c2317113bfdffb020be80b"/><file name="subscription_info.phtml" hash="1779ef3bebcbb955779acd78d0254991"/></dir><file name="subscription.phtml" hash="fc4379c5da4ed70fae9610cbd9e971c0"/></dir><file name="mysubscriptions.phtml" hash="b91d072e75eadaa033b19922dafbb047"/><dir name="newsubscription"><file name="ajax_update.phtml" hash="6165fe63bfd32e11319fba40f23fd6cf"/><file name="billing_address.phtml" hash="2fe25de0e084f4e850a2cdaa9ab64fee"/><file name="delivery_date.phtml" hash="a937bb32c4900b9650cc903662ecc5a9"/><file name="delivery_frequency.phtml" hash="53090ce31858558232f50e052bbd7028"/><file name="payment.phtml" hash="add40caa322b065b60c18a0754280b64"/><file name="product_info.phtml" hash="46b2419447f9ec7cc67c110f932e7f8b"/><file name="shipping_address.phtml" hash="4df7ce0979941cb358f479096f2598cb"/><file name="summary.phtml" hash="14e00d67a4e97df262a9c676eb699602"/></dir><file name="newsubscription.phtml" hash="9c81b0c8b8cc205bb33b83ba774c2bd2"/><dir name="payment"><dir name="form"><file name="cc.phtml" hash="51f946cc57fa877385d6792fa023407f"/><file name="cc_saved.phtml" hash="fa85460bc2bef4e00760cfeb52cf8386"/></dir><dir name="profile"><file name="edit.phtml" hash="e539648eaa66efe56ea5ef8fc1f74e92"/><file name="grid.phtml" hash="d77360eeb0c769d09a58deebbf87869f"/><file name="new.phtml" hash="0c99c60c7ff9929f104d2cfc855ad620"/></dir></dir><dir name="product"><file name="subscribe.phtml" hash="eb1d185006a9b16af96ccf99492dd0b6"/><dir name="view"><file name="addtocart.phtml" hash="90cc1bc0fabf84eafd7ee948710139e1"/><dir name="type"><dir name="grouped"><file name="subscribe.phtml" hash="db5b9d3c84808e0120636c6b6d1235b3"/></dir></dir></dir></dir><dir name="subscription"><dir name="form"><file name="billing.phtml" hash="e381ce871a7fb1ee1ad685c780abf5d8"/><file name="payment.phtml" hash="e958ddd4a6dd15008c4a1d8a4d8d439d"/><file name="shipping.phtml" hash="51db842d7a7ed560a27aa1cc188ea179"/></dir></dir></dir></dir></dir></dir><dir name="enterprise"><dir name="default"><dir name="layout"><file name="autoship.xml" hash="1a90fee16782ba0cd90fc7afbfaa0823"/></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="autoship.xml" hash="f02dedf9c2e9de305528fcc9fc3307fc"/></dir><dir name="template"><dir name="autoship"><dir name="payment"><dir name="form"><file name="cc.phtml" hash="5c8c404c91a83252bffb40e7788323c9"/><file name="cc_saved.phtml" hash="72ef34ae9fd9be0314c8dfe351654d01"/></dir></dir><dir name="sales"><dir name="create_order"><file name="jsonp.phtml" hash="b507e2f4d74312f7f8a3ea220634f49e"/></dir></dir><dir name="system"><dir name="config"><file name="test_connection_button.phtml" hash="1ab886afca2bca69d25f543e28482fc9"/></dir></dir></dir></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><file name="autoship.css" hash="960e1ea27d6dd97e44afa47563e3e84f"/></dir><dir name="images"><dir name="autoship"><file name="bkg_active-step.gif" hash="01d803ca8f4d7c7fb96c96694d233810"/><file name="bkg_block.gif" hash="df355007ee78db8a33c4e542594fe3f2"/><file name="bkg_btn-co.gif" hash="45547679e3ba34e4fd2a69750bbad05d"/><file name="bkg_thead.gif" hash="9957f9c2b564965d4d1a0ef1edcb1349"/><file name="calendar_icon.png" hash="f7073fc49641344b880a0b3218f2b261"/><file name="white_trans.png" hash="118606bdffc3e99bf15c6544cfdff1c2"/></dir></dir><dir name="js"><dir name="autoship"><file name="checkout.js" hash="cb92f1cc9bac34057843e6dcd5a38290"/><dir name="jquery"><file name="jquery-1.10.1.min.js" hash="33d85132f0154466fc017dd05111873d"/><file name="noconflict.js" hash="d8cc6cf5baad45a3ff03f75649f8ee41"/><dir name="ui"><file name="jquery.ui.core.min.js" hash="739cf68f21c10e04cde3ad13fcff9063"/><file name="jquery.ui.datepicker.min.js" hash="4eac58ed8deb3189c8d05bab9187f1ce"/><dir name="theme"><dir name="images"><file name="animated-overlay.gif" hash="2b912f7c0653008ca28ebacda49025e7"/><file name="ui-bg_flat_0_aaaaaa_40x100.png" hash="2a44fbdb7360c60122bcf6dcef0387d8"/><file name="ui-bg_flat_75_ffffff_40x100.png" hash="8692e6efddf882acbff144c38ea7dfdf"/><file name="ui-bg_glass_55_fbf9ee_1x400.png" hash="f8f4558e0b92ff2cd6136781533902ec"/><file name="ui-bg_glass_65_ffffff_1x400.png" hash="e5a8f32e28fd5c27bf0fed33c8a8b9b5"/><file name="ui-bg_glass_75_dadada_1x400.png" hash="c12c6510dad3ebfa64c8a30e959a2469"/><file name="ui-bg_glass_75_e6e6e6_1x400.png" hash="f4254356c2a8c9a383205ef2c4de22c4"/><file name="ui-bg_glass_95_fef1ec_1x400.png" hash="5a3be2d8fff8324d59aec3df7b0a0c83"/><file name="ui-bg_highlight-soft_75_cccccc_1x100.png" hash="72c593d16e998952cd8d798fee33c6f3"/><file name="ui-icons_222222_256x240.png" hash="9129e086dc488d8bcaf808510bc646ba"/><file name="ui-icons_2e83ff_256x240.png" hash="25162bf857a8eb83ea932a58436e1049"/><file name="ui-icons_454545_256x240.png" hash="771099482bdc1571ece41073b1752596"/><file name="ui-icons_888888_256x240.png" hash="faf6f5dc44e713178784c1fb053990aa"/><file name="ui-icons_cd0a0a_256x240.png" hash="5d8808d43cefca6f6781a5316d176632"/></dir><file name="jquery-ui.css" hash="dfcf2d9b984ec33bc6bb11e755ca0931"/></dir></dir></dir><file name="mysubscription.js" hash="38493104f99d9b50dccaae7267cef8d5"/><file name="newsubscription.js" hash="d89ad52dc30a5e3b50fec5d1cbc87308"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="js"><dir name="autoship"><dir name="jquery"><file name="jquery-1.10.1.min.js" hash="33d85132f0154466fc017dd05111873d"/><file name="noconflict.js" hash="d8cc6cf5baad45a3ff03f75649f8ee41"/></dir><file name="sales_create_order.js" hash="07f17495a2d1ba171d35798478fe0616"/></dir></dir></dir></dir></dir></target><target name="magelib"><dir name="OAuth2"><file name="Client.php" hash="fa9439393ed6483bd7d07af87df09b7e"/><dir name="GrantType"><file name="AuthorizationCode.php" hash="a1ff324a733fc33dbf938153c4c1667c"/><file name="ClientCredentials.php" hash="21b30fbb06d4b67263499d687316ae8b"/><file name="IGrantType.php" hash="ee03d4c5bc20f518716fc2c616b4d38d"/><file name="Password.php" hash="2e938e60c4af8bad71b5c4f0f1a40969"/><file name="RefreshToken.php" hash="a773f48348ad7aa510955099ba18d3ad"/></dir><file name="README" hash="8ef3bf723c93b6e091b707a546df2804"/></dir></target><target name="mage"><dir name="shell"><file name="autoship_prod_sync.php" hash="631910ac8ed6d0825bbd41f397934572"/></dir></target></contents>
|
16 |
+
<compatible/>
|
17 |
+
<dependencies><required><php><min>5.2.0</min><max>6.2.0</max></php><extension><name>ionCube Loader</name><min/><max/></extension></required></dependencies>
|
18 |
+
</package>
|
shell/autoship_prod_sync.php
ADDED
@@ -0,0 +1,61 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Subscribe Pro - Subscriptions Management Extension
|
4 |
+
*
|
5 |
+
* PHP version 5
|
6 |
+
*
|
7 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
8 |
+
*
|
9 |
+
* @category SFC
|
10 |
+
* @package SFC_Autoship
|
11 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
12 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
13 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
14 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
15 |
+
* @link http://www.subscribepro.com/
|
16 |
+
*
|
17 |
+
*/
|
18 |
+
|
19 |
+
require 'app/Mage.php';
|
20 |
+
|
21 |
+
if (!Mage::isInstalled()) {
|
22 |
+
die("Application is not installed yet, please complete install wizard first.\n");
|
23 |
+
}
|
24 |
+
|
25 |
+
// Only for urls
|
26 |
+
// Don't remove this
|
27 |
+
$_SERVER['SCRIPT_NAME'] = str_replace(basename(__FILE__), 'index.php', $_SERVER['SCRIPT_NAME']);
|
28 |
+
$_SERVER['SCRIPT_FILENAME'] = str_replace(basename(__FILE__), 'index.php', $_SERVER['SCRIPT_FILENAME']);
|
29 |
+
|
30 |
+
Mage::app('admin')->setUseSessionInUrl(false);
|
31 |
+
|
32 |
+
umask(0);
|
33 |
+
|
34 |
+
/** @var SFC_Autoship_Helper_Platform $platformHelper */
|
35 |
+
$platformHelper = Mage::helper('autoship/platform');
|
36 |
+
|
37 |
+
eLog("Syncing magento products to the platform.");
|
38 |
+
|
39 |
+
// Get and iterate collection of all products
|
40 |
+
$mageProducts = Mage::getModel('catalog/product')->getCollection();
|
41 |
+
/** @var Mage_Catalog_Model_Product $product */
|
42 |
+
foreach ($mageProducts as $product) {
|
43 |
+
try {
|
44 |
+
// Create / update product on platform
|
45 |
+
$platformHelper->handleOnSaveProduct($product);
|
46 |
+
eLog("Processed Product ID {$product->getId()}, sku {$product->getSku()}");
|
47 |
+
}
|
48 |
+
catch (Exception $e) {
|
49 |
+
eLog("Failed to process product ({$product->getId()}) with error: " . $e->getMessage());
|
50 |
+
}
|
51 |
+
}
|
52 |
+
|
53 |
+
function eLog($message)
|
54 |
+
{
|
55 |
+
if (is_string($message)) {
|
56 |
+
echo $message . "\n";
|
57 |
+
}
|
58 |
+
else {
|
59 |
+
print_r($message);
|
60 |
+
}
|
61 |
+
}
|
skin/adminhtml/default/default/js/autoship/jquery/jquery-1.10.1.min.js
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*! jQuery v1.10.1 | (c) 2005, 2013 jQuery Foundation, Inc. | jquery.org/license
|
2 |
+
//@ sourceMappingURL=jquery-1.10.1.min.map
|
3 |
+
*/
|
4 |
+
(function(e,t){var n,r,i=typeof t,o=e.location,a=e.document,s=a.documentElement,l=e.jQuery,u=e.$,c={},p=[],f="1.10.1",d=p.concat,h=p.push,g=p.slice,m=p.indexOf,y=c.toString,v=c.hasOwnProperty,b=f.trim,x=function(e,t){return new x.fn.init(e,t,r)},w=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,T=/\S+/g,C=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,N=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,k=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,E=/^[\],:{}\s]*$/,S=/(?:^|:|,)(?:\s*\[)+/g,A=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,j=/"[^"\\\r\n]*"|true|false|null|-?(?:\d+\.|)\d+(?:[eE][+-]?\d+|)/g,D=/^-ms-/,L=/-([\da-z])/gi,H=function(e,t){return t.toUpperCase()},q=function(e){(a.addEventListener||"load"===e.type||"complete"===a.readyState)&&(_(),x.ready())},_=function(){a.addEventListener?(a.removeEventListener("DOMContentLoaded",q,!1),e.removeEventListener("load",q,!1)):(a.detachEvent("onreadystatechange",q),e.detachEvent("onload",q))};x.fn=x.prototype={jquery:f,constructor:x,init:function(e,n,r){var i,o;if(!e)return this;if("string"==typeof e){if(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:N.exec(e),!i||!i[1]&&n)return!n||n.jquery?(n||r).find(e):this.constructor(n).find(e);if(i[1]){if(n=n instanceof x?n[0]:n,x.merge(this,x.parseHTML(i[1],n&&n.nodeType?n.ownerDocument||n:a,!0)),k.test(i[1])&&x.isPlainObject(n))for(i in n)x.isFunction(this[i])?this[i](n[i]):this.attr(i,n[i]);return this}if(o=a.getElementById(i[2]),o&&o.parentNode){if(o.id!==i[2])return r.find(e);this.length=1,this[0]=o}return this.context=a,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):x.isFunction(e)?r.ready(e):(e.selector!==t&&(this.selector=e.selector,this.context=e.context),x.makeArray(e,this))},selector:"",length:0,toArray:function(){return g.call(this)},get:function(e){return null==e?this.toArray():0>e?this[this.length+e]:this[e]},pushStack:function(e){var t=x.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return x.each(this,e,t)},ready:function(e){return x.ready.promise().done(e),this},slice:function(){return this.pushStack(g.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},map:function(e){return this.pushStack(x.map(this,function(t,n){return e.call(t,n,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:h,sort:[].sort,splice:[].splice},x.fn.init.prototype=x.fn,x.extend=x.fn.extend=function(){var e,n,r,i,o,a,s=arguments[0]||{},l=1,u=arguments.length,c=!1;for("boolean"==typeof s&&(c=s,s=arguments[1]||{},l=2),"object"==typeof s||x.isFunction(s)||(s={}),u===l&&(s=this,--l);u>l;l++)if(null!=(o=arguments[l]))for(i in o)e=s[i],r=o[i],s!==r&&(c&&r&&(x.isPlainObject(r)||(n=x.isArray(r)))?(n?(n=!1,a=e&&x.isArray(e)?e:[]):a=e&&x.isPlainObject(e)?e:{},s[i]=x.extend(c,a,r)):r!==t&&(s[i]=r));return s},x.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),noConflict:function(t){return e.$===x&&(e.$=u),t&&e.jQuery===x&&(e.jQuery=l),x},isReady:!1,readyWait:1,holdReady:function(e){e?x.readyWait++:x.ready(!0)},ready:function(e){if(e===!0?!--x.readyWait:!x.isReady){if(!a.body)return setTimeout(x.ready);x.isReady=!0,e!==!0&&--x.readyWait>0||(n.resolveWith(a,[x]),x.fn.trigger&&x(a).trigger("ready").off("ready"))}},isFunction:function(e){return"function"===x.type(e)},isArray:Array.isArray||function(e){return"array"===x.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?c[y.call(e)]||"object":typeof e},isPlainObject:function(e){var n;if(!e||"object"!==x.type(e)||e.nodeType||x.isWindow(e))return!1;try{if(e.constructor&&!v.call(e,"constructor")&&!v.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(r){return!1}if(x.support.ownLast)for(n in e)return v.call(e,n);for(n in e);return n===t||v.call(e,n)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},error:function(e){throw Error(e)},parseHTML:function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||a;var r=k.exec(e),i=!n&&[];return r?[t.createElement(r[1])]:(r=x.buildFragment([e],t,i),i&&x(i).remove(),x.merge([],r.childNodes))},parseJSON:function(n){return e.JSON&&e.JSON.parse?e.JSON.parse(n):null===n?n:"string"==typeof n&&(n=x.trim(n),n&&E.test(n.replace(A,"@").replace(j,"]").replace(S,"")))?Function("return "+n)():(x.error("Invalid JSON: "+n),t)},parseXML:function(n){var r,i;if(!n||"string"!=typeof n)return null;try{e.DOMParser?(i=new DOMParser,r=i.parseFromString(n,"text/xml")):(r=new ActiveXObject("Microsoft.XMLDOM"),r.async="false",r.loadXML(n))}catch(o){r=t}return r&&r.documentElement&&!r.getElementsByTagName("parsererror").length||x.error("Invalid XML: "+n),r},noop:function(){},globalEval:function(t){t&&x.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(D,"ms-").replace(L,H)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,n){var r,i=0,o=e.length,a=M(e);if(n){if(a){for(;o>i;i++)if(r=t.apply(e[i],n),r===!1)break}else for(i in e)if(r=t.apply(e[i],n),r===!1)break}else if(a){for(;o>i;i++)if(r=t.call(e[i],i,e[i]),r===!1)break}else for(i in e)if(r=t.call(e[i],i,e[i]),r===!1)break;return e},trim:b&&!b.call("\ufeff\u00a0")?function(e){return null==e?"":b.call(e)}:function(e){return null==e?"":(e+"").replace(C,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(M(Object(e))?x.merge(n,"string"==typeof e?[e]:e):h.call(n,e)),n},inArray:function(e,t,n){var r;if(t){if(m)return m.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,n){var r=n.length,i=e.length,o=0;if("number"==typeof r)for(;r>o;o++)e[i++]=n[o];else while(n[o]!==t)e[i++]=n[o++];return e.length=i,e},grep:function(e,t,n){var r,i=[],o=0,a=e.length;for(n=!!n;a>o;o++)r=!!t(e[o],o),n!==r&&i.push(e[o]);return i},map:function(e,t,n){var r,i=0,o=e.length,a=M(e),s=[];if(a)for(;o>i;i++)r=t(e[i],i,n),null!=r&&(s[s.length]=r);else for(i in e)r=t(e[i],i,n),null!=r&&(s[s.length]=r);return d.apply([],s)},guid:1,proxy:function(e,n){var r,i,o;return"string"==typeof n&&(o=e[n],n=e,e=o),x.isFunction(e)?(r=g.call(arguments,2),i=function(){return e.apply(n||this,r.concat(g.call(arguments)))},i.guid=e.guid=e.guid||x.guid++,i):t},access:function(e,n,r,i,o,a,s){var l=0,u=e.length,c=null==r;if("object"===x.type(r)){o=!0;for(l in r)x.access(e,n,l,r[l],!0,a,s)}else if(i!==t&&(o=!0,x.isFunction(i)||(s=!0),c&&(s?(n.call(e,i),n=null):(c=n,n=function(e,t,n){return c.call(x(e),n)})),n))for(;u>l;l++)n(e[l],r,s?i:i.call(e[l],l,n(e[l],r)));return o?e:c?n.call(e):u?n(e[0],r):a},now:function(){return(new Date).getTime()},swap:function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i}}),x.ready.promise=function(t){if(!n)if(n=x.Deferred(),"complete"===a.readyState)setTimeout(x.ready);else if(a.addEventListener)a.addEventListener("DOMContentLoaded",q,!1),e.addEventListener("load",q,!1);else{a.attachEvent("onreadystatechange",q),e.attachEvent("onload",q);var r=!1;try{r=null==e.frameElement&&a.documentElement}catch(i){}r&&r.doScroll&&function o(){if(!x.isReady){try{r.doScroll("left")}catch(e){return setTimeout(o,50)}_(),x.ready()}}()}return n.promise(t)},x.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){c["[object "+t+"]"]=t.toLowerCase()});function M(e){var t=e.length,n=x.type(e);return x.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||"function"!==n&&(0===t||"number"==typeof t&&t>0&&t-1 in e)}r=x(a),function(e,t){var n,r,i,o,a,s,l,u,c,p,f,d,h,g,m,y,v,b="sizzle"+-new Date,w=e.document,T=0,C=0,N=lt(),k=lt(),E=lt(),S=!1,A=function(){return 0},j=typeof t,D=1<<31,L={}.hasOwnProperty,H=[],q=H.pop,_=H.push,M=H.push,O=H.slice,F=H.indexOf||function(e){var t=0,n=this.length;for(;n>t;t++)if(this[t]===e)return t;return-1},B="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",P="[\\x20\\t\\r\\n\\f]",R="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",W=R.replace("w","w#"),$="\\["+P+"*("+R+")"+P+"*(?:([*^$|!~]?=)"+P+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+W+")|)|)"+P+"*\\]",I=":("+R+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+$.replace(3,8)+")*)|.*)\\)|)",z=RegExp("^"+P+"+|((?:^|[^\\\\])(?:\\\\.)*)"+P+"+$","g"),X=RegExp("^"+P+"*,"+P+"*"),U=RegExp("^"+P+"*([>+~]|"+P+")"+P+"*"),V=RegExp(P+"*[+~]"),Y=RegExp("="+P+"*([^\\]'\"]*)"+P+"*\\]","g"),J=RegExp(I),G=RegExp("^"+W+"$"),Q={ID:RegExp("^#("+R+")"),CLASS:RegExp("^\\.("+R+")"),TAG:RegExp("^("+R.replace("w","w*")+")"),ATTR:RegExp("^"+$),PSEUDO:RegExp("^"+I),CHILD:RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+P+"*(even|odd|(([+-]|)(\\d*)n|)"+P+"*(?:([+-]|)"+P+"*(\\d+)|))"+P+"*\\)|)","i"),bool:RegExp("^(?:"+B+")$","i"),needsContext:RegExp("^"+P+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+P+"*((?:-\\d)?\\d*)"+P+"*\\)|)(?=[^-]|$)","i")},K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,et=/^(?:input|select|textarea|button)$/i,tt=/^h\d$/i,nt=/'|\\/g,rt=RegExp("\\\\([\\da-f]{1,6}"+P+"?|("+P+")|.)","ig"),it=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:0>r?String.fromCharCode(r+65536):String.fromCharCode(55296|r>>10,56320|1023&r)};try{M.apply(H=O.call(w.childNodes),w.childNodes),H[w.childNodes.length].nodeType}catch(ot){M={apply:H.length?function(e,t){_.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function at(e,t,n,i){var o,a,s,l,u,c,d,m,y,x;if((t?t.ownerDocument||t:w)!==f&&p(t),t=t||f,n=n||[],!e||"string"!=typeof e)return n;if(1!==(l=t.nodeType)&&9!==l)return[];if(h&&!i){if(o=Z.exec(e))if(s=o[1]){if(9===l){if(a=t.getElementById(s),!a||!a.parentNode)return n;if(a.id===s)return n.push(a),n}else if(t.ownerDocument&&(a=t.ownerDocument.getElementById(s))&&v(t,a)&&a.id===s)return n.push(a),n}else{if(o[2])return M.apply(n,t.getElementsByTagName(e)),n;if((s=o[3])&&r.getElementsByClassName&&t.getElementsByClassName)return M.apply(n,t.getElementsByClassName(s)),n}if(r.qsa&&(!g||!g.test(e))){if(m=d=b,y=t,x=9===l&&e,1===l&&"object"!==t.nodeName.toLowerCase()){c=bt(e),(d=t.getAttribute("id"))?m=d.replace(nt,"\\$&"):t.setAttribute("id",m),m="[id='"+m+"'] ",u=c.length;while(u--)c[u]=m+xt(c[u]);y=V.test(e)&&t.parentNode||t,x=c.join(",")}if(x)try{return M.apply(n,y.querySelectorAll(x)),n}catch(T){}finally{d||t.removeAttribute("id")}}}return At(e.replace(z,"$1"),t,n,i)}function st(e){return K.test(e+"")}function lt(){var e=[];function t(n,r){return e.push(n+=" ")>o.cacheLength&&delete t[e.shift()],t[n]=r}return t}function ut(e){return e[b]=!0,e}function ct(e){var t=f.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function pt(e,t,n){e=e.split("|");var r,i=e.length,a=n?null:t;while(i--)(r=o.attrHandle[e[i]])&&r!==t||(o.attrHandle[e[i]]=a)}function ft(e,t){var n=e.getAttributeNode(t);return n&&n.specified?n.value:e[t]===!0?t.toLowerCase():null}function dt(e,t){return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}function ht(e){return"input"===e.nodeName.toLowerCase()?e.defaultValue:t}function gt(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||D)-(~e.sourceIndex||D);if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function mt(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function yt(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function vt(e){return ut(function(t){return t=+t,ut(function(n,r){var i,o=e([],n.length,t),a=o.length;while(a--)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}s=at.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},r=at.support={},p=at.setDocument=function(e){var n=e?e.ownerDocument||e:w,i=n.parentWindow;return n!==f&&9===n.nodeType&&n.documentElement?(f=n,d=n.documentElement,h=!s(n),i&&i.frameElement&&i.attachEvent("onbeforeunload",function(){p()}),r.attributes=ct(function(e){return e.innerHTML="<a href='#'></a>",pt("type|href|height|width",dt,"#"===e.firstChild.getAttribute("href")),pt(B,ft,null==e.getAttribute("disabled")),e.className="i",!e.getAttribute("className")}),r.input=ct(function(e){return e.innerHTML="<input>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")}),pt("value",ht,r.attributes&&r.input),r.getElementsByTagName=ct(function(e){return e.appendChild(n.createComment("")),!e.getElementsByTagName("*").length}),r.getElementsByClassName=ct(function(e){return e.innerHTML="<div class='a'></div><div class='a i'></div>",e.firstChild.className="i",2===e.getElementsByClassName("i").length}),r.getById=ct(function(e){return d.appendChild(e).id=b,!n.getElementsByName||!n.getElementsByName(b).length}),r.getById?(o.find.ID=function(e,t){if(typeof t.getElementById!==j&&h){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){return e.getAttribute("id")===t}}):(delete o.find.ID,o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){var n=typeof e.getAttributeNode!==j&&e.getAttributeNode("id");return n&&n.value===t}}),o.find.TAG=r.getElementsByTagName?function(e,n){return typeof n.getElementsByTagName!==j?n.getElementsByTagName(e):t}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},o.find.CLASS=r.getElementsByClassName&&function(e,n){return typeof n.getElementsByClassName!==j&&h?n.getElementsByClassName(e):t},m=[],g=[],(r.qsa=st(n.querySelectorAll))&&(ct(function(e){e.innerHTML="<select><option selected=''></option></select>",e.querySelectorAll("[selected]").length||g.push("\\["+P+"*(?:value|"+B+")"),e.querySelectorAll(":checked").length||g.push(":checked")}),ct(function(e){var t=n.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("t",""),e.querySelectorAll("[t^='']").length&&g.push("[*^$]="+P+"*(?:''|\"\")"),e.querySelectorAll(":enabled").length||g.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),g.push(",.*:")})),(r.matchesSelector=st(y=d.webkitMatchesSelector||d.mozMatchesSelector||d.oMatchesSelector||d.msMatchesSelector))&&ct(function(e){r.disconnectedMatch=y.call(e,"div"),y.call(e,"[s!='']:x"),m.push("!=",I)}),g=g.length&&RegExp(g.join("|")),m=m.length&&RegExp(m.join("|")),v=st(d.contains)||d.compareDocumentPosition?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},r.sortDetached=ct(function(e){return 1&e.compareDocumentPosition(n.createElement("div"))}),A=d.compareDocumentPosition?function(e,t){if(e===t)return S=!0,0;var i=t.compareDocumentPosition&&e.compareDocumentPosition&&e.compareDocumentPosition(t);return i?1&i||!r.sortDetached&&t.compareDocumentPosition(e)===i?e===n||v(w,e)?-1:t===n||v(w,t)?1:c?F.call(c,e)-F.call(c,t):0:4&i?-1:1:e.compareDocumentPosition?-1:1}:function(e,t){var r,i=0,o=e.parentNode,a=t.parentNode,s=[e],l=[t];if(e===t)return S=!0,0;if(!o||!a)return e===n?-1:t===n?1:o?-1:a?1:c?F.call(c,e)-F.call(c,t):0;if(o===a)return gt(e,t);r=e;while(r=r.parentNode)s.unshift(r);r=t;while(r=r.parentNode)l.unshift(r);while(s[i]===l[i])i++;return i?gt(s[i],l[i]):s[i]===w?-1:l[i]===w?1:0},n):f},at.matches=function(e,t){return at(e,null,null,t)},at.matchesSelector=function(e,t){if((e.ownerDocument||e)!==f&&p(e),t=t.replace(Y,"='$1']"),!(!r.matchesSelector||!h||m&&m.test(t)||g&&g.test(t)))try{var n=y.call(e,t);if(n||r.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(i){}return at(t,f,null,[e]).length>0},at.contains=function(e,t){return(e.ownerDocument||e)!==f&&p(e),v(e,t)},at.attr=function(e,n){(e.ownerDocument||e)!==f&&p(e);var i=o.attrHandle[n.toLowerCase()],a=i&&L.call(o.attrHandle,n.toLowerCase())?i(e,n,!h):t;return a===t?r.attributes||!h?e.getAttribute(n):(a=e.getAttributeNode(n))&&a.specified?a.value:null:a},at.error=function(e){throw Error("Syntax error, unrecognized expression: "+e)},at.uniqueSort=function(e){var t,n=[],i=0,o=0;if(S=!r.detectDuplicates,c=!r.sortStable&&e.slice(0),e.sort(A),S){while(t=e[o++])t===e[o]&&(i=n.push(o));while(i--)e.splice(n[i],1)}return e},a=at.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=a(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r];r++)n+=a(t);return n},o=at.selectors={cacheLength:50,createPseudo:ut,match:Q,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(rt,it),e[3]=(e[4]||e[5]||"").replace(rt,it),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||at.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&at.error(e[0]),e},PSEUDO:function(e){var n,r=!e[5]&&e[2];return Q.CHILD.test(e[0])?null:(e[3]&&e[4]!==t?e[2]=e[4]:r&&J.test(r)&&(n=bt(r,!0))&&(n=r.indexOf(")",r.length-n)-r.length)&&(e[0]=e[0].slice(0,n),e[2]=r.slice(0,n)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(rt,it).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=N[e+" "];return t||(t=RegExp("(^|"+P+")"+e+"("+P+"|$)"))&&N(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==j&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var i=at.attr(r,e);return null==i?"!="===t:t?(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i+" ").indexOf(n)>-1:"|="===t?i===n||i.slice(0,n.length+1)===n+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,l){var u,c,p,f,d,h,g=o!==a?"nextSibling":"previousSibling",m=t.parentNode,y=s&&t.nodeName.toLowerCase(),v=!l&&!s;if(m){if(o){while(g){p=t;while(p=p[g])if(s?p.nodeName.toLowerCase()===y:1===p.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?m.firstChild:m.lastChild],a&&v){c=m[b]||(m[b]={}),u=c[e]||[],d=u[0]===T&&u[1],f=u[0]===T&&u[2],p=d&&m.childNodes[d];while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if(1===p.nodeType&&++f&&p===t){c[e]=[T,d,f];break}}else if(v&&(u=(t[b]||(t[b]={}))[e])&&u[0]===T)f=u[1];else while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if((s?p.nodeName.toLowerCase()===y:1===p.nodeType)&&++f&&(v&&((p[b]||(p[b]={}))[e]=[T,f]),p===t))break;return f-=i,f===r||0===f%r&&f/r>=0}}},PSEUDO:function(e,t){var n,r=o.pseudos[e]||o.setFilters[e.toLowerCase()]||at.error("unsupported pseudo: "+e);return r[b]?r(t):r.length>1?(n=[e,e,"",t],o.setFilters.hasOwnProperty(e.toLowerCase())?ut(function(e,n){var i,o=r(e,t),a=o.length;while(a--)i=F.call(e,o[a]),e[i]=!(n[i]=o[a])}):function(e){return r(e,0,n)}):r}},pseudos:{not:ut(function(e){var t=[],n=[],r=l(e.replace(z,"$1"));return r[b]?ut(function(e,t,n,i){var o,a=r(e,null,i,[]),s=e.length;while(s--)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),!n.pop()}}),has:ut(function(e){return function(t){return at(e,t).length>0}}),contains:ut(function(e){return function(t){return(t.textContent||t.innerText||a(t)).indexOf(e)>-1}}),lang:ut(function(e){return G.test(e||"")||at.error("unsupported lang: "+e),e=e.replace(rt,it).toLowerCase(),function(t){var n;do if(n=h?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===d},focus:function(e){return e===f.activeElement&&(!f.hasFocus||f.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeName>"@"||3===e.nodeType||4===e.nodeType)return!1;return!0},parent:function(e){return!o.pseudos.empty(e)},header:function(e){return tt.test(e.nodeName)},input:function(e){return et.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||t.toLowerCase()===e.type)},first:vt(function(){return[0]}),last:vt(function(e,t){return[t-1]}),eq:vt(function(e,t,n){return[0>n?n+t:n]}),even:vt(function(e,t){var n=0;for(;t>n;n+=2)e.push(n);return e}),odd:vt(function(e,t){var n=1;for(;t>n;n+=2)e.push(n);return e}),lt:vt(function(e,t,n){var r=0>n?n+t:n;for(;--r>=0;)e.push(r);return e}),gt:vt(function(e,t,n){var r=0>n?n+t:n;for(;t>++r;)e.push(r);return e})}};for(n in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})o.pseudos[n]=mt(n);for(n in{submit:!0,reset:!0})o.pseudos[n]=yt(n);function bt(e,t){var n,r,i,a,s,l,u,c=k[e+" "];if(c)return t?0:c.slice(0);s=e,l=[],u=o.preFilter;while(s){(!n||(r=X.exec(s)))&&(r&&(s=s.slice(r[0].length)||s),l.push(i=[])),n=!1,(r=U.exec(s))&&(n=r.shift(),i.push({value:n,type:r[0].replace(z," ")}),s=s.slice(n.length));for(a in o.filter)!(r=Q[a].exec(s))||u[a]&&!(r=u[a](r))||(n=r.shift(),i.push({value:n,type:a,matches:r}),s=s.slice(n.length));if(!n)break}return t?s.length:s?at.error(e):k(e,l).slice(0)}function xt(e){var t=0,n=e.length,r="";for(;n>t;t++)r+=e[t].value;return r}function wt(e,t,n){var r=t.dir,o=n&&"parentNode"===r,a=C++;return t.first?function(t,n,i){while(t=t[r])if(1===t.nodeType||o)return e(t,n,i)}:function(t,n,s){var l,u,c,p=T+" "+a;if(s){while(t=t[r])if((1===t.nodeType||o)&&e(t,n,s))return!0}else while(t=t[r])if(1===t.nodeType||o)if(c=t[b]||(t[b]={}),(u=c[r])&&u[0]===p){if((l=u[1])===!0||l===i)return l===!0}else if(u=c[r]=[p],u[1]=e(t,n,s)||i,u[1]===!0)return!0}}function Tt(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function Ct(e,t,n,r,i){var o,a=[],s=0,l=e.length,u=null!=t;for(;l>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),u&&t.push(s));return a}function Nt(e,t,n,r,i,o){return r&&!r[b]&&(r=Nt(r)),i&&!i[b]&&(i=Nt(i,o)),ut(function(o,a,s,l){var u,c,p,f=[],d=[],h=a.length,g=o||St(t||"*",s.nodeType?[s]:s,[]),m=!e||!o&&t?g:Ct(g,f,e,s,l),y=n?i||(o?e:h||r)?[]:a:m;if(n&&n(m,y,s,l),r){u=Ct(y,d),r(u,[],s,l),c=u.length;while(c--)(p=u[c])&&(y[d[c]]=!(m[d[c]]=p))}if(o){if(i||e){if(i){u=[],c=y.length;while(c--)(p=y[c])&&u.push(m[c]=p);i(null,y=[],u,l)}c=y.length;while(c--)(p=y[c])&&(u=i?F.call(o,p):f[c])>-1&&(o[u]=!(a[u]=p))}}else y=Ct(y===a?y.splice(h,y.length):y),i?i(null,a,y,l):M.apply(a,y)})}function kt(e){var t,n,r,i=e.length,a=o.relative[e[0].type],s=a||o.relative[" "],l=a?1:0,c=wt(function(e){return e===t},s,!0),p=wt(function(e){return F.call(t,e)>-1},s,!0),f=[function(e,n,r){return!a&&(r||n!==u)||((t=n).nodeType?c(e,n,r):p(e,n,r))}];for(;i>l;l++)if(n=o.relative[e[l].type])f=[wt(Tt(f),n)];else{if(n=o.filter[e[l].type].apply(null,e[l].matches),n[b]){for(r=++l;i>r;r++)if(o.relative[e[r].type])break;return Nt(l>1&&Tt(f),l>1&&xt(e.slice(0,l-1).concat({value:" "===e[l-2].type?"*":""})).replace(z,"$1"),n,r>l&&kt(e.slice(l,r)),i>r&&kt(e=e.slice(r)),i>r&&xt(e))}f.push(n)}return Tt(f)}function Et(e,t){var n=0,r=t.length>0,a=e.length>0,s=function(s,l,c,p,d){var h,g,m,y=[],v=0,b="0",x=s&&[],w=null!=d,C=u,N=s||a&&o.find.TAG("*",d&&l.parentNode||l),k=T+=null==C?1:Math.random()||.1;for(w&&(u=l!==f&&l,i=n);null!=(h=N[b]);b++){if(a&&h){g=0;while(m=e[g++])if(m(h,l,c)){p.push(h);break}w&&(T=k,i=++n)}r&&((h=!m&&h)&&v--,s&&x.push(h))}if(v+=b,r&&b!==v){g=0;while(m=t[g++])m(x,y,l,c);if(s){if(v>0)while(b--)x[b]||y[b]||(y[b]=q.call(p));y=Ct(y)}M.apply(p,y),w&&!s&&y.length>0&&v+t.length>1&&at.uniqueSort(p)}return w&&(T=k,u=C),x};return r?ut(s):s}l=at.compile=function(e,t){var n,r=[],i=[],o=E[e+" "];if(!o){t||(t=bt(e)),n=t.length;while(n--)o=kt(t[n]),o[b]?r.push(o):i.push(o);o=E(e,Et(i,r))}return o};function St(e,t,n){var r=0,i=t.length;for(;i>r;r++)at(e,t[r],n);return n}function At(e,t,n,i){var a,s,u,c,p,f=bt(e);if(!i&&1===f.length){if(s=f[0]=f[0].slice(0),s.length>2&&"ID"===(u=s[0]).type&&r.getById&&9===t.nodeType&&h&&o.relative[s[1].type]){if(t=(o.find.ID(u.matches[0].replace(rt,it),t)||[])[0],!t)return n;e=e.slice(s.shift().value.length)}a=Q.needsContext.test(e)?0:s.length;while(a--){if(u=s[a],o.relative[c=u.type])break;if((p=o.find[c])&&(i=p(u.matches[0].replace(rt,it),V.test(s[0].type)&&t.parentNode||t))){if(s.splice(a,1),e=i.length&&xt(s),!e)return M.apply(n,i),n;break}}}return l(e,f)(i,t,!h,n,V.test(e)),n}o.pseudos.nth=o.pseudos.eq;function jt(){}jt.prototype=o.filters=o.pseudos,o.setFilters=new jt,r.sortStable=b.split("").sort(A).join("")===b,p(),[0,0].sort(A),r.detectDuplicates=S,x.find=at,x.expr=at.selectors,x.expr[":"]=x.expr.pseudos,x.unique=at.uniqueSort,x.text=at.getText,x.isXMLDoc=at.isXML,x.contains=at.contains}(e);var O={};function F(e){var t=O[e]={};return x.each(e.match(T)||[],function(e,n){t[n]=!0}),t}x.Callbacks=function(e){e="string"==typeof e?O[e]||F(e):x.extend({},e);var n,r,i,o,a,s,l=[],u=!e.once&&[],c=function(t){for(r=e.memory&&t,i=!0,a=s||0,s=0,o=l.length,n=!0;l&&o>a;a++)if(l[a].apply(t[0],t[1])===!1&&e.stopOnFalse){r=!1;break}n=!1,l&&(u?u.length&&c(u.shift()):r?l=[]:p.disable())},p={add:function(){if(l){var t=l.length;(function i(t){x.each(t,function(t,n){var r=x.type(n);"function"===r?e.unique&&p.has(n)||l.push(n):n&&n.length&&"string"!==r&&i(n)})})(arguments),n?o=l.length:r&&(s=t,c(r))}return this},remove:function(){return l&&x.each(arguments,function(e,t){var r;while((r=x.inArray(t,l,r))>-1)l.splice(r,1),n&&(o>=r&&o--,a>=r&&a--)}),this},has:function(e){return e?x.inArray(e,l)>-1:!(!l||!l.length)},empty:function(){return l=[],o=0,this},disable:function(){return l=u=r=t,this},disabled:function(){return!l},lock:function(){return u=t,r||p.disable(),this},locked:function(){return!u},fireWith:function(e,t){return t=t||[],t=[e,t.slice?t.slice():t],!l||i&&!u||(n?u.push(t):c(t)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p},x.extend({Deferred:function(e){var t=[["resolve","done",x.Callbacks("once memory"),"resolved"],["reject","fail",x.Callbacks("once memory"),"rejected"],["notify","progress",x.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return x.Deferred(function(n){x.each(t,function(t,o){var a=o[0],s=x.isFunction(e[t])&&e[t];i[o[1]](function(){var e=s&&s.apply(this,arguments);e&&x.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[a+"With"](this===r?n.promise():this,s?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?x.extend(e,r):r}},i={};return r.pipe=r.then,x.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=g.call(arguments),r=n.length,i=1!==r||e&&x.isFunction(e.promise)?r:0,o=1===i?e:x.Deferred(),a=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?g.call(arguments):r,n===s?o.notifyWith(t,n):--i||o.resolveWith(t,n)}},s,l,u;if(r>1)for(s=Array(r),l=Array(r),u=Array(r);r>t;t++)n[t]&&x.isFunction(n[t].promise)?n[t].promise().done(a(t,u,n)).fail(o.reject).progress(a(t,l,s)):--i;return i||o.resolveWith(u,n),o.promise()}}),x.support=function(t){var n,r,o,s,l,u,c,p,f,d=a.createElement("div");if(d.setAttribute("className","t"),d.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",n=d.getElementsByTagName("*")||[],r=d.getElementsByTagName("a")[0],!r||!r.style||!n.length)return t;s=a.createElement("select"),u=s.appendChild(a.createElement("option")),o=d.getElementsByTagName("input")[0],r.style.cssText="top:1px;float:left;opacity:.5",t.getSetAttribute="t"!==d.className,t.leadingWhitespace=3===d.firstChild.nodeType,t.tbody=!d.getElementsByTagName("tbody").length,t.htmlSerialize=!!d.getElementsByTagName("link").length,t.style=/top/.test(r.getAttribute("style")),t.hrefNormalized="/a"===r.getAttribute("href"),t.opacity=/^0.5/.test(r.style.opacity),t.cssFloat=!!r.style.cssFloat,t.checkOn=!!o.value,t.optSelected=u.selected,t.enctype=!!a.createElement("form").enctype,t.html5Clone="<:nav></:nav>"!==a.createElement("nav").cloneNode(!0).outerHTML,t.inlineBlockNeedsLayout=!1,t.shrinkWrapBlocks=!1,t.pixelPosition=!1,t.deleteExpando=!0,t.noCloneEvent=!0,t.reliableMarginRight=!0,t.boxSizingReliable=!0,o.checked=!0,t.noCloneChecked=o.cloneNode(!0).checked,s.disabled=!0,t.optDisabled=!u.disabled;try{delete d.test}catch(h){t.deleteExpando=!1}o=a.createElement("input"),o.setAttribute("value",""),t.input=""===o.getAttribute("value"),o.value="t",o.setAttribute("type","radio"),t.radioValue="t"===o.value,o.setAttribute("checked","t"),o.setAttribute("name","t"),l=a.createDocumentFragment(),l.appendChild(o),t.appendChecked=o.checked,t.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,d.attachEvent&&(d.attachEvent("onclick",function(){t.noCloneEvent=!1}),d.cloneNode(!0).click());for(f in{submit:!0,change:!0,focusin:!0})d.setAttribute(c="on"+f,"t"),t[f+"Bubbles"]=c in e||d.attributes[c].expando===!1;d.style.backgroundClip="content-box",d.cloneNode(!0).style.backgroundClip="",t.clearCloneStyle="content-box"===d.style.backgroundClip;for(f in x(t))break;return t.ownLast="0"!==f,x(function(){var n,r,o,s="padding:0;margin:0;border:0;display:block;box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;",l=a.getElementsByTagName("body")[0];l&&(n=a.createElement("div"),n.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",l.appendChild(n).appendChild(d),d.innerHTML="<table><tr><td></td><td>t</td></tr></table>",o=d.getElementsByTagName("td"),o[0].style.cssText="padding:0;margin:0;border:0;display:none",p=0===o[0].offsetHeight,o[0].style.display="",o[1].style.display="none",t.reliableHiddenOffsets=p&&0===o[0].offsetHeight,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",x.swap(l,null!=l.style.zoom?{zoom:1}:{},function(){t.boxSizing=4===d.offsetWidth}),e.getComputedStyle&&(t.pixelPosition="1%"!==(e.getComputedStyle(d,null)||{}).top,t.boxSizingReliable="4px"===(e.getComputedStyle(d,null)||{width:"4px"}).width,r=d.appendChild(a.createElement("div")),r.style.cssText=d.style.cssText=s,r.style.marginRight=r.style.width="0",d.style.width="1px",t.reliableMarginRight=!parseFloat((e.getComputedStyle(r,null)||{}).marginRight)),typeof d.style.zoom!==i&&(d.innerHTML="",d.style.cssText=s+"width:1px;padding:1px;display:inline;zoom:1",t.inlineBlockNeedsLayout=3===d.offsetWidth,d.style.display="block",d.innerHTML="<div></div>",d.firstChild.style.width="5px",t.shrinkWrapBlocks=3!==d.offsetWidth,t.inlineBlockNeedsLayout&&(l.style.zoom=1)),l.removeChild(n),n=d=o=r=null)
|
5 |
+
}),n=s=l=u=r=o=null,t}({});var B=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,P=/([A-Z])/g;function R(e,n,r,i){if(x.acceptData(e)){var o,a,s=x.expando,l=e.nodeType,u=l?x.cache:e,c=l?e[s]:e[s]&&s;if(c&&u[c]&&(i||u[c].data)||r!==t||"string"!=typeof n)return c||(c=l?e[s]=p.pop()||x.guid++:s),u[c]||(u[c]=l?{}:{toJSON:x.noop}),("object"==typeof n||"function"==typeof n)&&(i?u[c]=x.extend(u[c],n):u[c].data=x.extend(u[c].data,n)),a=u[c],i||(a.data||(a.data={}),a=a.data),r!==t&&(a[x.camelCase(n)]=r),"string"==typeof n?(o=a[n],null==o&&(o=a[x.camelCase(n)])):o=a,o}}function W(e,t,n){if(x.acceptData(e)){var r,i,o=e.nodeType,a=o?x.cache:e,s=o?e[x.expando]:x.expando;if(a[s]){if(t&&(r=n?a[s]:a[s].data)){x.isArray(t)?t=t.concat(x.map(t,x.camelCase)):t in r?t=[t]:(t=x.camelCase(t),t=t in r?[t]:t.split(" ")),i=t.length;while(i--)delete r[t[i]];if(n?!I(r):!x.isEmptyObject(r))return}(n||(delete a[s].data,I(a[s])))&&(o?x.cleanData([e],!0):x.support.deleteExpando||a!=a.window?delete a[s]:a[s]=null)}}}x.extend({cache:{},noData:{applet:!0,embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return e=e.nodeType?x.cache[e[x.expando]]:e[x.expando],!!e&&!I(e)},data:function(e,t,n){return R(e,t,n)},removeData:function(e,t){return W(e,t)},_data:function(e,t,n){return R(e,t,n,!0)},_removeData:function(e,t){return W(e,t,!0)},acceptData:function(e){if(e.nodeType&&1!==e.nodeType&&9!==e.nodeType)return!1;var t=e.nodeName&&x.noData[e.nodeName.toLowerCase()];return!t||t!==!0&&e.getAttribute("classid")===t}}),x.fn.extend({data:function(e,n){var r,i,o=null,a=0,s=this[0];if(e===t){if(this.length&&(o=x.data(s),1===s.nodeType&&!x._data(s,"parsedAttrs"))){for(r=s.attributes;r.length>a;a++)i=r[a].name,0===i.indexOf("data-")&&(i=x.camelCase(i.slice(5)),$(s,i,o[i]));x._data(s,"parsedAttrs",!0)}return o}return"object"==typeof e?this.each(function(){x.data(this,e)}):arguments.length>1?this.each(function(){x.data(this,e,n)}):s?$(s,e,x.data(s,e)):null},removeData:function(e){return this.each(function(){x.removeData(this,e)})}});function $(e,n,r){if(r===t&&1===e.nodeType){var i="data-"+n.replace(P,"-$1").toLowerCase();if(r=e.getAttribute(i),"string"==typeof r){try{r="true"===r?!0:"false"===r?!1:"null"===r?null:+r+""===r?+r:B.test(r)?x.parseJSON(r):r}catch(o){}x.data(e,n,r)}else r=t}return r}function I(e){var t;for(t in e)if(("data"!==t||!x.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}x.extend({queue:function(e,n,r){var i;return e?(n=(n||"fx")+"queue",i=x._data(e,n),r&&(!i||x.isArray(r)?i=x._data(e,n,x.makeArray(r)):i.push(r)),i||[]):t},dequeue:function(e,t){t=t||"fx";var n=x.queue(e,t),r=n.length,i=n.shift(),o=x._queueHooks(e,t),a=function(){x.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return x._data(e,n)||x._data(e,n,{empty:x.Callbacks("once memory").add(function(){x._removeData(e,t+"queue"),x._removeData(e,n)})})}}),x.fn.extend({queue:function(e,n){var r=2;return"string"!=typeof e&&(n=e,e="fx",r--),r>arguments.length?x.queue(this[0],e):n===t?this:this.each(function(){var t=x.queue(this,e,n);x._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&x.dequeue(this,e)})},dequeue:function(e){return this.each(function(){x.dequeue(this,e)})},delay:function(e,t){return e=x.fx?x.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,n){var r,i=1,o=x.Deferred(),a=this,s=this.length,l=function(){--i||o.resolveWith(a,[a])};"string"!=typeof e&&(n=e,e=t),e=e||"fx";while(s--)r=x._data(a[s],e+"queueHooks"),r&&r.empty&&(i++,r.empty.add(l));return l(),o.promise(n)}});var z,X,U=/[\t\r\n\f]/g,V=/\r/g,Y=/^(?:input|select|textarea|button|object)$/i,J=/^(?:a|area)$/i,G=/^(?:checked|selected)$/i,Q=x.support.getSetAttribute,K=x.support.input;x.fn.extend({attr:function(e,t){return x.access(this,x.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){x.removeAttr(this,e)})},prop:function(e,t){return x.access(this,x.prop,e,t,arguments.length>1)},removeProp:function(e){return e=x.propFix[e]||e,this.each(function(){try{this[e]=t,delete this[e]}catch(n){}})},addClass:function(e){var t,n,r,i,o,a=0,s=this.length,l="string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).addClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):" ")){o=0;while(i=t[o++])0>r.indexOf(" "+i+" ")&&(r+=i+" ");n.className=x.trim(r)}return this},removeClass:function(e){var t,n,r,i,o,a=0,s=this.length,l=0===arguments.length||"string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).removeClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):"")){o=0;while(i=t[o++])while(r.indexOf(" "+i+" ")>=0)r=r.replace(" "+i+" "," ");n.className=e?x.trim(r):""}return this},toggleClass:function(e,t){var n=typeof e,r="boolean"==typeof t;return x.isFunction(e)?this.each(function(n){x(this).toggleClass(e.call(this,n,this.className,t),t)}):this.each(function(){if("string"===n){var o,a=0,s=x(this),l=t,u=e.match(T)||[];while(o=u[a++])l=r?l:!s.hasClass(o),s[l?"addClass":"removeClass"](o)}else(n===i||"boolean"===n)&&(this.className&&x._data(this,"__className__",this.className),this.className=this.className||e===!1?"":x._data(this,"__className__")||"")})},hasClass:function(e){var t=" "+e+" ",n=0,r=this.length;for(;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(U," ").indexOf(t)>=0)return!0;return!1},val:function(e){var n,r,i,o=this[0];{if(arguments.length)return i=x.isFunction(e),this.each(function(n){var o;1===this.nodeType&&(o=i?e.call(this,n,x(this).val()):e,null==o?o="":"number"==typeof o?o+="":x.isArray(o)&&(o=x.map(o,function(e){return null==e?"":e+""})),r=x.valHooks[this.type]||x.valHooks[this.nodeName.toLowerCase()],r&&"set"in r&&r.set(this,o,"value")!==t||(this.value=o))});if(o)return r=x.valHooks[o.type]||x.valHooks[o.nodeName.toLowerCase()],r&&"get"in r&&(n=r.get(o,"value"))!==t?n:(n=o.value,"string"==typeof n?n.replace(V,""):null==n?"":n)}}}),x.extend({valHooks:{option:{get:function(e){var t=x.find.attr(e,"value");return null!=t?t:e.text}},select:{get:function(e){var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,l=0>i?s:o?i:0;for(;s>l;l++)if(n=r[l],!(!n.selected&&l!==i||(x.support.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&x.nodeName(n.parentNode,"optgroup"))){if(t=x(n).val(),o)return t;a.push(t)}return a},set:function(e,t){var n,r,i=e.options,o=x.makeArray(t),a=i.length;while(a--)r=i[a],(r.selected=x.inArray(x(r).val(),o)>=0)&&(n=!0);return n||(e.selectedIndex=-1),o}}},attr:function(e,n,r){var o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return typeof e.getAttribute===i?x.prop(e,n,r):(1===s&&x.isXMLDoc(e)||(n=n.toLowerCase(),o=x.attrHooks[n]||(x.expr.match.bool.test(n)?X:z)),r===t?o&&"get"in o&&null!==(a=o.get(e,n))?a:(a=x.find.attr(e,n),null==a?t:a):null!==r?o&&"set"in o&&(a=o.set(e,r,n))!==t?a:(e.setAttribute(n,r+""),r):(x.removeAttr(e,n),t))},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(T);if(o&&1===e.nodeType)while(n=o[i++])r=x.propFix[n]||n,x.expr.match.bool.test(n)?K&&Q||!G.test(n)?e[r]=!1:e[x.camelCase("default-"+n)]=e[r]=!1:x.attr(e,n,""),e.removeAttribute(Q?n:r)},attrHooks:{type:{set:function(e,t){if(!x.support.radioValue&&"radio"===t&&x.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},propFix:{"for":"htmlFor","class":"className"},prop:function(e,n,r){var i,o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return a=1!==s||!x.isXMLDoc(e),a&&(n=x.propFix[n]||n,o=x.propHooks[n]),r!==t?o&&"set"in o&&(i=o.set(e,r,n))!==t?i:e[n]=r:o&&"get"in o&&null!==(i=o.get(e,n))?i:e[n]},propHooks:{tabIndex:{get:function(e){var t=x.find.attr(e,"tabindex");return t?parseInt(t,10):Y.test(e.nodeName)||J.test(e.nodeName)&&e.href?0:-1}}}}),X={set:function(e,t,n){return t===!1?x.removeAttr(e,n):K&&Q||!G.test(n)?e.setAttribute(!Q&&x.propFix[n]||n,n):e[x.camelCase("default-"+n)]=e[n]=!0,n}},x.each(x.expr.match.bool.source.match(/\w+/g),function(e,n){var r=x.expr.attrHandle[n]||x.find.attr;x.expr.attrHandle[n]=K&&Q||!G.test(n)?function(e,n,i){var o=x.expr.attrHandle[n],a=i?t:(x.expr.attrHandle[n]=t)!=r(e,n,i)?n.toLowerCase():null;return x.expr.attrHandle[n]=o,a}:function(e,n,r){return r?t:e[x.camelCase("default-"+n)]?n.toLowerCase():null}}),K&&Q||(x.attrHooks.value={set:function(e,n,r){return x.nodeName(e,"input")?(e.defaultValue=n,t):z&&z.set(e,n,r)}}),Q||(z={set:function(e,n,r){var i=e.getAttributeNode(r);return i||e.setAttributeNode(i=e.ownerDocument.createAttribute(r)),i.value=n+="","value"===r||n===e.getAttribute(r)?n:t}},x.expr.attrHandle.id=x.expr.attrHandle.name=x.expr.attrHandle.coords=function(e,n,r){var i;return r?t:(i=e.getAttributeNode(n))&&""!==i.value?i.value:null},x.valHooks.button={get:function(e,n){var r=e.getAttributeNode(n);return r&&r.specified?r.value:t},set:z.set},x.attrHooks.contenteditable={set:function(e,t,n){z.set(e,""===t?!1:t,n)}},x.each(["width","height"],function(e,n){x.attrHooks[n]={set:function(e,r){return""===r?(e.setAttribute(n,"auto"),r):t}}})),x.support.hrefNormalized||x.each(["href","src"],function(e,t){x.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),x.support.style||(x.attrHooks.style={get:function(e){return e.style.cssText||t},set:function(e,t){return e.style.cssText=t+""}}),x.support.optSelected||(x.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}}),x.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){x.propFix[this.toLowerCase()]=this}),x.support.enctype||(x.propFix.enctype="encoding"),x.each(["radio","checkbox"],function(){x.valHooks[this]={set:function(e,n){return x.isArray(n)?e.checked=x.inArray(x(e).val(),n)>=0:t}},x.support.checkOn||(x.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Z=/^(?:input|select|textarea)$/i,et=/^key/,tt=/^(?:mouse|contextmenu)|click/,nt=/^(?:focusinfocus|focusoutblur)$/,rt=/^([^.]*)(?:\.(.+)|)$/;function it(){return!0}function ot(){return!1}function at(){try{return a.activeElement}catch(e){}}x.event={global:{},add:function(e,n,r,o,a){var s,l,u,c,p,f,d,h,g,m,y,v=x._data(e);if(v){r.handler&&(c=r,r=c.handler,a=c.selector),r.guid||(r.guid=x.guid++),(l=v.events)||(l=v.events={}),(f=v.handle)||(f=v.handle=function(e){return typeof x===i||e&&x.event.triggered===e.type?t:x.event.dispatch.apply(f.elem,arguments)},f.elem=e),n=(n||"").match(T)||[""],u=n.length;while(u--)s=rt.exec(n[u])||[],g=y=s[1],m=(s[2]||"").split(".").sort(),g&&(p=x.event.special[g]||{},g=(a?p.delegateType:p.bindType)||g,p=x.event.special[g]||{},d=x.extend({type:g,origType:y,data:o,handler:r,guid:r.guid,selector:a,needsContext:a&&x.expr.match.needsContext.test(a),namespace:m.join(".")},c),(h=l[g])||(h=l[g]=[],h.delegateCount=0,p.setup&&p.setup.call(e,o,m,f)!==!1||(e.addEventListener?e.addEventListener(g,f,!1):e.attachEvent&&e.attachEvent("on"+g,f))),p.add&&(p.add.call(e,d),d.handler.guid||(d.handler.guid=r.guid)),a?h.splice(h.delegateCount++,0,d):h.push(d),x.event.global[g]=!0);e=null}},remove:function(e,t,n,r,i){var o,a,s,l,u,c,p,f,d,h,g,m=x.hasData(e)&&x._data(e);if(m&&(c=m.events)){t=(t||"").match(T)||[""],u=t.length;while(u--)if(s=rt.exec(t[u])||[],d=g=s[1],h=(s[2]||"").split(".").sort(),d){p=x.event.special[d]||{},d=(r?p.delegateType:p.bindType)||d,f=c[d]||[],s=s[2]&&RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=o=f.length;while(o--)a=f[o],!i&&g!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,p.remove&&p.remove.call(e,a));l&&!f.length&&(p.teardown&&p.teardown.call(e,h,m.handle)!==!1||x.removeEvent(e,d,m.handle),delete c[d])}else for(d in c)x.event.remove(e,d+t[u],n,r,!0);x.isEmptyObject(c)&&(delete m.handle,x._removeData(e,"events"))}},trigger:function(n,r,i,o){var s,l,u,c,p,f,d,h=[i||a],g=v.call(n,"type")?n.type:n,m=v.call(n,"namespace")?n.namespace.split("."):[];if(u=f=i=i||a,3!==i.nodeType&&8!==i.nodeType&&!nt.test(g+x.event.triggered)&&(g.indexOf(".")>=0&&(m=g.split("."),g=m.shift(),m.sort()),l=0>g.indexOf(":")&&"on"+g,n=n[x.expando]?n:new x.Event(g,"object"==typeof n&&n),n.isTrigger=o?2:3,n.namespace=m.join("."),n.namespace_re=n.namespace?RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,n.result=t,n.target||(n.target=i),r=null==r?[n]:x.makeArray(r,[n]),p=x.event.special[g]||{},o||!p.trigger||p.trigger.apply(i,r)!==!1)){if(!o&&!p.noBubble&&!x.isWindow(i)){for(c=p.delegateType||g,nt.test(c+g)||(u=u.parentNode);u;u=u.parentNode)h.push(u),f=u;f===(i.ownerDocument||a)&&h.push(f.defaultView||f.parentWindow||e)}d=0;while((u=h[d++])&&!n.isPropagationStopped())n.type=d>1?c:p.bindType||g,s=(x._data(u,"events")||{})[n.type]&&x._data(u,"handle"),s&&s.apply(u,r),s=l&&u[l],s&&x.acceptData(u)&&s.apply&&s.apply(u,r)===!1&&n.preventDefault();if(n.type=g,!o&&!n.isDefaultPrevented()&&(!p._default||p._default.apply(h.pop(),r)===!1)&&x.acceptData(i)&&l&&i[g]&&!x.isWindow(i)){f=i[l],f&&(i[l]=null),x.event.triggered=g;try{i[g]()}catch(y){}x.event.triggered=t,f&&(i[l]=f)}return n.result}},dispatch:function(e){e=x.event.fix(e);var n,r,i,o,a,s=[],l=g.call(arguments),u=(x._data(this,"events")||{})[e.type]||[],c=x.event.special[e.type]||{};if(l[0]=e,e.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,e)!==!1){s=x.event.handlers.call(this,e,u),n=0;while((o=s[n++])&&!e.isPropagationStopped()){e.currentTarget=o.elem,a=0;while((i=o.handlers[a++])&&!e.isImmediatePropagationStopped())(!e.namespace_re||e.namespace_re.test(i.namespace))&&(e.handleObj=i,e.data=i.data,r=((x.event.special[i.origType]||{}).handle||i.handler).apply(o.elem,l),r!==t&&(e.result=r)===!1&&(e.preventDefault(),e.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,n){var r,i,o,a,s=[],l=n.delegateCount,u=e.target;if(l&&u.nodeType&&(!e.button||"click"!==e.type))for(;u!=this;u=u.parentNode||this)if(1===u.nodeType&&(u.disabled!==!0||"click"!==e.type)){for(o=[],a=0;l>a;a++)i=n[a],r=i.selector+" ",o[r]===t&&(o[r]=i.needsContext?x(r,this).index(u)>=0:x.find(r,this,null,[u]).length),o[r]&&o.push(i);o.length&&s.push({elem:u,handlers:o})}return n.length>l&&s.push({elem:this,handlers:n.slice(l)}),s},fix:function(e){if(e[x.expando])return e;var t,n,r,i=e.type,o=e,s=this.fixHooks[i];s||(this.fixHooks[i]=s=tt.test(i)?this.mouseHooks:et.test(i)?this.keyHooks:{}),r=s.props?this.props.concat(s.props):this.props,e=new x.Event(o),t=r.length;while(t--)n=r[t],e[n]=o[n];return e.target||(e.target=o.srcElement||a),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,o):e},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,n){var r,i,o,s=n.button,l=n.fromElement;return null==e.pageX&&null!=n.clientX&&(i=e.target.ownerDocument||a,o=i.documentElement,r=i.body,e.pageX=n.clientX+(o&&o.scrollLeft||r&&r.scrollLeft||0)-(o&&o.clientLeft||r&&r.clientLeft||0),e.pageY=n.clientY+(o&&o.scrollTop||r&&r.scrollTop||0)-(o&&o.clientTop||r&&r.clientTop||0)),!e.relatedTarget&&l&&(e.relatedTarget=l===e.target?n.toElement:l),e.which||s===t||(e.which=1&s?1:2&s?3:4&s?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==at()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===at()&&this.blur?(this.blur(),!1):t},delegateType:"focusout"},click:{trigger:function(){return x.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):t},_default:function(e){return x.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){e.result!==t&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,r){var i=x.extend(new x.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?x.event.trigger(i,null,t):x.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},x.removeEvent=a.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]===i&&(e[r]=null),e.detachEvent(r,n))},x.Event=function(e,n){return this instanceof x.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.returnValue===!1||e.getPreventDefault&&e.getPreventDefault()?it:ot):this.type=e,n&&x.extend(this,n),this.timeStamp=e&&e.timeStamp||x.now(),this[x.expando]=!0,t):new x.Event(e,n)},x.Event.prototype={isDefaultPrevented:ot,isPropagationStopped:ot,isImmediatePropagationStopped:ot,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=it,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=it,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=it,this.stopPropagation()}},x.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(e,t){x.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return(!i||i!==r&&!x.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),x.support.submitBubbles||(x.event.special.submit={setup:function(){return x.nodeName(this,"form")?!1:(x.event.add(this,"click._submit keypress._submit",function(e){var n=e.target,r=x.nodeName(n,"input")||x.nodeName(n,"button")?n.form:t;r&&!x._data(r,"submitBubbles")&&(x.event.add(r,"submit._submit",function(e){e._submit_bubble=!0}),x._data(r,"submitBubbles",!0))}),t)},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&x.event.simulate("submit",this.parentNode,e,!0))},teardown:function(){return x.nodeName(this,"form")?!1:(x.event.remove(this,"._submit"),t)}}),x.support.changeBubbles||(x.event.special.change={setup:function(){return Z.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(x.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),x.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),x.event.simulate("change",this,e,!0)})),!1):(x.event.add(this,"beforeactivate._change",function(e){var t=e.target;Z.test(t.nodeName)&&!x._data(t,"changeBubbles")&&(x.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||x.event.simulate("change",this.parentNode,e,!0)}),x._data(t,"changeBubbles",!0))}),t)},handle:function(e){var n=e.target;return this!==n||e.isSimulated||e.isTrigger||"radio"!==n.type&&"checkbox"!==n.type?e.handleObj.handler.apply(this,arguments):t},teardown:function(){return x.event.remove(this,"._change"),!Z.test(this.nodeName)}}),x.support.focusinBubbles||x.each({focus:"focusin",blur:"focusout"},function(e,t){var n=0,r=function(e){x.event.simulate(t,e.target,x.event.fix(e),!0)};x.event.special[t]={setup:function(){0===n++&&a.addEventListener(e,r,!0)},teardown:function(){0===--n&&a.removeEventListener(e,r,!0)}}}),x.fn.extend({on:function(e,n,r,i,o){var a,s;if("object"==typeof e){"string"!=typeof n&&(r=r||n,n=t);for(a in e)this.on(a,n,r,e[a],o);return this}if(null==r&&null==i?(i=n,r=n=t):null==i&&("string"==typeof n?(i=r,r=t):(i=r,r=n,n=t)),i===!1)i=ot;else if(!i)return this;return 1===o&&(s=i,i=function(e){return x().off(e),s.apply(this,arguments)},i.guid=s.guid||(s.guid=x.guid++)),this.each(function(){x.event.add(this,e,i,r,n)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,n,r){var i,o;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,x(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof e){for(o in e)this.off(o,n,e[o]);return this}return(n===!1||"function"==typeof n)&&(r=n,n=t),r===!1&&(r=ot),this.each(function(){x.event.remove(this,e,r,n)})},trigger:function(e,t){return this.each(function(){x.event.trigger(e,t,this)})},triggerHandler:function(e,n){var r=this[0];return r?x.event.trigger(e,n,r,!0):t}});var st=/^.[^:#\[\.,]*$/,lt=/^(?:parents|prev(?:Until|All))/,ut=x.expr.match.needsContext,ct={children:!0,contents:!0,next:!0,prev:!0};x.fn.extend({find:function(e){var t,n=[],r=this,i=r.length;if("string"!=typeof e)return this.pushStack(x(e).filter(function(){for(t=0;i>t;t++)if(x.contains(r[t],this))return!0}));for(t=0;i>t;t++)x.find(e,r[t],n);return n=this.pushStack(i>1?x.unique(n):n),n.selector=this.selector?this.selector+" "+e:e,n},has:function(e){var t,n=x(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(x.contains(this,n[t]))return!0})},not:function(e){return this.pushStack(ft(this,e||[],!0))},filter:function(e){return this.pushStack(ft(this,e||[],!1))},is:function(e){return!!ft(this,"string"==typeof e&&ut.test(e)?x(e):e||[],!1).length},closest:function(e,t){var n,r=0,i=this.length,o=[],a=ut.test(e)||"string"!=typeof e?x(e,t||this.context):0;for(;i>r;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(11>n.nodeType&&(a?a.index(n)>-1:1===n.nodeType&&x.find.matchesSelector(n,e))){n=o.push(n);break}return this.pushStack(o.length>1?x.unique(o):o)},index:function(e){return e?"string"==typeof e?x.inArray(this[0],x(e)):x.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){var n="string"==typeof e?x(e,t):x.makeArray(e&&e.nodeType?[e]:e),r=x.merge(this.get(),n);return this.pushStack(x.unique(r))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}});function pt(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}x.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return x.dir(e,"parentNode")},parentsUntil:function(e,t,n){return x.dir(e,"parentNode",n)},next:function(e){return pt(e,"nextSibling")},prev:function(e){return pt(e,"previousSibling")},nextAll:function(e){return x.dir(e,"nextSibling")},prevAll:function(e){return x.dir(e,"previousSibling")},nextUntil:function(e,t,n){return x.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return x.dir(e,"previousSibling",n)},siblings:function(e){return x.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return x.sibling(e.firstChild)},contents:function(e){return x.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:x.merge([],e.childNodes)}},function(e,t){x.fn[e]=function(n,r){var i=x.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=x.filter(r,i)),this.length>1&&(ct[e]||(i=x.unique(i)),lt.test(e)&&(i=i.reverse())),this.pushStack(i)}}),x.extend({filter:function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?x.find.matchesSelector(r,e)?[r]:[]:x.find.matches(e,x.grep(t,function(e){return 1===e.nodeType}))},dir:function(e,n,r){var i=[],o=e[n];while(o&&9!==o.nodeType&&(r===t||1!==o.nodeType||!x(o).is(r)))1===o.nodeType&&i.push(o),o=o[n];return i},sibling:function(e,t){var n=[];for(;e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}});function ft(e,t,n){if(x.isFunction(t))return x.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return x.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(st.test(t))return x.filter(t,e,n);t=x.filter(t,e)}return x.grep(e,function(e){return x.inArray(e,t)>=0!==n})}function dt(e){var t=ht.split("|"),n=e.createDocumentFragment();if(n.createElement)while(t.length)n.createElement(t.pop());return n}var ht="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",gt=/ jQuery\d+="(?:null|\d+)"/g,mt=RegExp("<(?:"+ht+")[\\s/>]","i"),yt=/^\s+/,vt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bt=/<([\w:]+)/,xt=/<tbody/i,wt=/<|&#?\w+;/,Tt=/<(?:script|style|link)/i,Ct=/^(?:checkbox|radio)$/i,Nt=/checked\s*(?:[^=]|=\s*.checked.)/i,kt=/^$|\/(?:java|ecma)script/i,Et=/^true\/(.*)/,St=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,At={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:x.support.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},jt=dt(a),Dt=jt.appendChild(a.createElement("div"));At.optgroup=At.option,At.tbody=At.tfoot=At.colgroup=At.caption=At.thead,At.th=At.td,x.fn.extend({text:function(e){return x.access(this,function(e){return e===t?x.text(this):this.empty().append((this[0]&&this[0].ownerDocument||a).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){var n,r=e?x.filter(e,this):this,i=0;for(;null!=(n=r[i]);i++)t||1!==n.nodeType||x.cleanData(Ft(n)),n.parentNode&&(t&&x.contains(n.ownerDocument,n)&&_t(Ft(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){var e,t=0;for(;null!=(e=this[t]);t++){1===e.nodeType&&x.cleanData(Ft(e,!1));while(e.firstChild)e.removeChild(e.firstChild);e.options&&x.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return x.clone(this,e,t)})},html:function(e){return x.access(this,function(e){var n=this[0]||{},r=0,i=this.length;if(e===t)return 1===n.nodeType?n.innerHTML.replace(gt,""):t;if(!("string"!=typeof e||Tt.test(e)||!x.support.htmlSerialize&&mt.test(e)||!x.support.leadingWhitespace&&yt.test(e)||At[(bt.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(vt,"<$1></$2>");try{for(;i>r;r++)n=this[r]||{},1===n.nodeType&&(x.cleanData(Ft(n,!1)),n.innerHTML=e);n=0}catch(o){}}n&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=x.map(this,function(e){return[e.nextSibling,e.parentNode]}),t=0;return this.domManip(arguments,function(n){var r=e[t++],i=e[t++];i&&(r&&r.parentNode!==i&&(r=this.nextSibling),x(this).remove(),i.insertBefore(n,r))},!0),t?this:this.remove()},detach:function(e){return this.remove(e,!0)},domManip:function(e,t,n){e=d.apply([],e);var r,i,o,a,s,l,u=0,c=this.length,p=this,f=c-1,h=e[0],g=x.isFunction(h);if(g||!(1>=c||"string"!=typeof h||x.support.checkClone)&&Nt.test(h))return this.each(function(r){var i=p.eq(r);g&&(e[0]=h.call(this,r,i.html())),i.domManip(e,t,n)});if(c&&(l=x.buildFragment(e,this[0].ownerDocument,!1,!n&&this),r=l.firstChild,1===l.childNodes.length&&(l=r),r)){for(a=x.map(Ft(l,"script"),Ht),o=a.length;c>u;u++)i=l,u!==f&&(i=x.clone(i,!0,!0),o&&x.merge(a,Ft(i,"script"))),t.call(this[u],i,u);if(o)for(s=a[a.length-1].ownerDocument,x.map(a,qt),u=0;o>u;u++)i=a[u],kt.test(i.type||"")&&!x._data(i,"globalEval")&&x.contains(s,i)&&(i.src?x._evalUrl(i.src):x.globalEval((i.text||i.textContent||i.innerHTML||"").replace(St,"")));l=r=null}return this}});function Lt(e,t){return x.nodeName(e,"table")&&x.nodeName(1===t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function Ht(e){return e.type=(null!==x.find.attr(e,"type"))+"/"+e.type,e}function qt(e){var t=Et.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function _t(e,t){var n,r=0;for(;null!=(n=e[r]);r++)x._data(n,"globalEval",!t||x._data(t[r],"globalEval"))}function Mt(e,t){if(1===t.nodeType&&x.hasData(e)){var n,r,i,o=x._data(e),a=x._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)x.event.add(t,n,s[n][r])}a.data&&(a.data=x.extend({},a.data))}}function Ot(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!x.support.noCloneEvent&&t[x.expando]){i=x._data(t);for(r in i.events)x.removeEvent(t,r,i.handle);t.removeAttribute(x.expando)}"script"===n&&t.text!==e.text?(Ht(t).text=e.text,qt(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),x.support.html5Clone&&e.innerHTML&&!x.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&Ct.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}x.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){x.fn[e]=function(e){var n,r=0,i=[],o=x(e),a=o.length-1;for(;a>=r;r++)n=r===a?this:this.clone(!0),x(o[r])[t](n),h.apply(i,n.get());return this.pushStack(i)}});function Ft(e,n){var r,o,a=0,s=typeof e.getElementsByTagName!==i?e.getElementsByTagName(n||"*"):typeof e.querySelectorAll!==i?e.querySelectorAll(n||"*"):t;if(!s)for(s=[],r=e.childNodes||e;null!=(o=r[a]);a++)!n||x.nodeName(o,n)?s.push(o):x.merge(s,Ft(o,n));return n===t||n&&x.nodeName(e,n)?x.merge([e],s):s}function Bt(e){Ct.test(e.type)&&(e.defaultChecked=e.checked)}x.extend({clone:function(e,t,n){var r,i,o,a,s,l=x.contains(e.ownerDocument,e);if(x.support.html5Clone||x.isXMLDoc(e)||!mt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Dt.innerHTML=e.outerHTML,Dt.removeChild(o=Dt.firstChild)),!(x.support.noCloneEvent&&x.support.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||x.isXMLDoc(e)))for(r=Ft(o),s=Ft(e),a=0;null!=(i=s[a]);++a)r[a]&&Ot(i,r[a]);if(t)if(n)for(s=s||Ft(e),r=r||Ft(o),a=0;null!=(i=s[a]);a++)Mt(i,r[a]);else Mt(e,o);return r=Ft(o,"script"),r.length>0&&_t(r,!l&&Ft(e,"script")),r=s=i=null,o},buildFragment:function(e,t,n,r){var i,o,a,s,l,u,c,p=e.length,f=dt(t),d=[],h=0;for(;p>h;h++)if(o=e[h],o||0===o)if("object"===x.type(o))x.merge(d,o.nodeType?[o]:o);else if(wt.test(o)){s=s||f.appendChild(t.createElement("div")),l=(bt.exec(o)||["",""])[1].toLowerCase(),c=At[l]||At._default,s.innerHTML=c[1]+o.replace(vt,"<$1></$2>")+c[2],i=c[0];while(i--)s=s.lastChild;if(!x.support.leadingWhitespace&&yt.test(o)&&d.push(t.createTextNode(yt.exec(o)[0])),!x.support.tbody){o="table"!==l||xt.test(o)?"<table>"!==c[1]||xt.test(o)?0:s:s.firstChild,i=o&&o.childNodes.length;while(i--)x.nodeName(u=o.childNodes[i],"tbody")&&!u.childNodes.length&&o.removeChild(u)}x.merge(d,s.childNodes),s.textContent="";while(s.firstChild)s.removeChild(s.firstChild);s=f.lastChild}else d.push(t.createTextNode(o));s&&f.removeChild(s),x.support.appendChecked||x.grep(Ft(d,"input"),Bt),h=0;while(o=d[h++])if((!r||-1===x.inArray(o,r))&&(a=x.contains(o.ownerDocument,o),s=Ft(f.appendChild(o),"script"),a&&_t(s),n)){i=0;while(o=s[i++])kt.test(o.type||"")&&n.push(o)}return s=null,f},cleanData:function(e,t){var n,r,o,a,s=0,l=x.expando,u=x.cache,c=x.support.deleteExpando,f=x.event.special;for(;null!=(n=e[s]);s++)if((t||x.acceptData(n))&&(o=n[l],a=o&&u[o])){if(a.events)for(r in a.events)f[r]?x.event.remove(n,r):x.removeEvent(n,r,a.handle);
|
6 |
+
u[o]&&(delete u[o],c?delete n[l]:typeof n.removeAttribute!==i?n.removeAttribute(l):n[l]=null,p.push(o))}},_evalUrl:function(e){return x.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})}}),x.fn.extend({wrapAll:function(e){if(x.isFunction(e))return this.each(function(t){x(this).wrapAll(e.call(this,t))});if(this[0]){var t=x(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstChild&&1===e.firstChild.nodeType)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return x.isFunction(e)?this.each(function(t){x(this).wrapInner(e.call(this,t))}):this.each(function(){var t=x(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=x.isFunction(e);return this.each(function(n){x(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){x.nodeName(this,"body")||x(this).replaceWith(this.childNodes)}).end()}});var Pt,Rt,Wt,$t=/alpha\([^)]*\)/i,It=/opacity\s*=\s*([^)]*)/,zt=/^(top|right|bottom|left)$/,Xt=/^(none|table(?!-c[ea]).+)/,Ut=/^margin/,Vt=RegExp("^("+w+")(.*)$","i"),Yt=RegExp("^("+w+")(?!px)[a-z%]+$","i"),Jt=RegExp("^([+-])=("+w+")","i"),Gt={BODY:"block"},Qt={position:"absolute",visibility:"hidden",display:"block"},Kt={letterSpacing:0,fontWeight:400},Zt=["Top","Right","Bottom","Left"],en=["Webkit","O","Moz","ms"];function tn(e,t){if(t in e)return t;var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=en.length;while(i--)if(t=en[i]+n,t in e)return t;return r}function nn(e,t){return e=t||e,"none"===x.css(e,"display")||!x.contains(e.ownerDocument,e)}function rn(e,t){var n,r,i,o=[],a=0,s=e.length;for(;s>a;a++)r=e[a],r.style&&(o[a]=x._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&nn(r)&&(o[a]=x._data(r,"olddisplay",ln(r.nodeName)))):o[a]||(i=nn(r),(n&&"none"!==n||!i)&&x._data(r,"olddisplay",i?n:x.css(r,"display"))));for(a=0;s>a;a++)r=e[a],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}x.fn.extend({css:function(e,n){return x.access(this,function(e,n,r){var i,o,a={},s=0;if(x.isArray(n)){for(o=Rt(e),i=n.length;i>s;s++)a[n[s]]=x.css(e,n[s],!1,o);return a}return r!==t?x.style(e,n,r):x.css(e,n)},e,n,arguments.length>1)},show:function(){return rn(this,!0)},hide:function(){return rn(this)},toggle:function(e){var t="boolean"==typeof e;return this.each(function(){(t?e:nn(this))?x(this).show():x(this).hide()})}}),x.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Wt(e,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":x.support.cssFloat?"cssFloat":"styleFloat"},style:function(e,n,r,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,a,s,l=x.camelCase(n),u=e.style;if(n=x.cssProps[l]||(x.cssProps[l]=tn(u,l)),s=x.cssHooks[n]||x.cssHooks[l],r===t)return s&&"get"in s&&(o=s.get(e,!1,i))!==t?o:u[n];if(a=typeof r,"string"===a&&(o=Jt.exec(r))&&(r=(o[1]+1)*o[2]+parseFloat(x.css(e,n)),a="number"),!(null==r||"number"===a&&isNaN(r)||("number"!==a||x.cssNumber[l]||(r+="px"),x.support.clearCloneStyle||""!==r||0!==n.indexOf("background")||(u[n]="inherit"),s&&"set"in s&&(r=s.set(e,r,i))===t)))try{u[n]=r}catch(c){}}},css:function(e,n,r,i){var o,a,s,l=x.camelCase(n);return n=x.cssProps[l]||(x.cssProps[l]=tn(e.style,l)),s=x.cssHooks[n]||x.cssHooks[l],s&&"get"in s&&(a=s.get(e,!0,r)),a===t&&(a=Wt(e,n,i)),"normal"===a&&n in Kt&&(a=Kt[n]),""===r||r?(o=parseFloat(a),r===!0||x.isNumeric(o)?o||0:a):a}}),e.getComputedStyle?(Rt=function(t){return e.getComputedStyle(t,null)},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s.getPropertyValue(n)||s[n]:t,u=e.style;return s&&(""!==l||x.contains(e.ownerDocument,e)||(l=x.style(e,n)),Yt.test(l)&&Ut.test(n)&&(i=u.width,o=u.minWidth,a=u.maxWidth,u.minWidth=u.maxWidth=u.width=l,l=s.width,u.width=i,u.minWidth=o,u.maxWidth=a)),l}):a.documentElement.currentStyle&&(Rt=function(e){return e.currentStyle},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s[n]:t,u=e.style;return null==l&&u&&u[n]&&(l=u[n]),Yt.test(l)&&!zt.test(n)&&(i=u.left,o=e.runtimeStyle,a=o&&o.left,a&&(o.left=e.currentStyle.left),u.left="fontSize"===n?"1em":l,l=u.pixelLeft+"px",u.left=i,a&&(o.left=a)),""===l?"auto":l});function on(e,t,n){var r=Vt.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function an(e,t,n,r,i){var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;for(;4>o;o+=2)"margin"===n&&(a+=x.css(e,n+Zt[o],!0,i)),r?("content"===n&&(a-=x.css(e,"padding"+Zt[o],!0,i)),"margin"!==n&&(a-=x.css(e,"border"+Zt[o]+"Width",!0,i))):(a+=x.css(e,"padding"+Zt[o],!0,i),"padding"!==n&&(a+=x.css(e,"border"+Zt[o]+"Width",!0,i)));return a}function sn(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=Rt(e),a=x.support.boxSizing&&"border-box"===x.css(e,"boxSizing",!1,o);if(0>=i||null==i){if(i=Wt(e,t,o),(0>i||null==i)&&(i=e.style[t]),Yt.test(i))return i;r=a&&(x.support.boxSizingReliable||i===e.style[t]),i=parseFloat(i)||0}return i+an(e,t,n||(a?"border":"content"),r,o)+"px"}function ln(e){var t=a,n=Gt[e];return n||(n=un(e,t),"none"!==n&&n||(Pt=(Pt||x("<iframe frameborder='0' width='0' height='0'/>").css("cssText","display:block !important")).appendTo(t.documentElement),t=(Pt[0].contentWindow||Pt[0].contentDocument).document,t.write("<!doctype html><html><body>"),t.close(),n=un(e,t),Pt.detach()),Gt[e]=n),n}function un(e,t){var n=x(t.createElement(e)).appendTo(t.body),r=x.css(n[0],"display");return n.remove(),r}x.each(["height","width"],function(e,n){x.cssHooks[n]={get:function(e,r,i){return r?0===e.offsetWidth&&Xt.test(x.css(e,"display"))?x.swap(e,Qt,function(){return sn(e,n,i)}):sn(e,n,i):t},set:function(e,t,r){var i=r&&Rt(e);return on(e,t,r?an(e,n,r,x.support.boxSizing&&"border-box"===x.css(e,"boxSizing",!1,i),i):0)}}}),x.support.opacity||(x.cssHooks.opacity={get:function(e,t){return It.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=x.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=r&&r.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===x.trim(o.replace($t,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||r&&!r.filter)||(n.filter=$t.test(o)?o.replace($t,i):o+" "+i)}}),x(function(){x.support.reliableMarginRight||(x.cssHooks.marginRight={get:function(e,n){return n?x.swap(e,{display:"inline-block"},Wt,[e,"marginRight"]):t}}),!x.support.pixelPosition&&x.fn.position&&x.each(["top","left"],function(e,n){x.cssHooks[n]={get:function(e,r){return r?(r=Wt(e,n),Yt.test(r)?x(e).position()[n]+"px":r):t}}})}),x.expr&&x.expr.filters&&(x.expr.filters.hidden=function(e){return 0>=e.offsetWidth&&0>=e.offsetHeight||!x.support.reliableHiddenOffsets&&"none"===(e.style&&e.style.display||x.css(e,"display"))},x.expr.filters.visible=function(e){return!x.expr.filters.hidden(e)}),x.each({margin:"",padding:"",border:"Width"},function(e,t){x.cssHooks[e+t]={expand:function(n){var r=0,i={},o="string"==typeof n?n.split(" "):[n];for(;4>r;r++)i[e+Zt[r]+t]=o[r]||o[r-2]||o[0];return i}},Ut.test(e)||(x.cssHooks[e+t].set=on)});var cn=/%20/g,pn=/\[\]$/,fn=/\r?\n/g,dn=/^(?:submit|button|image|reset|file)$/i,hn=/^(?:input|select|textarea|keygen)/i;x.fn.extend({serialize:function(){return x.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=x.prop(this,"elements");return e?x.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!x(this).is(":disabled")&&hn.test(this.nodeName)&&!dn.test(e)&&(this.checked||!Ct.test(e))}).map(function(e,t){var n=x(this).val();return null==n?null:x.isArray(n)?x.map(n,function(e){return{name:t.name,value:e.replace(fn,"\r\n")}}):{name:t.name,value:n.replace(fn,"\r\n")}}).get()}}),x.param=function(e,n){var r,i=[],o=function(e,t){t=x.isFunction(t)?t():null==t?"":t,i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(n===t&&(n=x.ajaxSettings&&x.ajaxSettings.traditional),x.isArray(e)||e.jquery&&!x.isPlainObject(e))x.each(e,function(){o(this.name,this.value)});else for(r in e)gn(r,e[r],n,o);return i.join("&").replace(cn,"+")};function gn(e,t,n,r){var i;if(x.isArray(t))x.each(t,function(t,i){n||pn.test(e)?r(e,i):gn(e+"["+("object"==typeof i?t:"")+"]",i,n,r)});else if(n||"object"!==x.type(t))r(e,t);else for(i in t)gn(e+"["+i+"]",t[i],n,r)}x.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(e,t){x.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),x.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}});var mn,yn,vn=x.now(),bn=/\?/,xn=/#.*$/,wn=/([?&])_=[^&]*/,Tn=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Cn=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Nn=/^(?:GET|HEAD)$/,kn=/^\/\//,En=/^([\w.+-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,Sn=x.fn.load,An={},jn={},Dn="*/".concat("*");try{yn=o.href}catch(Ln){yn=a.createElement("a"),yn.href="",yn=yn.href}mn=En.exec(yn.toLowerCase())||[];function Hn(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(T)||[];if(x.isFunction(n))while(r=o[i++])"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function qn(e,n,r,i){var o={},a=e===jn;function s(l){var u;return o[l]=!0,x.each(e[l]||[],function(e,l){var c=l(n,r,i);return"string"!=typeof c||a||o[c]?a?!(u=c):t:(n.dataTypes.unshift(c),s(c),!1)}),u}return s(n.dataTypes[0])||!o["*"]&&s("*")}function _n(e,n){var r,i,o=x.ajaxSettings.flatOptions||{};for(i in n)n[i]!==t&&((o[i]?e:r||(r={}))[i]=n[i]);return r&&x.extend(!0,e,r),e}x.fn.load=function(e,n,r){if("string"!=typeof e&&Sn)return Sn.apply(this,arguments);var i,o,a,s=this,l=e.indexOf(" ");return l>=0&&(i=e.slice(l,e.length),e=e.slice(0,l)),x.isFunction(n)?(r=n,n=t):n&&"object"==typeof n&&(a="POST"),s.length>0&&x.ajax({url:e,type:a,dataType:"html",data:n}).done(function(e){o=arguments,s.html(i?x("<div>").append(x.parseHTML(e)).find(i):e)}).complete(r&&function(e,t){s.each(r,o||[e.responseText,t,e])}),this},x.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){x.fn[t]=function(e){return this.on(t,e)}}),x.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:yn,type:"GET",isLocal:Cn.test(mn[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Dn,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":x.parseJSON,"text xml":x.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?_n(_n(e,x.ajaxSettings),t):_n(x.ajaxSettings,e)},ajaxPrefilter:Hn(An),ajaxTransport:Hn(jn),ajax:function(e,n){"object"==typeof e&&(n=e,e=t),n=n||{};var r,i,o,a,s,l,u,c,p=x.ajaxSetup({},n),f=p.context||p,d=p.context&&(f.nodeType||f.jquery)?x(f):x.event,h=x.Deferred(),g=x.Callbacks("once memory"),m=p.statusCode||{},y={},v={},b=0,w="canceled",C={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!c){c={};while(t=Tn.exec(a))c[t[1].toLowerCase()]=t[2]}t=c[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return b||(e=v[n]=v[n]||e,y[e]=t),this},overrideMimeType:function(e){return b||(p.mimeType=e),this},statusCode:function(e){var t;if(e)if(2>b)for(t in e)m[t]=[m[t],e[t]];else C.always(e[C.status]);return this},abort:function(e){var t=e||w;return u&&u.abort(t),k(0,t),this}};if(h.promise(C).complete=g.add,C.success=C.done,C.error=C.fail,p.url=((e||p.url||yn)+"").replace(xn,"").replace(kn,mn[1]+"//"),p.type=n.method||n.type||p.method||p.type,p.dataTypes=x.trim(p.dataType||"*").toLowerCase().match(T)||[""],null==p.crossDomain&&(r=En.exec(p.url.toLowerCase()),p.crossDomain=!(!r||r[1]===mn[1]&&r[2]===mn[2]&&(r[3]||("http:"===r[1]?"80":"443"))===(mn[3]||("http:"===mn[1]?"80":"443")))),p.data&&p.processData&&"string"!=typeof p.data&&(p.data=x.param(p.data,p.traditional)),qn(An,p,n,C),2===b)return C;l=p.global,l&&0===x.active++&&x.event.trigger("ajaxStart"),p.type=p.type.toUpperCase(),p.hasContent=!Nn.test(p.type),o=p.url,p.hasContent||(p.data&&(o=p.url+=(bn.test(o)?"&":"?")+p.data,delete p.data),p.cache===!1&&(p.url=wn.test(o)?o.replace(wn,"$1_="+vn++):o+(bn.test(o)?"&":"?")+"_="+vn++)),p.ifModified&&(x.lastModified[o]&&C.setRequestHeader("If-Modified-Since",x.lastModified[o]),x.etag[o]&&C.setRequestHeader("If-None-Match",x.etag[o])),(p.data&&p.hasContent&&p.contentType!==!1||n.contentType)&&C.setRequestHeader("Content-Type",p.contentType),C.setRequestHeader("Accept",p.dataTypes[0]&&p.accepts[p.dataTypes[0]]?p.accepts[p.dataTypes[0]]+("*"!==p.dataTypes[0]?", "+Dn+"; q=0.01":""):p.accepts["*"]);for(i in p.headers)C.setRequestHeader(i,p.headers[i]);if(p.beforeSend&&(p.beforeSend.call(f,C,p)===!1||2===b))return C.abort();w="abort";for(i in{success:1,error:1,complete:1})C[i](p[i]);if(u=qn(jn,p,n,C)){C.readyState=1,l&&d.trigger("ajaxSend",[C,p]),p.async&&p.timeout>0&&(s=setTimeout(function(){C.abort("timeout")},p.timeout));try{b=1,u.send(y,k)}catch(N){if(!(2>b))throw N;k(-1,N)}}else k(-1,"No Transport");function k(e,n,r,i){var c,y,v,w,T,N=n;2!==b&&(b=2,s&&clearTimeout(s),u=t,a=i||"",C.readyState=e>0?4:0,c=e>=200&&300>e||304===e,r&&(w=Mn(p,C,r)),w=On(p,w,C,c),c?(p.ifModified&&(T=C.getResponseHeader("Last-Modified"),T&&(x.lastModified[o]=T),T=C.getResponseHeader("etag"),T&&(x.etag[o]=T)),204===e||"HEAD"===p.type?N="nocontent":304===e?N="notmodified":(N=w.state,y=w.data,v=w.error,c=!v)):(v=N,(e||!N)&&(N="error",0>e&&(e=0))),C.status=e,C.statusText=(n||N)+"",c?h.resolveWith(f,[y,N,C]):h.rejectWith(f,[C,N,v]),C.statusCode(m),m=t,l&&d.trigger(c?"ajaxSuccess":"ajaxError",[C,p,c?y:v]),g.fireWith(f,[C,N]),l&&(d.trigger("ajaxComplete",[C,p]),--x.active||x.event.trigger("ajaxStop")))}return C},getJSON:function(e,t,n){return x.get(e,t,n,"json")},getScript:function(e,n){return x.get(e,t,n,"script")}}),x.each(["get","post"],function(e,n){x[n]=function(e,r,i,o){return x.isFunction(r)&&(o=o||i,i=r,r=t),x.ajax({url:e,type:n,dataType:o,data:r,success:i})}});function Mn(e,n,r){var i,o,a,s,l=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),o===t&&(o=e.mimeType||n.getResponseHeader("Content-Type"));if(o)for(s in l)if(l[s]&&l[s].test(o)){u.unshift(s);break}if(u[0]in r)a=u[0];else{for(s in r){if(!u[0]||e.converters[s+" "+u[0]]){a=s;break}i||(i=s)}a=a||i}return a?(a!==u[0]&&u.unshift(a),r[a]):t}function On(e,t,n,r){var i,o,a,s,l,u={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)u[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!l&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=o,o=c.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(a=u[l+" "+o]||u["* "+o],!a)for(i in u)if(s=i.split(" "),s[1]===o&&(a=u[l+" "+s[0]]||u["* "+s[0]])){a===!0?a=u[i]:u[i]!==!0&&(o=s[0],c.unshift(s[1]));break}if(a!==!0)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(p){return{state:"parsererror",error:a?p:"No conversion from "+l+" to "+o}}}return{state:"success",data:t}}x.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return x.globalEval(e),e}}}),x.ajaxPrefilter("script",function(e){e.cache===t&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),x.ajaxTransport("script",function(e){if(e.crossDomain){var n,r=a.head||x("head")[0]||a.documentElement;return{send:function(t,i){n=a.createElement("script"),n.async=!0,e.scriptCharset&&(n.charset=e.scriptCharset),n.src=e.url,n.onload=n.onreadystatechange=function(e,t){(t||!n.readyState||/loaded|complete/.test(n.readyState))&&(n.onload=n.onreadystatechange=null,n.parentNode&&n.parentNode.removeChild(n),n=null,t||i(200,"success"))},r.insertBefore(n,r.firstChild)},abort:function(){n&&n.onload(t,!0)}}}});var Fn=[],Bn=/(=)\?(?=&|$)|\?\?/;x.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Fn.pop()||x.expando+"_"+vn++;return this[e]=!0,e}}),x.ajaxPrefilter("json jsonp",function(n,r,i){var o,a,s,l=n.jsonp!==!1&&(Bn.test(n.url)?"url":"string"==typeof n.data&&!(n.contentType||"").indexOf("application/x-www-form-urlencoded")&&Bn.test(n.data)&&"data");return l||"jsonp"===n.dataTypes[0]?(o=n.jsonpCallback=x.isFunction(n.jsonpCallback)?n.jsonpCallback():n.jsonpCallback,l?n[l]=n[l].replace(Bn,"$1"+o):n.jsonp!==!1&&(n.url+=(bn.test(n.url)?"&":"?")+n.jsonp+"="+o),n.converters["script json"]=function(){return s||x.error(o+" was not called"),s[0]},n.dataTypes[0]="json",a=e[o],e[o]=function(){s=arguments},i.always(function(){e[o]=a,n[o]&&(n.jsonpCallback=r.jsonpCallback,Fn.push(o)),s&&x.isFunction(a)&&a(s[0]),s=a=t}),"script"):t});var Pn,Rn,Wn=0,$n=e.ActiveXObject&&function(){var e;for(e in Pn)Pn[e](t,!0)};function In(){try{return new e.XMLHttpRequest}catch(t){}}function zn(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}x.ajaxSettings.xhr=e.ActiveXObject?function(){return!this.isLocal&&In()||zn()}:In,Rn=x.ajaxSettings.xhr(),x.support.cors=!!Rn&&"withCredentials"in Rn,Rn=x.support.ajax=!!Rn,Rn&&x.ajaxTransport(function(n){if(!n.crossDomain||x.support.cors){var r;return{send:function(i,o){var a,s,l=n.xhr();if(n.username?l.open(n.type,n.url,n.async,n.username,n.password):l.open(n.type,n.url,n.async),n.xhrFields)for(s in n.xhrFields)l[s]=n.xhrFields[s];n.mimeType&&l.overrideMimeType&&l.overrideMimeType(n.mimeType),n.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");try{for(s in i)l.setRequestHeader(s,i[s])}catch(u){}l.send(n.hasContent&&n.data||null),r=function(e,i){var s,u,c,p;try{if(r&&(i||4===l.readyState))if(r=t,a&&(l.onreadystatechange=x.noop,$n&&delete Pn[a]),i)4!==l.readyState&&l.abort();else{p={},s=l.status,u=l.getAllResponseHeaders(),"string"==typeof l.responseText&&(p.text=l.responseText);try{c=l.statusText}catch(f){c=""}s||!n.isLocal||n.crossDomain?1223===s&&(s=204):s=p.text?200:404}}catch(d){i||o(-1,d)}p&&o(s,c,p,u)},n.async?4===l.readyState?setTimeout(r):(a=++Wn,$n&&(Pn||(Pn={},x(e).unload($n)),Pn[a]=r),l.onreadystatechange=r):r()},abort:function(){r&&r(t,!0)}}}});var Xn,Un,Vn=/^(?:toggle|show|hide)$/,Yn=RegExp("^(?:([+-])=|)("+w+")([a-z%]*)$","i"),Jn=/queueHooks$/,Gn=[nr],Qn={"*":[function(e,t){var n=this.createTween(e,t),r=n.cur(),i=Yn.exec(t),o=i&&i[3]||(x.cssNumber[e]?"":"px"),a=(x.cssNumber[e]||"px"!==o&&+r)&&Yn.exec(x.css(n.elem,e)),s=1,l=20;if(a&&a[3]!==o){o=o||a[3],i=i||[],a=+r||1;do s=s||".5",a/=s,x.style(n.elem,e,a+o);while(s!==(s=n.cur()/r)&&1!==s&&--l)}return i&&(a=n.start=+a||+r||0,n.unit=o,n.end=i[1]?a+(i[1]+1)*i[2]:+i[2]),n}]};function Kn(){return setTimeout(function(){Xn=t}),Xn=x.now()}function Zn(e,t,n){var r,i=(Qn[t]||[]).concat(Qn["*"]),o=0,a=i.length;for(;a>o;o++)if(r=i[o].call(n,t,e))return r}function er(e,t,n){var r,i,o=0,a=Gn.length,s=x.Deferred().always(function(){delete l.elem}),l=function(){if(i)return!1;var t=Xn||Kn(),n=Math.max(0,u.startTime+u.duration-t),r=n/u.duration||0,o=1-r,a=0,l=u.tweens.length;for(;l>a;a++)u.tweens[a].run(o);return s.notifyWith(e,[u,o,n]),1>o&&l?n:(s.resolveWith(e,[u]),!1)},u=s.promise({elem:e,props:x.extend({},t),opts:x.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:Xn||Kn(),duration:n.duration,tweens:[],createTween:function(t,n){var r=x.Tween(e,u.opts,t,n,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(r),r},stop:function(t){var n=0,r=t?u.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)u.tweens[n].run(1);return t?s.resolveWith(e,[u,t]):s.rejectWith(e,[u,t]),this}}),c=u.props;for(tr(c,u.opts.specialEasing);a>o;o++)if(r=Gn[o].call(u,e,c,u.opts))return r;return x.map(c,Zn,u),x.isFunction(u.opts.start)&&u.opts.start.call(e,u),x.fx.timer(x.extend(l,{elem:e,anim:u,queue:u.opts.queue})),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always)}function tr(e,t){var n,r,i,o,a;for(n in e)if(r=x.camelCase(n),i=t[r],o=e[n],x.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),a=x.cssHooks[r],a&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}x.Animation=x.extend(er,{tweener:function(e,t){x.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");var n,r=0,i=e.length;for(;i>r;r++)n=e[r],Qn[n]=Qn[n]||[],Qn[n].unshift(t)},prefilter:function(e,t){t?Gn.unshift(e):Gn.push(e)}});function nr(e,t,n){var r,i,o,a,s,l,u=this,c={},p=e.style,f=e.nodeType&&nn(e),d=x._data(e,"fxshow");n.queue||(s=x._queueHooks(e,"fx"),null==s.unqueued&&(s.unqueued=0,l=s.empty.fire,s.empty.fire=function(){s.unqueued||l()}),s.unqueued++,u.always(function(){u.always(function(){s.unqueued--,x.queue(e,"fx").length||s.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],"inline"===x.css(e,"display")&&"none"===x.css(e,"float")&&(x.support.inlineBlockNeedsLayout&&"inline"!==ln(e.nodeName)?p.zoom=1:p.display="inline-block")),n.overflow&&(p.overflow="hidden",x.support.shrinkWrapBlocks||u.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}));for(r in t)if(i=t[r],Vn.exec(i)){if(delete t[r],o=o||"toggle"===i,i===(f?"hide":"show"))continue;c[r]=d&&d[r]||x.style(e,r)}if(!x.isEmptyObject(c)){d?"hidden"in d&&(f=d.hidden):d=x._data(e,"fxshow",{}),o&&(d.hidden=!f),f?x(e).show():u.done(function(){x(e).hide()}),u.done(function(){var t;x._removeData(e,"fxshow");for(t in c)x.style(e,t,c[t])});for(r in c)a=Zn(f?d[r]:0,r,u),r in d||(d[r]=a.start,f&&(a.end=a.start,a.start="width"===r||"height"===r?1:0))}}function rr(e,t,n,r,i){return new rr.prototype.init(e,t,n,r,i)}x.Tween=rr,rr.prototype={constructor:rr,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(x.cssNumber[n]?"":"px")},cur:function(){var e=rr.propHooks[this.prop];return e&&e.get?e.get(this):rr.propHooks._default.get(this)},run:function(e){var t,n=rr.propHooks[this.prop];return this.pos=t=this.options.duration?x.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):rr.propHooks._default.set(this),this}},rr.prototype.init.prototype=rr.prototype,rr.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=x.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){x.fx.step[e.prop]?x.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[x.cssProps[e.prop]]||x.cssHooks[e.prop])?x.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},rr.propHooks.scrollTop=rr.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},x.each(["toggle","show","hide"],function(e,t){var n=x.fn[t];x.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(ir(t,!0),e,r,i)}}),x.fn.extend({fadeTo:function(e,t,n,r){return this.filter(nn).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=x.isEmptyObject(e),o=x.speed(t,n,r),a=function(){var t=er(this,x.extend({},e),o);(i||x._data(this,"finish"))&&t.stop(!0)};return a.finish=a,i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,n,r){var i=function(e){var t=e.stop;delete e.stop,t(r)};return"string"!=typeof e&&(r=n,n=e,e=t),n&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,n=null!=e&&e+"queueHooks",o=x.timers,a=x._data(this);if(n)a[n]&&a[n].stop&&i(a[n]);else for(n in a)a[n]&&a[n].stop&&Jn.test(n)&&i(a[n]);for(n=o.length;n--;)o[n].elem!==this||null!=e&&o[n].queue!==e||(o[n].anim.stop(r),t=!1,o.splice(n,1));(t||!r)&&x.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=x._data(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=x.timers,a=r?r.length:0;for(n.finish=!0,x.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}});function ir(e,t){var n,r={height:e},i=0;for(t=t?1:0;4>i;i+=2-t)n=Zt[i],r["margin"+n]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}x.each({slideDown:ir("show"),slideUp:ir("hide"),slideToggle:ir("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){x.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),x.speed=function(e,t,n){var r=e&&"object"==typeof e?x.extend({},e):{complete:n||!n&&t||x.isFunction(e)&&e,duration:e,easing:n&&t||t&&!x.isFunction(t)&&t};return r.duration=x.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in x.fx.speeds?x.fx.speeds[r.duration]:x.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){x.isFunction(r.old)&&r.old.call(this),r.queue&&x.dequeue(this,r.queue)},r},x.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},x.timers=[],x.fx=rr.prototype.init,x.fx.tick=function(){var e,n=x.timers,r=0;for(Xn=x.now();n.length>r;r++)e=n[r],e()||n[r]!==e||n.splice(r--,1);n.length||x.fx.stop(),Xn=t},x.fx.timer=function(e){e()&&x.timers.push(e)&&x.fx.start()},x.fx.interval=13,x.fx.start=function(){Un||(Un=setInterval(x.fx.tick,x.fx.interval))},x.fx.stop=function(){clearInterval(Un),Un=null},x.fx.speeds={slow:600,fast:200,_default:400},x.fx.step={},x.expr&&x.expr.filters&&(x.expr.filters.animated=function(e){return x.grep(x.timers,function(t){return e===t.elem}).length}),x.fn.offset=function(e){if(arguments.length)return e===t?this:this.each(function(t){x.offset.setOffset(this,e,t)});var n,r,o={top:0,left:0},a=this[0],s=a&&a.ownerDocument;if(s)return n=s.documentElement,x.contains(n,a)?(typeof a.getBoundingClientRect!==i&&(o=a.getBoundingClientRect()),r=or(s),{top:o.top+(r.pageYOffset||n.scrollTop)-(n.clientTop||0),left:o.left+(r.pageXOffset||n.scrollLeft)-(n.clientLeft||0)}):o},x.offset={setOffset:function(e,t,n){var r=x.css(e,"position");"static"===r&&(e.style.position="relative");var i=x(e),o=i.offset(),a=x.css(e,"top"),s=x.css(e,"left"),l=("absolute"===r||"fixed"===r)&&x.inArray("auto",[a,s])>-1,u={},c={},p,f;l?(c=i.position(),p=c.top,f=c.left):(p=parseFloat(a)||0,f=parseFloat(s)||0),x.isFunction(t)&&(t=t.call(e,n,o)),null!=t.top&&(u.top=t.top-o.top+p),null!=t.left&&(u.left=t.left-o.left+f),"using"in t?t.using.call(e,u):i.css(u)}},x.fn.extend({position:function(){if(this[0]){var e,t,n={top:0,left:0},r=this[0];return"fixed"===x.css(r,"position")?t=r.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),x.nodeName(e[0],"html")||(n=e.offset()),n.top+=x.css(e[0],"borderTopWidth",!0),n.left+=x.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-x.css(r,"marginTop",!0),left:t.left-n.left-x.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent||s;while(e&&!x.nodeName(e,"html")&&"static"===x.css(e,"position"))e=e.offsetParent;return e||s})}}),x.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,n){var r=/Y/.test(n);x.fn[e]=function(i){return x.access(this,function(e,i,o){var a=or(e);return o===t?a?n in a?a[n]:a.document.documentElement[i]:e[i]:(a?a.scrollTo(r?x(a).scrollLeft():o,r?o:x(a).scrollTop()):e[i]=o,t)},e,i,arguments.length,null)}});function or(e){return x.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}x.each({Height:"height",Width:"width"},function(e,n){x.each({padding:"inner"+e,content:n,"":"outer"+e},function(r,i){x.fn[i]=function(i,o){var a=arguments.length&&(r||"boolean"!=typeof i),s=r||(i===!0||o===!0?"margin":"border");return x.access(this,function(n,r,i){var o;return x.isWindow(n)?n.document.documentElement["client"+e]:9===n.nodeType?(o=n.documentElement,Math.max(n.body["scroll"+e],o["scroll"+e],n.body["offset"+e],o["offset"+e],o["client"+e])):i===t?x.css(n,r,s):x.style(n,r,i,s)},n,a?i:t,a,null)}})}),x.fn.size=function(){return this.length},x.fn.andSelf=x.fn.addBack,"object"==typeof module&&module&&"object"==typeof module.exports?module.exports=x:(e.jQuery=e.$=x,"function"==typeof define&&define.amd&&define("jquery",[],function(){return x}))})(window);
|
skin/adminhtml/default/default/js/autoship/jquery/noconflict.js
ADDED
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* Subscribe Pro - Subscriptions Management Extension
|
3 |
+
*
|
4 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
5 |
+
*
|
6 |
+
* @category SFC
|
7 |
+
* @package SFC_Autoship
|
8 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
9 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
10 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
11 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
12 |
+
* @link http://www.subscribepro.com/
|
13 |
+
*
|
14 |
+
*/
|
15 |
+
|
16 |
+
$j = jQuery.noConflict();
|
17 |
+
jQuery.fn.highlight = function() {
|
18 |
+
$j(this).each(function() {
|
19 |
+
var el = $j(this);
|
20 |
+
el.before("<div style='position:absolute;'></div>")
|
21 |
+
el.prev()
|
22 |
+
.width(el.width())
|
23 |
+
.height(el.height())
|
24 |
+
.css({
|
25 |
+
"background-color": "#F96D3B",
|
26 |
+
"opacity": ".9"
|
27 |
+
})
|
28 |
+
.fadeOut(700, function(){$j(this).remove()});
|
29 |
+
});
|
30 |
+
return $j(this);
|
31 |
+
}
|
skin/adminhtml/default/default/js/autoship/sales_create_order.js
ADDED
@@ -0,0 +1,156 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* Subscribe Pro - Subscriptions Management Extension
|
3 |
+
*
|
4 |
+
* PHP version 5
|
5 |
+
*
|
6 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
7 |
+
*
|
8 |
+
* @category SFC
|
9 |
+
* @package SFC_Autoship
|
10 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
11 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
12 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
13 |
+
* @link http://www.subscribepro.com/
|
14 |
+
*
|
15 |
+
*/
|
16 |
+
|
17 |
+
// Tokenize card method -
|
18 |
+
// Send card out to vault via JSONP for tokenization and store resulting token in form
|
19 |
+
function tokenizeCard(submitOrderOnSuccess) {
|
20 |
+
// Get Prototype representation of field, so we can call prototype Validation methods on it inside
|
21 |
+
var spCcNumberField = $('subscribe_pro_cc_number');
|
22 |
+
var spCcMonthField = $('subscribe_pro_expiration');
|
23 |
+
var spCcYearField = $('subscribe_pro_expiration_yr');
|
24 |
+
// Wrap rest of code with $ jquery operator
|
25 |
+
(function($){
|
26 |
+
// Clear previous validation messages
|
27 |
+
$('#advice-validate-ajax-subscribe_pro_cc_number').remove();
|
28 |
+
$('#advice-validate-ajax-subscribe_pro_expiration').remove();
|
29 |
+
$('#advice-validate-ajax-subscribe_pro_expiration_yr').remove();
|
30 |
+
// Build data structure for JSONP call
|
31 |
+
var card = {
|
32 |
+
"kind": "credit_card",
|
33 |
+
"number": $('#subscribe_pro_cc_number').val(),
|
34 |
+
"verification_value": $('#subscribe_pro_cc_cid').val(),
|
35 |
+
"month": $('#subscribe_pro_expiration').val(),
|
36 |
+
"year": $('#subscribe_pro_expiration_yr').val(),
|
37 |
+
"first_name": $('#order-billing_address_firstname').val(),
|
38 |
+
"last_name": $('#order-billing_address_lastname').val()
|
39 |
+
}
|
40 |
+
// Serialize and URI encode parameters.
|
41 |
+
var paramStr = $.param(card);
|
42 |
+
// Build JSONP GET URL
|
43 |
+
var url = jsonpUrl + "?environment_key=" + jsonpEnvironmentKey + "&" + paramStr;
|
44 |
+
// Make JSONP GET call to vault
|
45 |
+
$.ajax({
|
46 |
+
type: "GET",
|
47 |
+
url: url,
|
48 |
+
dataType: "jsonp",
|
49 |
+
timeout: 1200
|
50 |
+
}).success(function (data) {
|
51 |
+
console.log(data);
|
52 |
+
if (data.status === 201) {
|
53 |
+
// Save token in payment data
|
54 |
+
$('#subscribe_pro_payment_token').val(data.transaction.payment_method.token);
|
55 |
+
// Replace card number and CVV with obscured data
|
56 |
+
$('#subscribe_pro_cc_number').val(
|
57 |
+
data.transaction.payment_method.first_six_digits +
|
58 |
+
'XXXXXX' +
|
59 |
+
data.transaction.payment_method.last_four_digits
|
60 |
+
);
|
61 |
+
$('#subscribe_pro_cc_cid').val(data.transaction.payment_method.verification_value);
|
62 |
+
// Now submit order to Magento like normal
|
63 |
+
if (submitOrderOnSuccess) {
|
64 |
+
submitOrder();
|
65 |
+
}
|
66 |
+
} else {
|
67 |
+
console.log('validation error!');
|
68 |
+
if (data.errors && data.errors.length > 0) {
|
69 |
+
if (data.errors[0].attribute == 'month') {
|
70 |
+
Validation.ajaxError(spCcMonthField, data.errors[0].message);
|
71 |
+
}
|
72 |
+
else if (data.errors[0].attribute == 'year') {
|
73 |
+
Validation.ajaxError(spCcYearField, data.errors[0].message);
|
74 |
+
}
|
75 |
+
else {
|
76 |
+
Validation.ajaxError(spCcNumberField, data.errors[0].message);
|
77 |
+
}
|
78 |
+
}
|
79 |
+
else {
|
80 |
+
Validation.ajaxError(spCcNumberField, 'Credit card validation error occurred!');
|
81 |
+
}
|
82 |
+
}
|
83 |
+
}).error(function (request, status, error) {
|
84 |
+
console.log('transmission error!');
|
85 |
+
Validation.ajaxError(spCcNumberField, 'Error occurred sending card to payment vault!');
|
86 |
+
});
|
87 |
+
})(jQuery);
|
88 |
+
}
|
89 |
+
|
90 |
+
function isCardAlreadyTokenized() {
|
91 |
+
return (function($){
|
92 |
+
if ($('#subscribe_pro_cc_number').val().indexOf('XXXXXX') >= 0 && $('#subscribe_pro_payment_token').val().length > 0) {
|
93 |
+
return true;
|
94 |
+
}
|
95 |
+
else {
|
96 |
+
return false;
|
97 |
+
}
|
98 |
+
})(jQuery);
|
99 |
+
}
|
100 |
+
|
101 |
+
function submitOrder() {
|
102 |
+
(function($){
|
103 |
+
// Submit
|
104 |
+
// Call original method
|
105 |
+
return AdminOrder.prototype.submit.call(order);
|
106 |
+
})(jQuery);
|
107 |
+
}
|
108 |
+
|
109 |
+
// Store card number in browser instead of POST to server
|
110 |
+
var subscribeProCardNumber;
|
111 |
+
|
112 |
+
// Handle document ready event
|
113 |
+
jQuery(document).ready(
|
114 |
+
function ($) {
|
115 |
+
// Replace method from AdminOrder prototype
|
116 |
+
order.loadArea = function(area, indicator, params) {
|
117 |
+
if ($.inArray('billing_method', area)) {
|
118 |
+
console.log('loadArea: billing_method');
|
119 |
+
// Save card number in browser, so we dont have to POST it to server
|
120 |
+
subscribeProCardNumber = $('#subscribe_pro_cc_number').val();
|
121 |
+
}
|
122 |
+
// Call original method
|
123 |
+
return AdminOrder.prototype.loadArea.call(this, area, indicator, params);
|
124 |
+
}
|
125 |
+
order.loadAreaResponseHandler = function(response) {
|
126 |
+
// Call original method
|
127 |
+
result = AdminOrder.prototype.loadAreaResponseHandler.call(this, response);
|
128 |
+
// Restore card number
|
129 |
+
$('#subscribe_pro_cc_number').val(subscribeProCardNumber);
|
130 |
+
// Return original method result
|
131 |
+
return result;
|
132 |
+
}
|
133 |
+
// Replace method from AdminOrder prototype
|
134 |
+
order.submit = function() {
|
135 |
+
//console.log('Subscribe Pro submit called.');
|
136 |
+
// Check if free payment method is selected
|
137 |
+
// This is necessary because of Magneto bug where 'free' doesn't get set in this.paymentMethod when free payment method is automatically selected
|
138 |
+
var freeMethodChecked = $('#p_method_free').is(':checked');
|
139 |
+
// tokenize card if new card entered
|
140 |
+
if (!freeMethodChecked && this.paymentMethod == 'subscribe_pro') {
|
141 |
+
console.log('subscribe_pro method selected.');
|
142 |
+
if (isCardAlreadyTokenized()) {
|
143 |
+
// Card already tokenized, just submit to Magento
|
144 |
+
submitOrder();
|
145 |
+
}
|
146 |
+
else {
|
147 |
+
// Tokenize card, calling order submit when jsonp call returns
|
148 |
+
tokenizeCard(true);
|
149 |
+
}
|
150 |
+
}
|
151 |
+
else {
|
152 |
+
submitOrder();
|
153 |
+
}
|
154 |
+
}
|
155 |
+
}
|
156 |
+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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* SFC - Subscriptions / Autoship Manager Extension
|
3 |
+
*
|
4 |
+
* PHP version 5
|
5 |
+
*
|
6 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
7 |
+
*
|
8 |
+
* @category SFC
|
9 |
+
* @package SFC_Autoship
|
10 |
+
* @author Aaron Boswell <aaron@storefrontconsulting.com>
|
11 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
12 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
13 |
+
* @link http://www.subscribepro.com/
|
14 |
+
*
|
15 |
+
*/
|
16 |
+
|
17 |
+
|
18 |
+
/* New Subscription page */
|
19 |
+
|
20 |
+
/* top-row */
|
21 |
+
.subscription p { padding-bottom: 6px; }
|
22 |
+
.subscription .top-image, .subscription .top-name { float: left; }
|
23 |
+
.subscription .product-image img { margin-right: 12px; border: 1px solid #cfcfcf; padding: 6px; }
|
24 |
+
.subscription .product-name { width: 486px; }
|
25 |
+
.subscription .product-name a { font-size: 18px; font-weight: normal; color: #c73615; text-decoration: none; }
|
26 |
+
.subscription .product-original-price { font-size: 11px; color: #989696; text-decoration: line-through; }
|
27 |
+
.subscription .product-price { font-size: 18px; color: #c73615; font-weight: bold; }
|
28 |
+
|
29 |
+
.subscription .block {
|
30 |
+
width: 288px;
|
31 |
+
height: 162px;
|
32 |
+
float: left;
|
33 |
+
margin: 0 14px 14px 0;
|
34 |
+
border: 1px solid #cfcfcf;
|
35 |
+
-webkit-border-radius: 6px;
|
36 |
+
-moz-border-radius: 6px;
|
37 |
+
border-radius: 6px;
|
38 |
+
background: #f5f5f5 url(../images/autoship/bkg_block.gif) repeat-x 0 0;
|
39 |
+
}
|
40 |
+
.subscription .delivery-date-block { height: 92px; text-align: center; }
|
41 |
+
.subscription .delivery-date-block input.input-text { margin: 12px 0 0 -8px; border: none; padding: 0; background: none; font-size: 22px; font-weight: bold; text-align: center; width: 96px; }
|
42 |
+
.subscription .delivery-date-block .ui-datepicker-trigger { margin-top: 16px; cursor: pointer; }
|
43 |
+
.subscription .summary-block { height: 340px; }
|
44 |
+
.subscription .delivery-date-block, .subscription .summary-block { margin-right: 0px; margin-bottom: 0px; float: right; }
|
45 |
+
|
46 |
+
.subscription .block .block-title {
|
47 |
+
margin-top: -1px;
|
48 |
+
-webkit-border-top-left-radius: 6px;
|
49 |
+
-webkit-border-top-right-radius: 6px;
|
50 |
+
-moz-border-radius-topleft: 6px;
|
51 |
+
-moz-border-radius-topright: 6px;
|
52 |
+
border-top-left-radius: 6px;
|
53 |
+
border-top-right-radius: 6px;
|
54 |
+
padding: 5px 12px 5px;
|
55 |
+
background: #d12c01 url(../images/autoship/bkg_active-step.gif) repeat-x 0 -4px;
|
56 |
+
}
|
57 |
+
|
58 |
+
.subscription .box-padding { padding: 18px; }
|
59 |
+
|
60 |
+
.subscription .block .block-title h2 { color: #ffffff; }
|
61 |
+
|
62 |
+
.subscription .top-row { margin-bottom: 18px; }
|
63 |
+
|
64 |
+
.subscription .bottom-left { float: left; }
|
65 |
+
.subscription .bottom-top { width: 608px; }
|
66 |
+
.subscription .bottom-bottom { width: 608px; }
|
67 |
+
.subscription .bottom-right { float: right; }
|
68 |
+
|
69 |
+
.subscription .summary-block { position: relative; background: none; }
|
70 |
+
.subscription .summary-block .subscription-summary-table { float: right; }
|
71 |
+
.subscription .summary-block .subscription-summary-table table th, .subscription .summary-block .subscription-summary-table table td { padding: 0 5px 5px; }
|
72 |
+
.subscription .summary-block .subscription-summary-table table tfoot strong { font-size: 14px; color: #cd3800; padding: 6px 0 8px; }
|
73 |
+
|
74 |
+
.subscription .summary-block .subscribe-button-block {
|
75 |
+
position: absolute;
|
76 |
+
bottom: 0;
|
77 |
+
width: 288px;
|
78 |
+
height: 72px;
|
79 |
+
line-height: 72px;
|
80 |
+
text-align: center;
|
81 |
+
background: #fbf8f4;
|
82 |
+
-webkit-border-bottom-right-radius: 6px;
|
83 |
+
-webkit-border-bottom-left-radius: 6px;
|
84 |
+
-moz-border-radius-bottomright: 6px;
|
85 |
+
-moz-border-radius-bottomleft: 6px;
|
86 |
+
border-bottom-right-radius: 6px;
|
87 |
+
border-bottom-left-radius: 6px;
|
88 |
+
}
|
89 |
+
.subscription .summary-block .subscribe-button-block .btn-cart span {
|
90 |
+
background-image: url(../images/autoship/bkg_btn-co.gif);
|
91 |
+
height: 27px !important;
|
92 |
+
padding: 0 0 0 13px !important;
|
93 |
+
}
|
94 |
+
.subscription .summary-block .subscribe-button-block .btn-cart span span {
|
95 |
+
border: 0;
|
96 |
+
background-image: url(../images/autoship/bkg_btn-co.gif);
|
97 |
+
padding: 1px 32px 0 19px !important;
|
98 |
+
color: #fff;
|
99 |
+
font: bold 15px/26px Arial, Helvetica, sans-serif !important;
|
100 |
+
height: 26px;
|
101 |
+
text-transform: none;
|
102 |
+
margin: 0 !important;
|
103 |
+
}
|
104 |
+
|
105 |
+
.subscription div.change { padding: 20px; background-color: #ffffff; }
|
106 |
+
|
107 |
+
|
108 |
+
/* My Subscriptions page */
|
109 |
+
#all-subscriptions-details { margin-top: 18px; border-bottom: 1px solid #cfcfcf; padding-bottom: 18px; }
|
110 |
+
#all-subscriptions-details .delivery_date { margin: 2px 0 12px -6px; border: none; padding: 0; background: none; font-size: 22px; font-weight: bold; text-align: center; width: 96px; }
|
111 |
+
#all-subscriptions-details .input-box .ui-datepicker-trigger { margin-top: 6px; cursor: pointer; }
|
112 |
+
|
113 |
+
.active-subscriptions-links { padding-bottom: 18px; }
|
114 |
+
|
115 |
+
.subscription-block:first-child { margin-top: 0px; border-top: none; padding-top: 0px; }
|
116 |
+
.subscription-block { margin-top: 18px; border-bottom: 1px solid #cfcfcf; padding-bottom: 18px; }
|
117 |
+
.subscription-block p, .subscription-block h2 { padding-bottom: 6px; }
|
118 |
+
|
119 |
+
.subscription-info { float: left; width: 200px; padding-right: 10px; }
|
120 |
+
.subscription-product { float: left; width: 340px; padding-right: 10px; }
|
121 |
+
.subscription-actions { float: right; width: 144px; }
|
122 |
+
.subscription-more-details { padding-top: 10px; }
|
123 |
+
.subscription-shipping-address { float: left; padding-right: 40px; }
|
124 |
+
.subscription-billing-address { float: left; padding-right: 40px; }
|
125 |
+
.subscription-payment { float: left; padding-right: 40px; }
|
126 |
+
|
127 |
+
.subscription-info .next-order-date { font-size: 22px; }
|
128 |
+
.subscription-actions .status { font-size: 18px; }
|
129 |
+
|
130 |
+
.subscription-product .product-image img { float: left; margin-right: 12px; border: 1px solid #cfcfcf; padding: 6px; background: #ffffff; }
|
131 |
+
.subscription-product .product-name a { color: #c73615; text-decoration: none; }
|
132 |
+
.subscription-product .product-original-price { font-size: 11px; color: #989696; text-decoration: line-through; }
|
133 |
+
.subscription-product .product-price { font-size: 14px; color: #c73615; font-weight: bold; }
|
134 |
+
|
135 |
+
.subscription-actions .button { padding-bottom: 6px; }
|
136 |
+
.subscription-actions .button span span { width: 116px; }
|
137 |
+
|
138 |
+
.subscription-block .input-box input.delivery_date { margin: 2px 0 12px -6px; border: none; padding: 0; background: none; font-size: 22px; font-weight: bold; text-align: center; width: 96px; }
|
139 |
+
.subscription-block .input-box .ui-datepicker-trigger { margin-top: 6px; cursor: pointer; }
|
140 |
+
|
141 |
+
.subscription-block .change .buttons-set button.button { float: none; margin-left: 0; }
|
142 |
+
|
143 |
+
/* Subscription Product page */
|
144 |
+
.subscription-product .options-list li { padding-bottom: 18px; }
|
145 |
+
.subscription-product .options-list .radio { font-size: 14px !important; }
|
146 |
+
.subscription-product .options-list .radio, .subscription-product .options-list .radio-text { float: left; margin-right: 9px; }
|
147 |
+
.subscription-product .options-list .price { font-weight: bold; }
|
148 |
+
.subscription-product .options-list p { margin: 2px; }
|
149 |
+
|
150 |
+
/* Subscription Lightbox */
|
151 |
+
#modal_overlay {
|
152 |
+
position: absolute;
|
153 |
+
top: 0;
|
154 |
+
left: 0;
|
155 |
+
width: 100%;
|
156 |
+
height: 100%;
|
157 |
+
background: url(../images/autoship/white_trans.png);
|
158 |
+
z-index: 900;
|
159 |
+
display: none;
|
160 |
+
}
|
161 |
+
|
162 |
+
.new-subscription #please-wait {
|
163 |
+
z-index: 999;
|
164 |
+
}
|
165 |
+
|
166 |
+
.new-subscription div.change {
|
167 |
+
position: absolute;
|
168 |
+
z-index: 999;
|
169 |
+
display: none;
|
170 |
+
border: 1px solid #cfcfcf;
|
171 |
+
-webkit-border-radius: 6px;
|
172 |
+
-moz-border-radius: 6px;
|
173 |
+
border-radius: 6px;
|
174 |
+
-webkit-box-shadow: 0px 5px 20px 0px #e6e6e6;
|
175 |
+
box-shadow: 0px 5px 20px 0px #e6e6e6;
|
176 |
+
background: #ffffff url(../images/autoship/bkg_block.gif) repeat-x center bottom;
|
177 |
+
}
|
178 |
+
.new-subscription .change .block-title {
|
179 |
+
margin-top: -1px;
|
180 |
+
-webkit-border-top-left-radius: 6px;
|
181 |
+
-webkit-border-top-right-radius: 6px;
|
182 |
+
-moz-border-radius-topleft: 6px;
|
183 |
+
-moz-border-radius-topright: 6px;
|
184 |
+
border-top-left-radius: 6px;
|
185 |
+
border-top-right-radius: 6px;
|
186 |
+
padding: 5px 12px 5px;
|
187 |
+
background: #d12c01 url(../images/autoship/bkg_active-step.gif) repeat-x 0 -4px;
|
188 |
+
}
|
189 |
+
|
190 |
+
.new-subscription .payment-block .change { width: 440px; }
|
191 |
+
|
192 |
+
.new-subscription .change .form-list select { width: 300px; }
|
193 |
+
.new-subscription .change .form-list input.input-text, .subscription-lightbox-background .change .form-list textarea { width: 294px }
|
194 |
+
.new-subscription .change .buttons-set { padding: 0 15px 0 0 }
|
195 |
+
.new-subscription .change .form-list .input-box { float: right; margin-right: 3px; padding-right: 20px; }
|
196 |
+
.new-subscription .change p.required { width: auto; }
|
197 |
+
|
198 |
+
.new-subscription .change .messages { margin-top: 0; }
|
199 |
+
.new-subscription .change label { font-size: 12px; font-weight: bold; }
|
200 |
+
.new-subscription .change dt { padding-bottom: 6px; }
|
201 |
+
|
202 |
+
.new-subscription .change .new-cc-form-list label { width: 160px; }
|
203 |
+
.new-subscription .change .new-cc-form-list select { width: auto; margin-right: 4px; }
|
204 |
+
.new-subscription .change .new-cc-form-list input.input-text, .subscription-lightbox-background .change .new-cc-form-list textarea { width: auto; }
|
205 |
+
.new-subscription .change .new-cc-form-list .input-box { float: left; }
|
206 |
+
|
207 |
+
.active-subscriptions div.change {
|
208 |
+
position: absolute;
|
209 |
+
z-index: 999;
|
210 |
+
display: none;
|
211 |
+
border: 1px solid #d9d9d9;
|
212 |
+
-webkit-box-shadow: 0px 5px 20px 0px #e6e6e6;
|
213 |
+
box-shadow: 0px 5px 20px 0px #e6e6e6;
|
214 |
+
background: #ffffff url(../images/autoship/bkg_block.gif) repeat-x center bottom;
|
215 |
+
}
|
216 |
+
.active-subscriptions .change .block-title {
|
217 |
+
padding: 5px 12px;
|
218 |
+
border-bottom: 1px solid #d9d9d9;
|
219 |
+
background: url(../images/autoship/bkg_thead.gif) repeat-x;
|
220 |
+
}
|
221 |
+
.active-subscriptions .change .block-title h2 {
|
222 |
+
text-transform: uppercase;
|
223 |
+
font-size: 11px;
|
224 |
+
padding-bottom: 0;
|
225 |
+
}
|
226 |
+
.active-subscriptions .change .block-content { padding: 20px; }
|
227 |
+
|
228 |
+
.active-subscriptions .change .next-order-date { font-size: 22px; }
|
229 |
+
|
230 |
+
.active-subscriptions .change .form-list select { width: 300px; }
|
231 |
+
.active-subscriptions .change .form-list input.input-text, .subscription-lightbox-background .change .form-list textarea { width: 294px }
|
232 |
+
.active-subscriptions .change .buttons-set { padding: 0 15px 0 0 }
|
233 |
+
.active-subscriptions .change .form-list .input-box { float: right; margin-right: 3px; padding-right: 20px; }
|
234 |
+
.active-subscriptions .change p.required { width: auto; }
|
235 |
+
|
236 |
+
.active-subscriptions .change .messages { margin-top: 0; }
|
237 |
+
.active-subscriptions .change label { font-size: 12px; font-weight: bold; }
|
238 |
+
.active-subscriptions .change dt { padding-bottom: 6px; }
|
239 |
+
|
240 |
+
.active-subscriptions .change .new-cc-form-list label { width: 160px; }
|
241 |
+
.active-subscriptions .change .new-cc-form-list select { width: auto; margin-right: 4px; }
|
242 |
+
.active-subscriptions .change .new-cc-form-list input.input-text, .subscription-lightbox-background .change .new-cc-form-list textarea { width: auto; }
|
243 |
+
.active-subscriptions .change .new-cc-form-list .input-box { float: left; }
|
244 |
+
|
245 |
+
#all-subscriptions-details div.change {
|
246 |
+
position: absolute;
|
247 |
+
z-index: 999;
|
248 |
+
display: none;
|
249 |
+
border: 1px solid #d9d9d9;
|
250 |
+
-webkit-box-shadow: 0px 5px 20px 0px #e6e6e6;
|
251 |
+
box-shadow: 0px 5px 20px 0px #e6e6e6;
|
252 |
+
background: #ffffff url(../images/autoship/bkg_block.gif) repeat-x center bottom;
|
253 |
+
}
|
254 |
+
#all-subscriptions-details .change .block-title {
|
255 |
+
padding: 5px 12px;
|
256 |
+
border-bottom: 1px solid #d9d9d9;
|
257 |
+
background: url(../images/autoship/bkg_thead.gif) repeat-x;
|
258 |
+
}
|
259 |
+
#all-subscriptions-details .change .block-title h2 {
|
260 |
+
text-transform: uppercase;
|
261 |
+
font-size: 11px;
|
262 |
+
padding-bottom: 0;
|
263 |
+
}
|
264 |
+
#all-subscriptions-details .change .block-content { padding: 20px; }
|
265 |
+
|
266 |
+
#all-subscriptions-details .change .next-order-date { font-size: 22px; }
|
267 |
+
|
268 |
+
#all-subscriptions-details .change .form-list select { width: 300px; }
|
269 |
+
#all-subscriptions-details .change .form-list input.input-text, .subscription-lightbox-background .change .form-list textarea { width: 294px }
|
270 |
+
#all-subscriptions-details .change .buttons-set { padding: 0 15px 0 0 }
|
271 |
+
#all-subscriptions-details .change .form-list .input-box { float: right; margin-right: 3px; padding-right: 20px; }
|
272 |
+
#all-subscriptions-details .change p.required { width: auto; }
|
273 |
+
|
274 |
+
#all-subscriptions-details .change .messages { margin-top: 0; }
|
275 |
+
#all-subscriptions-details .change label { font-size: 12px; font-weight: bold; }
|
276 |
+
#all-subscriptions-details .change dt { padding-bottom: 6px; }
|
277 |
+
|
278 |
+
#all-subscriptions-details .change .new-cc-form-list label { width: 160px; }
|
279 |
+
#all-subscriptions-details .change .new-cc-form-list select { width: auto; margin-right: 4px; }
|
280 |
+
#all-subscriptions-details .change .new-cc-form-list input.input-text, .subscription-lightbox-background .change .new-cc-form-list textarea { width: auto; }
|
281 |
+
#all-subscriptions-details .change .new-cc-form-list .input-box { float: left; }
|
282 |
+
|
283 |
+
/* Cart page */
|
284 |
+
|
285 |
+
.cart .subscription-product { width: auto; padding-top: 4px; }
|
286 |
+
.cart .subscription-product .options-list { padding-top: 2px; }
|
287 |
+
.cart .subscription-product .options-list li { padding-bottom: 6px; }
|
288 |
+
.cart .subscription-product .options-list .radio, .cart .subscription-product .options-list .radio-text { line-height: 18px; }
|
289 |
+
.cart .subscription-product .options-list .radio { cursor: pointer; }
|
290 |
+
.cart .subscription-product .options-list p { margin: 0; }
|
skin/frontend/base/default/images/autoship/bkg_active-step.gif
ADDED
Binary file
|
skin/frontend/base/default/images/autoship/bkg_block.gif
ADDED
Binary file
|
skin/frontend/base/default/images/autoship/bkg_btn-co.gif
ADDED
Binary file
|
skin/frontend/base/default/images/autoship/bkg_thead.gif
ADDED
Binary file
|
skin/frontend/base/default/images/autoship/calendar_icon.png
ADDED
Binary file
|
skin/frontend/base/default/images/autoship/white_trans.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/checkout.js
ADDED
@@ -0,0 +1,121 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* Subscribe Pro - Subscriptions Management Extension
|
3 |
+
*
|
4 |
+
* PHP version 5
|
5 |
+
*
|
6 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
7 |
+
*
|
8 |
+
* @category SFC
|
9 |
+
* @package SFC_Autoship
|
10 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
11 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
12 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
13 |
+
* @link http://www.subscribepro.com/
|
14 |
+
*
|
15 |
+
*/
|
16 |
+
|
17 |
+
// Tokenize card method -
|
18 |
+
// Send card out to vault via JSONP for tokenization and store resulting token in form
|
19 |
+
function tokenizeCard(paymentSaveThis) {
|
20 |
+
(function($){
|
21 |
+
// Turn on waiting indicator
|
22 |
+
checkout.setLoadWaiting('payment');
|
23 |
+
// Build data structure for JSONP call
|
24 |
+
var card = {
|
25 |
+
"kind": "credit_card",
|
26 |
+
"number": $('#subscribe_pro_cc_number').val(),
|
27 |
+
"verification_value": $('#subscribe_pro_cc_cid').val(),
|
28 |
+
"month": $('#subscribe_pro_expiration').val(),
|
29 |
+
"year": $('#subscribe_pro_expiration_yr').val(),
|
30 |
+
"first_name": $('#subscribe_pro_firstname').val(),
|
31 |
+
"last_name": $('#subscribe_pro_lastname').val()
|
32 |
+
}
|
33 |
+
// Serialize and URI encode parameters.
|
34 |
+
var paramStr = $.param(card);
|
35 |
+
// Build JSONP GET URL
|
36 |
+
var url = jsonpUrl + "?environment_key=" + jsonpEnvironmentKey + "&" + paramStr;
|
37 |
+
// Make JSONP GET call to vault
|
38 |
+
$.ajax({
|
39 |
+
type: "GET",
|
40 |
+
url: url,
|
41 |
+
dataType: "jsonp"
|
42 |
+
}).success(function (data) {
|
43 |
+
if (data.status === 201) {
|
44 |
+
// Save token in payment data
|
45 |
+
$('#subscribe_pro_payment_token').val(data.transaction.payment_method.token);
|
46 |
+
// Replace card number and CVV with obscured data
|
47 |
+
$('#subscribe_pro_cc_number').val(
|
48 |
+
data.transaction.payment_method.first_six_digits +
|
49 |
+
'XXXXXX' +
|
50 |
+
data.transaction.payment_method.last_four_digits
|
51 |
+
);
|
52 |
+
$('#subscribe_pro_cc_cid').val(data.transaction.payment_method.verification_value);
|
53 |
+
// Call Magento payment save ajax call
|
54 |
+
paymentSaveAjaxCall(paymentSaveThis);
|
55 |
+
} else {
|
56 |
+
console.log('validation error!');
|
57 |
+
}
|
58 |
+
}).error(function (request, status, error) {
|
59 |
+
checkout.setLoadWaiting(false);
|
60 |
+
console.log('transmission error!');
|
61 |
+
});
|
62 |
+
})(jQuery);
|
63 |
+
}
|
64 |
+
|
65 |
+
// Call Magento payment save ajax call
|
66 |
+
function paymentSaveAjaxCall(paymentSaveThis) {
|
67 |
+
(function($){
|
68 |
+
// Make original payment save function ajax call to Magento
|
69 |
+
var request = new Ajax.Request(
|
70 |
+
paymentSaveThis.saveUrl,
|
71 |
+
{
|
72 |
+
method:'post',
|
73 |
+
onComplete: paymentSaveThis.onComplete,
|
74 |
+
onSuccess: paymentSaveThis.onSave,
|
75 |
+
onFailure: checkout.ajaxFailure.bind(checkout),
|
76 |
+
parameters: Form.serialize(paymentSaveThis.form)
|
77 |
+
}
|
78 |
+
);
|
79 |
+
})(jQuery);
|
80 |
+
}
|
81 |
+
|
82 |
+
// Handle document ready event
|
83 |
+
jQuery(document).ready(
|
84 |
+
function ($) {
|
85 |
+
// Replace payment save function
|
86 |
+
payment.save = function () {
|
87 |
+
if (this.currentMethod != 'subscribe_pro') {
|
88 |
+
// Call original payment save function
|
89 |
+
return Payment.prototype.save.call(this);
|
90 |
+
}
|
91 |
+
// Save this ref so we can use to call original payment.save method
|
92 |
+
var paymentSaveThis = this;
|
93 |
+
// Check if we are already running and return immediately if so
|
94 |
+
if (checkout.loadWaiting!=false) return;
|
95 |
+
// Check if we already have a tokenized card
|
96 |
+
var cardAlreadyTokenized =
|
97 |
+
$('#subscribe_pro_payment_token').val().length > 0 &&
|
98 |
+
$('#subscribe_pro_cc_number').val().indexOf('XXXXXX') >= 0
|
99 |
+
;
|
100 |
+
// Check if card is already tokenized
|
101 |
+
if (cardAlreadyTokenized) {
|
102 |
+
// Turn on waiting indicator
|
103 |
+
checkout.setLoadWaiting('payment');
|
104 |
+
// Call Magento payment save ajax call
|
105 |
+
paymentSaveAjaxCall(paymentSaveThis);
|
106 |
+
}
|
107 |
+
else {
|
108 |
+
// Card not yet tokenized, run it through vault
|
109 |
+
// Run validation
|
110 |
+
var validator = new Validation(paymentSaveThis.form);
|
111 |
+
if (paymentSaveThis.validate() && validator.validate()) {
|
112 |
+
// Validation passed
|
113 |
+
// Call vault to tokenize card, then call Magento Ajax payment save action
|
114 |
+
tokenizeCard(paymentSaveThis);
|
115 |
+
}
|
116 |
+
}
|
117 |
+
}
|
118 |
+
;
|
119 |
+
}
|
120 |
+
)
|
121 |
+
;
|
skin/frontend/base/default/js/autoship/jquery/jquery-1.10.1.min.js
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*! jQuery v1.10.1 | (c) 2005, 2013 jQuery Foundation, Inc. | jquery.org/license
|
2 |
+
//@ sourceMappingURL=jquery-1.10.1.min.map
|
3 |
+
*/
|
4 |
+
(function(e,t){var n,r,i=typeof t,o=e.location,a=e.document,s=a.documentElement,l=e.jQuery,u=e.$,c={},p=[],f="1.10.1",d=p.concat,h=p.push,g=p.slice,m=p.indexOf,y=c.toString,v=c.hasOwnProperty,b=f.trim,x=function(e,t){return new x.fn.init(e,t,r)},w=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,T=/\S+/g,C=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,N=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,k=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,E=/^[\],:{}\s]*$/,S=/(?:^|:|,)(?:\s*\[)+/g,A=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,j=/"[^"\\\r\n]*"|true|false|null|-?(?:\d+\.|)\d+(?:[eE][+-]?\d+|)/g,D=/^-ms-/,L=/-([\da-z])/gi,H=function(e,t){return t.toUpperCase()},q=function(e){(a.addEventListener||"load"===e.type||"complete"===a.readyState)&&(_(),x.ready())},_=function(){a.addEventListener?(a.removeEventListener("DOMContentLoaded",q,!1),e.removeEventListener("load",q,!1)):(a.detachEvent("onreadystatechange",q),e.detachEvent("onload",q))};x.fn=x.prototype={jquery:f,constructor:x,init:function(e,n,r){var i,o;if(!e)return this;if("string"==typeof e){if(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:N.exec(e),!i||!i[1]&&n)return!n||n.jquery?(n||r).find(e):this.constructor(n).find(e);if(i[1]){if(n=n instanceof x?n[0]:n,x.merge(this,x.parseHTML(i[1],n&&n.nodeType?n.ownerDocument||n:a,!0)),k.test(i[1])&&x.isPlainObject(n))for(i in n)x.isFunction(this[i])?this[i](n[i]):this.attr(i,n[i]);return this}if(o=a.getElementById(i[2]),o&&o.parentNode){if(o.id!==i[2])return r.find(e);this.length=1,this[0]=o}return this.context=a,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):x.isFunction(e)?r.ready(e):(e.selector!==t&&(this.selector=e.selector,this.context=e.context),x.makeArray(e,this))},selector:"",length:0,toArray:function(){return g.call(this)},get:function(e){return null==e?this.toArray():0>e?this[this.length+e]:this[e]},pushStack:function(e){var t=x.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return x.each(this,e,t)},ready:function(e){return x.ready.promise().done(e),this},slice:function(){return this.pushStack(g.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},map:function(e){return this.pushStack(x.map(this,function(t,n){return e.call(t,n,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:h,sort:[].sort,splice:[].splice},x.fn.init.prototype=x.fn,x.extend=x.fn.extend=function(){var e,n,r,i,o,a,s=arguments[0]||{},l=1,u=arguments.length,c=!1;for("boolean"==typeof s&&(c=s,s=arguments[1]||{},l=2),"object"==typeof s||x.isFunction(s)||(s={}),u===l&&(s=this,--l);u>l;l++)if(null!=(o=arguments[l]))for(i in o)e=s[i],r=o[i],s!==r&&(c&&r&&(x.isPlainObject(r)||(n=x.isArray(r)))?(n?(n=!1,a=e&&x.isArray(e)?e:[]):a=e&&x.isPlainObject(e)?e:{},s[i]=x.extend(c,a,r)):r!==t&&(s[i]=r));return s},x.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),noConflict:function(t){return e.$===x&&(e.$=u),t&&e.jQuery===x&&(e.jQuery=l),x},isReady:!1,readyWait:1,holdReady:function(e){e?x.readyWait++:x.ready(!0)},ready:function(e){if(e===!0?!--x.readyWait:!x.isReady){if(!a.body)return setTimeout(x.ready);x.isReady=!0,e!==!0&&--x.readyWait>0||(n.resolveWith(a,[x]),x.fn.trigger&&x(a).trigger("ready").off("ready"))}},isFunction:function(e){return"function"===x.type(e)},isArray:Array.isArray||function(e){return"array"===x.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?c[y.call(e)]||"object":typeof e},isPlainObject:function(e){var n;if(!e||"object"!==x.type(e)||e.nodeType||x.isWindow(e))return!1;try{if(e.constructor&&!v.call(e,"constructor")&&!v.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(r){return!1}if(x.support.ownLast)for(n in e)return v.call(e,n);for(n in e);return n===t||v.call(e,n)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},error:function(e){throw Error(e)},parseHTML:function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||a;var r=k.exec(e),i=!n&&[];return r?[t.createElement(r[1])]:(r=x.buildFragment([e],t,i),i&&x(i).remove(),x.merge([],r.childNodes))},parseJSON:function(n){return e.JSON&&e.JSON.parse?e.JSON.parse(n):null===n?n:"string"==typeof n&&(n=x.trim(n),n&&E.test(n.replace(A,"@").replace(j,"]").replace(S,"")))?Function("return "+n)():(x.error("Invalid JSON: "+n),t)},parseXML:function(n){var r,i;if(!n||"string"!=typeof n)return null;try{e.DOMParser?(i=new DOMParser,r=i.parseFromString(n,"text/xml")):(r=new ActiveXObject("Microsoft.XMLDOM"),r.async="false",r.loadXML(n))}catch(o){r=t}return r&&r.documentElement&&!r.getElementsByTagName("parsererror").length||x.error("Invalid XML: "+n),r},noop:function(){},globalEval:function(t){t&&x.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(D,"ms-").replace(L,H)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,n){var r,i=0,o=e.length,a=M(e);if(n){if(a){for(;o>i;i++)if(r=t.apply(e[i],n),r===!1)break}else for(i in e)if(r=t.apply(e[i],n),r===!1)break}else if(a){for(;o>i;i++)if(r=t.call(e[i],i,e[i]),r===!1)break}else for(i in e)if(r=t.call(e[i],i,e[i]),r===!1)break;return e},trim:b&&!b.call("\ufeff\u00a0")?function(e){return null==e?"":b.call(e)}:function(e){return null==e?"":(e+"").replace(C,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(M(Object(e))?x.merge(n,"string"==typeof e?[e]:e):h.call(n,e)),n},inArray:function(e,t,n){var r;if(t){if(m)return m.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,n){var r=n.length,i=e.length,o=0;if("number"==typeof r)for(;r>o;o++)e[i++]=n[o];else while(n[o]!==t)e[i++]=n[o++];return e.length=i,e},grep:function(e,t,n){var r,i=[],o=0,a=e.length;for(n=!!n;a>o;o++)r=!!t(e[o],o),n!==r&&i.push(e[o]);return i},map:function(e,t,n){var r,i=0,o=e.length,a=M(e),s=[];if(a)for(;o>i;i++)r=t(e[i],i,n),null!=r&&(s[s.length]=r);else for(i in e)r=t(e[i],i,n),null!=r&&(s[s.length]=r);return d.apply([],s)},guid:1,proxy:function(e,n){var r,i,o;return"string"==typeof n&&(o=e[n],n=e,e=o),x.isFunction(e)?(r=g.call(arguments,2),i=function(){return e.apply(n||this,r.concat(g.call(arguments)))},i.guid=e.guid=e.guid||x.guid++,i):t},access:function(e,n,r,i,o,a,s){var l=0,u=e.length,c=null==r;if("object"===x.type(r)){o=!0;for(l in r)x.access(e,n,l,r[l],!0,a,s)}else if(i!==t&&(o=!0,x.isFunction(i)||(s=!0),c&&(s?(n.call(e,i),n=null):(c=n,n=function(e,t,n){return c.call(x(e),n)})),n))for(;u>l;l++)n(e[l],r,s?i:i.call(e[l],l,n(e[l],r)));return o?e:c?n.call(e):u?n(e[0],r):a},now:function(){return(new Date).getTime()},swap:function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i}}),x.ready.promise=function(t){if(!n)if(n=x.Deferred(),"complete"===a.readyState)setTimeout(x.ready);else if(a.addEventListener)a.addEventListener("DOMContentLoaded",q,!1),e.addEventListener("load",q,!1);else{a.attachEvent("onreadystatechange",q),e.attachEvent("onload",q);var r=!1;try{r=null==e.frameElement&&a.documentElement}catch(i){}r&&r.doScroll&&function o(){if(!x.isReady){try{r.doScroll("left")}catch(e){return setTimeout(o,50)}_(),x.ready()}}()}return n.promise(t)},x.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){c["[object "+t+"]"]=t.toLowerCase()});function M(e){var t=e.length,n=x.type(e);return x.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||"function"!==n&&(0===t||"number"==typeof t&&t>0&&t-1 in e)}r=x(a),function(e,t){var n,r,i,o,a,s,l,u,c,p,f,d,h,g,m,y,v,b="sizzle"+-new Date,w=e.document,T=0,C=0,N=lt(),k=lt(),E=lt(),S=!1,A=function(){return 0},j=typeof t,D=1<<31,L={}.hasOwnProperty,H=[],q=H.pop,_=H.push,M=H.push,O=H.slice,F=H.indexOf||function(e){var t=0,n=this.length;for(;n>t;t++)if(this[t]===e)return t;return-1},B="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",P="[\\x20\\t\\r\\n\\f]",R="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",W=R.replace("w","w#"),$="\\["+P+"*("+R+")"+P+"*(?:([*^$|!~]?=)"+P+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+W+")|)|)"+P+"*\\]",I=":("+R+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+$.replace(3,8)+")*)|.*)\\)|)",z=RegExp("^"+P+"+|((?:^|[^\\\\])(?:\\\\.)*)"+P+"+$","g"),X=RegExp("^"+P+"*,"+P+"*"),U=RegExp("^"+P+"*([>+~]|"+P+")"+P+"*"),V=RegExp(P+"*[+~]"),Y=RegExp("="+P+"*([^\\]'\"]*)"+P+"*\\]","g"),J=RegExp(I),G=RegExp("^"+W+"$"),Q={ID:RegExp("^#("+R+")"),CLASS:RegExp("^\\.("+R+")"),TAG:RegExp("^("+R.replace("w","w*")+")"),ATTR:RegExp("^"+$),PSEUDO:RegExp("^"+I),CHILD:RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+P+"*(even|odd|(([+-]|)(\\d*)n|)"+P+"*(?:([+-]|)"+P+"*(\\d+)|))"+P+"*\\)|)","i"),bool:RegExp("^(?:"+B+")$","i"),needsContext:RegExp("^"+P+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+P+"*((?:-\\d)?\\d*)"+P+"*\\)|)(?=[^-]|$)","i")},K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,et=/^(?:input|select|textarea|button)$/i,tt=/^h\d$/i,nt=/'|\\/g,rt=RegExp("\\\\([\\da-f]{1,6}"+P+"?|("+P+")|.)","ig"),it=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:0>r?String.fromCharCode(r+65536):String.fromCharCode(55296|r>>10,56320|1023&r)};try{M.apply(H=O.call(w.childNodes),w.childNodes),H[w.childNodes.length].nodeType}catch(ot){M={apply:H.length?function(e,t){_.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function at(e,t,n,i){var o,a,s,l,u,c,d,m,y,x;if((t?t.ownerDocument||t:w)!==f&&p(t),t=t||f,n=n||[],!e||"string"!=typeof e)return n;if(1!==(l=t.nodeType)&&9!==l)return[];if(h&&!i){if(o=Z.exec(e))if(s=o[1]){if(9===l){if(a=t.getElementById(s),!a||!a.parentNode)return n;if(a.id===s)return n.push(a),n}else if(t.ownerDocument&&(a=t.ownerDocument.getElementById(s))&&v(t,a)&&a.id===s)return n.push(a),n}else{if(o[2])return M.apply(n,t.getElementsByTagName(e)),n;if((s=o[3])&&r.getElementsByClassName&&t.getElementsByClassName)return M.apply(n,t.getElementsByClassName(s)),n}if(r.qsa&&(!g||!g.test(e))){if(m=d=b,y=t,x=9===l&&e,1===l&&"object"!==t.nodeName.toLowerCase()){c=bt(e),(d=t.getAttribute("id"))?m=d.replace(nt,"\\$&"):t.setAttribute("id",m),m="[id='"+m+"'] ",u=c.length;while(u--)c[u]=m+xt(c[u]);y=V.test(e)&&t.parentNode||t,x=c.join(",")}if(x)try{return M.apply(n,y.querySelectorAll(x)),n}catch(T){}finally{d||t.removeAttribute("id")}}}return At(e.replace(z,"$1"),t,n,i)}function st(e){return K.test(e+"")}function lt(){var e=[];function t(n,r){return e.push(n+=" ")>o.cacheLength&&delete t[e.shift()],t[n]=r}return t}function ut(e){return e[b]=!0,e}function ct(e){var t=f.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function pt(e,t,n){e=e.split("|");var r,i=e.length,a=n?null:t;while(i--)(r=o.attrHandle[e[i]])&&r!==t||(o.attrHandle[e[i]]=a)}function ft(e,t){var n=e.getAttributeNode(t);return n&&n.specified?n.value:e[t]===!0?t.toLowerCase():null}function dt(e,t){return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}function ht(e){return"input"===e.nodeName.toLowerCase()?e.defaultValue:t}function gt(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||D)-(~e.sourceIndex||D);if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function mt(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function yt(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function vt(e){return ut(function(t){return t=+t,ut(function(n,r){var i,o=e([],n.length,t),a=o.length;while(a--)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}s=at.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},r=at.support={},p=at.setDocument=function(e){var n=e?e.ownerDocument||e:w,i=n.parentWindow;return n!==f&&9===n.nodeType&&n.documentElement?(f=n,d=n.documentElement,h=!s(n),i&&i.frameElement&&i.attachEvent("onbeforeunload",function(){p()}),r.attributes=ct(function(e){return e.innerHTML="<a href='#'></a>",pt("type|href|height|width",dt,"#"===e.firstChild.getAttribute("href")),pt(B,ft,null==e.getAttribute("disabled")),e.className="i",!e.getAttribute("className")}),r.input=ct(function(e){return e.innerHTML="<input>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")}),pt("value",ht,r.attributes&&r.input),r.getElementsByTagName=ct(function(e){return e.appendChild(n.createComment("")),!e.getElementsByTagName("*").length}),r.getElementsByClassName=ct(function(e){return e.innerHTML="<div class='a'></div><div class='a i'></div>",e.firstChild.className="i",2===e.getElementsByClassName("i").length}),r.getById=ct(function(e){return d.appendChild(e).id=b,!n.getElementsByName||!n.getElementsByName(b).length}),r.getById?(o.find.ID=function(e,t){if(typeof t.getElementById!==j&&h){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){return e.getAttribute("id")===t}}):(delete o.find.ID,o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){var n=typeof e.getAttributeNode!==j&&e.getAttributeNode("id");return n&&n.value===t}}),o.find.TAG=r.getElementsByTagName?function(e,n){return typeof n.getElementsByTagName!==j?n.getElementsByTagName(e):t}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},o.find.CLASS=r.getElementsByClassName&&function(e,n){return typeof n.getElementsByClassName!==j&&h?n.getElementsByClassName(e):t},m=[],g=[],(r.qsa=st(n.querySelectorAll))&&(ct(function(e){e.innerHTML="<select><option selected=''></option></select>",e.querySelectorAll("[selected]").length||g.push("\\["+P+"*(?:value|"+B+")"),e.querySelectorAll(":checked").length||g.push(":checked")}),ct(function(e){var t=n.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("t",""),e.querySelectorAll("[t^='']").length&&g.push("[*^$]="+P+"*(?:''|\"\")"),e.querySelectorAll(":enabled").length||g.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),g.push(",.*:")})),(r.matchesSelector=st(y=d.webkitMatchesSelector||d.mozMatchesSelector||d.oMatchesSelector||d.msMatchesSelector))&&ct(function(e){r.disconnectedMatch=y.call(e,"div"),y.call(e,"[s!='']:x"),m.push("!=",I)}),g=g.length&&RegExp(g.join("|")),m=m.length&&RegExp(m.join("|")),v=st(d.contains)||d.compareDocumentPosition?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},r.sortDetached=ct(function(e){return 1&e.compareDocumentPosition(n.createElement("div"))}),A=d.compareDocumentPosition?function(e,t){if(e===t)return S=!0,0;var i=t.compareDocumentPosition&&e.compareDocumentPosition&&e.compareDocumentPosition(t);return i?1&i||!r.sortDetached&&t.compareDocumentPosition(e)===i?e===n||v(w,e)?-1:t===n||v(w,t)?1:c?F.call(c,e)-F.call(c,t):0:4&i?-1:1:e.compareDocumentPosition?-1:1}:function(e,t){var r,i=0,o=e.parentNode,a=t.parentNode,s=[e],l=[t];if(e===t)return S=!0,0;if(!o||!a)return e===n?-1:t===n?1:o?-1:a?1:c?F.call(c,e)-F.call(c,t):0;if(o===a)return gt(e,t);r=e;while(r=r.parentNode)s.unshift(r);r=t;while(r=r.parentNode)l.unshift(r);while(s[i]===l[i])i++;return i?gt(s[i],l[i]):s[i]===w?-1:l[i]===w?1:0},n):f},at.matches=function(e,t){return at(e,null,null,t)},at.matchesSelector=function(e,t){if((e.ownerDocument||e)!==f&&p(e),t=t.replace(Y,"='$1']"),!(!r.matchesSelector||!h||m&&m.test(t)||g&&g.test(t)))try{var n=y.call(e,t);if(n||r.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(i){}return at(t,f,null,[e]).length>0},at.contains=function(e,t){return(e.ownerDocument||e)!==f&&p(e),v(e,t)},at.attr=function(e,n){(e.ownerDocument||e)!==f&&p(e);var i=o.attrHandle[n.toLowerCase()],a=i&&L.call(o.attrHandle,n.toLowerCase())?i(e,n,!h):t;return a===t?r.attributes||!h?e.getAttribute(n):(a=e.getAttributeNode(n))&&a.specified?a.value:null:a},at.error=function(e){throw Error("Syntax error, unrecognized expression: "+e)},at.uniqueSort=function(e){var t,n=[],i=0,o=0;if(S=!r.detectDuplicates,c=!r.sortStable&&e.slice(0),e.sort(A),S){while(t=e[o++])t===e[o]&&(i=n.push(o));while(i--)e.splice(n[i],1)}return e},a=at.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=a(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r];r++)n+=a(t);return n},o=at.selectors={cacheLength:50,createPseudo:ut,match:Q,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(rt,it),e[3]=(e[4]||e[5]||"").replace(rt,it),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||at.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&at.error(e[0]),e},PSEUDO:function(e){var n,r=!e[5]&&e[2];return Q.CHILD.test(e[0])?null:(e[3]&&e[4]!==t?e[2]=e[4]:r&&J.test(r)&&(n=bt(r,!0))&&(n=r.indexOf(")",r.length-n)-r.length)&&(e[0]=e[0].slice(0,n),e[2]=r.slice(0,n)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(rt,it).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=N[e+" "];return t||(t=RegExp("(^|"+P+")"+e+"("+P+"|$)"))&&N(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==j&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var i=at.attr(r,e);return null==i?"!="===t:t?(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i+" ").indexOf(n)>-1:"|="===t?i===n||i.slice(0,n.length+1)===n+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,l){var u,c,p,f,d,h,g=o!==a?"nextSibling":"previousSibling",m=t.parentNode,y=s&&t.nodeName.toLowerCase(),v=!l&&!s;if(m){if(o){while(g){p=t;while(p=p[g])if(s?p.nodeName.toLowerCase()===y:1===p.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?m.firstChild:m.lastChild],a&&v){c=m[b]||(m[b]={}),u=c[e]||[],d=u[0]===T&&u[1],f=u[0]===T&&u[2],p=d&&m.childNodes[d];while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if(1===p.nodeType&&++f&&p===t){c[e]=[T,d,f];break}}else if(v&&(u=(t[b]||(t[b]={}))[e])&&u[0]===T)f=u[1];else while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if((s?p.nodeName.toLowerCase()===y:1===p.nodeType)&&++f&&(v&&((p[b]||(p[b]={}))[e]=[T,f]),p===t))break;return f-=i,f===r||0===f%r&&f/r>=0}}},PSEUDO:function(e,t){var n,r=o.pseudos[e]||o.setFilters[e.toLowerCase()]||at.error("unsupported pseudo: "+e);return r[b]?r(t):r.length>1?(n=[e,e,"",t],o.setFilters.hasOwnProperty(e.toLowerCase())?ut(function(e,n){var i,o=r(e,t),a=o.length;while(a--)i=F.call(e,o[a]),e[i]=!(n[i]=o[a])}):function(e){return r(e,0,n)}):r}},pseudos:{not:ut(function(e){var t=[],n=[],r=l(e.replace(z,"$1"));return r[b]?ut(function(e,t,n,i){var o,a=r(e,null,i,[]),s=e.length;while(s--)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),!n.pop()}}),has:ut(function(e){return function(t){return at(e,t).length>0}}),contains:ut(function(e){return function(t){return(t.textContent||t.innerText||a(t)).indexOf(e)>-1}}),lang:ut(function(e){return G.test(e||"")||at.error("unsupported lang: "+e),e=e.replace(rt,it).toLowerCase(),function(t){var n;do if(n=h?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===d},focus:function(e){return e===f.activeElement&&(!f.hasFocus||f.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeName>"@"||3===e.nodeType||4===e.nodeType)return!1;return!0},parent:function(e){return!o.pseudos.empty(e)},header:function(e){return tt.test(e.nodeName)},input:function(e){return et.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||t.toLowerCase()===e.type)},first:vt(function(){return[0]}),last:vt(function(e,t){return[t-1]}),eq:vt(function(e,t,n){return[0>n?n+t:n]}),even:vt(function(e,t){var n=0;for(;t>n;n+=2)e.push(n);return e}),odd:vt(function(e,t){var n=1;for(;t>n;n+=2)e.push(n);return e}),lt:vt(function(e,t,n){var r=0>n?n+t:n;for(;--r>=0;)e.push(r);return e}),gt:vt(function(e,t,n){var r=0>n?n+t:n;for(;t>++r;)e.push(r);return e})}};for(n in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})o.pseudos[n]=mt(n);for(n in{submit:!0,reset:!0})o.pseudos[n]=yt(n);function bt(e,t){var n,r,i,a,s,l,u,c=k[e+" "];if(c)return t?0:c.slice(0);s=e,l=[],u=o.preFilter;while(s){(!n||(r=X.exec(s)))&&(r&&(s=s.slice(r[0].length)||s),l.push(i=[])),n=!1,(r=U.exec(s))&&(n=r.shift(),i.push({value:n,type:r[0].replace(z," ")}),s=s.slice(n.length));for(a in o.filter)!(r=Q[a].exec(s))||u[a]&&!(r=u[a](r))||(n=r.shift(),i.push({value:n,type:a,matches:r}),s=s.slice(n.length));if(!n)break}return t?s.length:s?at.error(e):k(e,l).slice(0)}function xt(e){var t=0,n=e.length,r="";for(;n>t;t++)r+=e[t].value;return r}function wt(e,t,n){var r=t.dir,o=n&&"parentNode"===r,a=C++;return t.first?function(t,n,i){while(t=t[r])if(1===t.nodeType||o)return e(t,n,i)}:function(t,n,s){var l,u,c,p=T+" "+a;if(s){while(t=t[r])if((1===t.nodeType||o)&&e(t,n,s))return!0}else while(t=t[r])if(1===t.nodeType||o)if(c=t[b]||(t[b]={}),(u=c[r])&&u[0]===p){if((l=u[1])===!0||l===i)return l===!0}else if(u=c[r]=[p],u[1]=e(t,n,s)||i,u[1]===!0)return!0}}function Tt(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function Ct(e,t,n,r,i){var o,a=[],s=0,l=e.length,u=null!=t;for(;l>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),u&&t.push(s));return a}function Nt(e,t,n,r,i,o){return r&&!r[b]&&(r=Nt(r)),i&&!i[b]&&(i=Nt(i,o)),ut(function(o,a,s,l){var u,c,p,f=[],d=[],h=a.length,g=o||St(t||"*",s.nodeType?[s]:s,[]),m=!e||!o&&t?g:Ct(g,f,e,s,l),y=n?i||(o?e:h||r)?[]:a:m;if(n&&n(m,y,s,l),r){u=Ct(y,d),r(u,[],s,l),c=u.length;while(c--)(p=u[c])&&(y[d[c]]=!(m[d[c]]=p))}if(o){if(i||e){if(i){u=[],c=y.length;while(c--)(p=y[c])&&u.push(m[c]=p);i(null,y=[],u,l)}c=y.length;while(c--)(p=y[c])&&(u=i?F.call(o,p):f[c])>-1&&(o[u]=!(a[u]=p))}}else y=Ct(y===a?y.splice(h,y.length):y),i?i(null,a,y,l):M.apply(a,y)})}function kt(e){var t,n,r,i=e.length,a=o.relative[e[0].type],s=a||o.relative[" "],l=a?1:0,c=wt(function(e){return e===t},s,!0),p=wt(function(e){return F.call(t,e)>-1},s,!0),f=[function(e,n,r){return!a&&(r||n!==u)||((t=n).nodeType?c(e,n,r):p(e,n,r))}];for(;i>l;l++)if(n=o.relative[e[l].type])f=[wt(Tt(f),n)];else{if(n=o.filter[e[l].type].apply(null,e[l].matches),n[b]){for(r=++l;i>r;r++)if(o.relative[e[r].type])break;return Nt(l>1&&Tt(f),l>1&&xt(e.slice(0,l-1).concat({value:" "===e[l-2].type?"*":""})).replace(z,"$1"),n,r>l&&kt(e.slice(l,r)),i>r&&kt(e=e.slice(r)),i>r&&xt(e))}f.push(n)}return Tt(f)}function Et(e,t){var n=0,r=t.length>0,a=e.length>0,s=function(s,l,c,p,d){var h,g,m,y=[],v=0,b="0",x=s&&[],w=null!=d,C=u,N=s||a&&o.find.TAG("*",d&&l.parentNode||l),k=T+=null==C?1:Math.random()||.1;for(w&&(u=l!==f&&l,i=n);null!=(h=N[b]);b++){if(a&&h){g=0;while(m=e[g++])if(m(h,l,c)){p.push(h);break}w&&(T=k,i=++n)}r&&((h=!m&&h)&&v--,s&&x.push(h))}if(v+=b,r&&b!==v){g=0;while(m=t[g++])m(x,y,l,c);if(s){if(v>0)while(b--)x[b]||y[b]||(y[b]=q.call(p));y=Ct(y)}M.apply(p,y),w&&!s&&y.length>0&&v+t.length>1&&at.uniqueSort(p)}return w&&(T=k,u=C),x};return r?ut(s):s}l=at.compile=function(e,t){var n,r=[],i=[],o=E[e+" "];if(!o){t||(t=bt(e)),n=t.length;while(n--)o=kt(t[n]),o[b]?r.push(o):i.push(o);o=E(e,Et(i,r))}return o};function St(e,t,n){var r=0,i=t.length;for(;i>r;r++)at(e,t[r],n);return n}function At(e,t,n,i){var a,s,u,c,p,f=bt(e);if(!i&&1===f.length){if(s=f[0]=f[0].slice(0),s.length>2&&"ID"===(u=s[0]).type&&r.getById&&9===t.nodeType&&h&&o.relative[s[1].type]){if(t=(o.find.ID(u.matches[0].replace(rt,it),t)||[])[0],!t)return n;e=e.slice(s.shift().value.length)}a=Q.needsContext.test(e)?0:s.length;while(a--){if(u=s[a],o.relative[c=u.type])break;if((p=o.find[c])&&(i=p(u.matches[0].replace(rt,it),V.test(s[0].type)&&t.parentNode||t))){if(s.splice(a,1),e=i.length&&xt(s),!e)return M.apply(n,i),n;break}}}return l(e,f)(i,t,!h,n,V.test(e)),n}o.pseudos.nth=o.pseudos.eq;function jt(){}jt.prototype=o.filters=o.pseudos,o.setFilters=new jt,r.sortStable=b.split("").sort(A).join("")===b,p(),[0,0].sort(A),r.detectDuplicates=S,x.find=at,x.expr=at.selectors,x.expr[":"]=x.expr.pseudos,x.unique=at.uniqueSort,x.text=at.getText,x.isXMLDoc=at.isXML,x.contains=at.contains}(e);var O={};function F(e){var t=O[e]={};return x.each(e.match(T)||[],function(e,n){t[n]=!0}),t}x.Callbacks=function(e){e="string"==typeof e?O[e]||F(e):x.extend({},e);var n,r,i,o,a,s,l=[],u=!e.once&&[],c=function(t){for(r=e.memory&&t,i=!0,a=s||0,s=0,o=l.length,n=!0;l&&o>a;a++)if(l[a].apply(t[0],t[1])===!1&&e.stopOnFalse){r=!1;break}n=!1,l&&(u?u.length&&c(u.shift()):r?l=[]:p.disable())},p={add:function(){if(l){var t=l.length;(function i(t){x.each(t,function(t,n){var r=x.type(n);"function"===r?e.unique&&p.has(n)||l.push(n):n&&n.length&&"string"!==r&&i(n)})})(arguments),n?o=l.length:r&&(s=t,c(r))}return this},remove:function(){return l&&x.each(arguments,function(e,t){var r;while((r=x.inArray(t,l,r))>-1)l.splice(r,1),n&&(o>=r&&o--,a>=r&&a--)}),this},has:function(e){return e?x.inArray(e,l)>-1:!(!l||!l.length)},empty:function(){return l=[],o=0,this},disable:function(){return l=u=r=t,this},disabled:function(){return!l},lock:function(){return u=t,r||p.disable(),this},locked:function(){return!u},fireWith:function(e,t){return t=t||[],t=[e,t.slice?t.slice():t],!l||i&&!u||(n?u.push(t):c(t)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p},x.extend({Deferred:function(e){var t=[["resolve","done",x.Callbacks("once memory"),"resolved"],["reject","fail",x.Callbacks("once memory"),"rejected"],["notify","progress",x.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return x.Deferred(function(n){x.each(t,function(t,o){var a=o[0],s=x.isFunction(e[t])&&e[t];i[o[1]](function(){var e=s&&s.apply(this,arguments);e&&x.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[a+"With"](this===r?n.promise():this,s?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?x.extend(e,r):r}},i={};return r.pipe=r.then,x.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=g.call(arguments),r=n.length,i=1!==r||e&&x.isFunction(e.promise)?r:0,o=1===i?e:x.Deferred(),a=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?g.call(arguments):r,n===s?o.notifyWith(t,n):--i||o.resolveWith(t,n)}},s,l,u;if(r>1)for(s=Array(r),l=Array(r),u=Array(r);r>t;t++)n[t]&&x.isFunction(n[t].promise)?n[t].promise().done(a(t,u,n)).fail(o.reject).progress(a(t,l,s)):--i;return i||o.resolveWith(u,n),o.promise()}}),x.support=function(t){var n,r,o,s,l,u,c,p,f,d=a.createElement("div");if(d.setAttribute("className","t"),d.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",n=d.getElementsByTagName("*")||[],r=d.getElementsByTagName("a")[0],!r||!r.style||!n.length)return t;s=a.createElement("select"),u=s.appendChild(a.createElement("option")),o=d.getElementsByTagName("input")[0],r.style.cssText="top:1px;float:left;opacity:.5",t.getSetAttribute="t"!==d.className,t.leadingWhitespace=3===d.firstChild.nodeType,t.tbody=!d.getElementsByTagName("tbody").length,t.htmlSerialize=!!d.getElementsByTagName("link").length,t.style=/top/.test(r.getAttribute("style")),t.hrefNormalized="/a"===r.getAttribute("href"),t.opacity=/^0.5/.test(r.style.opacity),t.cssFloat=!!r.style.cssFloat,t.checkOn=!!o.value,t.optSelected=u.selected,t.enctype=!!a.createElement("form").enctype,t.html5Clone="<:nav></:nav>"!==a.createElement("nav").cloneNode(!0).outerHTML,t.inlineBlockNeedsLayout=!1,t.shrinkWrapBlocks=!1,t.pixelPosition=!1,t.deleteExpando=!0,t.noCloneEvent=!0,t.reliableMarginRight=!0,t.boxSizingReliable=!0,o.checked=!0,t.noCloneChecked=o.cloneNode(!0).checked,s.disabled=!0,t.optDisabled=!u.disabled;try{delete d.test}catch(h){t.deleteExpando=!1}o=a.createElement("input"),o.setAttribute("value",""),t.input=""===o.getAttribute("value"),o.value="t",o.setAttribute("type","radio"),t.radioValue="t"===o.value,o.setAttribute("checked","t"),o.setAttribute("name","t"),l=a.createDocumentFragment(),l.appendChild(o),t.appendChecked=o.checked,t.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,d.attachEvent&&(d.attachEvent("onclick",function(){t.noCloneEvent=!1}),d.cloneNode(!0).click());for(f in{submit:!0,change:!0,focusin:!0})d.setAttribute(c="on"+f,"t"),t[f+"Bubbles"]=c in e||d.attributes[c].expando===!1;d.style.backgroundClip="content-box",d.cloneNode(!0).style.backgroundClip="",t.clearCloneStyle="content-box"===d.style.backgroundClip;for(f in x(t))break;return t.ownLast="0"!==f,x(function(){var n,r,o,s="padding:0;margin:0;border:0;display:block;box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;",l=a.getElementsByTagName("body")[0];l&&(n=a.createElement("div"),n.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",l.appendChild(n).appendChild(d),d.innerHTML="<table><tr><td></td><td>t</td></tr></table>",o=d.getElementsByTagName("td"),o[0].style.cssText="padding:0;margin:0;border:0;display:none",p=0===o[0].offsetHeight,o[0].style.display="",o[1].style.display="none",t.reliableHiddenOffsets=p&&0===o[0].offsetHeight,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",x.swap(l,null!=l.style.zoom?{zoom:1}:{},function(){t.boxSizing=4===d.offsetWidth}),e.getComputedStyle&&(t.pixelPosition="1%"!==(e.getComputedStyle(d,null)||{}).top,t.boxSizingReliable="4px"===(e.getComputedStyle(d,null)||{width:"4px"}).width,r=d.appendChild(a.createElement("div")),r.style.cssText=d.style.cssText=s,r.style.marginRight=r.style.width="0",d.style.width="1px",t.reliableMarginRight=!parseFloat((e.getComputedStyle(r,null)||{}).marginRight)),typeof d.style.zoom!==i&&(d.innerHTML="",d.style.cssText=s+"width:1px;padding:1px;display:inline;zoom:1",t.inlineBlockNeedsLayout=3===d.offsetWidth,d.style.display="block",d.innerHTML="<div></div>",d.firstChild.style.width="5px",t.shrinkWrapBlocks=3!==d.offsetWidth,t.inlineBlockNeedsLayout&&(l.style.zoom=1)),l.removeChild(n),n=d=o=r=null)
|
5 |
+
}),n=s=l=u=r=o=null,t}({});var B=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,P=/([A-Z])/g;function R(e,n,r,i){if(x.acceptData(e)){var o,a,s=x.expando,l=e.nodeType,u=l?x.cache:e,c=l?e[s]:e[s]&&s;if(c&&u[c]&&(i||u[c].data)||r!==t||"string"!=typeof n)return c||(c=l?e[s]=p.pop()||x.guid++:s),u[c]||(u[c]=l?{}:{toJSON:x.noop}),("object"==typeof n||"function"==typeof n)&&(i?u[c]=x.extend(u[c],n):u[c].data=x.extend(u[c].data,n)),a=u[c],i||(a.data||(a.data={}),a=a.data),r!==t&&(a[x.camelCase(n)]=r),"string"==typeof n?(o=a[n],null==o&&(o=a[x.camelCase(n)])):o=a,o}}function W(e,t,n){if(x.acceptData(e)){var r,i,o=e.nodeType,a=o?x.cache:e,s=o?e[x.expando]:x.expando;if(a[s]){if(t&&(r=n?a[s]:a[s].data)){x.isArray(t)?t=t.concat(x.map(t,x.camelCase)):t in r?t=[t]:(t=x.camelCase(t),t=t in r?[t]:t.split(" ")),i=t.length;while(i--)delete r[t[i]];if(n?!I(r):!x.isEmptyObject(r))return}(n||(delete a[s].data,I(a[s])))&&(o?x.cleanData([e],!0):x.support.deleteExpando||a!=a.window?delete a[s]:a[s]=null)}}}x.extend({cache:{},noData:{applet:!0,embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return e=e.nodeType?x.cache[e[x.expando]]:e[x.expando],!!e&&!I(e)},data:function(e,t,n){return R(e,t,n)},removeData:function(e,t){return W(e,t)},_data:function(e,t,n){return R(e,t,n,!0)},_removeData:function(e,t){return W(e,t,!0)},acceptData:function(e){if(e.nodeType&&1!==e.nodeType&&9!==e.nodeType)return!1;var t=e.nodeName&&x.noData[e.nodeName.toLowerCase()];return!t||t!==!0&&e.getAttribute("classid")===t}}),x.fn.extend({data:function(e,n){var r,i,o=null,a=0,s=this[0];if(e===t){if(this.length&&(o=x.data(s),1===s.nodeType&&!x._data(s,"parsedAttrs"))){for(r=s.attributes;r.length>a;a++)i=r[a].name,0===i.indexOf("data-")&&(i=x.camelCase(i.slice(5)),$(s,i,o[i]));x._data(s,"parsedAttrs",!0)}return o}return"object"==typeof e?this.each(function(){x.data(this,e)}):arguments.length>1?this.each(function(){x.data(this,e,n)}):s?$(s,e,x.data(s,e)):null},removeData:function(e){return this.each(function(){x.removeData(this,e)})}});function $(e,n,r){if(r===t&&1===e.nodeType){var i="data-"+n.replace(P,"-$1").toLowerCase();if(r=e.getAttribute(i),"string"==typeof r){try{r="true"===r?!0:"false"===r?!1:"null"===r?null:+r+""===r?+r:B.test(r)?x.parseJSON(r):r}catch(o){}x.data(e,n,r)}else r=t}return r}function I(e){var t;for(t in e)if(("data"!==t||!x.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}x.extend({queue:function(e,n,r){var i;return e?(n=(n||"fx")+"queue",i=x._data(e,n),r&&(!i||x.isArray(r)?i=x._data(e,n,x.makeArray(r)):i.push(r)),i||[]):t},dequeue:function(e,t){t=t||"fx";var n=x.queue(e,t),r=n.length,i=n.shift(),o=x._queueHooks(e,t),a=function(){x.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return x._data(e,n)||x._data(e,n,{empty:x.Callbacks("once memory").add(function(){x._removeData(e,t+"queue"),x._removeData(e,n)})})}}),x.fn.extend({queue:function(e,n){var r=2;return"string"!=typeof e&&(n=e,e="fx",r--),r>arguments.length?x.queue(this[0],e):n===t?this:this.each(function(){var t=x.queue(this,e,n);x._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&x.dequeue(this,e)})},dequeue:function(e){return this.each(function(){x.dequeue(this,e)})},delay:function(e,t){return e=x.fx?x.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,n){var r,i=1,o=x.Deferred(),a=this,s=this.length,l=function(){--i||o.resolveWith(a,[a])};"string"!=typeof e&&(n=e,e=t),e=e||"fx";while(s--)r=x._data(a[s],e+"queueHooks"),r&&r.empty&&(i++,r.empty.add(l));return l(),o.promise(n)}});var z,X,U=/[\t\r\n\f]/g,V=/\r/g,Y=/^(?:input|select|textarea|button|object)$/i,J=/^(?:a|area)$/i,G=/^(?:checked|selected)$/i,Q=x.support.getSetAttribute,K=x.support.input;x.fn.extend({attr:function(e,t){return x.access(this,x.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){x.removeAttr(this,e)})},prop:function(e,t){return x.access(this,x.prop,e,t,arguments.length>1)},removeProp:function(e){return e=x.propFix[e]||e,this.each(function(){try{this[e]=t,delete this[e]}catch(n){}})},addClass:function(e){var t,n,r,i,o,a=0,s=this.length,l="string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).addClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):" ")){o=0;while(i=t[o++])0>r.indexOf(" "+i+" ")&&(r+=i+" ");n.className=x.trim(r)}return this},removeClass:function(e){var t,n,r,i,o,a=0,s=this.length,l=0===arguments.length||"string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).removeClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):"")){o=0;while(i=t[o++])while(r.indexOf(" "+i+" ")>=0)r=r.replace(" "+i+" "," ");n.className=e?x.trim(r):""}return this},toggleClass:function(e,t){var n=typeof e,r="boolean"==typeof t;return x.isFunction(e)?this.each(function(n){x(this).toggleClass(e.call(this,n,this.className,t),t)}):this.each(function(){if("string"===n){var o,a=0,s=x(this),l=t,u=e.match(T)||[];while(o=u[a++])l=r?l:!s.hasClass(o),s[l?"addClass":"removeClass"](o)}else(n===i||"boolean"===n)&&(this.className&&x._data(this,"__className__",this.className),this.className=this.className||e===!1?"":x._data(this,"__className__")||"")})},hasClass:function(e){var t=" "+e+" ",n=0,r=this.length;for(;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(U," ").indexOf(t)>=0)return!0;return!1},val:function(e){var n,r,i,o=this[0];{if(arguments.length)return i=x.isFunction(e),this.each(function(n){var o;1===this.nodeType&&(o=i?e.call(this,n,x(this).val()):e,null==o?o="":"number"==typeof o?o+="":x.isArray(o)&&(o=x.map(o,function(e){return null==e?"":e+""})),r=x.valHooks[this.type]||x.valHooks[this.nodeName.toLowerCase()],r&&"set"in r&&r.set(this,o,"value")!==t||(this.value=o))});if(o)return r=x.valHooks[o.type]||x.valHooks[o.nodeName.toLowerCase()],r&&"get"in r&&(n=r.get(o,"value"))!==t?n:(n=o.value,"string"==typeof n?n.replace(V,""):null==n?"":n)}}}),x.extend({valHooks:{option:{get:function(e){var t=x.find.attr(e,"value");return null!=t?t:e.text}},select:{get:function(e){var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,l=0>i?s:o?i:0;for(;s>l;l++)if(n=r[l],!(!n.selected&&l!==i||(x.support.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&x.nodeName(n.parentNode,"optgroup"))){if(t=x(n).val(),o)return t;a.push(t)}return a},set:function(e,t){var n,r,i=e.options,o=x.makeArray(t),a=i.length;while(a--)r=i[a],(r.selected=x.inArray(x(r).val(),o)>=0)&&(n=!0);return n||(e.selectedIndex=-1),o}}},attr:function(e,n,r){var o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return typeof e.getAttribute===i?x.prop(e,n,r):(1===s&&x.isXMLDoc(e)||(n=n.toLowerCase(),o=x.attrHooks[n]||(x.expr.match.bool.test(n)?X:z)),r===t?o&&"get"in o&&null!==(a=o.get(e,n))?a:(a=x.find.attr(e,n),null==a?t:a):null!==r?o&&"set"in o&&(a=o.set(e,r,n))!==t?a:(e.setAttribute(n,r+""),r):(x.removeAttr(e,n),t))},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(T);if(o&&1===e.nodeType)while(n=o[i++])r=x.propFix[n]||n,x.expr.match.bool.test(n)?K&&Q||!G.test(n)?e[r]=!1:e[x.camelCase("default-"+n)]=e[r]=!1:x.attr(e,n,""),e.removeAttribute(Q?n:r)},attrHooks:{type:{set:function(e,t){if(!x.support.radioValue&&"radio"===t&&x.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},propFix:{"for":"htmlFor","class":"className"},prop:function(e,n,r){var i,o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return a=1!==s||!x.isXMLDoc(e),a&&(n=x.propFix[n]||n,o=x.propHooks[n]),r!==t?o&&"set"in o&&(i=o.set(e,r,n))!==t?i:e[n]=r:o&&"get"in o&&null!==(i=o.get(e,n))?i:e[n]},propHooks:{tabIndex:{get:function(e){var t=x.find.attr(e,"tabindex");return t?parseInt(t,10):Y.test(e.nodeName)||J.test(e.nodeName)&&e.href?0:-1}}}}),X={set:function(e,t,n){return t===!1?x.removeAttr(e,n):K&&Q||!G.test(n)?e.setAttribute(!Q&&x.propFix[n]||n,n):e[x.camelCase("default-"+n)]=e[n]=!0,n}},x.each(x.expr.match.bool.source.match(/\w+/g),function(e,n){var r=x.expr.attrHandle[n]||x.find.attr;x.expr.attrHandle[n]=K&&Q||!G.test(n)?function(e,n,i){var o=x.expr.attrHandle[n],a=i?t:(x.expr.attrHandle[n]=t)!=r(e,n,i)?n.toLowerCase():null;return x.expr.attrHandle[n]=o,a}:function(e,n,r){return r?t:e[x.camelCase("default-"+n)]?n.toLowerCase():null}}),K&&Q||(x.attrHooks.value={set:function(e,n,r){return x.nodeName(e,"input")?(e.defaultValue=n,t):z&&z.set(e,n,r)}}),Q||(z={set:function(e,n,r){var i=e.getAttributeNode(r);return i||e.setAttributeNode(i=e.ownerDocument.createAttribute(r)),i.value=n+="","value"===r||n===e.getAttribute(r)?n:t}},x.expr.attrHandle.id=x.expr.attrHandle.name=x.expr.attrHandle.coords=function(e,n,r){var i;return r?t:(i=e.getAttributeNode(n))&&""!==i.value?i.value:null},x.valHooks.button={get:function(e,n){var r=e.getAttributeNode(n);return r&&r.specified?r.value:t},set:z.set},x.attrHooks.contenteditable={set:function(e,t,n){z.set(e,""===t?!1:t,n)}},x.each(["width","height"],function(e,n){x.attrHooks[n]={set:function(e,r){return""===r?(e.setAttribute(n,"auto"),r):t}}})),x.support.hrefNormalized||x.each(["href","src"],function(e,t){x.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),x.support.style||(x.attrHooks.style={get:function(e){return e.style.cssText||t},set:function(e,t){return e.style.cssText=t+""}}),x.support.optSelected||(x.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}}),x.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){x.propFix[this.toLowerCase()]=this}),x.support.enctype||(x.propFix.enctype="encoding"),x.each(["radio","checkbox"],function(){x.valHooks[this]={set:function(e,n){return x.isArray(n)?e.checked=x.inArray(x(e).val(),n)>=0:t}},x.support.checkOn||(x.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Z=/^(?:input|select|textarea)$/i,et=/^key/,tt=/^(?:mouse|contextmenu)|click/,nt=/^(?:focusinfocus|focusoutblur)$/,rt=/^([^.]*)(?:\.(.+)|)$/;function it(){return!0}function ot(){return!1}function at(){try{return a.activeElement}catch(e){}}x.event={global:{},add:function(e,n,r,o,a){var s,l,u,c,p,f,d,h,g,m,y,v=x._data(e);if(v){r.handler&&(c=r,r=c.handler,a=c.selector),r.guid||(r.guid=x.guid++),(l=v.events)||(l=v.events={}),(f=v.handle)||(f=v.handle=function(e){return typeof x===i||e&&x.event.triggered===e.type?t:x.event.dispatch.apply(f.elem,arguments)},f.elem=e),n=(n||"").match(T)||[""],u=n.length;while(u--)s=rt.exec(n[u])||[],g=y=s[1],m=(s[2]||"").split(".").sort(),g&&(p=x.event.special[g]||{},g=(a?p.delegateType:p.bindType)||g,p=x.event.special[g]||{},d=x.extend({type:g,origType:y,data:o,handler:r,guid:r.guid,selector:a,needsContext:a&&x.expr.match.needsContext.test(a),namespace:m.join(".")},c),(h=l[g])||(h=l[g]=[],h.delegateCount=0,p.setup&&p.setup.call(e,o,m,f)!==!1||(e.addEventListener?e.addEventListener(g,f,!1):e.attachEvent&&e.attachEvent("on"+g,f))),p.add&&(p.add.call(e,d),d.handler.guid||(d.handler.guid=r.guid)),a?h.splice(h.delegateCount++,0,d):h.push(d),x.event.global[g]=!0);e=null}},remove:function(e,t,n,r,i){var o,a,s,l,u,c,p,f,d,h,g,m=x.hasData(e)&&x._data(e);if(m&&(c=m.events)){t=(t||"").match(T)||[""],u=t.length;while(u--)if(s=rt.exec(t[u])||[],d=g=s[1],h=(s[2]||"").split(".").sort(),d){p=x.event.special[d]||{},d=(r?p.delegateType:p.bindType)||d,f=c[d]||[],s=s[2]&&RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=o=f.length;while(o--)a=f[o],!i&&g!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,p.remove&&p.remove.call(e,a));l&&!f.length&&(p.teardown&&p.teardown.call(e,h,m.handle)!==!1||x.removeEvent(e,d,m.handle),delete c[d])}else for(d in c)x.event.remove(e,d+t[u],n,r,!0);x.isEmptyObject(c)&&(delete m.handle,x._removeData(e,"events"))}},trigger:function(n,r,i,o){var s,l,u,c,p,f,d,h=[i||a],g=v.call(n,"type")?n.type:n,m=v.call(n,"namespace")?n.namespace.split("."):[];if(u=f=i=i||a,3!==i.nodeType&&8!==i.nodeType&&!nt.test(g+x.event.triggered)&&(g.indexOf(".")>=0&&(m=g.split("."),g=m.shift(),m.sort()),l=0>g.indexOf(":")&&"on"+g,n=n[x.expando]?n:new x.Event(g,"object"==typeof n&&n),n.isTrigger=o?2:3,n.namespace=m.join("."),n.namespace_re=n.namespace?RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,n.result=t,n.target||(n.target=i),r=null==r?[n]:x.makeArray(r,[n]),p=x.event.special[g]||{},o||!p.trigger||p.trigger.apply(i,r)!==!1)){if(!o&&!p.noBubble&&!x.isWindow(i)){for(c=p.delegateType||g,nt.test(c+g)||(u=u.parentNode);u;u=u.parentNode)h.push(u),f=u;f===(i.ownerDocument||a)&&h.push(f.defaultView||f.parentWindow||e)}d=0;while((u=h[d++])&&!n.isPropagationStopped())n.type=d>1?c:p.bindType||g,s=(x._data(u,"events")||{})[n.type]&&x._data(u,"handle"),s&&s.apply(u,r),s=l&&u[l],s&&x.acceptData(u)&&s.apply&&s.apply(u,r)===!1&&n.preventDefault();if(n.type=g,!o&&!n.isDefaultPrevented()&&(!p._default||p._default.apply(h.pop(),r)===!1)&&x.acceptData(i)&&l&&i[g]&&!x.isWindow(i)){f=i[l],f&&(i[l]=null),x.event.triggered=g;try{i[g]()}catch(y){}x.event.triggered=t,f&&(i[l]=f)}return n.result}},dispatch:function(e){e=x.event.fix(e);var n,r,i,o,a,s=[],l=g.call(arguments),u=(x._data(this,"events")||{})[e.type]||[],c=x.event.special[e.type]||{};if(l[0]=e,e.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,e)!==!1){s=x.event.handlers.call(this,e,u),n=0;while((o=s[n++])&&!e.isPropagationStopped()){e.currentTarget=o.elem,a=0;while((i=o.handlers[a++])&&!e.isImmediatePropagationStopped())(!e.namespace_re||e.namespace_re.test(i.namespace))&&(e.handleObj=i,e.data=i.data,r=((x.event.special[i.origType]||{}).handle||i.handler).apply(o.elem,l),r!==t&&(e.result=r)===!1&&(e.preventDefault(),e.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,n){var r,i,o,a,s=[],l=n.delegateCount,u=e.target;if(l&&u.nodeType&&(!e.button||"click"!==e.type))for(;u!=this;u=u.parentNode||this)if(1===u.nodeType&&(u.disabled!==!0||"click"!==e.type)){for(o=[],a=0;l>a;a++)i=n[a],r=i.selector+" ",o[r]===t&&(o[r]=i.needsContext?x(r,this).index(u)>=0:x.find(r,this,null,[u]).length),o[r]&&o.push(i);o.length&&s.push({elem:u,handlers:o})}return n.length>l&&s.push({elem:this,handlers:n.slice(l)}),s},fix:function(e){if(e[x.expando])return e;var t,n,r,i=e.type,o=e,s=this.fixHooks[i];s||(this.fixHooks[i]=s=tt.test(i)?this.mouseHooks:et.test(i)?this.keyHooks:{}),r=s.props?this.props.concat(s.props):this.props,e=new x.Event(o),t=r.length;while(t--)n=r[t],e[n]=o[n];return e.target||(e.target=o.srcElement||a),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,o):e},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,n){var r,i,o,s=n.button,l=n.fromElement;return null==e.pageX&&null!=n.clientX&&(i=e.target.ownerDocument||a,o=i.documentElement,r=i.body,e.pageX=n.clientX+(o&&o.scrollLeft||r&&r.scrollLeft||0)-(o&&o.clientLeft||r&&r.clientLeft||0),e.pageY=n.clientY+(o&&o.scrollTop||r&&r.scrollTop||0)-(o&&o.clientTop||r&&r.clientTop||0)),!e.relatedTarget&&l&&(e.relatedTarget=l===e.target?n.toElement:l),e.which||s===t||(e.which=1&s?1:2&s?3:4&s?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==at()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===at()&&this.blur?(this.blur(),!1):t},delegateType:"focusout"},click:{trigger:function(){return x.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):t},_default:function(e){return x.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){e.result!==t&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,r){var i=x.extend(new x.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?x.event.trigger(i,null,t):x.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},x.removeEvent=a.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]===i&&(e[r]=null),e.detachEvent(r,n))},x.Event=function(e,n){return this instanceof x.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.returnValue===!1||e.getPreventDefault&&e.getPreventDefault()?it:ot):this.type=e,n&&x.extend(this,n),this.timeStamp=e&&e.timeStamp||x.now(),this[x.expando]=!0,t):new x.Event(e,n)},x.Event.prototype={isDefaultPrevented:ot,isPropagationStopped:ot,isImmediatePropagationStopped:ot,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=it,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=it,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=it,this.stopPropagation()}},x.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(e,t){x.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return(!i||i!==r&&!x.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),x.support.submitBubbles||(x.event.special.submit={setup:function(){return x.nodeName(this,"form")?!1:(x.event.add(this,"click._submit keypress._submit",function(e){var n=e.target,r=x.nodeName(n,"input")||x.nodeName(n,"button")?n.form:t;r&&!x._data(r,"submitBubbles")&&(x.event.add(r,"submit._submit",function(e){e._submit_bubble=!0}),x._data(r,"submitBubbles",!0))}),t)},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&x.event.simulate("submit",this.parentNode,e,!0))},teardown:function(){return x.nodeName(this,"form")?!1:(x.event.remove(this,"._submit"),t)}}),x.support.changeBubbles||(x.event.special.change={setup:function(){return Z.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(x.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),x.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),x.event.simulate("change",this,e,!0)})),!1):(x.event.add(this,"beforeactivate._change",function(e){var t=e.target;Z.test(t.nodeName)&&!x._data(t,"changeBubbles")&&(x.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||x.event.simulate("change",this.parentNode,e,!0)}),x._data(t,"changeBubbles",!0))}),t)},handle:function(e){var n=e.target;return this!==n||e.isSimulated||e.isTrigger||"radio"!==n.type&&"checkbox"!==n.type?e.handleObj.handler.apply(this,arguments):t},teardown:function(){return x.event.remove(this,"._change"),!Z.test(this.nodeName)}}),x.support.focusinBubbles||x.each({focus:"focusin",blur:"focusout"},function(e,t){var n=0,r=function(e){x.event.simulate(t,e.target,x.event.fix(e),!0)};x.event.special[t]={setup:function(){0===n++&&a.addEventListener(e,r,!0)},teardown:function(){0===--n&&a.removeEventListener(e,r,!0)}}}),x.fn.extend({on:function(e,n,r,i,o){var a,s;if("object"==typeof e){"string"!=typeof n&&(r=r||n,n=t);for(a in e)this.on(a,n,r,e[a],o);return this}if(null==r&&null==i?(i=n,r=n=t):null==i&&("string"==typeof n?(i=r,r=t):(i=r,r=n,n=t)),i===!1)i=ot;else if(!i)return this;return 1===o&&(s=i,i=function(e){return x().off(e),s.apply(this,arguments)},i.guid=s.guid||(s.guid=x.guid++)),this.each(function(){x.event.add(this,e,i,r,n)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,n,r){var i,o;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,x(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof e){for(o in e)this.off(o,n,e[o]);return this}return(n===!1||"function"==typeof n)&&(r=n,n=t),r===!1&&(r=ot),this.each(function(){x.event.remove(this,e,r,n)})},trigger:function(e,t){return this.each(function(){x.event.trigger(e,t,this)})},triggerHandler:function(e,n){var r=this[0];return r?x.event.trigger(e,n,r,!0):t}});var st=/^.[^:#\[\.,]*$/,lt=/^(?:parents|prev(?:Until|All))/,ut=x.expr.match.needsContext,ct={children:!0,contents:!0,next:!0,prev:!0};x.fn.extend({find:function(e){var t,n=[],r=this,i=r.length;if("string"!=typeof e)return this.pushStack(x(e).filter(function(){for(t=0;i>t;t++)if(x.contains(r[t],this))return!0}));for(t=0;i>t;t++)x.find(e,r[t],n);return n=this.pushStack(i>1?x.unique(n):n),n.selector=this.selector?this.selector+" "+e:e,n},has:function(e){var t,n=x(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(x.contains(this,n[t]))return!0})},not:function(e){return this.pushStack(ft(this,e||[],!0))},filter:function(e){return this.pushStack(ft(this,e||[],!1))},is:function(e){return!!ft(this,"string"==typeof e&&ut.test(e)?x(e):e||[],!1).length},closest:function(e,t){var n,r=0,i=this.length,o=[],a=ut.test(e)||"string"!=typeof e?x(e,t||this.context):0;for(;i>r;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(11>n.nodeType&&(a?a.index(n)>-1:1===n.nodeType&&x.find.matchesSelector(n,e))){n=o.push(n);break}return this.pushStack(o.length>1?x.unique(o):o)},index:function(e){return e?"string"==typeof e?x.inArray(this[0],x(e)):x.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){var n="string"==typeof e?x(e,t):x.makeArray(e&&e.nodeType?[e]:e),r=x.merge(this.get(),n);return this.pushStack(x.unique(r))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}});function pt(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}x.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return x.dir(e,"parentNode")},parentsUntil:function(e,t,n){return x.dir(e,"parentNode",n)},next:function(e){return pt(e,"nextSibling")},prev:function(e){return pt(e,"previousSibling")},nextAll:function(e){return x.dir(e,"nextSibling")},prevAll:function(e){return x.dir(e,"previousSibling")},nextUntil:function(e,t,n){return x.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return x.dir(e,"previousSibling",n)},siblings:function(e){return x.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return x.sibling(e.firstChild)},contents:function(e){return x.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:x.merge([],e.childNodes)}},function(e,t){x.fn[e]=function(n,r){var i=x.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=x.filter(r,i)),this.length>1&&(ct[e]||(i=x.unique(i)),lt.test(e)&&(i=i.reverse())),this.pushStack(i)}}),x.extend({filter:function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?x.find.matchesSelector(r,e)?[r]:[]:x.find.matches(e,x.grep(t,function(e){return 1===e.nodeType}))},dir:function(e,n,r){var i=[],o=e[n];while(o&&9!==o.nodeType&&(r===t||1!==o.nodeType||!x(o).is(r)))1===o.nodeType&&i.push(o),o=o[n];return i},sibling:function(e,t){var n=[];for(;e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}});function ft(e,t,n){if(x.isFunction(t))return x.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return x.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(st.test(t))return x.filter(t,e,n);t=x.filter(t,e)}return x.grep(e,function(e){return x.inArray(e,t)>=0!==n})}function dt(e){var t=ht.split("|"),n=e.createDocumentFragment();if(n.createElement)while(t.length)n.createElement(t.pop());return n}var ht="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",gt=/ jQuery\d+="(?:null|\d+)"/g,mt=RegExp("<(?:"+ht+")[\\s/>]","i"),yt=/^\s+/,vt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bt=/<([\w:]+)/,xt=/<tbody/i,wt=/<|&#?\w+;/,Tt=/<(?:script|style|link)/i,Ct=/^(?:checkbox|radio)$/i,Nt=/checked\s*(?:[^=]|=\s*.checked.)/i,kt=/^$|\/(?:java|ecma)script/i,Et=/^true\/(.*)/,St=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,At={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:x.support.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},jt=dt(a),Dt=jt.appendChild(a.createElement("div"));At.optgroup=At.option,At.tbody=At.tfoot=At.colgroup=At.caption=At.thead,At.th=At.td,x.fn.extend({text:function(e){return x.access(this,function(e){return e===t?x.text(this):this.empty().append((this[0]&&this[0].ownerDocument||a).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){var n,r=e?x.filter(e,this):this,i=0;for(;null!=(n=r[i]);i++)t||1!==n.nodeType||x.cleanData(Ft(n)),n.parentNode&&(t&&x.contains(n.ownerDocument,n)&&_t(Ft(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){var e,t=0;for(;null!=(e=this[t]);t++){1===e.nodeType&&x.cleanData(Ft(e,!1));while(e.firstChild)e.removeChild(e.firstChild);e.options&&x.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return x.clone(this,e,t)})},html:function(e){return x.access(this,function(e){var n=this[0]||{},r=0,i=this.length;if(e===t)return 1===n.nodeType?n.innerHTML.replace(gt,""):t;if(!("string"!=typeof e||Tt.test(e)||!x.support.htmlSerialize&&mt.test(e)||!x.support.leadingWhitespace&&yt.test(e)||At[(bt.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(vt,"<$1></$2>");try{for(;i>r;r++)n=this[r]||{},1===n.nodeType&&(x.cleanData(Ft(n,!1)),n.innerHTML=e);n=0}catch(o){}}n&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=x.map(this,function(e){return[e.nextSibling,e.parentNode]}),t=0;return this.domManip(arguments,function(n){var r=e[t++],i=e[t++];i&&(r&&r.parentNode!==i&&(r=this.nextSibling),x(this).remove(),i.insertBefore(n,r))},!0),t?this:this.remove()},detach:function(e){return this.remove(e,!0)},domManip:function(e,t,n){e=d.apply([],e);var r,i,o,a,s,l,u=0,c=this.length,p=this,f=c-1,h=e[0],g=x.isFunction(h);if(g||!(1>=c||"string"!=typeof h||x.support.checkClone)&&Nt.test(h))return this.each(function(r){var i=p.eq(r);g&&(e[0]=h.call(this,r,i.html())),i.domManip(e,t,n)});if(c&&(l=x.buildFragment(e,this[0].ownerDocument,!1,!n&&this),r=l.firstChild,1===l.childNodes.length&&(l=r),r)){for(a=x.map(Ft(l,"script"),Ht),o=a.length;c>u;u++)i=l,u!==f&&(i=x.clone(i,!0,!0),o&&x.merge(a,Ft(i,"script"))),t.call(this[u],i,u);if(o)for(s=a[a.length-1].ownerDocument,x.map(a,qt),u=0;o>u;u++)i=a[u],kt.test(i.type||"")&&!x._data(i,"globalEval")&&x.contains(s,i)&&(i.src?x._evalUrl(i.src):x.globalEval((i.text||i.textContent||i.innerHTML||"").replace(St,"")));l=r=null}return this}});function Lt(e,t){return x.nodeName(e,"table")&&x.nodeName(1===t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function Ht(e){return e.type=(null!==x.find.attr(e,"type"))+"/"+e.type,e}function qt(e){var t=Et.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function _t(e,t){var n,r=0;for(;null!=(n=e[r]);r++)x._data(n,"globalEval",!t||x._data(t[r],"globalEval"))}function Mt(e,t){if(1===t.nodeType&&x.hasData(e)){var n,r,i,o=x._data(e),a=x._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)x.event.add(t,n,s[n][r])}a.data&&(a.data=x.extend({},a.data))}}function Ot(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!x.support.noCloneEvent&&t[x.expando]){i=x._data(t);for(r in i.events)x.removeEvent(t,r,i.handle);t.removeAttribute(x.expando)}"script"===n&&t.text!==e.text?(Ht(t).text=e.text,qt(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),x.support.html5Clone&&e.innerHTML&&!x.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&Ct.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}x.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){x.fn[e]=function(e){var n,r=0,i=[],o=x(e),a=o.length-1;for(;a>=r;r++)n=r===a?this:this.clone(!0),x(o[r])[t](n),h.apply(i,n.get());return this.pushStack(i)}});function Ft(e,n){var r,o,a=0,s=typeof e.getElementsByTagName!==i?e.getElementsByTagName(n||"*"):typeof e.querySelectorAll!==i?e.querySelectorAll(n||"*"):t;if(!s)for(s=[],r=e.childNodes||e;null!=(o=r[a]);a++)!n||x.nodeName(o,n)?s.push(o):x.merge(s,Ft(o,n));return n===t||n&&x.nodeName(e,n)?x.merge([e],s):s}function Bt(e){Ct.test(e.type)&&(e.defaultChecked=e.checked)}x.extend({clone:function(e,t,n){var r,i,o,a,s,l=x.contains(e.ownerDocument,e);if(x.support.html5Clone||x.isXMLDoc(e)||!mt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Dt.innerHTML=e.outerHTML,Dt.removeChild(o=Dt.firstChild)),!(x.support.noCloneEvent&&x.support.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||x.isXMLDoc(e)))for(r=Ft(o),s=Ft(e),a=0;null!=(i=s[a]);++a)r[a]&&Ot(i,r[a]);if(t)if(n)for(s=s||Ft(e),r=r||Ft(o),a=0;null!=(i=s[a]);a++)Mt(i,r[a]);else Mt(e,o);return r=Ft(o,"script"),r.length>0&&_t(r,!l&&Ft(e,"script")),r=s=i=null,o},buildFragment:function(e,t,n,r){var i,o,a,s,l,u,c,p=e.length,f=dt(t),d=[],h=0;for(;p>h;h++)if(o=e[h],o||0===o)if("object"===x.type(o))x.merge(d,o.nodeType?[o]:o);else if(wt.test(o)){s=s||f.appendChild(t.createElement("div")),l=(bt.exec(o)||["",""])[1].toLowerCase(),c=At[l]||At._default,s.innerHTML=c[1]+o.replace(vt,"<$1></$2>")+c[2],i=c[0];while(i--)s=s.lastChild;if(!x.support.leadingWhitespace&&yt.test(o)&&d.push(t.createTextNode(yt.exec(o)[0])),!x.support.tbody){o="table"!==l||xt.test(o)?"<table>"!==c[1]||xt.test(o)?0:s:s.firstChild,i=o&&o.childNodes.length;while(i--)x.nodeName(u=o.childNodes[i],"tbody")&&!u.childNodes.length&&o.removeChild(u)}x.merge(d,s.childNodes),s.textContent="";while(s.firstChild)s.removeChild(s.firstChild);s=f.lastChild}else d.push(t.createTextNode(o));s&&f.removeChild(s),x.support.appendChecked||x.grep(Ft(d,"input"),Bt),h=0;while(o=d[h++])if((!r||-1===x.inArray(o,r))&&(a=x.contains(o.ownerDocument,o),s=Ft(f.appendChild(o),"script"),a&&_t(s),n)){i=0;while(o=s[i++])kt.test(o.type||"")&&n.push(o)}return s=null,f},cleanData:function(e,t){var n,r,o,a,s=0,l=x.expando,u=x.cache,c=x.support.deleteExpando,f=x.event.special;for(;null!=(n=e[s]);s++)if((t||x.acceptData(n))&&(o=n[l],a=o&&u[o])){if(a.events)for(r in a.events)f[r]?x.event.remove(n,r):x.removeEvent(n,r,a.handle);
|
6 |
+
u[o]&&(delete u[o],c?delete n[l]:typeof n.removeAttribute!==i?n.removeAttribute(l):n[l]=null,p.push(o))}},_evalUrl:function(e){return x.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})}}),x.fn.extend({wrapAll:function(e){if(x.isFunction(e))return this.each(function(t){x(this).wrapAll(e.call(this,t))});if(this[0]){var t=x(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstChild&&1===e.firstChild.nodeType)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return x.isFunction(e)?this.each(function(t){x(this).wrapInner(e.call(this,t))}):this.each(function(){var t=x(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=x.isFunction(e);return this.each(function(n){x(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){x.nodeName(this,"body")||x(this).replaceWith(this.childNodes)}).end()}});var Pt,Rt,Wt,$t=/alpha\([^)]*\)/i,It=/opacity\s*=\s*([^)]*)/,zt=/^(top|right|bottom|left)$/,Xt=/^(none|table(?!-c[ea]).+)/,Ut=/^margin/,Vt=RegExp("^("+w+")(.*)$","i"),Yt=RegExp("^("+w+")(?!px)[a-z%]+$","i"),Jt=RegExp("^([+-])=("+w+")","i"),Gt={BODY:"block"},Qt={position:"absolute",visibility:"hidden",display:"block"},Kt={letterSpacing:0,fontWeight:400},Zt=["Top","Right","Bottom","Left"],en=["Webkit","O","Moz","ms"];function tn(e,t){if(t in e)return t;var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=en.length;while(i--)if(t=en[i]+n,t in e)return t;return r}function nn(e,t){return e=t||e,"none"===x.css(e,"display")||!x.contains(e.ownerDocument,e)}function rn(e,t){var n,r,i,o=[],a=0,s=e.length;for(;s>a;a++)r=e[a],r.style&&(o[a]=x._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&nn(r)&&(o[a]=x._data(r,"olddisplay",ln(r.nodeName)))):o[a]||(i=nn(r),(n&&"none"!==n||!i)&&x._data(r,"olddisplay",i?n:x.css(r,"display"))));for(a=0;s>a;a++)r=e[a],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}x.fn.extend({css:function(e,n){return x.access(this,function(e,n,r){var i,o,a={},s=0;if(x.isArray(n)){for(o=Rt(e),i=n.length;i>s;s++)a[n[s]]=x.css(e,n[s],!1,o);return a}return r!==t?x.style(e,n,r):x.css(e,n)},e,n,arguments.length>1)},show:function(){return rn(this,!0)},hide:function(){return rn(this)},toggle:function(e){var t="boolean"==typeof e;return this.each(function(){(t?e:nn(this))?x(this).show():x(this).hide()})}}),x.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Wt(e,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":x.support.cssFloat?"cssFloat":"styleFloat"},style:function(e,n,r,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,a,s,l=x.camelCase(n),u=e.style;if(n=x.cssProps[l]||(x.cssProps[l]=tn(u,l)),s=x.cssHooks[n]||x.cssHooks[l],r===t)return s&&"get"in s&&(o=s.get(e,!1,i))!==t?o:u[n];if(a=typeof r,"string"===a&&(o=Jt.exec(r))&&(r=(o[1]+1)*o[2]+parseFloat(x.css(e,n)),a="number"),!(null==r||"number"===a&&isNaN(r)||("number"!==a||x.cssNumber[l]||(r+="px"),x.support.clearCloneStyle||""!==r||0!==n.indexOf("background")||(u[n]="inherit"),s&&"set"in s&&(r=s.set(e,r,i))===t)))try{u[n]=r}catch(c){}}},css:function(e,n,r,i){var o,a,s,l=x.camelCase(n);return n=x.cssProps[l]||(x.cssProps[l]=tn(e.style,l)),s=x.cssHooks[n]||x.cssHooks[l],s&&"get"in s&&(a=s.get(e,!0,r)),a===t&&(a=Wt(e,n,i)),"normal"===a&&n in Kt&&(a=Kt[n]),""===r||r?(o=parseFloat(a),r===!0||x.isNumeric(o)?o||0:a):a}}),e.getComputedStyle?(Rt=function(t){return e.getComputedStyle(t,null)},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s.getPropertyValue(n)||s[n]:t,u=e.style;return s&&(""!==l||x.contains(e.ownerDocument,e)||(l=x.style(e,n)),Yt.test(l)&&Ut.test(n)&&(i=u.width,o=u.minWidth,a=u.maxWidth,u.minWidth=u.maxWidth=u.width=l,l=s.width,u.width=i,u.minWidth=o,u.maxWidth=a)),l}):a.documentElement.currentStyle&&(Rt=function(e){return e.currentStyle},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s[n]:t,u=e.style;return null==l&&u&&u[n]&&(l=u[n]),Yt.test(l)&&!zt.test(n)&&(i=u.left,o=e.runtimeStyle,a=o&&o.left,a&&(o.left=e.currentStyle.left),u.left="fontSize"===n?"1em":l,l=u.pixelLeft+"px",u.left=i,a&&(o.left=a)),""===l?"auto":l});function on(e,t,n){var r=Vt.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function an(e,t,n,r,i){var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;for(;4>o;o+=2)"margin"===n&&(a+=x.css(e,n+Zt[o],!0,i)),r?("content"===n&&(a-=x.css(e,"padding"+Zt[o],!0,i)),"margin"!==n&&(a-=x.css(e,"border"+Zt[o]+"Width",!0,i))):(a+=x.css(e,"padding"+Zt[o],!0,i),"padding"!==n&&(a+=x.css(e,"border"+Zt[o]+"Width",!0,i)));return a}function sn(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=Rt(e),a=x.support.boxSizing&&"border-box"===x.css(e,"boxSizing",!1,o);if(0>=i||null==i){if(i=Wt(e,t,o),(0>i||null==i)&&(i=e.style[t]),Yt.test(i))return i;r=a&&(x.support.boxSizingReliable||i===e.style[t]),i=parseFloat(i)||0}return i+an(e,t,n||(a?"border":"content"),r,o)+"px"}function ln(e){var t=a,n=Gt[e];return n||(n=un(e,t),"none"!==n&&n||(Pt=(Pt||x("<iframe frameborder='0' width='0' height='0'/>").css("cssText","display:block !important")).appendTo(t.documentElement),t=(Pt[0].contentWindow||Pt[0].contentDocument).document,t.write("<!doctype html><html><body>"),t.close(),n=un(e,t),Pt.detach()),Gt[e]=n),n}function un(e,t){var n=x(t.createElement(e)).appendTo(t.body),r=x.css(n[0],"display");return n.remove(),r}x.each(["height","width"],function(e,n){x.cssHooks[n]={get:function(e,r,i){return r?0===e.offsetWidth&&Xt.test(x.css(e,"display"))?x.swap(e,Qt,function(){return sn(e,n,i)}):sn(e,n,i):t},set:function(e,t,r){var i=r&&Rt(e);return on(e,t,r?an(e,n,r,x.support.boxSizing&&"border-box"===x.css(e,"boxSizing",!1,i),i):0)}}}),x.support.opacity||(x.cssHooks.opacity={get:function(e,t){return It.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=x.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=r&&r.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===x.trim(o.replace($t,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||r&&!r.filter)||(n.filter=$t.test(o)?o.replace($t,i):o+" "+i)}}),x(function(){x.support.reliableMarginRight||(x.cssHooks.marginRight={get:function(e,n){return n?x.swap(e,{display:"inline-block"},Wt,[e,"marginRight"]):t}}),!x.support.pixelPosition&&x.fn.position&&x.each(["top","left"],function(e,n){x.cssHooks[n]={get:function(e,r){return r?(r=Wt(e,n),Yt.test(r)?x(e).position()[n]+"px":r):t}}})}),x.expr&&x.expr.filters&&(x.expr.filters.hidden=function(e){return 0>=e.offsetWidth&&0>=e.offsetHeight||!x.support.reliableHiddenOffsets&&"none"===(e.style&&e.style.display||x.css(e,"display"))},x.expr.filters.visible=function(e){return!x.expr.filters.hidden(e)}),x.each({margin:"",padding:"",border:"Width"},function(e,t){x.cssHooks[e+t]={expand:function(n){var r=0,i={},o="string"==typeof n?n.split(" "):[n];for(;4>r;r++)i[e+Zt[r]+t]=o[r]||o[r-2]||o[0];return i}},Ut.test(e)||(x.cssHooks[e+t].set=on)});var cn=/%20/g,pn=/\[\]$/,fn=/\r?\n/g,dn=/^(?:submit|button|image|reset|file)$/i,hn=/^(?:input|select|textarea|keygen)/i;x.fn.extend({serialize:function(){return x.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=x.prop(this,"elements");return e?x.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!x(this).is(":disabled")&&hn.test(this.nodeName)&&!dn.test(e)&&(this.checked||!Ct.test(e))}).map(function(e,t){var n=x(this).val();return null==n?null:x.isArray(n)?x.map(n,function(e){return{name:t.name,value:e.replace(fn,"\r\n")}}):{name:t.name,value:n.replace(fn,"\r\n")}}).get()}}),x.param=function(e,n){var r,i=[],o=function(e,t){t=x.isFunction(t)?t():null==t?"":t,i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(n===t&&(n=x.ajaxSettings&&x.ajaxSettings.traditional),x.isArray(e)||e.jquery&&!x.isPlainObject(e))x.each(e,function(){o(this.name,this.value)});else for(r in e)gn(r,e[r],n,o);return i.join("&").replace(cn,"+")};function gn(e,t,n,r){var i;if(x.isArray(t))x.each(t,function(t,i){n||pn.test(e)?r(e,i):gn(e+"["+("object"==typeof i?t:"")+"]",i,n,r)});else if(n||"object"!==x.type(t))r(e,t);else for(i in t)gn(e+"["+i+"]",t[i],n,r)}x.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(e,t){x.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),x.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}});var mn,yn,vn=x.now(),bn=/\?/,xn=/#.*$/,wn=/([?&])_=[^&]*/,Tn=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Cn=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Nn=/^(?:GET|HEAD)$/,kn=/^\/\//,En=/^([\w.+-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,Sn=x.fn.load,An={},jn={},Dn="*/".concat("*");try{yn=o.href}catch(Ln){yn=a.createElement("a"),yn.href="",yn=yn.href}mn=En.exec(yn.toLowerCase())||[];function Hn(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(T)||[];if(x.isFunction(n))while(r=o[i++])"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function qn(e,n,r,i){var o={},a=e===jn;function s(l){var u;return o[l]=!0,x.each(e[l]||[],function(e,l){var c=l(n,r,i);return"string"!=typeof c||a||o[c]?a?!(u=c):t:(n.dataTypes.unshift(c),s(c),!1)}),u}return s(n.dataTypes[0])||!o["*"]&&s("*")}function _n(e,n){var r,i,o=x.ajaxSettings.flatOptions||{};for(i in n)n[i]!==t&&((o[i]?e:r||(r={}))[i]=n[i]);return r&&x.extend(!0,e,r),e}x.fn.load=function(e,n,r){if("string"!=typeof e&&Sn)return Sn.apply(this,arguments);var i,o,a,s=this,l=e.indexOf(" ");return l>=0&&(i=e.slice(l,e.length),e=e.slice(0,l)),x.isFunction(n)?(r=n,n=t):n&&"object"==typeof n&&(a="POST"),s.length>0&&x.ajax({url:e,type:a,dataType:"html",data:n}).done(function(e){o=arguments,s.html(i?x("<div>").append(x.parseHTML(e)).find(i):e)}).complete(r&&function(e,t){s.each(r,o||[e.responseText,t,e])}),this},x.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){x.fn[t]=function(e){return this.on(t,e)}}),x.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:yn,type:"GET",isLocal:Cn.test(mn[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Dn,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":x.parseJSON,"text xml":x.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?_n(_n(e,x.ajaxSettings),t):_n(x.ajaxSettings,e)},ajaxPrefilter:Hn(An),ajaxTransport:Hn(jn),ajax:function(e,n){"object"==typeof e&&(n=e,e=t),n=n||{};var r,i,o,a,s,l,u,c,p=x.ajaxSetup({},n),f=p.context||p,d=p.context&&(f.nodeType||f.jquery)?x(f):x.event,h=x.Deferred(),g=x.Callbacks("once memory"),m=p.statusCode||{},y={},v={},b=0,w="canceled",C={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!c){c={};while(t=Tn.exec(a))c[t[1].toLowerCase()]=t[2]}t=c[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return b||(e=v[n]=v[n]||e,y[e]=t),this},overrideMimeType:function(e){return b||(p.mimeType=e),this},statusCode:function(e){var t;if(e)if(2>b)for(t in e)m[t]=[m[t],e[t]];else C.always(e[C.status]);return this},abort:function(e){var t=e||w;return u&&u.abort(t),k(0,t),this}};if(h.promise(C).complete=g.add,C.success=C.done,C.error=C.fail,p.url=((e||p.url||yn)+"").replace(xn,"").replace(kn,mn[1]+"//"),p.type=n.method||n.type||p.method||p.type,p.dataTypes=x.trim(p.dataType||"*").toLowerCase().match(T)||[""],null==p.crossDomain&&(r=En.exec(p.url.toLowerCase()),p.crossDomain=!(!r||r[1]===mn[1]&&r[2]===mn[2]&&(r[3]||("http:"===r[1]?"80":"443"))===(mn[3]||("http:"===mn[1]?"80":"443")))),p.data&&p.processData&&"string"!=typeof p.data&&(p.data=x.param(p.data,p.traditional)),qn(An,p,n,C),2===b)return C;l=p.global,l&&0===x.active++&&x.event.trigger("ajaxStart"),p.type=p.type.toUpperCase(),p.hasContent=!Nn.test(p.type),o=p.url,p.hasContent||(p.data&&(o=p.url+=(bn.test(o)?"&":"?")+p.data,delete p.data),p.cache===!1&&(p.url=wn.test(o)?o.replace(wn,"$1_="+vn++):o+(bn.test(o)?"&":"?")+"_="+vn++)),p.ifModified&&(x.lastModified[o]&&C.setRequestHeader("If-Modified-Since",x.lastModified[o]),x.etag[o]&&C.setRequestHeader("If-None-Match",x.etag[o])),(p.data&&p.hasContent&&p.contentType!==!1||n.contentType)&&C.setRequestHeader("Content-Type",p.contentType),C.setRequestHeader("Accept",p.dataTypes[0]&&p.accepts[p.dataTypes[0]]?p.accepts[p.dataTypes[0]]+("*"!==p.dataTypes[0]?", "+Dn+"; q=0.01":""):p.accepts["*"]);for(i in p.headers)C.setRequestHeader(i,p.headers[i]);if(p.beforeSend&&(p.beforeSend.call(f,C,p)===!1||2===b))return C.abort();w="abort";for(i in{success:1,error:1,complete:1})C[i](p[i]);if(u=qn(jn,p,n,C)){C.readyState=1,l&&d.trigger("ajaxSend",[C,p]),p.async&&p.timeout>0&&(s=setTimeout(function(){C.abort("timeout")},p.timeout));try{b=1,u.send(y,k)}catch(N){if(!(2>b))throw N;k(-1,N)}}else k(-1,"No Transport");function k(e,n,r,i){var c,y,v,w,T,N=n;2!==b&&(b=2,s&&clearTimeout(s),u=t,a=i||"",C.readyState=e>0?4:0,c=e>=200&&300>e||304===e,r&&(w=Mn(p,C,r)),w=On(p,w,C,c),c?(p.ifModified&&(T=C.getResponseHeader("Last-Modified"),T&&(x.lastModified[o]=T),T=C.getResponseHeader("etag"),T&&(x.etag[o]=T)),204===e||"HEAD"===p.type?N="nocontent":304===e?N="notmodified":(N=w.state,y=w.data,v=w.error,c=!v)):(v=N,(e||!N)&&(N="error",0>e&&(e=0))),C.status=e,C.statusText=(n||N)+"",c?h.resolveWith(f,[y,N,C]):h.rejectWith(f,[C,N,v]),C.statusCode(m),m=t,l&&d.trigger(c?"ajaxSuccess":"ajaxError",[C,p,c?y:v]),g.fireWith(f,[C,N]),l&&(d.trigger("ajaxComplete",[C,p]),--x.active||x.event.trigger("ajaxStop")))}return C},getJSON:function(e,t,n){return x.get(e,t,n,"json")},getScript:function(e,n){return x.get(e,t,n,"script")}}),x.each(["get","post"],function(e,n){x[n]=function(e,r,i,o){return x.isFunction(r)&&(o=o||i,i=r,r=t),x.ajax({url:e,type:n,dataType:o,data:r,success:i})}});function Mn(e,n,r){var i,o,a,s,l=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),o===t&&(o=e.mimeType||n.getResponseHeader("Content-Type"));if(o)for(s in l)if(l[s]&&l[s].test(o)){u.unshift(s);break}if(u[0]in r)a=u[0];else{for(s in r){if(!u[0]||e.converters[s+" "+u[0]]){a=s;break}i||(i=s)}a=a||i}return a?(a!==u[0]&&u.unshift(a),r[a]):t}function On(e,t,n,r){var i,o,a,s,l,u={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)u[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!l&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=o,o=c.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(a=u[l+" "+o]||u["* "+o],!a)for(i in u)if(s=i.split(" "),s[1]===o&&(a=u[l+" "+s[0]]||u["* "+s[0]])){a===!0?a=u[i]:u[i]!==!0&&(o=s[0],c.unshift(s[1]));break}if(a!==!0)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(p){return{state:"parsererror",error:a?p:"No conversion from "+l+" to "+o}}}return{state:"success",data:t}}x.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return x.globalEval(e),e}}}),x.ajaxPrefilter("script",function(e){e.cache===t&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),x.ajaxTransport("script",function(e){if(e.crossDomain){var n,r=a.head||x("head")[0]||a.documentElement;return{send:function(t,i){n=a.createElement("script"),n.async=!0,e.scriptCharset&&(n.charset=e.scriptCharset),n.src=e.url,n.onload=n.onreadystatechange=function(e,t){(t||!n.readyState||/loaded|complete/.test(n.readyState))&&(n.onload=n.onreadystatechange=null,n.parentNode&&n.parentNode.removeChild(n),n=null,t||i(200,"success"))},r.insertBefore(n,r.firstChild)},abort:function(){n&&n.onload(t,!0)}}}});var Fn=[],Bn=/(=)\?(?=&|$)|\?\?/;x.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Fn.pop()||x.expando+"_"+vn++;return this[e]=!0,e}}),x.ajaxPrefilter("json jsonp",function(n,r,i){var o,a,s,l=n.jsonp!==!1&&(Bn.test(n.url)?"url":"string"==typeof n.data&&!(n.contentType||"").indexOf("application/x-www-form-urlencoded")&&Bn.test(n.data)&&"data");return l||"jsonp"===n.dataTypes[0]?(o=n.jsonpCallback=x.isFunction(n.jsonpCallback)?n.jsonpCallback():n.jsonpCallback,l?n[l]=n[l].replace(Bn,"$1"+o):n.jsonp!==!1&&(n.url+=(bn.test(n.url)?"&":"?")+n.jsonp+"="+o),n.converters["script json"]=function(){return s||x.error(o+" was not called"),s[0]},n.dataTypes[0]="json",a=e[o],e[o]=function(){s=arguments},i.always(function(){e[o]=a,n[o]&&(n.jsonpCallback=r.jsonpCallback,Fn.push(o)),s&&x.isFunction(a)&&a(s[0]),s=a=t}),"script"):t});var Pn,Rn,Wn=0,$n=e.ActiveXObject&&function(){var e;for(e in Pn)Pn[e](t,!0)};function In(){try{return new e.XMLHttpRequest}catch(t){}}function zn(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}x.ajaxSettings.xhr=e.ActiveXObject?function(){return!this.isLocal&&In()||zn()}:In,Rn=x.ajaxSettings.xhr(),x.support.cors=!!Rn&&"withCredentials"in Rn,Rn=x.support.ajax=!!Rn,Rn&&x.ajaxTransport(function(n){if(!n.crossDomain||x.support.cors){var r;return{send:function(i,o){var a,s,l=n.xhr();if(n.username?l.open(n.type,n.url,n.async,n.username,n.password):l.open(n.type,n.url,n.async),n.xhrFields)for(s in n.xhrFields)l[s]=n.xhrFields[s];n.mimeType&&l.overrideMimeType&&l.overrideMimeType(n.mimeType),n.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");try{for(s in i)l.setRequestHeader(s,i[s])}catch(u){}l.send(n.hasContent&&n.data||null),r=function(e,i){var s,u,c,p;try{if(r&&(i||4===l.readyState))if(r=t,a&&(l.onreadystatechange=x.noop,$n&&delete Pn[a]),i)4!==l.readyState&&l.abort();else{p={},s=l.status,u=l.getAllResponseHeaders(),"string"==typeof l.responseText&&(p.text=l.responseText);try{c=l.statusText}catch(f){c=""}s||!n.isLocal||n.crossDomain?1223===s&&(s=204):s=p.text?200:404}}catch(d){i||o(-1,d)}p&&o(s,c,p,u)},n.async?4===l.readyState?setTimeout(r):(a=++Wn,$n&&(Pn||(Pn={},x(e).unload($n)),Pn[a]=r),l.onreadystatechange=r):r()},abort:function(){r&&r(t,!0)}}}});var Xn,Un,Vn=/^(?:toggle|show|hide)$/,Yn=RegExp("^(?:([+-])=|)("+w+")([a-z%]*)$","i"),Jn=/queueHooks$/,Gn=[nr],Qn={"*":[function(e,t){var n=this.createTween(e,t),r=n.cur(),i=Yn.exec(t),o=i&&i[3]||(x.cssNumber[e]?"":"px"),a=(x.cssNumber[e]||"px"!==o&&+r)&&Yn.exec(x.css(n.elem,e)),s=1,l=20;if(a&&a[3]!==o){o=o||a[3],i=i||[],a=+r||1;do s=s||".5",a/=s,x.style(n.elem,e,a+o);while(s!==(s=n.cur()/r)&&1!==s&&--l)}return i&&(a=n.start=+a||+r||0,n.unit=o,n.end=i[1]?a+(i[1]+1)*i[2]:+i[2]),n}]};function Kn(){return setTimeout(function(){Xn=t}),Xn=x.now()}function Zn(e,t,n){var r,i=(Qn[t]||[]).concat(Qn["*"]),o=0,a=i.length;for(;a>o;o++)if(r=i[o].call(n,t,e))return r}function er(e,t,n){var r,i,o=0,a=Gn.length,s=x.Deferred().always(function(){delete l.elem}),l=function(){if(i)return!1;var t=Xn||Kn(),n=Math.max(0,u.startTime+u.duration-t),r=n/u.duration||0,o=1-r,a=0,l=u.tweens.length;for(;l>a;a++)u.tweens[a].run(o);return s.notifyWith(e,[u,o,n]),1>o&&l?n:(s.resolveWith(e,[u]),!1)},u=s.promise({elem:e,props:x.extend({},t),opts:x.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:Xn||Kn(),duration:n.duration,tweens:[],createTween:function(t,n){var r=x.Tween(e,u.opts,t,n,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(r),r},stop:function(t){var n=0,r=t?u.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)u.tweens[n].run(1);return t?s.resolveWith(e,[u,t]):s.rejectWith(e,[u,t]),this}}),c=u.props;for(tr(c,u.opts.specialEasing);a>o;o++)if(r=Gn[o].call(u,e,c,u.opts))return r;return x.map(c,Zn,u),x.isFunction(u.opts.start)&&u.opts.start.call(e,u),x.fx.timer(x.extend(l,{elem:e,anim:u,queue:u.opts.queue})),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always)}function tr(e,t){var n,r,i,o,a;for(n in e)if(r=x.camelCase(n),i=t[r],o=e[n],x.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),a=x.cssHooks[r],a&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}x.Animation=x.extend(er,{tweener:function(e,t){x.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");var n,r=0,i=e.length;for(;i>r;r++)n=e[r],Qn[n]=Qn[n]||[],Qn[n].unshift(t)},prefilter:function(e,t){t?Gn.unshift(e):Gn.push(e)}});function nr(e,t,n){var r,i,o,a,s,l,u=this,c={},p=e.style,f=e.nodeType&&nn(e),d=x._data(e,"fxshow");n.queue||(s=x._queueHooks(e,"fx"),null==s.unqueued&&(s.unqueued=0,l=s.empty.fire,s.empty.fire=function(){s.unqueued||l()}),s.unqueued++,u.always(function(){u.always(function(){s.unqueued--,x.queue(e,"fx").length||s.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],"inline"===x.css(e,"display")&&"none"===x.css(e,"float")&&(x.support.inlineBlockNeedsLayout&&"inline"!==ln(e.nodeName)?p.zoom=1:p.display="inline-block")),n.overflow&&(p.overflow="hidden",x.support.shrinkWrapBlocks||u.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}));for(r in t)if(i=t[r],Vn.exec(i)){if(delete t[r],o=o||"toggle"===i,i===(f?"hide":"show"))continue;c[r]=d&&d[r]||x.style(e,r)}if(!x.isEmptyObject(c)){d?"hidden"in d&&(f=d.hidden):d=x._data(e,"fxshow",{}),o&&(d.hidden=!f),f?x(e).show():u.done(function(){x(e).hide()}),u.done(function(){var t;x._removeData(e,"fxshow");for(t in c)x.style(e,t,c[t])});for(r in c)a=Zn(f?d[r]:0,r,u),r in d||(d[r]=a.start,f&&(a.end=a.start,a.start="width"===r||"height"===r?1:0))}}function rr(e,t,n,r,i){return new rr.prototype.init(e,t,n,r,i)}x.Tween=rr,rr.prototype={constructor:rr,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(x.cssNumber[n]?"":"px")},cur:function(){var e=rr.propHooks[this.prop];return e&&e.get?e.get(this):rr.propHooks._default.get(this)},run:function(e){var t,n=rr.propHooks[this.prop];return this.pos=t=this.options.duration?x.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):rr.propHooks._default.set(this),this}},rr.prototype.init.prototype=rr.prototype,rr.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=x.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){x.fx.step[e.prop]?x.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[x.cssProps[e.prop]]||x.cssHooks[e.prop])?x.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},rr.propHooks.scrollTop=rr.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},x.each(["toggle","show","hide"],function(e,t){var n=x.fn[t];x.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(ir(t,!0),e,r,i)}}),x.fn.extend({fadeTo:function(e,t,n,r){return this.filter(nn).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=x.isEmptyObject(e),o=x.speed(t,n,r),a=function(){var t=er(this,x.extend({},e),o);(i||x._data(this,"finish"))&&t.stop(!0)};return a.finish=a,i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,n,r){var i=function(e){var t=e.stop;delete e.stop,t(r)};return"string"!=typeof e&&(r=n,n=e,e=t),n&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,n=null!=e&&e+"queueHooks",o=x.timers,a=x._data(this);if(n)a[n]&&a[n].stop&&i(a[n]);else for(n in a)a[n]&&a[n].stop&&Jn.test(n)&&i(a[n]);for(n=o.length;n--;)o[n].elem!==this||null!=e&&o[n].queue!==e||(o[n].anim.stop(r),t=!1,o.splice(n,1));(t||!r)&&x.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=x._data(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=x.timers,a=r?r.length:0;for(n.finish=!0,x.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}});function ir(e,t){var n,r={height:e},i=0;for(t=t?1:0;4>i;i+=2-t)n=Zt[i],r["margin"+n]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}x.each({slideDown:ir("show"),slideUp:ir("hide"),slideToggle:ir("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){x.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),x.speed=function(e,t,n){var r=e&&"object"==typeof e?x.extend({},e):{complete:n||!n&&t||x.isFunction(e)&&e,duration:e,easing:n&&t||t&&!x.isFunction(t)&&t};return r.duration=x.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in x.fx.speeds?x.fx.speeds[r.duration]:x.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){x.isFunction(r.old)&&r.old.call(this),r.queue&&x.dequeue(this,r.queue)},r},x.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},x.timers=[],x.fx=rr.prototype.init,x.fx.tick=function(){var e,n=x.timers,r=0;for(Xn=x.now();n.length>r;r++)e=n[r],e()||n[r]!==e||n.splice(r--,1);n.length||x.fx.stop(),Xn=t},x.fx.timer=function(e){e()&&x.timers.push(e)&&x.fx.start()},x.fx.interval=13,x.fx.start=function(){Un||(Un=setInterval(x.fx.tick,x.fx.interval))},x.fx.stop=function(){clearInterval(Un),Un=null},x.fx.speeds={slow:600,fast:200,_default:400},x.fx.step={},x.expr&&x.expr.filters&&(x.expr.filters.animated=function(e){return x.grep(x.timers,function(t){return e===t.elem}).length}),x.fn.offset=function(e){if(arguments.length)return e===t?this:this.each(function(t){x.offset.setOffset(this,e,t)});var n,r,o={top:0,left:0},a=this[0],s=a&&a.ownerDocument;if(s)return n=s.documentElement,x.contains(n,a)?(typeof a.getBoundingClientRect!==i&&(o=a.getBoundingClientRect()),r=or(s),{top:o.top+(r.pageYOffset||n.scrollTop)-(n.clientTop||0),left:o.left+(r.pageXOffset||n.scrollLeft)-(n.clientLeft||0)}):o},x.offset={setOffset:function(e,t,n){var r=x.css(e,"position");"static"===r&&(e.style.position="relative");var i=x(e),o=i.offset(),a=x.css(e,"top"),s=x.css(e,"left"),l=("absolute"===r||"fixed"===r)&&x.inArray("auto",[a,s])>-1,u={},c={},p,f;l?(c=i.position(),p=c.top,f=c.left):(p=parseFloat(a)||0,f=parseFloat(s)||0),x.isFunction(t)&&(t=t.call(e,n,o)),null!=t.top&&(u.top=t.top-o.top+p),null!=t.left&&(u.left=t.left-o.left+f),"using"in t?t.using.call(e,u):i.css(u)}},x.fn.extend({position:function(){if(this[0]){var e,t,n={top:0,left:0},r=this[0];return"fixed"===x.css(r,"position")?t=r.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),x.nodeName(e[0],"html")||(n=e.offset()),n.top+=x.css(e[0],"borderTopWidth",!0),n.left+=x.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-x.css(r,"marginTop",!0),left:t.left-n.left-x.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent||s;while(e&&!x.nodeName(e,"html")&&"static"===x.css(e,"position"))e=e.offsetParent;return e||s})}}),x.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,n){var r=/Y/.test(n);x.fn[e]=function(i){return x.access(this,function(e,i,o){var a=or(e);return o===t?a?n in a?a[n]:a.document.documentElement[i]:e[i]:(a?a.scrollTo(r?x(a).scrollLeft():o,r?o:x(a).scrollTop()):e[i]=o,t)},e,i,arguments.length,null)}});function or(e){return x.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}x.each({Height:"height",Width:"width"},function(e,n){x.each({padding:"inner"+e,content:n,"":"outer"+e},function(r,i){x.fn[i]=function(i,o){var a=arguments.length&&(r||"boolean"!=typeof i),s=r||(i===!0||o===!0?"margin":"border");return x.access(this,function(n,r,i){var o;return x.isWindow(n)?n.document.documentElement["client"+e]:9===n.nodeType?(o=n.documentElement,Math.max(n.body["scroll"+e],o["scroll"+e],n.body["offset"+e],o["offset"+e],o["client"+e])):i===t?x.css(n,r,s):x.style(n,r,i,s)},n,a?i:t,a,null)}})}),x.fn.size=function(){return this.length},x.fn.andSelf=x.fn.addBack,"object"==typeof module&&module&&"object"==typeof module.exports?module.exports=x:(e.jQuery=e.$=x,"function"==typeof define&&define.amd&&define("jquery",[],function(){return x}))})(window);
|
skin/frontend/base/default/js/autoship/jquery/noconflict.js
ADDED
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* Subscribe Pro - Subscriptions Management Extension
|
3 |
+
*
|
4 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
5 |
+
*
|
6 |
+
* @category SFC
|
7 |
+
* @package SFC_Autoship
|
8 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
9 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
10 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
11 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
12 |
+
* @link http://www.subscribepro.com/
|
13 |
+
*
|
14 |
+
*/
|
15 |
+
|
16 |
+
$j = jQuery.noConflict();
|
17 |
+
jQuery.fn.highlight = function() {
|
18 |
+
$j(this).each(function() {
|
19 |
+
var el = $j(this);
|
20 |
+
el.before("<div style='position:absolute;'></div>")
|
21 |
+
el.prev()
|
22 |
+
.width(el.width())
|
23 |
+
.height(el.height())
|
24 |
+
.css({
|
25 |
+
"background-color": "#F96D3B",
|
26 |
+
"opacity": ".9"
|
27 |
+
})
|
28 |
+
.fadeOut(700, function(){$j(this).remove()});
|
29 |
+
});
|
30 |
+
return $j(this);
|
31 |
+
}
|
skin/frontend/base/default/js/autoship/jquery/ui/jquery.ui.core.min.js
ADDED
@@ -0,0 +1,4 @@
|
|
|
|
|
|
|
|
|
1 |
+
/*! jQuery UI - v1.10.3 - 2013-05-03
|
2 |
+
* http://jqueryui.com
|
3 |
+
* Copyright 2013 jQuery Foundation and other contributors; Licensed MIT */
|
4 |
+
(function(e,t){function i(t,i){var a,n,r,o=t.nodeName.toLowerCase();return"area"===o?(a=t.parentNode,n=a.name,t.href&&n&&"map"===a.nodeName.toLowerCase()?(r=e("img[usemap=#"+n+"]")[0],!!r&&s(r)):!1):(/input|select|textarea|button|object/.test(o)?!t.disabled:"a"===o?t.href||i:i)&&s(t)}function s(t){return e.expr.filters.visible(t)&&!e(t).parents().addBack().filter(function(){return"hidden"===e.css(this,"visibility")}).length}var a=0,n=/^ui-id-\d+$/;e.ui=e.ui||{},e.extend(e.ui,{version:"1.10.3",keyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}}),e.fn.extend({focus:function(t){return function(i,s){return"number"==typeof i?this.each(function(){var t=this;setTimeout(function(){e(t).focus(),s&&s.call(t)},i)}):t.apply(this,arguments)}}(e.fn.focus),scrollParent:function(){var t;return t=e.ui.ie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(e.css(this,"position"))&&/(auto|scroll)/.test(e.css(this,"overflow")+e.css(this,"overflow-y")+e.css(this,"overflow-x"))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(e.css(this,"overflow")+e.css(this,"overflow-y")+e.css(this,"overflow-x"))}).eq(0),/fixed/.test(this.css("position"))||!t.length?e(document):t},zIndex:function(i){if(i!==t)return this.css("zIndex",i);if(this.length)for(var s,a,n=e(this[0]);n.length&&n[0]!==document;){if(s=n.css("position"),("absolute"===s||"relative"===s||"fixed"===s)&&(a=parseInt(n.css("zIndex"),10),!isNaN(a)&&0!==a))return a;n=n.parent()}return 0},uniqueId:function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++a)})},removeUniqueId:function(){return this.each(function(){n.test(this.id)&&e(this).removeAttr("id")})}}),e.extend(e.expr[":"],{data:e.expr.createPseudo?e.expr.createPseudo(function(t){return function(i){return!!e.data(i,t)}}):function(t,i,s){return!!e.data(t,s[3])},focusable:function(t){return i(t,!isNaN(e.attr(t,"tabindex")))},tabbable:function(t){var s=e.attr(t,"tabindex"),a=isNaN(s);return(a||s>=0)&&i(t,!a)}}),e("<a>").outerWidth(1).jquery||e.each(["Width","Height"],function(i,s){function a(t,i,s,a){return e.each(n,function(){i-=parseFloat(e.css(t,"padding"+this))||0,s&&(i-=parseFloat(e.css(t,"border"+this+"Width"))||0),a&&(i-=parseFloat(e.css(t,"margin"+this))||0)}),i}var n="Width"===s?["Left","Right"]:["Top","Bottom"],r=s.toLowerCase(),o={innerWidth:e.fn.innerWidth,innerHeight:e.fn.innerHeight,outerWidth:e.fn.outerWidth,outerHeight:e.fn.outerHeight};e.fn["inner"+s]=function(i){return i===t?o["inner"+s].call(this):this.each(function(){e(this).css(r,a(this,i)+"px")})},e.fn["outer"+s]=function(t,i){return"number"!=typeof t?o["outer"+s].call(this,t):this.each(function(){e(this).css(r,a(this,t,!0,i)+"px")})}}),e.fn.addBack||(e.fn.addBack=function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}),e("<a>").data("a-b","a").removeData("a-b").data("a-b")&&(e.fn.removeData=function(t){return function(i){return arguments.length?t.call(this,e.camelCase(i)):t.call(this)}}(e.fn.removeData)),e.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),e.support.selectstart="onselectstart"in document.createElement("div"),e.fn.extend({disableSelection:function(){return this.bind((e.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(e){e.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")}}),e.extend(e.ui,{plugin:{add:function(t,i,s){var a,n=e.ui[t].prototype;for(a in s)n.plugins[a]=n.plugins[a]||[],n.plugins[a].push([i,s[a]])},call:function(e,t,i){var s,a=e.plugins[t];if(a&&e.element[0].parentNode&&11!==e.element[0].parentNode.nodeType)for(s=0;a.length>s;s++)e.options[a[s][0]]&&a[s][1].apply(e.element,i)}},hasScroll:function(t,i){if("hidden"===e(t).css("overflow"))return!1;var s=i&&"left"===i?"scrollLeft":"scrollTop",a=!1;return t[s]>0?!0:(t[s]=1,a=t[s]>0,t[s]=0,a)}})})(jQuery);
|
skin/frontend/base/default/js/autoship/jquery/ui/jquery.ui.datepicker.min.js
ADDED
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*! jQuery UI - v1.10.3 - 2013-05-03
|
2 |
+
* http://jqueryui.com
|
3 |
+
* Copyright 2013 jQuery Foundation and other contributors; Licensed MIT */
|
4 |
+
(function(t,e){function i(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},t.extend(this._defaults,this.regional[""]),this.dpDiv=s(t("<div id='"+this._mainDivId+"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>"))}function s(e){var i="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return e.delegate(i,"mouseout",function(){t(this).removeClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).removeClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).removeClass("ui-datepicker-next-hover")}).delegate(i,"mouseover",function(){t.datepicker._isDisabledDatepicker(a.inline?e.parent()[0]:a.input[0])||(t(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),t(this).addClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).addClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).addClass("ui-datepicker-next-hover"))})}function n(e,i){t.extend(e,i);for(var s in i)null==i[s]&&(e[s]=i[s]);return e}t.extend(t.ui,{datepicker:{version:"1.10.3"}});var a,r="datepicker";t.extend(i.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(t){return n(this._defaults,t||{}),this},_attachDatepicker:function(e,i){var s,n,a;s=e.nodeName.toLowerCase(),n="div"===s||"span"===s,e.id||(this.uuid+=1,e.id="dp"+this.uuid),a=this._newInst(t(e),n),a.settings=t.extend({},i||{}),"input"===s?this._connectDatepicker(e,a):n&&this._inlineDatepicker(e,a)},_newInst:function(e,i){var n=e[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1");return{id:n,input:e,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:i,dpDiv:i?s(t("<div class='"+this._inlineClass+" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>")):this.dpDiv}},_connectDatepicker:function(e,i){var s=t(e);i.append=t([]),i.trigger=t([]),s.hasClass(this.markerClassName)||(this._attachments(s,i),s.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress).keyup(this._doKeyUp),this._autoSize(i),t.data(e,r,i),i.settings.disabled&&this._disableDatepicker(e))},_attachments:function(e,i){var s,n,a,r=this._get(i,"appendText"),o=this._get(i,"isRTL");i.append&&i.append.remove(),r&&(i.append=t("<span class='"+this._appendClass+"'>"+r+"</span>"),e[o?"before":"after"](i.append)),e.unbind("focus",this._showDatepicker),i.trigger&&i.trigger.remove(),s=this._get(i,"showOn"),("focus"===s||"both"===s)&&e.focus(this._showDatepicker),("button"===s||"both"===s)&&(n=this._get(i,"buttonText"),a=this._get(i,"buttonImage"),i.trigger=t(this._get(i,"buttonImageOnly")?t("<img/>").addClass(this._triggerClass).attr({src:a,alt:n,title:n}):t("<button type='button'></button>").addClass(this._triggerClass).html(a?t("<img/>").attr({src:a,alt:n,title:n}):n)),e[o?"before":"after"](i.trigger),i.trigger.click(function(){return t.datepicker._datepickerShowing&&t.datepicker._lastInput===e[0]?t.datepicker._hideDatepicker():t.datepicker._datepickerShowing&&t.datepicker._lastInput!==e[0]?(t.datepicker._hideDatepicker(),t.datepicker._showDatepicker(e[0])):t.datepicker._showDatepicker(e[0]),!1}))},_autoSize:function(t){if(this._get(t,"autoSize")&&!t.inline){var e,i,s,n,a=new Date(2009,11,20),r=this._get(t,"dateFormat");r.match(/[DM]/)&&(e=function(t){for(i=0,s=0,n=0;t.length>n;n++)t[n].length>i&&(i=t[n].length,s=n);return s},a.setMonth(e(this._get(t,r.match(/MM/)?"monthNames":"monthNamesShort"))),a.setDate(e(this._get(t,r.match(/DD/)?"dayNames":"dayNamesShort"))+20-a.getDay())),t.input.attr("size",this._formatDate(t,a).length)}},_inlineDatepicker:function(e,i){var s=t(e);s.hasClass(this.markerClassName)||(s.addClass(this.markerClassName).append(i.dpDiv),t.data(e,r,i),this._setDate(i,this._getDefaultDate(i),!0),this._updateDatepicker(i),this._updateAlternate(i),i.settings.disabled&&this._disableDatepicker(e),i.dpDiv.css("display","block"))},_dialogDatepicker:function(e,i,s,a,o){var h,l,c,u,d,p=this._dialogInst;return p||(this.uuid+=1,h="dp"+this.uuid,this._dialogInput=t("<input type='text' id='"+h+"' style='position: absolute; top: -100px; width: 0px;'/>"),this._dialogInput.keydown(this._doKeyDown),t("body").append(this._dialogInput),p=this._dialogInst=this._newInst(this._dialogInput,!1),p.settings={},t.data(this._dialogInput[0],r,p)),n(p.settings,a||{}),i=i&&i.constructor===Date?this._formatDate(p,i):i,this._dialogInput.val(i),this._pos=o?o.length?o:[o.pageX,o.pageY]:null,this._pos||(l=document.documentElement.clientWidth,c=document.documentElement.clientHeight,u=document.documentElement.scrollLeft||document.body.scrollLeft,d=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[l/2-100+u,c/2-150+d]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),p.settings.onSelect=s,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),t.blockUI&&t.blockUI(this.dpDiv),t.data(this._dialogInput[0],r,p),this},_destroyDatepicker:function(e){var i,s=t(e),n=t.data(e,r);s.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),t.removeData(e,r),"input"===i?(n.append.remove(),n.trigger.remove(),s.removeClass(this.markerClassName).unbind("focus",this._showDatepicker).unbind("keydown",this._doKeyDown).unbind("keypress",this._doKeyPress).unbind("keyup",this._doKeyUp)):("div"===i||"span"===i)&&s.removeClass(this.markerClassName).empty())},_enableDatepicker:function(e){var i,s,n=t(e),a=t.data(e,r);n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),"input"===i?(e.disabled=!1,a.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):("div"===i||"span"===i)&&(s=n.children("."+this._inlineClass),s.children().removeClass("ui-state-disabled"),s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}))},_disableDatepicker:function(e){var i,s,n=t(e),a=t.data(e,r);n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),"input"===i?(e.disabled=!0,a.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):("div"===i||"span"===i)&&(s=n.children("."+this._inlineClass),s.children().addClass("ui-state-disabled"),s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}),this._disabledInputs[this._disabledInputs.length]=e)},_isDisabledDatepicker:function(t){if(!t)return!1;for(var e=0;this._disabledInputs.length>e;e++)if(this._disabledInputs[e]===t)return!0;return!1},_getInst:function(e){try{return t.data(e,r)}catch(i){throw"Missing instance data for this datepicker"}},_optionDatepicker:function(i,s,a){var r,o,h,l,c=this._getInst(i);return 2===arguments.length&&"string"==typeof s?"defaults"===s?t.extend({},t.datepicker._defaults):c?"all"===s?t.extend({},c.settings):this._get(c,s):null:(r=s||{},"string"==typeof s&&(r={},r[s]=a),c&&(this._curInst===c&&this._hideDatepicker(),o=this._getDateDatepicker(i,!0),h=this._getMinMaxDate(c,"min"),l=this._getMinMaxDate(c,"max"),n(c.settings,r),null!==h&&r.dateFormat!==e&&r.minDate===e&&(c.settings.minDate=this._formatDate(c,h)),null!==l&&r.dateFormat!==e&&r.maxDate===e&&(c.settings.maxDate=this._formatDate(c,l)),"disabled"in r&&(r.disabled?this._disableDatepicker(i):this._enableDatepicker(i)),this._attachments(t(i),c),this._autoSize(c),this._setDate(c,o),this._updateAlternate(c),this._updateDatepicker(c)),e)},_changeDatepicker:function(t,e,i){this._optionDatepicker(t,e,i)},_refreshDatepicker:function(t){var e=this._getInst(t);e&&this._updateDatepicker(e)},_setDateDatepicker:function(t,e){var i=this._getInst(t);i&&(this._setDate(i,e),this._updateDatepicker(i),this._updateAlternate(i))},_getDateDatepicker:function(t,e){var i=this._getInst(t);return i&&!i.inline&&this._setDateFromField(i,e),i?this._getDate(i):null},_doKeyDown:function(e){var i,s,n,a=t.datepicker._getInst(e.target),r=!0,o=a.dpDiv.is(".ui-datepicker-rtl");if(a._keyEvent=!0,t.datepicker._datepickerShowing)switch(e.keyCode){case 9:t.datepicker._hideDatepicker(),r=!1;break;case 13:return n=t("td."+t.datepicker._dayOverClass+":not(."+t.datepicker._currentClass+")",a.dpDiv),n[0]&&t.datepicker._selectDay(e.target,a.selectedMonth,a.selectedYear,n[0]),i=t.datepicker._get(a,"onSelect"),i?(s=t.datepicker._formatDate(a),i.apply(a.input?a.input[0]:null,[s,a])):t.datepicker._hideDatepicker(),!1;case 27:t.datepicker._hideDatepicker();break;case 33:t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(a,"stepBigMonths"):-t.datepicker._get(a,"stepMonths"),"M");break;case 34:t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(a,"stepBigMonths"):+t.datepicker._get(a,"stepMonths"),"M");break;case 35:(e.ctrlKey||e.metaKey)&&t.datepicker._clearDate(e.target),r=e.ctrlKey||e.metaKey;break;case 36:(e.ctrlKey||e.metaKey)&&t.datepicker._gotoToday(e.target),r=e.ctrlKey||e.metaKey;break;case 37:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,o?1:-1,"D"),r=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(a,"stepBigMonths"):-t.datepicker._get(a,"stepMonths"),"M");break;case 38:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,-7,"D"),r=e.ctrlKey||e.metaKey;break;case 39:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,o?-1:1,"D"),r=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(a,"stepBigMonths"):+t.datepicker._get(a,"stepMonths"),"M");break;case 40:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,7,"D"),r=e.ctrlKey||e.metaKey;break;default:r=!1}else 36===e.keyCode&&e.ctrlKey?t.datepicker._showDatepicker(this):r=!1;r&&(e.preventDefault(),e.stopPropagation())},_doKeyPress:function(i){var s,n,a=t.datepicker._getInst(i.target);return t.datepicker._get(a,"constrainInput")?(s=t.datepicker._possibleChars(t.datepicker._get(a,"dateFormat")),n=String.fromCharCode(null==i.charCode?i.keyCode:i.charCode),i.ctrlKey||i.metaKey||" ">n||!s||s.indexOf(n)>-1):e},_doKeyUp:function(e){var i,s=t.datepicker._getInst(e.target);if(s.input.val()!==s.lastVal)try{i=t.datepicker.parseDate(t.datepicker._get(s,"dateFormat"),s.input?s.input.val():null,t.datepicker._getFormatConfig(s)),i&&(t.datepicker._setDateFromField(s),t.datepicker._updateAlternate(s),t.datepicker._updateDatepicker(s))}catch(n){}return!0},_showDatepicker:function(e){if(e=e.target||e,"input"!==e.nodeName.toLowerCase()&&(e=t("input",e.parentNode)[0]),!t.datepicker._isDisabledDatepicker(e)&&t.datepicker._lastInput!==e){var i,s,a,r,o,h,l;i=t.datepicker._getInst(e),t.datepicker._curInst&&t.datepicker._curInst!==i&&(t.datepicker._curInst.dpDiv.stop(!0,!0),i&&t.datepicker._datepickerShowing&&t.datepicker._hideDatepicker(t.datepicker._curInst.input[0])),s=t.datepicker._get(i,"beforeShow"),a=s?s.apply(e,[e,i]):{},a!==!1&&(n(i.settings,a),i.lastVal=null,t.datepicker._lastInput=e,t.datepicker._setDateFromField(i),t.datepicker._inDialog&&(e.value=""),t.datepicker._pos||(t.datepicker._pos=t.datepicker._findPos(e),t.datepicker._pos[1]+=e.offsetHeight),r=!1,t(e).parents().each(function(){return r|="fixed"===t(this).css("position"),!r}),o={left:t.datepicker._pos[0],top:t.datepicker._pos[1]},t.datepicker._pos=null,i.dpDiv.empty(),i.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),t.datepicker._updateDatepicker(i),o=t.datepicker._checkOffset(i,o,r),i.dpDiv.css({position:t.datepicker._inDialog&&t.blockUI?"static":r?"fixed":"absolute",display:"none",left:o.left+"px",top:o.top+"px"}),i.inline||(h=t.datepicker._get(i,"showAnim"),l=t.datepicker._get(i,"duration"),i.dpDiv.zIndex(t(e).zIndex()+1),t.datepicker._datepickerShowing=!0,t.effects&&t.effects.effect[h]?i.dpDiv.show(h,t.datepicker._get(i,"showOptions"),l):i.dpDiv[h||"show"](h?l:null),t.datepicker._shouldFocusInput(i)&&i.input.focus(),t.datepicker._curInst=i))}},_updateDatepicker:function(e){this.maxRows=4,a=e,e.dpDiv.empty().append(this._generateHTML(e)),this._attachHandlers(e),e.dpDiv.find("."+this._dayOverClass+" a").mouseover();var i,s=this._getNumberOfMonths(e),n=s[1],r=17;e.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""),n>1&&e.dpDiv.addClass("ui-datepicker-multi-"+n).css("width",r*n+"em"),e.dpDiv[(1!==s[0]||1!==s[1]?"add":"remove")+"Class"]("ui-datepicker-multi"),e.dpDiv[(this._get(e,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl"),e===t.datepicker._curInst&&t.datepicker._datepickerShowing&&t.datepicker._shouldFocusInput(e)&&e.input.focus(),e.yearshtml&&(i=e.yearshtml,setTimeout(function(){i===e.yearshtml&&e.yearshtml&&e.dpDiv.find("select.ui-datepicker-year:first").replaceWith(e.yearshtml),i=e.yearshtml=null},0))},_shouldFocusInput:function(t){return t.input&&t.input.is(":visible")&&!t.input.is(":disabled")&&!t.input.is(":focus")},_checkOffset:function(e,i,s){var n=e.dpDiv.outerWidth(),a=e.dpDiv.outerHeight(),r=e.input?e.input.outerWidth():0,o=e.input?e.input.outerHeight():0,h=document.documentElement.clientWidth+(s?0:t(document).scrollLeft()),l=document.documentElement.clientHeight+(s?0:t(document).scrollTop());return i.left-=this._get(e,"isRTL")?n-r:0,i.left-=s&&i.left===e.input.offset().left?t(document).scrollLeft():0,i.top-=s&&i.top===e.input.offset().top+o?t(document).scrollTop():0,i.left-=Math.min(i.left,i.left+n>h&&h>n?Math.abs(i.left+n-h):0),i.top-=Math.min(i.top,i.top+a>l&&l>a?Math.abs(a+o):0),i},_findPos:function(e){for(var i,s=this._getInst(e),n=this._get(s,"isRTL");e&&("hidden"===e.type||1!==e.nodeType||t.expr.filters.hidden(e));)e=e[n?"previousSibling":"nextSibling"];return i=t(e).offset(),[i.left,i.top]},_hideDatepicker:function(e){var i,s,n,a,o=this._curInst;!o||e&&o!==t.data(e,r)||this._datepickerShowing&&(i=this._get(o,"showAnim"),s=this._get(o,"duration"),n=function(){t.datepicker._tidyDialog(o)},t.effects&&(t.effects.effect[i]||t.effects[i])?o.dpDiv.hide(i,t.datepicker._get(o,"showOptions"),s,n):o.dpDiv["slideDown"===i?"slideUp":"fadeIn"===i?"fadeOut":"hide"](i?s:null,n),i||n(),this._datepickerShowing=!1,a=this._get(o,"onClose"),a&&a.apply(o.input?o.input[0]:null,[o.input?o.input.val():"",o]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),t.blockUI&&(t.unblockUI(),t("body").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(t){t.dpDiv.removeClass(this._dialogClass).unbind(".ui-datepicker-calendar")},_checkExternalClick:function(e){if(t.datepicker._curInst){var i=t(e.target),s=t.datepicker._getInst(i[0]);(i[0].id!==t.datepicker._mainDivId&&0===i.parents("#"+t.datepicker._mainDivId).length&&!i.hasClass(t.datepicker.markerClassName)&&!i.closest("."+t.datepicker._triggerClass).length&&t.datepicker._datepickerShowing&&(!t.datepicker._inDialog||!t.blockUI)||i.hasClass(t.datepicker.markerClassName)&&t.datepicker._curInst!==s)&&t.datepicker._hideDatepicker()}},_adjustDate:function(e,i,s){var n=t(e),a=this._getInst(n[0]);this._isDisabledDatepicker(n[0])||(this._adjustInstDate(a,i+("M"===s?this._get(a,"showCurrentAtPos"):0),s),this._updateDatepicker(a))},_gotoToday:function(e){var i,s=t(e),n=this._getInst(s[0]);this._get(n,"gotoCurrent")&&n.currentDay?(n.selectedDay=n.currentDay,n.drawMonth=n.selectedMonth=n.currentMonth,n.drawYear=n.selectedYear=n.currentYear):(i=new Date,n.selectedDay=i.getDate(),n.drawMonth=n.selectedMonth=i.getMonth(),n.drawYear=n.selectedYear=i.getFullYear()),this._notifyChange(n),this._adjustDate(s)},_selectMonthYear:function(e,i,s){var n=t(e),a=this._getInst(n[0]);a["selected"+("M"===s?"Month":"Year")]=a["draw"+("M"===s?"Month":"Year")]=parseInt(i.options[i.selectedIndex].value,10),this._notifyChange(a),this._adjustDate(n)},_selectDay:function(e,i,s,n){var a,r=t(e);t(n).hasClass(this._unselectableClass)||this._isDisabledDatepicker(r[0])||(a=this._getInst(r[0]),a.selectedDay=a.currentDay=t("a",n).html(),a.selectedMonth=a.currentMonth=i,a.selectedYear=a.currentYear=s,this._selectDate(e,this._formatDate(a,a.currentDay,a.currentMonth,a.currentYear)))},_clearDate:function(e){var i=t(e);this._selectDate(i,"")},_selectDate:function(e,i){var s,n=t(e),a=this._getInst(n[0]);i=null!=i?i:this._formatDate(a),a.input&&a.input.val(i),this._updateAlternate(a),s=this._get(a,"onSelect"),s?s.apply(a.input?a.input[0]:null,[i,a]):a.input&&a.input.trigger("change"),a.inline?this._updateDatepicker(a):(this._hideDatepicker(),this._lastInput=a.input[0],"object"!=typeof a.input[0]&&a.input.focus(),this._lastInput=null)},_updateAlternate:function(e){var i,s,n,a=this._get(e,"altField");a&&(i=this._get(e,"altFormat")||this._get(e,"dateFormat"),s=this._getDate(e),n=this.formatDate(i,s,this._getFormatConfig(e)),t(a).each(function(){t(this).val(n)}))},noWeekends:function(t){var e=t.getDay();return[e>0&&6>e,""]},iso8601Week:function(t){var e,i=new Date(t.getTime());return i.setDate(i.getDate()+4-(i.getDay()||7)),e=i.getTime(),i.setMonth(0),i.setDate(1),Math.floor(Math.round((e-i)/864e5)/7)+1},parseDate:function(i,s,n){if(null==i||null==s)throw"Invalid arguments";if(s="object"==typeof s?""+s:s+"",""===s)return null;var a,r,o,h,l=0,c=(n?n.shortYearCutoff:null)||this._defaults.shortYearCutoff,u="string"!=typeof c?c:(new Date).getFullYear()%100+parseInt(c,10),d=(n?n.dayNamesShort:null)||this._defaults.dayNamesShort,p=(n?n.dayNames:null)||this._defaults.dayNames,f=(n?n.monthNamesShort:null)||this._defaults.monthNamesShort,m=(n?n.monthNames:null)||this._defaults.monthNames,g=-1,v=-1,_=-1,b=-1,y=!1,x=function(t){var e=i.length>a+1&&i.charAt(a+1)===t;return e&&a++,e},k=function(t){var e=x(t),i="@"===t?14:"!"===t?20:"y"===t&&e?4:"o"===t?3:2,n=RegExp("^\\d{1,"+i+"}"),a=s.substring(l).match(n);if(!a)throw"Missing number at position "+l;return l+=a[0].length,parseInt(a[0],10)},w=function(i,n,a){var r=-1,o=t.map(x(i)?a:n,function(t,e){return[[e,t]]}).sort(function(t,e){return-(t[1].length-e[1].length)});if(t.each(o,function(t,i){var n=i[1];return s.substr(l,n.length).toLowerCase()===n.toLowerCase()?(r=i[0],l+=n.length,!1):e}),-1!==r)return r+1;throw"Unknown name at position "+l},D=function(){if(s.charAt(l)!==i.charAt(a))throw"Unexpected literal at position "+l;l++};for(a=0;i.length>a;a++)if(y)"'"!==i.charAt(a)||x("'")?D():y=!1;else switch(i.charAt(a)){case"d":_=k("d");break;case"D":w("D",d,p);break;case"o":b=k("o");break;case"m":v=k("m");break;case"M":v=w("M",f,m);break;case"y":g=k("y");break;case"@":h=new Date(k("@")),g=h.getFullYear(),v=h.getMonth()+1,_=h.getDate();break;case"!":h=new Date((k("!")-this._ticksTo1970)/1e4),g=h.getFullYear(),v=h.getMonth()+1,_=h.getDate();break;case"'":x("'")?D():y=!0;break;default:D()}if(s.length>l&&(o=s.substr(l),!/^\s+/.test(o)))throw"Extra/unparsed characters found in date: "+o;if(-1===g?g=(new Date).getFullYear():100>g&&(g+=(new Date).getFullYear()-(new Date).getFullYear()%100+(u>=g?0:-100)),b>-1)for(v=1,_=b;;){if(r=this._getDaysInMonth(g,v-1),r>=_)break;v++,_-=r}if(h=this._daylightSavingAdjust(new Date(g,v-1,_)),h.getFullYear()!==g||h.getMonth()+1!==v||h.getDate()!==_)throw"Invalid date";return h},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TICKS:"!",TIMESTAMP:"@",W3C:"yy-mm-dd",_ticksTo1970:1e7*60*60*24*(718685+Math.floor(492.5)-Math.floor(19.7)+Math.floor(4.925)),formatDate:function(t,e,i){if(!e)return"";var s,n=(i?i.dayNamesShort:null)||this._defaults.dayNamesShort,a=(i?i.dayNames:null)||this._defaults.dayNames,r=(i?i.monthNamesShort:null)||this._defaults.monthNamesShort,o=(i?i.monthNames:null)||this._defaults.monthNames,h=function(e){var i=t.length>s+1&&t.charAt(s+1)===e;return i&&s++,i},l=function(t,e,i){var s=""+e;if(h(t))for(;i>s.length;)s="0"+s;return s},c=function(t,e,i,s){return h(t)?s[e]:i[e]},u="",d=!1;if(e)for(s=0;t.length>s;s++)if(d)"'"!==t.charAt(s)||h("'")?u+=t.charAt(s):d=!1;else switch(t.charAt(s)){case"d":u+=l("d",e.getDate(),2);break;case"D":u+=c("D",e.getDay(),n,a);break;case"o":u+=l("o",Math.round((new Date(e.getFullYear(),e.getMonth(),e.getDate()).getTime()-new Date(e.getFullYear(),0,0).getTime())/864e5),3);break;case"m":u+=l("m",e.getMonth()+1,2);break;case"M":u+=c("M",e.getMonth(),r,o);break;case"y":u+=h("y")?e.getFullYear():(10>e.getYear()%100?"0":"")+e.getYear()%100;break;case"@":u+=e.getTime();break;case"!":u+=1e4*e.getTime()+this._ticksTo1970;break;case"'":h("'")?u+="'":d=!0;break;default:u+=t.charAt(s)}return u},_possibleChars:function(t){var e,i="",s=!1,n=function(i){var s=t.length>e+1&&t.charAt(e+1)===i;return s&&e++,s};for(e=0;t.length>e;e++)if(s)"'"!==t.charAt(e)||n("'")?i+=t.charAt(e):s=!1;else switch(t.charAt(e)){case"d":case"m":case"y":case"@":i+="0123456789";break;case"D":case"M":return null;case"'":n("'")?i+="'":s=!0;break;default:i+=t.charAt(e)}return i},_get:function(t,i){return t.settings[i]!==e?t.settings[i]:this._defaults[i]},_setDateFromField:function(t,e){if(t.input.val()!==t.lastVal){var i=this._get(t,"dateFormat"),s=t.lastVal=t.input?t.input.val():null,n=this._getDefaultDate(t),a=n,r=this._getFormatConfig(t);try{a=this.parseDate(i,s,r)||n}catch(o){s=e?"":s}t.selectedDay=a.getDate(),t.drawMonth=t.selectedMonth=a.getMonth(),t.drawYear=t.selectedYear=a.getFullYear(),t.currentDay=s?a.getDate():0,t.currentMonth=s?a.getMonth():0,t.currentYear=s?a.getFullYear():0,this._adjustInstDate(t)}},_getDefaultDate:function(t){return this._restrictMinMax(t,this._determineDate(t,this._get(t,"defaultDate"),new Date))},_determineDate:function(e,i,s){var n=function(t){var e=new Date;return e.setDate(e.getDate()+t),e},a=function(i){try{return t.datepicker.parseDate(t.datepicker._get(e,"dateFormat"),i,t.datepicker._getFormatConfig(e))}catch(s){}for(var n=(i.toLowerCase().match(/^c/)?t.datepicker._getDate(e):null)||new Date,a=n.getFullYear(),r=n.getMonth(),o=n.getDate(),h=/([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,l=h.exec(i);l;){switch(l[2]||"d"){case"d":case"D":o+=parseInt(l[1],10);break;case"w":case"W":o+=7*parseInt(l[1],10);break;case"m":case"M":r+=parseInt(l[1],10),o=Math.min(o,t.datepicker._getDaysInMonth(a,r));break;case"y":case"Y":a+=parseInt(l[1],10),o=Math.min(o,t.datepicker._getDaysInMonth(a,r))}l=h.exec(i)}return new Date(a,r,o)},r=null==i||""===i?s:"string"==typeof i?a(i):"number"==typeof i?isNaN(i)?s:n(i):new Date(i.getTime());return r=r&&"Invalid Date"==""+r?s:r,r&&(r.setHours(0),r.setMinutes(0),r.setSeconds(0),r.setMilliseconds(0)),this._daylightSavingAdjust(r)},_daylightSavingAdjust:function(t){return t?(t.setHours(t.getHours()>12?t.getHours()+2:0),t):null},_setDate:function(t,e,i){var s=!e,n=t.selectedMonth,a=t.selectedYear,r=this._restrictMinMax(t,this._determineDate(t,e,new Date));t.selectedDay=t.currentDay=r.getDate(),t.drawMonth=t.selectedMonth=t.currentMonth=r.getMonth(),t.drawYear=t.selectedYear=t.currentYear=r.getFullYear(),n===t.selectedMonth&&a===t.selectedYear||i||this._notifyChange(t),this._adjustInstDate(t),t.input&&t.input.val(s?"":this._formatDate(t))},_getDate:function(t){var e=!t.currentYear||t.input&&""===t.input.val()?null:this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return e},_attachHandlers:function(e){var i=this._get(e,"stepMonths"),s="#"+e.id.replace(/\\\\/g,"\\");e.dpDiv.find("[data-handler]").map(function(){var e={prev:function(){t.datepicker._adjustDate(s,-i,"M")},next:function(){t.datepicker._adjustDate(s,+i,"M")},hide:function(){t.datepicker._hideDatepicker()},today:function(){t.datepicker._gotoToday(s)},selectDay:function(){return t.datepicker._selectDay(s,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return t.datepicker._selectMonthYear(s,this,"M"),!1},selectYear:function(){return t.datepicker._selectMonthYear(s,this,"Y"),!1}};t(this).bind(this.getAttribute("data-event"),e[this.getAttribute("data-handler")])})},_generateHTML:function(t){var e,i,s,n,a,r,o,h,l,c,u,d,p,f,m,g,v,_,b,y,x,k,w,D,T,C,M,S,N,I,P,A,z,H,E,F,O,W,j,R=new Date,L=this._daylightSavingAdjust(new Date(R.getFullYear(),R.getMonth(),R.getDate())),Y=this._get(t,"isRTL"),B=this._get(t,"showButtonPanel"),J=this._get(t,"hideIfNoPrevNext"),K=this._get(t,"navigationAsDateFormat"),Q=this._getNumberOfMonths(t),V=this._get(t,"showCurrentAtPos"),U=this._get(t,"stepMonths"),q=1!==Q[0]||1!==Q[1],X=this._daylightSavingAdjust(t.currentDay?new Date(t.currentYear,t.currentMonth,t.currentDay):new Date(9999,9,9)),G=this._getMinMaxDate(t,"min"),$=this._getMinMaxDate(t,"max"),Z=t.drawMonth-V,te=t.drawYear;if(0>Z&&(Z+=12,te--),$)for(e=this._daylightSavingAdjust(new Date($.getFullYear(),$.getMonth()-Q[0]*Q[1]+1,$.getDate())),e=G&&G>e?G:e;this._daylightSavingAdjust(new Date(te,Z,1))>e;)Z--,0>Z&&(Z=11,te--);for(t.drawMonth=Z,t.drawYear=te,i=this._get(t,"prevText"),i=K?this.formatDate(i,this._daylightSavingAdjust(new Date(te,Z-U,1)),this._getFormatConfig(t)):i,s=this._canAdjustMonth(t,-1,te,Z)?"<a class='ui-datepicker-prev ui-corner-all' data-handler='prev' data-event='click' title='"+i+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"e":"w")+"'>"+i+"</span></a>":J?"":"<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='"+i+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"e":"w")+"'>"+i+"</span></a>",n=this._get(t,"nextText"),n=K?this.formatDate(n,this._daylightSavingAdjust(new Date(te,Z+U,1)),this._getFormatConfig(t)):n,a=this._canAdjustMonth(t,1,te,Z)?"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click' title='"+n+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"w":"e")+"'>"+n+"</span></a>":J?"":"<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='"+n+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"w":"e")+"'>"+n+"</span></a>",r=this._get(t,"currentText"),o=this._get(t,"gotoCurrent")&&t.currentDay?X:L,r=K?this.formatDate(r,o,this._getFormatConfig(t)):r,h=t.inline?"":"<button type='button' class='ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all' data-handler='hide' data-event='click'>"+this._get(t,"closeText")+"</button>",l=B?"<div class='ui-datepicker-buttonpane ui-widget-content'>"+(Y?h:"")+(this._isInRange(t,o)?"<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'>"+r+"</button>":"")+(Y?"":h)+"</div>":"",c=parseInt(this._get(t,"firstDay"),10),c=isNaN(c)?0:c,u=this._get(t,"showWeek"),d=this._get(t,"dayNames"),p=this._get(t,"dayNamesMin"),f=this._get(t,"monthNames"),m=this._get(t,"monthNamesShort"),g=this._get(t,"beforeShowDay"),v=this._get(t,"showOtherMonths"),_=this._get(t,"selectOtherMonths"),b=this._getDefaultDate(t),y="",k=0;Q[0]>k;k++){for(w="",this.maxRows=4,D=0;Q[1]>D;D++){if(T=this._daylightSavingAdjust(new Date(te,Z,t.selectedDay)),C=" ui-corner-all",M="",q){if(M+="<div class='ui-datepicker-group",Q[1]>1)switch(D){case 0:M+=" ui-datepicker-group-first",C=" ui-corner-"+(Y?"right":"left");break;case Q[1]-1:M+=" ui-datepicker-group-last",C=" ui-corner-"+(Y?"left":"right");break;default:M+=" ui-datepicker-group-middle",C=""}M+="'>"}for(M+="<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix"+C+"'>"+(/all|left/.test(C)&&0===k?Y?a:s:"")+(/all|right/.test(C)&&0===k?Y?s:a:"")+this._generateMonthYearHeader(t,Z,te,G,$,k>0||D>0,f,m)+"</div><table class='ui-datepicker-calendar'><thead>"+"<tr>",S=u?"<th class='ui-datepicker-week-col'>"+this._get(t,"weekHeader")+"</th>":"",x=0;7>x;x++)N=(x+c)%7,S+="<th"+((x+c+6)%7>=5?" class='ui-datepicker-week-end'":"")+">"+"<span title='"+d[N]+"'>"+p[N]+"</span></th>";for(M+=S+"</tr></thead><tbody>",I=this._getDaysInMonth(te,Z),te===t.selectedYear&&Z===t.selectedMonth&&(t.selectedDay=Math.min(t.selectedDay,I)),P=(this._getFirstDayOfMonth(te,Z)-c+7)%7,A=Math.ceil((P+I)/7),z=q?this.maxRows>A?this.maxRows:A:A,this.maxRows=z,H=this._daylightSavingAdjust(new Date(te,Z,1-P)),E=0;z>E;E++){for(M+="<tr>",F=u?"<td class='ui-datepicker-week-col'>"+this._get(t,"calculateWeek")(H)+"</td>":"",x=0;7>x;x++)O=g?g.apply(t.input?t.input[0]:null,[H]):[!0,""],W=H.getMonth()!==Z,j=W&&!_||!O[0]||G&&G>H||$&&H>$,F+="<td class='"+((x+c+6)%7>=5?" ui-datepicker-week-end":"")+(W?" ui-datepicker-other-month":"")+(H.getTime()===T.getTime()&&Z===t.selectedMonth&&t._keyEvent||b.getTime()===H.getTime()&&b.getTime()===T.getTime()?" "+this._dayOverClass:"")+(j?" "+this._unselectableClass+" ui-state-disabled":"")+(W&&!v?"":" "+O[1]+(H.getTime()===X.getTime()?" "+this._currentClass:"")+(H.getTime()===L.getTime()?" ui-datepicker-today":""))+"'"+(W&&!v||!O[2]?"":" title='"+O[2].replace(/'/g,"'")+"'")+(j?"":" data-handler='selectDay' data-event='click' data-month='"+H.getMonth()+"' data-year='"+H.getFullYear()+"'")+">"+(W&&!v?" ":j?"<span class='ui-state-default'>"+H.getDate()+"</span>":"<a class='ui-state-default"+(H.getTime()===L.getTime()?" ui-state-highlight":"")+(H.getTime()===X.getTime()?" ui-state-active":"")+(W?" ui-priority-secondary":"")+"' href='#'>"+H.getDate()+"</a>")+"</td>",H.setDate(H.getDate()+1),H=this._daylightSavingAdjust(H);M+=F+"</tr>"}Z++,Z>11&&(Z=0,te++),M+="</tbody></table>"+(q?"</div>"+(Q[0]>0&&D===Q[1]-1?"<div class='ui-datepicker-row-break'></div>":""):""),w+=M}y+=w}return y+=l,t._keyEvent=!1,y},_generateMonthYearHeader:function(t,e,i,s,n,a,r,o){var h,l,c,u,d,p,f,m,g=this._get(t,"changeMonth"),v=this._get(t,"changeYear"),_=this._get(t,"showMonthAfterYear"),b="<div class='ui-datepicker-title'>",y="";if(a||!g)y+="<span class='ui-datepicker-month'>"+r[e]+"</span>";else{for(h=s&&s.getFullYear()===i,l=n&&n.getFullYear()===i,y+="<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>",c=0;12>c;c++)(!h||c>=s.getMonth())&&(!l||n.getMonth()>=c)&&(y+="<option value='"+c+"'"+(c===e?" selected='selected'":"")+">"+o[c]+"</option>");y+="</select>"}if(_||(b+=y+(!a&&g&&v?"":" ")),!t.yearshtml)if(t.yearshtml="",a||!v)b+="<span class='ui-datepicker-year'>"+i+"</span>";else{for(u=this._get(t,"yearRange").split(":"),d=(new Date).getFullYear(),p=function(t){var e=t.match(/c[+\-].*/)?i+parseInt(t.substring(1),10):t.match(/[+\-].*/)?d+parseInt(t,10):parseInt(t,10);
|
5 |
+
return isNaN(e)?d:e},f=p(u[0]),m=Math.max(f,p(u[1]||"")),f=s?Math.max(f,s.getFullYear()):f,m=n?Math.min(m,n.getFullYear()):m,t.yearshtml+="<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>";m>=f;f++)t.yearshtml+="<option value='"+f+"'"+(f===i?" selected='selected'":"")+">"+f+"</option>";t.yearshtml+="</select>",b+=t.yearshtml,t.yearshtml=null}return b+=this._get(t,"yearSuffix"),_&&(b+=(!a&&g&&v?"":" ")+y),b+="</div>"},_adjustInstDate:function(t,e,i){var s=t.drawYear+("Y"===i?e:0),n=t.drawMonth+("M"===i?e:0),a=Math.min(t.selectedDay,this._getDaysInMonth(s,n))+("D"===i?e:0),r=this._restrictMinMax(t,this._daylightSavingAdjust(new Date(s,n,a)));t.selectedDay=r.getDate(),t.drawMonth=t.selectedMonth=r.getMonth(),t.drawYear=t.selectedYear=r.getFullYear(),("M"===i||"Y"===i)&&this._notifyChange(t)},_restrictMinMax:function(t,e){var i=this._getMinMaxDate(t,"min"),s=this._getMinMaxDate(t,"max"),n=i&&i>e?i:e;return s&&n>s?s:n},_notifyChange:function(t){var e=this._get(t,"onChangeMonthYear");e&&e.apply(t.input?t.input[0]:null,[t.selectedYear,t.selectedMonth+1,t])},_getNumberOfMonths:function(t){var e=this._get(t,"numberOfMonths");return null==e?[1,1]:"number"==typeof e?[1,e]:e},_getMinMaxDate:function(t,e){return this._determineDate(t,this._get(t,e+"Date"),null)},_getDaysInMonth:function(t,e){return 32-this._daylightSavingAdjust(new Date(t,e,32)).getDate()},_getFirstDayOfMonth:function(t,e){return new Date(t,e,1).getDay()},_canAdjustMonth:function(t,e,i,s){var n=this._getNumberOfMonths(t),a=this._daylightSavingAdjust(new Date(i,s+(0>e?e:n[0]*n[1]),1));return 0>e&&a.setDate(this._getDaysInMonth(a.getFullYear(),a.getMonth())),this._isInRange(t,a)},_isInRange:function(t,e){var i,s,n=this._getMinMaxDate(t,"min"),a=this._getMinMaxDate(t,"max"),r=null,o=null,h=this._get(t,"yearRange");return h&&(i=h.split(":"),s=(new Date).getFullYear(),r=parseInt(i[0],10),o=parseInt(i[1],10),i[0].match(/[+\-].*/)&&(r+=s),i[1].match(/[+\-].*/)&&(o+=s)),(!n||e.getTime()>=n.getTime())&&(!a||e.getTime()<=a.getTime())&&(!r||e.getFullYear()>=r)&&(!o||o>=e.getFullYear())},_getFormatConfig:function(t){var e=this._get(t,"shortYearCutoff");return e="string"!=typeof e?e:(new Date).getFullYear()%100+parseInt(e,10),{shortYearCutoff:e,dayNamesShort:this._get(t,"dayNamesShort"),dayNames:this._get(t,"dayNames"),monthNamesShort:this._get(t,"monthNamesShort"),monthNames:this._get(t,"monthNames")}},_formatDate:function(t,e,i,s){e||(t.currentDay=t.selectedDay,t.currentMonth=t.selectedMonth,t.currentYear=t.selectedYear);var n=e?"object"==typeof e?e:this._daylightSavingAdjust(new Date(s,i,e)):this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return this.formatDate(this._get(t,"dateFormat"),n,this._getFormatConfig(t))}}),t.fn.datepicker=function(e){if(!this.length)return this;t.datepicker.initialized||(t(document).mousedown(t.datepicker._checkExternalClick),t.datepicker.initialized=!0),0===t("#"+t.datepicker._mainDivId).length&&t("body").append(t.datepicker.dpDiv);var i=Array.prototype.slice.call(arguments,1);return"string"!=typeof e||"isDisabled"!==e&&"getDate"!==e&&"widget"!==e?"option"===e&&2===arguments.length&&"string"==typeof arguments[1]?t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this[0]].concat(i)):this.each(function(){"string"==typeof e?t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this].concat(i)):t.datepicker._attachDatepicker(this,e)}):t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this[0]].concat(i))},t.datepicker=new i,t.datepicker.initialized=!1,t.datepicker.uuid=(new Date).getTime(),t.datepicker.version="1.10.3"})(jQuery);
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/animated-overlay.gif
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_flat_0_aaaaaa_40x100.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_flat_75_ffffff_40x100.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_55_fbf9ee_1x400.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_65_ffffff_1x400.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_75_dadada_1x400.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_75_e6e6e6_1x400.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_glass_95_fef1ec_1x400.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-bg_highlight-soft_75_cccccc_1x100.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_222222_256x240.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_2e83ff_256x240.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_454545_256x240.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_888888_256x240.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/images/ui-icons_cd0a0a_256x240.png
ADDED
Binary file
|
skin/frontend/base/default/js/autoship/jquery/ui/theme/jquery-ui.css
ADDED
@@ -0,0 +1,1188 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/*! jQuery UI - v1.10.3 - 2013-05-03
|
2 |
+
* http://jqueryui.com
|
3 |
+
* Includes: jquery.ui.core.css, jquery.ui.accordion.css, jquery.ui.autocomplete.css, jquery.ui.button.css, jquery.ui.datepicker.css, jquery.ui.dialog.css, jquery.ui.menu.css, jquery.ui.progressbar.css, jquery.ui.resizable.css, jquery.ui.selectable.css, jquery.ui.slider.css, jquery.ui.spinner.css, jquery.ui.tabs.css, jquery.ui.tooltip.css, jquery.ui.theme.css
|
4 |
+
* Copyright 2013 jQuery Foundation and other contributors; Licensed MIT */
|
5 |
+
/* Layout helpers
|
6 |
+
----------------------------------*/
|
7 |
+
.ui-helper-hidden {
|
8 |
+
display: none;
|
9 |
+
}
|
10 |
+
.ui-helper-hidden-accessible {
|
11 |
+
border: 0;
|
12 |
+
clip: rect(0 0 0 0);
|
13 |
+
height: 1px;
|
14 |
+
margin: -1px;
|
15 |
+
overflow: hidden;
|
16 |
+
padding: 0;
|
17 |
+
position: absolute;
|
18 |
+
width: 1px;
|
19 |
+
}
|
20 |
+
.ui-helper-reset {
|
21 |
+
margin: 0;
|
22 |
+
padding: 0;
|
23 |
+
border: 0;
|
24 |
+
outline: 0;
|
25 |
+
line-height: 1.3;
|
26 |
+
text-decoration: none;
|
27 |
+
font-size: 100%;
|
28 |
+
list-style: none;
|
29 |
+
}
|
30 |
+
.ui-helper-clearfix:before,
|
31 |
+
.ui-helper-clearfix:after {
|
32 |
+
content: "";
|
33 |
+
display: table;
|
34 |
+
border-collapse: collapse;
|
35 |
+
}
|
36 |
+
.ui-helper-clearfix:after {
|
37 |
+
clear: both;
|
38 |
+
}
|
39 |
+
.ui-helper-clearfix {
|
40 |
+
min-height: 0; /* support: IE7 */
|
41 |
+
}
|
42 |
+
.ui-helper-zfix {
|
43 |
+
width: 100%;
|
44 |
+
height: 100%;
|
45 |
+
top: 0;
|
46 |
+
left: 0;
|
47 |
+
position: absolute;
|
48 |
+
opacity: 0;
|
49 |
+
filter:Alpha(Opacity=0);
|
50 |
+
}
|
51 |
+
|
52 |
+
.ui-front {
|
53 |
+
z-index: 100;
|
54 |
+
}
|
55 |
+
|
56 |
+
|
57 |
+
/* Interaction Cues
|
58 |
+
----------------------------------*/
|
59 |
+
.ui-state-disabled {
|
60 |
+
cursor: default !important;
|
61 |
+
}
|
62 |
+
|
63 |
+
|
64 |
+
/* Icons
|
65 |
+
----------------------------------*/
|
66 |
+
|
67 |
+
/* states and images */
|
68 |
+
.ui-icon {
|
69 |
+
display: block;
|
70 |
+
text-indent: -99999px;
|
71 |
+
overflow: hidden;
|
72 |
+
background-repeat: no-repeat;
|
73 |
+
}
|
74 |
+
|
75 |
+
|
76 |
+
/* Misc visuals
|
77 |
+
----------------------------------*/
|
78 |
+
|
79 |
+
/* Overlays */
|
80 |
+
.ui-widget-overlay {
|
81 |
+
position: fixed;
|
82 |
+
top: 0;
|
83 |
+
left: 0;
|
84 |
+
width: 100%;
|
85 |
+
height: 100%;
|
86 |
+
}
|
87 |
+
|
88 |
+
.ui-accordion .ui-accordion-header {
|
89 |
+
display: block;
|
90 |
+
cursor: pointer;
|
91 |
+
position: relative;
|
92 |
+
margin-top: 2px;
|
93 |
+
padding: .5em .5em .5em .7em;
|
94 |
+
min-height: 0; /* support: IE7 */
|
95 |
+
}
|
96 |
+
.ui-accordion .ui-accordion-icons {
|
97 |
+
padding-left: 2.2em;
|
98 |
+
}
|
99 |
+
.ui-accordion .ui-accordion-noicons {
|
100 |
+
padding-left: .7em;
|
101 |
+
}
|
102 |
+
.ui-accordion .ui-accordion-icons .ui-accordion-icons {
|
103 |
+
padding-left: 2.2em;
|
104 |
+
}
|
105 |
+
.ui-accordion .ui-accordion-header .ui-accordion-header-icon {
|
106 |
+
position: absolute;
|
107 |
+
left: .5em;
|
108 |
+
top: 50%;
|
109 |
+
margin-top: -8px;
|
110 |
+
}
|
111 |
+
.ui-accordion .ui-accordion-content {
|
112 |
+
padding: 1em 2.2em;
|
113 |
+
border-top: 0;
|
114 |
+
overflow: auto;
|
115 |
+
}
|
116 |
+
|
117 |
+
.ui-autocomplete {
|
118 |
+
position: absolute;
|
119 |
+
top: 0;
|
120 |
+
left: 0;
|
121 |
+
cursor: default;
|
122 |
+
}
|
123 |
+
|
124 |
+
.ui-button {
|
125 |
+
display: inline-block;
|
126 |
+
position: relative;
|
127 |
+
padding: 0;
|
128 |
+
line-height: normal;
|
129 |
+
margin-right: .1em;
|
130 |
+
cursor: pointer;
|
131 |
+
vertical-align: middle;
|
132 |
+
text-align: center;
|
133 |
+
overflow: visible; /* removes extra width in IE */
|
134 |
+
}
|
135 |
+
.ui-button,
|
136 |
+
.ui-button:link,
|
137 |
+
.ui-button:visited,
|
138 |
+
.ui-button:hover,
|
139 |
+
.ui-button:active {
|
140 |
+
text-decoration: none;
|
141 |
+
}
|
142 |
+
/* to make room for the icon, a width needs to be set here */
|
143 |
+
.ui-button-icon-only {
|
144 |
+
width: 2.2em;
|
145 |
+
}
|
146 |
+
/* button elements seem to need a little more width */
|
147 |
+
button.ui-button-icon-only {
|
148 |
+
width: 2.4em;
|
149 |
+
}
|
150 |
+
.ui-button-icons-only {
|
151 |
+
width: 3.4em;
|
152 |
+
}
|
153 |
+
button.ui-button-icons-only {
|
154 |
+
width: 3.7em;
|
155 |
+
}
|
156 |
+
|
157 |
+
/* button text element */
|
158 |
+
.ui-button .ui-button-text {
|
159 |
+
display: block;
|
160 |
+
line-height: normal;
|
161 |
+
}
|
162 |
+
.ui-button-text-only .ui-button-text {
|
163 |
+
padding: .4em 1em;
|
164 |
+
}
|
165 |
+
.ui-button-icon-only .ui-button-text,
|
166 |
+
.ui-button-icons-only .ui-button-text {
|
167 |
+
padding: .4em;
|
168 |
+
text-indent: -9999999px;
|
169 |
+
}
|
170 |
+
.ui-button-text-icon-primary .ui-button-text,
|
171 |
+
.ui-button-text-icons .ui-button-text {
|
172 |
+
padding: .4em 1em .4em 2.1em;
|
173 |
+
}
|
174 |
+
.ui-button-text-icon-secondary .ui-button-text,
|
175 |
+
.ui-button-text-icons .ui-button-text {
|
176 |
+
padding: .4em 2.1em .4em 1em;
|
177 |
+
}
|
178 |
+
.ui-button-text-icons .ui-button-text {
|
179 |
+
padding-left: 2.1em;
|
180 |
+
padding-right: 2.1em;
|
181 |
+
}
|
182 |
+
/* no icon support for input elements, provide padding by default */
|
183 |
+
input.ui-button {
|
184 |
+
padding: .4em 1em;
|
185 |
+
}
|
186 |
+
|
187 |
+
/* button icon element(s) */
|
188 |
+
.ui-button-icon-only .ui-icon,
|
189 |
+
.ui-button-text-icon-primary .ui-icon,
|
190 |
+
.ui-button-text-icon-secondary .ui-icon,
|
191 |
+
.ui-button-text-icons .ui-icon,
|
192 |
+
.ui-button-icons-only .ui-icon {
|
193 |
+
position: absolute;
|
194 |
+
top: 50%;
|
195 |
+
margin-top: -8px;
|
196 |
+
}
|
197 |
+
.ui-button-icon-only .ui-icon {
|
198 |
+
left: 50%;
|
199 |
+
margin-left: -8px;
|
200 |
+
}
|
201 |
+
.ui-button-text-icon-primary .ui-button-icon-primary,
|
202 |
+
.ui-button-text-icons .ui-button-icon-primary,
|
203 |
+
.ui-button-icons-only .ui-button-icon-primary {
|
204 |
+
left: .5em;
|
205 |
+
}
|
206 |
+
.ui-button-text-icon-secondary .ui-button-icon-secondary,
|
207 |
+
.ui-button-text-icons .ui-button-icon-secondary,
|
208 |
+
.ui-button-icons-only .ui-button-icon-secondary {
|
209 |
+
right: .5em;
|
210 |
+
}
|
211 |
+
|
212 |
+
/* button sets */
|
213 |
+
.ui-buttonset {
|
214 |
+
margin-right: 7px;
|
215 |
+
}
|
216 |
+
.ui-buttonset .ui-button {
|
217 |
+
margin-left: 0;
|
218 |
+
margin-right: -.3em;
|
219 |
+
}
|
220 |
+
|
221 |
+
/* workarounds */
|
222 |
+
/* reset extra padding in Firefox, see h5bp.com/l */
|
223 |
+
input.ui-button::-moz-focus-inner,
|
224 |
+
button.ui-button::-moz-focus-inner {
|
225 |
+
border: 0;
|
226 |
+
padding: 0;
|
227 |
+
}
|
228 |
+
|
229 |
+
.ui-datepicker {
|
230 |
+
width: 17em;
|
231 |
+
padding: .2em .2em 0;
|
232 |
+
display: none;
|
233 |
+
}
|
234 |
+
.ui-datepicker .ui-datepicker-header {
|
235 |
+
position: relative;
|
236 |
+
padding: .2em 0;
|
237 |
+
}
|
238 |
+
.ui-datepicker .ui-datepicker-prev,
|
239 |
+
.ui-datepicker .ui-datepicker-next {
|
240 |
+
position: absolute;
|
241 |
+
top: 2px;
|
242 |
+
width: 1.8em;
|
243 |
+
height: 1.8em;
|
244 |
+
}
|
245 |
+
.ui-datepicker .ui-datepicker-prev-hover,
|
246 |
+
.ui-datepicker .ui-datepicker-next-hover {
|
247 |
+
top: 1px;
|
248 |
+
}
|
249 |
+
.ui-datepicker .ui-datepicker-prev {
|
250 |
+
left: 2px;
|
251 |
+
}
|
252 |
+
.ui-datepicker .ui-datepicker-next {
|
253 |
+
right: 2px;
|
254 |
+
}
|
255 |
+
.ui-datepicker .ui-datepicker-prev-hover {
|
256 |
+
left: 1px;
|
257 |
+
}
|
258 |
+
.ui-datepicker .ui-datepicker-next-hover {
|
259 |
+
right: 1px;
|
260 |
+
}
|
261 |
+
.ui-datepicker .ui-datepicker-prev span,
|
262 |
+
.ui-datepicker .ui-datepicker-next span {
|
263 |
+
display: block;
|
264 |
+
position: absolute;
|
265 |
+
left: 50%;
|
266 |
+
margin-left: -8px;
|
267 |
+
top: 50%;
|
268 |
+
margin-top: -8px;
|
269 |
+
}
|
270 |
+
.ui-datepicker .ui-datepicker-title {
|
271 |
+
margin: 0 2.3em;
|
272 |
+
line-height: 1.8em;
|
273 |
+
text-align: center;
|
274 |
+
}
|
275 |
+
.ui-datepicker .ui-datepicker-title select {
|
276 |
+
font-size: 1em;
|
277 |
+
margin: 1px 0;
|
278 |
+
}
|
279 |
+
.ui-datepicker select.ui-datepicker-month-year {
|
280 |
+
width: 100%;
|
281 |
+
}
|
282 |
+
.ui-datepicker select.ui-datepicker-month,
|
283 |
+
.ui-datepicker select.ui-datepicker-year {
|
284 |
+
width: 49%;
|
285 |
+
}
|
286 |
+
.ui-datepicker table {
|
287 |
+
width: 100%;
|
288 |
+
font-size: .9em;
|
289 |
+
border-collapse: collapse;
|
290 |
+
margin: 0 0 .4em;
|
291 |
+
}
|
292 |
+
.ui-datepicker th {
|
293 |
+
padding: .7em .3em;
|
294 |
+
text-align: center;
|
295 |
+
font-weight: bold;
|
296 |
+
border: 0;
|
297 |
+
}
|
298 |
+
.ui-datepicker td {
|
299 |
+
border: 0;
|
300 |
+
padding: 1px;
|
301 |
+
}
|
302 |
+
.ui-datepicker td span,
|
303 |
+
.ui-datepicker td a {
|
304 |
+
display: block;
|
305 |
+
padding: .2em;
|
306 |
+
text-align: right;
|
307 |
+
text-decoration: none;
|
308 |
+
}
|
309 |
+
.ui-datepicker .ui-datepicker-buttonpane {
|
310 |
+
background-image: none;
|
311 |
+
margin: .7em 0 0 0;
|
312 |
+
padding: 0 .2em;
|
313 |
+
border-left: 0;
|
314 |
+
border-right: 0;
|
315 |
+
border-bottom: 0;
|
316 |
+
}
|
317 |
+
.ui-datepicker .ui-datepicker-buttonpane button {
|
318 |
+
float: right;
|
319 |
+
margin: .5em .2em .4em;
|
320 |
+
cursor: pointer;
|
321 |
+
padding: .2em .6em .3em .6em;
|
322 |
+
width: auto;
|
323 |
+
overflow: visible;
|
324 |
+
}
|
325 |
+
.ui-datepicker .ui-datepicker-buttonpane button.ui-datepicker-current {
|
326 |
+
float: left;
|
327 |
+
}
|
328 |
+
|
329 |
+
/* with multiple calendars */
|
330 |
+
.ui-datepicker.ui-datepicker-multi {
|
331 |
+
width: auto;
|
332 |
+
}
|
333 |
+
.ui-datepicker-multi .ui-datepicker-group {
|
334 |
+
float: left;
|
335 |
+
}
|
336 |
+
.ui-datepicker-multi .ui-datepicker-group table {
|
337 |
+
width: 95%;
|
338 |
+
margin: 0 auto .4em;
|
339 |
+
}
|
340 |
+
.ui-datepicker-multi-2 .ui-datepicker-group {
|
341 |
+
width: 50%;
|
342 |
+
}
|
343 |
+
.ui-datepicker-multi-3 .ui-datepicker-group {
|
344 |
+
width: 33.3%;
|
345 |
+
}
|
346 |
+
.ui-datepicker-multi-4 .ui-datepicker-group {
|
347 |
+
width: 25%;
|
348 |
+
}
|
349 |
+
.ui-datepicker-multi .ui-datepicker-group-last .ui-datepicker-header,
|
350 |
+
.ui-datepicker-multi .ui-datepicker-group-middle .ui-datepicker-header {
|
351 |
+
border-left-width: 0;
|
352 |
+
}
|
353 |
+
.ui-datepicker-multi .ui-datepicker-buttonpane {
|
354 |
+
clear: left;
|
355 |
+
}
|
356 |
+
.ui-datepicker-row-break {
|
357 |
+
clear: both;
|
358 |
+
width: 100%;
|
359 |
+
font-size: 0;
|
360 |
+
}
|
361 |
+
|
362 |
+
/* RTL support */
|
363 |
+
.ui-datepicker-rtl {
|
364 |
+
direction: rtl;
|
365 |
+
}
|
366 |
+
.ui-datepicker-rtl .ui-datepicker-prev {
|
367 |
+
right: 2px;
|
368 |
+
left: auto;
|
369 |
+
}
|
370 |
+
.ui-datepicker-rtl .ui-datepicker-next {
|
371 |
+
left: 2px;
|
372 |
+
right: auto;
|
373 |
+
}
|
374 |
+
.ui-datepicker-rtl .ui-datepicker-prev:hover {
|
375 |
+
right: 1px;
|
376 |
+
left: auto;
|
377 |
+
}
|
378 |
+
.ui-datepicker-rtl .ui-datepicker-next:hover {
|
379 |
+
left: 1px;
|
380 |
+
right: auto;
|
381 |
+
}
|
382 |
+
.ui-datepicker-rtl .ui-datepicker-buttonpane {
|
383 |
+
clear: right;
|
384 |
+
}
|
385 |
+
.ui-datepicker-rtl .ui-datepicker-buttonpane button {
|
386 |
+
float: left;
|
387 |
+
}
|
388 |
+
.ui-datepicker-rtl .ui-datepicker-buttonpane button.ui-datepicker-current,
|
389 |
+
.ui-datepicker-rtl .ui-datepicker-group {
|
390 |
+
float: right;
|
391 |
+
}
|
392 |
+
.ui-datepicker-rtl .ui-datepicker-group-last .ui-datepicker-header,
|
393 |
+
.ui-datepicker-rtl .ui-datepicker-group-middle .ui-datepicker-header {
|
394 |
+
border-right-width: 0;
|
395 |
+
border-left-width: 1px;
|
396 |
+
}
|
397 |
+
|
398 |
+
.ui-dialog {
|
399 |
+
position: absolute;
|
400 |
+
top: 0;
|
401 |
+
left: 0;
|
402 |
+
padding: .2em;
|
403 |
+
outline: 0;
|
404 |
+
}
|
405 |
+
.ui-dialog .ui-dialog-titlebar {
|
406 |
+
padding: .4em 1em;
|
407 |
+
position: relative;
|
408 |
+
}
|
409 |
+
.ui-dialog .ui-dialog-title {
|
410 |
+
float: left;
|
411 |
+
margin: .1em 0;
|
412 |
+
white-space: nowrap;
|
413 |
+
width: 90%;
|
414 |
+
overflow: hidden;
|
415 |
+
text-overflow: ellipsis;
|
416 |
+
}
|
417 |
+
.ui-dialog .ui-dialog-titlebar-close {
|
418 |
+
position: absolute;
|
419 |
+
right: .3em;
|
420 |
+
top: 50%;
|
421 |
+
width: 21px;
|
422 |
+
margin: -10px 0 0 0;
|
423 |
+
padding: 1px;
|
424 |
+
height: 20px;
|
425 |
+
}
|
426 |
+
.ui-dialog .ui-dialog-content {
|
427 |
+
position: relative;
|
428 |
+
border: 0;
|
429 |
+
padding: .5em 1em;
|
430 |
+
background: none;
|
431 |
+
overflow: auto;
|
432 |
+
}
|
433 |
+
.ui-dialog .ui-dialog-buttonpane {
|
434 |
+
text-align: left;
|
435 |
+
border-width: 1px 0 0 0;
|
436 |
+
background-image: none;
|
437 |
+
margin-top: .5em;
|
438 |
+
padding: .3em 1em .5em .4em;
|
439 |
+
}
|
440 |
+
.ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset {
|
441 |
+
float: right;
|
442 |
+
}
|
443 |
+
.ui-dialog .ui-dialog-buttonpane button {
|
444 |
+
margin: .5em .4em .5em 0;
|
445 |
+
cursor: pointer;
|
446 |
+
}
|
447 |
+
.ui-dialog .ui-resizable-se {
|
448 |
+
width: 12px;
|
449 |
+
height: 12px;
|
450 |
+
right: -5px;
|
451 |
+
bottom: -5px;
|
452 |
+
background-position: 16px 16px;
|
453 |
+
}
|
454 |
+
.ui-draggable .ui-dialog-titlebar {
|
455 |
+
cursor: move;
|
456 |
+
}
|
457 |
+
|
458 |
+
.ui-menu {
|
459 |
+
list-style: none;
|
460 |
+
padding: 2px;
|
461 |
+
margin: 0;
|
462 |
+
display: block;
|
463 |
+
outline: none;
|
464 |
+
}
|
465 |
+
.ui-menu .ui-menu {
|
466 |
+
margin-top: -3px;
|
467 |
+
position: absolute;
|
468 |
+
}
|
469 |
+
.ui-menu .ui-menu-item {
|
470 |
+
margin: 0;
|
471 |
+
padding: 0;
|
472 |
+
width: 100%;
|
473 |
+
/* support: IE10, see #8844 */
|
474 |
+
list-style-image: url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7);
|
475 |
+
}
|
476 |
+
.ui-menu .ui-menu-divider {
|
477 |
+
margin: 5px -2px 5px -2px;
|
478 |
+
height: 0;
|
479 |
+
font-size: 0;
|
480 |
+
line-height: 0;
|
481 |
+
border-width: 1px 0 0 0;
|
482 |
+
}
|
483 |
+
.ui-menu .ui-menu-item a {
|
484 |
+
text-decoration: none;
|
485 |
+
display: block;
|
486 |
+
padding: 2px .4em;
|
487 |
+
line-height: 1.5;
|
488 |
+
min-height: 0; /* support: IE7 */
|
489 |
+
font-weight: normal;
|
490 |
+
}
|
491 |
+
.ui-menu .ui-menu-item a.ui-state-focus,
|
492 |
+
.ui-menu .ui-menu-item a.ui-state-active {
|
493 |
+
font-weight: normal;
|
494 |
+
margin: -1px;
|
495 |
+
}
|
496 |
+
|
497 |
+
.ui-menu .ui-state-disabled {
|
498 |
+
font-weight: normal;
|
499 |
+
margin: .4em 0 .2em;
|
500 |
+
line-height: 1.5;
|
501 |
+
}
|
502 |
+
.ui-menu .ui-state-disabled a {
|
503 |
+
cursor: default;
|
504 |
+
}
|
505 |
+
|
506 |
+
/* icon support */
|
507 |
+
.ui-menu-icons {
|
508 |
+
position: relative;
|
509 |
+
}
|
510 |
+
.ui-menu-icons .ui-menu-item a {
|
511 |
+
position: relative;
|
512 |
+
padding-left: 2em;
|
513 |
+
}
|
514 |
+
|
515 |
+
/* left-aligned */
|
516 |
+
.ui-menu .ui-icon {
|
517 |
+
position: absolute;
|
518 |
+
top: .2em;
|
519 |
+
left: .2em;
|
520 |
+
}
|
521 |
+
|
522 |
+
/* right-aligned */
|
523 |
+
.ui-menu .ui-menu-icon {
|
524 |
+
position: static;
|
525 |
+
float: right;
|
526 |
+
}
|
527 |
+
|
528 |
+
.ui-progressbar {
|
529 |
+
height: 2em;
|
530 |
+
text-align: left;
|
531 |
+
overflow: hidden;
|
532 |
+
}
|
533 |
+
.ui-progressbar .ui-progressbar-value {
|
534 |
+
margin: -1px;
|
535 |
+
height: 100%;
|
536 |
+
}
|
537 |
+
.ui-progressbar .ui-progressbar-overlay {
|
538 |
+
background: url("images/animated-overlay.gif");
|
539 |
+
height: 100%;
|
540 |
+
filter: alpha(opacity=25);
|
541 |
+
opacity: 0.25;
|
542 |
+
}
|
543 |
+
.ui-progressbar-indeterminate .ui-progressbar-value {
|
544 |
+
background-image: none;
|
545 |
+
}
|
546 |
+
|
547 |
+
.ui-resizable {
|
548 |
+
position: relative;
|
549 |
+
}
|
550 |
+
.ui-resizable-handle {
|
551 |
+
position: absolute;
|
552 |
+
font-size: 0.1px;
|
553 |
+
display: block;
|
554 |
+
}
|
555 |
+
.ui-resizable-disabled .ui-resizable-handle,
|
556 |
+
.ui-resizable-autohide .ui-resizable-handle {
|
557 |
+
display: none;
|
558 |
+
}
|
559 |
+
.ui-resizable-n {
|
560 |
+
cursor: n-resize;
|
561 |
+
height: 7px;
|
562 |
+
width: 100%;
|
563 |
+
top: -5px;
|
564 |
+
left: 0;
|
565 |
+
}
|
566 |
+
.ui-resizable-s {
|
567 |
+
cursor: s-resize;
|
568 |
+
height: 7px;
|
569 |
+
width: 100%;
|
570 |
+
bottom: -5px;
|
571 |
+
left: 0;
|
572 |
+
}
|
573 |
+
.ui-resizable-e {
|
574 |
+
cursor: e-resize;
|
575 |
+
width: 7px;
|
576 |
+
right: -5px;
|
577 |
+
top: 0;
|
578 |
+
height: 100%;
|
579 |
+
}
|
580 |
+
.ui-resizable-w {
|
581 |
+
cursor: w-resize;
|
582 |
+
width: 7px;
|
583 |
+
left: -5px;
|
584 |
+
top: 0;
|
585 |
+
height: 100%;
|
586 |
+
}
|
587 |
+
.ui-resizable-se {
|
588 |
+
cursor: se-resize;
|
589 |
+
width: 12px;
|
590 |
+
height: 12px;
|
591 |
+
right: 1px;
|
592 |
+
bottom: 1px;
|
593 |
+
}
|
594 |
+
.ui-resizable-sw {
|
595 |
+
cursor: sw-resize;
|
596 |
+
width: 9px;
|
597 |
+
height: 9px;
|
598 |
+
left: -5px;
|
599 |
+
bottom: -5px;
|
600 |
+
}
|
601 |
+
.ui-resizable-nw {
|
602 |
+
cursor: nw-resize;
|
603 |
+
width: 9px;
|
604 |
+
height: 9px;
|
605 |
+
left: -5px;
|
606 |
+
top: -5px;
|
607 |
+
}
|
608 |
+
.ui-resizable-ne {
|
609 |
+
cursor: ne-resize;
|
610 |
+
width: 9px;
|
611 |
+
height: 9px;
|
612 |
+
right: -5px;
|
613 |
+
top: -5px;
|
614 |
+
}
|
615 |
+
|
616 |
+
.ui-selectable-helper {
|
617 |
+
position: absolute;
|
618 |
+
z-index: 100;
|
619 |
+
border: 1px dotted black;
|
620 |
+
}
|
621 |
+
|
622 |
+
.ui-slider {
|
623 |
+
position: relative;
|
624 |
+
text-align: left;
|
625 |
+
}
|
626 |
+
.ui-slider .ui-slider-handle {
|
627 |
+
position: absolute;
|
628 |
+
z-index: 2;
|
629 |
+
width: 1.2em;
|
630 |
+
height: 1.2em;
|
631 |
+
cursor: default;
|
632 |
+
}
|
633 |
+
.ui-slider .ui-slider-range {
|
634 |
+
position: absolute;
|
635 |
+
z-index: 1;
|
636 |
+
font-size: .7em;
|
637 |
+
display: block;
|
638 |
+
border: 0;
|
639 |
+
background-position: 0 0;
|
640 |
+
}
|
641 |
+
|
642 |
+
/* For IE8 - See #6727 */
|
643 |
+
.ui-slider.ui-state-disabled .ui-slider-handle,
|
644 |
+
.ui-slider.ui-state-disabled .ui-slider-range {
|
645 |
+
filter: inherit;
|
646 |
+
}
|
647 |
+
|
648 |
+
.ui-slider-horizontal {
|
649 |
+
height: .8em;
|
650 |
+
}
|
651 |
+
.ui-slider-horizontal .ui-slider-handle {
|
652 |
+
top: -.3em;
|
653 |
+
margin-left: -.6em;
|
654 |
+
}
|
655 |
+
.ui-slider-horizontal .ui-slider-range {
|
656 |
+
top: 0;
|
657 |
+
height: 100%;
|
658 |
+
}
|
659 |
+
.ui-slider-horizontal .ui-slider-range-min {
|
660 |
+
left: 0;
|
661 |
+
}
|
662 |
+
.ui-slider-horizontal .ui-slider-range-max {
|
663 |
+
right: 0;
|
664 |
+
}
|
665 |
+
|
666 |
+
.ui-slider-vertical {
|
667 |
+
width: .8em;
|
668 |
+
height: 100px;
|
669 |
+
}
|
670 |
+
.ui-slider-vertical .ui-slider-handle {
|
671 |
+
left: -.3em;
|
672 |
+
margin-left: 0;
|
673 |
+
margin-bottom: -.6em;
|
674 |
+
}
|
675 |
+
.ui-slider-vertical .ui-slider-range {
|
676 |
+
left: 0;
|
677 |
+
width: 100%;
|
678 |
+
}
|
679 |
+
.ui-slider-vertical .ui-slider-range-min {
|
680 |
+
bottom: 0;
|
681 |
+
}
|
682 |
+
.ui-slider-vertical .ui-slider-range-max {
|
683 |
+
top: 0;
|
684 |
+
}
|
685 |
+
|
686 |
+
.ui-spinner {
|
687 |
+
position: relative;
|
688 |
+
display: inline-block;
|
689 |
+
overflow: hidden;
|
690 |
+
padding: 0;
|
691 |
+
vertical-align: middle;
|
692 |
+
}
|
693 |
+
.ui-spinner-input {
|
694 |
+
border: none;
|
695 |
+
background: none;
|
696 |
+
color: inherit;
|
697 |
+
padding: 0;
|
698 |
+
margin: .2em 0;
|
699 |
+
vertical-align: middle;
|
700 |
+
margin-left: .4em;
|
701 |
+
margin-right: 22px;
|
702 |
+
}
|
703 |
+
.ui-spinner-button {
|
704 |
+
width: 16px;
|
705 |
+
height: 50%;
|
706 |
+
font-size: .5em;
|
707 |
+
padding: 0;
|
708 |
+
margin: 0;
|
709 |
+
text-align: center;
|
710 |
+
position: absolute;
|
711 |
+
cursor: default;
|
712 |
+
display: block;
|
713 |
+
overflow: hidden;
|
714 |
+
right: 0;
|
715 |
+
}
|
716 |
+
/* more specificity required here to overide default borders */
|
717 |
+
.ui-spinner a.ui-spinner-button {
|
718 |
+
border-top: none;
|
719 |
+
border-bottom: none;
|
720 |
+
border-right: none;
|
721 |
+
}
|
722 |
+
/* vertical centre icon */
|
723 |
+
.ui-spinner .ui-icon {
|
724 |
+
position: absolute;
|
725 |
+
margin-top: -8px;
|
726 |
+
top: 50%;
|
727 |
+
left: 0;
|
728 |
+
}
|
729 |
+
.ui-spinner-up {
|
730 |
+
top: 0;
|
731 |
+
}
|
732 |
+
.ui-spinner-down {
|
733 |
+
bottom: 0;
|
734 |
+
}
|
735 |
+
|
736 |
+
/* TR overrides */
|
737 |
+
.ui-spinner .ui-icon-triangle-1-s {
|
738 |
+
/* need to fix icons sprite */
|
739 |
+
background-position: -65px -16px;
|
740 |
+
}
|
741 |
+
|
742 |
+
.ui-tabs {
|
743 |
+
position: relative;/* position: relative prevents IE scroll bug (element with position: relative inside container with overflow: auto appear as "fixed") */
|
744 |
+
padding: .2em;
|
745 |
+
}
|
746 |
+
.ui-tabs .ui-tabs-nav {
|
747 |
+
margin: 0;
|
748 |
+
padding: .2em .2em 0;
|
749 |
+
}
|
750 |
+
.ui-tabs .ui-tabs-nav li {
|
751 |
+
list-style: none;
|
752 |
+
float: left;
|
753 |
+
position: relative;
|
754 |
+
top: 0;
|
755 |
+
margin: 1px .2em 0 0;
|
756 |
+
border-bottom-width: 0;
|
757 |
+
padding: 0;
|
758 |
+
white-space: nowrap;
|
759 |
+
}
|
760 |
+
.ui-tabs .ui-tabs-nav li a {
|
761 |
+
float: left;
|
762 |
+
padding: .5em 1em;
|
763 |
+
text-decoration: none;
|
764 |
+
}
|
765 |
+
.ui-tabs .ui-tabs-nav li.ui-tabs-active {
|
766 |
+
margin-bottom: -1px;
|
767 |
+
padding-bottom: 1px;
|
768 |
+
}
|
769 |
+
.ui-tabs .ui-tabs-nav li.ui-tabs-active a,
|
770 |
+
.ui-tabs .ui-tabs-nav li.ui-state-disabled a,
|
771 |
+
.ui-tabs .ui-tabs-nav li.ui-tabs-loading a {
|
772 |
+
cursor: text;
|
773 |
+
}
|
774 |
+
.ui-tabs .ui-tabs-nav li a, /* first selector in group seems obsolete, but required to overcome bug in Opera applying cursor: text overall if defined elsewhere... */
|
775 |
+
.ui-tabs-collapsible .ui-tabs-nav li.ui-tabs-active a {
|
776 |
+
cursor: pointer;
|
777 |
+
}
|
778 |
+
.ui-tabs .ui-tabs-panel {
|
779 |
+
display: block;
|
780 |
+
border-width: 0;
|
781 |
+
padding: 1em 1.4em;
|
782 |
+
background: none;
|
783 |
+
}
|
784 |
+
|
785 |
+
.ui-tooltip {
|
786 |
+
padding: 8px;
|
787 |
+
position: absolute;
|
788 |
+
z-index: 9999;
|
789 |
+
max-width: 300px;
|
790 |
+
-webkit-box-shadow: 0 0 5px #aaa;
|
791 |
+
box-shadow: 0 0 5px #aaa;
|
792 |
+
}
|
793 |
+
body .ui-tooltip {
|
794 |
+
border-width: 2px;
|
795 |
+
}
|
796 |
+
|
797 |
+
/* Component containers
|
798 |
+
----------------------------------*/
|
799 |
+
.ui-widget {
|
800 |
+
font-family: Verdana,Arial,sans-serif/*{ffDefault}*/;
|
801 |
+
font-size: 1.1em/*{fsDefault}*/;
|
802 |
+
}
|
803 |
+
.ui-widget .ui-widget {
|
804 |
+
font-size: 1em;
|
805 |
+
}
|
806 |
+
.ui-widget input,
|
807 |
+
.ui-widget select,
|
808 |
+
.ui-widget textarea,
|
809 |
+
.ui-widget button {
|
810 |
+
font-family: Verdana,Arial,sans-serif/*{ffDefault}*/;
|
811 |
+
font-size: 1em;
|
812 |
+
}
|
813 |
+
.ui-widget-content {
|
814 |
+
border: 1px solid #aaaaaa/*{borderColorContent}*/;
|
815 |
+
background: #ffffff/*{bgColorContent}*/ url(images/ui-bg_flat_75_ffffff_40x100.png)/*{bgImgUrlContent}*/ 50%/*{bgContentXPos}*/ 50%/*{bgContentYPos}*/ repeat-x/*{bgContentRepeat}*/;
|
816 |
+
color: #222222/*{fcContent}*/;
|
817 |
+
}
|
818 |
+
.ui-widget-content a {
|
819 |
+
color: #222222/*{fcContent}*/;
|
820 |
+
}
|
821 |
+
.ui-widget-header {
|
822 |
+
border: 1px solid #aaaaaa/*{borderColorHeader}*/;
|
823 |
+
background: #cccccc/*{bgColorHeader}*/ url(images/ui-bg_highlight-soft_75_cccccc_1x100.png)/*{bgImgUrlHeader}*/ 50%/*{bgHeaderXPos}*/ 50%/*{bgHeaderYPos}*/ repeat-x/*{bgHeaderRepeat}*/;
|
824 |
+
color: #222222/*{fcHeader}*/;
|
825 |
+
font-weight: bold;
|
826 |
+
}
|
827 |
+
.ui-widget-header a {
|
828 |
+
color: #222222/*{fcHeader}*/;
|
829 |
+
}
|
830 |
+
|
831 |
+
/* Interaction states
|
832 |
+
----------------------------------*/
|
833 |
+
.ui-state-default,
|
834 |
+
.ui-widget-content .ui-state-default,
|
835 |
+
.ui-widget-header .ui-state-default {
|
836 |
+
border: 1px solid #d3d3d3/*{borderColorDefault}*/;
|
837 |
+
background: #e6e6e6/*{bgColorDefault}*/ url(images/ui-bg_glass_75_e6e6e6_1x400.png)/*{bgImgUrlDefault}*/ 50%/*{bgDefaultXPos}*/ 50%/*{bgDefaultYPos}*/ repeat-x/*{bgDefaultRepeat}*/;
|
838 |
+
font-weight: normal/*{fwDefault}*/;
|
839 |
+
color: #555555/*{fcDefault}*/;
|
840 |
+
}
|
841 |
+
.ui-state-default a,
|
842 |
+
.ui-state-default a:link,
|
843 |
+
.ui-state-default a:visited {
|
844 |
+
color: #555555/*{fcDefault}*/;
|
845 |
+
text-decoration: none;
|
846 |
+
}
|
847 |
+
.ui-state-hover,
|
848 |
+
.ui-widget-content .ui-state-hover,
|
849 |
+
.ui-widget-header .ui-state-hover,
|
850 |
+
.ui-state-focus,
|
851 |
+
.ui-widget-content .ui-state-focus,
|
852 |
+
.ui-widget-header .ui-state-focus {
|
853 |
+
border: 1px solid #999999/*{borderColorHover}*/;
|
854 |
+
background: #dadada/*{bgColorHover}*/ url(images/ui-bg_glass_75_dadada_1x400.png)/*{bgImgUrlHover}*/ 50%/*{bgHoverXPos}*/ 50%/*{bgHoverYPos}*/ repeat-x/*{bgHoverRepeat}*/;
|
855 |
+
font-weight: normal/*{fwDefault}*/;
|
856 |
+
color: #212121/*{fcHover}*/;
|
857 |
+
}
|
858 |
+
.ui-state-hover a,
|
859 |
+
.ui-state-hover a:hover,
|
860 |
+
.ui-state-hover a:link,
|
861 |
+
.ui-state-hover a:visited {
|
862 |
+
color: #212121/*{fcHover}*/;
|
863 |
+
text-decoration: none;
|
864 |
+
}
|
865 |
+
.ui-state-active,
|
866 |
+
.ui-widget-content .ui-state-active,
|
867 |
+
.ui-widget-header .ui-state-active {
|
868 |
+
border: 1px solid #aaaaaa/*{borderColorActive}*/;
|
869 |
+
background: #ffffff/*{bgColorActive}*/ url(images/ui-bg_glass_65_ffffff_1x400.png)/*{bgImgUrlActive}*/ 50%/*{bgActiveXPos}*/ 50%/*{bgActiveYPos}*/ repeat-x/*{bgActiveRepeat}*/;
|
870 |
+
font-weight: normal/*{fwDefault}*/;
|
871 |
+
color: #212121/*{fcActive}*/;
|
872 |
+
}
|
873 |
+
.ui-state-active a,
|
874 |
+
.ui-state-active a:link,
|
875 |
+
.ui-state-active a:visited {
|
876 |
+
color: #212121/*{fcActive}*/;
|
877 |
+
text-decoration: none;
|
878 |
+
}
|
879 |
+
|
880 |
+
/* Interaction Cues
|
881 |
+
----------------------------------*/
|
882 |
+
.ui-state-highlight,
|
883 |
+
.ui-widget-content .ui-state-highlight,
|
884 |
+
.ui-widget-header .ui-state-highlight {
|
885 |
+
border: 1px solid #fcefa1/*{borderColorHighlight}*/;
|
886 |
+
background: #fbf9ee/*{bgColorHighlight}*/ url(images/ui-bg_glass_55_fbf9ee_1x400.png)/*{bgImgUrlHighlight}*/ 50%/*{bgHighlightXPos}*/ 50%/*{bgHighlightYPos}*/ repeat-x/*{bgHighlightRepeat}*/;
|
887 |
+
color: #363636/*{fcHighlight}*/;
|
888 |
+
}
|
889 |
+
.ui-state-highlight a,
|
890 |
+
.ui-widget-content .ui-state-highlight a,
|
891 |
+
.ui-widget-header .ui-state-highlight a {
|
892 |
+
color: #363636/*{fcHighlight}*/;
|
893 |
+
}
|
894 |
+
.ui-state-error,
|
895 |
+
.ui-widget-content .ui-state-error,
|
896 |
+
.ui-widget-header .ui-state-error {
|
897 |
+
border: 1px solid #cd0a0a/*{borderColorError}*/;
|
898 |
+
background: #fef1ec/*{bgColorError}*/ url(images/ui-bg_glass_95_fef1ec_1x400.png)/*{bgImgUrlError}*/ 50%/*{bgErrorXPos}*/ 50%/*{bgErrorYPos}*/ repeat-x/*{bgErrorRepeat}*/;
|
899 |
+
color: #cd0a0a/*{fcError}*/;
|
900 |
+
}
|
901 |
+
.ui-state-error a,
|
902 |
+
.ui-widget-content .ui-state-error a,
|
903 |
+
.ui-widget-header .ui-state-error a {
|
904 |
+
color: #cd0a0a/*{fcError}*/;
|
905 |
+
}
|
906 |
+
.ui-state-error-text,
|
907 |
+
.ui-widget-content .ui-state-error-text,
|
908 |
+
.ui-widget-header .ui-state-error-text {
|
909 |
+
color: #cd0a0a/*{fcError}*/;
|
910 |
+
}
|
911 |
+
.ui-priority-primary,
|
912 |
+
.ui-widget-content .ui-priority-primary,
|
913 |
+
.ui-widget-header .ui-priority-primary {
|
914 |
+
font-weight: bold;
|
915 |
+
}
|
916 |
+
.ui-priority-secondary,
|
917 |
+
.ui-widget-content .ui-priority-secondary,
|
918 |
+
.ui-widget-header .ui-priority-secondary {
|
919 |
+
opacity: .7;
|
920 |
+
filter:Alpha(Opacity=70);
|
921 |
+
font-weight: normal;
|
922 |
+
}
|
923 |
+
.ui-state-disabled,
|
924 |
+
.ui-widget-content .ui-state-disabled,
|
925 |
+
.ui-widget-header .ui-state-disabled {
|
926 |
+
opacity: .35;
|
927 |
+
filter:Alpha(Opacity=35);
|
928 |
+
background-image: none;
|
929 |
+
}
|
930 |
+
.ui-state-disabled .ui-icon {
|
931 |
+
filter:Alpha(Opacity=35); /* For IE8 - See #6059 */
|
932 |
+
}
|
933 |
+
|
934 |
+
/* Icons
|
935 |
+
----------------------------------*/
|
936 |
+
|
937 |
+
/* states and images */
|
938 |
+
.ui-icon {
|
939 |
+
width: 16px;
|
940 |
+
height: 16px;
|
941 |
+
}
|
942 |
+
.ui-icon,
|
943 |
+
.ui-widget-content .ui-icon {
|
944 |
+
background-image: url(images/ui-icons_222222_256x240.png)/*{iconsContent}*/;
|
945 |
+
}
|
946 |
+
.ui-widget-header .ui-icon {
|
947 |
+
background-image: url(images/ui-icons_222222_256x240.png)/*{iconsHeader}*/;
|
948 |
+
}
|
949 |
+
.ui-state-default .ui-icon {
|
950 |
+
background-image: url(images/ui-icons_888888_256x240.png)/*{iconsDefault}*/;
|
951 |
+
}
|
952 |
+
.ui-state-hover .ui-icon,
|
953 |
+
.ui-state-focus .ui-icon {
|
954 |
+
background-image: url(images/ui-icons_454545_256x240.png)/*{iconsHover}*/;
|
955 |
+
}
|
956 |
+
.ui-state-active .ui-icon {
|
957 |
+
background-image: url(images/ui-icons_454545_256x240.png)/*{iconsActive}*/;
|
958 |
+
}
|
959 |
+
.ui-state-highlight .ui-icon {
|
960 |
+
background-image: url(images/ui-icons_2e83ff_256x240.png)/*{iconsHighlight}*/;
|
961 |
+
}
|
962 |
+
.ui-state-error .ui-icon,
|
963 |
+
.ui-state-error-text .ui-icon {
|
964 |
+
background-image: url(images/ui-icons_cd0a0a_256x240.png)/*{iconsError}*/;
|
965 |
+
}
|
966 |
+
|
967 |
+
/* positioning */
|
968 |
+
.ui-icon-blank { background-position: 16px 16px; }
|
969 |
+
.ui-icon-carat-1-n { background-position: 0 0; }
|
970 |
+
.ui-icon-carat-1-ne { background-position: -16px 0; }
|
971 |
+
.ui-icon-carat-1-e { background-position: -32px 0; }
|
972 |
+
.ui-icon-carat-1-se { background-position: -48px 0; }
|
973 |
+
.ui-icon-carat-1-s { background-position: -64px 0; }
|
974 |
+
.ui-icon-carat-1-sw { background-position: -80px 0; }
|
975 |
+
.ui-icon-carat-1-w { background-position: -96px 0; }
|
976 |
+
.ui-icon-carat-1-nw { background-position: -112px 0; }
|
977 |
+
.ui-icon-carat-2-n-s { background-position: -128px 0; }
|
978 |
+
.ui-icon-carat-2-e-w { background-position: -144px 0; }
|
979 |
+
.ui-icon-triangle-1-n { background-position: 0 -16px; }
|
980 |
+
.ui-icon-triangle-1-ne { background-position: -16px -16px; }
|
981 |
+
.ui-icon-triangle-1-e { background-position: -32px -16px; }
|
982 |
+
.ui-icon-triangle-1-se { background-position: -48px -16px; }
|
983 |
+
.ui-icon-triangle-1-s { background-position: -64px -16px; }
|
984 |
+
.ui-icon-triangle-1-sw { background-position: -80px -16px; }
|
985 |
+
.ui-icon-triangle-1-w { background-position: -96px -16px; }
|
986 |
+
.ui-icon-triangle-1-nw { background-position: -112px -16px; }
|
987 |
+
.ui-icon-triangle-2-n-s { background-position: -128px -16px; }
|
988 |
+
.ui-icon-triangle-2-e-w { background-position: -144px -16px; }
|
989 |
+
.ui-icon-arrow-1-n { background-position: 0 -32px; }
|
990 |
+
.ui-icon-arrow-1-ne { background-position: -16px -32px; }
|
991 |
+
.ui-icon-arrow-1-e { background-position: -32px -32px; }
|
992 |
+
.ui-icon-arrow-1-se { background-position: -48px -32px; }
|
993 |
+
.ui-icon-arrow-1-s { background-position: -64px -32px; }
|
994 |
+
.ui-icon-arrow-1-sw { background-position: -80px -32px; }
|
995 |
+
.ui-icon-arrow-1-w { background-position: -96px -32px; }
|
996 |
+
.ui-icon-arrow-1-nw { background-position: -112px -32px; }
|
997 |
+
.ui-icon-arrow-2-n-s { background-position: -128px -32px; }
|
998 |
+
.ui-icon-arrow-2-ne-sw { background-position: -144px -32px; }
|
999 |
+
.ui-icon-arrow-2-e-w { background-position: -160px -32px; }
|
1000 |
+
.ui-icon-arrow-2-se-nw { background-position: -176px -32px; }
|
1001 |
+
.ui-icon-arrowstop-1-n { background-position: -192px -32px; }
|
1002 |
+
.ui-icon-arrowstop-1-e { background-position: -208px -32px; }
|
1003 |
+
.ui-icon-arrowstop-1-s { background-position: -224px -32px; }
|
1004 |
+
.ui-icon-arrowstop-1-w { background-position: -240px -32px; }
|
1005 |
+
.ui-icon-arrowthick-1-n { background-position: 0 -48px; }
|
1006 |
+
.ui-icon-arrowthick-1-ne { background-position: -16px -48px; }
|
1007 |
+
.ui-icon-arrowthick-1-e { background-position: -32px -48px; }
|
1008 |
+
.ui-icon-arrowthick-1-se { background-position: -48px -48px; }
|
1009 |
+
.ui-icon-arrowthick-1-s { background-position: -64px -48px; }
|
1010 |
+
.ui-icon-arrowthick-1-sw { background-position: -80px -48px; }
|
1011 |
+
.ui-icon-arrowthick-1-w { background-position: -96px -48px; }
|
1012 |
+
.ui-icon-arrowthick-1-nw { background-position: -112px -48px; }
|
1013 |
+
.ui-icon-arrowthick-2-n-s { background-position: -128px -48px; }
|
1014 |
+
.ui-icon-arrowthick-2-ne-sw { background-position: -144px -48px; }
|
1015 |
+
.ui-icon-arrowthick-2-e-w { background-position: -160px -48px; }
|
1016 |
+
.ui-icon-arrowthick-2-se-nw { background-position: -176px -48px; }
|
1017 |
+
.ui-icon-arrowthickstop-1-n { background-position: -192px -48px; }
|
1018 |
+
.ui-icon-arrowthickstop-1-e { background-position: -208px -48px; }
|
1019 |
+
.ui-icon-arrowthickstop-1-s { background-position: -224px -48px; }
|
1020 |
+
.ui-icon-arrowthickstop-1-w { background-position: -240px -48px; }
|
1021 |
+
.ui-icon-arrowreturnthick-1-w { background-position: 0 -64px; }
|
1022 |
+
.ui-icon-arrowreturnthick-1-n { background-position: -16px -64px; }
|
1023 |
+
.ui-icon-arrowreturnthick-1-e { background-position: -32px -64px; }
|
1024 |
+
.ui-icon-arrowreturnthick-1-s { background-position: -48px -64px; }
|
1025 |
+
.ui-icon-arrowreturn-1-w { background-position: -64px -64px; }
|
1026 |
+
.ui-icon-arrowreturn-1-n { background-position: -80px -64px; }
|
1027 |
+
.ui-icon-arrowreturn-1-e { background-position: -96px -64px; }
|
1028 |
+
.ui-icon-arrowreturn-1-s { background-position: -112px -64px; }
|
1029 |
+
.ui-icon-arrowrefresh-1-w { background-position: -128px -64px; }
|
1030 |
+
.ui-icon-arrowrefresh-1-n { background-position: -144px -64px; }
|
1031 |
+
.ui-icon-arrowrefresh-1-e { background-position: -160px -64px; }
|
1032 |
+
.ui-icon-arrowrefresh-1-s { background-position: -176px -64px; }
|
1033 |
+
.ui-icon-arrow-4 { background-position: 0 -80px; }
|
1034 |
+
.ui-icon-arrow-4-diag { background-position: -16px -80px; }
|
1035 |
+
.ui-icon-extlink { background-position: -32px -80px; }
|
1036 |
+
.ui-icon-newwin { background-position: -48px -80px; }
|
1037 |
+
.ui-icon-refresh { background-position: -64px -80px; }
|
1038 |
+
.ui-icon-shuffle { background-position: -80px -80px; }
|
1039 |
+
.ui-icon-transfer-e-w { background-position: -96px -80px; }
|
1040 |
+
.ui-icon-transferthick-e-w { background-position: -112px -80px; }
|
1041 |
+
.ui-icon-folder-collapsed { background-position: 0 -96px; }
|
1042 |
+
.ui-icon-folder-open { background-position: -16px -96px; }
|
1043 |
+
.ui-icon-document { background-position: -32px -96px; }
|
1044 |
+
.ui-icon-document-b { background-position: -48px -96px; }
|
1045 |
+
.ui-icon-note { background-position: -64px -96px; }
|
1046 |
+
.ui-icon-mail-closed { background-position: -80px -96px; }
|
1047 |
+
.ui-icon-mail-open { background-position: -96px -96px; }
|
1048 |
+
.ui-icon-suitcase { background-position: -112px -96px; }
|
1049 |
+
.ui-icon-comment { background-position: -128px -96px; }
|
1050 |
+
.ui-icon-person { background-position: -144px -96px; }
|
1051 |
+
.ui-icon-print { background-position: -160px -96px; }
|
1052 |
+
.ui-icon-trash { background-position: -176px -96px; }
|
1053 |
+
.ui-icon-locked { background-position: -192px -96px; }
|
1054 |
+
.ui-icon-unlocked { background-position: -208px -96px; }
|
1055 |
+
.ui-icon-bookmark { background-position: -224px -96px; }
|
1056 |
+
.ui-icon-tag { background-position: -240px -96px; }
|
1057 |
+
.ui-icon-home { background-position: 0 -112px; }
|
1058 |
+
.ui-icon-flag { background-position: -16px -112px; }
|
1059 |
+
.ui-icon-calendar { background-position: -32px -112px; }
|
1060 |
+
.ui-icon-cart { background-position: -48px -112px; }
|
1061 |
+
.ui-icon-pencil { background-position: -64px -112px; }
|
1062 |
+
.ui-icon-clock { background-position: -80px -112px; }
|
1063 |
+
.ui-icon-disk { background-position: -96px -112px; }
|
1064 |
+
.ui-icon-calculator { background-position: -112px -112px; }
|
1065 |
+
.ui-icon-zoomin { background-position: -128px -112px; }
|
1066 |
+
.ui-icon-zoomout { background-position: -144px -112px; }
|
1067 |
+
.ui-icon-search { background-position: -160px -112px; }
|
1068 |
+
.ui-icon-wrench { background-position: -176px -112px; }
|
1069 |
+
.ui-icon-gear { background-position: -192px -112px; }
|
1070 |
+
.ui-icon-heart { background-position: -208px -112px; }
|
1071 |
+
.ui-icon-star { background-position: -224px -112px; }
|
1072 |
+
.ui-icon-link { background-position: -240px -112px; }
|
1073 |
+
.ui-icon-cancel { background-position: 0 -128px; }
|
1074 |
+
.ui-icon-plus { background-position: -16px -128px; }
|
1075 |
+
.ui-icon-plusthick { background-position: -32px -128px; }
|
1076 |
+
.ui-icon-minus { background-position: -48px -128px; }
|
1077 |
+
.ui-icon-minusthick { background-position: -64px -128px; }
|
1078 |
+
.ui-icon-close { background-position: -80px -128px; }
|
1079 |
+
.ui-icon-closethick { background-position: -96px -128px; }
|
1080 |
+
.ui-icon-key { background-position: -112px -128px; }
|
1081 |
+
.ui-icon-lightbulb { background-position: -128px -128px; }
|
1082 |
+
.ui-icon-scissors { background-position: -144px -128px; }
|
1083 |
+
.ui-icon-clipboard { background-position: -160px -128px; }
|
1084 |
+
.ui-icon-copy { background-position: -176px -128px; }
|
1085 |
+
.ui-icon-contact { background-position: -192px -128px; }
|
1086 |
+
.ui-icon-image { background-position: -208px -128px; }
|
1087 |
+
.ui-icon-video { background-position: -224px -128px; }
|
1088 |
+
.ui-icon-script { background-position: -240px -128px; }
|
1089 |
+
.ui-icon-alert { background-position: 0 -144px; }
|
1090 |
+
.ui-icon-info { background-position: -16px -144px; }
|
1091 |
+
.ui-icon-notice { background-position: -32px -144px; }
|
1092 |
+
.ui-icon-help { background-position: -48px -144px; }
|
1093 |
+
.ui-icon-check { background-position: -64px -144px; }
|
1094 |
+
.ui-icon-bullet { background-position: -80px -144px; }
|
1095 |
+
.ui-icon-radio-on { background-position: -96px -144px; }
|
1096 |
+
.ui-icon-radio-off { background-position: -112px -144px; }
|
1097 |
+
.ui-icon-pin-w { background-position: -128px -144px; }
|
1098 |
+
.ui-icon-pin-s { background-position: -144px -144px; }
|
1099 |
+
.ui-icon-play { background-position: 0 -160px; }
|
1100 |
+
.ui-icon-pause { background-position: -16px -160px; }
|
1101 |
+
.ui-icon-seek-next { background-position: -32px -160px; }
|
1102 |
+
.ui-icon-seek-prev { background-position: -48px -160px; }
|
1103 |
+
.ui-icon-seek-end { background-position: -64px -160px; }
|
1104 |
+
.ui-icon-seek-start { background-position: -80px -160px; }
|
1105 |
+
/* ui-icon-seek-first is deprecated, use ui-icon-seek-start instead */
|
1106 |
+
.ui-icon-seek-first { background-position: -80px -160px; }
|
1107 |
+
.ui-icon-stop { background-position: -96px -160px; }
|
1108 |
+
.ui-icon-eject { background-position: -112px -160px; }
|
1109 |
+
.ui-icon-volume-off { background-position: -128px -160px; }
|
1110 |
+
.ui-icon-volume-on { background-position: -144px -160px; }
|
1111 |
+
.ui-icon-power { background-position: 0 -176px; }
|
1112 |
+
.ui-icon-signal-diag { background-position: -16px -176px; }
|
1113 |
+
.ui-icon-signal { background-position: -32px -176px; }
|
1114 |
+
.ui-icon-battery-0 { background-position: -48px -176px; }
|
1115 |
+
.ui-icon-battery-1 { background-position: -64px -176px; }
|
1116 |
+
.ui-icon-battery-2 { background-position: -80px -176px; }
|
1117 |
+
.ui-icon-battery-3 { background-position: -96px -176px; }
|
1118 |
+
.ui-icon-circle-plus { background-position: 0 -192px; }
|
1119 |
+
.ui-icon-circle-minus { background-position: -16px -192px; }
|
1120 |
+
.ui-icon-circle-close { background-position: -32px -192px; }
|
1121 |
+
.ui-icon-circle-triangle-e { background-position: -48px -192px; }
|
1122 |
+
.ui-icon-circle-triangle-s { background-position: -64px -192px; }
|
1123 |
+
.ui-icon-circle-triangle-w { background-position: -80px -192px; }
|
1124 |
+
.ui-icon-circle-triangle-n { background-position: -96px -192px; }
|
1125 |
+
.ui-icon-circle-arrow-e { background-position: -112px -192px; }
|
1126 |
+
.ui-icon-circle-arrow-s { background-position: -128px -192px; }
|
1127 |
+
.ui-icon-circle-arrow-w { background-position: -144px -192px; }
|
1128 |
+
.ui-icon-circle-arrow-n { background-position: -160px -192px; }
|
1129 |
+
.ui-icon-circle-zoomin { background-position: -176px -192px; }
|
1130 |
+
.ui-icon-circle-zoomout { background-position: -192px -192px; }
|
1131 |
+
.ui-icon-circle-check { background-position: -208px -192px; }
|
1132 |
+
.ui-icon-circlesmall-plus { background-position: 0 -208px; }
|
1133 |
+
.ui-icon-circlesmall-minus { background-position: -16px -208px; }
|
1134 |
+
.ui-icon-circlesmall-close { background-position: -32px -208px; }
|
1135 |
+
.ui-icon-squaresmall-plus { background-position: -48px -208px; }
|
1136 |
+
.ui-icon-squaresmall-minus { background-position: -64px -208px; }
|
1137 |
+
.ui-icon-squaresmall-close { background-position: -80px -208px; }
|
1138 |
+
.ui-icon-grip-dotted-vertical { background-position: 0 -224px; }
|
1139 |
+
.ui-icon-grip-dotted-horizontal { background-position: -16px -224px; }
|
1140 |
+
.ui-icon-grip-solid-vertical { background-position: -32px -224px; }
|
1141 |
+
.ui-icon-grip-solid-horizontal { background-position: -48px -224px; }
|
1142 |
+
.ui-icon-gripsmall-diagonal-se { background-position: -64px -224px; }
|
1143 |
+
.ui-icon-grip-diagonal-se { background-position: -80px -224px; }
|
1144 |
+
|
1145 |
+
|
1146 |
+
/* Misc visuals
|
1147 |
+
----------------------------------*/
|
1148 |
+
|
1149 |
+
/* Corner radius */
|
1150 |
+
.ui-corner-all,
|
1151 |
+
.ui-corner-top,
|
1152 |
+
.ui-corner-left,
|
1153 |
+
.ui-corner-tl {
|
1154 |
+
border-top-left-radius: 4px/*{cornerRadius}*/;
|
1155 |
+
}
|
1156 |
+
.ui-corner-all,
|
1157 |
+
.ui-corner-top,
|
1158 |
+
.ui-corner-right,
|
1159 |
+
.ui-corner-tr {
|
1160 |
+
border-top-right-radius: 4px/*{cornerRadius}*/;
|
1161 |
+
}
|
1162 |
+
.ui-corner-all,
|
1163 |
+
.ui-corner-bottom,
|
1164 |
+
.ui-corner-left,
|
1165 |
+
.ui-corner-bl {
|
1166 |
+
border-bottom-left-radius: 4px/*{cornerRadius}*/;
|
1167 |
+
}
|
1168 |
+
.ui-corner-all,
|
1169 |
+
.ui-corner-bottom,
|
1170 |
+
.ui-corner-right,
|
1171 |
+
.ui-corner-br {
|
1172 |
+
border-bottom-right-radius: 4px/*{cornerRadius}*/;
|
1173 |
+
}
|
1174 |
+
|
1175 |
+
/* Overlays */
|
1176 |
+
.ui-widget-overlay {
|
1177 |
+
background: #aaaaaa/*{bgColorOverlay}*/ url(images/ui-bg_flat_0_aaaaaa_40x100.png)/*{bgImgUrlOverlay}*/ 50%/*{bgOverlayXPos}*/ 50%/*{bgOverlayYPos}*/ repeat-x/*{bgOverlayRepeat}*/;
|
1178 |
+
opacity: .3/*{opacityOverlay}*/;
|
1179 |
+
filter: Alpha(Opacity=30)/*{opacityFilterOverlay}*/;
|
1180 |
+
}
|
1181 |
+
.ui-widget-shadow {
|
1182 |
+
margin: -8px/*{offsetTopShadow}*/ 0 0 -8px/*{offsetLeftShadow}*/;
|
1183 |
+
padding: 8px/*{thicknessShadow}*/;
|
1184 |
+
background: #aaaaaa/*{bgColorShadow}*/ url(images/ui-bg_flat_0_aaaaaa_40x100.png)/*{bgImgUrlShadow}*/ 50%/*{bgShadowXPos}*/ 50%/*{bgShadowYPos}*/ repeat-x/*{bgShadowRepeat}*/;
|
1185 |
+
opacity: .3/*{opacityShadow}*/;
|
1186 |
+
filter: Alpha(Opacity=30)/*{opacityFilterShadow}*/;
|
1187 |
+
border-radius: 8px/*{cornerRadiusShadow}*/;
|
1188 |
+
}
|
skin/frontend/base/default/js/autoship/mysubscription.js
ADDED
@@ -0,0 +1,213 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* Subscribe Pro - Subscriptions Management Extension
|
3 |
+
*
|
4 |
+
* PHP version 5
|
5 |
+
*
|
6 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
7 |
+
*
|
8 |
+
* @category SFC
|
9 |
+
* @package SFC_Autoship
|
10 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
11 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
function updateMySubscription(form) {
|
19 |
+
$j("div.change,#modal_overlay").hide();
|
20 |
+
$j("#please-wait").show();
|
21 |
+
$j(".subscription-block .messages").html("");
|
22 |
+
$j.ajax({
|
23 |
+
url: form.attr('action'),
|
24 |
+
data: form.serialize(),
|
25 |
+
method: "post",
|
26 |
+
success: function(transport){
|
27 |
+
$j("#please-wait").hide();
|
28 |
+
if(transport.match("error")){
|
29 |
+
form.parents(".subscription-block").find(".messages").html(transport);
|
30 |
+
} else {
|
31 |
+
form.parents(".subscription-block").html(transport).highlight();
|
32 |
+
}
|
33 |
+
}
|
34 |
+
});
|
35 |
+
}
|
36 |
+
|
37 |
+
function updateAllSubscriptions(form) {
|
38 |
+
$j("div.change,#modal_overlay").hide();
|
39 |
+
$j("#please-wait").show();
|
40 |
+
$j(".subscription-block .messages").html("");
|
41 |
+
$j.ajax({
|
42 |
+
url: form.attr('action'),
|
43 |
+
data: form.serialize(),
|
44 |
+
method: "post",
|
45 |
+
success: function(transport){
|
46 |
+
$j("#please-wait").hide();
|
47 |
+
if(transport.match("error")){
|
48 |
+
form.parents(".my-account").find(".messages").html(transport);
|
49 |
+
} else {
|
50 |
+
form.parents(".my-account").html(transport).highlight();
|
51 |
+
}
|
52 |
+
}
|
53 |
+
});
|
54 |
+
}
|
55 |
+
|
56 |
+
$j(document).ready(function(){
|
57 |
+
|
58 |
+
$j(".wrapper").after("<div id='modal_overlay'></div>");
|
59 |
+
$j('#modal_overlay').css({
|
60 |
+
position: "absolute",
|
61 |
+
top: 0,
|
62 |
+
left: 0,
|
63 |
+
height: $j(document).height(),
|
64 |
+
width: "100%",
|
65 |
+
zIndex: 900
|
66 |
+
}).bind('click', function(){
|
67 |
+
$j('div.change').hide();
|
68 |
+
$j(this).hide();
|
69 |
+
}).hide();
|
70 |
+
|
71 |
+
$j(".my-account").on('click', "a.change", function(e){
|
72 |
+
e.preventDefault();
|
73 |
+
var box = $j(this).parents(".block").find("div.change");
|
74 |
+
box.css({
|
75 |
+
"top": $j(window).scrollTop() + 50,
|
76 |
+
"left": ($j(window).width() / 2) - (box.width() / 2)
|
77 |
+
}).show();
|
78 |
+
$j('#modal_overlay').show();
|
79 |
+
}).on('submit', 'form.payment-form', function(e){
|
80 |
+
e.preventDefault();
|
81 |
+
var form = $j(this);
|
82 |
+
if(editMultipleSubscriptions == true) {
|
83 |
+
updateAllSubscriptions(form);
|
84 |
+
}
|
85 |
+
else {
|
86 |
+
updateMySubscription(form);
|
87 |
+
}
|
88 |
+
}).on('change', '.shipping-address-select', function(){
|
89 |
+
if($j(this).val() == ""){
|
90 |
+
$j(this).closest('.co-shipping-form').find('.shipping-new-address-form').show();
|
91 |
+
} else {
|
92 |
+
$j(this).closest('.co-shipping-form').find('.shipping-new-address-form').hide();
|
93 |
+
}
|
94 |
+
}).on('submit', 'form.co-shipping-form', function(e){
|
95 |
+
e.preventDefault();
|
96 |
+
var form = $j(this);
|
97 |
+
if(editMultipleSubscriptions == true) {
|
98 |
+
updateAllSubscriptions(form);
|
99 |
+
}
|
100 |
+
else {
|
101 |
+
updateMySubscription(form);
|
102 |
+
}
|
103 |
+
}).on('change', '.billing-address-select', function(){
|
104 |
+
if($j(this).val() == ""){
|
105 |
+
$j(this).closest('.co-billing-form').find('.billing-new-address-form').show();
|
106 |
+
} else {
|
107 |
+
$j(this).closest('.co-billing-form').find('.billing-new-address-form').hide();
|
108 |
+
}
|
109 |
+
}).on('submit', 'form.co-billing-form', function(e){
|
110 |
+
e.preventDefault();
|
111 |
+
var form = $j(this);
|
112 |
+
if(editMultipleSubscriptions == true) {
|
113 |
+
updateAllSubscriptions(form);
|
114 |
+
}
|
115 |
+
else {
|
116 |
+
updateMySubscription(form);
|
117 |
+
}
|
118 |
+
}).on("click", "a.link.more.details", function(e){
|
119 |
+
e.preventDefault();
|
120 |
+
var link = $j(this);
|
121 |
+
$j('#'+link.attr('href')).toggle();
|
122 |
+
}).on("change", "select.delivery_qty", function(e){
|
123 |
+
e.preventDefault();
|
124 |
+
var form = $j(this).closest("form");
|
125 |
+
updateMySubscription(form);
|
126 |
+
}).on("change", "select.delivery_interval", function(e){
|
127 |
+
e.preventDefault();
|
128 |
+
var form = $j(this).closest("form");
|
129 |
+
updateMySubscription(form);
|
130 |
+
}).on("click", "button.change.skip", function(e){
|
131 |
+
e.preventDefault();
|
132 |
+
var box = $j(this).parents(".subscription-block").find("div.change.skip-delivery");
|
133 |
+
box.css({
|
134 |
+
"top": $j(window).scrollTop() + 50,
|
135 |
+
"left": ($j(window).width() / 2) - (box.width() / 2)
|
136 |
+
}).show();
|
137 |
+
$j('#modal_overlay').show();
|
138 |
+
}).on("click", "a.change.cancel", function(e){
|
139 |
+
e.preventDefault();
|
140 |
+
var box = $j(this).parents(".subscription-block").find("div.change.cancel");
|
141 |
+
box.css({
|
142 |
+
"top": $j(window).scrollTop() + 50,
|
143 |
+
"left": ($j(window).width() / 2) - (box.width() / 2)
|
144 |
+
}).show();
|
145 |
+
$j('#modal_overlay').show();
|
146 |
+
}).on("click", "a.change.restart", function(e){
|
147 |
+
e.preventDefault();
|
148 |
+
var box = $j(this).parents(".subscription-block").find("div.change.restart");
|
149 |
+
box.css({
|
150 |
+
"top": $j(window).scrollTop() + 50,
|
151 |
+
"left": ($j(window).width() / 2) - (box.width() / 2)
|
152 |
+
}).show();
|
153 |
+
$j('#modal_overlay').show();
|
154 |
+
}).on("click", "button.no", function(e){
|
155 |
+
$j("div.change,#modal_overlay").hide();
|
156 |
+
}).on("click", "button.skip_yes", function(e){
|
157 |
+
e.preventDefault();
|
158 |
+
var form = $j(this);
|
159 |
+
$j("div.change,#modal_overlay").hide();
|
160 |
+
$j("#please-wait").show();
|
161 |
+
$j(".subscription-block .messages").html("");
|
162 |
+
$j.ajax({
|
163 |
+
url: form.attr('href'),
|
164 |
+
method: "get",
|
165 |
+
success: function(transport){
|
166 |
+
$j("#please-wait").hide();
|
167 |
+
if(transport.match("error")){
|
168 |
+
form.parents(".subscription-block").find(".messages").html(transport);
|
169 |
+
} else {
|
170 |
+
form.parents(".subscription-block").html(transport).highlight();
|
171 |
+
}
|
172 |
+
}
|
173 |
+
});
|
174 |
+
}).on("click", "button.cancel_yes", function(e){
|
175 |
+
e.preventDefault();
|
176 |
+
var form = $j(this);
|
177 |
+
$j("div.change,#modal_overlay").hide();
|
178 |
+
$j("#please-wait").show();
|
179 |
+
$j(".subscription-block .messages").html("");
|
180 |
+
$j.ajax({
|
181 |
+
url: form.attr('href'),
|
182 |
+
method: "get",
|
183 |
+
success: function(transport){
|
184 |
+
$j("#please-wait").hide();
|
185 |
+
if(transport.match("error")){
|
186 |
+
form.parents(".subscription-block").find(".messages").html(transport);
|
187 |
+
} else {
|
188 |
+
form.parents(".subscription-block").fadeOut(1000);
|
189 |
+
$j(".inactive-subscriptions").prepend('<div class="subscription-block">' + transport + '</div>');
|
190 |
+
}
|
191 |
+
}
|
192 |
+
});
|
193 |
+
}).on("click", "button.restart_yes", function(e){
|
194 |
+
e.preventDefault();
|
195 |
+
var form = $j(this);
|
196 |
+
$j("div.change,#modal_overlay").hide();
|
197 |
+
$j("#please-wait").show();
|
198 |
+
$j(".subscription-block .messages").html("");
|
199 |
+
$j.ajax({
|
200 |
+
url: form.attr('href'),
|
201 |
+
method: "get",
|
202 |
+
success: function(transport){
|
203 |
+
$j("#please-wait").hide();
|
204 |
+
if(transport.match("error")){
|
205 |
+
form.parents(".subscription-block").find(".messages").html(transport);
|
206 |
+
} else {
|
207 |
+
form.parents(".subscription-block").html(transport).highlight();
|
208 |
+
}
|
209 |
+
}
|
210 |
+
});
|
211 |
+
});
|
212 |
+
|
213 |
+
});
|
skin/frontend/base/default/js/autoship/newsubscription.js
ADDED
@@ -0,0 +1,166 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* Subscribe Pro - Subscriptions Management Extension
|
3 |
+
*
|
4 |
+
* PHP version 5
|
5 |
+
*
|
6 |
+
* LICENSE: This source file is subject to commercial source code license of SUBSCRIBE PRO INC.
|
7 |
+
*
|
8 |
+
* @category SFC
|
9 |
+
* @package SFC_Autoship
|
10 |
+
* @author Garth Brantley <garth@subscribepro.com>
|
11 |
+
* @author Dennis Rogers <dennis@storefrontconsulting.com>
|
12 |
+
* @copyright 2009-2014 SUBSCRIBE PRO INC. All Rights Reserved.
|
13 |
+
* @license http://www.subscribepro.com/terms-of-service/ Subscribe Pro Terms of Service
|
14 |
+
* @link http://www.subscribepro.com/
|
15 |
+
*
|
16 |
+
*/
|
17 |
+
|
18 |
+
$j = jQuery;
|
19 |
+
|
20 |
+
function updateSubscriptionData(transport) {
|
21 |
+
$j('#updated-subscription-content').append(transport);
|
22 |
+
$j('.new-subscription').find('.billing-address-block').html($j('#updated-subscription-content > .billing-address-block'));
|
23 |
+
$j('.new-subscription').find('.shipping-address-block').html($j('#updated-subscription-content > .shipping-address-block'));
|
24 |
+
$j('#updated-subscription-content > .payment-block .input-box input').val($j('.new-subscription .payment-block .input-box input').val());
|
25 |
+
$j('.new-subscription').find('.payment-block').html($j('#updated-subscription-content > .payment-block'));
|
26 |
+
$j('.new-subscription').find('.summary-block').html($j('#updated-subscription-content > .summary-block'));
|
27 |
+
$j('#updated-subscription-content').html('');
|
28 |
+
|
29 |
+
var billingForm = new VarienForm('co-billing-form-');
|
30 |
+
var billingAddressRegionUpdater = new RegionUpdater(':billing:country_id', ':billing:region', ':billing:region_id', regionsJson, undefined, ':billing:postcode');
|
31 |
+
var shippingForm = new VarienForm('co-shipping-form-');
|
32 |
+
var shippingAddressRegionUpdater = new RegionUpdater(':shipping:country_id', ':shipping:region', ':shipping:region_id', regionsJson, undefined, ':shipping:postcode');
|
33 |
+
|
34 |
+
}
|
35 |
+
|
36 |
+
$j(document).ready(function(){
|
37 |
+
|
38 |
+
$j(".wrapper").after("<div id='modal_overlay'></div>");
|
39 |
+
|
40 |
+
$j('#modal_overlay').css({
|
41 |
+
position: "absolute",
|
42 |
+
top: 0,
|
43 |
+
left: 0,
|
44 |
+
height: $j(document).height(),
|
45 |
+
width: "100%",
|
46 |
+
zIndex: 900
|
47 |
+
}).bind('click', function(){
|
48 |
+
$j('div.change,#please-wait').hide();
|
49 |
+
$j(this).hide();
|
50 |
+
}).hide();
|
51 |
+
|
52 |
+
$j(".new-subscription").on('click', 'a.change', function(e){
|
53 |
+
e.preventDefault();
|
54 |
+
var box = $j(this).parents(".block").find("div.change");
|
55 |
+
box.css({
|
56 |
+
"top": $j(window).scrollTop() + 50,
|
57 |
+
"left": ($j(window).width() / 2) - (box.width() / 2)
|
58 |
+
}).show();
|
59 |
+
$j('#modal_overlay').show();
|
60 |
+
}).on('change', '.billing-address-select', function(){
|
61 |
+
if($j(this).val() == ""){
|
62 |
+
$j('.billing-new-address-form').show();
|
63 |
+
} else {
|
64 |
+
$j('.billing-new-address-form').hide();
|
65 |
+
}
|
66 |
+
}).on('submit', '.co-billing-form', function(e){
|
67 |
+
e.preventDefault();
|
68 |
+
var form = $j(this);
|
69 |
+
$j("#please-wait").show();
|
70 |
+
$j('.billing-address-block .messages').html("");
|
71 |
+
$j.ajax({
|
72 |
+
url: form.attr('action'),
|
73 |
+
data: form.serialize(),
|
74 |
+
method: "post",
|
75 |
+
success: function(transport){
|
76 |
+
$j("#please-wait").hide();
|
77 |
+
if(transport.match("error")){
|
78 |
+
$j('.billing-address-block .messages').html(transport);
|
79 |
+
} else {
|
80 |
+
updateSubscriptionData(transport);
|
81 |
+
$j('div.change,#modal_overlay').hide();
|
82 |
+
}
|
83 |
+
}
|
84 |
+
});
|
85 |
+
}).on('submit', '#co-payment-form', function(e){
|
86 |
+
e.preventDefault();
|
87 |
+
var form = $j(this);
|
88 |
+
$j("#please-wait").show();
|
89 |
+
$j('.payment-block .messages').html("");
|
90 |
+
$j.ajax({
|
91 |
+
url: form.attr('action'),
|
92 |
+
data: form.serialize(),
|
93 |
+
method: "post",
|
94 |
+
success: function(transport){
|
95 |
+
$j("#please-wait").hide();
|
96 |
+
if(transport.match("error")){
|
97 |
+
$j('.payment-block .messages').html(transport);
|
98 |
+
} else {
|
99 |
+
updateSubscriptionData(transport);
|
100 |
+
$j('div.change,#modal_overlay').hide();
|
101 |
+
}
|
102 |
+
}
|
103 |
+
});
|
104 |
+
}).on('change', '.shipping-address-select', function(){
|
105 |
+
if($j(this).val() == ""){
|
106 |
+
$j('.shipping-new-address-form').show();
|
107 |
+
} else {
|
108 |
+
$j('.shipping-new-address-form').hide();
|
109 |
+
}
|
110 |
+
}).on('submit', '.co-shipping-form', function(e){
|
111 |
+
e.preventDefault();
|
112 |
+
var form = $j(this);
|
113 |
+
$j("#please-wait").show();
|
114 |
+
$j('.shipping-address-block .messages').html("");
|
115 |
+
$j.ajax({
|
116 |
+
url: form.attr('action'),
|
117 |
+
data: form.serialize(),
|
118 |
+
method: "post",
|
119 |
+
success: function(transport){
|
120 |
+
$j("#please-wait").hide();
|
121 |
+
if(transport.match("error")){
|
122 |
+
$j('.shipping-address-block .messages').html(transport);
|
123 |
+
} else {
|
124 |
+
updateSubscriptionData(transport);
|
125 |
+
$j('div.change,#modal_overlay').hide();
|
126 |
+
}
|
127 |
+
}
|
128 |
+
});
|
129 |
+
}).on('click', '#subscribe', function(e){
|
130 |
+
e.preventDefault();
|
131 |
+
var form = $j(this);
|
132 |
+
$j("#please-wait").show();
|
133 |
+
$j('.summary-block .messages').html("");
|
134 |
+
$j.ajax({
|
135 |
+
url: form.attr('href'),
|
136 |
+
data: {"delivery_date":$j("#delivery_date").val(), "coupon_code":$j("#coupon_code").val()},
|
137 |
+
method: "post",
|
138 |
+
success: function(transport){
|
139 |
+
$j("#please-wait").hide();
|
140 |
+
if(transport.match("error")){
|
141 |
+
$j('.summary-block .messages').html(transport);
|
142 |
+
} else {
|
143 |
+
window.location = transport;
|
144 |
+
}
|
145 |
+
}
|
146 |
+
});
|
147 |
+
});
|
148 |
+
|
149 |
+
$j("#delivery_qty,#delivery_interval").bind('change', function(e){
|
150 |
+
$j("#please-wait").show();
|
151 |
+
var form = $j("#frequency_form"); // fake form
|
152 |
+
$j.ajax({
|
153 |
+
url: form.val(),
|
154 |
+
data: {
|
155 |
+
"qty": $j("#delivery_qty").val(),
|
156 |
+
"interval": $j("#delivery_interval").val()
|
157 |
+
},
|
158 |
+
method: "post",
|
159 |
+
success: function(transport){
|
160 |
+
$j("#please-wait").hide();
|
161 |
+
updateSubscriptionData(transport);
|
162 |
+
}
|
163 |
+
});
|
164 |
+
});
|
165 |
+
|
166 |
+
});
|