-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
163 lines (162 loc) · 7.2 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
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Contact Manager</title>
<link rel='stylesheet prefetch' href='http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css'>
<link rel="stylesheet" href="css/style.css">
</head>
<body>
<div class="container">
<div class="row">
<h2>Contacts
<button type="button" class="btn btn-success pull-right" id="createUser" data-toggle="modal" data-target="#createModal"><span class="glyphicon glyphicon-plus"></span></button>
</h2>
<div class="table-responsive">
<table class="table table-striped table-bordered table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Phone</th>
<th>Address</th>
<th> </th>
</tr>
</thead>
<tbody id="output">
<tr id="12345678901">
<td class="name">Bryce</td>
<td class="phone">123-456-7890</td>
<td class="address">29 Benesfort Dr Kitchener, ON N2N 3B4</td>
<td class="center">
<button type="button" class="updateContact btn btn-info btn-xs" data-toggle="modal" data-target="#updateModal">
<span class="glyphicon glyphicon-edit"></span>
</button>
<button type="button" class="deleteContact btn btn-danger btn-xs" data-toggle="modal" data-target="#deleteModal">
<span class="glyphicon glyphicon-remove"></span>
</button>
</td>
</tr>
</tbody>
</table>
</div><!-- /.table-responsive -->
<!-- CREATE USER MODAL -->
<div class="modal fade" id="createModal" role="dialog">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title">Add New Contact</h4>
</div><!-- /.modal-header -->
<div class="modal-body">
<form role="form">
<!-- NAME -->
<div class="form-group input-group input-group-sm">
<span class="input-group-addon" id="sizing-addon3">
<span class="glyphicon glyphicon-user"></span>
</span>
<input type="text" id="createName" class="form-control" placeholder="Name" aria-describedby="sizing-addon3">
</div><!-- /.form-group -->
<!-- PHONE -->
<div class="form-group input-group input-group-sm">
<span class="input-group-addon" id="sizing-addon3">
<span class="glyphicon glyphicon-earphone"></span>
</span>
<input type="text" id="createPhone" class="form-control" placeholder="Username" aria-describedby="sizing-addon3">
</div><!-- /.form-group -->
<!-- ADDRESS -->
<div class="form-group input-group input-group-sm">
<span class="input-group-addon" id="sizing-addon3">
<span class="glyphicon glyphicon-home"></span>
</span>
<input type="text" id="createAddress" class="form-control" placeholder="Address" aria-describedby="sizing-addon3">
</div><!-- /.form-group -->
</form>
</div><!-- /.modal-body -->
<div class="modal-footer">
<button type="button" id="createContact" class="btn btn-success" data-dismiss="modal">Add</button>
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
</div><!-- /.modal-footer -->
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div><!-- /.modal -->
<!-- UPDATE USER MODAL -->
<div class="modal fade" id="updateModal" role="dialog">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header success">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title">Update Contact</h4>
</div><!-- /.modal-header -->
<div class="modal-body">
<form role="form">
<!-- NAME -->
<div class="form-group input-group input-group-sm">
<span class="input-group-addon" id="sizing-addon3">
<span class="glyphicon glyphicon-user"></span>
</span>
<input type="text" id="updateName" class="form-control" placeholder="Name" aria-describedby="sizing-addon3">
</div><!-- /.form-group -->
<!-- PHONE -->
<div class="form-group input-group input-group-sm">
<span class="input-group-addon" id="sizing-addon3">
<span class="glyphicon glyphicon-earphone"></span>
</span>
<input type="text" id="updatePhone" class="form-control" placeholder="Phone" aria-describedby="sizing-addon3">
</div><!-- /.form-group -->
<!-- ADDRESS -->
<div class="form-group input-group input-group-sm">
<span class="input-group-addon" id="sizing-addon3">
<span class="glyphicon glyphicon-home"></span>
</span>
<input type="text" id="updateAddress" class="form-control" placeholder="Address" aria-describedby="sizing-addon3">
</div><!-- /.form-group -->
</form>
</div><!-- /.modal-body -->
<div class="modal-footer">
<button type="button" id="confirmUpdate" class="btn btn-info" data-dismiss="modal">Update</button>
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
</div><!-- /.modal-footer -->
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div><!-- /.modal -->
<!-- DELETE USER MODAL -->
<div class="modal fade" id="deleteModal" role="dialog">
<div class="modal-dialog modal-sm">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title">Delete Contact</h4>
</div><!-- /.modal-header-->
<div class="modal-body">
<p>Are you sure you want to delete {{ user }} ?</p>
</div><!-- /.modal-body -->
<div class="modal-footer">
<button type="button" id="confirmDelete" class="btn btn-danger" data-dismiss="modal">Delete</button>
<button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button>
</div><!-- /.modal-footer-->
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div><!-- /.modal -->
<!-- ERROR MODAL -->
<div class="modal fade" id="errorModal" role="dialog">
<div class="modal-dialog modal-sm">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title"></h4>
</div><!-- /.modal-header-->
<div class="modal-body">
</div><!-- /.modal-body -->
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Okay</button>
</div><!-- /.modal-footer-->
</div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->
</div><!-- /.modal -->
</div><!-- /.row -->
</div><!-- /.container -->
<script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script>
<script src='http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js'></script>
<script src="js/contactManager.js"></script>
</body>
</html>