mirror of
				https://github.com/grocy/grocy.git
				synced 2025-10-31 02:36:54 +00:00 
			
		
		
		
	Added the possibility to merge chores
This commit is contained in:
		| @@ -116,6 +116,21 @@ | ||||
| 							title="{{ $__t('Delete this item') }}"> | ||||
| 							<i class="fas fa-trash"></i> | ||||
| 						</a> | ||||
| 						<div class="dropdown d-inline-block"> | ||||
| 							<button class="btn btn-sm btn-light text-secondary" | ||||
| 								type="button" | ||||
| 								data-toggle="dropdown"> | ||||
| 								<i class="fas fa-ellipsis-v"></i> | ||||
| 							</button> | ||||
| 							<div class="table-inline-menu dropdown-menu dropdown-menu-right"> | ||||
| 								<a class="dropdown-item merge-chores-button" | ||||
| 									data-chore-id="{{ $chore->id }}" | ||||
| 									type="button" | ||||
| 									href="#"> | ||||
| 									<span class="dropdown-item-text">{{ $__t('Merge') }}</span> | ||||
| 								</a> | ||||
| 							</div> | ||||
| 						</div> | ||||
| 					</td> | ||||
| 					<td> | ||||
| 						{{ $chore->name }} | ||||
| @@ -138,4 +153,55 @@ | ||||
| 		</table> | ||||
| 	</div> | ||||
| </div> | ||||
|  | ||||
| <div class="modal fade" | ||||
| 	id="merge-chores-modal" | ||||
| 	tabindex="-1"> | ||||
| 	<div class="modal-dialog"> | ||||
| 		<div class="modal-content text-center"> | ||||
| 			<div class="modal-header"> | ||||
| 				<h4 class="modal-title w-100">{{ $__t('Merge chores') }}</h4> | ||||
| 			</div> | ||||
| 			<div class="modal-body"> | ||||
| 				<div class="form-group"> | ||||
| 					<label for="merge-chores-keep">{{ $__t('Chore to keep') }} <i class="fas fa-question-circle text-muted" | ||||
| 							data-toggle="tooltip" | ||||
| 							data-trigger="hover click" | ||||
| 							title="{{ $__t('After merging, this chore will be kept') }}"></i> | ||||
| 					</label> | ||||
| 					<select class="custom-control custom-select" | ||||
| 						id="merge-chores-keep"> | ||||
| 						<option></option> | ||||
| 						@foreach($chores as $chore) | ||||
| 						<option value="{{ $chore->id }}">{{ $chore->name }}</option> | ||||
| 						@endforeach | ||||
| 					</select> | ||||
| 				</div> | ||||
| 				<div class="form-group"> | ||||
| 					<label for="merge-chores-remove">{{ $__t('Chore to remove') }} <i class="fas fa-question-circle text-muted" | ||||
| 							data-toggle="tooltip" | ||||
| 							data-trigger="hover click" | ||||
| 							title="{{ $__t('After merging, all occurences of this chore will be replaced by the kept chore (means this chore will not exist anymore)') }}"></i> | ||||
| 					</label> | ||||
| 					<select class="custom-control custom-select" | ||||
| 						id="merge-chores-remove"> | ||||
| 						<option></option> | ||||
| 						@foreach($chores as $chore) | ||||
| 						<option value="{{ $chore->id }}">{{ $chore->name }}</option> | ||||
| 						@endforeach | ||||
| 					</select> | ||||
| 				</div> | ||||
| 			</div> | ||||
| 			<div class="modal-footer"> | ||||
| 				<button type="button" | ||||
| 					class="btn btn-secondary" | ||||
| 					data-dismiss="modal">{{ $__t('Cancel') }}</button> | ||||
| 				<button id="merge-chores-save-button" | ||||
| 					type="button" | ||||
| 					class="btn btn-primary" | ||||
| 					data-dismiss="modal">{{ $__t('OK') }}</button> | ||||
| 			</div> | ||||
| 		</div> | ||||
| 	</div> | ||||
| </div> | ||||
| @stop | ||||
|   | ||||
		Reference in New Issue
	
	Block a user