Skip to content

Commit

Permalink
cat trans
Browse files Browse the repository at this point in the history
  • Loading branch information
bastihilger committed Mar 15, 2022
1 parent 7b1d9ff commit 741a206
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 12 deletions.
2 changes: 1 addition & 1 deletion resources/lang/nova-cms-portfolio/de/works.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
'title_position' => 'Position des Titels',
'title' => 'Titel',
'toggle_artist_portfolio_image' => 'AN/AUS "ist Künstler-Portfolio-Bild"',
'toggle_represents_artist_in_discipline_category' => 'AN/AUS "repräsentiert Künstler in Kategorie"',
'toggle_represents_artist_in_discipline_category' => 'AN/AUS "In allgemeiner Kategorie-Übersicht zeigen"',
'toggle_represents_in_discipline' => 'AN/AUS "In allgemeiner Kategorie-Übersicht zeigen"',
'toggle_show_in_overview_category' => 'AN/AUS "In Künstler-Übersicht zeigen, wenn eine einzelne Kategorie ausgewählt ist"',
'toggle_show_in_overview' => 'AN/AUS "In Künstler-Übersicht zeigen, wenn ALLE KATEGORIEN ausgewählt ist"',
Expand Down
3 changes: 3 additions & 0 deletions resources/lang/nova-cms-portfolio/en.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
{
"AN/AUS: In allgemeiner Kategorie-Übersicht zeigen": "represents artist on frontpage category",
"AN/AUS: In Künstler-Übersicht zeigen, wenn ALLE KATEGORIEN ausgewählt ist": "show in overview",
"AN/AUS: In Künstler-Übersicht zeigen, wenn eine einzelne Kategorie ausgewählt ist": "show in artists category portfolio",
"In allgemeiner Kategorie-Übersicht zeigen": "represents artist on frontpage category",
"In Künstler-Übersicht zeigen, wenn ALLE KATEGORIEN ausgewählt ist": "show in overview",
"In Künstler-Übersicht zeigen, wenn eine einzelne Kategorie ausgewählt ist": "show in artists category portfolio"
Expand Down
4 changes: 2 additions & 2 deletions src/Nova/Actions/ToggleArtistDisciplineImage.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

namespace Kraenkvisuell\NovaCmsPortfolio\Nova\Actions;

use Laravel\Nova\Actions\Action;
use Illuminate\Support\Collection;
use Laravel\Nova\Actions\Action;
use Laravel\Nova\Fields\ActionFields;

class ToggleArtistDisciplineImage extends Action
Expand All @@ -16,7 +16,7 @@ public function name()
public function handle(ActionFields $fields, Collection $models)
{
$work = $models->first();
$work->update(['is_artist_discipline_image' => !$work->is_artist_discipline_image]);
$work->update(['is_artist_discipline_image' => ! $work->is_artist_discipline_image]);
}

public function fields()
Expand Down
2 changes: 1 addition & 1 deletion src/Nova/Actions/ToggleRepresentsArtistInCategory.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public function name()
{
$category = Category::find($this->categoryId);

return __('AN/AUS "repräsentiert Künstler in Kategorie"').': '.$category->title;
return __('AN/AUS: In allgemeiner Kategorie-Übersicht zeigen').': '.$category->title;
}

public function handle(ActionFields $fields, Collection $models)
Expand Down
2 changes: 1 addition & 1 deletion src/Nova/Actions/ToggleShowInOverview.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class ToggleShowInOverview extends Action
{
public function name()
{
return __('AN/AUS "In Künstler-Übersicht zeigen, wenn ALLE KATEGORIEN ausgewählt ist"');
return __('AN/AUS: In Künstler-Übersicht zeigen, wenn ALLE KATEGORIEN ausgewählt ist');
}

public function handle(ActionFields $fields, Collection $models)
Expand Down
2 changes: 1 addition & 1 deletion src/Nova/Actions/ToggleShowInOverviewCategory.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public function name()
{
$category = Category::find($this->categoryId);

return __('AN/AUS "In Künstler-Übersicht zeigen, wenn eine einzelne Kategorie ausgewählt ist"').': '.$category->title;
return __('AN/AUS: In Künstler-Übersicht zeigen, wenn eine einzelne Kategorie ausgewählt ist').': '.$category->title;
}

public function handle(ActionFields $fields, Collection $models)
Expand Down
12 changes: 6 additions & 6 deletions src/Nova/Work.php
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ class="w-auto h-12 mr-1 inline-block"
Line::make('', function () {
if (is_array($this->representationCategorySlugs()) && $this->representationCategorySlugs()) {
return '<span class="text-xs uppercase">'
.__('nova-cms-portfolio::works.representation_categories')
.__('In allgemeiner Kategorie-Übersicht zeigen')
.': <span class="font-bold">'
.implode(', ', $this->representationCategorySlugs())
.'</span></span>';
Expand Down Expand Up @@ -262,17 +262,17 @@ public static function redirectAfterCreate(NovaRequest $request, $resource)
public function actions(Request $request)
{
$actions = [
ToggleShowInOverview::make()
->onlyOnTableRow()
->withoutConfirmation(),

ToggleArtistPortfolioImage::make()
->onlyOnTableRow()
->withoutConfirmation(),

ToggleArtistDisciplineImage::make()
ToggleShowInOverview::make()
->onlyOnTableRow()
->withoutConfirmation(),

// ToggleArtistDisciplineImage::make()
// ->onlyOnTableRow()
// ->withoutConfirmation(),
];

if ($request->viaResourceId) {
Expand Down

0 comments on commit 741a206

Please sign in to comment.