martin: server/kolab-webadmin/kolab-webadmin/php/admin/include form.class.php, 1.25, 1.26

cvs at intevation.de cvs at intevation.de
Fri Apr 21 12:41:40 CEST 2006


Author: martin

Update of /kolabrepository/server/kolab-webadmin/kolab-webadmin/php/admin/include
In directory doto:/tmp/cvs-serv14511/php/admin/include

Modified Files:
	form.class.php 
Log Message:
Martin Konold: Commited patch from Tobias König in order to support setting of foldertype for public folders.


Index: form.class.php
===================================================================
RCS file: /kolabrepository/server/kolab-webadmin/kolab-webadmin/php/admin/include/form.class.php,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -d -r1.25 -r1.26
--- form.class.php	29 Mar 2006 10:52:14 -0000	1.25
+++ form.class.php	21 Apr 2006 10:41:38 -0000	1.26
@@ -187,6 +187,30 @@
         $str .= '<td>'.$value['comment'].'</td>';
 		$str .= '</tr>'."\n";
 		break;
+	  case 'foldertypeselect':
+		$str .= '<tr>';
+		$str .= '<td>'.$value['name'].'</td>';
+                $entries = array ( '' => _('None'), 'mail' => _('Mails'), 'task' => _('Tasks'), 'journal' => _('Journals'),
+		                     'event' => _('Events'), 'contact' => _('Contacts'), 'note' => _('Notes'));
+		if( ereg( 'readonly', $value['attrs'] ) ) {
+		  $str .= '<td><p class="ctrl">'.MySmarty::htmlentities($entries[$value['value']]).
+			'<input type="hidden" name="'.$key.'" value="'.MySmarty::htmlentities($value['value']).'" /></p></td>';
+		} else {
+		  $str .= '<td><select name="'.$key.'" '.$value['attrs'].' >'."\n";
+		  foreach ($entries as $id => $title) {
+		  	if ( $value['value'] == $id )
+				$s = 'selected';
+			else
+				$s = '';
+
+		  	$str .= '<option value="'.$id.'" '.$s.'>'.MySmarty::htmlentities($title).'</option>'."\n";
+		  }
+		  $str .= '</select>';
+		  $str .= '</td>';
+		}
+        	$str .= '<td>'.$value['comment'].'</td>';
+		$str .= '</tr>'."\n";
+		break;
       case 'aclselect': // Special Kolab entry for ACLs
 		$str .= '<tr>';
 		$str .= '<td>'.$value['name'].'</td>';





More information about the commits mailing list