listStatement = query.getPreparedStatement();
}
private void populateList() {
JDBMaterialBatch materialBatch = new JDBMaterialBatch(Common.selectedHostID, Common.sessionID);
JDBMaterialBatchTableModel materialBatchTable = new JDBMaterialBatchTableModel(materialBatch.getMaterialBatchDataResultSet(listStatement));
TableRowSorter<JDBMaterialBatchTableModel> sorter = new TableRowSorter<JDBMaterialBatchTableModel>(materialBatchTable);
jTable1.setRowSorter(sorter);
jTable1.setModel(materialBatchTable);
jScrollPane1.setViewportView(jTable1);
JUtility.scrolltoHomePosition(jScrollPane1);
jTable1.getTableHeader().setReorderingAllowed(false);
jTable1.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
jTable1.setFont(Common.font_list);
jTable1.getColumnModel().getColumn(0).setPreferredWidth(95);
jTable1.getColumnModel().getColumn(1).setPreferredWidth(95);
jTable1.getColumnModel().getColumn(2).setPreferredWidth(95);
jTable1.getColumnModel().getColumn(3).setPreferredWidth(120);
jScrollPane1.repaint();
JUtility.setResultRecordCountColour(jStatusText, false, 0, materialBatchTable.getRowCount());
}