RequirementSpecs: Projekte nicht als Dropdown sondern als Input-Filter
[kivitendo-erp.git] / templates / webpages / requirement_spec / _filter.html
index 33fc863..82da89b 100644 (file)
@@ -1,13 +1,14 @@
 [%- USE HTML %][%- USE L %][%- USE LxERP %]
 
 <div class="filter_toggle">
- <a href="#" onClick="javascript:$('.filter_toggle').toggle()">[% LxERP.t8("Show Filter") %]</a>
+ <a href="#" onClick="$('.filter_toggle').toggle(); $('#filter_customer_name_substr_ilike').focus();">[% LxERP.t8("Show Filter") %]</a>
 </div>
 
 <div class="filter_toggle" style="display:none">
  <a href="#" onClick="javascript:$('.filter_toggle').toggle()">[% LxERP.t8("Hide Filter") %]</a>
 
  <form method="post" action="controller.pl">
+  [%- L.hidden_tag("is_template", is_template) %]
 
   <p>
    <table class="rs_input_field">
@@ -16,6 +17,7 @@
      <td>[% L.input_tag('filter.title:substr::ilike', filter.title_substr__ilike) %]</td>
     </tr>
 
+[%- UNLESS is_template %]
     <tr>
      <th align="right">[% LxERP.t8("Customer") %]</th>
      <td>[% L.input_tag('filter.customer.name:substr::ilike', filter.customer.name_substr__ilike) %]</td>
     </tr>
 
     <tr>
-     <th align="right">[% LxERP.t8("Project") %]</th>
-     <td>[% L.select_tag('filter.project_id', SELF.projects, default=filter.project_id, title_key="full_description", with_empty=1) %]</td>
+     <th align="right">[% LxERP.t8("Project Number") %]</th>
+     <td>[% L.input_tag('filter.project.projectnumber:substr::ilike', filter.project.projectnumber_substr__ilike) %]</td>
     </tr>
+    <tr>
+     <th align="right">[% LxERP.t8("Project Description") %]</th>
+     <td>[% L.input_tag('filter.project.description:substr::ilike', filter.project.description_substr__ilike) %]</td>
+    </tr>
+[%- END %]
    </table>
   </p>