OpenConcerto

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

svn://code.openconcerto.org/openconcerto

Rev

Rev 174 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 174 Rev 177
Line 87... Line 87...
87
import org.openconcerto.erp.core.humanresources.payroll.element.AyantDroitTypeSQLElement;
87
import org.openconcerto.erp.core.humanresources.payroll.element.AyantDroitTypeSQLElement;
88
import org.openconcerto.erp.core.humanresources.payroll.element.CaisseCotisationRenseignentSQLElement;
88
import org.openconcerto.erp.core.humanresources.payroll.element.CaisseCotisationRenseignentSQLElement;
89
import org.openconcerto.erp.core.humanresources.payroll.element.CaisseCotisationSQLElement;
89
import org.openconcerto.erp.core.humanresources.payroll.element.CaisseCotisationSQLElement;
90
import org.openconcerto.erp.core.humanresources.payroll.element.CaisseModePaiementSQLElement;
90
import org.openconcerto.erp.core.humanresources.payroll.element.CaisseModePaiementSQLElement;
91
import org.openconcerto.erp.core.humanresources.payroll.element.ClassementConventionnelSQLElement;
91
import org.openconcerto.erp.core.humanresources.payroll.element.ClassementConventionnelSQLElement;
-
 
92
import org.openconcerto.erp.core.humanresources.payroll.element.CodeAmenagementPartielSQLElement;
92
import org.openconcerto.erp.core.humanresources.payroll.element.CodeBaseAssujettieSQLElement;
93
import org.openconcerto.erp.core.humanresources.payroll.element.CodeBaseAssujettieSQLElement;
93
import org.openconcerto.erp.core.humanresources.payroll.element.CodeCaisseTypeRubriqueSQLElement;
94
import org.openconcerto.erp.core.humanresources.payroll.element.CodeCaisseTypeRubriqueSQLElement;
94
import org.openconcerto.erp.core.humanresources.payroll.element.CodeCaractActiviteSQLElement;
95
import org.openconcerto.erp.core.humanresources.payroll.element.CodeCaractActiviteSQLElement;
95
import org.openconcerto.erp.core.humanresources.payroll.element.CodeContratTravailSQLElement;
96
import org.openconcerto.erp.core.humanresources.payroll.element.CodeContratTravailSQLElement;
96
import org.openconcerto.erp.core.humanresources.payroll.element.CodeCotisationEtablissementSQLElement;
97
import org.openconcerto.erp.core.humanresources.payroll.element.CodeCotisationEtablissementSQLElement;
Line 102... Line 103...
102
import org.openconcerto.erp.core.humanresources.payroll.element.CodePenibiliteSQLElement;
103
import org.openconcerto.erp.core.humanresources.payroll.element.CodePenibiliteSQLElement;
103
import org.openconcerto.erp.core.humanresources.payroll.element.CodeRegimeSQLElement;
104
import org.openconcerto.erp.core.humanresources.payroll.element.CodeRegimeSQLElement;
104
import org.openconcerto.erp.core.humanresources.payroll.element.CodeStatutCategorielConventionnelSQLElement;
105
import org.openconcerto.erp.core.humanresources.payroll.element.CodeStatutCategorielConventionnelSQLElement;
105
import org.openconcerto.erp.core.humanresources.payroll.element.CodeStatutCategorielSQLElement;
106
import org.openconcerto.erp.core.humanresources.payroll.element.CodeStatutCategorielSQLElement;
106
import org.openconcerto.erp.core.humanresources.payroll.element.CodeStatutProfSQLElement;
107
import org.openconcerto.erp.core.humanresources.payroll.element.CodeStatutProfSQLElement;
-
 
108
import org.openconcerto.erp.core.humanresources.payroll.element.CodeSuspensionSQLElement;
107
import org.openconcerto.erp.core.humanresources.payroll.element.CodeTypeRubriqueBrutSQLElement;
109
import org.openconcerto.erp.core.humanresources.payroll.element.CodeTypeRubriqueBrutSQLElement;
108
import org.openconcerto.erp.core.humanresources.payroll.element.CoefficientPrimeSQLElement;
110
import org.openconcerto.erp.core.humanresources.payroll.element.CoefficientPrimeSQLElement;
109
import org.openconcerto.erp.core.humanresources.payroll.element.ContratDetacheExpatrieSQLElement;
111
import org.openconcerto.erp.core.humanresources.payroll.element.ContratDetacheExpatrieSQLElement;
110
import org.openconcerto.erp.core.humanresources.payroll.element.ContratDispositifPolitiqueSQLElement;
112
import org.openconcerto.erp.core.humanresources.payroll.element.ContratDispositifPolitiqueSQLElement;
111
import org.openconcerto.erp.core.humanresources.payroll.element.ContratModaliteTempsSQLElement;
113
import org.openconcerto.erp.core.humanresources.payroll.element.ContratModaliteTempsSQLElement;
Line 233... Line 235...
233
import org.openconcerto.erp.generationDoc.provider.ArticleCodeFournisseurProvider;
235
import org.openconcerto.erp.generationDoc.provider.ArticleCodeFournisseurProvider;
234
import org.openconcerto.erp.generationDoc.provider.ConditionsReglementDetailsProvider;
236
import org.openconcerto.erp.generationDoc.provider.ConditionsReglementDetailsProvider;
235
import org.openconcerto.erp.generationDoc.provider.DateBLProvider;
237
import org.openconcerto.erp.generationDoc.provider.DateBLProvider;
236
import org.openconcerto.erp.generationDoc.provider.DateProvider;
238
import org.openconcerto.erp.generationDoc.provider.DateProvider;
237
import org.openconcerto.erp.generationDoc.provider.FacturableValueProvider;
239
import org.openconcerto.erp.generationDoc.provider.FacturableValueProvider;
-
 
240
import org.openconcerto.erp.generationDoc.provider.FichePayeHeureSupTotalProvider;
-
 
241
import org.openconcerto.erp.generationDoc.provider.FichePayeHeureTotalProvider;
-
 
242
import org.openconcerto.erp.generationDoc.provider.FichePayePlafondAProvider;
-
 
243
import org.openconcerto.erp.generationDoc.provider.FichePayeSmicHProvider;
238
import org.openconcerto.erp.generationDoc.provider.FormatedGlobalQtyTotalProvider;
244
import org.openconcerto.erp.generationDoc.provider.FormatedGlobalQtyTotalProvider;
-
 
245
import org.openconcerto.erp.generationDoc.provider.IbanProvider;
239
import org.openconcerto.erp.generationDoc.provider.LabelAccountInvoiceProvider;
246
import org.openconcerto.erp.generationDoc.provider.LabelAccountInvoiceProvider;
240
import org.openconcerto.erp.generationDoc.provider.MergedGlobalQtyTotalProvider;
247
import org.openconcerto.erp.generationDoc.provider.MergedGlobalQtyTotalProvider;
241
import org.openconcerto.erp.generationDoc.provider.ModeDeReglementDetailsProvider;
248
import org.openconcerto.erp.generationDoc.provider.ModeDeReglementDetailsProvider;
242
import org.openconcerto.erp.generationDoc.provider.PaiementRemainedDevisProvider;
249
import org.openconcerto.erp.generationDoc.provider.PaiementRemainedDevisProvider;
243
import org.openconcerto.erp.generationDoc.provider.PaiementRemainedProvider;
250
import org.openconcerto.erp.generationDoc.provider.PaiementRemainedProvider;
Line 294... Line 301...
294
import org.openconcerto.erp.preferences.GestionClientPreferencePanel;
301
import org.openconcerto.erp.preferences.GestionClientPreferencePanel;
295
import org.openconcerto.erp.preferences.GestionCommercialeGlobalPreferencePanel;
302
import org.openconcerto.erp.preferences.GestionCommercialeGlobalPreferencePanel;
296
import org.openconcerto.erp.preferences.TemplateNXProps;
303
import org.openconcerto.erp.preferences.TemplateNXProps;
297
import org.openconcerto.erp.storage.CloudStorageEngine;
304
import org.openconcerto.erp.storage.CloudStorageEngine;
298
import org.openconcerto.erp.storage.StorageEngines;
305
import org.openconcerto.erp.storage.StorageEngines;
-
 
306
import org.openconcerto.erp.utils.TM;
299
import org.jopendocument.link.OOConnexion;
307
import org.jopendocument.link.OOConnexion;
300
import org.openconcerto.sql.ShowAs;
308
import org.openconcerto.sql.ShowAs;
301
import org.openconcerto.sql.element.SQLElement;
309
import org.openconcerto.sql.element.SQLElement;
302
import org.openconcerto.sql.element.SQLElementDirectory;
310
import org.openconcerto.sql.element.SQLElementDirectory;
303
import org.openconcerto.sql.element.SharedSQLElement;
311
import org.openconcerto.sql.element.SharedSQLElement;
Line 577... Line 585...
577
            registerAccountingProvider();
585
            registerAccountingProvider();
578
            registerCellValueProvider();
586
            registerCellValueProvider();
579
        }
587
        }
580
    }
588
    }
581
 
589
 
-
 
590
    public final TM getERP_TM() {
-
 
591
        return TM.getERP_TM(this.getLocale());
-
 
592
    }
-
 
593
 
582
    private void registerAccountingProvider() {
594
    private void registerAccountingProvider() {
583
        SalesInvoiceAccountingRecordsProvider.register();
595
        SalesInvoiceAccountingRecordsProvider.register();
584
        SalesCreditAccountingRecordsProvider.register();
596
        SalesCreditAccountingRecordsProvider.register();
585
        SupplyOrderAccountingRecordsProvider.register();
597
        SupplyOrderAccountingRecordsProvider.register();
586
    }
598
    }
Line 608... Line 620...
608
        QteTotalDocProvider.register();
620
        QteTotalDocProvider.register();
609
        StockLocationProvider.register();
621
        StockLocationProvider.register();
610
        RefClientValueProvider.register();
622
        RefClientValueProvider.register();
611
        ModeDeReglementDetailsProvider.register();
623
        ModeDeReglementDetailsProvider.register();
612
        FormatedGlobalQtyTotalProvider.register();
624
        FormatedGlobalQtyTotalProvider.register();
-
 
625
        FichePayeHeureSupTotalProvider.register();
-
 
626
        FichePayeHeureTotalProvider.register();
-
 
627
        FichePayePlafondAProvider.register();
-
 
628
        FichePayeSmicHProvider.register();
613
        MergedGlobalQtyTotalProvider.register();
629
        MergedGlobalQtyTotalProvider.register();
614
        PaiementRemainedProvider.register();
630
        PaiementRemainedProvider.register();
615
        PaiementRemainedDevisProvider.register();
631
        PaiementRemainedDevisProvider.register();
616
        RemiseProvider.register();
632
        RemiseProvider.register();
617
        DateProvider.register();
633
        DateProvider.register();
618
        RemiseTotalProvider.register();
634
        RemiseTotalProvider.register();
619
        RecapFactureProvider.register();
635
        RecapFactureProvider.register();
620
        RestantAReglerProvider.register();
636
        RestantAReglerProvider.register();
621
        SaledTotalNotDiscountedProvider.register();
637
        SaledTotalNotDiscountedProvider.register();
622
        ArticleCodeFournisseurProvider.register();
638
        ArticleCodeFournisseurProvider.register();
-
 
639
        IbanProvider.register();
623
    }
640
    }
624
 
641
 
625
    @Override
642
    @Override
626
    protected void initDS(SQLDataSource ds) {
643
    protected void initDS(SQLDataSource ds) {
627
        super.initDS(ds);
644
        super.initDS(ds);
628
        ds.setInitialSize(3);
645
        ds.setInitialSize(3);
629
        ds.setMinIdle(2);
646
        ds.setMinIdle(2);
630
        ds.setMaxActive(4);
647
        ds.setMaxActive(4);
-
 
648
        ds.setMaxWait(30000);
631
    }
649
    }
632
 
650
 
633
    public String getToken() {
651
    public String getToken() {
634
        return getProperty("token");
652
        return getProperty("token");
635
    }
653
    }
Line 764... Line 782...
764
        dir.addSQLElement(MotifFinContratSQLElement.class, root);
782
        dir.addSQLElement(MotifFinContratSQLElement.class, root);
765
        dir.addSQLElement(MotifRepriseArretTravailSQLElement.class, root);
783
        dir.addSQLElement(MotifRepriseArretTravailSQLElement.class, root);
766
        dir.addSQLElement(TypePreavisSQLElement.class, root);
784
        dir.addSQLElement(TypePreavisSQLElement.class, root);
767
        dir.addSQLElement(DSNNatureSQLElement.class, root);
785
        dir.addSQLElement(DSNNatureSQLElement.class, root);
768
        dir.addSQLElement(TypeTauxPasSQLElement.class, root);
786
        dir.addSQLElement(TypeTauxPasSQLElement.class, root);
-
 
787
        dir.addSQLElement(CodeAmenagementPartielSQLElement.class, root);
-
 
788
        dir.addSQLElement(CodeSuspensionSQLElement.class, root);
769
 
789
 
770
        // ECO
790
        // ECO
771
        dir.addSQLElement(FamilleEcoContributionSQLElement.class, root);
791
        dir.addSQLElement(FamilleEcoContributionSQLElement.class, root);
772
        dir.addSQLElement(EcoContributionSQLElement.class, root);
792
        dir.addSQLElement(EcoContributionSQLElement.class, root);
773
 
793
 
Line 1110... Line 1130...
1110
    private void setSocieteShowAs() {
1130
    private void setSocieteShowAs() {
1111
        final ShowAs showAs = this.getShowAs();
1131
        final ShowAs showAs = this.getShowAs();
1112
        final DBRoot root = this.getRootSociete();
1132
        final DBRoot root = this.getRootSociete();
1113
        showAs.setRoot(getRootSociete());
1133
        showAs.setRoot(getRootSociete());
1114
 
1134
 
1115
        List<String> listAdrShowAs = SQLRow.toList("RUE,CODE_POSTAL,VILLE");
-
 
1116
        if (root.contains("ADRESSE") && root.getTable("ADRESSE").contains("DISTRICT")) {
-
 
1117
            listAdrShowAs = SQLRow.toList("RUE,DISTRICT,DEPARTEMENT,CODE_POSTAL,VILLE");
-
 
1118
        }
-
 
1119
        showAs.show("ADRESSE", listAdrShowAs);
-
 
1120
 
-
 
1121
        showAs.show("AXE_ANALYTIQUE", "NOM");
1135
        showAs.show("AXE_ANALYTIQUE", "NOM");
1122
 
1136
 
1123
        List<String> lEcr = new ArrayList<String>();
1137
        List<String> lEcr = new ArrayList<String>();
1124
 
1138
 
1125
        lEcr.add("ID_MOUVEMENT");
1139
        lEcr.add("ID_MOUVEMENT");
Line 1206... Line 1220...
1206
        showAs.show("PIECE", "ID", "NOM");
1220
        showAs.show("PIECE", "ID", "NOM");
1207
 
1221
 
1208
        final SQLElementDirectory directory = this.getDirectory();
1222
        final SQLElementDirectory directory = this.getDirectory();
1209
        showAs.show("REPARTITION_ANALYTIQUE", "NOM");
1223
        showAs.show("REPARTITION_ANALYTIQUE", "NOM");
1210
        showAs.show("REGIME_BASE", "ID_CODE_REGIME_BASE");
1224
        showAs.show("REGIME_BASE", "ID_CODE_REGIME_BASE");
1211
        showAs.show("REGLEMENT_PAYE", "NOM_BANQUE", "RIB");
1225
        showAs.show("REGLEMENT_PAYE", "NOM_BANQUE", "IBAN", "BIC");
1212
 
1226
 
1213
        List<String> listFieldModReglMontant = new ArrayList<String>();
1227
        List<String> listFieldModReglMontant = new ArrayList<String>();
1214
        listFieldModReglMontant.add("ID_TYPE_REGLEMENT");
1228
        listFieldModReglMontant.add("ID_TYPE_REGLEMENT");
-
 
1229
        listFieldModReglMontant.add("ID_" + BanqueSQLElement.TABLENAME);
1215
 
1230
 
1216
        showAs.showField("REGLER_MONTANT.ID_MODE_REGLEMENT", listFieldModReglMontant);
1231
        showAs.showField("REGLER_MONTANT.ID_MODE_REGLEMENT", listFieldModReglMontant);
1217
        showAs.showField("ENCAISSER_MONTANT.ID_MODE_REGLEMENT", listFieldModReglMontant);
1232
        showAs.showField("ENCAISSER_MONTANT.ID_MODE_REGLEMENT", listFieldModReglMontant);
1218
 
1233
 
1219
        List<String> listFieldFactureElt = new ArrayList<String>();
1234
        List<String> listFieldFactureElt = new ArrayList<String>();