Package com.commander4j.tablemodel

Examples of com.commander4j.tablemodel.JDBMaterialUomTableModel


    query.applyRestriction(false, "none", 0);
    query.bindParams();
    listStatement = query.getPreparedStatement();
   
    JDBMaterialUom materialuom = new JDBMaterialUom(Common.selectedHostID, Common.sessionID);
    JDBMaterialUomTableModel materialuomtable = new JDBMaterialUomTableModel(materialuom.getMaterialDataResultSet(listStatement));
    TableRowSorter<JDBMaterialUomTableModel> sorter = new TableRowSorter<JDBMaterialUomTableModel>(materialuomtable);

    jTable1.setRowSorter(sorter);
    jTable1.setModel(materialuomtable);
    jScrollPane1.setViewportView(jTable1);
    jTable1.getTableHeader().setReorderingAllowed(false);
    jTable1.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
    jTable1.setFont(Common.font_list);

    TableColumn col = jTable1.getColumnModel().getColumn(0);
    col.setPreferredWidth(100); // Material
    col = jTable1.getColumnModel().getColumn(1);
    col.setPreferredWidth(50); // Uom
    col = jTable1.getColumnModel().getColumn(2);
    col.setPreferredWidth(110); // EAN
    col = jTable1.getColumnModel().getColumn(3);
    col.setPreferredWidth(50); // Variant
    col = jTable1.getColumnModel().getColumn(4);
    col.setPreferredWidth(80); // Nominator
    col = jTable1.getColumnModel().getColumn(5);
    col.setPreferredWidth(80); // Denominator
    jScrollPane1.repaint();

    JUtility.setResultRecordCountColour(jStatusText, false, 0, materialuomtable.getRowCount());

  }
View Full Code Here


    query.applyRestriction(false, "none", 0);
    query.bindParams();
    listStatement = query.getPreparedStatement();
   
    JDBMaterialUom materialuom = new JDBMaterialUom(Common.selectedHostID, Common.sessionID);
    JDBMaterialUomTableModel materialuomtable = new JDBMaterialUomTableModel(materialuom.getMaterialDataResultSet(listStatement));
    TableRowSorter<JDBMaterialUomTableModel> sorter = new TableRowSorter<JDBMaterialUomTableModel>(materialuomtable);

    jTable1.setRowSorter(sorter);
    jTable1.setModel(materialuomtable);
    jScrollPane1.setViewportView(jTable1);
    jTable1.getTableHeader().setReorderingAllowed(false);
    jTable1.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
    jTable1.setFont(Common.font_list);

    TableColumn col = jTable1.getColumnModel().getColumn(0);
    col.setPreferredWidth(100); // Material
    col = jTable1.getColumnModel().getColumn(1);
    col.setPreferredWidth(50); // Uom
    col = jTable1.getColumnModel().getColumn(2);
    col.setPreferredWidth(110); // EAN
    col = jTable1.getColumnModel().getColumn(3);
    col.setPreferredWidth(50); // Variant
    col = jTable1.getColumnModel().getColumn(4);
    col.setPreferredWidth(80); // Nominator
    col = jTable1.getColumnModel().getColumn(5);
    col.setPreferredWidth(80); // Denominator
    jScrollPane1.repaint();

    JUtility.setResultRecordCountColour(jStatusText, false, 0, materialuomtable.getRowCount());

  }
View Full Code Here

TOP

Related Classes of com.commander4j.tablemodel.JDBMaterialUomTableModel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.