source: extensions/PayPalShoppingCart/admin.tpl @ 23576

Last change on this file since 23576 was 19464, checked in by plg, 12 years ago

Ability to filter the PayPal form on a list of albums

Implements the "automatic update" mechanism from Skeleton plugin.

File size: 3.2 KB
Line 
1{combine_script id='jquery.chosen' load='footer' path='themes/default/js/plugins/chosen.jquery.min.js'}
2{combine_css path="themes/default/js/plugins/chosen.css"}
3
4{footer_script}{literal}
5jQuery(document).ready(function() {
6  jQuery(".chzn-select").chosen();
7
8  function checkStatusOptions() {
9    if (jQuery("input[name=apply_to_albums]:checked").val() == "list") {
10      jQuery("#albumList").show();
11    }
12    else {
13      jQuery("#albumList").hide();
14    }
15  }
16
17  checkStatusOptions();
18
19  jQuery("input[name=apply_to_albums]").change(function() {
20    checkStatusOptions();
21  });
22});
23{/literal}{/footer_script}
24
25<div class="titrePage">
26<h2>{'PayPal Shopping Cart'|@translate}</h2>
27</div>
28
29{if $tabsheet_selected=='currency'}
30<h3>{'Currency'|@translate}</h3>
31<form method=post>
32<fieldset>
33<legend>{'Currency'|@translate}</legend>
34<br>
35<select name=currency onchange=submit()>
36{foreach from=$ppppp_array_currency item=currency_label key=currency_code}
37<option value="{$currency_code}"{if $ppppp_currency==$currency_code} selected{/if}>{$currency_label} ({$currency_code})</option>
38{/foreach}
39</select>
40<br>
41<br>
42<!--input type=submit value="{'Update data'|@translate}"-->
43</fieldset>
44</form>
45
46{elseif $tabsheet_selected=='albums'}
47<h3>{'Albums'|@translate}</h3>
48<form method=post>
49<fieldset>
50  <legend>{'Apply to albums'|@translate}</legend>
51  <p>
52    <label><input type="radio" name="apply_to_albums" value="all"{if $apply_to_albums eq 'all'} checked="checked"{/if}> <strong>{'all albums'|@translate}</strong></label>
53    <label><input type="radio" name="apply_to_albums" value="list"{if $apply_to_albums eq 'list'} checked="checked"{/if}> <strong>{'a list of albums'|@translate}</strong></label>
54  </p>
55  <p id="albumList">
56    <select data-placeholder="Select albums..." class="chzn-select" multiple style="width:700px;" name="albums[]">
57      {html_options options=$album_options selected=$album_options_selected}
58    </select>
59  </p>
60  <p class="formButtons">
61                <input type="submit" name="submit" value="{'Save Settings'|@translate}">
62        </p>
63</fieldset>
64</form>
65
66{elseif $tabsheet_selected=='size'}
67<h3>{'Size'|@translate}</h3>
68<form method=post>
69<fieldset>
70<legend>{'Append photo size'|@translate}</legend>
71<br>
72{'Size'|@translate} <input type=text name=size>
73{'Price'|@translate} <input type=text name=price>
74<br>
75<br>
76<input type=submit value="{'Append data'|@translate}">
77</fieldset>
78</form>
79<fieldset>
80<table class=table2>
81<tr class=throw>
82<th>{'Size'|@translate}</th>
83<th>{'Price'|@translate}</th>
84<th>{'Action'|@translate}</th>
85</tr>
86{foreach from=$ppppp_array_size item=ppppp_row_size name=ppppp_row_size_loop}
87<tr class="{if $smarty.foreach.ppppp_row_size_loop.index is odd}row1{else}row2{/if}">
88<td>{$ppppp_row_size.size}</td>
89<td>{$ppppp_row_size.price}</td>
90<td>
91<form method=post>
92<input type=hidden name=delete value='{$ppppp_row_size.id}'}>
93<input type=submit value="{'Delete data'|@translate}">
94</form>
95</td>
96</tr>
97{/foreach}
98</table>
99</fieldset>
100
101{else}
102<h3>{'Shipping cost'|@translate}</h3>
103<form method=post>
104<fieldset>
105<legend>{'Fixed shipping cost'|@translate}</legend>
106<br>
107<input type=text name=fixed_shipping value={$ppppp_fixed_shipping}>
108<br>
109<br>
110<input type=submit value="{'Update data'|@translate}">
111</fieldset>
112</form>
113{/if}
Note: See TracBrowser for help on using the repository browser.