RSS Git Download  Clone
Raw Blame History
	[% META title="Record Search" %]
<!-- BEGIN search/default.tt -->

    <h2 class="header">Search for record(s):</h2>

    <form method="get" action="[% app_url %]/search/do_search" name="search" id="search"
		[% # INCLUDE site/snippets/disable_form_resubmission.tt name = 'searchButton'
			value = 'Searching' %]>

    [% INCLUDE search/main_form.tt %]

    [% IF c.user_can('simple_sql') %]
		[% INCLUDE site/simple_sql.tt %]
    [% END %]

    [% # IF c.user_can('free_sql') # maybe replace with dedicated package %]
		[% # INCLUDE site/free_sql.tt %]
    [% # END %]

    <h4>Search Options:</h4>

    <table class="indent">
        <tr>
            <td class="bold">Hits/page:
                <input type="text" name="entries_per_page" [% site.html.on_focus %]
					size="3" value="[% c.cfg('settings').entries_per_page %]" />
            </td>
            <td class="bold">Sort by:
                <select name="sort_by" [% site.html.on_focus %]>
                    <option value="requests.id">Date</option>
                    <option value="patients.dob">D.o.B</option>
                    <option value="patients.first_name">First Name</option>
                    <option value="patients.last_name">Last Name</option>
                    <option value="patient_case.unit_number">Patient No.</option>
                    <option value="patient.nhs_number">NHS No.</option>
                    <option value="referral_sources.display_name">Source</option>
                </select>
            </td>
            <td class="bold">Sort order:
                <select name="sort_order" [% site.html.on_focus %]>
                    <option value="desc">Descending</option>
                    <option value="">Ascending</option>
                </select>
            </td>
        </tr>
    </table>

    <p class="center">
        <input type="submit" value="Search" class="button" id="searchButton" />
        <input type="reset" name=".reset" class="button" />
    </p>
    </form>

    [% PROCESS site/field_focus.tt form_name = 'search', field_name = 'lab_number' %]
<!-- END search/default.tt -->