-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathangular-setcontacts.html
More file actions
52 lines (49 loc) · 2.13 KB
/
angular-setcontacts.html
File metadata and controls
52 lines (49 loc) · 2.13 KB
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
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<link href="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.1/css/bootstrap-combined.min.css" rel="stylesheet">
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.10.1/jquery-ui.min.js"></script>
<script src="http://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.1/js/bootstrap.min.js"></script>
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.0.4/angular.min.js"></script>
<script src="angular-setcontacts.js"></script>
<title>Set contacts</title>
</head>
<body ng-app="myApp" ng-controller="MyCtrl">
<div class="container">
<div class="row">
<div class="span4">
<h2>Contact Form</h2>
<form id="myForm">
<label>Prénom</label>
<input type="text" name="first_name">
<label>Nom</label>
<input type="text" name="last_name">
<label>Email</label>
<input type="text" name="email">
</form>
</div>
<div class="span8">
<h2>Contact List</h2>
<table class="table table-hover">
<thead>
<tr>
<th>Prénom</th>
<th>Nom</th>
<th>Email</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="contact in contacts" set-contact="#myForm">
<td>{{contact.first_name}}</td>
<td>{{contact.last_name}}</td>
<td>{{contact.email}}</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</body>
</html>