Commit 1205ba7b authored by Laurent Lecluse's avatar Laurent Lecluse
Browse files

Utilisation de tbl_paiement, raccordement au nouveau calcul aa/ac

parent 56d7219c
Loading
Loading
Loading
Loading
+3 −3
Changes for data/ddl/view/V_ETAT_PAIEMENT.sql: 3 added lines, 3 removed lines.
Original line number Diff line number Diff line
@@ -106,13 +106,13 @@ SELECT
                                df.libelle                                                          domaine_fonctionnel_libelle,
                                CASE WHEN th.code = 'fc_majorees' THEN 0 ELSE mep.heures END        hetd,
                                CASE WHEN th.code = 'fc_majorees' THEN mep.heures ELSE 0 END        fc_majorees,
                                mep.heures * 4 / 10                                                 exercice_aa,
                                mep.heures * 6 / 10                                                 exercice_ac,
                                mep.heures * mis.pourc_exercice_aa                                  exercice_aa,
                                mep.heures * mis.pourc_exercice_ac                                  exercice_ac,
                             --CASE WHEN th.code = 'fc_majorees' THEN 0 ELSE mep.heures END * 4 / 10                                                 exercice_aa,
                             --CASE WHEN th.code = 'fc_majorees' THEN 0 ELSE mep.heures END * 6 / 10                                                 exercice_ac,
                                OSE_FORMULE.GET_TAUX_HORAIRE_HETD( NVL(mep.date_mise_en_paiement,SYSDATE) )      taux_horaire
                         FROM
                              v_mep_intervenant_structure  mis
                                     tbl_paiement mis
                                JOIN mise_en_paiement        mep ON mep.id = mis.mise_en_paiement_id AND mep.histo_destruction IS NULL
                                JOIN type_heures              th ON  th.id = mep.type_heures_id
                                JOIN centre_cout              cc ON  cc.id = mep.centre_cout_id      -- pas d'historique pour les centres de coût, qui devront tout de même apparaitre mais en erreur
+8 −6
Changes for data/ddl/view/V_EXPORT_PAIEMENT_WINPAIE.sql: 8 added lines, 6 removed lines.
Original line number Diff line number Diff line
@@ -54,9 +54,11 @@ FROM (
          mis.intervenant_id,
          mep.heures,
          cc.unite_budgetaire,
          mep.date_mise_en_paiement
          mep.date_mise_en_paiement,
          mis.pourc_exercice_aa,
          mis.pourc_exercice_ac
        FROM
          v_mep_intervenant_structure  mis
          tbl_paiement  mis
          JOIN mise_en_paiement        mep ON mep.id = mis.mise_en_paiement_id AND mep.histo_destruction IS NULL
          JOIN centre_cout              cc ON cc.id = mep.centre_cout_id
          JOIN type_heures              th ON th.id = mep.type_heures_id
@@ -71,13 +73,13 @@ FROM (
        mep.periode_paiement_id,
        mep.intervenant_id,
        2 code_origine,
        mep.heures * 4 / 10 nbu,
        mep.heures * mep.pourc_exercice_aa nbu,
        mep.unite_budgetaire,
        mep.date_mise_en_paiement
      FROM
        mep
      WHERE
        mep.heures * 4 / 10 > 0
        mep.heures * mep.pourc_exercice_aa > 0

      UNION ALL

@@ -87,13 +89,13 @@ FROM (
        mep.periode_paiement_id,
        mep.intervenant_id,
        1 code_origine,
        mep.heures * 6 / 10 nbu,
        mep.heures * mep.pourc_exercice_ac nbu,
        mep.unite_budgetaire,
        mep.date_mise_en_paiement
      FROM
        mep
      WHERE
        mep.heures * 6 / 10 > 0
        mep.heures * mep.pourc_exercice_ac > 0
    ) t1
    GROUP BY
      structure_id,