Hook on searchType

By Jason - September 25, 2013

Hi Djulia,

Are you looking to customize the "WHERE" clause when performing an advanced search in the CMS?  If so, you can use the list_where filter to alter the where clause.

Hope this helps

---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By Djulia - September 25, 2013 - edited: September 26, 2013

Hi Jason,

Yes, I had also thought of this approach. But, I obtain a warning message.
Field 'createdByUserNum' must be set to type 'none'

I also tried to modify the file of the schema, but that does not function.

Do you have another suggestion?

Thanks again!

Djulia

By Jason - September 26, 2013

Hi Djulia,

Can you provide some more information on exactly what you're trying to accomplish?  Is your code trying to change the field type in the schema? 

Let me know and we'll see what we can work out.

Thanks,

---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By Djulia - September 26, 2013 - edited: September 26, 2013

Hi Jason,

I would like to limit the list which is given with the use of "Full Name|createdBy.fullname(special case for searching by record owner)" in Admin > Section Editors > MyTable (Searching).

Currently, the list gives the totality of the editors/authors (250) who are in the accounts table.
But, we have only three (3) editors who have an authorized access.
That is not really ergonomic to select an editor/author (in the <createdByUserNum_match> select).

Do you have an idea?

Thanks again!

Djulia

By Jason - September 30, 2013

Hi Djulia,

Okay, I see.  There aren't a  lot of simple options.  One approach would be to have an admin drop down field that only showed authorized users using an advanced MySQL query.  This field could be set by a custom plugin when a new record is selected.  This field could now be used in the advanced search.  Outside of that, you would need to actually customize the core CMSB code in order to make a special case for this search field.

Hope this helps

---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

By Djulia - October 2, 2013

Hi Jason,

>This field could be set by a custom plugin...
I found a solution with list_postAdvancedSearch.

Thanks again!

Djulia