Results 1 to 5 of 5

Thread: Hi all help needed please

  1. #1
    kobus is offline Member
    Join Date
    Jul 2009
    Posts
    5

    Question Hi all help needed please

    Good Day

    i am quite a newby at sugar and would like to know if anyone could assist me with the following:

    I need to get my foreign key set as a mandatory field in my tab have customised.

    Regards,

  2. #2
    kinshibuya's Avatar
    kinshibuya is offline A Sugar Hero
    Join Date
    Jul 2008
    Location
    brasil
    Posts
    521

    Default Re: Hi all help needed please

    what? i didn't understand could you be more specific?
    Priscila Kin Yamamoto Joranhezon
    Phone: +55 61 32010000
    priscila.joranhezon@nct.com.br
    NCT Informática Ltda

  3. #3
    kobus is offline Member
    Join Date
    Jul 2009
    Posts
    5

    Default Re: Hi all help needed please

    Hi we did setup a new database for our project and now has have several foreign keys in the database we need to set as mandatory fields in sugar. However when we ad the fields in the module builder it just appear as a small thin box with no description of the name whatsoever..... i found this advice on the forum though, think it would suffice?


    if($field == "billing_address_city" || $field == "billing_address_state")
    {
    $this->script .= "addToValidate('".$this->formname."', '".$prefix.$field."', '".$type . "', true,'". $this->stripEndColon(translate($displayName,$this->sugarbean->module_dir)) . "' );\n";
    }else{
    $this->script .= "addToValidate('".$this->formname."', '".$prefix.$field."', '".$type . "', $required,'". $this->stripEndColon(translate($displayName,$this->sugarbean->module_dir)) . "' );\n";
    }

  4. #4
    andopes's Avatar
    andopes is offline A Sugar Hero | Help Forum Moderator
    Join Date
    Jul 2006
    Location
    São Paulo - Brazil
    Posts
    8,335

    Default Re: Hi all help needed please

    You just need to add the attribute

    PHP Code:
    'displayParams' => array(
      
    'required' => true,
    ), 
    at field defs in editviewdefs.php

    Cheers
    André Lopes
    DevToolKit / Project of the Month - June 2009
    Lampada Global Services- Open Source Solutions
    Avenida Ipiranga, 318
    Bloco B - CJ 1602
    São Paulo, SP 01046-010
    Brazil
    Office: +55 11 3237-3110
    Mobile: +55 11 7636-5859
    e-mail: andre@lampadaglobal.com

    Lampada Global delivers offshore software development and support services to customers around the world.
    Lampada is proud to be a SugarCRM Gold Partner, revolutionizing Customer Relationship Management.

    I DO NOT answer questions through PM and Email. If you need some help post your question into SugarForum.

  5. #5
    kobus is offline Member
    Join Date
    Jul 2009
    Posts
    5

    Default Re: Hi all help needed please

    Thanks so much!!!!!!

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Help needed in 5.2
    By dinudanial in forum Developer Help
    Replies: 3
    Last Post: 2009-01-23, 11:55 AM
  2. Help Needed
    By Miceal in forum Help
    Replies: 1
    Last Post: 2007-08-20, 08:58 PM
  3. yui help needed
    By kbrill in forum Developer Help
    Replies: 4
    Last Post: 2006-11-30, 02:56 AM
  4. some help needed
    By macklein in forum Developer Help
    Replies: 6
    Last Post: 2006-04-18, 07:51 PM
  5. Help needed.
    By bizzop in forum Help
    Replies: 3
    Last Post: 2006-02-08, 11:34 AM

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
  •