Jump to content

workflow on imported jobs?


billster

Recommended Posts

Hello,

I want to create a workflow on imported jobs from SupportWorks. I have set the correct service inside of the config and enabled incidents in the service with a workflow set. But...imported jobs aren't running against the workflow and I cannot see them within running/failed or cancelled/completed in bpm tracking.

 

Link to comment
Share on other sites

6 minutes ago, Jim said:

Providing the config is set up correctly, does the import account have access to the service and support it? 

Hi Jim, yes it does and if I go into the service manually I can create a job.

Link to comment
Share on other sites

9 minutes ago, Jim said:

Providing the config is set up correctly, does the import account have access to the service and support it? 

I've also got this in the config...

"h_fk_serviceid": "27",

"DefaultService": "Historical Support Works Requests",

 

Link to comment
Share on other sites

There should be depending on the request types, that many catalog id's set up in your instance , so 1 for service request, 1 for Incidents, 1 for change and so on so forth

Link to comment
Share on other sites

19 minutes ago, Jim said:

we mapped to the catalog ID also which is what it looks like you are missing :) the workflow is connected the catalog item

image.png.ec3f479743d82bbeaf5288bd82b311ee.png

Thanks Jim. I added this with my catalog ID, and in Hornbill it sees it is set, however, the workflow when the job is imported never runs. And still cannot search in executed workflows.

image.png.9611d4f70b3d2ba370dec6da07130032.png

image.png.a56761a2778c3e01ca49385b34c27b64.png

image.png.3e4a8883e347e28c2d32e9e34807a787.png

 

 

Link to comment
Share on other sites

hmm, hard to say unless there's anything missing ref the defaults, here's how our incidents looked for our side, obviously your ID's, service and statement are going to differ

{
     "Description":"This object configures the importing of Incidents",
     "Import":true,
     "CallClass": "Incident",
     "SupportworksCallClass":"Incident",
     "DefaultTeam":"Service Desk",
     "DefaultPriority":"P4",
     "DefaultService":"IT Support",
     "SQLStatement":"SELECT opencall.callref,  logdatex, closedatex, cust_id, cust_name, itsm_title, owner, suppgroup, status, updatedb.updatetxt, priority, itsm_impact_level, itsm_urgency_level, withinfix, withinresp, bpm_workflow_id, probcode, fixcode, site FROM opencall, updatedb WHERE updatedb.callref = opencall.callref AND updatedb.udindex = 0 AND callclass = 'Incident' AND status < 15 AND status != 6 AND opencall.callref IN (0789852,0779402,0788229,0793492)",
     "CoreFieldMapping": {"h_catalog_id" = "111",
       "h_datelogged":"[logdatex]",
       "h_dateclosed":"[closedatex]",
       "h_summary":"[oldCallRef] - [itsm_title]",
       "h_description":"[updatetxt]",
       "h_external_ref_number":"[oldCallRef]",
       "h_fk_user_id":"[cust_id]",
       "h_status":"[status]",
       "h_request_language":"en-GB",
       "h_impact":"[itsm_impact_level]",
       "h_urgency":"[itsm_urgency_level]",
       "h_customer_type":"0",
       "h_container_id":"",
       "h_fk_serviceid":"",
       "h_resolution":"",
       "h_category_id":"[probcode]",
       "h_closure_category_id":"[fixcode]",
       "h_ownerid":"[owner]",
       "h_fk_team_id":"[suppgroup]",
       "h_fk_priorityid":"",
       "h_site":"[site]",
       "h_company_id":"",
       "h_company_name":"",
       "h_withinfix":"[withinfix]",
       "h_withinresponse":"[withinresp]",
       "h_custom_a":"",
       "h_custom_b":"",
       "h_custom_c":"",
       "h_custom_d":"",
       "h_custom_e":"",
       "h_custom_f":"",
       "h_custom_g":"",
       "h_custom_h":"",
       "h_custom_i":"",
       "h_custom_j":"",
       "h_custom_k":"",
       "h_custom_l":"",
       "h_custom_m":"",
       "h_custom_n":"",
       "h_custom_o":"",
       "h_custom_p":"",
       "h_custom_q":""
     },
     "AdditionalFieldMapping":{
       "h_firsttimefix":"",
       "h_custom_a":"Custom Data",
       "h_custom_b":"[itsm_title]",
       "h_custom_c":"[updatetxt]",
       "h_custom_d":"",
       "h_custom_e":"",
       "h_custom_f":"",
       "h_custom_g":"",
       "h_custom_h":"",
       "h_custom_i":"",
       "h_custom_j":"",
       "h_custom_k":"",
       "h_custom_l":"",
       "h_custom_m":"",
       "h_custom_n":"",
       "h_custom_o":"",
       "h_custom_p":"",
       "h_custom_q":"",
       "h_flgproblemfix":"",
       "h_fk_problemfixid":"",
       "h_flgfixisworkaround":"",
       "h_flg_fixisresolution":""
     }
   },

 

Link to comment
Share on other sites

1 hour ago, Jim said:

hmm, hard to say unless there's anything missing ref the defaults, here's how our incidents looked for our side, obviously your ID's, service and statement are going to differ

{
     "Description":"This object configures the importing of Incidents",
     "Import":true,
     "CallClass": "Incident",
     "SupportworksCallClass":"Incident",
     "DefaultTeam":"Service Desk",
     "DefaultPriority":"P4",
     "DefaultService":"IT Support",
     "SQLStatement":"SELECT opencall.callref,  logdatex, closedatex, cust_id, cust_name, itsm_title, owner, suppgroup, status, updatedb.updatetxt, priority, itsm_impact_level, itsm_urgency_level, withinfix, withinresp, bpm_workflow_id, probcode, fixcode, site FROM opencall, updatedb WHERE updatedb.callref = opencall.callref AND updatedb.udindex = 0 AND callclass = 'Incident' AND status < 15 AND status != 6 AND opencall.callref IN (0789852,0779402,0788229,0793492)",
     "CoreFieldMapping": {"h_catalog_id" = "111",
       "h_datelogged":"[logdatex]",
       "h_dateclosed":"[closedatex]",
       "h_summary":"[oldCallRef] - [itsm_title]",
       "h_description":"[updatetxt]",
       "h_external_ref_number":"[oldCallRef]",
       "h_fk_user_id":"[cust_id]",
       "h_status":"[status]",
       "h_request_language":"en-GB",
       "h_impact":"[itsm_impact_level]",
       "h_urgency":"[itsm_urgency_level]",
       "h_customer_type":"0",
       "h_container_id":"",
       "h_fk_serviceid":"",
       "h_resolution":"",
       "h_category_id":"[probcode]",
       "h_closure_category_id":"[fixcode]",
       "h_ownerid":"[owner]",
       "h_fk_team_id":"[suppgroup]",
       "h_fk_priorityid":"",
       "h_site":"[site]",
       "h_company_id":"",
       "h_company_name":"",
       "h_withinfix":"[withinfix]",
       "h_withinresponse":"[withinresp]",
       "h_custom_a":"",
       "h_custom_b":"",
       "h_custom_c":"",
       "h_custom_d":"",
       "h_custom_e":"",
       "h_custom_f":"",
       "h_custom_g":"",
       "h_custom_h":"",
       "h_custom_i":"",
       "h_custom_j":"",
       "h_custom_k":"",
       "h_custom_l":"",
       "h_custom_m":"",
       "h_custom_n":"",
       "h_custom_o":"",
       "h_custom_p":"",
       "h_custom_q":""
     },
     "AdditionalFieldMapping":{
       "h_firsttimefix":"",
       "h_custom_a":"Custom Data",
       "h_custom_b":"[itsm_title]",
       "h_custom_c":"[updatetxt]",
       "h_custom_d":"",
       "h_custom_e":"",
       "h_custom_f":"",
       "h_custom_g":"",
       "h_custom_h":"",
       "h_custom_i":"",
       "h_custom_j":"",
       "h_custom_k":"",
       "h_custom_l":"",
       "h_custom_m":"",
       "h_custom_n":"",
       "h_custom_o":"",
       "h_custom_p":"",
       "h_custom_q":"",
       "h_flgproblemfix":"",
       "h_fk_problemfixid":"",
       "h_flgfixisworkaround":"",
       "h_flg_fixisresolution":""
     }
   },

 

Thanks Jim. I tried to use this and alter for IDs/etc.......but still does nothing for the workflows :(

Link to comment
Share on other sites

1 hour ago, Jim said:

hmm, hard to say unless there's anything missing ref the defaults, here's how our incidents looked for our side, obviously your ID's, service and statement are going to differ

{
     "Description":"This object configures the importing of Incidents",
     "Import":true,
     "CallClass": "Incident",
     "SupportworksCallClass":"Incident",
     "DefaultTeam":"Service Desk",
     "DefaultPriority":"P4",
     "DefaultService":"IT Support",
     "SQLStatement":"SELECT opencall.callref,  logdatex, closedatex, cust_id, cust_name, itsm_title, owner, suppgroup, status, updatedb.updatetxt, priority, itsm_impact_level, itsm_urgency_level, withinfix, withinresp, bpm_workflow_id, probcode, fixcode, site FROM opencall, updatedb WHERE updatedb.callref = opencall.callref AND updatedb.udindex = 0 AND callclass = 'Incident' AND status < 15 AND status != 6 AND opencall.callref IN (0789852,0779402,0788229,0793492)",
     "CoreFieldMapping": {"h_catalog_id" = "111",
       "h_datelogged":"[logdatex]",
       "h_dateclosed":"[closedatex]",
       "h_summary":"[oldCallRef] - [itsm_title]",
       "h_description":"[updatetxt]",
       "h_external_ref_number":"[oldCallRef]",
       "h_fk_user_id":"[cust_id]",
       "h_status":"[status]",
       "h_request_language":"en-GB",
       "h_impact":"[itsm_impact_level]",
       "h_urgency":"[itsm_urgency_level]",
       "h_customer_type":"0",
       "h_container_id":"",
       "h_fk_serviceid":"",
       "h_resolution":"",
       "h_category_id":"[probcode]",
       "h_closure_category_id":"[fixcode]",
       "h_ownerid":"[owner]",
       "h_fk_team_id":"[suppgroup]",
       "h_fk_priorityid":"",
       "h_site":"[site]",
       "h_company_id":"",
       "h_company_name":"",
       "h_withinfix":"[withinfix]",
       "h_withinresponse":"[withinresp]",
       "h_custom_a":"",
       "h_custom_b":"",
       "h_custom_c":"",
       "h_custom_d":"",
       "h_custom_e":"",
       "h_custom_f":"",
       "h_custom_g":"",
       "h_custom_h":"",
       "h_custom_i":"",
       "h_custom_j":"",
       "h_custom_k":"",
       "h_custom_l":"",
       "h_custom_m":"",
       "h_custom_n":"",
       "h_custom_o":"",
       "h_custom_p":"",
       "h_custom_q":""
     },
     "AdditionalFieldMapping":{
       "h_firsttimefix":"",
       "h_custom_a":"Custom Data",
       "h_custom_b":"[itsm_title]",
       "h_custom_c":"[updatetxt]",
       "h_custom_d":"",
       "h_custom_e":"",
       "h_custom_f":"",
       "h_custom_g":"",
       "h_custom_h":"",
       "h_custom_i":"",
       "h_custom_j":"",
       "h_custom_k":"",
       "h_custom_l":"",
       "h_custom_m":"",
       "h_custom_n":"",
       "h_custom_o":"",
       "h_custom_p":"",
       "h_custom_q":"",
       "h_flgproblemfix":"",
       "h_fk_problemfixid":"",
       "h_flgfixisworkaround":"",
       "h_flg_fixisresolution":""
     }
   },

 

:( Seems because the tickets are closed then it won't allow it to run a bpm..... however, I need to add the customer names and analyst names on these closed tickets for ITSM reporting. is there a way to allow running a bpm on a resolved/closed request?

Link to comment
Share on other sites

Worflow* and catalog item, you would also need to modify the sql statement for each request type to separate closed from actual open ones and run 2 separate imports 

Link to comment
Share on other sites

20 hours ago, Jim said:

Create a new workforce for closed requests, import as open and close them as part of the process automatically 

When I try to import a closed job as open it errors when I open the job in HB. Failed to uppercase to lowercase conversion?

in the config, I set the status as "status.open" and made the date closed option as null.

There could be something I am missing to do, but cannot find it out.

Link to comment
Share on other sites

7 minutes ago, Jim said:

you would need to do it here image.png.3df17839ccb19cb8e612e1a576d7c9aa.png

perfect, I mapped the status as 1 and that's done it and now also allow BPM to run for the tickets.

Hmm.. I will have to have a play around with it and get it to put the correct customer and analyst information in.

I mapped the closed date to h_custom_d and got the epoh/unix time stamp. I have not yet tried or seen, but can you use the BPM to close an incident with a date in the past?

 

Link to comment
Share on other sites

I think date closed is a system set field, for the sake of historic data you could use custom fields though, I'm surprised at importing closed requests at all in all honesty. But you will have to bend the system a little to achieve what you need, I'm not too sure if Hornbill offer an option in the import that accommodates this scenario

Link to comment
Share on other sites

On 06/02/2024 at 15:44, Jim said:

I think date closed is a system set field, for the sake of historic data you could use custom fields though, I'm surprised at importing closed requests at all in all honesty. But you will have to bend the system a little to achieve what you need, I'm not too sure if Hornbill offer an option in the import that accommodates this scenario

Hi Jim,

yes-no way to change the date closed after the fact. however, in the reporting, I have unselected DATE CLOSED in favour of the custom mapped field imported from Support Works :) only thing I need to figure out is if I can use the Hornbill Utilities Cloud Automation to convert the date from EPOH/Unix but looks like it only converts already formatted dates like y-M-d h:i:s to d/m/y h:is

Thanks

Link to comment
Share on other sites

12 minutes ago, Jim said:

ORRRR now this is funny, do this actually as this defo works image.png.da1c1d8f4b5f56800801a9eafa7018b4.png

Yess!! this changes it from timestamp to sql date time :) you are a genius... tbh I was halfway there, I put the unix timestamp in starting timestamp!!

 

Grrr but for some reason I cannot format the date.....

I want to change this --- 2024-02-01 10:04:31 which is set up like yyyy-MM-dd HH:mm:ss

but if I try this format dd/MM/yyyy hh:mm it doesn't do anything LOL :( 

 

 

  • Haha 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...