Jump to content


Start grid with search/Filter box open

search filter open

  • Please log in to reply
6 replies to this topic

#1 fdias

fdias

    grocery CRUD Addict

  • Members
  • PipPipPip
  • 93 posts

Posted 15 June 2012 - 01:32 AM

I replied this to another thread and I thought I would post it here as an extra code for a small feature in case someone else is interested.

If you wish to have the search/filter box open when you start the grid so the user won't have to click on the magnifier button, then all you need to do is have this code on the head section of your view:

<script type="text/javascript">
$(document).ready(function() {
  $('#quickSearchButton').trigger('click');
});
</script>

I hope this helps someone else.

Cheers.

#2 noskov

noskov

    grocery CRUD Guru

  • Advanced Member
  • PipPipPip
  • 175 posts
  • LocationKiev

Posted 15 June 2012 - 06:41 AM

Hi! Thank you for sharing. In one of these days I thought about open search box and you are just in time. :)

#3 waqar

waqar

    Member

  • Members
  • PipPip
  • 10 posts

Posted 11 September 2012 - 06:44 PM

Any ideas/thoughts on how to make the search filter for a scenario like:

Search Orders FROM DATE, TO DATE ?

#4 HellKnight

HellKnight

    Newbie

  • Members
  • Pip
  • 8 posts
  • LocationUA, Zaporozhye

Posted 21 September 2012 - 10:20 AM

Any ideas/thoughts on how to make the search filter for a scenario like:

Search Orders FROM DATE, TO DATE ?


Has anyone found a solution to this problem?

#5 victor

victor

    grocery CRUD Hero

  • Advanced Member
  • PipPipPip
  • 967 posts
  • LocationMinsk

Posted 22 September 2012 - 07:50 PM

Has anyone found a solution to this problem?

use the method "where".

#6 HellKnight

HellKnight

    Newbie

  • Members
  • Pip
  • 8 posts
  • LocationUA, Zaporozhye

Posted 24 September 2012 - 06:41 AM

Ok

#7 kanted

kanted

    Member

  • Members
  • PipPip
  • 19 posts

Posted 04 December 2015 - 05:22 AM

I have copied the above code in the header section of my grocery view php file. when i click search it find the records as usual. it does not open the edit page

please find the view header and please let me know where i am wrong

 

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
<?php 
foreach($css_files as $file): ?>


<link type="text/css" rel="stylesheet" href="<?php echo $file; ?>" />
<?php endforeach; ?>
<?php foreach($js_files as $file): ?>
<script src="<?php echo $file; ?>"></script>
<script type="text/javascript">
    $(document).ready(function() {
    $('#quickSearchButton').trigger('click');
});
</script>


<?php endforeach; ?>
<style type='text/css'>
body
{
font-family: Arial;
font-size: 14px;
}
a {
    color: blue;
    text-decoration: none;
    font-size: 14px;
}
a:hover
{
text-decoration: underline;
}
</style>
</head>






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users