diff --git a/controllers/file.php b/controllers/file.php index 580abbece4e3757595457a1a68adf0f79d4480ef..810afc53f3f14d1b18252b2bbfdb6064285d5e08 100644 --- a/controllers/file.php +++ b/controllers/file.php @@ -114,7 +114,7 @@ class FileController extends PluginController PageLayout::postError( sprintf( dgettext('NextcloudPlugin', 'Ein Fehler trat auf beim Aktualisieren der Datei „%s“.'), - htmlReady($this->file_ref->name) + htmlReady($this->file->getFilename()) ), $this->errors ); @@ -122,7 +122,7 @@ class FileController extends PluginController PageLayout::postSuccess( sprintf( dgettext('NextcloudPlugin', 'Die Datei „%s“ wurde aktualisiert!'), - htmlReady($this->file_ref->name) + htmlReady($this->file->getFilename()) ) ); } diff --git a/plugin.manifest b/plugin.manifest index e81ef4ac8559641662f6c2264ddccdbd7e174380..e31fd9d830810380c4f5facd2e028796f321833d 100755 --- a/plugin.manifest +++ b/plugin.manifest @@ -1,6 +1,6 @@ pluginname=NextcloudPlugin pluginclassname=NextcloudPlugin -version=3.0.1 +version=3.1.0 origin=data-quest studipMinVersion=5.0 -studipMaxVersion=5.4.99 +studipMaxVersion=5.5.99 diff --git a/views/file/edit.php b/views/file/edit.php index dffeeff6d972d125b60aa868917d660dc11e4e2f..60f515e33e03604d26d8bc0dfde78b620fd2fead 100644 --- a/views/file/edit.php +++ b/views/file/edit.php @@ -2,7 +2,7 @@ <?= $aside_template->render() ?> <div id="file_management_forms"> <form method="post" data-dialog class="default" - action="<?= $controller->link_for('/edit/' . $file->getId()) ?>"> + action="<?= PluginEngine::getURL(NextcloudPlugin::class, [], 'file/edit/' . $file->getId()) ?>"> <?= CSRFProtection::tokenTag() ?> <fieldset> <legend><?= dgettext('NextcloudPlugin', 'Datei bearbeiten') ?></legend> diff --git a/views/file/update.php b/views/file/update.php index d68723184426b9f8ea6e380883db354136ec5cc1..aa60493aab02c3a6276ed3a2bf1d7695036f69d6 100644 --- a/views/file/update.php +++ b/views/file/update.php @@ -1,4 +1,4 @@ -<form action="<?= $controller->link_for('file/update/' . $file->getId(), ['from_plugin' => $from_plugin]) ?>" +<form action="<?= PluginEngine::getURL(NextcloudPlugin::class, ['from_plugin' => $from_plugin], 'file/update/' . $file->getId()) ?>" enctype="multipart/form-data" method="post" class="default"> <?= CSRFProtection::tokenTag() ?> <fieldset>