Hi Wiktor,

On Fri, Dec 06, 2002 at 11:40:35AM +0100, Wiktor Wodecki wrote:

> > Wiktor thanks for the idea! Ja, I'll write a backend module for 
> > Kernel::System::CustomerUser -=> Kernel::System::CustomerUser::IntDB 
> > If it's ready, it should be no problem to write a 
> > Kernel::System::CustomerUser::LDAP module.
> 
> okay, could you drop me a note when it's done? And what about the company/comment 
>field in the db?

Done. :) 

I created a new file Kernel/System/CustomerUser/DB.pm and added 

[...]
    # CustomerUser 
    # (customer user backend)
    $Self->{CustomerUser} = {
        Module => 'Kernel::System::CustomerUser::DB',
        Params => {
#            Host => '',
#            User => '',
#            Password => '',
            Table => 'customer_user',
        }, 
        Map => [
            # note: Login, Email and CustomerID needed!
            # var, frontend, storage, shown, required, storage-type
            [ 'UserSalutation', 'Salutation', 'salutation', 1, 0, 'var' ],
            [ 'UserFirstname', 'Firstname', 'first_name', 1, 1, 'var' ],
            [ 'UserLastname', 'Lastname', 'last_name', 1, 1, 'var' ],
            [ 'UserLogin', 'Login', 'login', 1, 1, 'var' ],
            [ 'UserPassword', 'Password', 'pw', 0, 1, 'var' ],
            [ 'UserEmail', 'Email', 'email', 1, 1, 'var' ],
            [ 'UserCustomerID', 'CustomerID', 'customer_id', 1, 1, 'var' ],
            [ 'UserComment', 'Comment', 'comment', 1, 0, 'var' ],
            [ 'ValidID', 'Valid', 'valid_id', 0, 1, 'int' ],
        ],
        Key => 'login',
        CustomerID => 'customer_id',
    };
[...]

to Kernel/Config/Defaults.pm. 

This describes the table structure of the customer_user table. If you 
change the columns (adde more fields), add just more types to the map 
and you can handle it.  

You also can change the database (if the table comes from another database).

The Kernel/System/CustomerUser/DB.pm module should be a good start for 
Kernel/System/CustomerUser/LDAP.pm. 

> Wiktor Wodecki

  Martin

--
Martin Edenhofer - <martin at edenhofer.de> - http://martin.edenhofer.de/
--
"There are two major products that come out of Berkeley: LSD and Unix.
We don't believe this to be a coincidence."  -- Jeremy S. Anderson

_______________________________________________
OpenTRS mailing list: dev - Webpage: http://otrs.org/
Archive: http://lists.otrs.org/pipermail/dev
To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/dev

Reply via email to