Commit | Line | Data |
---|---|---|
6a488035 TO |
1 | {* |
2 | +--------------------------------------------------------------------+ | |
2c4c49ca | 3 | | CiviCRM version 4.7 | |
6a488035 | 4 | +--------------------------------------------------------------------+ |
8c9251b3 | 5 | | Copyright CiviCRM LLC (c) 2004-2018 | |
6a488035 TO |
6 | +--------------------------------------------------------------------+ |
7 | | This file is a part of CiviCRM. | | |
8 | | | | |
9 | | CiviCRM is free software; you can copy, modify, and distribute it | | |
10 | | under the terms of the GNU Affero General Public License | | |
11 | | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. | | |
12 | | | | |
13 | | CiviCRM is distributed in the hope that it will be useful, but | | |
14 | | WITHOUT ANY WARRANTY; without even the implied warranty of | | |
15 | | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | | |
16 | | See the GNU Affero General Public License for more details. | | |
17 | | | | |
18 | | You should have received a copy of the GNU Affero General Public | | |
19 | | License and the CiviCRM Licensing Exception along | | |
20 | | with this program; if not, contact CiviCRM LLC | | |
21 | | at info[AT]civicrm[DOT]org. If you have questions about the | | |
22 | | GNU Affero General Public License or the licensing of CiviCRM, | | |
23 | | see the CiviCRM license FAQ at http://civicrm.org/licensing | | |
24 | +--------------------------------------------------------------------+ | |
25 | *} | |
26 | <script type="text/javascript"> | |
27 | {literal} | |
28 | function submitForm( ) { | |
29 | var text = document.getElementById('text').value; | |
30 | var table = document.getElementById('fulltext_table').value; | |
31 | var url = {/literal}'{crmURL p="civicrm/contact/search/custom" h=0 q="csid=`$fullTextSearchID`&reset=1&force=1&text="}'{literal} + text; | |
32 | if ( table ) { | |
33 | url = url + '&table=' + table; | |
34 | } | |
35 | document.getElementById('id_fulltext_search').action = url; | |
36 | } | |
37 | {/literal} | |
38 | </script> | |
39 | ||
40 | <div class="block-crm crm-container"> | |
41 | <form method="post" id="id_fulltext_search"> | |
42 | <div style="margin-bottom: 8px;"> | |
589ebe1f | 43 | <input type="text" name="text" id='text' value="" class="crm-form-text" style="width: 10em;" /> <input type="submit" name="submit" id="fulltext_submit" value="{ts}Go{/ts}" class="crm-form-submit"/ onclick='submitForm();'> |
fd0bc470 | 44 | <input type="hidden" name="qfKey" value="{crmKey name='CRM_Contact_Controller_Search' addSequence=1}" /> |
6a488035 TO |
45 | </div> |
46 | <select class="form-select" id="fulltext_table" name="fulltext_table"> | |
47 | {if call_user_func(array('CRM_Core_Permission','giveMeAllACLs'))} | |
48 | <option value="">{ts}All{/ts}</option> | |
49 | <option value="Contact">{ts}Contacts{/ts}</option> | |
50 | {/if} | |
51 | <option value="Activity">{ts}Activities{/ts}</option> | |
52 | {if call_user_func(array('CRM_Core_Permission','access'), 'CiviCase')} | |
53 | <option value="Case">{ts}Cases{/ts}</option> | |
54 | {/if} | |
55 | {if call_user_func(array('CRM_Core_Permission','access'), 'CiviContribute')} | |
56 | <option value="Contribution">{ts}Contributions{/ts}</option> | |
57 | {/if} | |
58 | {if call_user_func(array('CRM_Core_Permission','access'), 'CiviEvent')} | |
59 | <option value="Participant">{ts}Participants{/ts}</option> | |
60 | {/if} | |
61 | {if call_user_func(array('CRM_Core_Permission','access'), 'CiviMember')} | |
62 | <option value="Membership">{ts}Memberships{/ts}</option> | |
63 | {/if} | |
e4ae4d1d | 64 | </select> {help id="id-fullText" file="CRM/Contact/Form/Search/Custom/FullText.hlp"} |
6a488035 TO |
65 | </form> |
66 | </div> |