Compare commits

...

56 Commits

Author SHA1 Message Date
snipe df38d7e3ed Merge remote-tracking branch 'origin/develop'
Signed-off-by: snipe <snipe@snipe.net>

# Conflicts:
#	config/version.php
2025-02-27 12:22:30 +00:00
snipe b8799f8038 Bumped bash
Signed-off-by: snipe <snipe@snipe.net>
2025-02-27 12:21:28 +00:00
snipe dc619bb0dc Merge pull request #16365 from marcusmoore/chore/migrate-checkbox-helpers-pt6
Replace calls to Form::checkbox pt6
2025-02-26 23:54:50 +00:00
Marcus Moore af6d9e4a00 Replace Form::checkbox on custom report pages 2025-02-26 15:15:48 -08:00
snipe 8c8af3062e Merge pull request #16354 from snipe/dont_checkin_for_pending_on_asset_update
Allow pending as an asset status type that does not automatically check the asset in
2025-02-26 21:05:11 +00:00
snipe 44dd061619 Merge remote-tracking branch 'origin/develop' 2025-02-26 20:55:57 +00:00
snipe 2ff47edb94 Merge pull request #16361 from Godmartinz/acceptancer_reminder_unlisted_email_info
Fixed acceptance reminder command lag on users with no associated email
2025-02-26 20:33:02 +00:00
snipe d923d29bad Merge pull request #16360 from spencerrlongg/bug/sc-28537
Add Safety Around Bulk Status Update
2025-02-26 20:32:19 +00:00
Godfrey M 899119ae2d changes output to a table 2025-02-26 12:30:19 -08:00
snipe 7603a932b1 Merge remote-tracking branch 'origin/develop' 2025-02-26 20:29:42 +00:00
snipe e031de8e49 Merge pull request #16363 from snipe/added_a_few_more_no_interaction_calls
Added `--no-interaction` to additional passport commands
2025-02-26 20:19:37 +00:00
snipe a81c520d93 Follow up for #16341
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 20:15:09 +00:00
Godfrey M 8352e81228 fix unaccepted reminder test 2025-02-26 11:50:08 -08:00
Godfrey M fd0174ff32 remove unwanted changes to livewire 2025-02-26 11:31:41 -08:00
Godfrey M cc26aa02b2 fix acceptance reminder command no email list 2025-02-26 11:25:21 -08:00
snipe 616f3558dd Update example env
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 19:14:25 +00:00
spencerrlongg d6e266cec1 make super safe 2025-02-26 13:11:49 -06:00
snipe 138e7acc13 Merge remote-tracking branch 'origin/develop' 2025-02-26 12:47:54 +00:00
snipe 31516d7f24 Merge pull request #16356 from snipe/added_fields_for_model_search
Added name, model_number and notes for strict search
2025-02-26 12:46:13 +00:00
snipe e79af255aa Added name, model_number and notes for strict search
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 12:43:54 +00:00
snipe e863d3e7e5 Merge remote-tracking branch 'origin/develop' 2025-02-26 12:02:00 +00:00
snipe 5b0d7f4064 One more chonk
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 12:01:50 +00:00
snipe c8e401f5ed Merge remote-tracking branch 'origin/develop' 2025-02-26 11:59:53 +00:00
snipe 2f6af10c5d Bumped chunk for custom report
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 11:59:34 +00:00
snipe 3ba20a8e28 Merge remote-tracking branch 'origin/develop' 2025-02-26 11:39:10 +00:00
snipe afabda9235 Remove greater than 0 for alert threshold - fixes FD-47040
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 11:38:33 +00:00
snipe 1618c9ae8e Changed confirmation message
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 10:53:41 +00:00
snipe 5344ef4a1a Allow pending as an asset status that does not automatically check the asset in
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 10:46:38 +00:00
snipe ebae63752f Merge remote-tracking branch 'origin/develop' 2025-02-26 10:25:18 +00:00
snipe 16420b1e00 Audit Log Number under Days to next Audit [sc-28530]
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 10:25:07 +00:00
snipe 62f66e724e Drop errors to warnings to stop pooping on rollbar
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 09:54:13 +00:00
snipe 9b0ea51d35 Moved composer clear commands to after composer install per #16334
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 09:37:31 +00:00
snipe 8bc73901cf Merge remote-tracking branch 'origin/develop' 2025-02-26 08:25:35 +00:00
snipe 992214fc66 Check for adminuser withTrashed
Signed-off-by: snipe <snipe@snipe.net>
2025-02-26 08:25:22 +00:00
snipe b4f70d9244 Merge remote-tracking branch 'origin/develop' 2025-02-26 07:16:59 +00:00
snipe 93dab12461 Merge pull request #16342 from snipe/nicer_upgrade_script
Nicer upgrade.php UI
2025-02-26 07:16:28 +00:00
snipe 21e9f2bba3 Merge remote-tracking branch 'origin/develop' 2025-02-26 07:11:22 +00:00
snipe ea0f105180 Merge pull request #16347 from marcusmoore/chore/migrate-checkbox-helpers-pt4
Replace calls to Form::checkbox pt4
2025-02-26 07:05:38 +00:00
snipe 5b6da0c1e8 Merge pull request #16348 from marcusmoore/chore/migrate-checkbox-helpers-pt5
Replace calls to Form::checkbox pt5
2025-02-26 07:05:22 +00:00
snipe 4d7655bbe1 Merge pull request #16346 from marcusmoore/chore/migrate-checkbox-helpers-pt3
Replace calls to Form::checkbox pt3
2025-02-26 07:04:27 +00:00
snipe 5e3855ee5b Merge pull request #16345 from marcusmoore/fixes/update-custom-fields
Fixed renaming custom fields
2025-02-26 07:03:40 +00:00
Marcus Moore e01226a174 Replace Form::checkbox on saml settings page 2025-02-25 17:31:05 -08:00
Marcus Moore f9ccf32af4 Replace Form::checkbox on ldap settings page 2025-02-25 17:22:44 -08:00
Marcus Moore 2c5170a218 Replace Form::checkbox on security settings page 2025-02-25 17:09:25 -08:00
Marcus Moore 15f842e2dc Replace Form::checkbox on bulk user edit page 2025-02-25 16:00:46 -08:00
Marcus Moore 46b31dfe14 Replace Form::checkbox on user create and edit page 2025-02-25 14:32:39 -08:00
Marcus Moore d88c79366c Replace Form::checkbox on google settings page 2025-02-25 14:27:07 -08:00
Marcus Moore de330a47cd Replace Form::checkbox on asset tag settings page 2025-02-25 14:25:02 -08:00
Marcus Moore ecd7dc2094 Replace Form::checkbox on alert settings page 2025-02-25 14:23:26 -08:00
Marcus Moore 510946e0eb Replace Form::checkbox in logo upload partial 2025-02-25 14:20:43 -08:00
Marcus Moore 37e4a13979 Replace Form::checkbox in image upload partial 2025-02-25 14:15:12 -08:00
Marcus Moore c73d64cdbc Remove manual doctrine mapping for enums 2025-02-25 13:37:23 -08:00
snipe 037d2d9e84 Merge pull request #16341 from uberbrady/fix_passport_install_no_interaction
Fixes #16331 - Don't make passport:install command require user input
2025-02-25 16:43:49 +00:00
Brady Wetherington bce2007b97 Fixes #16331 - Don't make passport:install command require user input 2025-02-25 16:38:40 +00:00
snipe 881f4e3d6a Merge remote-tracking branch 'origin/develop' 2025-02-25 14:43:57 +00:00
snipe b141945add Updated branch
Signed-off-by: snipe <snipe@snipe.net>
2025-02-25 12:18:52 +00:00
33 changed files with 166 additions and 138 deletions
+1 -1
View File
@@ -99,7 +99,7 @@ PASSPORT_COOKIE_NAME='snipeit_passport_token'
COOKIE_DOMAIN=null
SECURE_COOKIES=false
API_TOKEN_EXPIRATION_YEARS=15
BS_TABLE_STORAGE=cookieStorage
BS_TABLE_STORAGE=localStorage
BS_TABLE_DEEPLINK=true
# --------------------------------------------
+1 -1
View File
@@ -67,7 +67,7 @@ jobs:
run: |
php artisan key:generate
php artisan migrate --force
php artisan passport:install
php artisan passport:install --no-interaction
chmod -R 777 storage bootstrap/cache
- name: Execute tests (Unit and Feature tests) via PHPUnit
+1 -1
View File
@@ -65,7 +65,7 @@ jobs:
run: |
php artisan key:generate
php artisan migrate --force
php artisan passport:install
php artisan passport:install --no-interaction
chmod -R 777 storage bootstrap/cache
- name: Execute tests (Unit and Feature tests) via PHPUnit
@@ -64,6 +64,7 @@ class SendAcceptanceReminder extends Command
->groupBy(function($item) {
return $item['acceptance']->assignedTo ? $item['acceptance']->assignedTo->id : '';
});
$no_email_list= [];
foreach($unacceptedAssetGroups as $unacceptedAssetGroup) {
// The [0] is weird, but it allows for the item_count to work and grabs the appropriate info for each user.
@@ -72,7 +73,10 @@ class SendAcceptanceReminder extends Command
$locale = $acceptance->assignedTo?->locale;
$email = $acceptance->assignedTo?->email;
if(!$email){
$this->info($acceptance->assignedTo?->present()->fullName().' has no email address.');
$no_email_list[] = [
'id' => $acceptance->assignedTo->id,
'name' => $acceptance->assignedTo->present()->fullName(),
];
}
$item_count = $unacceptedAssetGroup->count();
@@ -86,6 +90,14 @@ class SendAcceptanceReminder extends Command
}
$this->info($count.' users notified.');
$headers = ['ID', 'Name'];
$rows = [];
foreach ($no_email_list as $user) {
$rows[] = [$user['id'], $user['name']];
}
$this->info("The following users do not have an email address:");
$this->table($headers, $rows);
return 0;
}
@@ -77,6 +77,18 @@ class AssetModelsController extends Controller
$assetmodels->onlyTrashed();
}
if ($request->filled('name')) {
$assetmodels = $assetmodels->where('models.name', '=', $request->input('name'));
}
if ($request->filled('model_number')) {
$assetmodels = $assetmodels->where('models.model_number', '=', $request->input('model_number'));
}
if ($request->filled('notes')) {
$assetmodels = $assetmodels->where('models.notes', '=', $request->input('notes'));
}
if ($request->filled('category_id')) {
$assetmodels = $assetmodels->where('models.category_id', '=', $request->input('category_id'));
}
@@ -290,10 +290,12 @@ class StatuslabelsController extends Controller
/**
* Returns a boolean response based on whether the status label
* is one that is deployable.
* is one that is deployable or pending.
*
* This is used by the hardware create/edit view to determine whether
* we should provide a dropdown of users for them to check the asset out to.
* we should provide a dropdown of users for them to check the asset out to,
* and whether we show a warning that the asset will be checked in if it's already
* assigned but the status is changed to one that isn't pending or deployable
*
* @author [A. Gianotto] [<snipe@snipe.net>]
* @since [v4.0]
@@ -301,7 +303,7 @@ class StatuslabelsController extends Controller
public function checkIfDeployable($id) : string
{
$statuslabel = Statuslabel::findOrFail($id);
if ($statuslabel->getStatuslabelType() == 'deployable') {
if (($statuslabel->getStatuslabelType() == 'pending') || ($statuslabel->getStatuslabelType() == 'deployable')) {
return '1';
}
@@ -340,15 +340,14 @@ class AssetsController extends Controller
$status = Statuslabel::find($request->input('status_id'));
// This is a non-deployable status label - we should check the asset back in.
if (($status && $status->getStatuslabelType() != 'deployable') && ($target = $asset->assignedTo)) {
// This is an archived or undeployable - we should check the asset back in.
// Pending is allowed here
if (($status) && (($status->getStatuslabelType() != 'pending') && ($status->getStatuslabelType() != 'deployable')) && ($target = $asset->assignedTo)) {
$originalValues = $asset->getRawOriginal();
$asset->assigned_to = null;
$asset->assigned_type = null;
$asset->accepted = null;
event(new CheckoutableCheckedIn($asset, $target, auth()->user(), 'Checkin on asset update', date('Y-m-d H:i:s'), $originalValues));
event(new CheckoutableCheckedIn($asset, $target, auth()->user(), 'Checkin on asset update with '.$status->getStatuslabelType().' status', date('Y-m-d H:i:s'), $originalValues));
}
if ($asset->assigned_to == '') {
@@ -358,7 +358,11 @@ class BulkAssetsController extends Controller
* to someone/something.
*/
if ($request->filled('status_id')) {
$updated_status = Statuslabel::find($request->input('status_id'));
try {
$updated_status = Statuslabel::findOrFail($request->input('status_id'));
} catch (ModelNotFoundException $e) {
return redirect($bulk_back_url)->with('error', trans('admin/statuslabels/message.does_not_exist'));
}
// We cannot assign a non-deployable status type if the asset is already assigned.
// This could probably be added to a form request.
@@ -366,7 +370,7 @@ class BulkAssetsController extends Controller
// Otherwise we need to make sure the status type is still a deployable one.
if (
($asset->assigned_to == '')
|| ($updated_status->deployable == '1') && ($asset->assetstatus->deployable == '1')
|| ($updated_status->deployable == '1') && ($asset->assetstatus?->deployable == '1')
) {
$this->update_array['status_id'] = $updated_status->id;
}
+1 -1
View File
@@ -40,7 +40,7 @@ class DashboardController extends Controller
if ((! file_exists(storage_path().'/oauth-private.key')) || (! file_exists(storage_path().'/oauth-public.key'))) {
Artisan::call('migrate', ['--force' => true]);
\Artisan::call('passport:install');
Artisan::call('passport:install', ['--no-interaction' => true]);
}
return view('dashboard')->with('asset_stats', $asset_stats)->with('counts', $counts);
+2 -2
View File
@@ -266,7 +266,7 @@ class ReportsController extends Controller
$actionlogs = Actionlog::with('item', 'user', 'target', 'location', 'adminuser')
->orderBy('created_at', 'DESC')
->chunk(20, function ($actionlogs) use ($handle) {
->chunk(500, function ($actionlogs) use ($handle) {
$executionTime = microtime(true) - $_SERVER['REQUEST_TIME_FLOAT'];
Log::debug('Walking results: '.$executionTime);
$count = 0;
@@ -748,7 +748,7 @@ class ReportsController extends Controller
}
Log::debug($assets->toSql());
$assets->orderBy('assets.id', 'ASC')->chunk(20, function ($assets) use ($handle, $customfields, $request) {
$assets->orderBy('assets.id', 'ASC')->chunk(500, function ($assets) use ($handle, $customfields, $request) {
$executionTime = microtime(true) - $_SERVER['REQUEST_TIME_FLOAT'];
Log::debug('Walking results: '.$executionTime);
+1 -1
View File
@@ -256,7 +256,7 @@ class SettingsController extends Controller
Artisan::call('migrate', ['--force' => true]);
if ((! file_exists(storage_path().'/oauth-private.key')) || (! file_exists(storage_path().'/oauth-public.key'))) {
Artisan::call('migrate', ['--path' => 'vendor/laravel/passport/database/migrations', '--force' => true]);
Artisan::call('passport:install');
Artisan::call('passport:install', ['--no-interaction' => true]);
}
return view('setup/migrate')
@@ -26,7 +26,7 @@ class StoreNotificationSettings extends FormRequest
return [
'alert_email' => 'email_array|nullable',
'admin_cc_email' => 'email_array|nullable',
'alert_threshold' => 'numeric|nullable|gt:0',
'alert_threshold' => 'numeric|nullable',
'alert_interval' => 'numeric|nullable|gt:0',
'audit_warning_days' => 'numeric|nullable',
'due_checkin_days' => 'numeric|nullable|gt:0',
+2 -2
View File
@@ -115,7 +115,7 @@ class CheckoutableListener
}
return redirect()->back()->with('warning', ucfirst(Setting::getSettings()->webhook_selected) .trans('admin/settings/message.webhook.webhook_fail') );
} catch (Exception $e) {
Log::error(ucfirst(Setting::getSettings()->webhook_selected) . ' webhook notification failed:', [
Log::warning(ucfirst(Setting::getSettings()->webhook_selected) . ' webhook notification failed:', [
'error' => $e->getMessage(),
'webhook_endpoint' => Setting::getSettings()->webhook_endpoint,
'event' => $event,
@@ -211,7 +211,7 @@ class CheckoutableListener
return redirect()->back()->with('warning', ucfirst(Setting::getSettings()->webhook_selected) . trans('admin/settings/message.webhook.webhook_fail'));
}
} catch (Exception $e) {
Log::error(ucfirst(Setting::getSettings()->webhook_selected) . ' webhook notification failed:', [
Log::warning(ucfirst(Setting::getSettings()->webhook_selected) . ' webhook notification failed:', [
'error' => $e->getMessage(),
'webhook_endpoint' => Setting::getSettings()->webhook_endpoint,
'event' => $event,
+11 -5
View File
@@ -293,16 +293,22 @@ class Actionlog extends SnipeModel
public function daysUntilNextAudit($monthInterval = 12, $asset = null)
{
$now = Carbon::now();
$last_audit_date = $this->created_at;
$next_audit = $last_audit_date->addMonth($monthInterval);
$next_audit_days = $now->diffInDays($next_audit);
$last_audit_date = $this->created_at; // this is the action log's created at, not the asset itself
$next_audit = $last_audit_date->addMonth($monthInterval); // this actually *modifies* the $last_audit_date
$next_audit_days = round($now->diffInDays($next_audit, true));
$override_default_next = $next_audit;
// Override the default setting for interval if the asset has its own next audit date
if (($asset) && ($asset->next_audit_date)) {
$override_default_next = \Carbon::parse($asset->next_audit_date);
$next_audit_days = $override_default_next->diffInDays($now);
$override_default_next = Carbon::parse($asset->next_audit_date);
$next_audit_days = round($override_default_next->diffInDays($now, true));
}
// Show as negative number if the next audit date is before the audit date we're looking at
if ($this->created_at > $override_default_next) {
$next_audit_days = '-'.$next_audit_days;
}
return $next_audit_days;
}
+1 -1
View File
@@ -234,7 +234,7 @@ class AssetModel extends SnipeModel
*/
public function adminuser()
{
return $this->belongsTo(\App\Models\User::class, 'created_by');
return $this->belongsTo(\App\Models\User::class, 'created_by')->withTrashed();
}
-5
View File
@@ -149,11 +149,6 @@ class CustomField extends Model
return true;
}
// This is just a dumb thing we have to include because Laraval/Doctrine doesn't
// play well with enums or a table that EVER had enums. :(
$platform = Schema::getConnection()->getDoctrineSchemaManager()->getDatabasePlatform();
$platform->registerDoctrineTypeMapping('enum', 'string');
// Rename the field if the name has changed
Schema::table(self::$table_name, function ($table) use ($custom_field) {
$table->renameColumn($custom_field->convertUnicodeDbSlug($custom_field->getOriginal('name')), $custom_field->convertUnicodeDbSlug());
+6 -6
View File
@@ -1,10 +1,10 @@
<?php
return array (
'app_version' => 'v8.0.1',
'full_app_version' => 'v8.0.1 - build 16992-g18c7cbbbb',
'build_version' => '16992',
'app_version' => 'v8.0.2',
'full_app_version' => 'v8.0.2 - build 17048-g44dd06161',
'build_version' => '17048',
'prerelease_version' => '',
'hash_version' => 'g18c7cbbbb',
'full_hash' => 'v8.0.1-28-g18c7cbbbb',
'branch' => 'develop',
'hash_version' => 'g44dd06161',
'full_hash' => 'v8.0.2-54-g44dd06161',
'branch' => 'master',
);
+1 -1
View File
@@ -56,7 +56,7 @@ return [
'asset_location_update_actual' => 'Update only actual location',
'asset_not_deployable' => 'That asset status is not deployable. This asset cannot be checked out.',
'asset_not_deployable_checkin' => 'That asset status is not deployable. Using this status label will checkin the asset.',
'asset_deployable' => 'That status is deployable. This asset can be checked out.',
'asset_deployable' => 'This asset can be checked out.',
'processing_spinner' => 'Processing... (This might take a bit of time on large files)',
'optional_infos' => 'Optional Information',
'order_details' => 'Order Related Information',
+1 -1
View File
@@ -164,7 +164,7 @@
</li>
@endif
@if ($model->created_by)
@if ($model->adminuser)
<li>{{ trans('general.created_by') }}:
{{ $model->adminuser->present()->name() }}
</li>
@@ -4,7 +4,7 @@
<div class="form-group{{ $errors->has('image_delete') ? ' has-error' : '' }}">
<div class="col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('image_delete', '1', old('image_delete'), ['aria-label'=>'image_delete']) }}
<input type="checkbox" name="image_delete" value="1" @checked(old('image_delete')) aria-label="image_delete">
{{ trans('general.image_delete') }}
{!! $errors->first('image_delete', '<span class="alert-msg">:message</span>') !!}
</label>
@@ -47,7 +47,7 @@
<div class="col-md-9 col-md-offset-3">
<label id="{{ $logoId }}-deleteCheckbox" for="{{ $logoClearVariable }}" style="font-weight: normal" class="form-control">
{{ Form::checkbox($logoClearVariable, '1', old($logoClearVariable)) }}
<input type="checkbox" name="{{ $logoClearVariable }}" value="1" @checked(old($logoClearVariable))>
Remove current {{ ucwords(str_replace('_', ' ', $logoVariable)) }} image
</label>
</div>
+2 -3
View File
@@ -35,13 +35,12 @@
<thead>
<tr>
<th class="col-sm-1" data-field="file" data-visible="false" data-formatter="auditImageFormatter">{{ trans('admin/hardware/table.image') }}</th>
<th class="col-sm-2" data-field="created_at" data-formatter="dateDisplayFormatter" data-sortable="true" data-searchable="true">{{ trans('general.audit') }}</th>
<th class="col-sm-2" data-field="created_by" data-sortable="true" data-searchable="true" data-formatter="usersLinkObjFormatter">{{ trans('general.admin') }}</th>
<th class="col-sm-2" data-field="created_by" data-sortable="true" data-searchable="true" data-formatter="usersLinkObjFormatter">{{ trans('general.created_by') }}</th>
<th class="col-sm-2" data-field="item" data-sortable="true" data-searchable="true" data-formatter="polymorphicItemFormatter">{{ trans('general.item') }}</th>
<th class="col-sm-1" data-field="location" data-sortable="true" data-searchable="true" data-formatter="locationsLinkObjFormatter">{{ trans('general.location') }}</th>
<th class="col-sm-2" data-field="created_at" data-formatter="dateDisplayFormatter" data-sortable="true" data-searchable="true">{{ trans('general.last_audit') }}</th>
<th class="col-sm-2" data-field="next_audit_date" data-formatter="dateDisplayFormatter">{{ trans('general.next_audit_date') }}</th>
<th class="col-sm-1" data-field="days_to_next_audit">{{ trans('general.days_to_next_audit') }}</th>
<th class="col-sm-2" data-field="note" data-sortable="true" data-searchable="true">{{ trans('general.notes') }}</th>
</tr>
</thead>
+45 -45
View File
@@ -93,152 +93,152 @@
</label>
<label class="form-control">
{{ Form::checkbox('id', '1', $template->checkmarkValue('id')) }}
<input type="checkbox" name="id" value="1" @checked($template->checkmarkValue('id')) />
{{ trans('general.id') }}
</label>
<label class="form-control">
{{ Form::checkbox('company', '1', $template->checkmarkValue('company')) }}
<input type="checkbox" name="company" value="1" @checked($template->checkmarkValue('company')) />
{{ trans('general.company') }}
</label>
<label class="form-control">
{{ Form::checkbox('asset_tag', '1', $template->checkmarkValue('asset_tag')) }}
<input type="checkbox" name="asset_tag" value="1" @checked($template->checkmarkValue('asset_tag')) />
{{ trans('general.asset_tag') }}
</label>
<label class="form-control">
{{ Form::checkbox('asset_name', '1', $template->checkmarkValue('asset_name')) }}
<input type="checkbox" name="asset_name" value="1" @checked($template->checkmarkValue('asset_name')) />
{{ trans('admin/hardware/form.name') }}
</label>
<label class="form-control">
{{ Form::checkbox('manufacturer', '1', $template->checkmarkValue('manufacturer')) }}
<input type="checkbox" name="manufacturer" value="1" @checked($template->checkmarkValue('manufacturer')) />
{{ trans('general.manufacturer') }}
</label>
<label class="form-control">
{{ Form::checkbox('model', '1', $template->checkmarkValue('model')) }}
<input type="checkbox" name="model" value="1" @checked($template->checkmarkValue('model')) />
{{ trans('general.asset_models') }}
</label>
<label class="form-control">
{{ Form::checkbox('category', '1', $template->checkmarkValue('category')) }}
<input type="checkbox" name="category" value="1" @checked($template->checkmarkValue('category')) />
{{ trans('general.category') }}
</label>
<label class="form-control">
{{ Form::checkbox('serial', '1', $template->checkmarkValue('serial')) }}
<input type="checkbox" name="serial" value="1" @checked($template->checkmarkValue('serial')) />
{{ trans('admin/hardware/table.serial') }}
</label>
<label class="form-control">
{{ Form::checkbox('purchase_date', '1', $template->checkmarkValue('purchase_date')) }}
<input type="checkbox" name="purchase_date" value="1" @checked($template->checkmarkValue('purchase_date')) />
{{ trans('admin/licenses/table.purchase_date') }}
</label>
<label class="form-control">
{{ Form::checkbox('purchase_cost', '1', $template->checkmarkValue('purchase_cost')) }}
<input type="checkbox" name="purchase_cost" value="1" @checked($template->checkmarkValue('purchase_cost')) />
{{ trans('admin/hardware/form.cost') }}
</label>
<label class="form-control">
{{ Form::checkbox('eol', '1', $template->checkmarkValue('eol')) }}
<input type="checkbox" name="eol" value="1" @checked($template->checkmarkValue('eol')) />
{{ trans('admin/hardware/form.eol_date') }}
</label>
<label class="form-control">
{{ Form::checkbox('order', '1', $template->checkmarkValue('order')) }}
<input type="checkbox" name="order" value="1" @checked($template->checkmarkValue('order')) />
{{ trans('admin/hardware/form.order') }}
</label>
<label class="form-control">
{{ Form::checkbox('supplier', '1', $template->checkmarkValue('supplier')) }}
<input type="checkbox" name="supplier" value="1" @checked($template->checkmarkValue('supplier')) />
{{ trans('general.suppliers') }}
</label>
<label class="form-control">
{{ Form::checkbox('location', '1', $template->checkmarkValue('location')) }}
<input type="checkbox" name="location" value="1" @checked($template->checkmarkValue('location')) />
{{ trans('general.location') }}
</label>
<label class="form-control" style="margin-left: 25px;">
{{ Form::checkbox('location_address', '1', $template->checkmarkValue('location_address')) }}
<input type="checkbox" name="location_address" value="1" @checked($template->checkmarkValue('location_address')) />
{{ trans('general.address') }}
</label>
<label class="form-control">
{{ Form::checkbox('rtd_location', '1', $template->checkmarkValue('rtd_location')) }}
<input type="checkbox" name="rtd_location" value="1" @checked($template->checkmarkValue('rtd_location')) />
{{ trans('admin/hardware/form.default_location') }}
</label>
<label class="form-control" style="margin-left: 25px;">
{{ Form::checkbox('rtd_location_address', '1', $template->checkmarkValue('rtd_location_address')) }}
<input type="checkbox" name="rtd_location_address" value="1" @checked($template->checkmarkValue('rtd_location_address')) />
{{ trans('general.address') }}
</label>
<label class="form-control">
{{ Form::checkbox('status', '1', $template->checkmarkValue('status')) }}
<input type="checkbox" name="status" value="1" @checked($template->checkmarkValue('status')) />
{{ trans('general.status') }}
</label>
<label class="form-control">
{{ Form::checkbox('warranty', '1', $template->checkmarkValue('warranty')) }}
<input type="checkbox" name="warranty" value="1" @checked($template->checkmarkValue('warranty')) />
{{ trans('admin/hardware/form.warranty') }}
</label>
<label class="form-control">
{{ Form::checkbox('depreciation', '1', $template->checkmarkValue('depreciation')) }}
<input type="checkbox" name="depreciation" value="1" @checked($template->checkmarkValue('depreciation')) />
{{ trans('general.depreciation') }}
</label>
<label class="form-control">
{{ Form::checkbox('checkout_date', '1', $template->checkmarkValue('checkout_date')) }}
<input type="checkbox" name="checkout_date" value="1" @checked($template->checkmarkValue('checkout_date')) />
{{ trans('admin/hardware/table.checkout_date') }}
</label>
<label class="form-control">
{{ Form::checkbox('checkin_date', '1', $template->checkmarkValue('checkin_date')) }}
<input type="checkbox" name="checkin_date" value="1" @checked($template->checkmarkValue('checkin_date')) />
{{ trans('admin/hardware/table.last_checkin_date') }}
</label>
<label class="form-control">
{{ Form::checkbox('expected_checkin', '1', $template->checkmarkValue('expected_checkin')) }}
<input type="checkbox" name="expected_checkin" value="1" @checked($template->checkmarkValue('expected_checkin')) />
{{ trans('admin/hardware/form.expected_checkin') }}
</label>
<label class="form-control">
{{ Form::checkbox('created_at', '1', $template->checkmarkValue('created_at')) }}
<input type="checkbox" name="created_at" value="1" @checked($template->checkmarkValue('created_at')) />
{{ trans('general.created_at') }}
</label>
<label class="form-control">
{{ Form::checkbox('updated_at', '1', $template->checkmarkValue('updated_at')) }}
<input type="checkbox" name="updated_at" value="1" @checked($template->checkmarkValue('updated_at')) />
{{ trans('general.updated_at') }}
</label>
<label class="form-control">
{{ Form::checkbox('deleted_at', '1', $template->checkmarkValue('deleted_at')) }}
<input type="checkbox" name="deleted_at" value="1" @checked($template->checkmarkValue('deleted_at')) />
{{ trans('general.deleted') }}
</label>
<label class="form-control">
{{ Form::checkbox('last_audit_date', '1', $template->checkmarkValue('last_audit_date')) }}
<input type="checkbox" name="last_audit_date" value="1" @checked($template->checkmarkValue('last_audit_date')) />
{{ trans('general.last_audit') }}
</label>
<label class="form-control">
{{ Form::checkbox('next_audit_date', '1', $template->checkmarkValue('next_audit_date')) }}
<input type="checkbox" name="next_audit_date" value="1" @checked($template->checkmarkValue('next_audit_date')) />
{{ trans('general.next_audit_date') }}
</label>
<label class="form-control">
{{ Form::checkbox('notes', '1', $template->checkmarkValue('notes')) }}
<input type="checkbox" name="notes" value="1" @checked($template->checkmarkValue('notes')) />
{{ trans('general.notes') }}
</label>
<label class="form-control" style="margin-left: 25px;">
{{ Form::checkbox('url', '1', $template->checkmarkValue('url')) }}
<input type="checkbox" name="url" value="1" @checked($template->checkmarkValue('url')) />
{{ trans('general.url') }}
</label>
@@ -248,64 +248,64 @@
<h2>{{ trans('general.checked_out_to_fields') }}: </h2>
<label class="form-control">
{{ Form::checkbox('assigned_to', '1', $template->checkmarkValue('assigned_to')) }}
<input type="checkbox" name="assigned_to" value="1" @checked($template->checkmarkValue('assigned_to')) />
{{ trans('admin/licenses/table.assigned_to') }}
</label>
<label class="form-control">
{{ Form::checkbox('username', '1', $template->checkmarkValue('username')) }}
<input type="checkbox" name="username" value="1" @checked($template->checkmarkValue('username')) />
{{ trans('admin/users/table.username') }}
</label>
<label class="form-control">
{{ Form::checkbox('employee_num', '1', $template->checkmarkValue('employee_num')) }}
<input type="checkbox" name="employee_num" value="1" @checked($template->checkmarkValue('employee_num')) />
{{ trans('general.employee_number') }}
</label>
<label class="form-control">
{{ Form::checkbox('manager', '1', $template->checkmarkValue('manager')) }}
<input type="checkbox" name="manager" value="1" @checked($template->checkmarkValue('manager')) />
{{ trans('admin/users/table.manager') }}
</label>
<label class="form-control">
{{ Form::checkbox('department', '1', $template->checkmarkValue('department')) }}
<input type="checkbox" name="department" value="1" @checked($template->checkmarkValue('department')) />
{{ trans('general.department') }}
</label>
<label class="form-control">
{{ Form::checkbox('title', '1', $template->checkmarkValue('title')) }}
<input type="checkbox" name="title" value="1" @checked($template->checkmarkValue('title')) />
{{ trans('admin/users/table.title') }}
</label>
<!-- new -->
<label class="form-control">
{{ Form::checkbox('phone', '1', $template->checkmarkValue('phone')) }}
<input type="checkbox" name="phone" value="1" @checked($template->checkmarkValue('phone')) />
{{ trans('admin/users/table.phone') }}
</label>
<label class="form-control">
{{ Form::checkbox('user_address', '1', $template->checkmarkValue('user_address')) }}
<input type="checkbox" name="user_address" value="1" @checked($template->checkmarkValue('user_address')) />
{{ trans('general.address') }}
</label>
<label class="form-control">
{{Form::checkbox('user_city', '1', $template->checkmarkValue('user_city'))}}
<input type="checkbox" name="user_city" value="1" @checked($template->checkmarkValue('user_city')) />
{{ trans('general.city') }}
</label>
<label class="form-control">
{{Form::checkbox('user_state', '1', $template->checkmarkValue('user_state'))}}
<input type="checkbox" name="user_state" value="1" @checked($template->checkmarkValue('user_state')) />
{{ trans('general.state') }}
</label>
<label class="form-control">
{{Form::checkbox('user_country', '1', $template->checkmarkValue('user_country'))}}
<input type="checkbox" name="user_country" value="1" @checked($template->checkmarkValue('user_country')) />
{{ trans('general.country') }}
</label>
<label class="form-control">
{{Form::checkbox('user_zip', '1', $template->checkmarkValue('user_zip'))}}
<input type="checkbox" name="user_zip" value="1" @checked($template->checkmarkValue('user_zip')) />
{{ trans('general.zip') }}
</label>
@@ -318,7 +318,7 @@
@foreach ($customfields as $customfield)
<label class="form-control">
{{ Form::checkbox($customfield->db_column_name(), '1', $template->checkmarkValue($customfield->db_column_name())) }}
<input type="checkbox" name="{{ $customfield->db_column_name() }}" value="1" @checked($template->checkmarkValue($customfield->db_column_name())) />
{{ $customfield->name }}
</label>
@@ -549,13 +549,13 @@
<div class="col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('exclude_archived', '1', $template->checkmarkValue('exclude_archived', '0')) }}
<input type="checkbox" name="exclude_archived" value="1" @checked($template->checkmarkValue('exclude_archived', '0')) />
{{ trans('general.exclude_archived') }}
</label>
</div>
<div class="col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('use_bom', '1', $template->checkmarkValue('use_bom', '0')) }}
<input type="checkbox" name="use_bom" value="1" @checked($template->checkmarkValue('use_bom', '0')) />
{{ trans('general.bom_remark') }}
</label>
</div>
+2 -2
View File
@@ -45,7 +45,7 @@
<div class="form-group {{ $errors->has('alerts_enabled') ? 'error' : '' }}">
<div class="col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('alerts_enabled', '1', old('alerts_enabled', $setting->alerts_enabled)) }}
<input type="checkbox" name="alerts_enabled" value="1" @checked(old('alerts_enabled', $setting->alerts_enabled))>
{{ trans('admin/settings/general.alerts_enabled') }}
</label>
</div>
@@ -55,7 +55,7 @@
<div class="form-group {{ $errors->has('show_alerts_in_menu') ? 'error' : '' }}">
<div class="col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('show_alerts_in_menu', '1', old('show_alerts_in_menu', $setting->show_alerts_in_menu)) }}
<input type="checkbox" name="show_alerts_in_menu" value="1" @checked(old('show_alerts_in_menu', $setting->show_alerts_in_menu))>
{{ trans('admin/settings/general.show_alerts_in_menu') }}
</label>
</div>
@@ -47,7 +47,7 @@
</div>
<div class="col-md-7">
<label class="form-control">
{{ Form::checkbox('auto_increment_assets', '1', old('auto_increment_assets', $setting->auto_increment_assets),array('aria-label'=>'auto_increment_assets')) }}
<input type="checkbox" name="auto_increment_assets" value="1" @checked(old('auto_increment_assets', $setting->auto_increment_assets)) aria-label="auto_increment_assets">
{{ trans('admin/settings/general.enabled') }}
</label>
</div>
+1 -1
View File
@@ -54,7 +54,7 @@
<div class="col-md-8 col-md-offset-3">
<label class="form-control{{ (config('app.lock_passwords')===true) ? ' form-control--disabled': '' }}">
<span class="sr-only">{{ trans('admin/settings/general.pwd_secure_uncommon') }}</span>
{{ Form::checkbox('google_login', '1', old('google_login', $setting->google_login),array('aria-label'=>'google_login', (config('app.lock_passwords')===true) ? 'disabled': '')) }}
<input type="checkbox" name="google_login" value="1" @checked(old('google_login', $setting->google_login)) @disabled(config('app.lock_passwords')) aria-label="google_login">
{{ trans('admin/settings/general.enable_google_login') }}
</label>
<p class="help-block">{{ trans('admin/settings/general.enable_google_login_help') }}</p>
+5 -5
View File
@@ -75,7 +75,7 @@
<div class="col-md-8">
<label class="form-control">
{{ Form::checkbox('ldap_enabled', '1', old('ldap_enabled', $setting->ldap_enabled)) }}
<input type="checkbox" name="ldap_enabled" value="1" id="ldap_enabled" @checked(old('ldap_enabled', $setting->ldap_enabled)) />
{{ trans('admin/settings/general.ldap_enabled') }}
</label>
@@ -96,7 +96,7 @@
</div>
<div class="col-md-8">
<label class="form-control">
{{ Form::checkbox('is_ad', '1', old('is_ad', $setting->is_ad)) }}
<input type="checkbox" name="is_ad" value="1" id="is_ad" @checked(old('is_ad', $setting->is_ad))/>
{{ trans('admin/settings/general.is_ad') }}
</label>
@error('is_ad')
@@ -122,7 +122,7 @@
</div>
<div class="col-md-8">
<label class="form-control">
{{ Form::checkbox('ldap_pw_sync', '1', old('ldap_pw_sync', $setting->ldap_pw_sync)) }}
<input type="checkbox" name="ldap_pw_sync" value="1" id="ldap_pw_sync" @checked(old('ldap_pw_sync', $setting->ldap_pw_sync)) />
{{ trans('general.yes') }}
</label>
@@ -255,7 +255,7 @@
</div>
<div class="col-md-8">
<label class="form-control">
{{ Form::checkbox('ldap_tls', '1', old('ldap_tls', $setting->ldap_tls)) }}
<input type="checkbox" name="ldap_tls" value="1" id="ldap_tls" @checked(old('ldap_tls', $setting->ldap_tls)) />
{{ trans('admin/settings/general.ldap_tls_help') }}
</label>
@error('ldap_tls')
@@ -281,7 +281,7 @@
</div>
<div class="col-md-8">
<label class="form-control">
{{ Form::checkbox('ldap_server_cert_ignore', '1', old('ldap_server_cert_ignore', $setting->ldap_server_cert_ignore)) }}
<input type="checkbox" name="ldap_server_cert_ignore" value="1" id="ldap_server_cert_ignore" @checked(old('ldap_server_cert_ignore', $setting->ldap_server_cert_ignore)) />
{{ trans('admin/settings/general.ldap_server_cert_ignore') }}
</label>
@error('ldap_server_cert_ignore')
+3 -3
View File
@@ -52,7 +52,7 @@
<div class="col-md-9">
<label class="form-control{{ config('app.lock_passwords') === true ? ' form-control--disabled': '' }}">
{{ Form::checkbox('saml_enabled', '1', old('saml_enabled', $setting->saml_enabled), ['class' => config('app.lock_passwords') === true ? 'disabled ': '', config('app.lock_passwords') === true ? 'disabled ': '', ]) }}
<input type="checkbox" name="saml_enabled" value="1" @checked(old('saml_enabled', $setting->saml_enabled)) @disabled(config('app.lock_passwords')) @class(['disabled' => config('app.lock_passwords')])/>
{{ trans('admin/settings/general.saml_enabled') }}
</label>
@@ -146,7 +146,7 @@
</div>
<div class="col-md-9">
<label class="form-control{{ config('app.lock_passwords') === true ? ' form-control--disabled': '' }}">
{{ Form::checkbox('saml_forcelogin', '1', old('saml_forcelogin', $setting->saml_forcelogin),['class' => $setting->demoMode, $setting->demoMode]) }}
<input type="checkbox" name="saml_forcelogin" value="1" @checked(old('saml_forcelogin', $setting->saml_forcelogin)) @disabled(config('app.lock_passwords')) @class(['disabled' => config('app.lock_passwords')]) />
{{ trans('admin/settings/general.saml_forcelogin') }}
</label>
<p class="help-block">{{ trans('admin/settings/general.saml_forcelogin_help') }}</p>
@@ -162,7 +162,7 @@
</div>
<div class="col-md-9">
<label class="form-control{{ config('app.lock_passwords') === true ? ' form-control--disabled': '' }}">
{{ Form::checkbox('saml_slo', '1', old('saml_slo', $setting->saml_slo),['class' => 'minimal '. $setting->demoMode, $setting->demoMode]) }}
<input type="checkbox" name="saml_slo" value="1" @checked(old('saml_slo', $setting->saml_slo)) @disabled(config('app.lock_passwords')) @class(['minimal', 'disabled' => config('app.lock_passwords')])/>
{{ trans('admin/settings/general.saml_slo') }}
</label>
<p class="help-block">{{ trans('admin/settings/general.saml_slo_help') }}</p>
+8 -8
View File
@@ -83,27 +83,27 @@
<div class="col-md-9">
<label class="form-control">
<span class="sr-only">{{ trans('admin/settings/general.pwd_secure_uncommon') }}</span>
{{ Form::checkbox('pwd_secure_uncommon', '1', old('pwd_secure_uncommon', $setting->pwd_secure_uncommon),array( 'aria-label'=>'pwd_secure_uncommon')) }}
<input type="checkbox" name="pwd_secure_uncommon" value="1" @checked(old('pwd_secure_uncommon', $setting->pwd_secure_uncommon)) aria-label="pwd_secure_uncommon"/>
{{ trans('admin/settings/general.pwd_secure_uncommon') }}
</label>
<label class="form-control">
{{ Form::checkbox("pwd_secure_complexity['disallow_same_pwd_as_user_fields']", 'disallow_same_pwd_as_user_fields', old('disallow_same_pwd_as_user_fields', strpos($setting->pwd_secure_complexity, 'disallow_same_pwd_as_user_fields')!==false), array('aria-label'=>'pwd_secure_complexity')) }}
<input type="checkbox" name="pwd_secure_complexity['disallow_same_pwd_as_user_fields']" value="disallow_same_pwd_as_user_fields" @checked(old('disallow_same_pwd_as_user_fields', strpos($setting->pwd_secure_complexity, 'disallow_same_pwd_as_user_fields')!==false)) aria-label="pwd_secure_complexity"/>
{{ trans('admin/settings/general.pwd_secure_complexity_disallow_same_pwd_as_user_fields') }}
</label>
<label class="form-control">
{{ Form::checkbox("pwd_secure_complexity['letters']", 'letters', old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'letters')!==false), array('aria-label'=>'pwd_secure_complexity')) }}
<input type="checkbox" name="pwd_secure_complexity['letters']" value="letters" @checked(old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'letters')!==false)) aria-label="pwd_secure_complexity"/>
{{ trans('admin/settings/general.pwd_secure_complexity_letters') }}
</label>
<label class="form-control">
{{ Form::checkbox("pwd_secure_complexity['numbers']", 'numbers', old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'numbers')!==false), array('aria-label'=>'pwd_secure_complexity')) }}
<input type="checkbox" name="pwd_secure_complexity['numbers']" value="numbers" @checked(old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'numbers')!==false)) aria-label="pwd_secure_complexity"/>
{{ trans('admin/settings/general.pwd_secure_complexity_numbers') }}
</label>
<label class="form-control">
{{ Form::checkbox("pwd_secure_complexity['symbols']", 'symbols', old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'symbols')!==false), array('aria-label'=>'pwd_secure_complexity')) }}
<input type="checkbox" name="pwd_secure_complexity['symbols']" value="symbols" @checked(old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'symbols')!==false)) aria-label="pwd_secure_complexity"/>
{{ trans('admin/settings/general.pwd_secure_complexity_symbols') }}
</label>
<label class="form-control">
{{ Form::checkbox("pwd_secure_complexity['case_diff']", 'case_diff', old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'case_diff')!==false), array('aria-label'=>'pwd_secure_complexity')) }}
<input type="checkbox" name="pwd_secure_complexity['case_diff']" value="case_diff" @checked(old('pwd_secure_uncommon', strpos($setting->pwd_secure_complexity, 'case_diff')!==false)) aria-label="pwd_secure_complexity"/>
{{ trans('admin/settings/general.pwd_secure_complexity_case_diff') }}
</label>
@@ -129,7 +129,7 @@
<p class="text-warning"><i class="fas fa-lock"></i> {{ trans('general.feature_disabled') }}</p>
@else
<label class="form-control">
{{ Form::checkbox('login_remote_user_enabled', '1', old('login_remote_user_enabled', $setting->login_remote_user_enabled),array('aria-label'=>'login_remote_user')) }}
<input type="checkbox" name="login_remote_user_enabled" value="1" @checked(old('login_remote_user_enabled', $setting->login_remote_user_enabled)) aria-label="login_remote_user"/>
<label for="login_remote_user_enabled">{{ trans('admin/settings/general.login_remote_user_enabled_text') }}</label>
</label>
@@ -158,7 +158,7 @@
<!-- Disable other logins mechanism -->
<label class="form-control">
{{ Form::checkbox('login_common_disabled', '1', old('login_common_disabled', $setting->login_common_disabled),array('aria-label'=>'login_common_disabled')) }}
<input type="checkbox" name="login_common_disabled" value="1" @checked(old('login_common_disabled', $setting->login_common_disabled)) aria-label="login_common_disabled"/>
{{ trans('admin/settings/general.login_common_disabled_text') }}
</label>
{!! $errors->first('login_common_disabled', '<span class="alert-msg" aria-hidden="true">:message</span>') !!}
+7 -7
View File
@@ -42,7 +42,7 @@
<div class="form-group">
<div class=" col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('null_department_id', '1', false) }}
<input type="checkbox" name="null_department_id" value="1" />
{{ trans_choice('general.set_users_field_to_null', count($users), ['field' => trans('general.department'), 'user_count' => count($users)]) }}
</label>
</div>
@@ -55,7 +55,7 @@
<div class="form-group">
<div class=" col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('null_location_id', '1', false) }}
<input type="checkbox" name="null_location_id" value="1" />
{{ trans_choice('general.set_users_field_to_null', count($users), ['field' => trans('general.location'), 'user_count' => count($users)]) }}
</label>
</div>
@@ -69,7 +69,7 @@
<div class="form-group">
<div class=" col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('null_company_id', '1', false) }}
<input type="checkbox" name="null_company_id" value="1" />
{{ trans_choice('general.set_users_field_to_null', count($users), ['field' => trans('general.company'), 'user_count' => count($users)]) }}
</label>
</div>
@@ -83,7 +83,7 @@
<div class="form-group">
<div class=" col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('null_manager_id', '1', false) }}
<input type="checkbox" name="null_manager_id" value="1" />
{{ trans_choice('general.set_users_field_to_null', count($users), ['field' => trans('admin/users/table.manager'), 'user_count' => count($users)]) }}
</label>
</div>
@@ -102,7 +102,7 @@
<div class="form-group">
<div class=" col-md-9 col-md-offset-3">
<label class="form-control">
{{ Form::checkbox('null_locale', '1', false) }}
<input type="checkbox" name="null_locale" value="1" />
{{ trans_choice('general.set_users_field_to_null', count($users), ['field' => trans('general.language'), 'user_count' => count($users)]) }}
</label>
</div>
@@ -246,7 +246,7 @@
</div>
<div class="col-md-5">
<label class="form-control">
{{ Form::checkbox('null_start_date', '1', false) }}
<input type="checkbox" name="null_start_date" value="1" />
{{ trans_choice('general.set_to_null', count($users),['selection_count' => count($users)]) }}
</label>
</div>
@@ -264,7 +264,7 @@
</div>
<div class="col-md-5">
<label class="form-control">
{{ Form::checkbox('null_end_date', '1', false) }}
<input type="checkbox" name="null_end_date" value="1" />
{{ trans_choice('general.set_to_null', count($users),['selection_count' => count($users)]) }}
</label>
</div>
+2 -2
View File
@@ -213,7 +213,7 @@
@elseif ($user->id === Auth::user()->id)
<!-- disallow the user from editing their own login status -->
<label class="form-control form-control--disabled">
{{ Form::checkbox('activated', '1', old('activated', $user->activated), ['disabled' => true, 'checked'=> 'checked', 'aria-label'=>'update_real_loc']) }}
<input type="checkbox" name="activated" value="1" checked disabled aria-label="activated">
{{ trans('admin/users/general.activated_help_text') }}
</label>
<p class="text-warning">{{ trans('admin/users/general.activated_disabled_help_text') }}</p>
@@ -259,7 +259,7 @@
<div class="col-md-8 col-md-offset-3">
<label class="form-control form-control--disabled">
{{ Form::checkbox('email_user', '1', old('email_user'), ['id' => "email_user_checkbox", 'aria-label'=>'email_user']) }}
<input type="checkbox" name="email_user" value="1" id="email_user_checkbox" @checked(old('email_user')) aria-label="email_user">
{{ trans('admin/users/general.email_user_creds_on_create') }}
</label>
@@ -43,9 +43,13 @@ class SendAcceptanceReminderTest extends TestCase
CheckoutAcceptance::factory()->pending()->create([
'assigned_to_id' => $userA->id,
]);
$headers = ['ID', 'Name'];
$rows = [
[$userA->id, $userA->present()->fullName()],
];
$this->artisan('snipeit:acceptance-reminder')
->expectsOutput($userA->present()->fullName().' has no email address.')
->expectsOutput("The following users do not have an email address:")
->expectsTable($headers, $rows)
->assertExitCode(0);
Mail::assertNotSent(UnacceptedAssetReminderMail::class);
+12 -17
View File
@@ -479,15 +479,6 @@ foreach ($unused_files as $unused_file) {
}
echo "\n";
$config_clear = shell_exec('php artisan config:clear');
$cache_clear = shell_exec('php artisan cache:clear');
$route_clear = shell_exec('php artisan route:clear');
$view_clear = shell_exec('php artisan view:clear');
echo $success_icon.' '.trim($config_clear)."\n";
echo $success_icon.' '.trim($cache_clear)."\n";
echo $success_icon.' '.trim($route_clear)."\n";
echo $success_icon.' '.trim($view_clear)."\n";
echo "\n";
echo "\e[95m--------------------------------------------------------\n";
echo "STEP 6: Updating composer dependencies:\n";
@@ -497,13 +488,11 @@ echo "-- Running the app in ".$app_environment." mode.\n";
// Composer install
if (file_exists('composer.phar')) {
echo " Local composer.phar detected, so we'll use that.\n\n";
echo $success_icon." Local composer.phar detected, so we'll use that.\n\n";
echo "-- Updating local composer.phar\n\n";
$composer_update = shell_exec('php composer.phar self-update');
echo $composer_update."\n\n";
// Use --no-dev only if we are in production mode.
// This will cause errors otherwise, if the user is in develop or local for their APP_ENV
if ($app_environment == 'production') {
@@ -511,10 +500,9 @@ if (file_exists('composer.phar')) {
} else {
$composer = shell_exec('php composer.phar install --prefer-source');
}
$composer_dump = shell_exec('php composer.phar dump');
} else {
echo "-- We couldn't find a local composer.phar. No worries, trying globally.\n";
@@ -531,13 +519,20 @@ if (file_exists('composer.phar')) {
$composer_dump = shell_exec('composer dump');
}
echo $composer_dump."\n";
echo $composer;
$config_clear = shell_exec('php artisan config:clear');
$cache_clear = shell_exec('php artisan cache:clear');
$route_clear = shell_exec('php artisan route:clear');
$view_clear = shell_exec('php artisan view:clear');
echo $success_icon.' '.trim($config_clear)."\n";
echo $success_icon.' '.trim($cache_clear)."\n";
echo $success_icon.' '.trim($route_clear)."\n";
echo $success_icon.' '.trim($view_clear)."\n";
echo "\n";
echo "\e[95m--------------------------------------------------------\n";
echo "STEP 7: Putting application into maintenance mode: \n";
@@ -585,7 +580,7 @@ echo "--------------------------------------------------------\e[39m\n\n";
if ((!file_exists('storage/oauth-public.key')) || (!file_exists('storage/oauth-private.key'))) {
echo $info_icon." No OAuth keys detected. Running passport install now.\n\n";
$passport = shell_exec('php artisan passport:install');
$passport = shell_exec('php artisan passport:install --no-interaction');
echo $passport;
} else {
echo $success_icon." OAuth keys detected. Skipping passport install.\n\n";