-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
177 lines (166 loc) · 7.5 KB
/
index.html
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
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
<!doctype html>
<!--[if lt IE 7 ]> <html lang="en" class="ie6"> <![endif]--> <!--[if IE 7 ]> <html lang="en" class="ie7"> <![endif]--> <!--[if IE 8 ]> <html lang="en" class="ie8"> <![endif]--> <!--[if IE 9 ]> <html lang="en" class="ie9"> <![endif]-->
<!--[if (gt IE 9)|!(IE)]><!--> <html lang="en"> <!--<![endif]-->
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title></title>
<meta name="description" content="">
<meta name="author" content="">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="shortcut icon" href="/favicon.ico">
<link rel="apple-touch-icon" href="/apple-touch-icon.png">
<link rel="stylesheet" href="css/bootstrap.min.css?v=2">
<link rel="stylesheet" href="css/bootstrap-responsive.min.css?v=2">
<link rel="stylesheet" href="css/smoothness/jquery-ui-1.8.22.custom.css?v=2">
<link rel="stylesheet" href="css/style.css?v=2">
<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<script type="text/x-handlebars">
{{#view App.ApplicationView}}
<a data-target=".nav-collapse" data-toggle="collapse" class="btn btn-navbar">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</a>
<a href="#" class="brand">
{{App.name}}
</a>
<div class="nav-collapse">
<ul class="nav">
<li class="active"><a {{action "home" }} href="#">Home</a></li>
</ul>
</div><!--/.nav-collapse -->
{{/view}}
</script>
</div>
</div>
</div>
<div id="container" class="container">
<!-- all app views go here -->
</div>
<script type="text/x-handlebars" data-template-name='new-invoice-button'>
<div class="row-fluid">
<a class="btn btn-large newInvoiceButton" {{action "showInvoiceDetail"}}>New Invoice »</a>
<h2>Invoices List</h2>
</div>
</script>
<script type="text/x-handlebars" data-template-name='invoices-list'>
<div class="row-fluid chart">
<div id="holder"></div>
</div>
<div class="row-fluid">
<div class="span12">
<table class="table table-striped">
<thead>
<tr><th>Sender name</th><th>Recipient name</th><th>Status</th><th>Due date</th><th>Total price</th><th></th><th></th></tr>
</thead>
<tbody>
{{#each App.invoiceController}}
<tr>
<td>{{getSenderNameById this.senderId}}</td>
<td>{{getRecipientNameById this.recipientId}}</td>
<td><span {{bindAttr class="this.status :label"}}>{{this.status}}</span></td>
<td>{{this.dueDate}}</td>
<td>$ {{this.totalPrice}}</td>
<td><a class="btn" {{action "showInvoiceDetail"}}>Show</a></td>
<td><a class="btn editInvoiceButton" {{action "showInvoiceDetail"}}>Edit</a></td>
</tr>
{{/each}}
</tbody>
</table>
</div>
</div>
</script>
<script type="text/x-handlebars" data-template-name='invoice-detail'>
<div class="row-fluid"><a href="#" class="btn backToListButton" {{action "home" }}>Back to list</a></div>
<div class="row-fluid">
<div class="senderDetail span6">
<div>{{#if editEnabled}} {{view App.TextField valueBinding="invoice.number"}} {{else}} {{invoice.number}} {{/if}}</div>
<div>{{#if editEnabled}} {{view App.TextField valueBinding="invoice.orderDate" class="datepicker"}} {{else}} {{invoice.orderDate}} {{/if}}</div>
<div>{{#if editEnabled}} {{view App.TextField valueBinding="invoice.dueDate" class="datepicker"}} {{else}} {{invoice.dueDate}} {{/if}}</div>
<div>{{#if editEnabled}} {{view App.TextField valueBinding="sender.name"}} {{else}} {{sender.name}} {{/if}}</div>
<div>{{#if editEnabled}} {{view App.TextField valueBinding="sender.address"}} {{else}} {{sender.address}} {{/if}}</div>
<div>{{sender.bankName}}</div>
<div>{{sender.accountNumber}}</div>
</div>
<div class="recipientDetail span6">
{{#if editEnabled}}
<select id="status">
<option value="draft">Draft</option>
<option value="published">Published</option>
<option value="canceled">Canceled</option>
</select>
{{/if}}
<div>{{invoice.status}}</div>
<div>{{recipient.name}}</div>
<div>{{recipient.address}}</div>
</div>
</div>
<div class="row-fluid">
<div class="span12">
<table class="table table-striped">
<thead>
<tr><th>Description</th><th>Quantity</th><th>Unit price</th><th>Vat precentage</th><th>Vat price</th><th>Total price (with VAT)</th><th></th></tr>
</thead>
<tbody>
{{#if editEnabled}}
{{#each invoice.items}}
<tr>
<td>{{view App.TextField valueBinding="description" placeholder="Description"}}</td>
<td>{{view App.TextField valueBinding="quantity"}}</td>
<td>{{view App.TextField valueBinding="unitPrice"}}</td>
<td>{{view App.TextField valueBinding="vat"}}</td>
<td>{{vatPrice}}</td>
<td>{{totalPrice}}</td>
<td><div class="deleteInvoiceItem"></div></td>
</tr>
{{/each}}
{{else}}
{{#each invoice.items}}
<tr>
<td>{{description}}</td>
<td>{{quantity}}</td>
<td>{{unitPrice}}</td>
<td>{{vat}}</td>
<td>{{vatPrice}}</td>
<td>{{totalPrice}}</td>
<td></td>
</tr>
{{/each}}
{{/if}}
{{#if editEnabled}}
<tr class="no-boder"><td><a class="btn" {{action "newInvoiceItem" context="invoice"}}>New line</a></td><td></td><td></td><td></td><td></td><td></td><td></td></tr>
{{/if}}
<tr class="no-boder"><td></td><td></td><td></td><td></td><td><strong>Total VAT</strong></td><td><strong>{{invoice.totalVatPrice}} CZK</strong></td><td></td></tr>
<tr class="no-boder"><td></td><td></td><td></td><td></td><td><strong>Total price</strong></td><td><strong>{{invoice.totalPrice}} CZK</strong></td><td></td></tr>
</tbody>
</table>
</div>
</div>
<div class="row-fluid">
<div class="span12">
</div>
</div>
<div class="row-fluid">
<div class="span12">
</div>
</div>
</script>
<!-- The missing protocol means that it will match the current protocol, either http or https. If running locally, we use the local jQuery. -->
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script>window.jQuery || document.write('<script src="js/libs/jquery-1.7.2.min.js"><\/script>')</script>
<script src="js/libs/jquery-ui-1.8.22.custom.min.js"></script>
<script src="js/libs/pubsub.js"></script>
<script src="js/libs/ember-0.9.8.1.js"></script>
<script src="js/libs/bootstrap.min.js"></script>
<script src="js/libs/raphael.js"></script>
<script src="js/app.js"></script>
</body>
</html>