Commit graph

88 commits

Author SHA1 Message Date
Colin Darie
010c9a0dcb feat(procedure): includes read duration of explication/non fillable champs
Long explications can significantly increase global fill duration,
so we can't ignore them.

Closes #7963
2022-10-31 12:17:16 +01:00
Colin Darie
fcb478eb53 refactor(fc_info): use Dsfr::Notice for france connect informations 2022-09-21 15:47:35 +02:00
Kara Diaby
3e43597440 tests 2022-09-19 13:34:43 +02:00
Paul Chavard
d35ceb7214 fix(champs): finish EditableChampComponent refactor 2022-09-08 11:26:29 +02:00
Colin Darie
22fed3d9de feat: show entreprise etat "en activité" | "fermé in entreprise summary
Closes #7505
2022-07-25 10:58:02 +02:00
Paul Chavard
d9eea35ae8 fix(dossier): decoralate dropdown behaviour from autosave 2022-07-21 18:40:16 +02:00
Pierre de La Morinerie
3e91a16895 app: display estimated fill duration on procedure description 2022-05-25 10:39:15 +02:00
Paul Chavard
d2ab8b5593 feat(message): replace message partial with MessageComponent 2022-04-26 14:54:58 +02:00
Christophe Robillard
447612abdf fix a11y-8.9.1
no p tag when Champ text with no value
2022-02-02 19:03:40 +01:00
Pierre de La Morinerie
2e1a3c32cb helpers: handle flash[:error]
Errors generated by the `invisible-catcha` gem are reported as
`flash[:error]` (which differs from Rail's usual `flash[:alert]`).

We probably shouldn't use flash[:error] in our own codebase; but we can
handle its use in third-party libraries.
2022-01-06 14:09:31 +01:00
Pierre de La Morinerie
68b112e00a helpers: don't crash on unknown flash level
Errors generated by the `invisible-catcha` gem are reported as
`flash[:error]` (which differs from Rail's usual `flash[:alert]`).

Avoid crashing when the flash level passed to this helper is not known.
2022-01-06 14:09:26 +01:00
Pierre de La Morinerie
970c3e4b2b specs: avoid executing business logic in Procedure factory
Calling business logic in a factory is a code-smell, because it
usually requires the object to be saved into database, and may have
unintended consequences when the business logic is changed.

Also, this allows to just build a published procedure, without saving it
to the database.
2021-11-23 08:07:07 +01:00
Paul Chavard
e74d599042 feat(procedure): remove duree_conservation_dossiers_hors_ds 2021-11-16 19:55:56 +03:00
Christophe Robillard
4fd0ad71c3 add spec for archive weight estimation 2021-06-09 10:52:38 +02:00
François Vantomme
a596df9a4a Test: use APPLICATION_NAME to deal nicely with custom configuration 2021-04-13 22:46:33 +02:00
kara Diaby
64b94100f4 fix dossier link helper 2021-03-18 14:36:08 +01:00
kara Diaby
81f5a5254b tests 2021-03-18 11:38:52 +01:00
Christophe Robillard
f77cc06a91 prend en compte le nom de l'enseigne pour l'établissement 2020-08-20 14:23:02 +02:00
Pierre de La Morinerie
fe8804f208 models: require belong_to associations on individual 2020-08-18 15:57:37 +02:00
clemkeirua
de1df85462 suppression du message d'alerte suite aux problèmes d'upload 2020-07-27 10:32:03 +02:00
Christophe Robillard
8f9d6d2871 show which instructeur took decision and when
and also replace "sans suite" by "classé sans suite"
2020-07-08 18:15:15 +02:00
Christophe Robillard
cce1435faf remove precision for currency 2020-07-01 09:28:18 +02:00
Christophe Robillard
4839506374 refactor instructeur_avis_url 2020-06-30 09:17:27 +02:00
Pierre de La Morinerie
af5b36ea6a helpers: prevent some texts to be incorrectly detected as links
Users were having issues with texts like:

> Pour info: penser à faire cette action.

where `info:` was detected as being an URI.
2020-06-22 14:42:41 +02:00
Christophe Robillard
2fd88e3a17 affiche uniquement l'année pour les bilans 2020-06-09 17:06:08 +02:00
Christophe Robillard
81fa1d0e89 utilise un ordre plus logique pour identite entreprise
homogenise l'affichage des valeurs monétaires
elargit la colonne libellé
2020-06-09 16:59:57 +02:00
Christophe Robillard
75a268aed6 show some info from bilans 2020-06-04 12:33:33 +02:00
Judith
d930124839 change procedure_auto_archive helper name and added a helper for 23 h 59 2020-05-28 13:22:02 +00:00
Judith
38eb60f2ac views: display auto-archive date on procedure description 2020-05-28 13:22:02 +00:00
clemkeirua
7335500be4 tests for dossier_helper#demandeur_dossier 2020-04-10 13:14:39 +02:00
Pierre de La Morinerie
4cb747fdb6 specs: always require rails_helper
Test helpers are separated between two files: spec_helper and
rails_helper. This separation is meant to allow tests that do not
require Rails (like testing standalone libs) to boot faster.

The spec_helper file is always loaded, through `--require spec_helper`
in the `.rspec` config file. When needed, the rails_helper file is
expected to be required manually.

This is fine, but:
- Many test files have a redundant `require 'spec_helper'` line;
- Many test files should require `rails_helper`, but don't.

Not requiring `rails_helper` will cause the Rails-concerned section of
the test environment not to be configured–which may cause subtle bugs
(like the test database not being properly initialized).

Moreover, Spring loads all the Rails files on preloading anyway. So the
gains from using only `spec_helper` are thin.

To streamline this process, this commit:
- Configures `.rspec` to require `rails_helper` by default;
- Remove all manual requires to spec_helper or rails_helper.

Reference: https://stackoverflow.com/questions/24145329/how-is-spec-rails-helper-rb-different-from-spec-spec-helper-rb-do-i-need-it
2020-03-31 12:48:32 +02:00
Pierre de La Morinerie
7ba76c6658 dossier: add a notice when some attachments of the dossier were lost
On the 22/01/2020, a technical error on the demarches-simplifees.fr
instance made us delete some files attached to some dossiers.

This PR adds a warning when browsing a dossier containing attachments
that were deleted.
2020-02-12 11:49:33 +01:00
Pierre de La Morinerie
c7a307553c helpers: allow dossier_display_state to take a state as input
This allow to use either:

- `dossier_display_state(dossier)`
- `dossier_display_state(:en_construction)`
2019-12-19 13:22:40 +01:00
Paul Chavard
7b947feae4 Rename demarche archivée to demarche close 2019-11-28 15:07:16 +01:00
simon lehericey
90ae4181bf fix dossier_linked_path in routed procedure 2019-10-23 21:47:20 +02:00
simon lehericey
b541ef0b41 Procedure has many instructeurs with defaut_groupe_instructeur 2019-09-02 11:41:12 +02:00
Paul Chavard
cc35a04e26 Migrate procedure logo to active_storage 2019-08-21 11:15:00 +02:00
simon lehericey
3fde2a6f70 Rename gestionnaire in code to instructeur 2019-08-12 13:47:01 +02:00
Pierre de La Morinerie
0c4cb3b498 admin: remove UI for managing old pj 2019-07-30 16:11:16 +02:00
Nicolas Bouilleaud
fac20ed190 Fix Commentaire factory so that the default case creates a valid object 2019-07-08 16:13:43 +02:00
pedong
abcd58c35d [fix #3710] date with letter
Co-Authored-By: simon lehericey <mail@simon.lehericey.net>
2019-06-12 17:48:12 +02:00
Mathieu Magnin
8525761332 Revert english dates 2019-04-02 14:38:47 +02:00
pedong
fb29d30826 [fix #3342] show date with format letter 2019-03-27 15:27:20 +01:00
Frederic Merizen
a8ce11a4d2 Add rel=noopener to links with target=_blank
http://support.detectify.com/customer/portal/articles/2792257-external-links-using-target-_blank-
2019-03-05 18:25:26 +01:00
gregoirenovel
b4781f7440 Make dossier link clickable for users in the Demande tab 2019-01-08 12:32:27 +01:00
gregoirenovel
f5a31be36a Remove the now useless #formatted_value method 2019-01-08 12:32:26 +01:00
gregoirenovel
9466442aff Remove the TypeDeChamp decorators 2019-01-03 12:08:25 +01:00
gregoirenovel
9c130c41da Remove ProcedureDecorator 2019-01-03 12:08:25 +01:00
gregoirenovel
b41764ec03 Remove ChampDecorator 2019-01-03 12:08:25 +01:00
gregoirenovel
186e362701 Enable the Layout/SpaceInsideArrayLiteralBrackets 2019-01-03 10:53:50 +01:00