Skip to content

Commit

Permalink
[ADVAPP-972]: The text displayed on the student profile page related …
Browse files Browse the repository at this point in the history
…to data sync is displaying in an unexpected screen location. (#1099)

* The text displayed on the student profile page related to data sync is displaying in an unexpected screen location.

* chore: fix enforcement of copyright on all files

* Increase space between button and text

Signed-off-by: Kevin Ullyott <kevin.ullyott@canyongbs.com>

* chore: fix code style

---------

Signed-off-by: Kevin Ullyott <kevin.ullyott@canyongbs.com>
Co-authored-by: amit-canyon <amit-canyon@users.noreply.github.com>
Co-authored-by: Kevin Ullyott <kevin.ullyott@canyongbs.com>
Co-authored-by: Orrison <Orrison@users.noreply.github.com>
  • Loading branch information
4 people authored Nov 6, 2024
1 parent 3f79868 commit 52cd3c8
Show file tree
Hide file tree
Showing 4 changed files with 76 additions and 38 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,19 @@ class="mb-2 hidden sm:block"
</div>

<div @class([
'flex shrink-0 items-center gap-3',
'flex shrink-0 items-center gap-3 justify-end',
'sm:mt-7' => $breadcrumbs,
])>
{{ \Filament\Support\Facades\FilamentView::renderHook(\Filament\View\PanelsRenderHook::PAGE_HEADER_ACTIONS_BEFORE, scopes: $this->getRenderHookScopes()) }}
<div class="flex flex-col justify-end gap-1">
<div class="flex flex-row items-center justify-end gap-3">
{{ \Filament\Support\Facades\FilamentView::renderHook(\Filament\View\PanelsRenderHook::PAGE_HEADER_ACTIONS_BEFORE, scopes: $this->getRenderHookScopes()) }}

@if ($actions)
<x-filament::actions :actions="$actions" />
@endif
@if ($actions)
<x-filament::actions :actions="$actions" />
@endif
</div>
{{ \Filament\Support\Facades\FilamentView::renderHook(\Filament\View\PanelsRenderHook::PAGE_HEADER_ACTIONS_AFTER, scopes: $this->getRenderHookScopes()) }}
</div>

{{ \Filament\Support\Facades\FilamentView::renderHook(\Filament\View\PanelsRenderHook::PAGE_HEADER_ACTIONS_AFTER, scopes: $this->getRenderHookScopes()) }}
</div>
</header>
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{{--
<COPYRIGHT>
Copyright © 2016-2024, Canyon GBS LLC. All rights reserved.
Advising App™ is licensed under the Elastic License 2.0. For more details,
see https://github.com/canyongbs/advisingapp/blob/main/LICENSE.
Notice:
- You may not provide the software to third parties as a hosted or managed
service, where the service provides users with access to any substantial set of
the features or functionality of the software.
- You may not move, change, disable, or circumvent the license key functionality
in the software, and you may not remove or obscure any functionality in the
software that is protected by the license key.
- You may not alter, remove, or obscure any licensing, copyright, or other notices
of the licensor in the software. Any use of the licensor’s trademarks is subject
to applicable law.
- Canyon GBS LLC respects the intellectual property rights of others and expects the
same in return. Canyon GBS™ and Advising App™ are registered trademarks of
Canyon GBS LLC, and we are committed to enforcing and protecting our trademarks
vigorously.
- The software solution, including services, infrastructure, and code, is offered as a
Software as a Service (SaaS) by Canyon GBS LLC.
- Use of this software implies agreement to the license terms and conditions as stated
in the Elastic License 2.0.
For more information or inquiries please visit our website at
https://www.canyongbs.com or contact us via email at legal@canyongbs.com.
</COPYRIGHT>
--}}
@php
use AdvisingApp\StudentDataModel\Models\Student;
use Illuminate\Support\Carbon;
use App\Settings\DisplaySettings;
/** @var Student $student */
$timezone = app(DisplaySettings::class)->getTimezone();
@endphp
<div class="mt-2 flex-1">
<p class="text-xs">
Last Updated
{{ $student->updated_at->setTimezone($timezone)->format('m/d/Y \a\t g:i A') }}
</p>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -31,37 +31,16 @@
</COPYRIGHT>
--}}
<?php
use AdvisingApp\StudentDataModel\Models\Student;
use Illuminate\Support\Carbon;
use App\Settings\DisplaySettings;

/** @var Student $student */
$timezone = app(DisplaySettings::class)->getTimezone();
?>
<div class="flex flex-col items-center gap-3 md:flex-row">
@if ($student->updated_at)
<div class="flex-1">
<p class="text-xs">
This record was last updated in the SIS on
{{ $student->updated_at->setTimezone($timezone)->format('F j, Y g:i A') }}.
</p>
</div>
@endif

<div class="flex-shrink-0">

<x-filament::button
type="button"
color="gray"
icon="heroicon-m-arrow-path"
labeled-from="sm"
tag="button"
wire:click="sisRefresh()"
>
{{ 'Sync' }}
</x-filament::button>

</div>
<div class="flex-shrink-0">
<x-filament::button
type="button"
color="gray"
icon="heroicon-m-arrow-path"
labeled-from="sm"
tag="button"
wire:click="sisRefresh()"
>
{{ 'Sync' }}
</x-filament::button>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,13 @@ public function boot()
]),
scopes: ViewStudent::class,
);
FilamentView::registerRenderHook(
PanelsRenderHook::PAGE_HEADER_ACTIONS_AFTER,
fn (): View => view('student-data-model::filament.resources.student-resource.sis-last-updated', [
'student' => $this->getRecord(),
]),
scopes: ViewStudent::class,
);
}
}

Expand Down

0 comments on commit 52cd3c8

Please sign in to comment.