Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
open-source
OSE
Commits
307d17d8
Commit
307d17d8
authored
Feb 14, 2022
by
Antony Le Courtes
Browse files
Imputation SIHAM
parent
955dc04c
Changes
5
Show whitespace changes
Inline
Side-by-side
data/ddl/view/V_IMPUTATION_BUDGETAIRE_SIHAM.sql
View file @
307d17d8
...
...
@@ -34,9 +34,8 @@ CREATE OR REPLACE FORCE VIEW V_IMPUTATION_BUDGETAIRE_SIHAM AS
domaine_fonctionnel_code
,
hetd
,
hetd_montant
,
rem_fc_d714
rem_fc_d714
,
type_intervenant_id
FROM
(
SELECT
...
...
module/Application/config/paiement.config.php
View file @
307d17d8
...
...
@@ -83,7 +83,7 @@ return [
'route'
=>
'/imputation-siham'
,
'defaults'
=>
[
'action'
=>
'imputationSiham'
,
'etat'
=>
Entity\Db\MiseEnPaiement
::
IMPUTATION_BUDGETAIRE
,
'etat'
=>
Entity\Db\MiseEnPaiement
::
MIS_EN_PAIEMENT
,
],
],
...
...
module/Application/src/Controller/PaiementController.php
View file @
307d17d8
...
...
@@ -407,8 +407,6 @@ class PaiementController extends AbstractController
{
if
(
$recherche
->
getEtat
()
==
MiseEnPaiement
::
A_METTRE_EN_PAIEMENT
)
{
$filename
=
'demande_mise_en_paiement'
;
}
elseif
(
$recherche
->
getEtat
()
==
'imputation-budgetaire'
)
{
$filename
=
'imputation-budgetaire'
;
}
else
{
$filename
=
'etat_paiement'
;
}
...
...
@@ -530,10 +528,9 @@ class PaiementController extends AbstractController
$etatSortie
=
$this
->
getServiceEtatSortie
()
->
getRepo
()
->
findOneBy
([
'code'
=>
'imputation-budgetaire'
]);
//creation d'un privilege specifique aux imputations budgétaire
if
(
$this
->
params
()
->
fromPost
(
'exporter-csv-imputation'
)
!==
null
&&
$this
->
isAllowed
(
Privileges
::
getResourceId
(
Privileges
::
MISE_EN_PAIEMENT_EXPORT_CSV
)))
{
$csvModel
=
$this
->
getServiceEtatSortie
()
->
genererCsv
(
$etatSortie
,
$recherche
->
getFilters
());
$csvModel
->
setFilename
(
$this
->
makeFilenameFromRecherche
(
$recherche
)
.
'.csv'
);
$csvModel
->
setFilename
(
str_replace
(
' '
,
'_'
,
'imputation_siham_'
.
strtolower
(
$recherche
->
getPeriode
()
->
getLibelleAnnuel
(
$recherche
->
getAnnee
()))
.
'_'
.
strtolower
((
$recherche
->
getTypeIntervenant
())
?
$recherche
->
getTypeIntervenant
()
->
getLibelle
()
:
'vactaire_et_permanent'
)
.
'.csv'
)
)
;
return
$csvModel
;
}
else
{
...
...
module/Application/src/Entity/Db/MiseEnPaiement.php
View file @
307d17d8
...
...
@@ -15,7 +15,6 @@ class MiseEnPaiement implements HistoriqueAwareInterface, ResourceInterface
const
A_METTRE_EN_PAIEMENT
=
'a-mettre-en-paiement'
;
const
MIS_EN_PAIEMENT
=
'mis-en-paiement'
;
const
IMPUTATION_BUDGETAIRE
=
'imputation-budgetaire'
;
/**
* @var \DateTime
...
...
module/Application/src/Entity/Paiement/MiseEnPaiementRecherche.php
View file @
307d17d8
...
...
@@ -36,7 +36,6 @@ class MiseEnPaiementRecherche
/**
*
* @return string
...
...
@@ -46,26 +45,32 @@ class MiseEnPaiementRecherche
return
$this
->
etat
;
}
function
setEtat
(
$etat
)
{
if
(
$etat
===
null
||
$etat
===
MiseEnPaiement
::
A_METTRE_EN_PAIEMENT
||
$etat
===
MiseEnPaiement
::
MIS_EN_PAIEMENT
)
{
if
(
$etat
===
null
||
$etat
===
MiseEnPaiement
::
A_METTRE_EN_PAIEMENT
||
$etat
===
MiseEnPaiement
::
MIS_EN_PAIEMENT
||
$etat
===
MiseEnPaiement
::
IMPUTATION_BUDGETAIRE
)
{
$this
->
etat
=
$etat
;
}
else
{
throw
new
\
LogicException
(
'L\'état de mise en paiement "'
.
$etat
.
'" est invalide.'
);
}
else
{
throw
new
\
LogicException
(
'L\'état de mise en paiement "'
.
$etat
.
'" est invalide.'
);
}
return
$this
;
}
/**
*
* @return Intervenant[]
*/
public
function
getIntervenants
()
{
if
(
null
===
$this
->
intervenants
){
if
(
null
===
$this
->
intervenants
)
{
$this
->
intervenants
=
new
Collection
;
$this
->
intervenants
->
initEntityClass
(
Intervenant
::
class
);
$this
->
intervenants
->
initEntityClass
(
Intervenant
::
class
);
}
return
$this
->
intervenants
;
}
...
...
@@ -74,7 +79,7 @@ class MiseEnPaiementRecherche
public
function
getFilters
():
array
{
$filters
=
[];
if
(
$e
=
$this
->
getEtat
()){
if
(
$e
=
$this
->
getEtat
())
{
$filters
[
'ETAT'
]
=
$e
;
}
if
(
$a
=
$this
->
getAnnee
())
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment