openrat-cms

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

commit 4d246c998d0822f55528fa1ae1084dd53c1976a0
parent 2d38c49a35e4df7414d2f151717a848a1326ff76
Author: dankert <devnull@localhost>
Date:   Tue, 24 Jan 2006 00:10:46 +0100

*** empty log message ***

Diffstat:
actionClasses/LinkAction.class.php | 105++++++++++++++++++++++++++++++++++++++++++++++++-------------------------------
actionClasses/MainAction.class.php | 77++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-------
actionClasses/MainmenuAction.class.php | 85+++++++++++++++++++++++++++++++++++++++++++++++++++++++------------------------
actionClasses/ObjectAction.class.php | 75+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++----------------
actionClasses/PageAction.class.php | 21+++++++++++++++++++++
actionClasses/ProfileAction.class.php | 10++++++----
actionClasses/ProjectAction.class.php | 58++++++++++++++++++++++++++++++++++++----------------------
actionClasses/TemplateAction.class.php | 8++++----
8 files changed, 319 insertions(+), 120 deletions(-)

diff --git a/actionClasses/LinkAction.class.php b/actionClasses/LinkAction.class.php @@ -20,7 +20,10 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // --------------------------------------------------------------------------- // $Log$ -// Revision 1.6 2004-12-20 22:04:25 dankert +// Revision 1.7 2006-01-23 23:10:45 dankert +// *** empty log message *** +// +// Revision 1.6 2004/12/20 22:04:25 dankert // kein Lesen der Benutzer // // Revision 1.5 2004/12/15 23:23:11 dankert @@ -70,58 +73,41 @@ class LinkAction extends ObjectAction } - /** - * Verschieben der Verkn?pfung - */ - function move() - { - $this->objectMove(); - $this->link->load(); - - $this->callSubAction('prop'); - } - - /** * Abspeichern der Eigenschaften */ function save() { - // Wenn Name gef?llt, dann Datenbank-Update + // Wenn Name gefuellt, dann Datenbank-Update if ( $this->getRequestVar('name') != '' ) { - if ( $this->getRequestVar('delete') != '' ) - { - // Verknuepfung l?schen - $this->link->delete(); + // Eigenschaften speichern + $this->link->name = $this->getRequestVar('name'); + $this->link->desc = $this->getRequestVar('desc'); - $this->getRequestVar('tree_refresh',true); - $this->forward('blank'); + $this->link->save(); + $this->link->setTimestamp(); + Session::setObject( $this->link ); + } + elseif( $this->getRequestVar('type') != '' ) + { + if ( $this->getRequestVar('type') == 'link' ) + { + $this->link->isLinkToObject = true; + $this->link->isLinkToUrl = false; + $this->link->linkedObjectId = $this->getRequestVar('linkobjectid'); } else { - // Eigenschaften speichern - $this->link->name = $this->getRequestVar('name'); - $this->link->desc = $this->getRequestVar('desc'); - - if ( $this->getRequestVar('type') == 'link' ) - { - $this->link->isLinkToObject = true; - $this->link->isLinkToUrl = false; - $this->link->linkedObjectId = $this->getRequestVar('linkobjectid'); - } - else - { - $this->link->isLinkToObject = false; - $this->link->isLinkToUrl = true; - $this->link->url = $this->getRequestVar('url'); - } - - $this->link->save(); - $this->link->setTimestamp(); - Session::setObject( $this->link ); + $this->link->isLinkToObject = false; + $this->link->isLinkToUrl = true; + $this->link->url = $this->getRequestVar('url'); } + + $this->link->save(); + $this->link->setTimestamp(); + Session::setObject( $this->link ); } $this->getRequestVar('tree_refresh',true); @@ -130,9 +116,35 @@ class LinkAction extends ObjectAction } + function target() + { +// $this->setTemplateVars( $this->link->getProperties() ); + + // Typ der Verkn?pfung + $this->setTemplateVar('type' ,$this->link->getType() ); + $this->setTemplateVar('act_linkobjectid',$this->link->linkedObjectId); + $this->setTemplateVar('url' ,$this->link->url ); + + $this->setTemplateVar('edittarget_url',Html::url('link','edittarget',$this->link->objectid)); + + $this->forward('link_target'); + } + + + function prop() { $this->setTemplateVars( $this->link->getProperties() ); + $this->setTemplateVar('editprop_url' ,Html::url('link','editprop',$this->link->objectid)); + + $this->forward('link_prop'); + } + + + + function edittarget() + { + $this->setTemplateVars( $this->link->getProperties() ); // Typ der Verkn?pfung $this->setTemplateVar('type' ,$this->link->getType() ); @@ -161,6 +173,17 @@ class LinkAction extends ObjectAction asort( $list ); $this->setTemplateVar('objects',$list); - $this->forward('link_prop'); + $this->forward('link_edittarget'); + } + + + + function editprop() + { + $this->setTemplateVars( $this->link->getProperties() ); + + $this->setTemplateVar('act_linkobjectid',$this->link->linkedObjectId); + + $this->forward('link_editprop'); } } \ No newline at end of file diff --git a/actionClasses/MainAction.class.php b/actionClasses/MainAction.class.php @@ -20,7 +20,10 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // --------------------------------------------------------------------------- // $Log$ -// Revision 1.7 2006-01-11 22:52:24 dankert +// Revision 1.8 2006-01-23 23:10:46 dankert +// *** empty log message *** +// +// Revision 1.7 2006/01/11 22:52:24 dankert // URLs f?r neue Frames setzen // // Revision 1.6 2005/01/14 21:41:23 dankert @@ -55,6 +58,68 @@ class MainAction extends Action { var $defaultSubAction = 'show'; + var $doActionName = ""; + + + function element() + { + $this->doActionName = 'element'; + } + function folder() + { + $this->doActionName = 'folder'; + } + function file() + { + $this->doActionName = 'file'; + } + function group() + { + $this->doActionName = 'group'; + } + function language() + { + $this->doActionName = 'language'; + } + function link() + { + $this->doActionName = 'link'; + } + function model() + { + $this->doActionName = 'model'; + } + function page() + { + $this->doActionName = 'page'; + } + function pagelement() + { + $this->doActionName = 'pagelement'; + } + function project() + { + $this->doActionName = 'project'; + } + function search() + { + $this->doActionName = 'search'; + } + function template() + { + $this->doActionName = 'template'; + } + function transfer() + { + $this->doActionName = 'transfer'; + } + function user() + { + $this->doActionName = 'user'; + } + + + function show() { $user = Session::getUser(); @@ -71,12 +136,10 @@ class MainAction extends Action } // Variablen fuellen - $this->setTemplateVar('frame_src_main_menu',Html::url( 'mainmenu' ,$this->getRequestVar('subaction'),$this->getRequestId(),$params ) ); - $this->setTemplateVar('frame_src_main_main',Html::url( $this->getRequestVar('subaction'),'' ,$this->getRequestId(),$params ) ); - $this->setTemplateVar( 'frame_src_border' ,Html::url( 'border' ) ); - $this->setTemplateVar( 'frame_src_background',Html::url( 'background' ) ); - - $this->forward('frameset_main'); // Forward auf View + $this->setTemplateVar('frame_src_main_menu' ,Html::url( 'mainmenu' ,$this->doActionName,$this->getRequestId(),$params ) ); + $this->setTemplateVar('frame_src_main_main' ,Html::url( $this->doActionName,'' ,$this->getRequestId(),$params ) ); + $this->setTemplateVar('frame_src_border' ,Html::url( 'border' ) ); + $this->setTemplateVar('frame_src_background',Html::url( 'background' ) ); } } diff --git a/actionClasses/MainmenuAction.class.php b/actionClasses/MainmenuAction.class.php @@ -30,6 +30,7 @@ class MainmenuAction extends Action var $defaultSubAction = 'login'; var $subActionList = array(); + var $path = array(); var $obj; @@ -43,7 +44,18 @@ class MainmenuAction extends Action function addSubAction( $name,$aclbit=0 ) { if ( $aclbit==0 || $this->obj->hasRight($aclbit) ) - $this->subActionList[ $name ] = lang( 'MENU_'.strtoupper($name) ); + $this->subActionList[ $name ] = array( 'text' =>lang('MENU_'.strtoupper($name) ), + 'title'=>lang('MENU_'.strtoupper($name).'_DESC' ), + 'url' =>Html::url($this->subActionName,$name,$this->getRequestId() ) ); + } + + + function addPath( $name,$title,$url,$type ) + { + $this->path[$name] = array('name' =>$name , + 'title'=>$title, + 'url' =>$url , + 'type' =>$type ); } @@ -67,7 +79,7 @@ class MainmenuAction extends Action } $this->setTemplateVar('param' ,'templateid'); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->callSubAction('show'); } @@ -98,7 +110,8 @@ class MainmenuAction extends Action $folder->filenames = false; $folder->load(); - $this->setTemplateVar('folder',$folder->parentObjectNames(true,true)); + foreach( $folder->parentObjectNames(true,true) as $id=>$name ) + $this->addPath($name,$name,Html::url('main','folder',$id),'folder'); $others = $folder->getObjects(); $o2 = array(); @@ -115,14 +128,14 @@ class MainmenuAction extends Action $this->addSubAction('show' ,ACL_READ ); $this->addSubAction('edit' ,ACL_WRITE ); $this->addSubAction('el' ,ACL_WRITE ); - $this->addSubAction('form' ,ACL_WRITE ); +// $this->addSubAction('form' ,ACL_WRITE ); $this->addSubAction('pub' ,ACL_PUBLISH ); $this->addSubAction('prop' ,ACL_PROP ); $this->addSubAction('src' ,ACL_PROP ); $this->addSubAction('rights',ACL_GRANT ); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->callSubAction('show'); } @@ -131,7 +144,7 @@ class MainmenuAction extends Action function user() { - $this->setTemplateVar('folder',array() ); + $this->setTemplateVar('path',array() ); $user = new User( $this->getRequestId() ); $user->load(); @@ -151,7 +164,7 @@ class MainmenuAction extends Action $this->addSubaction('rights' ); } - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param' ,'userid' ); $this->callSubAction('show'); @@ -161,7 +174,7 @@ class MainmenuAction extends Action function group() { - $this->setTemplateVar('folder',array() ); + $this->setTemplateVar('path',array() ); $group = new Group( $this->getRequestId() ); $group->load(); @@ -174,7 +187,7 @@ class MainmenuAction extends Action $this->addSubaction('edit' ); $this->addSubaction('users' ); } - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param' ,'groupid' ); $this->callSubAction('show'); @@ -193,7 +206,9 @@ class MainmenuAction extends Action $this->setTemplateVar('nr',$this->getSessionVar('objectid')); - $this->setTemplateVar('folder',$folder->parentObjectNames(true,true)); + foreach( $folder->parentObjectNames(true,true) as $id=>$name ) + $this->addPath($name,$name,Html::url('main','folder',$id),'folder'); + $this->setTemplateVar('text' ,$file->name); $this->setTemplateVar('id','o'.$file->objectid); @@ -207,7 +222,7 @@ class MainmenuAction extends Action $this->addSubAction('prop' ,ACL_PROP ); $this->addSubAction('rights',ACL_GRANT ); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param','objectid'); @@ -216,6 +231,18 @@ class MainmenuAction extends Action + function prefs() + { + $this->addSubaction('show'); + + $this->setTemplateVar('windowMenu',$this->subActionList); + $this->setTemplateVar('param','conf'); + + $this->callSubAction('show'); + } + + + function link() { // Ermitteln Sprache @@ -228,16 +255,19 @@ class MainmenuAction extends Action $this->setTemplateVar('nr',$this->getSessionVar('objectid')); - $this->setTemplateVar('folder',$folder->parentObjectNames(true,true)); + foreach( $folder->parentObjectNames(true,true) as $id=>$name ) + $this->addPath($name,$name,Html::url('main','folder',$id),'folder'); + $this->setTemplateVar('text' ,$link->name); $this->setTemplateVar('id','o'.$link->objectid); $this->obj = &$link; + $this->addSubAction('target',ACL_WRITE); $this->addSubAction('prop' ,ACL_PROP ); $this->addSubAction('rights',ACL_GRANT); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param','objectid'); $this->callSubAction('show'); @@ -260,24 +290,26 @@ class MainmenuAction extends Action $folder->load(); - $this->setTemplateVar('folder',$folder->parentObjectNames(true,false)); + foreach( $folder->parentObjectNames(true,false) as $id=>$name ) + $this->addPath($name,$name,Html::url('main','folder',$id),'folder'); $this->setTemplateVar('text',$folder->name); $this->addSubAction('show',ACL_READ ); - if ( !$folder->isRoot ) - $this->addSubAction('prop',ACL_PROP ); - $this->addSubAction('create',ACL_CREATE_FOLDER ); $this->addSubAction('create',ACL_CREATE_FILE ); $this->addSubAction('create',ACL_CREATE_PAGE ); $this->addSubAction('create',ACL_CREATE_LINK ); $this->addSubAction('pub' ,ACL_PUBLISH ); + + if ( !$folder->isRoot ) + $this->addSubAction('prop',ACL_PROP ); + $this->addSubAction('rights',ACL_GRANT); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param','objectid'); $this->callSubAction('show'); @@ -286,7 +318,7 @@ class MainmenuAction extends Action function project() { - $this->setTemplateVar('folder',array() ); + $this->setTemplateVar('path',array() ); $this->addSubaction('listing'); @@ -303,7 +335,7 @@ class MainmenuAction extends Action $this->setTemplateVar('text','' ); } - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param','projectid'); $this->callSubAction('show'); @@ -314,7 +346,7 @@ class MainmenuAction extends Action { $this->addSubaction('listing'); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param','languageid'); $this->callSubAction('show'); @@ -325,7 +357,7 @@ class MainmenuAction extends Action function model() { $this->addSubaction('listing'); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->setTemplateVar('param','modelid'); $this->callSubAction('show'); @@ -334,7 +366,7 @@ class MainmenuAction extends Action function search() { - $this->setTemplateVar('subaction',array('prop' =>lang('SEARCH_PROP' ), + $this->setTemplateVar('windowMenu',array('prop' =>lang('SEARCH_PROP' ), 'content'=>lang('SEARCH_CONTENT' ) )); $this->setTemplateVar('param','objectid'); @@ -345,7 +377,7 @@ class MainmenuAction extends Action function transfer() { $this->addSubaction('import'); - $this->setTemplateVar('subaction',$this->subActionList); + $this->setTemplateVar('windowMenu',$this->subActionList); $this->callSubAction('show'); } @@ -362,9 +394,10 @@ class MainmenuAction extends Action $this->setTemplateVar('name' ,$this->subActionName); $this->setTemplateVar('css_body_class','menu' ); - $this->setTemplateVar('type' ,$this->subActionName); + $this->setTemplateVar('type' ,$this->getRequestVar( 'subaction') ); + $this->setTemplateVar('path' ,$this->path ); - $this->forward( 'main_menu' ); + $this->forward( 'menu' ); } } diff --git a/actionClasses/ObjectAction.class.php b/actionClasses/ObjectAction.class.php @@ -20,7 +20,10 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // --------------------------------------------------------------------------- // $Log$ -// Revision 1.4 2004-12-19 14:56:33 dankert +// Revision 1.5 2006-01-23 23:10:46 dankert +// *** empty log message *** +// +// Revision 1.4 2004/12/19 14:56:33 dankert // Abfrage von Rechten // // Revision 1.3 2004/11/28 19:25:38 dankert @@ -85,11 +88,14 @@ class ObjectAction extends Action $acl->objectid = $this->getRequestId(); + // Nachschauen, ob der Benutzer ueberhaupt berechtigt ist, an + // diesem Objekt die ACLs zu aendern. $o = new Object( $acl->objectid ); if ( !$o->hasRight( ACL_GRANT ) ) - die('uh?'); + die('uh?'); // Scheiss Hacker. + // Handelt es sich um eine Benutzer- oder Gruppen ACL? switch( $this->getRequestVar('type') ) { case 'user': @@ -103,17 +109,17 @@ class ObjectAction extends Action $acl->languageid = $this->getRequestVar('languageid'); - $acl->write = ( $this->getRequestVar('write' ) != '' ); - $acl->prop = ( $this->getRequestVar('prop' ) != '' ); - $acl->delete = ( $this->getRequestVar('delete' ) != '' ); - $acl->release = ( $this->getRequestVar('release' ) != '' ); - $acl->publish = ( $this->getRequestVar('publish' ) != '' ); - $acl->create_folder = ( $this->getRequestVar('create_folder') != '' ); - $acl->create_file = ( $this->getRequestVar('create_file' ) != '' ); - $acl->create_link = ( $this->getRequestVar('create_link' ) != '' ); - $acl->create_page = ( $this->getRequestVar('create_page' ) != '' ); - $acl->grant = ( $this->getRequestVar('grant' ) != '' ); - $acl->transmit = ( $this->getRequestVar('transmit' ) != '' ); + $acl->write = ( $this->hasRequestVar('write' ) ); + $acl->prop = ( $this->hasRequestVar('prop' ) ); + $acl->delete = ( $this->hasRequestVar('delete' ) ); + $acl->release = ( $this->hasRequestVar('release' ) ); + $acl->publish = ( $this->hasRequestVar('publish' ) ); + $acl->create_folder = ( $this->hasRequestVar('create_folder') ); + $acl->create_file = ( $this->hasRequestVar('create_file' ) ); + $acl->create_link = ( $this->hasRequestVar('create_link' ) ); + $acl->create_page = ( $this->hasRequestVar('create_page' ) ); + $acl->grant = ( $this->hasRequestVar('grant' ) ); + $acl->transmit = ( $this->hasRequestVar('transmit' ) ); $acl->add(); @@ -127,8 +133,10 @@ class ObjectAction extends Action */ function rights() { + $this->actionName = 'object'; $o = Session::getObject(); $o->objectLoadRaw(); + $this->setTemplateVar( 'show',$o->getRelatedAclTypes() ); $acllist = array(); foreach( $o->getAllInheritedAclIds() as $aclid ) @@ -152,6 +160,23 @@ class ObjectAction extends Action $this->setTemplateVar('acls',$acllist ); $this->setTemplateVars( $o->getAssocRelatedAclTypes() ); + + $this->setWindowMenu( 'acl' ); + + $this->forward('object_rights'); + } + + + + /** + * Formular anzeigen, um Rechte hinzufuegen + */ + function aclform() + { + $o = Session::getObject(); + $o->objectLoadRaw(); + + $this->setTemplateVars( $o->getAssocRelatedAclTypes() ); $this->setTemplateVar( 'show',$o->getRelatedAclTypes() ); $this->setTemplateVar('users' ,User::listAll() ); @@ -163,13 +188,16 @@ class ObjectAction extends Action $this->setTemplateVar('objectid' ,$o->objectid ); $this->setTemplateVar('action' ,$this->actionName); - $this->forward('object_rights'); + $this->setWindowMenu( 'acl' ); + + $this->forward('object_aclform'); } /** * Entfernen einer ACL + * * @access protected */ function delacl() @@ -177,14 +205,29 @@ class ObjectAction extends Action $acl = new Acl($this->getRequestVar('aclid')); $acl->objectid = $this->getRequestId(); + // Nachschauen, ob der Benutzer ueberhaupt berechtigt ist, an + // diesem Objekt die ACLs zu aendern. $o = new Object( $this->getRequestId() ); if ( !$o->hasRight( ACL_GRANT ) ) - die('ehm?'); + die('ehm?'); // Da wollte uns wohl einer vereimern. - $acl->delete(); + $acl->delete(); // Weg mit der ACL $this->callSubAction('rights'); } + + + function setWindowMenu( $type ) { + switch( $type) + { + case 'acl': + $menu = array( array('subaction'=>'rights' ,'text'=>'show'), + array('subaction'=>'aclform','text'=>'add' ) ); + $this->setTemplateVar('windowMenu',$menu); + break; + } + } + } \ No newline at end of file diff --git a/actionClasses/PageAction.class.php b/actionClasses/PageAction.class.php @@ -430,6 +430,8 @@ class PageAction extends ObjectAction } } + $this->setWindowMenu( 'elements' ); + $this->setTemplateVar('el',$list); $this->forward('page_element'); @@ -527,6 +529,7 @@ class PageAction extends ObjectAction $this->setTemplateVar( 'release',$this->page->hasRight(ACL_RELEASE) ); $this->setTemplateVar( 'publish',$this->page->hasRight(ACL_PUBLISH) ); + $this->setWindowMenu( 'elements' ); $this->setTemplateVar('el',$list); $this->forward('page_form'); } @@ -678,6 +681,24 @@ class PageAction extends ObjectAction $this->callSubaction('pub'); } + + + function setWindowMenu( $type ) { + switch( $type) + { + case 'elements': + $menu = array( array('subaction'=>'el' ,'text'=>'all'), + array('subaction'=>'form','text'=>'change' ) ); + $this->setTemplateVar('windowMenu',$menu); + break; + case 'acl': + $menu = array( array('subaction'=>'rights' ,'text'=>'show'), + array('subaction'=>'aclform','text'=>'add' ) ); + $this->setTemplateVar('windowMenu',$menu); + break; + + } + } } ?> \ No newline at end of file diff --git a/actionClasses/ProfileAction.class.php b/actionClasses/ProfileAction.class.php @@ -51,12 +51,17 @@ class ProfileAction extends Action $this->user->save(); $this->addNotice('user',$this->user->name,'SAVED','ok'); - $this->callSubAction('edit'); } function pwchange() { + } + + + + function savepw() + { if ( $this->getRequestVar('password1') != '' && $this->getRequestVar('password1') == $this->getRequestVar('password2') ) { @@ -84,7 +89,6 @@ class ProfileAction extends Action } } - $this->callSubAction('edit'); } @@ -94,7 +98,5 @@ class ProfileAction extends Action $this->setTemplateVars( $this->user->getProperties() ); $this->setTemplateVar( 'allstyles',$this->user->getAvailableStyles() ); - - $this->forward( 'user_profile' ); } } \ No newline at end of file diff --git a/actionClasses/ProjectAction.class.php b/actionClasses/ProjectAction.class.php @@ -20,7 +20,10 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // --------------------------------------------------------------------------- // $Log$ -// Revision 1.7 2004-12-26 20:24:16 dankert +// Revision 1.8 2006-01-23 23:10:46 dankert +// *** empty log message *** +// +// Revision 1.7 2004/12/26 20:24:16 dankert // Korrektur Abfrage Berechtigungen // // Revision 1.6 2004/12/19 15:16:02 dankert @@ -71,32 +74,26 @@ class ProjectAction extends Action function save() { - if ( $this->getRequestVar('delete') != '' ) - { - // Gesamtes Projekt l?schen - $this->project->delete(); - - $this->setTemplateVar('tree_refresh',true); - } - else - { - $this->project->name = $this->getRequestVar('name' ); - $this->project->target_dir = $this->getRequestVar('target_dir' ); - $this->project->ftp_url = $this->getRequestVar('ftp_url' ); - $this->project->ftp_passive = $this->getRequestVar('ftp_passive' ); - $this->project->cmd_after_publish = $this->getRequestVar('cmd_after_publish' ); - $this->project->content_negotiation = $this->getRequestVar('content_negotiation'); - $this->project->cut_index = $this->getRequestVar('cut_index' ); - - $this->project->save(); // speichern - } - - $this->callSubAction('listing'); + $this->project->name = $this->getRequestVar('name' ); + $this->project->target_dir = $this->getRequestVar('target_dir' ); + $this->project->ftp_url = $this->getRequestVar('ftp_url' ); + $this->project->ftp_passive = $this->getRequestVar('ftp_passive' ); + $this->project->cmd_after_publish = $this->getRequestVar('cmd_after_publish' ); + $this->project->content_negotiation = $this->getRequestVar('content_negotiation'); + $this->project->cut_index = $this->getRequestVar('cut_index' ); + + $this->project->save(); // speichern } + function add() { + } + + + function addproject() + { // Projekt hinzufuegen if ( $this->getRequestVar('name') != '' ) { @@ -161,4 +158,21 @@ class ProjectAction extends Action $this->forward('project_edit'); } + + + function remove() + { + } + + + function delete() + { + if ( $this->getRequestVar('delete') != '' ) + { + // Gesamtes Projekt loeschen + $this->project->delete(); + + $this->setTemplateVar('tree_refresh',true); + } + } } \ No newline at end of file diff --git a/actionClasses/TemplateAction.class.php b/actionClasses/TemplateAction.class.php @@ -20,7 +20,10 @@ // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. // --------------------------------------------------------------------------- // $Log$ -// Revision 1.10 2005-11-07 22:32:20 dankert +// Revision 1.11 2006-01-23 23:10:46 dankert +// *** empty log message *** +// +// Revision 1.10 2005/11/07 22:32:20 dankert // Neue Methode "edit()" // // Revision 1.9 2005/01/05 23:11:14 dankert @@ -525,9 +528,6 @@ class TemplateAction extends Action // $var['templatemodelid'] = htmlentities( $id ); // $var['text'] = htmlentities( $text ); $this->setTemplateVar('templates',$list); - - $this->forward('template_list'); - } } \ No newline at end of file