From 3731b255e88ce2a42ea5c3d2300333f720488dce Mon Sep 17 00:00:00 2001 From: Samuell Date: Fri, 16 Aug 2019 10:15:13 +0200 Subject: [PATCH 1/2] Add component caching --- components/ContentEditor.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/components/ContentEditor.php b/components/ContentEditor.php index 2835300..cbb3d55 100644 --- a/components/ContentEditor.php +++ b/components/ContentEditor.php @@ -1,5 +1,6 @@ checkEditor()) { $this->content = $content; } else { - return $this->renderPartial('@render.htm', ['content' => $content]); + return Cache::remember('contenteditor::content-' . $this->file, now()->addHours(24), function () use ($content) { + return $this->renderPartial('@render.htm', ['content' => $content]); + }); } } From 4603b524a04b42b647158655091d0a4cff83d27a Mon Sep 17 00:00:00 2001 From: Samuell Date: Sat, 17 Aug 2019 11:22:47 +0200 Subject: [PATCH 2/2] Update version.yaml --- updates/version.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/updates/version.yaml b/updates/version.yaml index 9f45608..6f97bfa 100644 --- a/updates/version.yaml +++ b/updates/version.yaml @@ -34,4 +34,6 @@ 1.2.4: - Allow style attribute in property dialog - Add support for image cropping - - Added permissions for backend settings page \ No newline at end of file + - Added permissions for backend settings page +1.2.5: + - Add component caching