Service Manager Task Filters  Topic is solved

Discussions relating to Jiwa 7 plugin development, and the Jiwa 7 API.

Service Manager Task Filters

Postby NinaT » Thu Apr 15, 2021 4:34 pm

Hi,

It it possible to add custom task filters in Service Manager, I am trying to filter tasks that have not been retired, my filter works fine whilst I am still in the SM jobs form however as soon as I close the form and try to re-open I get a multi-part identifier error. I have seen this error before in Manufacturing which was logged as an issue but not sure if the issue is the problem.

I have attached an image of the filters that I have created and the subsequent error message, all done in v7.2.0 SR6.


2021-04-15_15-28-15.png
Filters


2021-04-15_15-30-33.png
Error
2021-04-15_15-30-33.png (21.35 KiB) Viewed 8987 times


Thanks
Nina
NinaT
I'm new here
I'm new here
 
Posts: 7
Joined: Tue Mar 16, 2021 3:54 pm
Topics Solved: 0

Re: Service Manager Task Filters  Topic is solved

Postby Scott.Pearce » Fri Apr 16, 2021 11:51 am

This is because when a form loads, the "BaseFindSQLQuery" is used to read the record - and filters are applied to this for the read. The "BaseFindSQLQuery" is constructed using the objects "RecIDFieldName" and "TableName" properties (properties which every business logic object must have). Therefore the BaseFindSQLQuery for service manager is "SELECT TOP 1 RecID FROM SM_Jobs". The SM_Tasks table is not involved, therefore the filter when appended causes a failure.

I've created a plugin that modifies the BaseFindSQLQuery for service manager, such that the SM_Tasks table is linked in, meaning filters referencing SM_Tasks will not break the initial readrecord:

Scott Pearce
Senior Analyst/Programmer
Jiwa Financials
User avatar
Scott.Pearce
Senpai
Senpai
 
Posts: 765
Joined: Tue Feb 12, 2008 11:27 am
Location: New South Wales, Australia
Topics Solved: 230

Re: Service Manager Task Filters

Postby NinaT » Fri Apr 16, 2021 1:02 pm

Thanks Scott,
That works a treat, much appreciated.
Nina
NinaT
I'm new here
I'm new here
 
Posts: 7
Joined: Tue Mar 16, 2021 3:54 pm
Topics Solved: 0


Return to Technical and or Programming

Who is online

Users browsing this forum: No registered users and 1 guest