| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | @extends('layout.default') | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2019-05-01 20:19:18 +02:00
										 |  |  | @section('title', $__t('Batteries journal')) | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | @section('activeNav', 'batteriesjournal') | 
					
						
							|  |  |  | @section('viewJsName', 'batteriesjournal') | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | @section('content') | 
					
						
							|  |  |  | <div class="row"> | 
					
						
							|  |  |  | 	<div class="col"> | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 		<h2 class="title">@yield('title')</h2> | 
					
						
							| 
									
										
										
										
											2020-11-07 14:53:45 +01:00
										 |  |  | 		<div class="float-right"> | 
					
						
							|  |  |  | 			<button class="btn btn-outline-dark d-md-none mt-2 order-1 order-md-3" | 
					
						
							|  |  |  | 				type="button" | 
					
						
							|  |  |  | 				data-toggle="collapse" | 
					
						
							|  |  |  | 				data-target="#table-filter-row"> | 
					
						
							|  |  |  | 				<i class="fas fa-filter"></i> | 
					
						
							|  |  |  | 			</button> | 
					
						
							|  |  |  | 		</div> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 	</div> | 
					
						
							|  |  |  | </div> | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-11-08 15:09:10 +01:00
										 |  |  | <hr class="my-2"> | 
					
						
							| 
									
										
										
										
											2020-10-31 18:37:10 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-11-07 14:53:45 +01:00
										 |  |  | <div class="row collapse d-md-flex" | 
					
						
							|  |  |  | 	id="table-filter-row"> | 
					
						
							| 
									
										
										
										
											2019-03-04 17:43:12 +01:00
										 |  |  | 	<div class="col-xs-12 col-md-6 col-xl-3"> | 
					
						
							| 
									
										
										
										
											2020-10-31 18:37:10 +01:00
										 |  |  | 		<div class="input-group"> | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 			<div class="input-group-prepend"> | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 				<span class="input-group-text"><i class="fas fa-search"></i></span> | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 			</div> | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 			<input type="text" | 
					
						
							|  |  |  | 				id="search" | 
					
						
							|  |  |  | 				class="form-control" | 
					
						
							|  |  |  | 				placeholder="{{ $__t('Search') }}"> | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 		</div> | 
					
						
							| 
									
										
										
										
											2019-03-04 17:43:12 +01:00
										 |  |  | 	</div> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 	<div class="col-xs-12 col-md-6 col-xl-3"> | 
					
						
							| 
									
										
										
										
											2020-10-31 18:37:10 +01:00
										 |  |  | 		<div class="input-group"> | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 			<div class="input-group-prepend"> | 
					
						
							| 
									
										
										
										
											2020-10-31 18:37:10 +01:00
										 |  |  | 				<span class="input-group-text"><i class="fas fa-filter"></i> {{ $__t('Battery') }}</span> | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 			</div> | 
					
						
							| 
									
										
										
										
											2020-11-16 19:10:29 +01:00
										 |  |  | 			<select class="custom-control custom-select" | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 				id="battery-filter"> | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 				<option value="all">{{ $__t('All') }}</option> | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 				@foreach($batteries as $battery) | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 				<option value="{{ $battery->id }}">{{ $battery->name }}</option> | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 				@endforeach | 
					
						
							| 
									
										
										
										
											2020-04-19 08:51:02 -04:00
										 |  |  | 			</select> | 
					
						
							|  |  |  | 		</div> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 	</div> | 
					
						
							| 
									
										
										
										
											2020-11-07 14:53:45 +01:00
										 |  |  | 	<div class="col"> | 
					
						
							|  |  |  | 		<div class="float-right"> | 
					
						
							|  |  |  | 			<a id="clear-filter-button" | 
					
						
							|  |  |  | 				class="btn btn-sm btn-outline-info" | 
					
						
							|  |  |  | 				href="#"> | 
					
						
							|  |  |  | 				{{ $__t('Clear filter') }} | 
					
						
							|  |  |  | 			</a> | 
					
						
							|  |  |  | 		</div> | 
					
						
							|  |  |  | 	</div> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | </div> | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-10-31 18:37:10 +01:00
										 |  |  | <div class="row mt-2"> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 	<div class="col"> | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 		<table id="batteries-journal-table" | 
					
						
							| 
									
										
										
										
											2020-11-07 14:53:45 +01:00
										 |  |  | 			class="table table-sm table-striped nowrap w-100"> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 			<thead> | 
					
						
							|  |  |  | 				<tr> | 
					
						
							| 
									
										
										
										
											2020-11-11 22:28:05 +01:00
										 |  |  | 					<th class="border-right"><a class="text-muted change-table-columns-visibility-button" | 
					
						
							|  |  |  | 							data-toggle="tooltip" | 
					
						
							| 
									
										
										
										
											2020-11-11 21:11:17 +01:00
										 |  |  | 							data-toggle="tooltip" | 
					
						
							| 
									
										
										
										
											2020-12-16 18:18:03 +01:00
										 |  |  | 							title="{{ $__t('Table options') }}" | 
					
						
							| 
									
										
										
										
											2020-11-11 21:11:17 +01:00
										 |  |  | 							data-table-selector="#batteries-journal-table" | 
					
						
							|  |  |  | 							href="#"><i class="fas fa-eye"></i></a> | 
					
						
							|  |  |  | 					</th> | 
					
						
							| 
									
										
										
										
											2019-05-01 20:19:18 +02:00
										 |  |  | 					<th>{{ $__t('Battery') }}</th> | 
					
						
							|  |  |  | 					<th>{{ $__t('Tracked time') }}</th> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 				</tr> | 
					
						
							|  |  |  | 			</thead> | 
					
						
							| 
									
										
										
										
											2019-01-05 20:06:35 +01:00
										 |  |  | 			<tbody class="d-none"> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 				@foreach($chargeCycles as $chargeCycleEntry) | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 				<tr id="charge-cycle-{{ $chargeCycleEntry->id }}-row" | 
					
						
							|  |  |  | 					class="@if($chargeCycleEntry->undone == 1) text-muted @endif"> | 
					
						
							| 
									
										
										
										
											2019-03-09 10:49:26 +01:00
										 |  |  | 					<td class="fit-content border-right"> | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 						<a class="btn btn-secondary btn-sm undo-battery-execution-button @if($chargeCycleEntry->undone == 1) disabled @endif permission-BATTERIES_UNDO_CHARGE_CYCLE" | 
					
						
							|  |  |  | 							href="#" | 
					
						
							|  |  |  | 							data-charge-cycle-id="{{ $chargeCycleEntry->id }}" | 
					
						
							|  |  |  | 							data-toggle="tooltip" | 
					
						
							|  |  |  | 							data-placement="left" | 
					
						
							|  |  |  | 							title="{{ $__t('Undo charge cycle') }}"> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 							<i class="fas fa-undo"></i> | 
					
						
							|  |  |  | 						</a> | 
					
						
							|  |  |  | 					</td> | 
					
						
							|  |  |  | 					<td> | 
					
						
							| 
									
										
										
										
											2018-11-18 12:58:15 +01:00
										 |  |  | 						<span class="name-anchor @if($chargeCycleEntry->undone == 1) text-strike-through @endif">{{ FindObjectInArrayByPropertyValue($batteries, 'id', $chargeCycleEntry->battery_id)->name }}</span> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 						@if($chargeCycleEntry->undone == 1) | 
					
						
							|  |  |  | 						<br> | 
					
						
							| 
									
										
										
										
											2019-05-01 20:19:18 +02:00
										 |  |  | 						{{ $__t('Undone on') . ' ' . $chargeCycleEntry->undone_timestamp }} | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 						<time class="timeago timeago-contextual" | 
					
						
							|  |  |  | 							datetime="{{ $chargeCycleEntry->undone_timestamp }}"></time> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 						@endif | 
					
						
							|  |  |  | 					</td> | 
					
						
							|  |  |  | 					<td> | 
					
						
							|  |  |  | 						{{ $chargeCycleEntry->tracked_time }} | 
					
						
							| 
									
										
										
										
											2020-08-31 20:32:50 +02:00
										 |  |  | 						<time class="timeago timeago-contextual" | 
					
						
							|  |  |  | 							datetime="{{ $chargeCycleEntry->tracked_time }}"></time> | 
					
						
							| 
									
										
										
										
											2018-10-27 17:26:00 +02:00
										 |  |  | 					</td> | 
					
						
							|  |  |  | 				</tr> | 
					
						
							|  |  |  | 				@endforeach | 
					
						
							|  |  |  | 			</tbody> | 
					
						
							|  |  |  | 		</table> | 
					
						
							|  |  |  | 	</div> | 
					
						
							|  |  |  | </div> | 
					
						
							|  |  |  | @stop |