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) »
  • Support »
  • Using CiviCRM »
  • Using Drupal Modules (Moderator: Donald Lobo) »
  • CiviCRM CCK Contact Reference only shows 10 contacts
Pages: [1]

Author Topic: CiviCRM CCK Contact Reference only shows 10 contacts  (Read 1040 times)

JmsCrk

  • I’m new here
  • *
  • Posts: 2
  • Karma: 0
  • CiviCRM version: 3.4
  • CMS version: Drupal 6
  • MySQL version: 5.1
  • PHP version: 5.2
CiviCRM CCK Contact Reference only shows 10 contacts
July 26, 2011, 07:34:55 pm
I have a CiviCRM contact reference field on a Drupal content type, I can then use the reference to pull some contact info and display it in the template file. Nice.

It's working but on the drupal node edit screen the contact reference field dropdown only shows around 10 contacts (out of hundreds) and even the ten aren't in alphabetical order.

I can't find settings for this - are there settings? I'd like to get *all* CiviCRM contacts available in the dropdown and have them displayed in alpha order.

Help would be GREATLY appreciated!

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: CiviCRM CCK Contact Reference only shows 10 contacts
July 27, 2011, 12:25:02 am

maybe try using this hook:

http://wiki.civicrm.org/confluence/display/CRMDOC32/CiviCRM+hook+specification#CiviCRMhookspecification-hookcivicrmcontactListQuery

however not sure if the jQuery widget used has a limit on number of entries it displays

Note that in general displaying ALL contacts will not scale for any reasonably sized db :)

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

JmsCrk

  • I’m new here
  • *
  • Posts: 2
  • Karma: 0
  • CiviCRM version: 3.4
  • CMS version: Drupal 6
  • MySQL version: 5.1
  • PHP version: 5.2
Re: CiviCRM CCK Contact Reference only shows 10 contacts
August 03, 2011, 06:13:15 pm
Thanks Donald, I've changed it to an auto-complete field as there were several hundred entries and that works even without the hook changes.

However I'm still going to use the hook to limit selection to only 'organization' members.

Thanks for the help!

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Drupal Modules (Moderator: Donald Lobo) »
  • CiviCRM CCK Contact Reference only shows 10 contacts

This forum was archived on 2017-11-26.