Results 1 to 6 of 6

Thread: Inherite Numbers when Creating a Call

  1. #1
    chrislynch8's Avatar
    chrislynch8 is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Cork, Ireland
    Posts
    747

    Default Inherite Numbers when Creating a Call

    Hi,

    When i create a call in my CRMI want it to inherite the Phone Numbers (Work, Home, Mobile) from the realted Account or Contacts.

    So If I create a Call under an Account it will inherite it phone numbers and if I create it under contacts it will inherite the contacts numbers.

    I know I have to edit the the view.edit.php for the Calls module.

    I try to $_REQUEST['parent_type'] to see if its parent is an Account or a Contact, then depending on which it is I will Select (three numbers) from accounts Where id = parent_id and then pass the numbers to the call record

    Rgds
    Chris
    Linkedin Profile:Chris Lynch

    FDC IT Solutions
    FDC House
    Wellington Road
    Cork
    Ireland

  2. #2
    josh.sweeney is offline Sugar Community Member
    Join Date
    Apr 2008
    Location
    Ga
    Posts
    339

    Default Re: Inherite Numbers when Creating a Call

    Although I have never thought of this before I am somewhat surprised that I haven't seen this request in the past. There is no call number field in the calls module.

    One option is to change the data that is returned from the popup selection to include the phone number/s and then populate the number field.

  3. #3
    chrislynch8's Avatar
    chrislynch8 is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Cork, Ireland
    Posts
    747

    Default Re: Inherite Numbers when Creating a Call

    I created three phone number fields for Calls and I now want to inherite the numbers inthe parent record Account or Contact.

    I have the following code to detect if the parent is an Account or Contact

    PHP Code:
    if (empty($this->ev->focus->id))

       if (!empty(
    $this->ev->fieldDefs['contact_id'}{'value']))
       {
         echo 
    "Parent Contact";
         
    ##code here to select phone numbers from contact
        
    }

       if (!empty(
    $this->ev->fieldDefs['account_id'}{'value']))
       {
         echo 
    "Parent Account";
         
    ##code here to select phone numbers from account
        

    This is code that is already in the view.edit.php file from Sugar.

    I've used this in another custom module to pull in info depending on whether the parent is an Account or Contact and it works, but when creating a call under and Account or Contact it doesn't seem to detect what the parent is.

    Rgds
    Chris
    Linkedin Profile:Chris Lynch

    FDC IT Solutions
    FDC House
    Wellington Road
    Cork
    Ireland

  4. #4
    chrislynch8's Avatar
    chrislynch8 is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Cork, Ireland
    Posts
    747

    Default Re: Inherite Numbers when Creating a Call

    Hi,

    I've been looking at this a bit more. I am able to request the parent ID and the parent type and I can say when its an Accounts then use a query to pull the numbers from the accounts_cstm field..

    But the problem here is that when I create a call under a contact and use the request parent_id and parent type if return that of the Account the contact is a member of, and if the contact has no account it will not return an ID but is will return the parent_type as an Account.

    I notice that when I press the schedule call under an Account the relate field is populated with the Account but for a contact with no accoun the relate to field is not populated by the contact as I expect it should and if the contact has an Account the relate is set as the contacts Account and not the contact -IS THIS A BUG??

    Rgds
    Chris
    Linkedin Profile:Chris Lynch

    FDC IT Solutions
    FDC House
    Wellington Road
    Cork
    Ireland

  5. #5
    chrislynch8's Avatar
    chrislynch8 is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Cork, Ireland
    Posts
    747

    Default Re: Inherite Numbers when Creating a Call

    I have achieved this with a Logic Hook.
    Linkedin Profile:Chris Lynch

    FDC IT Solutions
    FDC House
    Wellington Road
    Cork
    Ireland

  6. #6
    shamimwilson is offline Sugar Community Member
    Join Date
    Mar 2009
    Location
    Banglore India
    Posts
    235

    Default Re: Inherite Numbers when Creating a Call

    Hi friend,

    If you don't mind can you please post your solution here.
    I am also looking for something similar.

    Thanks,

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Best Practice: Creating & tracking a call list
    By petercrowe in forum Marketing/Campaign Management
    Replies: 3
    Last Post: 2010-06-04, 04:36 PM
  2. Replies: 5
    Last Post: 2008-04-10, 05:45 PM
  3. Creating a workable cold call list
    By slippy62 in forum Help
    Replies: 18
    Last Post: 2007-09-20, 02:42 AM
  4. Replies: 2
    Last Post: 2007-08-02, 01:05 PM
  5. Creating a meeting from a call
    By stevec in forum Developer Help
    Replies: 0
    Last Post: 2007-02-15, 02:10 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •