Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Libriciel
web-DPO
Commits
a9fe2dd6
Commit
a9fe2dd6
authored
Jan 08, 2020
by
tguillon
Browse files
Suppression : du système de verrouillage au registre
parent
d03e6ca7
Changes
7
Hide whitespace changes
Inline
Side-by-side
CHANGELOG.md
View file @
a9fe2dd6
...
...
@@ -35,6 +35,7 @@ la création d'un traitement.
### Suppressions
-
Suppression de l'onglet "Information de l'entité" lors de la création, modification et visualisation d'un traitement
-
Suppression du verrouillage des traitements au registre.
1.1.0 - 2019-12-03
...
...
VERSION.txt
View file @
a9fe2dd6
1.
1
.0
1.
2
.0
app/Config/Schema/CreationBase/patchs/1.1.0_to_1.2.0.sql
View file @
a9fe2dd6
...
...
@@ -53,5 +53,6 @@ INSERT INTO etats (libelle, value, created, modified) VALUES
(
'Initialisation du traitement par le DPO'
,
11
,
NOW
(),
NOW
()),
(
'Rédaction du traitement initialisé'
,
12
,
NOW
(),
NOW
());
ALTER
TABLE
organisations
DROP
verrouiller
;
COMMIT
;
app/Controller/FichesController.php
View file @
a9fe2dd6
...
...
@@ -857,6 +857,10 @@ class FichesController extends AppController
* @access public
* @created 04/01/2016
* @version V1.0.0
*
* @modified 08/01/2020
* @version V1.2.0
* @deprecated
*/
public
function
downloadFileTraitement
(
$fiche_id
)
{
...
...
app/Controller/RegistresController.php
View file @
a9fe2dd6
...
...
@@ -60,8 +60,7 @@ class RegistresController extends AppController {
'id'
=>
$this
->
Session
->
read
(
'Organisation.id'
)
],
'fields'
=>
[
'dpo'
,
'verrouiller'
'dpo'
]
]);
$this
->
set
(
compact
(
'organisationActuelle'
));
...
...
@@ -115,17 +114,6 @@ class RegistresController extends AppController {
];
}
// Filtre sur le traitement verrouillées ou non verrouillées
if
(
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
true
)
{
if
(
isset
(
$this
->
request
->
data
[
'Registre'
][
'archive'
]))
{
if
(
$this
->
request
->
data
[
'Registre'
][
'archive'
]
==
'true'
)
{
$condition
[
'EtatFiche.etat_id'
]
=
EtatFiche
::
ARCHIVER
;
}
elseif
(
$this
->
request
->
data
[
'Registre'
][
'archive'
]
==
'false'
)
{
$condition
[
'EtatFiche.etat_id'
]
=
EtatFiche
::
VALIDER_DPO
;
}
}
}
// Filtre sur le nombre de traitement à l'affichage
if
(
!
empty
(
$this
->
request
->
data
[
'Registre'
][
'nbAffichage'
]))
{
$limit
=
$this
->
request
->
data
[
'Registre'
][
'nbAffichage'
];
...
...
@@ -281,12 +269,7 @@ class RegistresController extends AppController {
$formulaires
=
[];
if
(
$this
->
Droits
->
authorized
(
$this
->
Droits
->
isDpo
())
==
true
)
{
if
(
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
true
)
{
$optionsAction
[
1
]
=
__d
(
'registre'
,
'registre.btnImprimerTraitementRegistrePDF'
);
}
else
{
$optionsAction
[
2
]
=
__d
(
'registre'
,
'registre.btnGenererTraitementRegistrePDF'
);
}
$optionsAction
[
2
]
=
__d
(
'registre'
,
'registre.btnGenererTraitementRegistrePDF'
);
$optionsAction
[
3
]
=
__d
(
'registre'
,
'registre.btnExportCsv'
);
}
$this
->
set
(
compact
(
'optionsAction'
));
...
...
app/View/Layouts/default.ctp
View file @
a9fe2dd6
...
...
@@ -951,7 +951,7 @@
echo " / révision " . $revision;
}
}
?>
<a
href=
"https://www.libriciel.fr/"
target=
"_blank"
>
<?php echo "/ © Libriciel SCOP 2006-
2019"
?>
</a>
?>
<a
href=
"https://www.libriciel.fr/"
target=
"_blank"
>
<?php echo "/ © Libriciel SCOP 2006-
" . date('Y');
?>
</a>
</div>
</div>
</div>
...
...
app/View/Registres/index.ctp
View file @
a9fe2dd6
...
...
@@ -229,41 +229,6 @@
?>
</div>
<?php
if
(
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
true
)
{
if
(
$this
->
Autorisation
->
isDpo
()
||
$this
->
Autorisation
->
isSu
())
{
?>
<!-- Filtre sur les formulaires -->
<div
class=
"input-group login"
>
<span
class=
"input-group-addon"
>
<?php
echo
$this
->
Form
->
label
(
'archive'
,
'<!---->'
,
[
'class'
=>
'fa fa-lock fa-lg'
,
'title'
=>
__d
(
'registre'
,
'registre.filtreArchive'
)
]);
?>
</span>
<?php
echo
$this
->
Form
->
input
(
'archive'
,
[
'id'
=>
'archive'
,
'options'
=>
[
'true'
=>
__d
(
'registre'
,
'registre.radioFicheVerouillee'
),
'false'
=>
__d
(
'registre'
,
'registre.radioFicheNonVerouillee'
)
],
'class'
=>
'usersDeroulant transformSelect form-control'
,
'empty'
=>
true
,
'data-placeholder'
=>
__d
(
'registre'
,
'registre.placeholderSelectionnerArchive'
),
'label'
=>
false
]);
?>
</div>
<?php
}
}
?>
<!-- Groupe de bouton -->
<div
class=
"row top30"
>
<div
class=
"col-md-4 col-md-offset-5 btn-group"
>
...
...
@@ -351,32 +316,17 @@
<?php
if
(
$organisationActuelle
[
'Organisation'
][
'dpo'
]
==
$this
->
Session
->
read
(
'Auth.User.id'
))
{
if
(
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
true
)
{
?>
<!--Bouton qui permet de choisir l'ordre de generation pour généré l'extrait de registre -->
<div
class=
"pull-left btnTraitementRegistre"
style=
"margin-left:25px"
>
<button
type=
"button"
class=
"btn btn-default-primary btn_telecharger"
data-toggle=
"modal"
data-target=
"#modalChangerPosition"
>
<span
class=
"fa fa-download fa-lg"
>
<!---->
</span>
<?php
echo
__d
(
'registre'
,
'registre.btnTélécharger'
);
?>
</button>
</div>
<?php
}
else
{
?>
<!--Bouton qui permet de choisir l'ordre de generation pour généré l'extrait de registre -->
<div
class=
"pull-left btnTraitementRegistreNonVerrouiller"
style=
"margin-left:25px"
>
<button
type=
"button"
class=
"btn btn-default-primary btn_telechargerNonVerrouiller"
data-toggle=
"modal"
data-target=
"#modalChangerPosition"
>
<span
class=
"fa fa-cogs fa-lg"
>
<!---->
</span>
<?php
echo
__d
(
'registre'
,
'registre.btnGenerer'
);
?>
</button>
</div>
<?php
}
?>
<!--Bouton qui permet de choisir l'ordre de generation pour généré l'extrait de registre -->
<div
class=
"pull-left btnTraitementRegistreNonVerrouiller"
style=
"margin-left:25px"
>
<button
type=
"button"
class=
"btn btn-default-primary btn_telechargerNonVerrouiller"
data-toggle=
"modal"
data-target=
"#modalChangerPosition"
>
<span
class=
"fa fa-cogs fa-lg"
>
<!---->
</span>
<?php
echo
__d
(
'registre'
,
'registre.btnGenerer'
);
?>
</button>
</div>
<!--Bouton pour l'export csv -->
<div
class=
"pull-left btnExportCsv"
style=
"margin-left:25px"
>
<button
type=
"button"
class=
"btn btn-default-primary btn_exportCsv"
data-toggle=
"modal"
data-target=
"#modalChangerPosition"
>
...
...
@@ -442,17 +392,12 @@
foreach
(
$fichesValid
as
$key
=>
$value
)
{
$numeroRegistre
=
$value
[
'Fiche'
][
'numero'
];
if
(
$value
[
'EtatFiche'
][
'etat_id'
]
!=
7
||
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
false
)
{
if
(
$value
[
'EtatFiche'
][
'etat_id'
]
!=
EtatFiche
::
ARCHIVER
||
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
false
)
{
$iconBtn
=
$this
->
Html
->
tag
(
'i'
,
'<!---->'
,[
'class'
=>
'fa fa-cog fa-lg'
]);
$titleBtn
=
__d
(
'registre'
,
'registre.commentaireGenererRegistrePDF'
);
$DlOrGenerate
=
'genereTraitement'
;
$idExtrait
=
json_encode
([
$value
[
'Fiche'
][
'id'
]]);
}
else
{
$iconBtn
=
$this
->
Html
->
tag
(
'i'
,
'<!---->'
,[
'class'
=>
'fa fa-download fa-lg'
]);
$titleBtn
=
__d
(
'registre'
,
'registre.commentaireTelechargeRegistrePDF'
);
$DlOrGenerate
=
'downloadFileTraitement'
;
$idExtrait
=
$value
[
'Fiche'
][
'id'
];
}
if
(
$value
[
'Fiche'
][
'Valeur'
]
!=
null
)
{
...
...
@@ -694,37 +639,19 @@
<?php
if
(
$this
->
Autorisation
->
isDpo
())
{
if
(
$value
[
'EtatFiche'
][
'etat_id'
]
!=
EtatFiche
::
ARCHIVER
)
{
if
(
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
false
)
{
// Bouton de modification du traitement
echo
$this
->
Form
->
button
(
$this
->
Html
->
tag
(
'i'
,
'<!---->'
,
[
'class'
=>
'fa fa-pencil fa-lg'
]),
[
'class'
=>
'btn btn-default-default boutonEdit btn-sm my-tooltip btn-edit-registre modif_traitement'
,
'id'
=>
$value
[
'Fiche'
][
'id'
],
'escapeTitle'
=>
false
,
'data-toggle'
=>
'modal'
,
'data-target'
=>
'#modalEditRegistre'
,
'title'
=>
__d
(
'registre'
,
'registre.commentaireModifierTraitement'
)
]);
}
// Bouton de modification du traitement
echo
$this
->
Form
->
button
(
$this
->
Html
->
tag
(
'i'
,
'<!---->'
,
[
'class'
=>
'fa fa-pencil fa-lg'
]),
[
'class'
=>
'btn btn-default-default boutonEdit btn-sm my-tooltip btn-edit-registre modif_traitement'
,
'id'
=>
$value
[
'Fiche'
][
'id'
],
'escapeTitle'
=>
false
,
'data-toggle'
=>
'modal'
,
'data-target'
=>
'#modalEditRegistre'
,
'title'
=>
__d
(
'registre'
,
'registre.commentaireModifierTraitement'
)
]);
}
}
?>
</div>
<?php
if
(
$this
->
Autorisation
->
isDpo
()
&&
$value
[
'EtatFiche'
][
'etat_id'
]
!=
7
&&
$organisationActuelle
[
'Organisation'
][
'verrouiller'
]
==
true
)
{
// Bouton de verrouillage du traitement
echo
$this
->
Html
->
link
(
$this
->
Html
->
tag
(
'i'
,
'<!---->'
,[
'class'
=>
'fa fa-lock fa-lg'
]),
[
'controller'
=>
'fiches'
,
'action'
=>
'archive'
,
$value
[
'Fiche'
][
'id'
],
],
[
'class'
=>
'btn btn-default-danger boutonArchive btn-sm my-tooltip'
,
'title'
=>
__d
(
'registre'
,
'registre.commentaireVerouillerTraitement'
),
'escapeTitle'
=>
false
],
__d
(
'registre'
,
'registre.confirmationVerouillerTraitement'
)
);
}
?>
</td>
</tr>
...
...
Write
Preview
Markdown
is supported
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