Hello,
I want to fill a freetext with the state/province field in the LDAP base.
Is there a way to do that automaticaly ?
This will be very usefull for statistique ...
Thanks
Fill freetext with ldap field
Moderator: crythias
-
- Znuny advanced
- Posts: 149
- Joined: 25 Oct 2010, 10:02
- Znuny Version: 3.2
- Location: Bangalore, India
Re: Fill freetext with ldap field
You can display those details without using free text fields. Check out the below section that you use in Config.pm when you configure LDAP. If you set the parameter before var to 1, they can be displayed in Agent screen. Pls note that this section is from Config.pm when you need to point OTRS to get customers from LDAP. Lemme know if you have any questions.
# # cache time to live in sec. - cache any database queries
CacheTTL => 120,
Map => [
# note: Login, Email and CustomerID are mandatory!
# if you need additional attributes from AD, just map them here.
# var, frontend, storage, shown (1=always,2=lite), required, storage-type, http-link, readonly
# [ 'UserSalutation', 'Title', 'title', 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 ],
[ 'UserEmail', 'Email', 'mail', 1, 1, 'var', '', 0 ],
[ 'UserCustomerID', 'CustomerID', 'mail', 0, 1, 'var', '', 0 ],
# [ 'UserCustomerIDs', 'CustomerIDs', 'second_customer_ids', 1, 0, 'var', '', 0 ],
[ 'UserPhone', 'Phone', 'telephoneNumber', 1, 0, 'var', '', 0 ],
# [ 'UserAddress', 'Address', 'postaladdress', 1, 0, 'var', '', 0 ],
# [ 'UserComment', 'Comment', 'description', 1, 0, 'var', '', 0 ],
[ 'UserMobile', 'Mobile', 'mobile', 1, 0, 'var', '', 0 ],
[ 'UserRoom', 'Room', 'physicalDeliveryOfficeName', 1, 0, 'var', '', 0 ],
],
};
# # cache time to live in sec. - cache any database queries
CacheTTL => 120,
Map => [
# note: Login, Email and CustomerID are mandatory!
# if you need additional attributes from AD, just map them here.
# var, frontend, storage, shown (1=always,2=lite), required, storage-type, http-link, readonly
# [ 'UserSalutation', 'Title', 'title', 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 ],
[ 'UserEmail', 'Email', 'mail', 1, 1, 'var', '', 0 ],
[ 'UserCustomerID', 'CustomerID', 'mail', 0, 1, 'var', '', 0 ],
# [ 'UserCustomerIDs', 'CustomerIDs', 'second_customer_ids', 1, 0, 'var', '', 0 ],
[ 'UserPhone', 'Phone', 'telephoneNumber', 1, 0, 'var', '', 0 ],
# [ 'UserAddress', 'Address', 'postaladdress', 1, 0, 'var', '', 0 ],
# [ 'UserComment', 'Comment', 'description', 1, 0, 'var', '', 0 ],
[ 'UserMobile', 'Mobile', 'mobile', 1, 0, 'var', '', 0 ],
[ 'UserRoom', 'Room', 'physicalDeliveryOfficeName', 1, 0, 'var', '', 0 ],
],
};
Best Regards
Chetan
OTRS 3.06
ITSM 3.1
MySQL
Windows 7 Ultimate
Chetan
OTRS 3.06
ITSM 3.1
MySQL
Windows 7 Ultimate
Re: Fill freetext with ldap field
Hello,
Thank's you but i allready did it.
Let me explain the problem with more details:
I need to make statistique with the detail of the state of ticket's origine.
this information is store in AD field "state/province" of the user who create the ticket.
With your parameters, i can see this information in the ticket but i can't make statistique with it because it's impossible to extract this information in statistique module or search ticket module.
That's why i would like to store "state/province" information in "freetext" and then use this field in search module to extract CSV doc with this information.
May be there is an other way but it's the simple's i find !
I hope you will found a solution to my problem...
Thank's you but i allready did it.
Let me explain the problem with more details:
I need to make statistique with the detail of the state of ticket's origine.
this information is store in AD field "state/province" of the user who create the ticket.
With your parameters, i can see this information in the ticket but i can't make statistique with it because it's impossible to extract this information in statistique module or search ticket module.
That's why i would like to store "state/province" information in "freetext" and then use this field in search module to extract CSV doc with this information.
May be there is an other way but it's the simple's i find !
I hope you will found a solution to my problem...
-
- Znuny advanced
- Posts: 149
- Joined: 25 Oct 2010, 10:02
- Znuny Version: 3.2
- Location: Bangalore, India
Re: Fill freetext with ldap field
Thanks for clarifying it. I didn't realize that you wanted it for stats/reports. I think that specifying Config values in {} may work. Lemme check if that works and revert.
Best Regards
Chetan
OTRS 3.06
ITSM 3.1
MySQL
Windows 7 Ultimate
Chetan
OTRS 3.06
ITSM 3.1
MySQL
Windows 7 Ultimate
-
- Znuny advanced
- Posts: 149
- Joined: 25 Oct 2010, 10:02
- Znuny Version: 3.2
- Location: Bangalore, India
Re: Fill freetext with ldap field
I tried with few methods however, I didn't get that output. How about accessing the ables via sql queries and putting them in the report format? If you are able to get displaying LDAP data in report/stats, lemme know too 

Best Regards
Chetan
OTRS 3.06
ITSM 3.1
MySQL
Windows 7 Ultimate
Chetan
OTRS 3.06
ITSM 3.1
MySQL
Windows 7 Ultimate