Results 1 to 5 of 5

Thread: Define default status, for search

  1. #1
    Tavares is offline Sugar Community Member
    Join Date
    Jan 2007
    Posts
    120

    Default Define default status, for search

    Hello!
    I'm working with sugar, for helpDesk purposes. By the nature of helpdesk whe receive a lot of cases from clients. So i changed my basic search to appear like a directory of queues, and made him searched by the status of "New". When i click in the button "Clean", it cleans the previous search and show's me all the cases that where created independent from the case status(all status...). In a week whe have received 4154 Cases!
    So...i wanted to define by default that when i clicked in "Clean" it would make me a new search, butt only for the Cases that are "New". Where can i make that change?

    Any help would be thankfull!

  2. #2
    ivolator's Avatar
    ivolator is offline Sugar Community Member
    Join Date
    Sep 2006
    Location
    Dagobah
    Posts
    98

    Default Re: Define default status, for search

    in Cases/ListView.php
    before
    PHP Code:
    $lv->setup($seedCase'include/ListView/ListViewGeneric.tpl'$where$params); 
    do this
    PHP Code:
    if(!empty($_REQUEST['clear_query']) && $_REQUEST['clear_query'] == 'true')
       
    $where .= '  cases.status = \''.$app_list_strings['case_status_dom']['New'].'\' '
    But why not just select Status = new from the advanced search if you want new ones?

  3. #3
    Tavares is offline Sugar Community Member
    Join Date
    Jan 2007
    Posts
    120

    Default Re: Define default status, for search

    Thanks for the reply!
    I added that code butt when i click on the clean button it appears with no record. When i refresh the cases ListView it appears all the records, idependently from the status of the Cases.


    I'm using sugar Version 4.5.1e (Build 1049).

    Thanks

  4. #4
    Tavares is offline Sugar Community Member
    Join Date
    Jan 2007
    Posts
    120

    Default Re: Define default status, for search

    Ok, it's done this way:
    In the Cases/metada/SearchFields.php in the satus array you just nee to add 'value'=>'New' and it will search by default for the New records.

  5. #5
    ivolator's Avatar
    ivolator is offline Sugar Community Member
    Join Date
    Sep 2006
    Location
    Dagobah
    Posts
    98

    Default Re: Define default status, for search

    Quote Originally Posted by Tavares
    Ok, it's done this way:
    In the Cases/metada/SearchFields.php in the satus array you just nee to add 'value'=>'New' and it will search by default for the New records.
    Good to know. Thanks!

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 3
    Last Post: 2006-10-18, 12:47 AM
  2. SugarCrm 4.0 Patch
    By mgamboa in forum General Discussion
    Replies: 0
    Last Post: 2005-12-21, 04:14 PM
  3. Replies: 0
    Last Post: 2005-09-24, 10:27 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
  •