OpenConcerto

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

svn://code.openconcerto.org/openconcerto

Rev

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

Rev 80 Rev 83
Line 11... Line 11...
11
 * When distributing the software, include this License Header Notice in each file.
11
 * When distributing the software, include this License Header Notice in each file.
12
 */
12
 */
13
 
13
 
14
 package org.openconcerto.erp.core.sales.quote.action;
14
 package org.openconcerto.erp.core.sales.quote.action;
15
 
15
 
16
import org.openconcerto.erp.action.CreateFrameAbstractAction;
16
import org.openconcerto.erp.action.CreateListFrameAbstractAction;
17
import org.openconcerto.erp.config.ComptaPropsConfiguration;
17
import org.openconcerto.erp.config.ComptaPropsConfiguration;
18
import org.openconcerto.erp.core.common.ui.IListFilterDatePanel;
18
import org.openconcerto.erp.core.common.ui.IListFilterDatePanel;
19
import org.openconcerto.erp.core.common.ui.IListTotalPanel;
19
import org.openconcerto.erp.core.common.ui.IListTotalPanel;
20
import org.openconcerto.erp.core.common.ui.PanelFrame;
20
import org.openconcerto.erp.core.common.ui.PanelFrame;
21
import org.openconcerto.erp.core.sales.invoice.ui.ListeFactureRenderer;
21
import org.openconcerto.erp.core.sales.invoice.ui.ListeFactureRenderer;
Line 60... Line 60...
60
import javax.swing.Action;
60
import javax.swing.Action;
61
import javax.swing.JFrame;
61
import javax.swing.JFrame;
62
import javax.swing.JLabel;
62
import javax.swing.JLabel;
63
import javax.swing.JMenu;
63
import javax.swing.JMenu;
64
import javax.swing.JMenuItem;
64
import javax.swing.JMenuItem;
-
 
65
import javax.swing.JOptionPane;
65
import javax.swing.JPopupMenu;
66
import javax.swing.JPopupMenu;
66
import javax.swing.JTable;
67
import javax.swing.JTable;
67
import javax.swing.SwingConstants;
68
import javax.swing.SwingConstants;
68
import javax.swing.table.DefaultTableCellRenderer;
69
import javax.swing.table.DefaultTableCellRenderer;
69
 
70
 
70
public class ListeDesDevisAction extends CreateFrameAbstractAction implements MouseListener {
71
public class ListeDesDevisAction extends CreateListFrameAbstractAction implements MouseListener {
71
 
72
 
72
    DateFormat dateFormat = new SimpleDateFormat("dd/MM/yyyy HH:mm");
73
    DateFormat dateFormat = new SimpleDateFormat("dd/MM/yyyy HH:mm");
73
 
74
 
74
    public ListeDesDevisAction() {
75
    public ListeDesDevisAction() {
75
        super();
76
        super();
Line 78... Line 79...
78
    }
79
    }
79
 
80
 
80
    IListFrame frame = null;
81
    IListFrame frame = null;
81
    final DevisSQLElement element = (DevisSQLElement) Configuration.getInstance().getDirectory().getElement("DEVIS");
82
    final DevisSQLElement element = (DevisSQLElement) Configuration.getInstance().getDirectory().getElement("DEVIS");
82
 
83
 
-
 
84
    public String getTableName() {
-
 
85
        return "DEVIS";
-
 
86
    }
-
 
87
 
83
    public JFrame createFrame() {
88
    public JFrame createFrame() {
84
            final String pluralName = this.element.getPluralName();
89
            final String pluralName = this.element.getPluralName();
85
            final PanelFrame frame2 = new PanelFrame(new ListeDesDevisPanel(), "Liste des " + pluralName);
90
            final PanelFrame frame2 = new PanelFrame(new ListeDesDevisPanel(), "Liste des " + pluralName);
86
            return frame2;
91
            return frame2;
87
    }
92
    }
Line 126... Line 131...
126
                                    if (ooConnexion == null) {
131
                                    if (ooConnexion == null) {
127
                                        return;
132
                                        return;
128
                                    }
133
                                    }
129
                                    ooConnexion.loadDocument(file, false);
134
                                    ooConnexion.loadDocument(file, false);
130
 
135
 
-
 
136
                                } catch (LinkageError ex) {
-
 
137
                                    JOptionPane.showMessageDialog(new JFrame(), "Merci d'installer OpenOffice ou LibreOffice");
131
                                } catch (Exception ex) {
138
                                } catch (Exception ex) {
132
                                    ex.printStackTrace();
139
                                    ex.printStackTrace();
133
                                    ExceptionHandler.handle("Impossible de charger le document OpenOffice", ex);
140
                                    ExceptionHandler.handle("Impossible de charger le document OpenOffice", ex);
134
                                }
141
                                }
135
 
142
 
Line 200... Line 207...
200
    public void mouseEntered(MouseEvent e) {
207
    public void mouseEntered(MouseEvent e) {
201
    }
208
    }
202
 
209
 
203
    public void mouseExited(MouseEvent e) {
210
    public void mouseExited(MouseEvent e) {
204
    }
211
    }
-
 
212
 
205
}
213
}