Skip to content

Commit

Permalink
Improvements for expiry package
Browse files Browse the repository at this point in the history
  • Loading branch information
AzGasim committed Dec 18, 2024
1 parent 7dd7f6e commit 0e07dc2
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 27 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/monorepo-split-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

env:
GITHUB_TOKEN: ${{ secrets.BOT }}
CORE_VERSION: "^3.0.2"
CORE_VERSION: "^3.0.3"

jobs:
packages_split:
Expand Down Expand Up @@ -42,13 +42,13 @@ jobs:
steps:
- uses: actions/checkout@v4

# Search and replace "moox/core": "*" with "moox/core": "^3.0.2" in composer.json
# Search and replace "moox/core": "*" with "moox/core": "^3.0.3" in composer.json
- name: Replace core version in composer.json
working-directory: packages/${{ matrix.package }}
run: |
if [ -f composer.json ]; then
echo "Updating moox/core version in ${{ matrix.package }}"
sed -i 's/"moox\/core": "\*"/"moox\/core": "^3.0.2"/g' composer.json
sed -i 's/"moox\/core": "\*"/"moox\/core": "^3.0.3"/g' composer.json
fi
# Commit the updated composer.json (if there was a change)
Expand All @@ -59,7 +59,7 @@ jobs:
git config --global user.name "mooxbot"
git config --global user.email "[email protected]"
git add composer.json
git commit -m "Update moox/core dependency to ^^3.0.2" || echo "No changes to commit"
git commit -m "Update moox/core dependency to ^^3.0.3" || echo "No changes to commit"
fi
- if: "!startsWith(github.ref, 'refs/tags/')"
Expand Down
13 changes: 6 additions & 7 deletions packages/core/resources/lang/de/expiry.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,17 @@
'update_expiries' => 'Ablaufdaten aktualisieren',
'updating_started' => 'Aktualisieren gestartet',

'expired_at' => 'Abgelaufen',
'expired_at' => 'Fällig',
'processing_deadline' => 'Bearbeitungsfrist',
'escalated_at' => 'Eskaliert am',
'escalated_to' => 'Eskaliert an',
'escalated_at' => 'Erinnerung',
'escalated_to' => 'Erinnerung an',
'cycle' => 'Turnus',
'notifyUser' => 'Verantwortlicher',
'expiry_job' => 'Typ',

'escalated_entries_in_expiry_dashboard' => 'Eskalierte Einträge im Expiry Dashboard',
'following_escalated_entries' => 'Folgende Einträge sind eskaliert:',
'will_expire_at' => 'Läuft ab am',
'review_entreis' => 'Bitte überprüfen Sie diese Einträge so bald wie möglich im ',
'escalated_entries_in_expiry_dashboard' => 'Erinnerung an zu bearbeitende Einträge',
'following_escalated_entries' => 'Folgende Einträge stehen zur Bearbeitung an',
'review_entries' => 'Bitte überprüfen Sie diese Einträge so bald wie möglich im ',
'expiry_dashboard' => 'Ablaufdaten Dashboard',

'set_date_based_on_cycle' => 'Neues Ablaufdatum setzen basierend auf dem Turnus',
Expand Down
13 changes: 6 additions & 7 deletions packages/core/resources/lang/en/expiry.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,17 @@
'update_expiries' => 'Update Expiries',
'updating_started' => 'Updating started',

'expired_at' => 'Expired',
'expired_at' => 'Due',
'processing_deadline' => 'Processing deadline',
'escalated_at' => 'Escalated at',
'escalated_to' => 'Escalated to',
'escalated_at' => 'Reminder',
'escalated_to' => 'Reminder to',
'cycle' => 'Cycle',
'notifyUser' => 'Assignee',
'expiry_job' => 'Type',

'escalated_entries_in_expiry_dashboard' => 'Escalated entries in the expiry dashboard',
'following_escalated_entries' => 'The following entries have been escalated:',
'will_expire_at' => 'Will expire at',
'review_entreis' => 'Please review these entries as soon as possible in the ',
'escalated_entries_in_expiry_dashboard' => 'Escalated entries in expiry dashboard',
'following_escalated_entries' => 'Following entries are escalated',
'review_entries' => 'Please review these entries as soon as possible in the ',
'expiry_dashboard' => 'Expiry Dashboard',

'set_date_based_on_cycle' => 'Set date based on cycle',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
}
.table .escalation {
color: #e53e3e;
color: #e5be01;
font-weight: bold;
}
Expand Down Expand Up @@ -101,8 +101,7 @@
<div class="logo">
<img src="{{ $logoUrl }}" alt="Company Logo" class="w-24 h-auto">
</div>
<h1>{{ __('core::expiry.escalated_entries_in_expiry_dashboard') }}</h1>
<h4>{{ __('core::expiry.following_escalated_entries') }}</h4>
<h1>{{ __('core::expiry.following_escalated_entries') }}</h1>

<!-- Escalated Entries -->
<table class="table">
Expand All @@ -111,7 +110,7 @@
<th>{{ __('core::core.title') }}</th>
<th>{{ __('core::expiry.notifyUser') }}</th>
<th>{{ __('core::core.category') }}</th>
<th>{{ __('core::expiry.will_expire_at') }}</th>
<th>{{ __('core::expiry.expired_at') }}</th>
<th>{{ __('core::expiry.processing_deadline') }}</th>
<th>{{ __('core::expiry.escalated_at') }}</th>
</tr>
Expand All @@ -133,7 +132,7 @@
<br>

<!-- Footer -->
<p class="footer">{{ __('core::expiry.review_entreis') }}<a
<p class="footer">{{ __('core::expiry.review_entries') }}<a
href="{{ url($panelPath . '/expiries') }}">{{ __('core::expiry.expiry_dashboard') }}</a>.</p>
</div>
</body>
Expand Down
4 changes: 2 additions & 2 deletions packages/expiry/src/Jobs/SendEscalatedExpiriesJob.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ public function handle()
'escalatedEntries' => $escalatedEntries->map(function ($entry) {
return [
'title' => $entry->title,
'expired_at' => Carbon::parse($entry->expired_at)->format('d.m.Y'),
'processing_deadline' => Carbon::parse($entry->processing_deadline)->format('d.m.Y'),
'expired_at' => Carbon::parse($entry->expired_at)->diffForHumans(),
'processing_deadline' => Carbon::parse($entry->processing_deadline)->diffForHumans(),
'escalated_at' => Carbon::parse($entry->escalated_at)->format('d.m.Y'),
'notified_to' => config('expiry.user_model')::where('ID', $entry->notified_to)->first()?->display_name,
'user_email' => config('expiry.user_model')::where('ID', $entry->notified_to)->first()?->email,
Expand Down
2 changes: 1 addition & 1 deletion packages/expiry/src/Mail/EscalatedExpiriesMail.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public function build()
$logoPath = config('expiry.logo_url');
$logoUrl = asset($logoPath);

return $this->subject('Eskalierte Einträge in den Ablaufdaten')
return $this->subject(__('core::expiry.escalated_entries_in_expiry_dashboard'))
->view('expiry::emails.escalated_expiries')
->with([
'escalatedEntries' => $this->entries['escalatedEntries'],
Expand Down
2 changes: 1 addition & 1 deletion packages/expiry/src/Resources/ExpiryResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class ExpiryResource extends Resource

protected static ?string $model = Expiry::class;

protected static ?string $navigationIcon = 'gmdi-access-time-o';
protected static ?string $navigationIcon = 'gmdi-view-timeline-o';

protected static ?string $recordTitleAttribute = 'title';

Expand Down

0 comments on commit 0e07dc2

Please sign in to comment.