CRM-6118 Drupal views integration ContactID inserts commas into number

    Details

      Description

      With views integrations creating a view of contacts, the Replacement Pattern "[id] == CiviCRM Contacts: Contact ID" inserts commas when a contact_id is greater than 999

      ie

      1,023

      etc.

      If you are building a URL from this then you will not be pleased. ie:

      <a href="/civicrm/blah/something?cid=[id]">Do something to this contact</a>

        Attachments

          Activity

          [CRM-6118] Drupal views integration ContactID inserts commas into number
          Donald A. Lobo added a comment -


          Would be great if you can investigate and submit a patch

          Chris Muenzer added a comment -

          I am having this issue as well, but I can't seem to fine where in the code the replacement pattern is being generated. Can anyone point me in the right direction?

          Chris Muenzer added a comment -

          This issue can be fixed by changing the civicrm.views.inc file. For any field that you want to remove the thousands separator replace:

          'handler' => 'views_handler_field_numeric'

          with:

          'handler' => 'views_handler_field'

          Jim Taylor added a comment -

          Isn't this just a configuration issue, can't you simply leave the Thousands Separator field blank?

          Helen Bergin added a comment -

          I was hoping to apply the workaround suggested by Chris to one instance of a multi-site installation of CiviCRM.

          I've tried the workaround on a single site already, and that picked up the changes to the civicrm.views.inc file.

          I tried applying them to a custom copy of the file on one of the multi-site instances, but don't think Civi is looking for it, as there only seems to be options to set custom directory paths for php or template files.

          Is there a recommended way to tell civi to look for custom versions of .inc files also?

            People

            • Assignee:
              Jim Taylor
              Reporter:
              Tom Morton

              Dates

              • Created:
                Updated:
                Resolved: