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) »
  • Some views issues: what if I need multiple types of 'phone numbers' ?
Pages: [1]

Author Topic: Some views issues: what if I need multiple types of 'phone numbers' ?  (Read 1696 times)

Danny_Joris

  • Guest
Some views issues: what if I need multiple types of 'phone numbers' ?
August 23, 2010, 06:51:21 am
Hello,

I was looking if it was possible with views to show for example only the following fields: full address, phone, mobile, fax: all of the 'work' type. Right now with the Location type filter it shows the right address, but not the phone number (it still shows the 'home' number'). Therefore I can't use these results.

I also feel that I should be able to call the fields directly through the fields section and that I shouldn't have to select one general field (for example: 'phone number') and then filter them. Right now there is for example one field for 'phone number'. What If I need multiple phone numbers, all of different type? (home, work, billing, etc..) Or different types of phone numbers? (phone, mobile, fax..) I can't just use one filter to show all that.

I also noticed with views that my result is only one contact, but this result shows up 8 times. (one time for every field?) I can reduce it by setting the 'distinct' option, but I feel that I shouldn't even have to use it in the first place.

Screenshot of my view: http://dannyjoris.be/files/fora/civicrm-views.png

Thanks in advance!
Cheers,
Danny


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: Some views issues: what if I need multiple types of 'phone numbers' ?
August 23, 2010, 07:04:20 am

please provide a patch to the views integration code to do the needful and/or hire a developer who can help you improve the views integration. that will help you, us and the community a whole lot and will be highly appreciated

as a free and open source project (FOSS), we do rely on community contributions to help improve the product

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

Danny_Joris

  • Guest
Re: Some views issues: what if I need multiple types of 'phone numbers' ?
August 29, 2010, 08:37:36 pm
Thanks for confirming the issue.

Unfortunately I'm not in a position right now to be able to contribute by code nor financially. I don't know the code enough - how many days (very roughly) would it take to add this functionality?

Right now I kind of worked around this issue by using mainly custom data fields which I can call with views directly. I'm not using the built-in fields because of this.

Cheers,
Danny

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: Some views issues: what if I need multiple types of 'phone numbers' ?
August 29, 2010, 08:46:34 pm

i suspect this is between 1-3 days of work. this will involve figuring out how exactly to pass the information to views and the various options we have available

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

jsimonis

  • I post frequently
  • ***
  • Posts: 316
  • Karma: 4
    • Forward Support, Inc.
  • CiviCRM version: 4.4-4.5
  • CMS version: Drupal 7
  • MySQL version: 5.5.37-cll
  • PHP version: 5.3.29
Re: Some views issues: what if I need multiple types of 'phone numbers' ?
February 12, 2011, 07:53:23 pm
It looks like what is needed is a "group by" type option.

Right now if you have multiple phone numbers for a person, you get that person listed in the view as many times as they have phone numbers. So then you need to turn on "distinct".

When you turn on distinct you lose all of the other phone numbers except the first one.

I guess what I'll do in the meantime is add a custom field for the fax number instead of using a phone field since I can't show it and the work number.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using Drupal Modules (Moderator: Donald Lobo) »
  • Some views issues: what if I need multiple types of 'phone numbers' ?

This forum was archived on 2017-11-26.