Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-14364

Contact details are not appearing correctly.

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.4.4
    • Fix Version/s: 4.5
    • Component/s: CiviEvent
    • Labels:
    • Documentation Required?:
      None
    • Funding Source:
      Core Team Funds

      Description

      Hi team,

      Go to "Events" -> "Manage Events" -> (Select any event) -> Under "Configure" select "Location".
      Add any mobile number and select type as "Mobile".
      Now on "Event Info" page, it is showing "Phone" instead of "Mobile".
      I am new to CiviCRM and Smarty. I am sending a patch here. Here I am using 'if' statement. Below code is working fine for me.

      In civicrm/templates/CRM/Event/Page/EventInfo.tpl

      {if $location.phone.1.phone || $location.email.1.email}

      <div class="crm-section event_contact-section">
      <div class="label"><label>

      {ts}Contact{/ts}</label></div>
      <div class="content">
      {* loop on any phones and emails for this event *}
      {foreach from=$location.phone item=phone}
      {if $phone.phone}
      {if $phone.phone_type_id EQ 1}
      <span class="tel">{ts}

      Phone

      {/ts} {$phone.phone} {if $phone.phone_ext} {ts}ext.{/ts}

      {$phone.phone_ext}

      {/if} </span> <br />
      {/if} {if $phone.phone_type_id EQ 2}

      <span class="tel">

      {ts}Mobile{/ts} {$phone.phone} {if $phone.phone_ext} {ts}

      ext.

      {/ts} {$phone.phone_ext}{/if} </span> <br />
      {/if}
      {if $phone.phone_type_id EQ 3}
      <span class="tel">{ts}Fax{/ts}

       {$phone.phone}

      {if $phone.phone_ext} {ts}ext.{/ts} {$phone.phone_ext}{/if} </span> <br />
      {/if}
      {if $phone.phone_type_id EQ 4}
      <span class="tel">{ts}Pager{/ts} {$phone.phone} {if $phone.phone_ext}

       

      {ts}ext.{/ts} {$phone.phone_ext}{/if} </span> <br />
      {/if}
      {if $phone.phone_type_id EQ 5}
      <span class="tel">{ts}

      Voicemail

      {/ts} {$phone.phone} {if $phone.phone_ext} {ts}ext.{/ts}

      {$phone.phone_ext}

      {/if} </span> <br />
      {/if} {/if}
      {/foreach}

      {foreach from=$location.email item=email}
      {if $email.email}
      {ts}Email:{/ts} <span class="email"><a href="mailto:{$email.email}">{$email.email}</a></span>
      {/if} {/foreach}

      </div>
      <div class="clear"></div>
      </div>

      {/if}

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              gauthamas Gautham A.S
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 10 minutes
                10m
                Remaining:
                Remaining Estimate - 10 minutes
                10m
                Logged:
                Time Spent - Not Specified
                Not Specified