diff options
Diffstat (limited to 'h-source/Application')
-rw-r--r-- | h-source/Application/Controllers/GenericController.php | 6 | ||||
-rw-r--r-- | h-source/Application/Views/Desktop/Search/form.php | 8 | ||||
-rw-r--r-- | h-source/Application/Views/Desktop/catalogue.php | 8 |
3 files changed, 18 insertions, 4 deletions
diff --git a/h-source/Application/Controllers/GenericController.php b/h-source/Application/Controllers/GenericController.php index 2381866..117845a 100644 --- a/h-source/Application/Controllers/GenericController.php +++ b/h-source/Application/Controllers/GenericController.php @@ -501,7 +501,13 @@ class GenericController extends BaseController $data['topNotice'] = $this->getModule(array('devices',$this->controller,'catalogue')); $data['popupLabel'] = $this->mod->getPopupLabel($this->viewArgs); + + $data["search_string_form_value"] = strcmp($this->viewArgs['search_string'],Params::$nullQueryValue) === 0 ? gtext("model name") : $this->viewArgs['search_string']; + //set search_string to undef to clean the model name filter + $this->viewArgs['search_string'] = "undef"; + $this->buildStatus(); + $this->append($data); $this->loadViewAll('catalogue'); diff --git a/h-source/Application/Views/Desktop/Search/form.php b/h-source/Application/Views/Desktop/Search/form.php index 22650f5..136c544 100644 --- a/h-source/Application/Views/Desktop/Search/form.php +++ b/h-source/Application/Views/Desktop/Search/form.php @@ -24,7 +24,7 @@ $(document).ready(function() { - $(".search_form table").append("<tr><td><input id=\"search_action_input\" type=\"submit\" name=\"action\" value=\"search\"></td></tr>"); + $(".search_form table").append("<tr><td><input id=\"search_action_input\" type=\"submit\" name=\"action\" value=\"<?php echo gtext('Search');?>\"></td></tr>"); $("#search_action_input").click(function(){ @@ -32,7 +32,7 @@ var s_model = $("#search_model_input").attr("value"); var s_action = $("#search_action_input").attr("value"); - var s_url = "1/" + s_action + "/" + s_type + "/" + s_model; + var s_url = "1/search/" + s_type + "/" + s_model; location.href="<?php echo $this->baseUrl."/search/results/$lang/";?>"+s_url; return false; @@ -86,7 +86,7 @@ <td><?php echo Html_Form::input('pciid','','input_entry_search');?></td> </tr> <tr> - <td><input type="submit" name="search_pci" value="search"></td> + <td><input type="submit" name="search_pci" value="<?php echo gtext('Search');?>"></td> </tr> </table> </form> @@ -103,7 +103,7 @@ <td><?php echo Html_Form::textarea('lspci',gtext('write here the output of lspci -vmmnn'),'textarea_entry_search');?></td> </tr> <tr> - <td><input type="submit" name="search_pci" value="search"></td> + <td><input type="submit" name="search_pci" value="<?php echo gtext('Search');?>"></td> </tr> </table> </form> diff --git a/h-source/Application/Views/Desktop/catalogue.php b/h-source/Application/Views/Desktop/catalogue.php index 5bda414..1e15e4c 100644 --- a/h-source/Application/Views/Desktop/catalogue.php +++ b/h-source/Application/Views/Desktop/catalogue.php @@ -40,6 +40,14 @@ </div> </div> <?php } ?> + + <div class="model_string_search_form"> + <form action="<?php echo $this->currPage."/$lang".$this->viewStatus;?>"> + <input type="text" value="<?php echo $search_string_form_value;?>" name="search_string"> + <a href="<?php echo $this->currPage."/$lang".$this->viewStatus;?>"><img src="<?php echo $this->baseUrl."/Public/Img/Crystal/button_cancel.png";?>" /></a> + <input type="submit" value="<?php echo gtext('Search');?>" name="submit"> + </form> + </div> <!--if no notebooks found--> <?php if (strcmp($recordNumber,0) === 0) { ?> |