示例#1
0
 @Override
 public void keyReleased(KeyEvent e) {
   javax.swing.JTextField txtSearch = home.getSearching().getTxtSearch();
   if (e.getSource().equals(txtSearch)) {
     modelSearching.setElements(
         mdlCustomers.searchAllCustomerByName("%" + txtSearch.getText().toLowerCase() + "%"));
   }
 }
示例#2
0
 public ControllerHome(HomeFrame home) {
   this.home = home;
   modelSearching =
       new SearchingModel<Customers>(
           new String[] {"ID", "NOMBRE", "APELLIDOS", "CIUDAD"}, new SearchingCtrlCustomers());
   mdlCustomers = new ModelCustomers();
   modelSearching.setElements(mdlCustomers.searchAllCustomerByName("%%"));
   home.setSearching(new JSearching(modelSearching));
 }
示例#3
0
 public void searchByField(String string) {
   searchingModel.setElements(modelBreeds.searchAllBreedsByName("%" + string + "%"));
 }
 public void searchByField(String string) {
   modelSearching.setElements(mdlEmployees.searchAllEmployeeByName("%" + string + "%"));
 }
示例#5
0
 @Override
 public void windowGainedFocus(WindowEvent e) {
   modelSearching.setElements(
       mdlCustomers.searchAllCustomerByName(
           "%" + home.getSearching().getTxtSearch().getText().toLowerCase() + "%"));
 }