OpenConcerto

Dépôt officiel du code source de l'ERP OpenConcerto
sonarqube

svn://code.openconcerto.org/openconcerto

Rev

Rev 63 | Rev 83 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 63 Rev 73
Line 36... Line 36...
36
import org.openconcerto.sql.sqlobject.ElementComboBox;
36
import org.openconcerto.sql.sqlobject.ElementComboBox;
37
import org.openconcerto.sql.sqlobject.JUniqueTextField;
37
import org.openconcerto.sql.sqlobject.JUniqueTextField;
38
import org.openconcerto.sql.sqlobject.SQLTextCombo;
38
import org.openconcerto.sql.sqlobject.SQLTextCombo;
39
import org.openconcerto.sql.users.UserManager;
39
import org.openconcerto.sql.users.UserManager;
40
import org.openconcerto.sql.view.EditFrame;
40
import org.openconcerto.sql.view.EditFrame;
-
 
41
import org.openconcerto.sql.view.list.RowValuesTable;
41
import org.openconcerto.ui.DefaultGridBagConstraints;
42
import org.openconcerto.ui.DefaultGridBagConstraints;
42
import org.openconcerto.ui.FormLayouter;
43
import org.openconcerto.ui.FormLayouter;
43
import org.openconcerto.ui.JDate;
44
import org.openconcerto.ui.JDate;
44
import org.openconcerto.ui.TitledSeparator;
45
import org.openconcerto.ui.TitledSeparator;
45
import org.openconcerto.ui.component.ITextArea;
46
import org.openconcerto.ui.component.ITextArea;
Line 79... Line 80...
79
 
80
 
80
    public CommandeClientSQLComponent() {
81
    public CommandeClientSQLComponent() {
81
        super(Configuration.getInstance().getDirectory().getElement("COMMANDE_CLIENT"));
82
        super(Configuration.getInstance().getDirectory().getElement("COMMANDE_CLIENT"));
82
    }
83
    }
83
 
84
 
84
    public CommandeClientItemTable getRowValuesTable() {
85
    public RowValuesTable getRowValuesTable() {
85
        return this.table;
86
        return this.table.getRowValuesTable();
86
    }
87
    }
87
 
88
 
88
    public void addViews() {
89
    public void addViews() {
89
        this.setLayout(new GridBagLayout());
90
        this.setLayout(new GridBagLayout());
90
        final GridBagConstraints c = new DefaultGridBagConstraints();
91
        final GridBagConstraints c = new DefaultGridBagConstraints();
Line 229... Line 230...
229
            c.gridwidth = GridBagConstraints.REMAINDER;
230
            c.gridwidth = GridBagConstraints.REMAINDER;
230
 
231
 
231
            c.weightx = 1;
232
            c.weightx = 1;
232
            this.add(boxTarif, c);
233
            this.add(boxTarif, c);
233
            this.addView(boxTarif, "ID_TARIF");
234
            this.addView(boxTarif, "ID_TARIF");
234
            boxTarif.addValueListener(new PropertyChangeListener() {
235
            boxTarif.addModelListener("wantedID", new PropertyChangeListener() {
235
 
236
 
236
                @Override
237
                @Override
237
                public void propertyChange(PropertyChangeEvent evt) {
238
                public void propertyChange(PropertyChangeEvent evt) {
-
 
239
                    SQLRow selectedRow = boxTarif.getRequest().getPrimaryTable().getRow(boxTarif.getWantedID());
238
                    table.setTarif(boxTarif.getSelectedRow(), false);
240
                    table.setTarif(selectedRow, false);
239
                }
241
                }
240
            });
242
            });
241
        }
243
        }
242
 
244
 
243
        // Table d'élément
245
        // Table d'élément