Changeset 12731

Show
Ignore:
Timestamp:
10/10/07 14:07:44 (1 year ago)
Author:
bergie
Message:

User account (username and password) editing, still needs links in toolbar

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/midcom/midcom.admin.user/config/config.inc

    r12708 r12731  
    11'schemadb_person' => 'file:/midcom/admin/user/config/schemadb_person.inc', 
     2'schemadb_account' => 'file:/midcom/admin/user/config/schemadb_account.inc', 
    23'schemadb_group' => 'file:/midcom/admin/user/config/schemadb_group.inc', 
    34'list_without_search' => 20, 
  • trunk/midcom/midcom.admin.user/config/schemadb_person.inc

    r12724 r12731  
    66    'fields'      => array  
    77    ( 
    8         'username' => array  
    9         ( 
    10             // COMPONENT-REQUIRED 
    11             'title'       => 'username', 
    12             'storage'     => 'username', 
    13             'type'        => 'text', 
    14             'widget'      => 'text', 
    15             'index_method' => 'noindex', 
    16         ), 
    178        'firstname' => array  
    189        ( 
  • trunk/midcom/midcom.admin.user/handler/user/edit.php

    r12729 r12731  
    4848     * Loads and prepares the schema database. 
    4949     */ 
    50     function _load_schemadb(
     50    function _load_schemadb($config_key
    5151    { 
    52         $this->_schemadb = midcom_helper_datamanager2_schema::load_database($this->_config->get('schemadb_person')); 
     52        $this->_schemadb = midcom_helper_datamanager2_schema::load_database($this->_config->get($config_key)); 
    5353    } 
    5454 
     
    6060    function _load_controller() 
    6161    { 
    62         $this->_load_schemadb(); 
    6362        $this->_controller =& midcom_helper_datamanager2_controller::create('simple'); 
    6463        $this->_controller->schemadb =& $this->_schemadb; 
     
    9594                 
    9695        $data['asgard_toolbar'] = new midcom_helper_toolbar(); 
     96 
     97         
     98        if ($handler_id == '____mfa-asgard_midcom.admin.user-user_edit_password') 
     99        { 
     100            $this->_load_schemadb('schemadb_account'); 
     101        } 
     102        else 
     103        { 
     104            $this->_load_schemadb('schemadb_person'); 
     105        } 
    97106         
    98107        $this->_load_controller(); 
  • trunk/midcom/midcom.admin.user/plugin.php

    r12716 r12731  
    6464            ), 
    6565            /** 
     66             * Edit a user's password 
     67             *  
     68             * Match /user-editor/edit/<guid>/ 
     69             */ 
     70            'user_edit_password' => array 
     71            ( 
     72                'handler' => array ('midcom_admin_user_handler_user_edit', 'edit'), 
     73                'fixed_args' => array ('password'), 
     74                'variable_args' => 1, 
     75            ), 
     76            /** 
    6677                 * Create new user 
    6778                 *