Des modules ajoutés et mise en page du CSS
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 7.3 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 18 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 26 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 19 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 6.0 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 18 KiB |
@@ -0,0 +1,38 @@
|
||||
{render_form_field field="locale"}
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
{intl l="Global informations of this planified payment" d="paypal.bo.default"}
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
{render_form_field field="title"}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
{render_form_field field="description"}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
{render_form_field field="frequency_interval"}
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
{render_form_field field="frequency"}
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
{render_form_field field="cycle"}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
{render_form_field field="min_amount"}
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
{render_form_field field="max_amount"}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,11 @@
|
||||
<script>
|
||||
$('.paypal-log').on('click', function(){
|
||||
var details = $($(this).data('details'));
|
||||
|
||||
if (details.hasClass('hidden')) {
|
||||
details.removeClass('hidden');
|
||||
} else {
|
||||
details.addClass('hidden');
|
||||
}
|
||||
});
|
||||
</script>
|
||||
@@ -0,0 +1,20 @@
|
||||
<tr{if $log->getHook()} style="cursor: pointer;"{/if}>
|
||||
|
||||
<td>{format_date date=$CREATE_DATE}</td>
|
||||
<td class="paypal-log" data-details="#details-{$log->getId()}">
|
||||
{if $log->getHook()}
|
||||
{$log->getHook()} ({intl l="See webhook details" d="paypal.bo.default"})
|
||||
<div id="details-{$log->getId()}" class="hidden">
|
||||
{$log->getMessage() nofilter}
|
||||
</div>
|
||||
{else}
|
||||
{$log->getMessage() nofilter}
|
||||
{/if}
|
||||
</td>
|
||||
<td><a title="{intl l='Edit this customer'}" href="{url path='/admin/customer/update' customer_id=$log->getCustomerId()}">{$log->getCustomerId()}</a></td>
|
||||
<td><a href="{url path="/admin/order/update/%id" id=$log->getOrderId()}">{$log->getOrderId()}</a></td>
|
||||
<td>
|
||||
<strong>{$log->getHook()}</strong>
|
||||
</td>
|
||||
<td>{intl l="critical_{$log->getLevel()}" d="paypal.bo.default"}</td>
|
||||
</tr>
|
||||
@@ -0,0 +1,6 @@
|
||||
<!-- Tab menu -->
|
||||
<ul id="tabbed-menu" class="nav nav-tabs">
|
||||
<li {if $selectedMenu eq 'general'}class="active"{/if}><a href="{if $selectedMenu eq 'general'}#{else}{url path='/admin/module/paypal'}{/if}">{intl l="General configuration" d='paypal.bo.default'}</a></li>
|
||||
<li {if $selectedMenu eq 'planifiedPayment'}class="active"{/if}><a href="{if $selectedMenu eq 'planifiedPayment'}#{else}{url path='/admin/module/paypal/configure/planified'}{/if}">{intl l='Planified payment' d="paypal.bo.default"}</a></li>
|
||||
<li {if $selectedMenu eq 'log'}class="active"{/if}><a href="{if $selectedMenu eq 'log'}#{else}{url path='/admin/module/paypal/configure/log'}{/if}">{intl l='Log' d="paypal.bo.default"}</a></li>
|
||||
</ul>
|
||||
@@ -0,0 +1,236 @@
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="general-block-decorator">
|
||||
|
||||
{include file="paypal/menu/menu.html" selectedMenu="general"}
|
||||
|
||||
<div class="tab-content">
|
||||
<!-- Countries managing tab -->
|
||||
<div class="tab-pane active form-container">
|
||||
|
||||
{form name="paypal_form_configure"}
|
||||
|
||||
{if $form_error}
|
||||
<div class="alert alert-danger">{$form_error_message}</div>
|
||||
{elseif $general_error}
|
||||
<div class="alert alert-danger">
|
||||
{$general_error}
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
<form action="{url path="/admin/module/paypal/configure"}" method="post">
|
||||
{form_hidden_fields form=$form}
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
{include file = "includes/inner-form-toolbar.html"
|
||||
hide_flags = true
|
||||
page_url = "{url path='/admin/module/Paypal'}"
|
||||
close_url = "{url path='/admin/modules'}"
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div class="col-md-8">
|
||||
<h3>
|
||||
<span class="label label-primary">1</span>
|
||||
{intl l="SandBox configuration" d="paypal.bo.default"}
|
||||
<span class="glyphicon glyphicon-info-sign"></span>
|
||||
</h3>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="tips__img">
|
||||
<img src="{image file='assets/paypal_conf1.png' source="PayPal"}" alt="Payment configuration" class="img-responsive" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
|
||||
{custom_render_form_field form=$form field="sandbox"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="sandbox"} {if $sandbox}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
{render_form_field form=$form field="sandbox_login" value=$sandbox_login}
|
||||
{render_form_field form=$form field="sandbox_password" value=$sandbox_password}
|
||||
{render_form_field form=$form field="sandbox_merchant_id" value=$sandbox_merchant_id}
|
||||
|
||||
{render_form_field form=$form field="allowed_ip_list" value=$allowed_ip_list}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12 alert alert-info">
|
||||
<h4 class="text-uppercase">
|
||||
<span class="glyphicon glyphicon-info-sign"></span> {intl l="Help" d="paypal.bo.default"} : {intl l="Configuration" d="paypal.bo.default"}
|
||||
</h4>
|
||||
- {intl l="Log In on <a target='_blank' href='https://developer.paypal.com'>developer.paypal.com</a>" d="paypal.bo.default"}<br />
|
||||
- {intl l="Create REST API apps <a target='_blank' href='https://developer.paypal.com/developer/applications/'>here</a>" d="paypal.bo.default"}<br />
|
||||
- {intl l="Click on Create App" d="paypal.bo.default"}<br />
|
||||
- {intl l="Fill the fields : App Name & Sandbox developer account" d="paypal.bo.default"}<br />
|
||||
- {intl l="Click on Create App" d="paypal.bo.default"}<br />
|
||||
- {intl l="Copy & Paste the Client ID in the form below" d="paypal.bo.default"}<br />
|
||||
- {intl l="Copy & Paste the Client SECRET in the form below" d="paypal.bo.default"}<br />
|
||||
- <strong>{intl l="In SANDBOX WEBHOOKS" d="paypal.bo.default"} :</strong><br />
|
||||
- {intl l="Add Webhook" d="paypal.bo.default"}<br />
|
||||
- {url path="/module/paypal/webhook/all/events"}<br />
|
||||
- {intl l="Check 'All events'" d="paypal.bo.default"}<br />
|
||||
- <strong>{intl l="In SANDBOX APP SETTINGS" d="paypal.bo.default"} :</strong><br />
|
||||
- {intl l="Return URL" d="paypal.bo.default"}<br />
|
||||
- {navigate to="index"}<br />
|
||||
- {url path="/module/paypal/login/ok"}<br />
|
||||
- {url path="/module/paypal/agreement/ok"}<br />
|
||||
- {url path="/module/paypal/agreement/ko"}<br />
|
||||
- <label class="alert alert-danger">{intl l="This urls can take 3 hours to be taken in consideration" d="paypal.bo.default"}</label><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Accept payments" d="paypal.bo.default"} </strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Future Payments" d="paypal.bo.default"}</strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Billing agreements" d="paypal.bo.default"}</strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Invoicing" d="paypal.bo.default"} </strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Payouts" d="paypal.bo.default"} </strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="PayPal Here" d="paypal.bo.default"} </strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Log In with PayPal" d="paypal.bo.default"} </strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Personal Information" d="paypal.bo.default"}</strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Address Information" d="paypal.bo.default"}</strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Account Information" d="paypal.bo.default"}</strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Use Seamless Checkout" d="paypal.bo.default"}</strong><br />
|
||||
- {intl l="Check" d="paypal.bo.default"} <strong>{intl l="Allow the customers who haven't yet confirmed their email address with PayPal, to log in to your app" d="paypal.bo.default"}</strong><br />
|
||||
- <strong>{intl l="That's it !" d="paypal.bo.default"}</strong><br />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="col-md-8">
|
||||
<h3>
|
||||
<span class="label label-primary">2</span>
|
||||
{intl l="Production configuration" d="paypal.bo.default"}
|
||||
</h3>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="tips__img">
|
||||
<img src="{image file='assets/paypal_conf2.png' source="PayPal"}" alt="Payment configuration" class="img-responsive" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
{render_form_field form=$form field="login" value=$login}
|
||||
{render_form_field form=$form field="password" value=$password}
|
||||
{render_form_field form=$form field="merchant_id" value=$merchant_id}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12 alert alert-info">
|
||||
<h4 class="text-uppercase">
|
||||
<span class="glyphicon glyphicon-info-sign"></span> {intl l="Help" d="paypal.bo.default"} : {intl l="Configuration" d="paypal.bo.default"}
|
||||
</h4>
|
||||
- {intl l="In your PayPal page API configuration" d="paypal.bo.default"}<br />
|
||||
- {intl l="Click on the Live Button" d="paypal.bo.default"}<br />
|
||||
<img src="{image file='assets/paypal_live_button.png' source="PayPal"}" alt="Payment configuration" class="img-responsive" /><br />
|
||||
- {intl l="And configure it like the SandBox" d="paypal.bo.default"}<br />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<h3>
|
||||
<span class="label label-primary">3</span>
|
||||
{intl l="Payment configuration" d="paypal.bo.default"}
|
||||
</h3>
|
||||
|
||||
<div class="row">
|
||||
<div class="tips__img">
|
||||
<img src="{image file='assets/paypal_conf3.png' source="PayPal"}" alt="Payment configuration" class="img-responsive" />
|
||||
</div>
|
||||
<div class="col-md-12">
|
||||
{custom_render_form_field form=$form field="method_paypal"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="method_paypal"} {if $method_paypal}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
{custom_render_form_field form=$form field="method_paypal_with_in_context"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="method_paypal_with_in_context"} {if $method_paypal_with_in_context}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
{custom_render_form_field form=$form field="method_express_checkout"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="method_express_checkout"} {if $method_express_checkout}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
{custom_render_form_field form=$form field="method_credit_card"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="method_credit_card"} {if $method_credit_card}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
<div class="well well-sm alert-danger">
|
||||
<span class="glyphicon glyphicon-info-sign"></span>
|
||||
{intl d='paypal.bo.default' l='This method works only with PayPal PRO UK account. Please contact PayPal to upgrade your account if you need this service. For more informations, go <a target="_blank" href="https://developer.paypal.com/docs/integration/direct/payments/accept-credit-cards/">here</a>'}
|
||||
</div>
|
||||
|
||||
{custom_render_form_field form=$form field="method_planified_payment"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="method_planified_payment"} {if $method_planified_payment}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
<div class="well well-sm alert-danger">
|
||||
<span class="glyphicon glyphicon-info-sign"></span>
|
||||
<strong>{intl d='paypal.bo.default' l='This method use PayPal webhooks and works only in HTTPS !'}</strong>
|
||||
</div>
|
||||
|
||||
<div class="well well-sm">
|
||||
<span class="glyphicon glyphicon-info-sign"></span>
|
||||
{intl d='paypal.bo.default' l='You can add some planified payment <a href="%url">here</a>.' url={url path="/admin/module/paypal/configure/planified"}}
|
||||
</div>
|
||||
|
||||
{custom_render_form_field form=$form field="send_confirmation_message_only_if_paid"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="send_confirmation_message_only_if_paid"} {if $send_confirmation_message_only_if_paid}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
{custom_render_form_field form=$form field="send_payment_confirmation_message"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="send_payment_confirmation_message"} {if $send_payment_confirmation_message}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
{custom_render_form_field form=$form field="send_recursive_message"}
|
||||
<input type="checkbox" {form_field_attributes form=$form field="send_recursive_message"} {if $send_recursive_message}checked{/if}>
|
||||
{$label}
|
||||
{/custom_render_form_field}
|
||||
|
||||
<div class="well well-sm">
|
||||
<span class="glyphicon glyphicon-info-sign"></span>
|
||||
{intl d='paypal.bo.default' l='You can <a href="%url">edit the payment confirmation email</a> sent to the customer after a successful payment.' url={url path="/admin/configuration/messages"}}
|
||||
</div>
|
||||
|
||||
{custom_render_form_field form=$form field="minimum_amount"}
|
||||
<div class="input-group">
|
||||
<input type="text" {form_field_attributes form=$form field="minimum_amount" value=$minimum_amount}>
|
||||
<span class="input-group-addon">{currency attr='symbol'}</span>
|
||||
</div>
|
||||
{/custom_render_form_field}
|
||||
|
||||
{custom_render_form_field form=$form field="maximum_amount"}
|
||||
<div class="input-group">
|
||||
<input type="text" {form_field_attributes form=$form field="maximum_amount" value=$maximum_amount}>
|
||||
<span class="input-group-addon">{currency attr='symbol'}</span>
|
||||
</div>
|
||||
{/custom_render_form_field}
|
||||
|
||||
{render_form_field form=$form field="cart_item_count" value=$cart_item_count}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
{include file = "includes/inner-form-toolbar.html"
|
||||
hide_flags = true
|
||||
page_url = "{url path='/admin/module/Paypal'}"
|
||||
close_url = "{url path='/admin/modules'}"
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{/form}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1 @@
|
||||
{include file = "paypal/includes/paypal-log-row-js.html"}
|
||||
@@ -0,0 +1,18 @@
|
||||
<table class="table table-striped table-condensed">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{intl l='Date' d="paypal.bo.default"}</th>
|
||||
<th>{intl l='Details' d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Customer ID" d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Order ID" d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Webhook" d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Level" d="paypal.bo.default"}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
{loop name="paypal_log" type="paypal_log" backend_context=true order_id=$order_id order="date-reverse"}
|
||||
{include file = "paypal/includes/paypal-log-row.html"}
|
||||
{/loop}
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -0,0 +1,105 @@
|
||||
{extends file="admin-layout.tpl"}
|
||||
|
||||
{block name="main-content"}
|
||||
<div class="clearfix">
|
||||
<ul class="breadcrumb pull-left">
|
||||
<li>
|
||||
<a href="{url path='/admin/home'}">{intl l="Home"}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{url path='/admin/modules'}">{intl l="Modules"}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{url path='/admin/module/PayPal'}">{intl l="PayPal"}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{url path='/admin/module/paypal/configure/log'}">{intl l="Automatic PayPal logs" d="paypal.bo.default"}</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="general-block-decorator">
|
||||
|
||||
{include file="paypal/menu/menu.html" selectedMenu="log"}
|
||||
|
||||
<div class="tab-content">
|
||||
<!-- Countries managing tab -->
|
||||
<div class="tab-pane active form-container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 general-block-decorator">
|
||||
|
||||
<h3>
|
||||
<span class="label label-primary">1</span>
|
||||
{intl l="Automatic PayPal logs" d="paypal.bo.default"}
|
||||
</h3>
|
||||
|
||||
<div class="col-md-12 alert alert-info">
|
||||
<div class="col-md-8">
|
||||
<h4 class="text-uppercase">
|
||||
<span class="glyphicon glyphicon-info-sign"></span> {intl l="Help" d="paypal.bo.default"} :
|
||||
</h4>
|
||||
<div class="tips">
|
||||
{intl l="This is where we log all the transactions made with PayPal. PayPal webhooks also automatically feed these logs." d="paypal.bo.default"}
|
||||
<br />{intl l="This informations can be found directly in concerned order details." d="paypal.bo.default"}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="tips__img">
|
||||
<img src="{image file='assets/paypal_webhook.png' source="PayPal"}" alt="Payment configuration" class="img-responsive" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{$page = $smarty.get.page|default:1}
|
||||
{$limit = $smarty.get.limit|default:100}
|
||||
|
||||
<div class="form-container">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<table class="table table-striped table-condensed">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{intl l='Date' d="paypal.bo.default"}</th>
|
||||
<th>{intl l='Details' d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Customer ID" d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Order ID" d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Webhook" d="paypal.bo.default"}</th>
|
||||
<th>{intl l="Level" d="paypal.bo.default"}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
{loop name="paypal_log" type="paypal_log" backend_context=true order="date-reverse" page=$page limit=$limit}
|
||||
{include file = "paypal/includes/paypal-log-row.html"}
|
||||
{/loop}
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="100">
|
||||
{include
|
||||
file = "includes/pagination.html"
|
||||
loop_ref = "paypal_log"
|
||||
max_page_count = $limit
|
||||
page_url = {url path="/admin/module/paypal/configure/log"}
|
||||
}
|
||||
</td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
|
||||
{block name="javascript-initialization"}
|
||||
{include file = "paypal/includes/paypal-log-row-js.html"}
|
||||
{/block}
|
||||
@@ -0,0 +1,86 @@
|
||||
{extends file="admin-layout.tpl"}
|
||||
|
||||
{block name="no-return-functions"}
|
||||
{$admin_current_location = 'module'}
|
||||
{/block}
|
||||
|
||||
{block name="page-title"}{intl l='Edit planified payment' d="paypal.bo.default"}{/block}
|
||||
|
||||
{block name="main-content"}
|
||||
<div class="planified-payment edit-planified-payment">
|
||||
<div id="wrapper" class="container">
|
||||
{loop name="paypal_planified_payment" type="paypal_planified_payment" id=$planifiedPaymentId backend_context=true}
|
||||
|
||||
<nav>
|
||||
<ul class="breadcrumb">
|
||||
<li><a href="{url path='admin/home'}">{intl l='Home'}</a></li>
|
||||
<li><a href="{url path='/admin/module/paypal/configure/planified'}">{intl l='Planified payments' d='paypal.bo.default'}</a></li>
|
||||
<li>{intl l='Editing planified payment "%title"' d="paypal.bo.default" title=$planifiedPayment->getTitle()}</li>
|
||||
</ul>
|
||||
</nav>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12 general-block-decorator">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-7 title">
|
||||
{intl l='Edit planified payment %title' d="paypal.bo.default" title=$planifiedPayment->getTitle()}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ul class="nav nav-tabs" id="tabbed-menu">
|
||||
<li class="active">
|
||||
<a href="#general" data-toggle="tab">{intl l="General description" d="paypal.bo.default"}</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<div class="tab-content">
|
||||
|
||||
<div class="tab-pane fade active in" id="general">
|
||||
|
||||
<div class="form-container">
|
||||
|
||||
{form name="paypal_planified_payment_update_form"}
|
||||
<form method="POST" action="{url path="/admin/module/paypal/configure/planified/%id" id=$planifiedPayment->getId()}" {form_enctype} class="clearfix">
|
||||
|
||||
{include file="includes/inner-form-toolbar.html" hide_flags=true close_url={url path="/admin/module/paypal/configure/planified"}}
|
||||
|
||||
<input type="hidden" name="current_tab" value="general"/>
|
||||
|
||||
{* Be sure to get the planified payment ID, even if the form could not be validated *}
|
||||
<input type="hidden" name="planifiedPaymentId" value="{$planifiedPayment->getId()}" />
|
||||
|
||||
{form_hidden_fields}
|
||||
|
||||
{render_form_field field="id"}
|
||||
|
||||
{render_form_field field="success_url" value={url path="/admin/module/paypal/configure/planified"}}
|
||||
|
||||
{if $form_error}
|
||||
<div class="alert alert-danger">{$form_error_message}</div>
|
||||
{/if}
|
||||
|
||||
<div class="row">
|
||||
{include file = "paypal/form/create-or-update-planified-payment-form.html"}
|
||||
</div>
|
||||
|
||||
{include
|
||||
file="includes/inner-form-toolbar.html"
|
||||
hide_submit_buttons = false
|
||||
hide_flags = true
|
||||
|
||||
close_url={url path="/admin/module/paypal/configure/planified"}
|
||||
}
|
||||
|
||||
<small>{intl l='Planified payment created on %date_create. Last modification: %date_change' d="paypal.bo.default" date_create={format_date date=$CREATE_DATE} date_change={format_date date=$UPDATE_DATE} }</small>
|
||||
</form>
|
||||
{/form}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/loop}
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,185 @@
|
||||
{extends file="admin-layout.tpl"}
|
||||
|
||||
{block name="main-content"}
|
||||
<div class="clearfix">
|
||||
<ul class="breadcrumb pull-left">
|
||||
<li>
|
||||
<a href="{url path='/admin/home'}">{intl l="Home"}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{url path='/admin/modules'}">{intl l="Modules"}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{url path='/admin/module/PayPal'}">{intl l="PayPal"}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{url path='/admin/module/paypal/configure/planified'}">{intl l="Planified payment" d="paypal.bo.default"}</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="general-block-decorator">
|
||||
|
||||
{include file="paypal/menu/menu.html" selectedMenu="planifiedPayment"}
|
||||
|
||||
<div class="tab-content">
|
||||
<!-- Countries managing tab -->
|
||||
<div class="tab-pane active form-container">
|
||||
<div class="row">
|
||||
<div class="col-md-12 general-block-decorator">
|
||||
<h3>
|
||||
<span class="label label-primary">1</span>
|
||||
{intl l="Planified payment configuration" d="paypal.bo.default"}
|
||||
</h3>
|
||||
|
||||
<div class="col-md-12 alert alert-info">
|
||||
<div class="col-md-8">
|
||||
<h4 class="text-uppercase">
|
||||
<span class="glyphicon glyphicon-info-sign"></span> {intl l="Help" d="paypal.bo.default"} :
|
||||
</h4>
|
||||
<div class="tips">
|
||||
{intl l="This feature uses PayPal's Billing Plan and Agreement. It allows debiting a client recursively directly from PayPal." d="paypal.bo.default"}
|
||||
<br />{intl l="These planned payments will appear in step 4 of the purchase tunnel when selecting the payment method." d="paypal.bo.default"}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<div class="tips__img">
|
||||
<img src="{image file='assets/paypal_agreement.jpeg' source="PayPal"}" alt="Payment configuration" class="img-responsive" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-container">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<table class="table table-striped table-condensed">
|
||||
<caption class="clearfix">
|
||||
{intl l="List of planified payments" d="paypal.bo.default"}
|
||||
<span class="pull-right">
|
||||
<button class="btn btn-primary" title="{intl l='Add a planified payment' d='paypal.bo.default'}" href="#creation_dialog" data-toggle="modal">
|
||||
<span class="glyphicon glyphicon-plus-sign"></span> {intl l='Add a planified payment' d='paypal.bo.default'}
|
||||
</button>
|
||||
</span>
|
||||
</caption>
|
||||
|
||||
<thead>
|
||||
<tr>
|
||||
<th>
|
||||
{intl l='Title' d="paypal.bo.default"}
|
||||
</th>
|
||||
|
||||
<th>
|
||||
{intl l='Details' d="paypal.bo.default"}
|
||||
</th>
|
||||
|
||||
<th class="actions"></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
{loop name="paypal_planified_payment" type="paypal_planified_payment" backend_context=true order=$order}
|
||||
<tr>
|
||||
<td>
|
||||
<strong>{$planifiedPayment->getTitle()} ;</strong><br />
|
||||
{$planifiedPayment->getDescription()}
|
||||
</td>
|
||||
|
||||
<td>
|
||||
<strong>{intl l='Frequency interval' d="paypal.bo.default"} : </strong>{$planifiedPayment->getFrequencyInterval()}<br />
|
||||
<strong>{intl l='Frequency' d="paypal.bo.default"} : </strong>{$planifiedPayment->getFrequency()}<br />
|
||||
<strong>{intl l='Cycle' d="paypal.bo.default"} : </strong>{$planifiedPayment->getCycle()}<br />
|
||||
<strong>{intl l='Min amount' d="paypal.bo.default"} : </strong>{if $planifiedPayment->getMinAmount() > 0}{format_money number=$planifiedPayment->getMinAmount()}{else}{intl l='None' d="paypal.bo.default"}{/if}<br />
|
||||
<strong>{intl l='Max amount' d="paypal.bo.default"} : </strong>{if $planifiedPayment->getMaxAmount() > 0}{format_money number=$planifiedPayment->getMaxAmount()}{else}{intl l='None' d="paypal.bo.default"}{/if}<br />
|
||||
</td>
|
||||
|
||||
<td class="actions">
|
||||
<div class="btn-group btn-group-sm" >
|
||||
|
||||
<a class="btn btn-primary" title="{intl l='Edit this planified payment' d='paypal.bo.default'}" href="{url path="/admin/module/paypal/configure/planified/%id" id=$planifiedPayment->getId()}">
|
||||
<span class="glyphicon glyphicon-edit"></span>
|
||||
</a>
|
||||
|
||||
<a class="btn btn-danger planified-payment-delete" title="{intl l='Delete this planified payment' d='paypal.bo.default'}" href="#delete_dialog" data-id="{$planifiedPayment->getId()}" data-toggle="modal">
|
||||
<span class="glyphicon glyphicon-trash"></span>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{/loop}
|
||||
{elseloop rel="paypal_planified_payment"}
|
||||
<tr>
|
||||
<td colspan="100">
|
||||
<div class="alert alert-info">
|
||||
{intl l="No planified payment has been created yet. Click the + button to create one." d="paypal.bo.default"}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
{/elseloop}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{* Adding a new planified payment *}
|
||||
{form name="paypal_planified_payment_create_form"}
|
||||
|
||||
{* Capture the dialog body, to pass it to the generic dialog *}
|
||||
{capture "creation_dialog"}
|
||||
{form_hidden_fields}
|
||||
|
||||
{include file = "paypal/form/create-or-update-planified-payment-form.html"}
|
||||
|
||||
{render_form_field field="success_url" value={url path='/admin/module/paypal/configure/planified'}}
|
||||
{/capture}
|
||||
|
||||
{include
|
||||
file = "includes/generic-create-dialog.html"
|
||||
|
||||
dialog_id = "creation_dialog"
|
||||
dialog_title = {intl l="Create a new planified payment" d="paypal.bo.default"}
|
||||
dialog_body = {$smarty.capture.creation_dialog nofilter}
|
||||
|
||||
dialog_ok_label = {intl l="Create this planified payment" d="paypal.bo.default"}
|
||||
|
||||
form_action = {url path='/admin/module/paypal/configure/planified/create'}
|
||||
form_enctype = {form_enctype}
|
||||
form_error_message = $form_error_message
|
||||
}
|
||||
{/form}
|
||||
|
||||
{* Delete confirmation dialog *}
|
||||
{capture "delete_dialog"}
|
||||
<input type="hidden" name="planifiedPaymentId" id="planifiedPaymentId" value="" />
|
||||
{/capture}
|
||||
|
||||
{include
|
||||
file = "includes/generic-confirm-dialog.html"
|
||||
|
||||
dialog_id = "delete_dialog"
|
||||
dialog_title = {intl l="Delete planified payment" d="paypal.bo.default"}
|
||||
dialog_message = {intl l="Do you really want to delete this planified payment ?" d="paypal.bo.default"}
|
||||
|
||||
form_action = {token_url path='/admin/module/paypal/configure/planified/create/delete'}
|
||||
form_content = {$smarty.capture.delete_dialog nofilter}
|
||||
}
|
||||
{/block}
|
||||
|
||||
{block name="javascript-initialization"}
|
||||
<script>
|
||||
$(function() {
|
||||
// Set proper planified ID in delete from
|
||||
$('a.planified-payment-delete').click(function(ev) {
|
||||
$('#planifiedPaymentId').val($(this).data('id'));
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{/block}
|
||||
Reference in New Issue
Block a user