Results 1 to 5 of 5

Thread: select field to export

  1. #1
    tamhd_vn88 is offline Member
    Join Date
    Jun 2010
    Posts
    18

    Default select field to export

    when i export account list, all field in account table will show. I only want show name,city, phone.(i want customize fields export).Please help me solving this problem
    thank!!


    when i click export

    the file .CSV will show all field


    I only want file .csv show some filed as that
    Last edited by tamhd_vn88; 2010-06-24 at 05:12 AM.

  2. #2
    davidboris is offline Sugar Community Member
    Join Date
    May 2010
    Posts
    1,113

    Default Re: select field to export

    Hi,

    Upgrade safe way -----

    I would suggest create your own button for export, and check the javascript function sugarListView.prototype.send_form( ) found in include/javascript/sugar_3.js

    Override the function in view.list.php

    You will get list of selected record ids and then you can use them in a new file which will do export like function and give you the output as you desire.

    If you want to go for upgrade safe way ----- (not preferable)
    modify the function create_export_query found in MODULE/MODULE.php
    Thumbs up.

    Skype ID - david__boris

    SugarForge Projects:

    WYSIWYG now in studio!(Version 1.1 is out now!)

    Sugar Feeds on your personalized home pages like iGoogle, My Yahoo!, etc.

    Fab Tools! > Dashlet Not Followed Opportunities for past six Months

  3. #3
    kingjatin is offline Senior Member
    Join Date
    May 2010
    Location
    India
    Posts
    35

    Thumbs up Re: select field to export

    you can refer to this thread and it will solve your queries also it has the exact code written with only you need to modify the database name and values according to you.

    Hope this helps.

    Cheers
    Cheers !!

  4. #4
    tamhd_vn88 is offline Member
    Join Date
    Jun 2010
    Posts
    18

    Default Re: select field to export

    Quote Originally Posted by kingjatin View Post
    you can refer to this thread and it will solve your queries also it has the exact code written with only you need to modify the database name and values according to you.

    Hope this helps.

    Cheers
    thank David and kingjatin, your advise helped me solving my problem. Thank so much!!

  5. #5
    kingjatin is offline Senior Member
    Join Date
    May 2010
    Location
    India
    Posts
    35

    Default Re: select field to export

    Quote Originally Posted by davidboris View Post
    Hi,

    Upgrade safe way -----

    I would suggest create your own button for export, and check the javascript function sugarListView.prototype.send_form( ) found in include/javascript/sugar_3.js

    Override the function in view.list.php

    You will get list of selected record ids and then you can use them in a new file which will do export like function and give you the output as you desire.

    If you want to go for upgrade safe way ----- (not preferable)
    modify the function create_export_query found in MODULE/MODULE.php
    Hi David,

    Can you please elaborate little more as exactly what you are referring to.

    1) How can we create a button? I mean in which file ? is that the file that is included in cache folder or we need to create a new field via module builder and then call the function on that button.

    2) the editing of the sugarListView.prototype.send_form( ), so where can we write the custom sql queries? Its already very complex.

    The below is the function that I found.:

    sugarListView.prototype.send_form=function(select, currentModule,action,no_record_txt,action_module,r eturn_info){if(document.MassUpdate.select_entire_l ist.value==1){if(sugarListView.get_checks_count()< 1){alert(no_record_txt);return false;}

    It is very interesting to know as this is a upgrade safe manner..

    Thanks
    Last edited by kingjatin; 2010-06-24 at 08:06 AM. Reason: to provide more information
    Cheers !!

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. How to add field with SELECT button?
    By jim.thornton in forum Developer Help
    Replies: 1
    Last Post: 2009-02-22, 06:05 AM
  2. select and export stopped working
    By michamamo2 in forum Help
    Replies: 3
    Last Post: 2009-01-19, 12:19 PM
  3. Select filed and export issue
    By piccirm2 in forum Help
    Replies: 1
    Last Post: 2008-05-09, 08:29 AM
  4. Select Field Issue
    By cagatay in forum Help
    Replies: 3
    Last Post: 2008-03-23, 02:44 AM
  5. Multi select field
    By crazybeardedman in forum Help
    Replies: 1
    Last Post: 2008-02-14, 07:49 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
  •