overview.html 46.8 KB
Newer Older
Maikel Zweerink's avatar
Maikel Zweerink committed
1 2
<div class="row">
	<div class="col-md-12">
3
		<span data-ng-show="tokenInvalid == true">
4
			<div class="alert alert-danger" role="alert"><strong>{{'TOKEN_INVALID' | translate}}</strong> {{'OVERVIEW_TOKEN_INVALID' | translate}}</div>
5 6
		</span>
		<span data-ng-show="tokenAuth != null">
7
			<div class="alert alert-warning" role="alert"><strong>{{'OVERVIEW_TOKEN_INFO_STRONG' | translate}}</strong> {{'OVERVIEW_TOKEN_INFO' | translate}}</div>
8 9
		</span>
		<div class="row" data-ng-hide="tokenAuth != null">
Maikel Zweerink's avatar
Maikel Zweerink committed
10 11
			<div class="col-md-3">
				<div class="well whatsspy-header-box">
12
					<strong><span class="glyphicon glyphicon-filter" aria-hidden="true"></span> {{'OVERVIEW_FILTERS' | translate}}</strong>
Maikel Zweerink's avatar
Maikel Zweerink committed
13 14 15
					<br />
					<br />
					<p>
16
						<input type="text" class="form-control" id="filterPhonenumber"data-ng-model="filterPhonenumber" ng-model-options="{debounce: 1000}" placeholder="{{'OVERVIEW_FILTER_PHONE' | translate}}">
Maikel Zweerink's avatar
Maikel Zweerink committed
17 18
					</p>
					<p>
19
						<input type="text" class="form-control" id="filterName" data-ng-model="filterName"  ng-model-options="{debounce: 1000}" placeholder="{{'OVERVIEW_FILTER_NAME' | translate}}" data-ng-attr-title="{{'OVERVIEW_FILTER_NAME_TITLE' | translate}}" data-toggle="tooltip" data-placement="bottom">
20 21 22
					</p>
					<p>
						<select class="form-control" data-ng-model="filterGroup" data-ng-options="group.gid as group.name for group in groups" ></select>
Maikel Zweerink's avatar
Maikel Zweerink committed
23 24 25 26 27 28
					</p>
				</div>
			</div>	
			<div class="col-md-9">
				<div class="well whatsspy-header-box">
					<p>
29
						<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span> {{'OVERVIEW_INFO_STATUS' | translate}} <span data-ng-show="accounts.length > 0">{{'OVERVIEW_INFO_STATUS_FROM' | translate}} {{accounts.length}} {{'OVERVIEW_INFO_STATUS_CONTACTS' | translate}}</span> {{'OVERVIEW_INFO_STATUS_SINCE' | translate}} {{trackerStart | staticDatetime}}
Maikel Zweerink's avatar
Maikel Zweerink committed
30 31
					</p>
					<p>
32
						<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span> {{'OVERVIEW_INFO_PRIV' | translate}} <a href="https://maikel.pro/blog/en-whatsapp-privacy-problem-explained-in-detail/" target="_blank">{{'OVERVIEW_INFO_PRIV_LINK' | translate}}</a>.
Maikel Zweerink's avatar
Maikel Zweerink committed
33 34
					</p>
					<p>
35
						<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span> {{'OVERVIEW_INFO_LIVE' | translate}}
36 37
					</p>
					<p>
38
						<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span> {{'OVERVIEW_INFO_TIMESPAN' | translate}}
Maikel Zweerink's avatar
Maikel Zweerink committed
39 40
					</p>
					<p data-ng-show="pendingAccounts.length > 0">
41
						<span class="glyphicon glyphicon-info-sign" aria-hidden="true"></span> {{pendingAccounts.length}} {{'OVERVIEW_INFO_VERIFY' | translate}} <a data-ng-click="refreshContent()">{{'OVERVIEW_INFO_RELOAD' | translate}}</a> {{'OVERVIEW_INFO_RELOAD_2' | translate}}
Maikel Zweerink's avatar
Maikel Zweerink committed
42
					</p>
43
					<p class="whatsspy-header-options">
44 45 46 47
						<span class="btn btn-default" data-toggle="modal" data-target="#addNumber"><span class="glyphicon glyphicon-plus"></span> {{'OVERVIEW_ADD' | translate}}</span> 
						<a class="btn btn-default" href="https://maikel.pro/service/whatsspy/?importGoogleContacts&warning" target="_blank"><span class="glyphicon glyphicon-refresh"></span> {{'OVERVIEW_IMPORT' | translate}}</a> 
						<span class="btn btn-default" data-toggle="modal" data-target="#manageGroups"><span class="glyphicon glyphicon-pencil"></span> {{'OVERVIEW_MANAGE_GROUPS' | translate}}</span> 
						<span class="btn btn-default" data-toggle="modal" data-target="#managePerformance"><span class="glyphicon glyphicon-wrench"></span> {{'OVERVIEW_MANAGE_PERF' | translate}}</span> 
Maikel Zweerink's avatar
Maikel Zweerink committed
48 49 50 51 52
					</p>
				</div>
			</div>
		</div>
		<div class="whatsspy-item-wrapper">	
53 54
			<div class="panel panel-default" data-ng-repeat="number in accounts | numberFilter:filterPhonenumber:filterName:filterGroup" id="{{number.id}}">
					<div class="panel-heading whatsspy-contact-head" data-ng-class="::{'whatsspy-account-highlight': number.id == hightLightAccount}">
55
						<div class="col-md-1 col-xs-5">
56 57 58
							<span data-ng-show="number.statusmessage_privacy == false && number.profilepic_privacy == true && number.profilepic != null" class="label label-info whatsspy-label-profile-pic" title="Showing last known profile picture because the privacy setting is now contacts only / nobody" data-toggle="tooltip" data-placement="bottom" data-container="body">!</span>
							<span data-ng-show="number.statusmessage_privacy == true && number.profilepic_privacy == false && number.last_statusmessage != null" class="label label-info whatsspy-label-profile-pic" title="Showing last known status message because the privacy setting is now contacts only / nobody" data-toggle="tooltip" data-placement="bottom" data-container="body">!</span>
							<span data-ng-show="number.statusmessage_privacy == true && number.profilepic_privacy == true && number.profilepic != null && number.last_statusmessage != null" class="label label-info whatsspy-label-profile-pic" title="Showing last known status message and last known profile picture because the privacy setting is now contacts only / nobody" data-toggle="tooltip" data-placement="bottom" data-container="body">!</span>
59
							<img data-ng-cloak class="img-responsive img-rounded whatsspy-profile-pic" title="Indexed image at {{number.profilepic_updated | staticDatetime}}" data-ng-show="number.profilepic != null" data-ng-src="{{(number.profilepic != null) && getImageURL(number.profilepic) || ''}}" />
60
							<img data-ng-cloak class="img-responsive img-rounded whatsspy-profile-pic" data-ng-show="number.profilepic == null" src="images/profile_pic_placeholder.png" />
Maikel Zweerink's avatar
Maikel Zweerink committed
61
						</div>
62 63 64 65 66 67 68 69 70 71 72
						<div class="col-md-11">
							<div class="row">
								<div class="col-md-6 hidden-xs">
									<h3>{{number.name | emptyName}} <small class="contact_status">{{number.last_statusmessage}}</small></h3>
								</div>
								<!-- Responsive small setup -->
								<div class="col-md-6 visible-xs">
									<h3>{{number.name | emptyName}} <br /><small class="contact_status">{{number.last_statusmessage}}</small></h3>
								</div>
								<!-- END responsive small setup -->
								<div class="col-md-3 hidden-xs whatsspy-contact-options">
73
									<a class="btn btn-default" data-ng-click="toggleContactPanel(number);" data-ng-hide="tokenAuth != null">
74 75
										<span data-ng-show="accountData[number.id].showPanel != true"><span class="glyphicon glyphicon-zoom-in" aria-hidden="true"></span> {{'OVERVIEW_EXPAND' | translate}}</span>
										<span data-ng-show="accountData[number.id].showPanel == true"><span class="glyphicon glyphicon-zoom-out" aria-hidden="true"></span> {{'OVERVIEW_COLLAPSE' | translate}}</span>
76
									</a>
77
									<a class="btn btn-default" data-ng-hide="tokenAuth != null" data-ng-click="editNameModal(number);"><span class="glyphicon glyphicon-pencil" ></span> {{'OVERVIEW_EDIT' | translate}}</a>
78 79 80 81 82 83 84 85 86 87
								</div>
								<div class="col-md-3 hidden-xs whatsspy-contact-phone">
									<div class="input-group">
			            				<span class="input-group-addon">+</span>  
						    			<input type="text" class="form-control" data-ng-value="::number.id">
						    		</div>
								</div>
								<!-- Responsive small setup -->
								<div class="col-xs-12 visible-xs whatsspy-contact-phone-xs">
									<a class="btn btn-default" data-ng-click="toggleContactPanel(number);">
88 89
										<span data-ng-show="accountData[number.id].showPanel != true"><span class="glyphicon glyphicon-zoom-in" aria-hidden="true"></span> {{'OVERVIEW_EXPAND' | translate}}</span>
										<span data-ng-show="accountData[number.id].showPanel == true"><span class="glyphicon glyphicon-zoom-out" aria-hidden="true"></span> {{'OVERVIEW_COLLAPSE' | translate}}</span>
90
									</a>
91
									<a class="btn btn-default" data-ng-click="editNameModal(number);"><span class="glyphicon glyphicon-pencil" ></span> {{'OVERVIEW_EDIT' | translate}}</a>
92 93 94 95 96 97 98 99 100
									<div class="input-group">
			            				<span class="input-group-addon">+</span>  
						    			<input type="text" class="form-control" data-ng-value="::number.id">
						    		</div>
								</div>
								<!-- END responsive small setup -->
							</div>
							<div class="row">
								<div class="col-md-9 hidden-xs">
101 102
									<span data-ng-show="number.since != null" class="label label-info">{{'OVERVIEW_CONTACT_SINCE' | translate}} {{::number.since | staticDatetime}}</span>
									<span data-ng-show="number.latest_online != null" class="label label-info whatsspy-label-last-seen" title="{{number.latest_online | staticDatetime}}">{{'OVERVIEW_CONTACT_LASTSEEN' | translate}} <span am-time-ago="number.latest_online"></span></span>
103
									<span data-ng-repeat="group in number.groups">
104
										<span class="label label-default">{{getGroupName(group.gid)}}</span>
105 106 107 108
									</span>
								</div>
								<!-- Responsive small setup -->
								<div class="col-md-9 visible-xs">
109 110
									<span data-ng-show="number.since != null" class="label label-info whatsspy-label-notifications">{{'OVERVIEW_CONTACT_SINCE' | translate}} {{::number.since | staticDatetime}}</span>
									<span data-ng-show="number.latest_online != null" class="label label-info whatsspy-label-notifications" title="{{number.latest_online | staticDatetime}}">{{'OVERVIEW_CONTACT_LASTSEEN' | translate}} <span am-time-ago="number.latest_online"></span></span>
111 112 113 114 115 116
									<span data-ng-repeat="group in number.groups">
										<span class="label label-default whatsspy-label-notifications">{{getGroupName(group.gid)}}</span> 
									</span>
								</div>
								<!-- END responsive small setup -->
								<div class="col-md-3 whatsspy-contact-phone">
117
					    			<span data-ng-show="number.notify_status == true || number.notify_statusmsg == true || number.notify_profilepic == true || number.notify_privacy == true" class="label label-danger whatsspy-label-notifications" title="notifications enabled">
118
					    				{{'OVERVIEW_CONTACT_NOTIF' | translate}}
119 120
					    			</span>
									<span data-ng-show="number.read_only_token" class="label label-warning whatsspy-label-notifications whatsspy-label-share" title="sharing enabled" data-ng-click="copyToClipboard(getTokenUrl('user', number.read_only_token))">
121
					    				{{'OVERVIEW_CONTACT_SHARING' | translate}}
122
					    			</span>
123 124
								</div>
							</div>
Maikel Zweerink's avatar
Maikel Zweerink committed
125
						</div>
126
						<div class="clear"></div>
Maikel Zweerink's avatar
Maikel Zweerink committed
127
					</div>
128
					<div class="panel-body" data-ng-show="accountData[number.id].showPanel == true">
129
						<span data-ng-show="accountData[number.id].status.length < 1">
130
							<center>{{'OVERVIEW_NO_INFO' | translate}}</center>
Maikel Zweerink's avatar
Maikel Zweerink committed
131
						</span>
132
						<span data-ng-show="accountData[number.id].status.length > 0">
Maikel Zweerink's avatar
Maikel Zweerink committed
133
							<!-- Timeline information -->
134
							<div data-ng-show="accountData[number.id] == null" class="whatsspy-lazy-load-warning"> {{'OVERVIEW_CLICK_LOAD' | translate}}</div>
135 136
							<div data-ng-show="accountData[number.id].timelineLoaded" class="whatsspy-number-timeline">
								<vis-timeline data="accountData[number.id].timelineData" options="timelineOptions" events="graphEvents"></vis-timeline>
Maikel Zweerink's avatar
Maikel Zweerink committed
137
							</div>
138
							<div class="whatsspy-passive-timeline" data-ng-show="accountData[number.id].timelineLoaded != true && accountData[number.id].status != null">
139
								<button class="btn btn-default"  data-ng-click="loadTimelineManually(number)">{{'OVERVIEW_CLICK_LOAD_TIMELINE' | translate}}</button>
Maikel Zweerink's avatar
Maikel Zweerink committed
140 141 142 143
							</div>
							<!-- Additional information -->
							<div class="row">
								<div class="col-md-8">
144
									<h4>{{'OVERVIEW_CONTACT_H_ANALYTICS' | translate}}</h4>
Maikel Zweerink's avatar
Maikel Zweerink committed
145 146 147
									<div role="tabpanel">
									  <!-- Nav tabs -->
									  <ul class="nav nav-tabs" role="tablist">
148 149 150 151 152
									    <li role="presentation" class="active" ><a aria-controls="overview" role="tab" data-toggle="tab" data-target="#overview-{{number.id}}">{{'OVERVIEW_CONTACT_ANALYTICS_OVERVIEW' | translate}}</a></li>
									    <li role="presentation"><a aria-controls="opened-overview" role="tab" data-toggle="tab" data-target="#opened-overview-{{number.id}}">{{'OVERVIEW_CONTACT_ANALYTICS_OPENOVERVIEW' | translate}}</a></li>
									    <li role="presentation"><a aria-controls="time-overview" role="tab" data-toggle="tab" data-target="#time-overview-{{number.id}}">{{'OVERVIEW_CONTACT_ANALYTICS_TIME_OVERVIEW' | translate}}</a></li>
									    <li role="presentation"><a aria-controls="statusmessages" role="tab" data-toggle="tab" data-target="#statusmessages-{{number.id}}">{{'OVERVIEW_CONTACT_ANALYTICS_STATUS' | translate}} <span data-ng-show="accountData[number.id].statusmessages.length > 0" class="badge">{{accountData[number.id].statusmessages.length}}</span></a></li>
									    <li role="presentation"><a aria-controls="pictures" role="tab" data-toggle="tab" data-target="#pictures-{{number.id}}">{{'OVERVIEW_CONTACT_ANALYTICS_PICS' | translate}} <span data-ng-show="accountData[number.id].pictures.length > 0" class="badge">{{accountData[number.id].pictures.length}}</span></a></li>
Maikel Zweerink's avatar
Maikel Zweerink committed
153 154 155 156
									  </ul>

									  <!-- Tab panes -->
									  <div class="tab-content">
157 158 159 160
									    <div role="tabpanel" class="tab-pane active whatsspy-tab-info-overview" id="overview-{{number.id}}">
									    	<div data-ng-show="accountData[number.id].user != null">
										    	<div class="row">
										    		<div class="col-md-6">
161
										    			<h5>{{'OVERVIEW_CONTACT_OPENED_H' | translate}}</h5>
162 163 164
														<table class="table table-striped table-bordered ">
													      <tbody>
													        <tr>
165
													          <th class="whatsspy-analytics-th-big">{{'OVERVIEW_CONTACT_TABLE_1D' | translate}} </th>
166
													          <td>{{accountData[number.id].user.count_1day}} {{'OVERVIEW_CONTACT_TIMES' | translate}}</td>
167 168
													        </tr>
													        <tr>
169
													          <th>{{'OVERVIEW_CONTACT_TABLE_7D' | translate}} </th>
170
													          <td>{{accountData[number.id].user.count_7day}} {{'OVERVIEW_CONTACT_TIMES' | translate}}</td>
171 172
													        </tr>
													        <tr>
173
													          <th>{{'OVERVIEW_CONTACT_TABLE_14D' | translate}} </th>
174
													          <td>{{accountData[number.id].user.count_14day}} {{'OVERVIEW_CONTACT_TIMES' | translate}}</td>
175 176
													        </tr>
													        <tr>
177
													          <th>{{'OVERVIEW_CONTACT_TABLE_31D' | translate}} </th>
178
													          <td>{{accountData[number.id].user.count_31day}} {{'OVERVIEW_CONTACT_TIMES' | translate}}</td>
179 180
													        </tr>
													        <tr>
181
													          <th>{{'OVERVIEW_CONTACT_TABLE_xD' | translate}} </th>
182
													          <td>{{accountData[number.id].user.count_all}} {{'OVERVIEW_CONTACT_TIMES' | translate}}</td>
183 184 185
													        </tr>
													      </tbody>
													    </table>
186
													    <small><span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span> {{'OVERVIEW_CONTACT_TRACKING_SINCE' | translate}} {{number.since | staticDatetime}}.</small>
187 188
										    		</div>
										    		<div class="col-md-6">
189
										    			<h5>{{'OVERVIEW_CONTACT_TIME_SPENT_WA' | translate}}</h5>
190 191 192
														<table class="table table-striped table-bordered ">
													      <tbody>
													        <tr>
193
													          <th class="whatsspy-analytics-th">{{'OVERVIEW_CONTACT_TABLE_1D' | translate}} </th>
194 195 196
													          <td>{{accountData[number.id].user.online_1day | timeFormat}}</td>
													        </tr>
													        <tr>
197
													          <th>{{'OVERVIEW_CONTACT_TABLE_7D' | translate}}</th>
198 199 200
													          <td>{{accountData[number.id].user.online_7day | timeFormat}}</td>
													        </tr>
													        <tr>
201
													          <th>{{'OVERVIEW_CONTACT_TABLE_14D' | translate}}</th>
202 203 204
													          <td>{{accountData[number.id].user.online_14day | timeFormat}}</td>
													        </tr>
													        <tr>
205
													          <th>{{'OVERVIEW_CONTACT_TABLE_31D' | translate}} </th>
206 207 208
													          <td>{{accountData[number.id].user.online_31day | timeFormat}}</td>
													        </tr>
													        <tr>
209
													          <th>{{'OVERVIEW_CONTACT_TABLE_xD' | translate}} </th>
210 211 212 213 214 215 216 217
													          <td>{{accountData[number.id].user.online_all | timeFormat}}</td>
													        </tr>
													      </tbody>
													    </table>
										    		</div>
										    	</div>
										    </div>
										    <div class="whatsspy-no-information-data" data-ng-show="accountData[number.id].user == null">
218
										    	{{'OVERVIEW_CONTACT_LOADING_INFO' | translate}}
219 220 221 222 223 224 225
										    </div>
									    </div>
									    <div role="tabpanel" class="tab-pane whatsspy-tab-info-overview" id="opened-overview-{{number.id}}">
									    	<div data-ng-show="accountData[number.id].user != null">
										    	<div class="row">
										    		<div class="col-md-12">
										    			<div class="whatsspy-bar-graph-toggle">
226 227
										    				<button data-ng-show="accountData[number.id].generated.showHour != true" data-ng-click="accountData[number.id].generated.showWeekday = false; accountData[number.id].generated.showHour = true; " type="button" class="btn btn-info">{{'OVERVIEW_CONTACT_SWITCH_HOUR_VIEW' | translate}}</button>
										    				<button data-ng-show="accountData[number.id].generated.showWeekday != true" data-ng-click="accountData[number.id].generated.showWeekday = true; accountData[number.id].generated.showHour = false" type="button" class="btn btn-info">{{'OVERVIEW_CONTACT_SWITCH_WEEKDAY_VIEW' | translate}}</button>
228 229
										    			</div>
										    			<span data-ng-show="accountData[number.id].generated.showWeekday == true">
230
											    			<h5>{{'OVERVIEW_CONTACT_H_OPENING_WA_WEEKDAY' | translate}}</h5>
231 232 233 234
											    			<nvd3-multi-bar-chart
														    	data="accountData[number.id].generated.chart_weekday_status_count_all"
														        id="opened-overview-graph-weekday-{{number.id}}"
														        tooltipcontent="barChartToolTip('weekday', 'times')"
235
														        width="700"
236
	        													height="260"
237 238 239 240 241 242 243 244 245 246
														        showXAxis="false"
														        showYAxis="true"
														        margin=" {top:5,bottom:5,right:0}"
														        showLegend="true"
														        tooltips="true"
														        stacked="true">
														        	<svg></svg>
														    </nvd3-multi-bar-chart>
														</span>
														<span data-ng-show="accountData[number.id].generated.showHour == true">
247
											    			<h5>{{'OVERVIEW_CONTACT_H_OPENING_WA_HOUR' | translate}}</h5>
248 249 250 251
											    			<nvd3-multi-bar-chart
														    	data="accountData[number.id].generated.chart_hour_status_count_all"
														        id="opened-overview-graph-hour-{{number.id}}"
														        tooltipcontent="barChartToolTip('hour', 'times')"
252
														        width="700"
253
	        													height="260"
254 255 256 257 258 259 260 261 262 263 264 265 266
														        showXAxis="false"
														        showYAxis="true"
														        margin=" {top:5,bottom:5,right:0}"
														        showLegend="true"
														        tooltips="true"
														        stacked="true">
														        	<svg></svg>
														    </nvd3-multi-bar-chart>
														</span>
										    		</div>
										    	</div>
										    </div>
										    <div class="whatsspy-no-information-data" data-ng-show="accountData[number.id].user == null">
267
										    	{{'OVERVIEW_CONTACT_LOADING_INFO' | translate}}
268
										    </div>
Maikel Zweerink's avatar
Maikel Zweerink committed
269
									    </div>
270 271 272 273 274
									    <div role="tabpanel" class="tab-pane whatsspy-tab-info-overview" id="time-overview-{{number.id}}">
									    	<div data-ng-show="accountData[number.id].user != null">
										    	<div class="row">
										    		<div class="col-md-12">
										    			<div class="whatsspy-bar-graph-toggle">
275 276
										    				<button data-ng-show="accountData[number.id].generated.showHour != true" data-ng-click="accountData[number.id].generated.showWeekday = false; accountData[number.id].generated.showHour = true; " type="button" class="btn btn-info">{{'OVERVIEW_CONTACT_SWITCH_HOUR_VIEW' | translate}}</button>
										    				<button data-ng-show="accountData[number.id].generated.showWeekday != true" data-ng-click="accountData[number.id].generated.showWeekday = true; accountData[number.id].generated.showHour = false" type="button" class="btn btn-info">{{'OVERVIEW_CONTACT_SWITCH_WEEKDAY_VIEW' | translate}}</button>
277 278
										    			</div>
										    			<span data-ng-show="accountData[number.id].generated.showWeekday == true">
279
											    			<h5>{{'OVERVIEW_CONTACT_H_TIME_WA_WEEKDAY' | translate}}</h5>
280 281 282 283
											    			<nvd3-multi-bar-chart
														    	data="accountData[number.id].generated.chart_weekday_status_time_all"
														        id="time-overview-graph-weekday-{{number.id}}"
														        tooltipcontent="barChartToolTip('weekday', 'minutes')"
284
														        width="700"
285
	        													height="260"
286 287 288 289 290 291 292 293 294 295
														        showXAxis="false"
														        showYAxis="true"
														        margin=" {top:5,bottom:5,right:0}"
														        showLegend="true"
														        tooltips="true"
														        stacked="true">
														        	<svg></svg>
														    </nvd3-multi-bar-chart>
														</span>
														<span data-ng-show="accountData[number.id].generated.showHour == true">
296
											    			<h5>{{'OVERVIEW_CONTACT_H_TIME_WA_HOUR' | translate}}</h5>
297 298 299 300
											    			<nvd3-multi-bar-chart
														    	data="accountData[number.id].generated.chart_hour_status_time_all"
														        id="time-overview-graph-hour-{{number.id}}"
														        tooltipcontent="barChartToolTip('hour', 'minutes')"
301
														        width="700"
302
	        													height="260"
303 304 305 306 307 308 309 310 311 312 313 314 315
														        showXAxis="false"
														        showYAxis="true"
														        margin=" {top:5,bottom:5,right:0}"
														        showLegend="true"
														        tooltips="true"
														        stacked="true">
														        	<svg></svg>
														    </nvd3-multi-bar-chart>
														</span>
										    		</div>
										    	</div>
										    </div>
										    <div class="whatsspy-no-information-data" data-ng-show="accountData[number.id].user == null">
316
										    	{{'OVERVIEW_CONTACT_LOADING_INFO' | translate}}
317 318 319
										    </div>
									    </div>
									    <div role="tabpanel" class="tab-pane whatsspy-tab-status-msg" id="statusmessages-{{number.id}}">
320
											<div class="whatsspy-status-entry" data-ng-repeat="entry in accountData[number.id].statusmessages">
Maikel Zweerink's avatar
Maikel Zweerink committed
321 322 323
												<span class="label label-info">{{entry.changed_at | staticDatetime}}</span> 
												{{entry.status}}
											</div>
324
											<div class="whatsspy-no-information-data" data-ng-show="accountData[number.id].statusmessages == null || accountData[number.id].statusmessages.length == 0">
325
									    		{{'OVERVIEW_NO_INFO' | translate}}
Maikel Zweerink's avatar
Maikel Zweerink committed
326 327 328
									    	</div>
									    </div>
									    <div role="tabpanel" class="tab-pane whatsspy-tab-info-pic" id="pictures-{{number.id}}">
329
									    	<div data-ng-repeat="picture in accountData[number.id].pictures" class="whatsspy-img-container">
330
									    		<img class="img-rounded whatsspy-img-big" data-ng-src="{{(picture.hash != null) && getImageURL(picture.hash) || ''}}" />
Maikel Zweerink's avatar
Maikel Zweerink committed
331 332 333
									    		<br />
									    		<span class="label label-info">{{picture.changed_at | staticDate}}</span>
									    	</div>
334
									    	<div class="whatsspy-no-information-data" data-ng-show="accountData[number.id].status == null || accountData[number.id].pictures.length == 0">
335
									    		{{'OVERVIEW_NO_INFO' | translate}}
Maikel Zweerink's avatar
Maikel Zweerink committed
336 337 338 339 340 341
									    	</div>
									    </div>
									  </div>
									</div>
								</div>
								<div class="col-md-4">
342
									<h4>{{'OVERVIEW_CONTACT_H_PRIV_STATUS' | translate}}</h4>
Maikel Zweerink's avatar
Maikel Zweerink committed
343 344 345
									<div role="tabpanel">
									  <!-- Nav tabs -->
									  <ul class="nav nav-tabs" role="tablist">
346 347
									    <li role="presentation" class="active"><a aria-controls="privacy" role="tab" data-toggle="tab" data-target="#privacy-{{number.id}}">{{'OVERVIEW_CONTACT_PRIV_STATUS' | translate}}</a></li>
									    <li role="presentation"><a aria-controls="stats" role="tab" data-toggle="tab" data-target="#logs-{{number.id}}">{{'OVERVIEW_CONTACT_ONLINE_EVENTS' | translate}}</a></li>
Maikel Zweerink's avatar
Maikel Zweerink committed
348 349 350 351
									  </ul>

									  <!-- Tab panes -->
									  <div class="tab-content">
352
									    <div role="tabpanel" class="tab-pane active" id="privacy-{{number.id}}">
Maikel Zweerink's avatar
Maikel Zweerink committed
353 354 355
									    	<table class="table table-striped table-bordered ">
										      <tbody>
										        <tr>
356
										          <th class="whatsspy-analytics-th-privacy">{{'OVERVIEW_CONTACT_H_LASTSEEN' | translate}}</th>
Maikel Zweerink's avatar
Maikel Zweerink committed
357
										          <td>
358 359
										          	<span data-ng-show="number.lastseen_privacy == true" title="This privacy setting may be contacts or nobody. This can't be detected." class="label label-danger label-full-width">{{'OVERVIEW_PRIVACY_SETTINGS_FRIENDS' | translate}}</span>
													<span data-ng-show="number.lastseen_privacy == false" class="label label-success label-full-width">{{'OVERVIEW_PRIVACY_SETTINGS_PUBLIC' | translate}}</span>
Maikel Zweerink's avatar
Maikel Zweerink committed
360
													
361
													<small><span data-ng-show="accountData[number.id].user.lastseen_changed_privacy != null">{{'OVERVIEW_PRIVACY_LAST_CHANGE' | translate}} <strong>{{accountData[number.id].user.lastseen_changed_privacy | privacy}}</strong><br /> {{'OVERVIEW_PRIVACY_LAST_CHANGE_AT' | translate}} {{accountData[number.id].user.lastseen_changed_privacy_updated | staticDatetime}}</span></small>
Maikel Zweerink's avatar
Maikel Zweerink committed
362 363 364
												</td>
										        </tr>
										        <tr>
365
										          <th class="whatsspy-analytics-th-privacy">{{'OVERVIEW_PRIVACY_H_PROF_PIC' | translate}}</th>
Maikel Zweerink's avatar
Maikel Zweerink committed
366
										          <td>
367 368
										          	<span data-ng-show="number.profilepic_privacy == true" title="This privacy setting may be contacts or nobody. This can't be detected." class="label label-danger label-full-width">{{'OVERVIEW_PRIVACY_SETTINGS_FRIENDS' | translate}}</span>
													<span data-ng-show="number.profilepic_privacy == false" class="label label-success label-full-width">{{'OVERVIEW_PRIVACY_SETTINGS_PUBLIC' | translate}}</span>
Maikel Zweerink's avatar
Maikel Zweerink committed
369

370
													<small><span data-ng-show="accountData[number.id].user.profilepic_changed_privacy != null">{{'OVERVIEW_PRIVACY_LAST_CHANGE' | translate}} <strong>{{accountData[number.id].user.profilepic_changed_privacy | privacy}}</strong><br /> {{'OVERVIEW_PRIVACY_LAST_CHANGE_AT' | translate}} {{accountData[number.id].user.profilepic_changed_privacy_updated | staticDatetime}}*</span></small>
Maikel Zweerink's avatar
Maikel Zweerink committed
371 372 373
												</td>
										        </tr>
										        <tr>
374
										          <th class="whatsspy-analytics-th-privacy">{{'OVERVIEW_PRIVACY_H_STATUS' | translate}}</th>
Maikel Zweerink's avatar
Maikel Zweerink committed
375
										          <td>
376 377
										          	<span data-ng-show="number.statusmessage_privacy == true" title="This privacy setting may be contacts or nobody. This can't be detected." class="label label-danger label-full-width">{{'OVERVIEW_PRIVACY_SETTINGS_FRIENDS' | translate}}</span>
													<span data-ng-show="number.statusmessage_privacy == false" class="label label-success label-full-width">{{'OVERVIEW_PRIVACY_SETTINGS_PUBLIC' | translate}}</span>
Maikel Zweerink's avatar
Maikel Zweerink committed
378

379
													<small><span data-ng-show="accountData[number.id].user.statusmessage_changed_privacy != null">{{'OVERVIEW_PRIVACY_LAST_CHANGE' | translate}} <strong>{{accountData[number.id].user.statusmessage_changed_privacy | privacy}}</strong><br /> {{'OVERVIEW_PRIVACY_LAST_CHANGE_AT' | translate}} {{accountData[number.id].user.statusmessage_changed_privacy_updated | staticDatetime}}*</span></small>
Maikel Zweerink's avatar
Maikel Zweerink committed
380 381 382 383
												</td>
										        </tr>
										      </tbody>
										    </table>
384
										    <small>
385
										    	<span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span> {{'OVERVIEW_PRIVACY_TRACK_NOTICE' | translate}}
386
										    	<br />
387
										    	<span class="glyphicon glyphicon-warning-sign" aria-hidden="true"></span> {{'OVERVIEW_PRIVACY_ASSUMPTION' | translate}}
388
										    </small>
Maikel Zweerink's avatar
Maikel Zweerink committed
389
									    </div>
390 391 392
									    <div role="tabpanel" class="tab-pane whatsspy-tab-info-logs" id="logs-{{number.id}}">
											<div class="whatsspy-status-entry" data-ng-repeat="entry in accountData[number.id].status">
												<span class="label label-info" title="Logid: {{entry.sid}}">{{entry.start | staticDate}}</span> 
393
												{{'OVERVIEW_LOG_FROM' | translate}} <strong>{{entry.start | staticTime}}</strong> {{'OVERVIEW_LOG_TILL' | translate}} <strong data-ng-show="entry.end != null">{{entry.end | staticTime}}</strong><strong data-ng-show="entry.end == null">{{'OVERVIEW_LOG_NOW' | translate}}</strong>
394 395
											</div>
											<div class="whatsspy-no-information-data" data-ng-show="accountData[number.id].status == null || accountData[number.id].status.length == 0">
396
									    		{{'OVERVIEW_NO_INFO' | translate}}
397
									    	</div>
Maikel Zweerink's avatar
Maikel Zweerink committed
398 399 400 401 402 403 404 405 406
									    </div>
									  </div>
									</div>
								</div>
							</div>
						</span>
					</div>
			</div>
			<span data-ng-show="accounts.length == 0">
407
				<center>{{'OVERVIEW_NO_ACC' | translate}}</center>
Maikel Zweerink's avatar
Maikel Zweerink committed
408 409 410 411 412 413 414 415 416 417
			</span>
		</div>
	</div>
</div>	
<!-- Models -->
<div class="modal fade" id="addNumber" tabindex="-1" role="dialog" aria-labelledby="addNumberLabel" aria-hidden="true">
  <div class="modal-dialog modal-lg">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
418
        <h4 class="modal-title" id="addNumberLabel">{{'OVERVIEW_ADD_CONTACT_H' | translate}}</h4>
Maikel Zweerink's avatar
Maikel Zweerink committed
419 420 421 422
      </div>
      <div class="modal-body">
      	<form class="form-horizontal">
		  <div class="form-group">
423
		    <label for="countryCode" class="col-sm-2 control-label">{{'OVERVIEW_ADD_CONTACT_PHONE' | translate}}</label>
424
		    <div class="col-sm-8">
Maikel Zweerink's avatar
Maikel Zweerink committed
425
		    	<div class="row">
426
		    		<div class="col-md-3">
Maikel Zweerink's avatar
Maikel Zweerink committed
427 428
		    			<div class="input-group ">
            				<span class="input-group-addon">+</span>  
429
			    			<input type="text" class="form-control" id="countryCode" data-ng-model="newContact.countryCode" placeholder="{{'OVERVIEW_ADD_CONTACT_PLACEHOLDER_COUNTRYCODE' | translate}}" value="0031">
Maikel Zweerink's avatar
Maikel Zweerink committed
430 431
			    		</div>
		    		</div>
432
		    		<div class="col-md-9">
433
		    			<input type="text"  class="form-control" id="phoneNumber" data-ng-model="newContact.number"placeholder="{{'OVERVIEW_ADD_CONTACT_PLACEHOLDER_PHONE' | translate}}" >
Maikel Zweerink's avatar
Maikel Zweerink committed
434 435 436 437 438
		    		</div>
		    	</div>
		    </div>
		  </div>
		  <div class="form-group">
439
		    <label for="name" class="col-sm-2 control-label">{{'OVERVIEW_ADD_CONTACT_NAME' | translate}}</label>
440
		    <div class="col-sm-8">
441
		      <input type="text" class="form-control" id="name" data-ng-model="newContact.name" placeholder="{{'OVERVIEW_EDIT_CONTACT_NAME_PLACEHOLDER' | translate}}">
Maikel Zweerink's avatar
Maikel Zweerink committed
442 443
		    </div>
		  </div>
444
		  <div class="form-group">
445
		    <label for="name" class="col-sm-2 control-label">{{'OVERVIEW_ADD_CONTACT_GROUP' | translate}}</label>
446 447 448 449 450 451 452
		    <div class="col-sm-8">
    			<div class="input-group"> 
    				<div class="input-group-addon"><span class="glyphicon glyphicon-tag" aria-hidden="true"></span></div>
			      	<multiselect class="whatsspy-group-select" data-ng-model="newContact.groups" data-options="group.gid as group.name for group in getRealGroups()" data-multiple="true" data-compare-by="gid" scroll-after-rows="10"></multiselect>
			    </div>
		    </div>
		  </div>
Maikel Zweerink's avatar
Maikel Zweerink committed
453
		</form>
454
		<small>{{'OVERVIEW_ADD_CONTACT_NOTICE' | translate}}</small>
Maikel Zweerink's avatar
Maikel Zweerink committed
455 456
      </div>
      <div class="modal-footer">
457
		<div class="whatsspy-contact-options">
458
      		<button type="submit" data-ng-click="submitNewAccount();" class="btn btn-success"><span class="glyphicon glyphicon-ok-circle" aria-hidden="true"></span> {{'OVERVIEW_ADD_CONTACT_ADD' | translate}}</button>
459
      	</div>
460
        <button type="button" class="btn btn-default" data-dismiss="modal">{{'OVERVIEW_ADD_CONTACT_CLOSE' | translate}}</button>
Maikel Zweerink's avatar
Maikel Zweerink committed
461 462 463 464 465 466 467 468 469 470
      </div>
    </div>
  </div>
</div>

<div class="modal fade" id="editName" tabindex="-1" role="dialog" aria-labelledby="editNameLabel" aria-hidden="true">
  <div class="modal-dialog modal-lg">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
471
        <h4 class="modal-title" id="editNameLabel">{{'OVERVIEW_EDIT_CONTACT_H' | translate}}</h4>
Maikel Zweerink's avatar
Maikel Zweerink committed
472 473 474 475
      </div>
      <div class="modal-body">
      	<form class="form-horizontal">
		  <div class="form-group">
476
		    <label for="phoneNumber" class="col-sm-2 control-label">{{'OVERVIEW_EDIT_CONTACT_PHONE' | translate}}</label>
477
		    <div class="col-sm-7 col-sm-offset-1 col-xs-10 col-xs-offset-1">
Maikel Zweerink's avatar
Maikel Zweerink committed
478 479 480
		    	<div class="row">
	    			<div class="input-group ">
        				<span class="input-group-addon">+</span>  
481
		    			<input type="text" class="form-control" id="phoneNumber" data-ng-value="editContact.id" disabled="disabled">
Maikel Zweerink's avatar
Maikel Zweerink committed
482 483 484 485 486
		    		</div>
		    	</div>
		    </div>
		  </div>
		  <div class="form-group">
487
		    <label for="name" class="col-sm-2 control-label">{{'OVERVIEW_EDIT_CONTACT_NAME' | translate}}</label>
488
		    <div class="col-sm-7 col-sm-offset-1 col-xs-10 col-xs-offset-1">
489
		    	<div class="row">
490 491
	    			<div class="input-group"> 
	    				<div class="input-group-addon"><span class="glyphicon glyphicon-user" aria-hidden="true"></span></div>
492
				      	<input type="text" class="form-control" id="name" data-ng-model="editContact.name" placeholder="{{'OVERVIEW_EDIT_CONTACT_NAME_PLACEHOLDER' | translate}}">
493 494
				    </div>
		    	</div>
Maikel Zweerink's avatar
Maikel Zweerink committed
495 496
		    </div>
		  </div>
497
		  <div class="form-group">
498
		    <label for="name" class="col-sm-2 control-label">{{'OVERVIEW_EDIT_CONTACT_GROUPS' | translate}}</label>
499 500 501 502
		    <div class="col-sm-7 col-sm-offset-1 col-xs-10 col-xs-offset-1">
		    	<div class="row">
	    			<div class="input-group"> 
	    				<div class="input-group-addon"><span class="glyphicon glyphicon-tag" aria-hidden="true"></span></div>
503
				      	<multiselect class="whatsspy-group-select" data-ng-model="editContact.groups" data-options="group.gid as group.name for group in getRealGroups()" data-multiple="true" data-compare-by="gid" scroll-after-rows="10"></multiselect>
504 505 506 507
				    </div>
		    	</div>
		    </div>
		  </div>
508
		  <div class="form-group">
509
		    <label for="phoneNumber" class="col-sm-2 control-label">{{'OVERVIEW_EDIT_CONTACT_PROFILESHARE' | translate}}</label>
510 511 512 513 514 515 516 517 518 519 520
		    <div class="col-sm-7 col-sm-offset-1 col-xs-10 col-xs-offset-1">
		    	<div class="row">
		    		<div class="row">
		    			<div class="col-sm-8  col-xs-12">
		    				<div class="input-group whatsspy-copy-token" data-ng-click="copyToClipboard(getTokenUrl('user', editContact.read_only_token))">
		        				<span class="input-group-addon"><span class="glyphicon glyphicon-link" aria-hidden="true"></span></span>  
				    			<input type="text" class="form-control" id="shareUrl" data-ng-value="editContact.read_only_token | emptyToken" disabled="disabled">
				    		</div>
		    			</div>
		    			<div class="col-sm-4 col-xs-12">
		    				<button type="button" class="btn btn-primary" data-ng-click="generateReadOnlyToken('user', editContact, null)">
521
		    					 {{'OVERVIEW_EDIT_CONTACT_GENERATE_TOKEN' | translate}}
522 523
		    				</button>
		    				<button type="button" class="btn btn-danger" data-ng-click="resetReadOnlyToken('user', editContact, null)">
524
		    					 {{'OVERVIEW_EDIT_CONTACT_RESET_TOKEN' | translate}}
525 526 527
		    				</button>
		    			</div>
		    		</div>    			
528 529
		    		<small> {{'OVERVIEW_EDIT_CONTACT_TOKEN_INFO' | translate}}<br />
		    			{{'OVERVIEW_EDIT_CONTACT_TOKEN_INFO2' | translate}}</small>
530 531 532
		    	</div>
		    </div>
		  </div>
533
		  <div class="form-group">
534
		    <label for="name" class="col-sm-2 control-label">{{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS' | translate}}</label>
535
		    <div class="col-sm-7 col-sm-offset-1 col-xs-10 col-xs-offset-1" data-ng-disabled="isNotificationEnabled();">
536 537
		    	<div class="row">
	    			<div class="input-group"> 
538 539 540
	    				<button type="button" class="btn btn-primary whatsspy-btn-notify col-xs-12" data-ng-click="editContact.notify_status = getOpposite(editContact.notify_status);" data-ng-disabled="notificationOptionDisabled">
	    					<span class="glyphicon glyphicon-ok green" aria-hidden="true" data-ng-show="editContact.notify_status == true"></span>
	    					<span class="glyphicon glyphicon-remove red" aria-hidden="true" data-ng-show="editContact.notify_status == false"></span>
541
	    					 {{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_ONLINE' | translate}}
542 543 544 545
	    				</button>
	    				<button type="button" class="btn btn-primary whatsspy-btn-notify col-xs-12" data-ng-click="editContact.notify_statusmsg = getOpposite(editContact.notify_statusmsg);" data-ng-disabled="notificationOptionDisabled">
	    					<span class="glyphicon glyphicon-ok green" aria-hidden="true" data-ng-show="editContact.notify_statusmsg == true"></span>
	    					<span class="glyphicon glyphicon-remove red" aria-hidden="true" data-ng-show="editContact.notify_statusmsg == false"></span>
546
	    					{{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_STATUSMSG' | translate}}
547 548 549 550
	    				</button>
	    				<button type="button" class="btn btn-primary whatsspy-btn-notify col-xs-12" data-ng-click="editContact.notify_profilepic = getOpposite(editContact.notify_profilepic);" data-ng-disabled="notificationOptionDisabled">
	    					<span class="glyphicon glyphicon-ok green" aria-hidden="true" data-ng-show="editContact.notify_profilepic == true"></span>
	    					<span class="glyphicon glyphicon-remove red" aria-hidden="true" data-ng-show="editContact.notify_profilepic == false"></span>
551
	    					{{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_PROFPIC' | translate}}
552 553 554 555
	    				</button>
	    				<button type="button" class="btn btn-primary whatsspy-btn-notify col-xs-12" data-ng-click="editContact.notify_privacy = getOpposite(editContact.notify_privacy);" data-ng-disabled="notificationOptionDisabled">
	    					<span class="glyphicon glyphicon-ok green" aria-hidden="true" data-ng-show="editContact.notify_privacy == true"></span>
	    					<span class="glyphicon glyphicon-remove red" aria-hidden="true" data-ng-show="editContact.notify_privacy == false"></span>
556
	    					{{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_PRIV' | translate}}
557
	    				</button>
558
					    <small data-ng-show="notificationOptionDisabled">{{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_AGENTS' | translate}} <strong>{{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_AGENTS_CONFIG' | translate}}</strong>. {{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_MISSING' | translate}}</small>
559
					    <small data-ng-show="notificationOptionDisabled == false">
560
					    	{{'OVERVIEW_EDIT_CONTACT_NOTIFICATIONS_SENDING' | translate}}
561
					    	<span data-ng-repeat="(key, agent) in notificationSettings" data-ng-show="agent.enabled == true && agent['notify-user'] == true">
562
					    		<strong>{{agent.name}}</strong> <span data-ng-hide="$last">{{'OVERVIEW_AND' | translate}}</span> 
563 564 565 566 567 568 569
					    	</span>
					    </small>
					    <br />
					    <br />
	    				<button type="button" class="btn btn-primary whatsspy-btn-notify col-xs-12" data-ng-click="editContact.notify_timeline = getOpposite(editContact.notify_timeline);">
	    					<span class="glyphicon glyphicon-ok green" aria-hidden="true" data-ng-show="editContact.notify_timeline == true"></span>
	    					<span class="glyphicon glyphicon-remove red" aria-hidden="true" data-ng-show="editContact.notify_timeline == false"></span>
570
	    					 {{'OVERVIEW_EDIT_CONTACT_SHOW_TIMELINE' | translate}}
571
	    				</button>
572 573 574 575 576 577 578 579
	    				<br />
						<div class="input-group col-xs-12">
							<div class="input-group-addon"><span class="glyphicon glyphicon-music" aria-hidden="true"></span></div>
							<select class="form-control" ng-model="editContact.notification_sound" ng-options="sound for sound in notificationSounds"></select>
							<div class="input-group-addon">
								<span class="glyphicon glyphicon-play whatsspy-copy-token" aria-hidden="true"  data-ng-click="playNotificationSound(editContact.notification_sound)"></span>
							</div>
						</div>
580
						<small>{{'OVERVIEW_EDIT_CONTACT_SHOW_TIMELINE_EXPL' | translate}}</small>
581 582 583 584
				    </div>
		    	</div>
		    </div>
		  </div>
Maikel Zweerink's avatar
Maikel Zweerink committed
585 586 587 588
		</form>

      </div>
      <div class="modal-footer">
589
      	<div class="whatsspy-contact-options">
590 591 592
	      	<button type="submit" data-ng-click="submitAccountEdit();" class="btn btn-success"><span class="glyphicon glyphicon-ok-circle" aria-hidden="true"></span> {{'OVERVIEW_EDIT_CONTACT_SAVE' | translate}}</button> 
			<a class="btn btn-warning" data-ng-attr-title="{{'OVERVIEW_EDIT_CONTACT_INACTIVE_TITLE' | translate}}" data-toggle="tooltip" data-placement="bottom" data-ng-click="setNumberInactive(editContact.id);"><span class="glyphicon glyphicon-off" title="Set inactive"></span> {{'OVERVIEW_EDIT_CONTACT_INACTIVE' | translate}}</a> 
			<a class="btn btn-danger" data-ng-attr-title="{{'OVERVIEW_EDIT_CONTACT_DETELE_TITLE' | translate}}" data-toggle="tooltip" data-placement="bottom" data-ng-click="deleteAccountConfirm(editContact.id);"><span class="glyphicon glyphicon-ban-circle" aria-hidden="true"></span> {{'OVERVIEW_EDIT_CONTACT_DELETE' | translate}}</a>
593
		</div>
594
        <button type="button" class="btn btn-default" data-dismiss="modal">{{'OVERVIEW_ADD_CONTACT_CLOSE' | translate}}</button>
Maikel Zweerink's avatar
Maikel Zweerink committed
595 596 597
      </div>
    </div>
  </div>
598 599 600 601 602 603 604
</div>

<div class="modal fade" id="manageGroups" tabindex="-1" role="dialog" aria-labelledby="manageGroupsLabel" aria-hidden="true">
  <div class="modal-dialog modal-lg">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
605
        <h4 class="modal-title" id="manageGroupsLabel">{{'OVERVIEW_GROUPS_H' | translate}}</h4>
606 607
      </div>
      <div class="modal-body">
608
      	<h4>{{'OVERVIEW_GROUPS_EXISTING' | translate}}</h4>
609 610 611 612 613 614 615
      	<div class="row">
	  		<span data-ng-show="groups.length > 1">
	  			<div class="col-md-4" data-ng-repeat="group in groups" data-ng-show="group.gid != null">
		  			<div class="panel panel-default">
						<div class="panel-heading">
							<div class="row">
								<div class="col-sm-12">
616
									<h2 class="panel-title group-name" data-ng-click="changeGroupName(group);"><span class="glyphicon glyphicon-tag" aria-hidden="true"></span> {{group.name}}</h2>
617 618 619 620
								</div>
							</div>
						</div>
						<div class="panel-body whatsspy-group-body">
621 622 623
							<span class="label label-default whatsspy-label-notifications">{{'OVERVIEW_GROUPS_USERS' | translate}} {{getGroupUsers(group.gid)}}</span>
							<span class="label label-success whatsspy-label-notifications" data-ng-show="group.read_only_token != null">{{'OVERVIEW_GROUPS_STATSEN' | translate}}</span>
							<span class="label label-warning whatsspy-label-notifications" data-ng-show="group.read_only_token == null">{{'OVERVIEW_GROUPS_STATSDIS' | translate}}</span>
624 625
							<br />
							<br />
626
							<a class="btn btn-danger whatsspy-label-notifications" title="Deleting the group will not delete the users in this group." data-ng-click="deleteGroup(group.gid);"><span class="glyphicon glyphicon-ban-circle" aria-hidden="true"></span> {{'OVERVIEW_GROUPS_DELETEBTN' | translate}}</a>   		
627 628 629 630 631
						</div>
					</div>
				</div>
			</span>
			<span data-ng-show="groups.length == 1">
632
				{{'OVERVIEW_GROUPS_NONE' | translate}}
633
			</span>
634
		</div>
635
		<small>{{'OVERVIEW_GROUPS_SHARE' | translate}}</small>
636
		<br />
637
		<small data-ng-show="groups.length > 1">{{'OVERVIEW_GROUPS_DELETE' | translate}}</small>
638
		<br />
639
		<h4>{{'OVERVIEW_GROUPS_CREATE' | translate}}</h4>
640 641
		<form class="form-horizontal">
			<div class="form-group">
642
				<label for="name" class="col-sm-2 control-label">{{'OVERVIEW_GROUPS_CREATE_NAME' | translate}}</label>
643
				<div class="col-sm-5">
644
					<input type="text" class="form-control" id="name" data-ng-model="newGroup.name" placeholder="{{'OVERVIEW_GROUPS_PLACEHOLDER' | translate}}">
645 646 647
				</div>
			</div>
			<div class="form-group">
648
				<label for="name" class="col-sm-2 control-label"></label>
649
				<div class="col-sm-5">
650
					<button type="submit" data-ng-click="submitNewGroup();" class="btn btn-success">{{'OVERVIEW_GROUPS_CREATEBTN' | translate}}</button>
651 652 653 654 655
				</div>
			</div>
		</form>
      </div>
      <div class="modal-footer">
656
        <button type="button" class="btn btn-default" data-dismiss="modal">{{'OVERVIEW_GROUPS_CLOSE' | translate}}</button>
657 658 659
      </div>
    </div>
  </div>
660 661 662 663 664 665 666
</div>

<div class="modal fade" id="managePerformance" tabindex="-1" role="dialog" aria-labelledby="managePerformanceLabel" aria-hidden="true">
  <div class="modal-dialog modal-lg">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
667
        <h4 class="modal-title" id="managePerformanceLabel">{{'OVERVIEW_PERFORMANCE_H' | translate}}</h4>
668 669 670
      </div>
      <div class="modal-body">
		<form class="form-horizontal">
671
			<h4><span class="glyphicon glyphicon-user" aria-hidden="true"></span> {{'OVERVIEW_PERFORMANCE_TIMELINE' | translate}}</h4>
672
		  <div class="form-group">
673
		    <label for="phoneNumber" class="col-sm-2 control-label">{{'OVERVIEW_PERFORMANCE_TIMELINE_OPTION' | translate}} </label>
674 675 676 677 678 679
		    <div class="col-sm-8 col-sm-offset-1 col-xs-10 col-xs-offset-1">
		    	<div class="row">
		    		<div class="col-sm-6">
		    			<select class="form-control whatsspy-inline-form" data-ng-model="config.account_show_timeline_length" data-ng-options="option.value as option.name for option in timelineLengthOptions" ></select>
		    		</div>
		    		<div class="col-sm-6">
680
		    			<small><span class="glyphicon glyphicon-flash" aria-hidden="true"></span> {{'OVERVIEW_PERFORMANCE_TIMELINE_EXP' | translate}} <strong>{{'OVERVIEW_PERFORMANCE_TIMELINE_EXP2' | translate}}</strong> {{'OVERVIEW_PERFORMANCE_TIMELINE_EXP3' | translate}}</small>
681 682 683 684 685 686 687
		    		</div>
		    	</div>
		    </div>
		  </div>
		</form>
		<form class="form-horizontal">
		  <div class="form-group">
688
		    <label for="phoneNumber" class="col-sm-2 control-label">{{'OVERVIEW_PERFORMANCE_TRACKER_H' | translate}}</label>
689 690 691 692 693 694
		    <div class="col-sm-8 col-sm-offset-1 col-xs-10 col-xs-offset-1">
		    	<div class="row">
		    		<div class="col-sm-6">
		    			<button type="button" class="btn btn-primary" data-ng-click="config.account_show_timeline_tracker = getOpposite(config.account_show_timeline_tracker);">
	    					<span class="glyphicon glyphicon-ok green" aria-hidden="true" data-ng-show="config.account_show_timeline_tracker == true"></span>
	    					<span class="glyphicon glyphicon-remove red" aria-hidden="true" data-ng-show="config.account_show_timeline_tracker == false"></span>
695
	    					 {{'OVERVIEW_PERFORMANCE_TRACKER_OPTION' | translate}}
696 697 698
	    				</button>
		    		</div>
		    		<div class="col-sm-6">
699
		    			<small><span class="glyphicon glyphicon-flash" aria-hidden="true"></span> {{'OVERVIEW_PERFORMANCE_TRACKER_EXP' | translate}} <strong>{{'OVERVIEW_PERFORMANCE_TRACKER_EXP2' | translate}}</strong> {{'OVERVIEW_PERFORMANCE_TRACKER_EXP3' | translate}}</small>
700 701 702 703 704 705 706 707
		    		</div>
		    	</div>
		    </div>
		  </div>
		</form>
      </div>
      <div class="modal-footer">
      	<div class="whatsspy-contact-options">
708
	      	<button type="submit" data-ng-click="submitConfigEdit();" class="btn btn-success"><span class="glyphicon glyphicon-ok-circle" aria-hidden="true"></span> {{'OVERVIEW_PERFORMANCE_SAVE' | translate}}</button> 
709
		</div>
710
        <button type="button" class="btn btn-default" data-dismiss="modal">{{'OVERVIEW_PERFORMANCE_CLOSE' | translate}}</button>
711 712 713
      </div>
    </div>
  </div>
Maikel Zweerink's avatar
Maikel Zweerink committed
714
</div>