Ticketing system auto populate
We are about to start using the help desk system on Kbox. There has been some request for modifications on what happens when you enter a ticket. In our "add a ticket" screen there is a spot for "site" & "department". Both of the fields are populated from the user database in kbox using this string in the custom fields (query: select distinct (CUSTOM_2) from USER). This populates the drop down menu for user selection. But what I would like to happen is have both the site and department field be automatically set when the submitter's name is selected.
Is there a way to add a query to do this?
thanks.
Is there a way to add a query to do this?
thanks.
0 Comments
[ + ] Show comments
Answers (6)
Please log in to answer
Posted by:
jverbosk
13 years ago
I played with this along with GillySpy's tip and came up with the following. Working fine here, hopefully this can save someone else some time.
John
______________________________
I have the Department field filled out in ADUC (Organization tab - Department field) and the KBOX pulls this via LDAP import. In the LDAP import setup, the Department is set to appear in the Custom 2 user field (in the User Contact Info popup, next to Submitter). For the tickets, I have the Department field set as Custom_4 in the GUI (which is CUSTOM_FIELD_VALUE3 in SQL). This is all done so I can run a custom report on tickets (querying this field) for the Sales users (as instructed by our Sales VP), but I suppose it's also useful to have the departments listed on the tickets without resorting to the popup.
______________________________
Title:
Autopopulate Department Field
Order:
10
Notes:
Automatically populates department field (custom field 4 in UI, custom field 3 in SQL) with department name. This is to help facilitate creation of weekly Sales reports.
Frequency:
on Ticket Save
Select Query:
SELECT HD_TICKET.ID AS ID FROM HD_TICKET
JOIN USER S ON (S.ID = HD_TICKET.SUBMITTER_ID)
WHERE HD_TICKET.SUBMITTER_ID <>0
X Run an update query, using the results from the one above
Update Query:
UPDATE HD_TICKET T
JOIN USER S ON (S.ID = T.SUBMITTER_ID)
SET T.CUSTOM_FIELD_VALUE3 = S.CUSTOM_2 WHERE T.ID=<TICKET_IDS>
John
______________________________
I have the Department field filled out in ADUC (Organization tab - Department field) and the KBOX pulls this via LDAP import. In the LDAP import setup, the Department is set to appear in the Custom 2 user field (in the User Contact Info popup, next to Submitter). For the tickets, I have the Department field set as Custom_4 in the GUI (which is CUSTOM_FIELD_VALUE3 in SQL). This is all done so I can run a custom report on tickets (querying this field) for the Sales users (as instructed by our Sales VP), but I suppose it's also useful to have the departments listed on the tickets without resorting to the popup.
______________________________
Title:
Autopopulate Department Field
Order:
10
Notes:
Automatically populates department field (custom field 4 in UI, custom field 3 in SQL) with department name. This is to help facilitate creation of weekly Sales reports.
Frequency:
on Ticket Save
Select Query:
SELECT HD_TICKET.ID AS ID FROM HD_TICKET
JOIN USER S ON (S.ID = HD_TICKET.SUBMITTER_ID)
WHERE HD_TICKET.SUBMITTER_ID <>0
X Run an update query, using the results from the one above
Update Query:
UPDATE HD_TICKET T
JOIN USER S ON (S.ID = T.SUBMITTER_ID)
SET T.CUSTOM_FIELD_VALUE3 = S.CUSTOM_2 WHERE T.ID=<TICKET_IDS>
Comments:
-
Thanks john.Thats exactly what I was looking for. - imranqamar34 12 years ago
Posted by:
GillySpy
15 years ago
You would need to write a ticket rule to do this.
It would be an on ticket save rule. The query would be a join of the ticket and the submitter. The update would modify the custom field in the ticket to be equal to the appropriate custom field of the user
Keep in mind that HD_TICKET.custom_field_value0 is the field that stores the values of "custom 1" in the ticket configuration but USER.CUSTOM_1 stores the values of "custom 1" in the user record.
It would be an on ticket save rule. The query would be a join of the ticket and the submitter. The update would modify the custom field in the ticket to be equal to the appropriate custom field of the user
Keep in mind that HD_TICKET.custom_field_value0 is the field that stores the values of "custom 1" in the ticket configuration but USER.CUSTOM_1 stores the values of "custom 1" in the user record.
Posted by:
airwolf
15 years ago
The short answer to your question is no, not actively anyway. The KBOX can't use nested values (except for categories) and it does not have the ability to dynamically populate fields based on other field choices. However, you can create custom ticket rules, as Gerald has suggested. You'd simply need to configure a custom rule to set the site and department when the submitter's name is equal to whomever you are setting up the rule for. If it's on ticket save, then it will be instantaneous when the ticket is saved - the department and site will automatically appear when the submitter or an owner looks at the ticket.
Posted by:
kdasanmartino
15 years ago
Posted by:
airwolf
15 years ago
Not necessarily. That would be one way to do it, but if you use LDAP then you can pull custom AD fields and set the ticket rule up to automatically find and set the site and department when the ticket is saved with a user - assuming you store site and department data somewhere in your AD structure (if you're using AD).
Posted by:
kdasanmartino
15 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.