Skip to content

Commit a75cfa2

Browse files
committed
Feature: Added data type context for select options with "URL:" and "Data:" labels, including translations
1 parent 1dd744e commit a75cfa2

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

resources/lang/en-US/admin/settings/general.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,12 +360,13 @@
360360
'label2_2d_type' => '2D Barcode Type',
361361
'label2_2d_type_help' => 'Format for 2D barcodes',
362362
'label2_2d_target' => '2D Barcode Target',
363-
'label2_2d_target_help' => 'The URL the 2D barcode points to when scanned',
363+
'label2_2d_target_help' => 'The data that will be contained in the 2D barcode',
364364
'label2_fields' => 'Field Definitions',
365365
'label2_fields_help' => 'Fields can be added, removed, and reordered in the left column. For each field, multiple options for Label and DataSource can be added, removed, and reordered in the right column.',
366366
'help_asterisk_bold' => 'Text entered as <code>**text**</code> will be displayed as bold',
367367
'help_blank_to_use' => 'Leave blank to use the value from <code>:setting_name</code>',
368368
'help_default_will_use' => '<code>:default</code> will use the value from <code>:setting_name</code>. <br>Note that the value of the barcodes must comply with the respective barcode spec in order to be successfully generated. Please see <a href="https://snipe-it.readme.io/docs/barcodes">the documentation <i class="fa fa-external-link"></i></a> for more details. ',
369+
'data' => 'Data',
369370
'default' => 'Default',
370371
'none' => 'None',
371372
'google_callback_help' => 'This should be entered as the callback URL in your Google OAuth app settings in your organization&apos;s <strong><a href="https://console.cloud.google.com/" target="_blank">Google developer console <i class="fa fa-external-link" aria-hidden="true"></i></a></strong>.',

resources/views/settings/labels.blade.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -205,11 +205,11 @@ class="table table-striped snipe-table"
205205
</div>
206206
<div class="col-md-9">
207207
{{ Form::select('label2_2d_target', [
208-
'hardware_id' => '/hardware/{id} ('.trans('admin/settings/general.default').')',
209-
'ht_tag' => '/ht/{asset_tag}',
210-
'plain_asset_tag' => trans('general.asset_tag'),
211-
'plain_serial_number' => trans('general.serial_number'),
212-
], old('label2_2d_target', $setting->label2_2d_target), [ 'class'=>'select2 col-md-4', 'aria-label'=>'label2_2d_target' ]) }}
208+
'hardware_id' => trans('general.url') .': /hardware/{id} ('.trans('admin/settings/general.default').')',
209+
'ht_tag' => trans('general.url') .': /ht/{asset_tag}',
210+
'plain_asset_tag' => trans('admin/settings/general.data') .': '. trans('general.asset_tag') .' {asset_tag}',
211+
'plain_serial_number' => trans('admin/settings/general.data') .': '. trans('general.serial_number') .' {serial}',
212+
], old('label2_2d_target', $setting->label2_2d_target), [ 'class'=>'select2 col-md-4', 'aria-label'=>'label2_2d_target' ]) }}
213213
{!! $errors->first('label2_2d_target', '<span class="alert-msg" aria-hidden="true"><i class="fas fa-times" aria-hidden="true"></i> :message</span>') !!}
214214
<p class="help-block">{{ trans('admin/settings/general.label2_2d_target_help') }}</p>
215215
</div>

0 commit comments

Comments
 (0)