openrat-cms

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 43f5666a4cdeb243c39ef2709442143350ad71bc
parent 1bd630743b7f231103ac5afbd659809842a60c9a
Author: dankert <devnull@localhost>
Date:   Thu, 11 Sep 2008 21:06:41 +0200

Abfrage auf Modus.

Diffstat:
actionClasses/PageelementAction.class.php | 10++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/actionClasses/PageelementAction.class.php b/actionClasses/PageelementAction.class.php @@ -634,7 +634,13 @@ class PageelementAction extends Action $this->setTemplateVar( 'editor','text' ); $this->setTemplateVar( 'text',$this->value->text ); - + + if (! $this->isEditMode() ) + { + $this->value->generate(); // Inhalt erzeugen. + $this->setTemplateVar('text',$this->value->value); + } + if ( $this->getSessionVar('pageaction') != '' ) $this->setTemplateVar('old_pageaction',$this->getSessionVar('pageaction')); else $this->setTemplateVar('old_pageaction','show' ); @@ -734,7 +740,7 @@ class PageelementAction extends Action // Nicht aktive Inhalte können direkt bearbeitet werden und sind // nach dem Speichern dann wieder aktiv (natürlich als nächster/neuer Inhalt) if ( ! $value->active ) - $zeile['useUrl'] = Html::url('pageelement','usevalue',$this->page->objectid,array('valueid' =>$value->valueid)); + $zeile['useUrl'] = Html::url('pageelement','usevalue',$this->page->objectid,array('valueid' =>$value->valueid,'mode'=>'edit')); // Freigeben des Inhaltes. // Nur das aktive Inhaltselement kann freigegeben werden. Natürlich auch nur,