Führe Dokumente mit Kapiteln, Fassung, Seite und PDF mit Inhaltsverzeichnis ein (ADR-51)
Ein Dokument ist eine Komposition der Art document, ein Kapitel ein Text mit der automatischen Materialart Dokumentkapitel; die Ebene steht in der Rolle. Der Aufbaueditor bekommt den Kapitelarbeitsplatz (Übersicht, Ordnen als Block, offene Eingaben bleiben beim Wechsel erhalten, Speichern als Entwurf, Bereitstellen als Dokumentfassung). Module und Programme binden eine Fassung über den gemeinsamen Picker ein. Mitglieder lesen sie mit anklickbarem Inhaltsverzeichnis und laden ein PDF mit Inhaltsverzeichnis, Seitenzahlen, Tabellen und Bildern. Ein älterer Stand liefert die gebundene Fassung weiter. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
c57a506f85
commit
3e2fd872c2
43 files changed
+2827
-64
No files matched your search
@@ -45,7 +45,7 @@ public function mayOpen(User $user, LicenseArticle $article, ArticleRelease $rel
|
||||
*
|
||||
* @return array{version: CompositionVersion, selection: list<string>|null}|null
|
||||
*/
|
||||
public function locate(ArticleRelease $release, string $path): ?array
|
||||
public function locate(ArticleRelease $release, string $path, CompositionKind $kind = CompositionKind::Exercise): ?array
|
||||
{
|
||||
if (preg_match('/^\d+(-\d+)*$/', $path) !== 1) {
|
||||
return null;
|
||||
@@ -71,7 +71,7 @@ public function locate(ArticleRelease $release, string $path): ?array
|
||||
|
||||
$version?->loadMissing('composition');
|
||||
|
||||
if ($version === null || $version->composition === null || $version->composition->kind !== CompositionKind::Exercise) {
|
||||
if ($version === null || $version->composition === null || $version->composition->kind !== $kind) {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user