CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion (Moderator: Donald Lobo) »
  • get more data in contact search results
Pages: [1]

Author Topic: get more data in contact search results  (Read 852 times)

justageek

  • Guest
get more data in contact search results
October 20, 2009, 12:44:38 pm
Is it possible to tell civicrm to return more of the contact data fields in the search results?  Specifically, I'd like to customize the display based on contact_type, and it appears that what I have is a pre-formated image the represents the contact type, but I don't find the raw data field for use in an if statement in the template

Thanks,
Brian

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: get more data in contact search results
October 20, 2009, 01:01:42 pm
That's a very good idea.

Debug the template to see if by any change it is already in the remplate. If not, could you change the php and add it as an extra variable assigned to smarty ?
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

justageek

  • Guest
Re: get more data in contact search results
October 20, 2009, 02:19:21 pm
I thought about php option, but I have no idea where to start, I have just begun customizing civicrm, and it is daunting just finding the right script that passes the data to smarty, I have not yet found it.

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: get more data in contact search results
October 20, 2009, 02:43:00 pm
"easy": look at the source of the page, you have a CRM/XXX/yyy/blablabla.tpl in a html comment.

That's how you find the template in templates/CRM/XXX/yyy/blablabla.tpl, I'm assuming you know already.

The CRM/XXX/yyy/blablabla.php is the php. That might or might not include another php that inherit from another class that dynamically compose the name on the file to require and load the class (also dynamically generated)...

Ok, sometimes that's not that easy ;)

Don't have the source code, but it is under CRM/Contacts/Form/Search/XXX or not too far away. grep on the html blob that contains the image that is (unfortunately) automatically assigned to the template.

Let me know if you found it. Good luck

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Developer Discussion (Moderator: Donald Lobo) »
  • get more data in contact search results

This forum was archived on 2017-11-26.