forked from osiloke/template-bootstrap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathviewquote.tpl
156 lines (120 loc) · 7.4 KB
/
viewquote.tpl
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
<html>
<head>
<title>{$companyname} - {$id}</title>
<link rel="stylesheet" type="text/css" href="templates/{$template}/css/quote.css">
<link href="includes/jscript/css/ui.all.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="includes/jscript/jquery.js"></script>
<script type="text/javascript" src="includes/jscript/jqueryui.js"></script>
{literal}<script>
$(document).ready(function(){
$("#quoteaccept").dialog({
autoOpen: false,
resizable: false,
width: 500,
modal: true,
buttons: {'Agree & Accept': function() {
$("#quoteacceptfrm").submit();
}}
});
});
</script>{/literal}
</head>
<body bgcolor="#efefef">
{if $error}
<p style="color:#cc0000;">{$LANG.invoiceserror}</p>
{else}
<table id="wrapper" cellspacing="1" cellpadding="10" bgcolor="#cccccc" align="center"><tr><td bgcolor="#ffffff">
<table width="100%"><tr><td width="50%">
{if $logo}<p><img src="{$logo}"></p>{else}<h1>{$companyname}</h1>{/if}
</td><td width="50%" align="center">
{if $stage eq "Delivered"}
<font class="unpaid">{$LANG.quotestagedelivered}</font><br />
<form style="display:inline"><input type="button" value="{$LANG.quoteacceptbtn}" {if $accepttos}onclick="$('#quoteaccept').dialog('open')"{else}onclick="location.href='viewquote.php?id={$quoteid}&action=accept'" {/if} /></form>
<form style="display:inline" method="post" action="dl.php?type=q&id={$quoteid}"><input type="submit" value="{$LANG.quotedlpdfbtn}" /></form>
{elseif $stage eq "Accepted"}
<font class="paid">{$LANG.quotestageaccepted}</font><br />
{elseif $stage eq "On Hold"}
<font class="refunded">{$LANG.quotestageonhold}</font>
<form style="display:inline"><input type="button" value="{$LANG.quoteacceptbtn}" {if $accepttos}onclick="$('#quoteaccept').dialog('open')"{else}onclick="location.href='viewquote.php?id={$quoteid}&action=accept'" {/if} /></form>
<form style="display:inline" method="post" action="dl.php?type=q&id={$quoteid}"><input type="submit" value="{$LANG.quotedlpdfbtn}" /></form>
{elseif $stage eq "Lost"}
<font class="cancelled">{$LANG.quotestagelost}</font>
{elseif $stage eq "Dead"}
<font class="collections">{$LANG.quotestagedead}</font>
{/if}
</td></tr></table>
{if $agreetosrequired}<p align="center" class="unpaid">{$LANG.ordererroraccepttos}</p>{/if}
<table width="100%" id="invoicetoptables" cellspacing="0"><tr><td width="50%" id="invoicecontent" style="border:1px solid #cccccc">
<table width="100%" height="120" cellspacing="0" cellpadding="10" id="invoicetoptables"><tr><td id="invoicecontent" valign="top" style="border:1px solid #cccccc">
<strong>{$LANG.quoterecipient}</strong><br />
{if $clientsdetails.companyname}{$clientsdetails.companyname}<br />{/if}
{$clientsdetails.firstname} {$clientsdetails.lastname}<br />
{$clientsdetails.address1}, {$clientsdetails.address2}<br />
{$clientsdetails.city}, {$clientsdetails.state}, {$clientsdetails.postcode}<br />
{$clientsdetails.country}
</td></tr></table>
</td><td width="50%" id="invoicecontent" style="border:1px solid #cccccc;border-left:0px;">
<table width="100%" height="120" cellspacing="0" cellpadding="10" id="invoicetoptables"><tr><td id="invoicecontent" valign="top" style="border:1px solid #cccccc">
<strong>{$LANG.invoicespayto}</strong><br />
{$payto}
</td></tr></table>
</td></tr></table>
<p><strong>{$LANG.quotenumber}: {$id}</strong><br />
{$LANG.quotedatecreated}: {$datecreated}<br />
{$LANG.quotevaliduntil}: {$validuntil}<br /></p>
<p>{$proposal}</p>
<table cellspacing="0" id="invoiceitemstable" align="center">
<tr>
<td id="invoiceitemsheading" align="center" width="50%" style="border:1px solid #cccccc;border-bottom:0px;"><strong>{$LANG.invoicesdescription}</strong></td>
<td id="invoiceitemsheading" align="center" width="25%" style="border:1px solid #cccccc;border-left:0px;border-bottom:0px;"><strong>{$LANG.quotediscountheading}</strong></td>
<td id="invoiceitemsheading" align="center" width="25%" style="border:1px solid #cccccc;border-left:0px;border-bottom:0px;"><strong>{$LANG.invoicesamount}</strong></td>
</tr>
{foreach key=num item=quoteitem from=$quoteitems}
<tr bgcolor=#ffffff>
<td id="invoiceitemsrow" style="border:1px solid #cccccc;border-bottom:0px;">{$quoteitem.description}{if $quoteitem.taxed eq "true"} *{/if}</td>
<td align="center" id="invoiceitemsrow" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;">{if $quoteitem.discount>0}{$quoteitem.discount} ({$quoteitem.discountpc}%){else} - {/if}</td>
<td align="center" id="invoiceitemsrow" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;">{$quoteitem.amount}</td>
</tr>
{/foreach}
<tr>
<td id="invoiceitemsheading" style="border:1px solid #cccccc;border-bottom:0px;"><div align="right">{$LANG.invoicessubtotal}: </div></td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;"> </td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;"><strong>{$subtotal}</strong></td>
</tr>
{if $taxrate}
<tr>
<td id="invoiceitemsheading" style="border:1px solid #cccccc;border-bottom:0px;"><div align="right">{$taxrate}% {$taxname}: </div></td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;"> </td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;"><strong>{$tax}</strong></td>
</tr>
{/if}
{if $taxrate2}
<tr>
<td id="invoiceitemsheading" style="border:1px solid #cccccc;border-bottom:0px;"><div align="right">{$taxrate2}% {$taxname2}: </div></td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;"> </td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-bottom:0px;border-left:0px;"><strong>{$tax2}</strong></td>
</tr>
{/if}
<tr>
<td id="invoiceitemsheading" style="border:1px solid #cccccc;"><div align="right">{$LANG.quotelinetotal}: </div></td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-left:0px;border-left:0px;"> </td>
<td id="invoiceitemsheading" align="center" style="border:1px solid #cccccc;border-left:0px;"><strong>{$total}</strong></td>
</tr>
</table>
{if $taxrate}<p>* {$LANG.invoicestaxindicator}</p>{/if}
{if $notes}
<p>{$LANG.invoicesnotes}: {$notes}</p>
{/if}
<br /><br /><br /><br /><br />
</td></tr></table>
{/if}
<p align="center"><a href="clientarea.php">{$LANG.invoicesbacktoclientarea}</a> | <a href="dl.php?type=q&id={$quoteid}">{$LANG.quotedlpdfbtn}</a> | <a href="javascript:window.close()">{$LANG.closewindow}</a></p>
<div id="quoteaccept" title="Quote Acceptance" style="display:none;">
<form method="post" action="{$smarty.server.PHP_SELF}?id={$quoteid}&action=accept" id="quoteacceptfrm">
<p>To accept the quote, please confirm your acceptance of our terms of service which can be viewed @ <a href="{$tosurl}" target="_blank">{$tosurl}</a></p>
<p align="center"><label><input type="checkbox" name="agreetos" /> {$LANG.ordertosagreement} <a href="{$tosurl}" target="_blank">{$LANG.ordertos}</a></label></p>
<p>Please be aware that accepting a quote is considered entering into a contract and you will not be able to cancel once accepted.</p>
</form>
</div>
</body>
</html>