Dynamic Field - Multi Valued String

Moderator: crythias

Post Reply
SuperDOS
Znuny newbie
Posts: 93
Joined: 17 Apr 2012, 16:16
Znuny Version: 6.0.3
Real Name: A!

Dynamic Field - Multi Valued String

Post by SuperDOS »

Added a new dynamic text field for customers called computer.
Now I want to fetch the serial number from the AD that is stored on the user in the attribute serialnumber

In my Config.pm I added a mapping:
[ 'DynamicField_Computer', 'Computer', 'serialNumber', 1, 0, 'var', '', 0 ],

But all I get is a blank textbox.
Is this becaus its a multi-valued string, and if so how can I fetch this information?

thanks
jojo
Znuny guru
Posts: 15019
Joined: 26 Jan 2007, 14:50
Znuny Version: Git Master
Contact:

Re: Dynamic Field - Multi Valued String

Post by jojo »

the dynamic fields for customers do not point to an external data source.
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master

Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
SuperDOS
Znuny newbie
Posts: 93
Joined: 17 Apr 2012, 16:16
Znuny Version: 6.0.3
Real Name: A!

Re: Dynamic Field - Multi Valued String

Post by SuperDOS »

But I sync other values from the AD like department, Name, Telehponenumber and so on.

Code: Select all

            # note: Login, Email and CustomerID needed!
            # var, frontend, storage, shown (1=always,2=lite), required, storage-type, http-link, readonly, http-link-target, link class(es)
            [ 'UserTitle',      'Title',      'title',      1, 0, 'var', '', 0 ],
        [ 'DynamicField_Department',    'Department',    'Department',     1, 0, 'var', '', 0 ],
            [ 'UserFirstname',  'Firstname',  'givenname', 1, 1, 'var', '', 0 ],
            [ 'UserLastname',   'Lastname',   'sn',  1, 1, 'var', '', 0 ],
            [ 'UserLogin',      'Username',   'sAMAccountName',      1, 1, 'var', '', 0 ],
#            [ 'UserPassword',   'Password',   'pw',         0, 0, 'var', '', 0 ],
            [ 'UserEmail',      'Email',      'mail',      1, 1, 'var', '', 0 ],
#            [ 'UserEmail',      'Email', 'email',           1, 1, 'var', '[% Env("CGIHandle") %]?Action=AgentTicketCompose;ResponseID=1;TicketID=[% Data.TicketID | uri %];ArticleID=[% Data.ArticleID | uri %]', 0, '', 'AsPopup OTRSPopup_TicketAction' ],
            [ 'UserCustomerID', 'CustomerID', 'sAMAccountName', 0, 1, 'var', '', 0 ],
#            [ 'UserCustomerIDs', 'CustomerIDs', 'customer_ids', 1, 0, 'var', '', 0 ],
            [ 'UserPhone',        'Phone',       'telephoneNumber',        1, 0, 'var', '#"><a href="tel:[% Data.UserPhone%]', 0 ],
#            [ 'UserFax',          'Fax',         'facsimileTelephoneNumber',          1, 0, 'var', '', 0 ],
            [ 'UserMobile',       'Mobile',      'mobile',       1, 0, 'var', '#"></a><a href="tel:[% Data.UserMobile%]', 0 ],
            [ 'UserStreet',       'Street',      'streetAddress',       1, 0, 'var', '', 0 ],
            [ 'UserZip',          'Zip',         'postalCode',          1, 0, 'var', '', 0 ],
            [ 'UserCity',         'City',        'l',         1, 0, 'var', '', 0 ],
#            [ 'UserCountry',      'Country',     'country',      1, 0, 'var', '', 0 ],
#            [ 'UserComment',      'Comment',     'comments',     1, 0, 'var', '', 0 ],
#            [ 'ValidID',          'Valid',       'valid_id',     0, 1, 'int', '', 0 ],
        [ 'DynamicField_Computer',    'Computer',    'serialNumber',     1, 0, 'var', '', 0 ],
        ],
		};
jojo
Znuny guru
Posts: 15019
Joined: 26 Jan 2007, 14:50
Znuny Version: Git Master
Contact:

Re: Dynamic Field - Multi Valued String

Post by jojo »

but dynamic fields point always to the dynamic fields configured in OTRS
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master

Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
SuperDOS
Znuny newbie
Posts: 93
Joined: 17 Apr 2012, 16:16
Znuny Version: 6.0.3
Real Name: A!

Re: Dynamic Field - Multi Valued String

Post by SuperDOS »

Ok so I don't really need to add dynamic field to add a new field for custoemr?

I can Simply add for instance [ 'Department', 'Department', 'Department', 1, 0, 'var', '', 0 ], ?

Still need to figure out how to map a multi-valued ad attribute to a field, if it's possible.
Post Reply