Results 1 to 5 of 5

Thread: "Fields" Questions

  1. #1
    mjchin is offline Member
    Join Date
    Jun 2009
    Posts
    9

    Question "Fields" Questions

    I have to build / modify a few modules. What I've been doing is adding newfields, then applying them in the layout. I realize I have a few similar fields that needs to be applied onto other modules.

    My questions are:
    • is there a way to reuse these fields in different modules or do I need to create them seperately?
    • Is there a way I can I create the fields and their properties (field type, mask, display name) in a text file and upload them?
    • Is there a way to run a report of what my fields are, for example a data diictionary?
    • when laying out a module, is there a way to have three fields per row?
    • In the accounts module, I notice billing address / shipping address is one panel but in the layout, its one field. how can I create this type of address field for another use? for example, instead of creating separate address, city, st, zip fields, I'd like to create similar "one panel" addresses and apply it for other addresses, e.g., mothers, fathers, emergency contact, etc.


    Thanks in advance

  2. #2
    crmbalah is offline A Prolific Poster
    Join Date
    Mar 2009
    Location
    chennai
    Posts
    418

    Default Re: "Fields" Questions

    HI
    1. you should be create every module. you can't use the other module fields.
    2. include/SugarFields/Fields/Address/EditView.tpl use this and create new address related fields.

  3. #3
    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: "Fields" Questions

    Quote Originally Posted by mjchin View Post
    I have to build / modify a few modules. What I've been doing is adding newfields, then applying them in the layout. I realize I have a few similar fields that needs to be applied onto other modules.

    My questions are:
    • is there a way to reuse these fields in different modules or do I need to create them seperately?
    • Is there a way I can I create the fields and their properties (field type, mask, display name) in a text file and upload them?
    • Is there a way to run a report of what my fields are, for example a data diictionary?
    • when laying out a module, is there a way to have three fields per row?
    • In the accounts module, I notice billing address / shipping address is one panel but in the layout, its one field. how can I create this type of address field for another use? for example, instead of creating separate address, city, st, zip fields, I'd like to create similar "one panel" addresses and apply it for other addresses, e.g., mothers, fathers, emergency contact, etc.


    Thanks in advance
    Sugar enable you to create new field templates.
    Just take a look at the folder include/SugarFields/Fields folder.
    Every folder has all definitions for each field: their templates (EditView, ListView, DetailView) and logic (php class).
    You can create new ones and add the attribute

    PHP Code:
    'type' => 'new_field_template'
    On field defs at metadata layout (detailviewdefs.php, editviewdefs.php and listviewdefs.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.

  4. #4
    mjchin is offline Member
    Join Date
    Jun 2009
    Posts
    9

    Default Re: "Fields" Questions

    Thanks Andopes, I'll look at that, field templates. I'm completely new to Sugar and therfore please excuse my seemingly "simple" questions

    Reusing or at least copying fields from another module would be simpler so I dont have to create similar feilds.

    For example under the Accounts module, I may have similar name and address fields that appear under the Contacts module.

  5. #5
    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: "Fields" Questions

    Quote Originally Posted by mjchin View Post
    Thanks Andopes, I'll look at that, field templates. I'm completely new to Sugar and therfore please excuse my seemingly "simple" questions

    Reusing or at least copying fields from another module would be simpler so I dont have to create similar feilds.

    For example under the Accounts module, I may have similar name and address fields that appear under the Contacts module.
    Hi mjchin

    Yes, you can copy a field from a module to another one, but sometimes you may want to customize a field the way you need to accomplish a non-upgrade safe customization. At that scene you may consider creating a new field template which can itself extends an existing field template and override just the enough to accomplish your needs.

    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.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Adding "Account" info in the "Add invitees" search result list
    By george_bbch in forum General Discussion
    Replies: 1
    Last Post: 2011-09-29, 04:37 PM
  2. Replies: 4
    Last Post: 2009-12-18, 05:52 PM
  3. Replies: 0
    Last Post: 2007-07-27, 08:13 AM
  4. Replies: 2
    Last Post: 2006-12-15, 03:00 PM
  5. Questions after following "idiots guide"
    By Dendarii in forum Help
    Replies: 0
    Last Post: 2006-03-25, 03:21 AM

Tags for this Thread

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
  •