mirror of
https://github.com/grocy/grocy.git
synced 2025-08-29 09:16:31 +00:00
Make Userfields reorderable (closes #1134)
This commit is contained in:
@@ -49,7 +49,12 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="name">{{ $__t('Name') }}</label>
|
||||
<label for="name">
|
||||
{{ $__t('Name') }}
|
||||
<i class="fas fa-question-circle text-muted"
|
||||
data-toggle="tooltip"
|
||||
title="{{ $__t('This is the internal field name, e. g. for the API') }}"></i>
|
||||
</label>
|
||||
<input type="text"
|
||||
class="form-control"
|
||||
required
|
||||
@@ -61,7 +66,12 @@
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="name">{{ $__t('Caption') }}</label>
|
||||
<label for="name">
|
||||
{{ $__t('Caption') }}
|
||||
<i class="fas fa-question-circle text-muted"
|
||||
data-toggle="tooltip"
|
||||
title="{{ $__t('This is used to display the field on the frontend') }}"></i>
|
||||
</label>
|
||||
<input type="text"
|
||||
class="form-control"
|
||||
required
|
||||
@@ -71,6 +81,15 @@
|
||||
<div class="invalid-feedback">{{ $__t('A caption is required') }}</div>
|
||||
</div>
|
||||
|
||||
@include('components.numberpicker', array(
|
||||
'id' => 'sort_number',
|
||||
'label' => 'Sort number',
|
||||
'min' => 0,
|
||||
'value' => $userfield->sort_number,
|
||||
'isRequired' => false,
|
||||
'hint' => $__t('Multiple Userfields will be ordered by that number on the input form')
|
||||
))
|
||||
|
||||
<div class="form-group">
|
||||
<label for="type">{{ $__t('Type') }}</label>
|
||||
<select required
|
||||
|
@@ -92,6 +92,7 @@
|
||||
<th>{{ $__t('Name') }}</th>
|
||||
<th>{{ $__t('Caption') }}</th>
|
||||
<th>{{ $__t('Type') }}</th>
|
||||
<th>{{ $__t('Sort number') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="d-none">
|
||||
@@ -125,6 +126,9 @@
|
||||
<td>
|
||||
{{ $__t($userfield->type) }}
|
||||
</td>
|
||||
<td>
|
||||
{{ $userfield->sort_number }}
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
|
Reference in New Issue
Block a user