Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update snippets.md #388

Merged
merged 1 commit into from
Dec 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 22 additions & 1 deletion _docs/addons/yform/snippets.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: Nützliche YForm-Snippets
authors: [skerbis,isospin,netzproductions,pschuchmann,rotzek,alxndr-w]
authors: [skerbis,isospin,netzproductions,pschuchmann,rotzek,alxndr-w,danspringer,christophboecker]
prio:
---

Expand All @@ -11,6 +11,7 @@ prio:
- [Table Manager: Spalteninhalt vor Anzeige in Übersicht ändern](#Spalteninhalt)
- [Table Manager: Bilderspalte in Tabellenansicht (Bild statt Dateiname)](#ytbilder)
- [Table Manager: Extensionpoint / Listensortierung beeinflussen)](#ytlistsort)
- [Table Manager: Paginierung auch am Tabellenende](#yform_table_manager_paginierung)
- [Choice Feld Optionen holen](#Choicefieldoptionen)
- [YForm Menüpunkt für Redakteure ausblenden](#yform_menu)
- [Details zum Datensatz nach dem Erstellen erhalten](#yform_created)
Expand Down Expand Up @@ -180,6 +181,26 @@ if (
```
Einfach `<TABLE_NAME>` und `<SOMETHING ELSE>` wie gewünscht austauschen.

<a name="yform_table_manager_paginierung"></a>
## Table Manager: Paginierung auch am Tabellenende
In der boot.php des project-Addons oder wo es sonst passt:
```php
rex_yform_list::setFactoryClass(RexYformList::class);
```
Und im Lib-Verzeichnis diese Klasse:
```php
class RexYformList extends rex_yform_list
{
/**
* @return string
*/
public function get()
{
return parent::get() . $this->getPagination();
}
}
```


<a name="Choicefieldoptionen"></a>
### Choice Feld Optionen im Frontend verwenden
Expand Down
Loading