baa00bb189cf45f42c6c09786ea37020e8804131
[kivitendo-erp.git] / templates / webpages / do / search.html
1 [%- USE T8 %]
2 [%- USE L %]
3 [%- USE HTML %][%- USE LxERP %]
4 <h1>[% title %]</h1>
5
6  [%- IF vc == 'customer' %]
7  [%- SET is_customer = '1' %]
8  [%- ELSE %]
9  [%- SET is_customer = '0' %]
10  [%- END %]
11
12  [%- SET vctypelabel = vc == 'customer' ? LxERP.t8('Customer type') : LxERP.t8('Vendor type') %]
13
14  <script type="text/javascript">
15    $(function(){ document.Form.donumber.focus(); });
16  </script>
17
18  <style type="text/css">
19   .fixed_width {
20     width: 250px;
21   }
22  </style>
23
24  <form method="post" action="do.pl" name="Form">
25
26   <p>
27    <table>
28     <tr>
29      <th align="right">[% IF is_customer %][% 'Customer' | $T8 %][% ELSE %][% 'Vendor' | $T8 %][% END %]</th>
30      <td colspan="3">
31       [%- UNLESS SHOW_VC_DROP_DOWN %]
32       <input type="text" name="[% HTML.escape(vc) %]" class="fixed_width">
33       [%- ELSE %]
34       <select name="[% vc %]" class="fixed_width">
35        <option></option>
36        [%- FOREACH row = ALL_VC %]
37        <option>[% HTML.escape(row.name) %]--[% HTML.escape(row.id) %]</option>
38        [%- END %]
39       </select>
40       <input type="hidden" name="select[% vc %]" value="1">
41       [%- END %]
42      </td>
43     </tr>
44
45     <tr>
46      <th align="right" nowrap>[% 'Contact Person' | $T8 %]</th>
47      <td colspan="3">[% L.input_tag("cp_name", '', class="fixed_width") %]</td>
48     </tr>
49
50     <tr>
51      <th align="right">[% 'Delivery Order Number' | $T8 %]</th>
52      <td colspan="3"><input name="donumber" class="fixed_width"></td>
53     </tr>
54
55     <tr>
56      <th align="right">[% 'Order Number' | $T8 %]</th>
57      <td colspan="3"><input name="ordnumber" class="fixed_width"></td>
58     </tr>
59
60     <tr>
61      <th align="right">[% 'Customer Order Number' | $T8 %]</th>
62      <td colspan="3"><input name="cusordnumber" class="fixed_width"></td>
63     </tr>
64
65     [%- IF ALL_DEPARTMENTS.size %]
66     <tr>
67      <th align="right" nowrap>[% 'Department' | $T8 %]</th>
68      <td colspan="3">
69       <select name="department" class="fixed_width">
70        <option></option>
71        [%- FOREACH row = ALL_DEPARTMENTS %]
72        <option[% IF department == row.id %] selected[% END %]>[% HTML.escape(row.description) %]--[% HTML.escape(row.id) %]</option>
73        [%- END %]
74       </select>
75      </td>
76     </tr>
77     [%- END %]
78
79     <tr>
80      <th align="right">[% 'Employee' | $T8 %]</th>
81      <td>[% L.select_tag('employee_id', ALL_EMPLOYEES, title_key = 'safe_name', with_empty = 1, class = 'fixed_width') %]</td>
82     </tr>
83
84     [%- IF is_customer %]
85     <tr>
86      <th align="right">[% 'Salesman' | $T8 %]</th>
87      <td>[% L.select_tag('salesman_id', ALL_EMPLOYEES, title_key = 'safe_name', with_empty = 1, class = 'fixed_width') %]</td>
88     </tr>
89     [%- END %]
90
91     <tr>
92      <th align="right">[% 'Transaction description' | $T8 %]</th>
93      <td colspan="3"><input name="transaction_description" class="fixed_width"></td>
94     </tr>
95
96     <tr>
97      <th align="right">[% 'Project Number' | $T8 %]</th>
98      <td colspan="3">
99       <select name="project_id" class="fixed_width">
100        <option></option>
101        [%- FOREACH row = ALL_PROJECTS %]
102        <option value="[% HTML.escape(row.id) %]">[% HTML.escape(row.projectnumber) %]</option>
103        [%- END %]
104       </select>
105      </td>
106     </tr>
107
108     <tr>
109      <th align="right">[% 'Serial Number' | $T8 %]</th>
110      <td colspan="3"><input name="serialnumber" class="fixed_width"></td>
111     </tr>
112
113     [%- IF ALL_BUSINESS_TYPES.size %]
114     <tr>
115      <th align="right" nowrap>[% vctypelabel %]</th>
116      <td colspan="3">
117       [% L.select_tag('business_id', ALL_BUSINESS_TYPES, title_key = 'description', with_empty = 1, style='width:250px') %]
118      </td>
119     </tr>
120     [%- END %]
121
122     <tr>
123      <th align="right">[% 'Delivery Order Date' | $T8 %] [% 'From' | $T8 %]</th>
124      <td>
125       [% L.date_tag('transdatefrom') %]
126      </td>
127      <th align="right">[% 'Bis' | $T8 %]</th>
128      <td>
129       [% L.date_tag('transdateto') %]
130      </td>
131     </tr>
132
133     <tr>
134      <th align="right">[% 'Reqdate' | $T8 %] [% 'From' | $T8 %]</th>
135      <td>
136       [% L.date_tag('reqdatefrom') %]
137      </td>
138      <th align="right">[% 'Bis' | $T8 %]</th>
139      <td>
140       [% L.date_tag('reqdateto') %]
141      </td>
142     </tr>
143
144     [%- IF is_customer %]
145     <tr>
146      <th align="right">[% 'Insert Date' | $T8 %] [% 'From' | $T8 %]</th>
147      <td>
148        [% L.date_tag('insertdatefrom') %]
149      </td>
150      <th align="right">[% 'Bis' | $T8 %]</th>
151      <td>
152        [% L.date_tag('insertdateto') %]
153      </td>
154     </tr>
155     [%- END %]
156
157     <tr>
158      <th align="right">[% 'Include in Report' | $T8 %]</th>
159      <td colspan="5">
160       <table>
161        <tr>
162         <td>
163          <input type="checkbox" name="open" value="1" id="open" checked>
164          <label for="open">[% 'Open' | $T8 %]</label>
165         </td>
166         <td>
167          <input type="checkbox" name="closed" value="1" id="closed">
168          <label for="closed">[% 'Closed' | $T8 %]</label>
169         </td>
170        </tr>
171
172        <tr>
173         <td>
174          <input name="notdelivered" id="notdelivered" class="checkbox" type="checkbox" value="1" checked>
175          <label for="notdelivered">[% 'Not delivered' | $T8 %]</label>
176         </td>
177         <td>
178          <input name="delivered" id="delivered" class="checkbox" type="checkbox" value="1" checked>
179          <label for="delivered">[% 'Delivered' | $T8 %]</label></td>
180        </tr>
181
182        <tr>
183         <td>
184          <input name="l_id" id="l_id" class="checkbox" type="checkbox" value="Y">
185          <label for="l_id">[% 'ID' | $T8 %]</label>
186         </td>
187
188         <td>
189          <input name="l_donumber" id="l_donumber" class="checkbox" type="checkbox" value="Y" checked>
190          <label for="l_donumber">[% 'Delivery Order Number' | $T8 %]</label>
191         </td>
192        </tr>
193
194        <tr>
195         <td>
196          <input name="l_ordnumber" id="l_ordnumber" class="checkbox" type="checkbox" value="Y" checked>
197          <label for="l_ordnumber">[% 'Order Number' | $T8 %]</label>
198         </td>
199
200         <td>
201          <input name="l_cusordnumber" id="l_cusordnumber" class="checkbox" type="checkbox" value="Y" checked>
202          <label for="l_cusordnumber">[% 'Customer Order Number' | $T8 %]</label>
203         </td>
204        </tr>
205
206        <tr>
207         <td>
208          <input name="l_transdate" id="l_transdate" class="checkbox" type="checkbox" value="Y" checked>
209          <label for="l_transdate">[% 'Delivery Order Date' | $T8 %]</label>
210         </td>
211         <td>
212          <input name="l_reqdate" id="l_reqdate" class="checkbox" type="checkbox" value="Y" checked>
213          <label for="l_reqdate">[% 'Reqdate' | $T8 %]</label>
214         </td>
215         [% IF is_customer %]
216         <td>
217          <input name="l_insertdate" id="l_insertdate" class="checkbox" type="checkbox" value="Y">
218          <label for="l_insertdate">[% 'Insert Date' | $T8 %]</label>
219         </td>
220         [%- END %]
221        </tr>
222
223        <tr>
224         <td>
225          <input name="l_name" id="l_name" class="checkbox" type="checkbox" value="Y" checked>
226          <label for="l_name">[% IF is_customer %][% 'Customer' | $T8 %][% ELSE %][% 'Vendor' | $T8 %][% END %]</label>
227         </td>
228
229         [% IF is_customer %]
230         <td>
231          <input name="l_customernumber" id="l_customernumber" class="checkbox" type="checkbox" value="Y">
232          <label for="l_customernumber">[% 'Customer Number' | $T8 %]</label>
233         </td>
234         [% END %]
235        </tr>
236
237        <tr>
238         <td>
239          <input name="l_department" id="l_department" class="checkbox" type="checkbox" value="Y">
240          <label for="l_department">[% "Department" | $T8 %]</label>
241         </td>
242
243         <td>
244          <input name="l_shipvia" id="l_shipvia" class="checkbox" type="checkbox" value="Y">
245          <label for="l_shipvia">[% 'Ship via' | $T8 %]</label>
246         </td>
247        </tr>
248
249        <tr>
250         <td>
251          <input name="l_employee" id="l_employee" class="checkbox" type="checkbox" value="Y" checked>
252          <label for="l_employee">[% 'Employee' | $T8 %]</label>
253         </td>
254
255         <td>
256          <input name="l_salesman" id="l_salesman" class="checkbox" type="checkbox" value="Y">
257          <label for="l_salesman">[% 'Salesman' | $T8 %]</label>
258         </td>
259        </tr>
260
261        <tr>
262         <td>
263          <input name="l_globalprojectnumber" id="l_globalprojectnumber" class="checkbox" type="checkbox" value="Y">
264          <label for="l_globalprojectnumber">[% 'Project Number' | $T8 %]</label>
265         </td>
266
267         <td>
268          <input name="l_transaction_description" id="l_transaction_description" class="checkbox" type="checkbox" value="Y"[% IF INSTANCE_CONF.get_require_transaction_description_ps %] checked[% END %]>
269          <label for="l_transaction_description">[% 'Transaction description' | $T8 %]</label>
270         </td>
271        </tr>
272
273       </table>
274      </td>
275     </tr>
276    </table>
277   </p>
278
279   <hr size="3" noshade>
280
281   <p>
282    <input type="hidden" name="nextsub" value="orders">
283    <input type="hidden" name="vc" value="[% HTML.escape(vc) %]">
284    <input type="hidden" name="type" value="[% HTML.escape(type) %]">
285
286    <input class="submit" type="submit" name="action" value="[% 'Continue' | $T8 %]">
287   </p>
288  </form>