include_php file order php include file header tpl mcolspan colspan in

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
{include_php file="order.php"}
{include file="header.tpl" mcolspan="colspan=2"}
{include file="messager.tpl"}
{if $page_text}
{$page_text}
{/if}
{if $order_id && !$smarty.request.order_id} {*** Заказ готов ***}
<br>
<div class="info-block">
<p class="info">Вашему заказу присвоен № {$order_id}, и он отправлен на e-mail адрес: <u>{$smarty.request.email_to_order|escape:"html"}</u>!</p>
</div>
<h4 class=hd-order>Заказ № {$order_id}</h4>
<table class=tbl3 border=0 cellspacing=0 cellpadding=0>
<tr>
<th></th>
<th>Артикул</th>
<th>Отдел</th>
<th>Наименование</th>
<th align=right nowrap>Цена</th>
<th align=right nowrap>Кол-во</th>
<th align=right nowrap>Стоимость</th>
</tr>
{foreach from=$cart_products item=item name=pr_cart}
<tr{cycle name=cart_z values=" class=alt,"}>
<td>{$smarty.foreach.pr_cart.iteration}.</td>
<td>{$item.product_art|default:"&nbsp;"}</td>
<td>{$departs[$item.depart_id].depart_title}</td>
<td>{$item.product_title}</td>
<td align=right nowrap>{$item.product_price}</td>
<td align=right nowrap>{$item.qty} {$units[$item.unit_id].unit_title}</td>
<td align=right nowrap>{$item.product_price*$item.qty|string_format:"%.2f"|default:"-"}</td>
</tr>
{/foreach}
{if $shipping|@is_array && $shipping|@count}
<tr{cycle name=cart_z values=" class=alt,"}>
<td colspan=2 align=right><i>Доставка:</i></td>
<td colspan=4>{$shipping_options[$smarty.session.shipping_id]}</td>
<td align=right nowrap>{$smarty.session.shipping_price|string_format:"%.2f"|default:"-"}</td>
</tr>
{/if}
<tr{cycle name=cart_z values=" class=alt,"}>
<td colspan=6 align=right><i>Итого:</i></td>
<td align=right nowrap>{$cart_total|string_format:"%.2f"}</td>
</tr>
</table>
{elseif $smarty.request.order_id} {* Просмотр любого заказа *}
<h4 class=hd-order>Заказ № {$order_s.order_id} от {$order_s.order_date}</h4>
<table class=tbl3 border=0 cellspacing=0 cellpadding=0>
<tr>
<th></th>
<th>Артикул</th>
<th>Отдел</th>
<th>Наименование</th>
<th align=right nowrap>Цена</th>
<th align=right nowrap>Кол-во</th>
<th align=right nowrap>Стоимость</th>
</tr>
{foreach from=$order_pr item=item name=order_pr}
<tr{cycle name=cart_z values=" class=alt,"}>
<td align=right>{$smarty.foreach.order_pr.iteration}</td>
<td>{$item.product_art|default:"&nbsp;"}</td>
<td>{$departs[$item.depart_id].depart_title}</td>
<td>{$item.product_title}</td>
<td align=right nowrap>{$item.product_price}</td>
<td align=right nowrap>{$item.product_qty}</td>
<td align=right nowrap>{$item.product_price*$item.product_qty|string_format:"%.2f"|default:"-"}</td>
</tr>
{/foreach}
{if $order_s.shipping_id}
<tr{cycle name=cart_z values=" class=alt,"}>
<td colspan=2 align=right><i>Доставка:</i></td>
<td colspan=4>{$shipping_options[$order_s.shipping_id]}</td>
<td align=right nowrap>{$order_s.shipping_price|string_format:"%.2f"|default:"-"}</td>
</tr>
{/if}
<tr{cycle name=cart_z values=" class=alt,"}>
<td colspan=6 align=right><i>Итого:</i></td>
<td align=right nowrap>{$order_s.order_summ+$order_s.shipping_price|string_format:"%.2f"}</td>
</tr>
</table>
<br>
{if $order_s.order_rem}
<span style="color:#060;">Примечания к заказу</span>
<div style="padding:6px; border:1px dotted #363; width:640px; margin-top:2px;">
{$order_s.order_rem}
</div>
<br>
{/if}
<a class=larr href="javascript:history.back()">назад</a>
{else}
{if $smarty.session.user}
<h4 class=hd-user>Информация о заказчике</h4>
{include file="user_show.tpl"}
{else}
<h4 class=hd-user>Авторизация</h4>
<i style="font-size:12px;">Для того, чтобы оформить заказ, Вам необходимо авторизоваться в системе.</i>
{include file="user_login.tpl" order=1}
{/if}
<hr class=ora noshade size=1>
<h4 class=hd-cart>Выбранные товары:</h4>
<table class=tbl3 border=0 cellspacing=0 cellpadding=0>
<tr>
<th></th>
<th>Артикул</th>
<th>Отдел</th>
<th>Наименование</th>
<th align=right nowrap>Цена</th>
<th align=right nowrap>Кол-во</th>
<th align=right nowrap>Стоимость</th>
</tr>
{foreach from=$cart_products item=item name=pr_cart}
<tr{cycle name=cart_z values=" class=alt,"}>
<td>{$smarty.foreach.pr_cart.iteration}.</td>
<td>{$item.product_art|default:"&nbsp;"}</td>
<td>{$departs[$item.depart_id].depart_title}</td>
<td>{$item.product_title}</td>
<td align=right nowrap>{$item.product_price}</td>
<td align=right nowrap>{$item.qty} {$units[$item.unit_id].unit_title}</td>
<td align=right nowrap>{$item.product_price*$item.qty|string_format:"%.2f"|default:"-"}</td>
</tr>
{/foreach}
{if $shipping|@is_array && $shipping|@count}
<tr{cycle name=cart_z values=" class=alt,"}>
<td colspan=2 align=right><i>Доставка:</i></td>
<td colspan=4>{$shipping_options[$smarty.session.shipping_id]}</td>
<td align=right nowrap>{$smarty.session.shipping_price|string_format:"%.2f"|default:"-"}</td>
</tr>
{/if}
<tr{cycle name=cart_z values=" class=alt,"}>
<td colspan=6 align=right><i>Итого:</i></td>
<td align=right nowrap>{$cart_total|string_format:"%.2f"}</td>
</tr>
</table>
{if $smarty.session.user}
{if $cart_products|@count}
<form action="/order/" method=get>
<h4 class=hd-note>Дополнительные примечания к заказу:</h4>
<textarea name=order_rem rows=3 cols=70 style="width:640px;"></textarea><br>
<i>Уточнение и подтверждение Вашего адреса e-mail для отправки заказа:</i>
<input type=text name="email_to_order" value="{$smarty.session.user.user_email|escape:"html"}" size=24 maxlength=128 style="width:185px;"><br>
<hr class=ora noshade size=1>
<input type=submit class=button name=submit_order value="Отправить заказ">
</form>
{/if}
{/if}
{/if}
{if $smarty.request.print != "yes"}
{include file="postmain.tpl"}
{/if}
{include file="footer.tpl"}