Pierre de La Morinerie
60c2718f29
models: remove custom code for file size validation message
...
With active_storage_validations 0.9.6, we can use the %{max_size}
variable directly in the error message.
2021-11-24 10:06:45 +01:00
Pierre de La Morinerie
2227dcc1e7
app: remove leftovers of procedure path autocomplete
...
We used to pre-validate the procedure, to display in advance if the path
could be used.
Now that the path autocomplete is long gone, we can remove this kludgy
code.
2021-11-23 14:30:21 +01:00
simon lehericey
5234a1854c
manage AgentConnect callback
2021-11-23 14:17:59 +01:00
simon lehericey
1926a630f9
add agent_connect_id to instructeur
2021-11-23 14:17:59 +01:00
simon lehericey
898df449d4
redirect to AgentConnect
2021-11-23 14:17:59 +01:00
Martin
b6adf5fc72
feat(dossiers/show): enhance header with expirations message/banner. also ensure consistent design between dossier states
...
fix(spec): broken due to last refactoring
spec(dossier.extend_conservation): add system spec
lint(ruby): still not yet ready for auto lint in IDE...
2021-11-23 05:50:25 +01:00
Martin
a9978fb70b
clean(code): move mfo comment to its rightful place
2021-11-19 14:34:20 +01:00
Martin
608a85148f
feat(Dossier.close_to_expiration): add method to find any kind of dossier close to expiration [reuse previous scopes], add missing spec to termine_close_to_expiration, complement spec for each kind of expiration scope with general close_to_expiration spec
2021-11-19 14:28:54 +01:00
Martin
d8257284ef
tech(refactor): extract states close to expiration within their scope.
2021-11-19 14:07:47 +01:00
Martin
1d721f14a0
fix(spec): get back to stable state
2021-11-19 12:36:03 +01:00
Martin
646459a1da
fix(spec): at least let us start from a green suite
2021-11-18 18:15:57 +01:00
Paul Chavard
df474b60cf
WIP
2021-11-18 18:58:17 +03:00
Paul Chavard
ae09b37e72
fix(champs): save departement info on champ commune
2021-11-17 14:52:47 +03:00
mfo
82b23b92c0
Merge branch 'main' into 6624/etq-instructeur-je-souhaite-supprimer-des-messages-envoyes-par-erreur
2021-11-17 05:41:56 +01:00
Paul Chavard
e74d599042
feat(procedure): remove duree_conservation_dossiers_hors_ds
2021-11-16 19:55:56 +03:00
Paul Chavard
04e67ea20a
fix(dossier): add instructeur email to traitements when available
2021-11-16 19:00:20 +03:00
mfo
1d174df2ec
Merge branch 'main' into 6624/etq-instructeur-je-souhaite-supprimer-des-messages-envoyes-par-erreur
2021-11-16 16:37:15 +01:00
Martin
f0950b592b
clean(CommentaireService): extract soft delete within controller. returning an instance with an error[:base] is not persisted with validation : avoid poluting stuff
2021-11-16 16:13:11 +01:00
Martin
8bbd77f89f
refactor(mail.delay): use simplier implementation using after_action to prevent email delivery with delay
2021-11-16 15:12:05 +01:00
Martin
0aecc301c9
refactor(Commentarie.soft_delete): use discard
2021-11-16 14:28:38 +01:00
simon lehericey
e3c1e19424
include hidden dossier in merge
2021-11-15 23:14:41 +01:00
Martin
ddabed0c7e
fix(refactor): continue to revert to past implementation. now use a job instead of calling deliver_later(wait: 5.minutes) [was not a satisfying implementation]
2021-11-15 15:45:48 +01:00
Martin
5534c3fbd6
fix(refactor): forgot to cleanup former implementation
2021-11-15 15:43:51 +01:00
Martin
5b6bb5171c
tech(lint): rubocopify
2021-11-15 15:42:20 +01:00
Martin
c68fa2d7f3
feat(Commentaire.notify_user): wait 5 minutes before sending email to user when instructor write a commentaire. leaving some space for instructor to destroy his message
2021-11-15 15:38:57 +01:00
Martin
46fc956de3
fix(refactor): forgot to pass var, classy
2021-11-15 15:01:56 +01:00
Martin
a74ca8ad39
fix(spec): scope out time as reference for time comparission, hope not a matter of precision
2021-11-15 14:55:35 +01:00
Martin
9a8ec1087c
feat(commentaire.soft_delete): wrap deletion behaviour in service
2021-11-15 12:43:53 +01:00
Martin
5b72bdec7e
fix(Commentaire.sent_by?): &.email compared to nil could sent by true when nil==nil, avoid this one
2021-11-15 12:01:56 +01:00
Martin
b03dc6ad5d
wip(dossiers/messages/_message): poc destroy button with expected ACL support
2021-11-15 11:30:41 +01:00
Paul Chavard
da47f491b3
fix(dossier): nullify close to expiration notice timestamps when changing state
2021-11-11 12:52:58 +01:00
Paul Chavard
faa235d205
fix(dossier): destroy operation logs when destroying an expired dossier
2021-11-11 09:37:09 +01:00
Paul Chavard
71939c650b
fix(export): remove wrong columns from repetition spreadsheets
...
This fix prevent repetition children types de champ from being pulled from cloned procedures. stable_id is stable across revisions but also across cloned procedures.
2021-11-10 20:45:32 +01:00
simon lehericey
17d131b3cc
add has_may requested_merge_from
2021-11-04 16:10:09 +01:00
simon lehericey
b160086cc5
update update_email to allow merge
2021-11-04 16:10:09 +01:00
simon lehericey
6625c6bac3
add requested_merge_into column in user table
2021-11-04 16:10:09 +01:00
Paul Chavard
122cdacbc2
fix(avis): destroy avis for discarded en_construction dossiers
2021-11-04 10:12:44 +01:00
Paul Chavard
f6b8689a97
fix(revisions): fix repetitions export with revisions
2021-11-03 18:20:48 +01:00
Paul Chavard
0e2f09dd6f
fix(dossiers): wrap dossier discard in a transaction
...
By doing this we ensure that deleted_dossier are not created when dossier is not discarded
2021-11-02 18:17:35 +01:00
Paul Chavard
da49a6447f
refactor(repetition): optimize and add a transaction around repetition add row
2021-10-28 14:54:33 +02:00
Paul Chavard
c4b93f8d4a
fix(groupe_instructeur): unfollow dossiers when removed from groupe instructeur
2021-10-28 14:45:52 +02:00
simon lehericey
8fe1e2bf71
wrap merge in transaction
2021-10-28 14:39:13 +02:00
simon lehericey
7935e42109
Add merge log
2021-10-28 14:39:13 +02:00
simon lehericey
3328c9a132
merge move invite as well
2021-10-28 14:39:13 +02:00
simon lehericey
f2ccb39912
merge destroys the old role and account
2021-10-28 14:39:13 +02:00
simon lehericey
1401d163ba
add dependent_destroy to user instructeur / admin / expert roles
2021-10-28 14:39:13 +02:00
simon lehericey
c725999582
move merge method to user
2021-10-28 14:39:13 +02:00
Paul Chavard
1393b7b07b
fix(rebase): fix repetition champ rebase
2021-10-28 13:27:53 +02:00
Paul Chavard
7ebc439630
refactor(drop_down_list_champ): other option
2021-10-27 12:01:15 +02:00
Paul Chavard
8154daf847
refactor(drop_down_list_champ): other option
2021-10-27 12:00:39 +02:00
kara Diaby
f1f2b76a3d
revisions
2021-10-27 12:00:39 +02:00
kara Diaby
dc35d9521f
add other option to liste deroulante champ
2021-10-26 16:11:15 +02:00
Paul Chavard
6e8e0c7b6b
feat(type_de_champ): reflect changes of secondary labels and descriptions
2021-10-26 12:18:01 +02:00
Paul Chavard
d308448f02
feat(type_de_champ): add secondary label and description do linked drop downs
2021-10-26 12:18:01 +02:00
Paul Chavard
579dce8eb6
refactor(user): wrap user destruction in a transaction
2021-10-26 11:16:29 +02:00
Paul Chavard
d5d3995dad
fix(dossier): fix dossier.avis cascade
2021-10-26 11:16:29 +02:00
Paul Chavard
4aa573a75d
fix(transfer): remove discarded dossiers from transfers
2021-10-26 10:41:01 +02:00
Paul Chavard
1561ea82f6
fix(transfer): manually nullify staled transfers references
2021-10-21 13:54:26 +02:00
Paul Chavard
2a3a9dd822
feat(revisions): rebase dossiers brouillons
2021-10-20 17:26:09 +02:00
Paul Chavard
09a09d3fcf
feat(revisions): add rebased_at to champs
2021-10-20 17:26:09 +02:00
Paul Chavard
67e98f79c9
feat(revisions): add stable_id to changes
2021-10-20 17:25:34 +02:00
Paul Chavard
1ca8192864
perf(export): load dossiers.champs in batches
2021-10-20 16:52:38 +02:00
simon lehericey
866df74706
merge admin
2021-10-19 16:12:42 +02:00
simon lehericey
19f81b594b
merge with an existing account by using the password
2021-10-14 14:47:50 +02:00
simon lehericey
f6879eba60
associate_user take a target email
2021-10-14 14:47:50 +02:00
simon lehericey
09f828a6a2
create_merge_token!
2021-10-14 14:47:50 +02:00
simon lehericey
34862f41e0
Add fci valid_for_merge
2021-10-14 14:47:50 +02:00
simon lehericey
2e118a8f5b
allow unattached fci
2021-10-14 14:47:50 +02:00
simon lehericey
6e6635560f
Add merge token to FCI
2021-10-14 14:47:50 +02:00
simon lehericey
6826bf03b0
Sign in with a user linked by france connect sub (openid)
...
instead of looking linked user by email because :
- follows FC recommendation to fetch ds account by openid
- the email is not a valid key as many user can share the same FCI email.
The following scenario is now working
A user A (email: 1@mail.com ) uses FC to connect to DS
=> It is connected as 1@mail.com
Another user B (email: generic@mail.com ) uses FC to connect
=> It is connected as generic@mail.com
The first user A change its FC email to generic@mail.com and connect to DS
=> It is still connected as 1@mail.com
2021-10-14 14:47:50 +02:00
simon lehericey
87de9e38c6
allow draft to be saved with invalid cnaf champ
2021-10-12 14:27:20 +02:00
simon lehericey
7aee944daa
show cnaf tdc when procedure is compatible
2021-10-12 14:27:20 +02:00
simon lehericey
57a7f82a8f
add cnaf ui
2021-10-12 14:27:20 +02:00
simon lehericey
40d0cfcdc4
add champ validation
2021-10-12 14:27:20 +02:00
simon lehericey
c76d1043fa
add cnaf champ
2021-10-12 14:27:20 +02:00
simon lehericey
354735ace4
add champ value_json jsonb column
2021-10-12 14:27:20 +02:00
simon lehericey
d68129b34d
add cnaf type de champ
2021-10-12 14:26:40 +02:00
simon lehericey
7c65571fca
add case when the old_expert or old_instructeur is nil
2021-10-12 11:04:06 +02:00
simon lehericey
d7e621d167
beef up the merge methods
2021-10-07 15:51:31 +02:00
simon lehericey
a480b31eb5
merge expert
2021-10-07 15:51:31 +02:00
simon lehericey
136f29524e
merge instructeur
2021-10-07 15:51:31 +02:00
Paul Chavard
4a947f9135
feat(manager): add become administrateur button in manager (with 24h expiration)
2021-10-07 11:32:12 +02:00
Paul Chavard
9d5c5447c2
fix(dossier): do not attempt to destroy transfers when a dossier is destroyed
...
we had a dependent option on both sides of a relationship which created race conditions
2021-10-06 17:51:09 +02:00
Paul Chavard
d3c1941fbe
fix(dossier): never write dossier log on dossiers brouillons
2021-10-05 17:56:51 +02:00
simon lehericey
1000417bc9
update notifications_for_dossier used in dossier show
2021-10-05 12:05:43 +02:00
simon lehericey
65911b7680
update with_notifications dossiers scope (used in procedure index and show)
2021-10-05 12:05:43 +02:00
simon lehericey
3a878dfc04
add identity_updated_at column to dossier
2021-10-05 12:05:43 +02:00
Pierre de La Morinerie
f01e4ed6ef
models: document upstream PR about file size validation
2021-09-30 15:45:30 +02:00
simon lehericey
6eb10ecde5
display tdc alphabetically 🎉
2021-09-27 15:45:37 +02:00
simon lehericey
f55db98e97
rework type de champ type
2021-09-27 15:45:37 +02:00
Paul Chavard
357c684688
feat(routage): self managing instructeurs
2021-09-27 15:06:17 +02:00
Paul Chavard
d4e8158887
feat(routing): add instructeurs_self_management_enabled to procedures
2021-09-27 15:06:17 +02:00
Ismael MOUSSA S
36dc9c2ca2
Add File Validation concern after refactoring
2021-09-21 12:11:20 -05:00
Ismael MOUSSA S
7c7c9c9ea4
Fix file size validation message
2021-09-21 12:11:20 -05:00
Ismael MOUSSA S
bdbb4deb87
ADD FILE_MAX_SIZE constant to set allow file size limit
2021-09-21 12:04:56 -05:00
Paul Chavard
0ff62c5a5e
feat(routage): add routing_enabled to procedures
2021-09-18 11:22:35 +02:00
Paul Chavard
8b4bef2816
refactor(routage): simplify goupe_instructeur assign code
2021-09-18 11:21:26 +02:00
simon lehericey
b000590d81
add api particulier sources to procedure
2021-09-17 13:50:23 +02:00
simon lehericey
6c6205e188
a cloned procedure to a different admin does not keep api_particulier token and scopes
2021-09-16 09:30:11 +02:00
simon lehericey
2d2ae3a878
add api particulier scopes to procedure
2021-09-16 09:30:11 +02:00
Pierre de La Morinerie
745e19bb8e
localize
2021-09-16 09:07:47 +02:00
Pierre de La Morinerie
e97b7164dd
models: extract password complexity to a concern
2021-09-09 09:40:39 -05:00
Paul Chavard
d6cbdf2a48
feat(dossier): add dossier transfer models
2021-09-08 14:39:46 +02:00
Paul Chavard
44eb0ada4f
fix(i18n): add Kosovo to countries list
...
Kosovo is not part of ISO 3166 as of time of writing. https://en.wikipedia.org/wiki/ISO_3166-2:RS#cite_ref-1
2021-09-08 12:11:25 +02:00
Paul Chavard
a7ec43a21e
fix(i18n): fix email previews
2021-09-08 09:21:19 +02:00
Pierre de La Morinerie
905fca0bd3
models: ensure Champs::Pays#to_s is always a string
...
Before this, the result of `Champs::Pays#to_s` could be `nil`, which
would break various things (like the PDF rendering of these champs).
2021-09-07 10:47:18 -05:00
Paul Chavard
74e277d0a2
feat(graphql): add an option to dossier state change mutations to disable notifications
2021-09-07 14:21:48 +02:00
Paul Chavard
96cbbc0192
fix(virus scan): prevent virus scan on archives and signatures uploads
2021-09-07 14:21:48 +02:00
simon lehericey
367f508e2e
linked_drop_down_list: empty primary => empty secondary
2021-09-07 10:09:18 +02:00
Paul Chavard
ff7fa4d895
feat(i18n): expose locale on dossier and deleted_dossier
2021-09-07 09:51:23 +02:00
Paul Chavard
f1ff6da81b
feat(i18n): add locale to user
2021-09-07 09:47:01 +02:00
Paul Chavard
a3cc072bbd
feat(i18n): translate countries selector
2021-08-31 13:15:26 +02:00
Paul Chavard
8e1bfb469f
fix(dossier): send expiration notifications 2 weeks prior to supression instead of a month
2021-08-26 11:28:57 +02:00
Christophe Robillard
e06f11f33f
add code insee libelle for commune export
2021-08-19 08:04:47 +02:00
Christophe Robillard
4a6c22d6a6
export code insee for commune champ
2021-08-19 08:04:47 +02:00
Christophe Robillard
daa306859c
champ export can be an array of values
2021-08-19 08:04:47 +02:00
Paul Chavard
ffa8c0c80a
feat(dossiers): enable dossiers termine expiration behind feature flag
...
feature flag "procedure_process_expired_dossiers_termine" controls if a procedure has expiration
enabled on dossiers termine
re #3796
2021-08-18 16:11:35 +01:00
Christophe Robillard
93ba0cc038
stats: rend plus explicite le graphe taux d'acceptation
2021-08-11 10:50:26 +02:00
Christophe Robillard
2ee505e9a9
stats: i18n pour legende repartition par semaine
2021-08-10 15:22:36 +02:00
kara Diaby
0300df9a35
add procedure to bulk messages
2021-08-04 11:35:06 +02:00
simon lehericey
b29bae4707
a procedure has an encrypted api_particulier_token
...
Co-authored-by: François VANTOMME <akarzim@gmail.com>
2021-07-30 11:18:44 +02:00
simon lehericey
66c35fdffe
add encryptable_concern
...
Co-authored-by: François VANTOMME <akarzim@gmail.com>
2021-07-30 11:18:44 +02:00
kara Diaby
ab0782530c
create Bulk Message model and migration
2021-07-27 19:38:22 +02:00
kara Diaby
c92b249340
fixup! modify models
2021-07-27 19:38:21 +02:00
Paul Chavard
64cfb4d64e
Fix sort with revisions
2021-07-23 10:57:04 +02:00
Pierre de La Morinerie
0fd23ebd43
db: fix schema.rb leftovers
2021-07-22 17:55:47 +02:00
Paul Chavard
388fb39eb5
Fix false positive blank champ warnings
2021-07-22 10:45:25 +02:00
Paul Chavard
ac0f50b488
Improuve champ blank check
2021-07-22 10:45:25 +02:00
Pierre de La Morinerie
32ab2f0a80
instructeur: limit the maximum size of a filter value
...
This prevents the URL from exceeding the max size, and
causing '414: Request-URI too large' errors.
2021-07-20 14:49:48 +02:00
Pierre de La Morinerie
40b3ea8ad6
Revert "Instructeurs : limitation de la valeur d'un filtre à 100 caractères"
2021-07-13 18:19:46 +02:00
Pierre de La Morinerie
3c8a88a660
instructeur: limit the maximum size of a filter value
...
This prevents the URL from exceeding the max size, and
causing '414: Request-URI too large' errors.
2021-07-08 16:17:22 +02:00
Christophe Robillard
bc07a875eb
integrate a mininum weight for the average dossier weight
...
before this commit, the average dossier weight took account only pieces
justificatives. With this commit, we add a minimum weight for other
files included in an archive like pdf_export, log operations,
attachments added to traitements. This minimum weight is set arbitrary,
from the observation of some random procedures in production
2021-07-06 15:58:45 +02:00
Paul Chavard
ce27999bc3
Refactor clone_attachments
2021-07-01 16:21:46 +02:00
Paul Chavard
280e54b59d
Enable test revisions
2021-07-01 15:59:07 +02:00
Christophe Robillard
66cc0dd08d
Revert "Revert "Expose dossier PDF export as IO""
...
This reverts commit 362093eff0
.
2021-06-24 21:01:59 +02:00
krichtof
362093eff0
Revert "Expose dossier PDF export as IO"
2021-06-24 19:21:37 +02:00
Paul Chavard
b73d504f8d
Expose dossier PDF export as IO
...
Co-authored-by: Christophe Robillard <christophe.robillard@beta.gouv.fr>
2021-06-24 17:49:24 +02:00
Paul Chavard
a4482233b8
[GraphQL] expose deleted dossiers
2021-06-24 11:51:37 +02:00
Paul Chavard
15ff046428
Improuve revision changes messages
2021-06-24 11:39:49 +02:00
Paul Chavard
241eff76a3
Enable publish new revision only if some changes are found
2021-06-24 11:39:49 +02:00
Paul Chavard
0ca5e1abe2
Preview should reflect revision changes
2021-06-24 11:39:49 +02:00
Paul Chavard
8b2c2c6466
Handle carte layers changes
2021-06-24 11:39:49 +02:00
Paul Chavard
35eccb5630
Show separate blocks for types de champ and annotation changes
2021-06-23 09:40:07 +02:00
Paul Chavard
19195008e8
Expose removed types_de_champ in exports
2021-06-23 09:40:07 +02:00
simon lehericey
eadae7af6b
show all available tdc for procedure presentation
2021-06-23 09:40:07 +02:00
Paul Chavard
0d25f52309
Add changed? and compare on ProcedureRevision
2021-06-23 09:40:07 +02:00
Paul Chavard
15e9013264
Set published_at on revision when publishing a procedure
2021-06-23 09:40:07 +02:00
Paul Chavard
f238710044
Add last_month export
2021-06-23 09:23:10 +02:00
Christophe Robillard
7851d6b1cc
archives: count archived dossiers
2021-06-18 08:59:13 +02:00
krichtof
4bda6600b1
explain what percentile constant means
...
Co-authored-by: Pierre de La Morinerie <pierre.de_la_morinerie@beta.gouv.fr>
2021-06-17 16:31:53 +02:00
Christophe Robillard
896190b91e
return nil when no traitement time
2021-06-17 16:31:53 +02:00
Christophe Robillard
887c5cb4a9
correct rubocop offenses
2021-06-17 16:31:53 +02:00
Christophe Robillard
a5ae5af56a
extract NB_DAYS_RECENT_DOSSIERS and PERCENTILE
2021-06-17 16:31:53 +02:00
Christophe Robillard
f2deba733d
use traitement_times to compute usual_traitement_time for recent
...
dossiers
2021-06-17 16:31:53 +02:00
Christophe Robillard
21dd05cc56
less sql queries for usual_traitement_time_by_month
2021-06-17 16:31:53 +02:00
Christophe Robillard
a8840faadb
move stats methods to appropriate concern class
2021-06-17 16:31:53 +02:00
Christophe Robillard
45ffae9eb3
affiche evolution temps de traitement
2021-06-17 16:31:53 +02:00
Christophe Robillard
701b72494d
compute usual traitement time for specific month
2021-06-17 16:31:53 +02:00
Paul Chavard
a2c53ce7ea
format phone numbers
2021-06-15 09:14:55 +02:00
François Vantomme
c9b1095d1e
Refactor (Rubocop): replace map{ … }.compact by filter_map
...
In Ruby 2.7, Enumerable#filter_map has been added.
This cop identifies places where map { … }.compact can be replaced by filter_map.
See: https://docs.rubocop.org/rubocop-performance/cops_performance.html#performancemapcompact
2021-06-11 15:38:09 +02:00
Christophe Robillard
169f254c79
infer champ type from class
2021-06-09 10:52:38 +02:00
Christophe Robillard
6f845508b4
order archive by desc month
2021-06-09 10:52:38 +02:00
Christophe Robillard
5e180268cd
remove one sql query
2021-06-09 10:52:38 +02:00
simon lehericey
f2ba83a704
cout_dossier_termines_by_month for groupe_instructeurs
...
Co-authored-by: Christophe Robillard <christophe.robillard@beta.gouv.fr>
2021-06-09 10:52:38 +02:00
simon lehericey
9e43823f9a
add average_dossier_weight
...
Co-authored-by: Christophe Robillard <christophe.robillard@beta.gouv.fr>
2021-06-09 10:52:38 +02:00
Christophe Robillard
7002811ba5
optim count nb_dossiers per month for archive
...
`Traitement#count_dossiers_termines_by_month` removes n+1 queries
Co-authored-by: LeSim <mail@simon.lehericey.net>
2021-06-09 10:52:38 +02:00
Christophe Robillard
9bb9462b3a
optimise les stats termines by week
2021-06-08 15:23:31 +02:00
Paul Chavard
1888f74b10
Prevent double processing of declarative dossiers
2021-06-04 17:55:40 +02:00
kara Diaby
3555c9696a
modify concern
2021-06-04 15:29:08 +02:00
Paul Chavard
f526e303e8
Apply suggestions from code review
...
Co-authored-by: Pierre de La Morinerie <kemenaran@gmail.com>
2021-06-03 13:11:16 +02:00
Paul Chavard
3fb10fb4b8
Set published_at on revision when publishing a procedure
2021-06-03 13:11:16 +02:00
Paul Chavard
306e5d228d
Add published_at to procedure_revisions
2021-06-03 13:11:16 +02:00
Paul Chavard
05380b9520
Fix destoying discarded procedures
2021-05-27 18:48:56 +02:00
Paul Chavard
9b0dae4cc2
Fix apostrophes ‘ -> ’
2021-05-26 18:05:14 +02:00
Paul Chavard
4922bc88d6
Do not crash when properties is nil
2021-05-26 12:40:07 +02:00
Paul Chavard
dfc46a8736
Enable add descriptions to cadastres
2021-05-26 11:27:09 +02:00
Paul Chavard
179bb5a9fe
Apply suggestions from code review
...
Co-authored-by: Pierre de La Morinerie <kemenaran@gmail.com>
2021-05-25 11:43:38 +02:00
Paul Chavard
acb277e650
Use stable_id when replacing tags
2021-05-25 11:43:38 +02:00
Paul Chavard
3b85ade440
Add compatibility cadsatre layer with old API GEO
2021-05-24 11:57:00 +02:00
Paul Chavard
e74dcb0056
Remove ign feature flag
2021-05-24 11:50:16 +02:00
simon lehericey
b620888597
show only dossier avis
2021-05-20 16:18:04 +02:00
kara Diaby
20933579b0
do not display confidential avis to other experts
2021-05-19 21:30:22 +02:00
Paul Chavard
5f419954b4
Fix dossier deleted user display
2021-05-13 10:43:55 +02:00
Paul Chavard
3f7a2bea9b
Dossier without user should be valid
2021-05-11 17:50:10 +02:00
Paul Chavard
8a74438dc1
Use conservation_extension instead of en_construction_conservation_extension
2021-05-11 17:33:53 +02:00
Paul Chavard
1e0d6ea28f
Rename en_construction_conservation_extension to conservation_extension
2021-05-11 14:08:51 +02:00
simon lehericey
c5f6c9ae1e
fix missing state translation
2021-05-10 11:17:34 +02:00
simon lehericey
8d0082419c
do not know how it worked before
2021-05-05 14:36:34 +02:00
simon lehericey
4dc314d24b
[ fix #6084 ] add db constraints to france_connect_informations table
2021-05-05 14:28:20 +02:00
simon lehericey
50f679746f
do not extract twice the same dossier_id if the dossier is followed twice
2021-05-04 16:38:34 +02:00
Paul Chavard
bcbfcdc537
Revert "Merge pull request #6142 from tchak/enable_brouillon_extend_conservation"
...
This reverts commit 48eb4d9778
, reversing
changes made to 5539d5cb8c
.
# Conflicts:
# app/models/dossier.rb
# db/schema.rb
2021-05-04 16:03:29 +02:00
Christophe Robillard
01f180022b
prend en compte uniquement les pj pour estimer la taille d'un dossier
2021-05-04 12:50:12 +02:00
Paul Chavard
f6508899de
Refactor NotificationMailer
2021-05-04 12:05:06 +02:00
Paul Chavard
a4fd629f4a
Enable user destruction
2021-05-04 12:05:06 +02:00
Paul Chavard
b2a867266a
Allow users to extend conservation on drafts
2021-04-29 19:50:30 +02:00
Christophe Robillard
f40d96fbd2
Revert "Revert "Export de tous les dossier d'une démarche""
...
This reverts commit d9a588b52e
.
2021-04-29 17:29:47 +02:00
krichtof
d9a588b52e
Revert "Export de tous les dossier d'une démarche"
2021-04-29 16:07:18 +02:00
simon lehericey
db23a853a9
fetch all notification at once
2021-04-29 11:23:41 +02:00
simon lehericey
a4e813380a
one query for avis count
2021-04-29 11:23:41 +02:00
simon lehericey
8b73d8804c
fetch all exports at once by groupe_instructeurs_ids
2021-04-29 11:23:41 +02:00
Christophe Robillard
09870c918d
prevent race conditions when creating archives
2021-04-28 11:40:58 +02:00
Christophe Robillard
dfbe004122
rename content_type to time_span_type for archives
2021-04-28 11:40:58 +02:00
Christophe Robillard
8b2849408c
instructeurs can create and download archives
2021-04-28 11:40:58 +02:00
Christophe Robillard
07cc4fa97f
add service to create procedure archive
2021-04-28 11:40:58 +02:00
Christophe Robillard
c25f3c79d9
add archive model
2021-04-28 11:40:58 +02:00
Pierre de La Morinerie
0cb2162a65
db: fix out-to-date Procedure comments
2021-04-27 15:36:22 +02:00
Paul Chavard
2a068fb9b0
Remove user feedback buttons
2021-04-22 15:40:40 +01:00
Paul Chavard
c20ad5ca17
Remove the link between commentaire and user
2021-04-22 15:10:47 +01:00
simon lehericey
553e1d973c
remove old methods
2021-04-22 10:46:04 +02:00
kara Diaby
541a36abbf
Add boolean to procedures table
2021-04-19 10:23:45 +02:00
simon lehericey
e0959cda1e
constantize hot strings
...
- 1131 objects over 4220 (-25%) created in app/
2021-04-16 13:13:22 +02:00
simon lehericey
47f13219ed
Avoid useless TypeDeChamp deserialization
...
- 520 objects overs 4720 (10%) created in app/ (using ?pp=profile-memory&memory_profiler_allow_files=app/)
2021-04-16 13:13:22 +02:00
simon lehericey
e728a3fcb7
include type_de_champ
...
Avoid n+1 when matching champ.stable_id in procedure.presentation.displayed_fields_values
win 2s in the worst 3s scenario
2021-04-16 13:13:22 +02:00
Paul Chavard
ea484b879e
Prevent expert users to be deleted
2021-04-15 16:17:36 +01:00
kara Diaby
663fa50f02
notify expert when a decision is taken on a dossier
2021-04-15 11:29:55 +02:00
Paul Chavard
6d37e1d133
Fix discarded procedures destruction
2021-04-14 12:24:16 +01:00
Paul Chavard
5b56ec425b
Fix discarded dossiers destruction
2021-04-14 12:24:16 +01:00
Paul Chavard
f152c51d12
Remove ignored_columns
2021-04-13 17:00:07 +01:00
simon lehericey
76e261691a
add data column to france_connect_infromations
2021-04-13 09:59:28 +02:00
simon lehericey
cd6cb99c3c
add bypass_email_login_token to instructeur
2021-04-13 09:43:38 +02:00
simon lehericey
594cda3ee3
Remove previous attempt but steal its spec
2021-04-13 09:32:48 +02:00
simon lehericey
6055fd1b0b
remove for_procedure
2021-04-13 09:32:48 +02:00
simon lehericey
430acb1cb0
Fetch all count at once (- 400ms on pass culture)
2021-04-13 09:32:48 +02:00
simon lehericey
b24faae7e3
remove obsolete procedure_id column in assign_to table
2021-04-09 11:41:13 +02:00
Paul Chavard
5a7312f775
Ensure address to_s never returns nil
2021-04-08 16:43:45 +01:00
Paul Chavard
651a928b7c
Improuve export UI
2021-04-08 14:40:26 +01:00
Paul Chavard
371d612fdb
Remove unused columns
2021-04-08 12:43:29 +01:00
Paul Chavard
5e5122a436
Prevent crash in preview where there is no siblings
2021-04-06 18:15:29 +01:00
Paul Chavard
2702660d72
Update app/models/champs/header_section_champ.rb
...
Co-authored-by: Pierre de La Morinerie <kemenaran@gmail.com>
2021-04-06 10:45:16 +01:00
Paul Chavard
4feda01b6f
Show section numbers only if none of sections start with numbers
2021-04-06 10:45:16 +01:00
kara Diaby
60c06b6d8c
add revoked at to experts_procedures
2021-04-06 10:39:22 +02:00
Pierre de La Morinerie
3499f5af9a
models: remove invalid Dossier ↔︎ Champ inverse relationship
...
`Dossier.champs` is not really an inverse of `Champs.dossier`: when a
Champ record is created, it should not always be added to dossier.champs
(for instance if the champ is private).
NB: this breaks the workaround we added in #3907 to fix the parent
dossier not being touched in some cases (the workaround was to add an
inverse relationship, but we now have to remove it).
The new workaround is to watch for `changed_for_autosave?` on champs.
Unlike `changed?`, `changed_for_autosave?` also detects changes to
attachments. This allows us to touch both `last_champ_updated_at` and
`updated_at` in a single pass.
2021-04-06 10:26:17 +02:00
Paul Chavard
7f3d4a26ad
Make exports#key not-null
2021-04-02 17:42:24 +01:00
Paul Chavard
fd48b86b7f
Simplify export unicity check and use create_or_find_by
2021-04-01 21:14:16 +01:00
Pierre de La Morinerie
798b4a65cc
models: fix db structure comment in etablissement.rb
...
The column is not removed yet, but it is ignored.
2021-03-30 10:45:31 +02:00
Paul Chavard
23104f15a4
Fix export n+1 queries
2021-03-25 19:22:12 +01:00
Pierre de La Morinerie
3f3d6ae399
controllers: use template:
rather than file:
to render PDFs
...
ActionView now throws an error if a relative path is used with `file:`.
2021-03-25 13:24:53 +01:00
kara Diaby
2930de1015
remove useless code in models
2021-03-24 17:47:24 +01:00
kara Diaby
71973de17c
remove useless columns from the db
2021-03-24 16:20:44 +01:00
Paul Chavard
0b22788d60
experts_procedure should not be optional
2021-03-23 13:46:33 +01:00
Paul Chavard
84214f4bd4
Do not export non exportable champs on draft procedures
2021-03-23 09:55:37 +01:00
Kara Diaby
38837443aa
Merge branch 'main' into fix-experts-lookup
2021-03-18 20:46:56 +01:00
Pierre de La Morinerie
239169e925
dossier: fix looking-up avis from Expert
...
This line causes an error on Rails 6.1.
And it isn't even necessary: this line is supposed to query avis where
the expert advice has been requested – but this is handled by the
`if expert.dossiers.include?(self)` condition just above.
2021-03-18 17:59:30 +01:00
Paul Chavard
1449fbbe67
Fix multiple_drop_down_list mandatory check
2021-03-18 15:22:28 +01:00
kara Diaby
5e88ecc24c
improve request to find an expert
2021-03-18 11:38:53 +01:00
kara Diaby
328c2a8e3c
change email to display for expert
2021-03-18 11:38:52 +01:00
kara Diaby
e7945594cf
eager_load for expert
2021-03-18 11:38:52 +01:00
kara Diaby
38740d1b5b
modify experts avis controllers, concern and serializer
2021-03-18 11:38:52 +01:00
kara Diaby
c55e4d0d98
remove unused instructeur logic
2021-03-18 11:38:52 +01:00
kara Diaby
54d414b3b7
add expert to export
2021-03-18 11:27:51 +01:00
kara Diaby
d47fde3fcb
add polymorphic relation to claimant on avis table
2021-03-18 11:27:51 +01:00
kara Diaby
d2ab2debb6
add expert logic
2021-03-18 11:27:51 +01:00
Christophe Robillard
60cc4d3697
add pdf to pjs export
2021-03-16 15:13:17 +01:00
Paul Chavard
76aa7bdfe3
Add default nil value for numero_tva_intracommunautaire
2021-03-16 12:57:10 +01:00
Pierre de La Morinerie
75a1046315
active_storage: refactor concerns
...
Follow-up of #5953 .
Refactor the concerns with two goals:
- Getting closer from the way ActiveStorage adds its own hooks.
Usually ActiveStorage does this using an `Attachment#after_create`
hook, which then delegates to the blob to enqueue the job.
- Enqueuing each job only once. By hooking on `Attachment#after_create`,
we guarantee each job will be added only once.
We then let the jobs themselves check if they are relevant or not, and
retry or discard themselves if necessary.
We also need to update the tests a bit, because Rails'
`perform_enqueued_jobs(&block)` test helper doesn't honor the `retry_on`
clause of jobs. Instead it forwards the exception to the caller – which
makes the test fail.
Instead we use the inline version of `perform_enqueued_jobs()`, without
a block, which properly ignores errors catched by retry_on.
2021-03-16 11:49:14 +01:00
Paul Chavard
a7fb7bf1ef
Add geo json validation
2021-03-11 15:51:09 +01:00
Paul Chavard
d24ee27cac
Try to reduce the number of external data fetches
...
Only fetch external data if the external_id is the current one and data is not yet fetched
2021-03-11 14:56:37 +01:00
kara Diaby
6383e6b9e7
Revert "Revert "Claimant type to avis table""
...
This reverts commit f4fd220d43
.
2021-03-10 08:48:55 +01:00
Paul Chavard
70500e3d56
Groupe instructeur selector default blank
2021-03-09 14:47:23 +01:00
Paul Chavard
9c3e72c84a
Use revision instead of groupe instructeur as dossier procedure link
2021-03-09 14:47:23 +01:00
Kara Diaby
f4fd220d43
Revert "Claimant type to avis table"
2021-03-09 13:40:10 +01:00
kara Diaby
af4a27f4e0
add claimant type on avis table
2021-03-07 22:47:24 +01:00
Christophe Robillard
6169399a6b
fix limit date for notice validation
2021-03-05 08:34:39 +01:00
Pierre de La Morinerie
b0735aafe0
config: fix DynamicSmtpSettingsInterceptor warning again
...
This warning re-appeared when running mailer tests:
```
DISABLE_SPRING=1 bin/rspec spec/mailers/administration_mailer_spec.rb
```
It is now fixed properly, in a way recommanded by the documentation.
2021-03-04 22:52:19 +01:00
Christophe Robillard
7f496c43e5
no validation for old procedures
2021-03-04 16:13:19 +01:00
Pierre de La Morinerie
2f948f7e46
active_storage: fix blob update hooks
...
For some reason on Rails 6.1 the `after_update_commit` hook is properly
registered – but disappears from the record later, and in the end is
never run.
Fix it by using the general `after_commit` hook instead.
2021-03-04 14:30:38 +01:00
Paul Chavard
f31096b33e
When procedure is reset delete only draft revision dossiers
2021-03-04 13:10:58 +01:00
Paul Chavard
600f49a0ff
Hide groupe instructeur selector when routage is done via API
2021-03-04 11:06:04 +01:00
Paul Chavard
1c811083c0
Cleanup feature flags usage
2021-03-04 11:06:04 +01:00
Pierre de La Morinerie
9537342c06
procedure: fix query for finding champs without stable_id
...
It would break on ActiveRecord 6.1.
2021-03-04 09:54:22 +00:00
Paul Chavard
5d4f025be0
Rename for consistency with defaut_groupe_instructeur
2021-03-04 10:45:02 +01:00
Paul Chavard
89ec3923f2
Defaut groupe instructeur ordered by label
2021-03-04 10:35:44 +01:00
Paul Chavard
96a832bc19
Add SerializerService
2021-03-02 12:42:22 +01:00
Paul Chavard
bb072ba9e9
Add id argument to most collections on dossier
2021-03-02 12:42:22 +01:00
Pierre de La Morinerie
9f676c76e1
config: fix zeitwerk warning about DynamicSmtpSettingsInterceptor
...
Fix a warning when running tests:
> DEPRECATION WARNING: Initialization autoloaded the constant DynamicSmtpSettingsInterceptor.
>
> Being able to do this is deprecated. Autoloading during initialization is going
to be an error condition in future versions of Rails.
>
> Reloading does not reboot the application, and therefore code executed during
> initialization does not run again. So, if you reload DynamicSmtpSettingsInterceptor, for example,
> the expected changes won't be reflected in that stale Class object.
>
> This autoloaded constant has been unloaded.
>
> Please, check the "Autoloading and Reloading Constants" guide for solutions.
However if we fix as recommanded, the interceptor will get added
each time the classes are reloaded. And as the actual class instance
changed after the reloading, they won't be de-duplicated – *and*
there's no way to remove the old interceptor without having a reference
to the (now-deleted) class.
Instead we load the interceptor once, and add a message about the class
not being auto-reloaded.
2021-02-24 19:00:29 +01:00
Paul Chavard
92158cecb6
fix constant
2021-02-19 11:29:08 +01:00
Paul Chavard
75392272fb
Add champ address model
2021-02-17 19:10:16 +01:00
Paul Chavard
7eee14feef
Add ChampFetchExternalDataJob
2021-02-17 19:10:16 +01:00
Christophe Robillard
d55f156aec
admin: durée de conservation des données hors ds n'est plus demandée
...
La colonne est tout de même gardée en base
2021-02-17 16:41:57 +01:00
kara Diaby
7b4ec486ec
change active record request to get expert list
2021-02-16 09:46:18 +00:00
Paul Chavard
9ce07be1ee
[GraphQL] modifier annotation
2021-02-11 17:45:14 +01:00
Pierre de La Morinerie
819325c761
zeitwerk: move our Array extension to initializers/core_ext
2021-02-11 12:30:43 +01:00
Christophe Robillard
966ee33529
ignore when FranceConnect calls callback 2 times
2021-02-10 18:13:47 +01:00
Christophe Robillard
a288a13805
disable france connect authentication for admin and instructeurs
2021-02-10 18:13:47 +01:00
Pierre de La Morinerie
150ddab660
zeitwerk: Api -> API
2021-02-09 13:07:30 +01:00
Pierre de La Morinerie
4ad9adc510
models: fix Ruby 2.7 arguments passing
...
Arguments to an ActiveRecord scope will always been passed as a
Dictionnary. Thus
`Dossier.with_notifiable_procedure(notify_on_closed: true)` will trigger
a Ruby 2.7 warning:
> /ruby/2.7.0/gems/activerecord-6.0.3.4/lib/active_record/relation.rb:412: warning: Using the last argument as keyword parameters is deprecated; maybe ** should be added to the call
Fix the issue by always expecting a Dictionary (rather than keyword
arguments).
2021-02-09 09:20:46 +01:00
Paul Chavard
a591d5528e
Add job exception log methods to champ and dossier
2021-02-05 18:56:27 +01:00
Paul Chavard
78a07ef021
Add job exception logs to dossier and champ
2021-02-04 19:27:27 +01:00
Judith
6d89a83d14
unused locales clean-up
2021-02-04 12:15:13 +01:00
Paul Chavard
41c3a98d7d
Update Raven references to use Sentry
2021-01-28 19:46:36 +01:00
Paul Chavard
a26537c77d
Make some api entreprise fields optional
2021-01-27 11:53:00 +01:00
Paul Chavard
03ddd17884
Ignore entreprise_id on etablissements
2021-01-27 11:53:00 +01:00
kara Diaby
9b8d2f6fd3
instead of call Avis table, we now call Experts Procedure table to see the experts list
2021-01-26 13:59:10 +01:00
kara Diaby
85242e118b
add an email method to expert model
2021-01-26 13:59:09 +01:00
Paul Chavard
4452b2cf45
fix order of types de champ on procedure
2021-01-26 10:45:34 +01:00
kara Diaby
b683c2023b
add expert to avis table
2021-01-22 14:31:02 +01:00
kara Diaby
da067597ab
Add create expert method
2021-01-20 18:03:05 +01:00
simon lehericey
d409a9a6c5
Procedure and expert link
2021-01-20 18:03:05 +01:00
simon lehericey
29e9f2dd32
Ajout du model expert
...
Co-authored-by: Kara Diaby <kdiaby.pro@gmail.com>
2021-01-20 18:03:05 +01:00
simon lehericey
685534e827
Add content validation for avis and messages
2021-01-18 17:23:08 +01:00
simon lehericey
d72f0c6dd2
Add authorized content type for pj
2021-01-18 17:23:08 +01:00
simon lehericey
da71031801
add skip_content_type_pj_validation attr to pj
2021-01-18 15:12:17 +01:00
Paul Chavard
97ce8f312b
Use external_id to fetch annuaire_education data
2021-01-15 11:50:02 +01:00
Paul Chavard
09a3cacd88
Add external_id to champs
2021-01-15 11:50:02 +01:00
Paul Chavard
54f2084aef
Add annuaire_education champ
2021-01-14 17:57:48 +01:00
Paul Chavard
a1643dad84
Add data column to champ
2021-01-14 17:31:37 +01:00
Paul Chavard
082b4830f3
Fix a crash when champ carte has no options
2021-01-12 14:47:20 +01:00
Paul Chavard
f33544f067
Fix type_de_champ repetition revision after clone
...
fix #5769
2021-01-12 10:57:34 +01:00
simon lehericey
d43c7364fc
add image to notice and deliberation valid content type
2021-01-04 15:13:26 +01:00
kara Diaby
2b06ee95e1
Add a method to retrieve all invited experts for all procedure dossiers
2020-12-21 14:55:51 +01:00
Paul Chavard
09128cb85e
Add titre identite champ to GraphQL
2020-12-17 17:23:34 +01:00
Paul Chavard
a9a4f6e2a8
Add migration task to use stable_id in filters
2020-12-17 10:51:09 +01:00
simon lehericey
024cc70667
human_value use stable_id ?
2020-12-17 10:51:09 +01:00
simon lehericey
4960eda5cb
use stable id
2020-12-17 10:51:09 +01:00
simon lehericey
f07b395d95
sort : remove superfluous return
2020-12-17 10:51:08 +01:00
simon lehericey
f37c27a243
nicer find_field
2020-12-17 10:51:08 +01:00
simon lehericey
e5da1d7111
move remove_filter
2020-12-17 10:51:08 +01:00
simon lehericey
4241ea05f3
move add_filter
2020-12-17 10:51:08 +01:00
simon lehericey
e3ee756da4
move update_sort
2020-12-17 10:51:08 +01:00
simon lehericey
b7a43f3f44
move update_displayed_fields to procedure_presentation
2020-12-17 10:51:08 +01:00
simon lehericey
cbccdea8e0
move displayed_fields for select to procedure_controller
2020-12-17 10:51:08 +01:00
simon lehericey
55998b1284
remove unused dossier_field service
2020-12-17 10:51:08 +01:00
kara Diaby
c7643154d1
final optims after sim review
2020-12-16 15:00:26 +01:00
kara Diaby
f3c4040d2d
add grace period to deleted dossiers
2020-12-16 15:00:26 +01:00
kara Diaby
00b5ad7a10
EQT instructeur, je peux supprimer un dossier terminé
2020-12-16 15:00:26 +01:00
Christophe Robillard
3428c58b9e
extract password complexity validator
...
for user and superadmin
2020-12-15 16:26:09 +01:00
Christophe Robillard
15a395fbc7
superadmin: check complexity password server side
2020-12-15 16:26:09 +01:00
simon lehericey
a941626d45
factorize read_attachment
2020-12-14 14:09:15 +01:00
simon lehericey
38a5847ca4
rewind io before reading to allow multiple read
2020-12-14 14:09:15 +01:00
Fabrice Gangler
064ea776c7
allow default logo of a procedure to be configured in .env file
...
Refs: #5795
2020-12-14 13:41:10 +01:00
simon lehericey
5a9cd71783
fix bill signature
2020-12-11 15:49:05 +01:00
Paul Chavard
3c6e30a326
Show titre identite link only once watermark is added
2020-12-10 16:50:03 +01:00
Paul Chavard
48e7822e34
Remove titres identite after a dossier is processed
2020-12-10 15:21:25 +01:00
Paul Chavard
eaa9b1c071
Expose all optional layers in TypeDeChamp editor
2020-12-10 11:26:16 +01:00
Paul Chavard
cad8ee31d8
Remove legacy geo sources
2020-12-10 11:26:16 +01:00
Christophe Robillard
23ae528c6b
affiche Madame ou Monsieur
...
mais continue à enregistrer en base Mme ou M.
2020-12-08 21:30:54 +01:00
Christophe Robillard
2066e3db87
rend plus compréhensible la civilité
2020-12-08 18:31:38 +01:00
Christophe Robillard
a8ed9ef172
remove dead code
2020-12-08 13:09:08 +00:00
Paul Chavard
b48e7813d2
Put watermark code behind a feature flag
2020-11-25 16:19:06 +01:00
Paul Chavard
371179dc5b
Watermark titres identite
2020-11-25 16:19:06 +01:00
kara Diaby
d9dea779ea
Remove foreign key dossier on dossier operations logs
2020-11-17 16:02:53 +01:00
kara Diaby
06f6cf7771
add new columns to deleted dossiers
2020-11-12 12:18:59 +01:00
kara Diaby
c033ef0910
Ajoute a l'information de connexion France Connect dans les informations du dossier ainsi que sur la demande usager
2020-11-05 19:30:13 +01:00
Christophe Robillard
5562e65bf3
refacto: rename administration to super_admin
2020-11-05 16:03:55 +01:00
Christophe Robillard
a88172eb01
configure otp_secret_key secret
2020-11-05 16:03:55 +01:00
Christophe Robillard
2a0ebd062a
enable 2FA for manager
...
when trying to access manager, if superadmin did'nt enable otp, he/she is redirected to a page to enable 2FA. When superadmin is enabling 2FA, he has to to scan a qrcode with the 2FA application client. And afterwards, the superadmin has to log in with email, password and OTP code.
2020-11-05 16:03:55 +01:00
Christophe Robillard
305ccdc0cd
add recoverable and two_factor stragegy for administration
2020-11-05 16:03:55 +01:00
Christophe Robillard
6c2eb22960
remove github authentication for manager
2020-11-05 16:03:55 +01:00
clemkeirua
30dfe7fbd0
fix a_suivre
2020-11-04 11:07:53 +01:00
clemkeirua
89316c0689
fix counter for dossiers suivis/à suivre when unfollow
2020-10-28 13:51:35 +00:00
clemkeirua
b4910c557d
ajout de procedure.dossiers_count_for_instructeur
2020-10-28 13:51:35 +00:00
clemkeirua
47181ca80b
remove assert_matching_procedure
2020-10-28 13:51:35 +00:00
Paul Chavard
7c58f06c60
always validate geometries returned from api
2020-10-08 16:03:28 +02:00
Paul Chavard
0aa06d0197
[GraphQL] expose dossier pdf, geojson and attestation
2020-10-06 21:54:43 +02:00
simon lehericey
4af8bd47ac
cache landing data
2020-10-06 16:12:01 +02:00
simon lehericey
ad01d4dee5
really faster stats by precomputing some of them
2020-10-06 16:12:01 +02:00
kara Diaby
73399ae072
Fixe le nombre de caractères maximum dans l'url de la démarche (back end)
2020-10-06 14:26:14 +02:00
Paul Chavard
59086cc728
Fix geo length computations
2020-10-01 15:09:38 +02:00
Paul Chavard
4dfc1c719f
Fix geo areas computations
2020-10-01 15:09:38 +02:00
kara Diaby
57adb90c8f
add the possibility for administrator to refuse external review on a specific procedure
2020-10-01 10:55:19 +02:00
clemkeirua
9019a8b380
ensure a dossier_id is set if possible
2020-09-30 16:50:28 +02:00
Paul Chavard
1bd59c72e5
Include in exports types_de_champ from all revisions
2020-09-30 13:42:38 +02:00
clemkeirua
4fc038fe1b
use after_create instead of after_save
2020-09-29 18:15:38 +00:00
clemkeirua
d23b1136ad
send invite notifications using a hook
2020-09-29 18:15:38 +00:00
clemkeirua
dd7840cdc4
Notify new draft after dossier commit
2020-09-29 18:15:38 +00:00
simon lehericey
29ef5e6785
compute async only after create
2020-09-29 14:00:31 +02:00
simon lehericey
5ed491b958
export are kept for 1 hour
2020-09-29 13:59:57 +02:00
clemkeirua
9b324614b8
transform_values instead of map+to_h
2020-09-25 12:53:11 +00:00
clemkeirua
eb46cc6425
piecejusticative file validation focus on size
2020-09-25 09:35:16 +00:00
clemkeirua
c155de1d7e
ajout de la liste des extensions
2020-09-25 09:35:16 +00:00
clemkeirua
31d48c2879
validation is enableed only for 'new' procedures
2020-09-25 09:35:16 +00:00
clemkeirua
0d88674cea
better translations
2020-09-25 09:35:16 +00:00
clemkeirua
8711e8f911
reenable validator on piece_justificative
2020-09-25 09:35:16 +00:00
clemkeirua
d617a4b252
create export after commiting the export object
2020-09-24 18:56:22 +00:00
clemkeirua
c19b653581
higher level length sanitization for worksheet length
2020-09-24 14:59:46 +02:00
Paul Chavard
26a6e18cb9
Do not crash when rgeo can’t calculate polygon area
...
example are “hourglass” shaped polygons
2020-09-23 16:52:08 +02:00
Paul Chavard
61c315b276
Fix geo area point coordinates display
2020-09-23 16:52:08 +02:00
kara Diaby
cb4e91c405
Add iban type de champ
2020-09-23 15:56:26 +02:00
Paul Chavard
973973ab6a
Do not enqueue web hooks for empty urls
2020-09-22 17:03:19 +02:00
Paul Chavard
c9f2224991
Remove ignored_columns from type_de_champ
2020-09-22 11:28:48 +02:00
Paul Chavard
3d3d0259a0
Remove TypeDeChamp.to_stable_id
2020-09-22 11:28:48 +02:00
Paul Chavard
a3f3b8a8e0
procedure.dossiers through revisions
2020-09-22 10:55:17 +02:00
Paul Chavard
a911a71db9
Log dossier archiver/desarchiver operations
2020-09-22 08:34:38 +00:00
Paul Chavard
50c0955465
Avoid an error if area can’t be computed
2020-09-22 09:12:55 +02:00
clemkeirua
f96377d878
refactor Dossier#with_notifications
2020-09-21 08:28:42 +00:00
clemkeirua
d01a53eb72
remove :cached_notifications gate
2020-09-21 08:28:42 +00:00
kara Diaby
5c68d75107
add titre_identite champ
2020-09-18 14:57:08 +02:00
clemkeirua
1e32a3c11f
add complexity check to admin account creation
2020-09-18 11:16:34 +02:00
clemkeirua
5a8fbde0e7
remove dead code in admin model
2020-09-18 11:16:34 +02:00
clemkeirua
de3118bc7b
force password reset on admin promotion or creation
2020-09-17 16:39:13 +02:00
clemkeirua
0307beecd6
Revert "Merge pull request #5576 from tchak/soft-delete-users"
...
This reverts commit bf0d3914ce
, reversing
changes made to 503527459e
.
2020-09-17 15:39:16 +02:00
Paul Chavard
a0dd3604a4
User discard_and_anonymize!
2020-09-17 11:16:56 +02:00
Paul Chavard
337b20661a
Add discared_at to users
2020-09-17 11:16:56 +02:00
clemkeirua
01ac4d7e19
remove operation_log_serialize_subject
2020-09-17 09:24:50 +02:00
Paul Chavard
bbcdff0ccf
Use IGN plan v2 and add MNHN data sources
2020-09-15 14:39:02 +02:00
simon lehericey
e4de522b48
only retrieve id of procedures with notifications
2020-09-11 09:43:04 +00:00
clemkeirua
3697c610b6
make polynesia mobile phone number valid
2020-09-09 09:00:07 +02:00
clemkeirua
c7b96d3d43
add feature-flip for instructeurs on cached notifications
2020-09-08 15:40:42 +00:00
clemkeirua
52ea5ef89a
make Dossier#with_notifications great again
...
Co-authored-by: Christophe Robillard <christophe.robillard@beta.gouv.fr>
2020-09-08 15:40:42 +00:00
Paul Chavard
91bc2db594
Expose revisions on GraphQL API
2020-09-08 10:54:13 +02:00
clemkeirua
61cf33e3ca
remove duplicate private champ
2020-09-04 15:40:23 +02:00
Paul Chavard
6d4425885d
Fix champ order joins sql error
2020-09-03 18:32:43 +02:00
Paul Chavard
11a1e44fbe
Remove procedure_id from type_de_champ
2020-09-03 15:23:58 +02:00
Paul Chavard
d1de1587d3
Always serialize type_de_champ stable_id as id
2020-09-03 15:23:58 +02:00
kara Diaby
ae61c279af
migrate emails text editor to new interface
2020-09-03 14:42:22 +02:00
Paul Chavard
5ceae8235b
Ignore type_de_champ procedure_id
2020-09-02 11:26:26 +02:00
Paul Chavard
ec72fdd164
Remove migration service
2020-09-02 11:26:26 +02:00
Christophe Robillard
090a247ba9
validates phone champ server side
2020-08-20 15:33:03 +02: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
a7361fdbd3
models: require belong_to associations on mail templates
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
29e8c43e5e
models: require belong_to associations on groupe_instructeur
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
5a7bd24fba
models: require belong_to associations on type_de_champ
...
- Make `type_de_champ.procedure` a requirement;
- Move the procedure_id assignation to `before_validation` (otherwise
the record is invalid, and never gets saved);
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
6328011f60
models: require belong_to associations on champ
...
- Make `champ.dossier` a requirement;
- Move the dossier_id assignation to `before_validation` (otherwise
the record is invalid, and never gets saved);
- Allow specs to only build the champ (instead of saving it to the
database), which bypasses the requirement to have a dossier.
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
eb22dc9d8f
models: require belong_to associations on module_api_carto
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
71d9774d58
models: require belong_to associations on trusted_device_token
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
d807700c7b
models: require belong_to associations on traitement
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
059c147ffc
models: require belong_to associations on service
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
ce53e219e0
models: require belong_to associations on procedure_presentation
...
Some tests are still failing
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
802d3804f5
models: require belong_to associations on invite
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
fe8804f208
models: require belong_to associations on individual
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
afb1c33154
models: require belong_to associations on geo_area
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
aff2713032
models: require belong_to associations on follow
2020-08-18 15:57:37 +02:00
Pierre de La Morinerie
91619b16e8
models: require belong_to associations on feedback
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
79fcf5e814
models: require belong_to associations on exercice
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
51d392a1dc
models: require belong_to associations on dossier
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
01248022bf
models: require belong_to associations on deleted_dossier
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
dd1bed9340
models: require belong_to associations on commentaire
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
32e55a6d37
models: require belong_to associations on avis
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
aefdd5d2a1
models: require belong_to associations on attestation_template
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
1ea4c2aa36
models: require belong_to associations on attestation
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
c1e2928ce7
models: require belong_to associations on assign_to
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
11456109c0
models: explicitly mark optional belongs_to
relationship as so
...
This prepares making the `belongs_to` relationship required by default.
2020-08-18 15:57:36 +02:00
Pierre de La Morinerie
c01d640997
models: return procedure revisions in deterministic order
...
Fixes a randomly-failing spec in spec/models/procedure_revision_spec.rb.
2020-08-13 17:27:37 +02:00
Pierre de La Morinerie
2892fdbeef
models: remove columns that have been deleted from db schema
...
These columns are gone, so we can't stop ignoring them.
2020-08-12 12:06:58 +02:00
Pierre de La Morinerie
6d28069539
models: generate annotations
2020-08-12 11:45:53 +02:00
Pierre de La Morinerie
8962db38cc
models: render attestations in a simpler way
...
The older method of instanciating an entire new rendering stack can be
made simpler using Rails >= 5.0 methods.
See https://api.rubyonrails.org/classes/ActionController/Renderer.html#method-i-render
2020-08-04 16:53:46 +02:00
jpoulvel
bf94cc021b
Merge pull request #5424 from betagouv/new_design_edit_attestation
...
New design page admin/attestation_templates/edit
2020-07-31 11:18:22 +02:00
Christophe Robillard
03e3e8fb1c
rename Dossier#modifier_annotations!
...
give a more accurate name to the method
Co-authored-by: clemkeirua <clement@keiruaprod.fr>
2020-07-30 10:18:44 +02:00
Judith
5df3838173
- tranferred controllers from admin to mew_administrateur
...
- removed admin/attestation_templates views
- changed routes accordingly
2020-07-29 12:26:27 +02:00
Paul Chavard
1fca481c6e
Cleanup after clone
2020-07-28 17:04:06 +02:00
clemkeirua
7e085c657d
specific deactivation of rubocop DS/ApplicationName rule
2020-07-23 16:20:16 +02:00
Paul Chavard
a08e318617
Add implicit_order_column on revisions
2020-07-22 12:25:06 +02:00
Paul Chavard
69ab2e44fb
Insert type_de_champ with correct initial position
2020-07-22 11:09:51 +02:00
Paul Chavard
3193784c24
Remove unused revision_id from payload
2020-07-22 11:09:06 +02:00
Paul Chavard
0338080430
Remove unused procedure move type_de_champ code
2020-07-21 19:35:30 +02:00
Paul Chavard
d18a9c8162
Migrate procedures “on demand”
2020-07-21 19:35:30 +02:00
Paul Chavard
0a0912503b
Add type_de_champ mutation methods to revision
2020-07-21 19:35:30 +02:00
Paul Chavard
9de917592b
Add revisions models and relationships
2020-07-21 19:35:30 +02:00
Christophe Robillard
7f90bdeec4
only instructeurs of the avis dossier or claimant can revive expert
2020-07-21 13:14:07 +02:00
Christophe Robillard
52e8f32e19
expert can only revoke avis claimed by him/her
2020-07-16 21:07:20 +02:00
Christophe Robillard
3ea34834a7
revoke expert avis
2020-07-16 21:05:11 +02:00
Paul Chavard
b628169053
Remove unsused drop_down_list model
2020-07-16 15:29:01 +02:00
clemkeirua
7b9a954473
include procedure in usual_traitement_time
2020-07-15 09:27:23 +00:00
clemkeirua
96e82c75d6
use more idiomatic update
2020-07-15 09:00:12 +00:00
clemkeirua
299c86141c
added before_save to PieceJustificativeChamp in order to set skip_pj_validation
2020-07-15 09:00:12 +00:00
clemkeirua
bdbe57debd
add skip_pj_validation accessor to TypeDeChamp
2020-07-15 09:00:12 +00:00
Paul Chavard
cc7e6853e7
Disable usual_traitement_time
2020-07-12 12:32:28 +02:00
Paul Chavard
ef259c361d
Fix exception when purge_later is called before save
2020-07-08 19:25:05 +02:00
Paul Chavard
a74e52c828
Call remove_drop_down_list on before_save
2020-07-08 19:25:05 +02:00
Paul Chavard
3c9cc6c070
Remove repetition types_de_champ on type_champ change
2020-07-08 19:25:05 +02:00
Christophe Robillard
2c56511204
validate api_entreprise_token
2020-07-08 18:59:22 +02:00
Christophe Robillard
f38e16e371
avoid n+1 queries
2020-07-08 18:15:15 +02:00
Christophe Robillard
1253bb5994
store instructeur_email in traitement
2020-07-08 18:15:15 +02:00
Christophe Robillard
9b6c5fd7fd
update termine_close_to_expiration with traitement
2020-07-08 18:15:15 +02:00
Christophe Robillard
0be4b50ade
update usual_traitement_time with traitement model
2020-07-08 18:15:15 +02:00
Christophe Robillard
a072d35211
use traitement model
...
when a dossier is terminated (accepte, refuse or classe_sans_suite),
we store now `processed_at` and `motivation` in a traitement instance
2020-07-08 18:15:15 +02:00
Christophe Robillard
f631acd118
update state date in aasm after callbacks
...
call aasm event methods, not state methods directly
2020-07-08 18:15:15 +02:00
Pierre de La Morinerie
cd65dc14dd
models: fix ProcedurePresentation#sorted_ids
...
The `Dossier#with_notifications` scope needs to be composed with an
`instructeurs` scope. But it seems Rails 6 will only generate proper
SQL if the `instructeurs` scope is merged before filtering on
`with_notifications`.
2020-07-07 18:03:56 +02:00
Pierre de La Morinerie
4aeb8c392f
bill_signature: fix reading unsaved attachments
...
Since Rails 6, an unsaved attachment_changes can contain either
a Tempfile, or an hash with an :io key.
squash! bill_signature: fix reading unsaved attachments
2020-07-07 18:03:56 +02:00
Pierre de La Morinerie
a4ed845e43
models: fix attestation template rendering on Rails 6
2020-07-07 18:03:56 +02:00
Paul Chavard
c9ab80c880
WIP
2020-07-07 18:03:56 +02:00
Paul Chavard
6a24c3f812
Rails app:update
2020-07-07 18:03:56 +02:00
Christophe Robillard
83fba55b29
refactor instruction_instructeur_avis_url
2020-06-30 09:17:27 +02:00
Paul Chavard
210389d0f8
Remove admin creation notification email
2020-06-25 16:29:06 +02:00
Paul Chavard
97f91513c8
Store drop_down_list values as jsonb
2020-06-25 13:14:17 +02:00
Pierre de La Morinerie
84149218db
dossier: refactor piece_justificative export helpers
2020-06-24 15:42:30 +02:00
clemkeirua
6b3631dbfe
extract rendering condition
2020-06-24 14:11:58 +02:00
clemkeirua
5c39f22417
seuil d'affichages des checbox/radio à 5 elements
2020-06-24 12:18:56 +02:00
clemkeirua
342129c893
display small multiple selects as checkboxes
2020-06-24 12:18:56 +02:00
clemkeirua
22fc4c4195
display small selects as radio buttons
2020-06-24 12:18:56 +02:00
Paul Chavard
34df07bc96
Fix oui/non filter on type_de_champ_private
2020-06-23 11:33:46 +02:00
jpoulvel
adaf0753b0
Merge branch 'dev' into instruct-filter-yes-no
2020-06-16 14:53:22 +02:00
Paul Chavard
c4896b45ad
Prepare to remove dossier procedure_id
2020-06-11 16:13:44 +02:00
Christophe Robillard
8b802ae2c8
add destroy dependent option for exports
2020-06-11 12:33:29 +02:00
Christophe Robillard
56ed8dd36a
remove useless dependent option
2020-06-11 10:24:04 +02:00
Judith
0e75910d58
ajout de human_to_filter
2020-06-10 15:53:09 +02:00
Judith
ad53dfa84d
Instructeurs: Changed the filters from 'true/false' to 'oui/non' for yes_no type_de_champ
2020-06-10 15:50:41 +02:00
Paul Chavard
d099314e56
Add decription to geo_area
2020-06-09 18:45:45 +02:00
Paul Chavard
901b6e23a8
Remove legacy carto
2020-06-04 16:03:23 +02:00
Christophe Robillard
cf9d6ccf34
export bilans in ods and xlsx
2020-06-04 15:31:16 +02:00
Christophe Robillard
75a268aed6
show some info from bilans
2020-06-04 12:33:33 +02:00
Christophe Robillard
d06867822b
reorder bilans bdf csv
2020-06-03 15:45:11 +02:00
kara Diaby
f104567619
Add 2 cards style for MapEditor + optim import gpx kml
2020-06-02 13:24:29 +02:00
Paul Chavard
20705d6e30
Do not send draft norifications to users on inactive démarches
2020-05-27 16:36:46 +02:00
Christophe Robillard
fb87a09c02
doesn't update dossier etablissement for siret controller
2020-05-26 18:13:20 +02:00
Pierre de La Morinerie
b63fa0e6b8
dossier: remove "Birthdate" column from export
2020-05-18 13:14:28 +00:00
clemkeirua
77101208a4
Anonymisation de l'instructeur dans la messagerie
2020-05-18 12:56:30 +00:00
kara Diaby
db5fd9bd0f
fix bug on mandatory carto champ for the new map editor
2020-05-15 13:44:50 +02:00
clemkeirua
3c751ac696
small logo for procedures
2020-05-14 14:08:05 +00:00
clemkeirua
236fd0291b
bump zip sizes from 50 to 100 mb
2020-05-14 10:37:01 +00:00
Pierre de La Morinerie
190548844a
dossiers: add piece justificative filename to spreadsheet export
2020-05-14 10:18:10 +00:00
Paul Chavard
f0148184ca
Remove legacy carto code
2020-05-13 12:17:04 +02:00
Paul Chavard
dfc004d7bb
Unarchive dossier when repasser_en_instruction
2020-05-12 19:05:18 +02:00
Christophe Robillard
10a21f9010
expose attestationSocialeAttachment and attestationFiscaleAttachment
2020-05-06 17:25:04 +02:00
Christophe Robillard
f587e6600a
extract class ApiEntrepriseToken
...
and check if token is expired
2020-05-06 10:57:45 +02:00
Paul Chavard
6556df2a85
Fix a crash in case of invalid geometry
2020-05-05 15:56:05 +02:00
Christophe Robillard
9de2c7c85a
improve csv generation for bilans bdf
2020-04-30 16:15:16 +02:00
Christophe Robillard
9873826dd4
remove date computed column
...
we will add it when more info of business
2020-04-30 16:15:16 +02:00
Christophe Robillard
22e2c2e133
render csv bidf bilans
2020-04-30 16:15:16 +02:00
Paul Chavard
843e033c38
Allow instructeurs to download a GeoJSON document for a given dossier
2020-04-30 15:49:43 +02:00
Paul Chavard
ef2d9e1138
Expose stable_id on champ
2020-04-30 15:49:31 +02:00
Christophe Robillard
3ddb5a4cb4
store attestation fiscale and display
2020-04-30 11:39:54 +02:00
Paul Chavard
b516cbc179
Enable republish on démarches dépubliée
2020-04-29 18:04:35 +02:00
Christophe Robillard
ddd3e6bb02
don't copy api_entreprise_token when cloning
...
except for an admin who owns the parent procedure
2020-04-29 17:17:20 +02:00
Christophe Robillard
158b4802ab
store attestation sociale and display
2020-04-29 16:25:47 +02:00
Christophe Robillard
d74b14c205
fetch attestation sociale url
2020-04-29 14:25:55 +02:00
Paul Chavard
2a3530738d
Do not crash on boot if geos is not installed
2020-04-23 20:12:31 +02:00
Paul Chavard
9cb612bb3d
Show area and length on champ carto selections utilisateur
2020-04-23 10:21:18 +02:00
Christophe Robillard
792e755af9
expose effectif_annuel dans api graphql
2020-04-23 09:53:27 +02:00
Paul Chavard
bdbee38ff1
Add expired termine scopes to dossier
2020-04-22 15:39:10 +02:00
Pierre de La Morinerie
1cb18e51ac
champ: return the parent dossier even when discarded
...
Dossier has a `default_scope { kept }`.
Because of that, when the parent dossier is discarded, `champ.dossier`
will return nil.
We should kill the default scope. But meanwhile, ensure that
`champ.dossier` returns even a discarded dossier.
2020-04-22 11:46:42 +02:00
Christophe Robillard
149b98007f
add effectif mensuel to graphql api
2020-04-21 21:13:07 +02:00
Paul Chavard
e512870fd2
Cleanup procedure duree_conservation_dossiers_dans_ds validations
2020-04-16 19:40:19 +02:00
Paul Chavard
bc8217e030
Carte Editor sends FeatureCollection to the server
2020-04-16 18:29:19 +02:00
Paul Chavard
ee3ff78b12
Create constants for default map location
2020-04-16 10:22:07 +02:00
Paul Chavard
22604013d0
Expose multiple user selections on champ carte
2020-04-15 18:07:09 +02:00
clemkeirua
8c2f589cbf
fix admin deletion of empty service with archived procedures
2020-04-10 20:01:40 +02:00
Christophe Robillard
f683b850c3
Notifie instructeurs le souhaitant lors depot dossier
...
Notifie par mail uniquement les instructeurs qui le souhaitent à chaque dépôt de dossier
2020-04-09 15:02:05 +02:00
Christophe Robillard
ae18ff6627
Notifie tous les instructeurs lors dépôt dossier
...
- envoie un mail à tous les instructeurs d'une procédure après le dépôt
d'un nouveau dossier
2020-04-09 14:33:56 +02:00
Christophe Robillard
969478b706
Envoie une notif aux followers_instructeurs le souhaitant
...
après chaque message déposé par l'usager
2020-04-09 14:17:07 +02:00
Paul Chavard
61eaca928f
remove WarnExpiringDossiersJob
2020-04-09 11:11:51 +02:00
Paul Chavard
32f783142c
[GraphQL] allow to query dossiers by groupe instructeur
2020-04-09 09:29:28 +02:00
clemkeirua
ed45c88bdf
do not clone groups instructeurs for admin outside the procedure
2020-04-07 09:25:40 +02:00
pedong
7806a26e2c
copy groupe_instructeurs when clone
2020-04-07 09:22:33 +02:00
Christophe Robillard
5b6044803b
forbid to create champ with same type_de_champ and same row
2020-04-06 17:39:51 +02:00
Paul Chavard
725cfa45d3
Do not set processed_at if already defined
2020-04-02 15:23:53 +02:00
Paul Chavard
413abccd3c
Add default order to dossier.dossier_operation_logs
2020-04-02 14:05:40 +02:00
Paul Chavard
c0bbfa42b7
Reassign discarded dossiers on group_instructeur
...
fix #4851
2020-04-01 18:10:12 +02:00
Paul Chavard
288ace2f34
Dossier on discarded procedure should have access to discarded procedure
2020-03-31 17:08:29 +02:00
Paul Chavard
bd81970f67
DeletedDossier should have access to discarded demarche
2020-03-31 17:08:29 +02:00
Paul Chavard
e4ab2574ce
Démarches discarded by administrateur can be reactivated in manager
2020-03-31 17:08:28 +02:00
Paul Chavard
58c126308c
Add DiscardedProceduresDeletionJob job
2020-03-31 17:08:28 +02:00
Paul Chavard
da52ec30bd
Undo discard dossiers and demarches from manager
2020-03-31 17:08:28 +02:00
Paul Chavard
876e05aed3
Discard demarches from manager
2020-03-31 17:08:28 +02:00
Paul Chavard
aa066bc20a
Validate deleted dossiers dossier_id uniqueness
2020-03-31 16:54:33 +02:00
Pierre de La Morinerie
fe13043efd
dossier: prepare validations to piece_justificative champs
...
We can't yet enable the validations, because of an issue that will
(hopefully) be solved with Rails 6.
See https://github.com/betagouv/demarches-simplifiees.fr/issues/4926
2020-03-30 11:12:25 +02:00
Pierre de La Morinerie
f3c210e875
dossier: remove dead validation code
...
This code used to be called by CarrierWave, but is unused since the
migration to ActiveStorage.
This means that these validations are currently disabled though.
See https://github.com/betagouv/demarches-simplifiees.fr/issues/4926
2020-03-30 11:12:25 +02:00
Paul Chavard
c763679b54
Remove non-existant columns from manager dashboards
2020-03-26 16:17:07 +01:00
Paul Chavard
c707a21f97
Rename delete_and_keep_track -> discard_and_keep_track
2020-03-26 14:23:23 +01:00
Paul Chavard
08a5dd6a27
User should not be deleted if they have hidden dossiers with state_instruction_commencee
...
fix #4933
2020-03-25 18:15:14 +01:00
Paul Chavard
51224fad49
Refactor scopes with intervals and use Time.zone.now
2020-03-25 17:42:03 +01:00
Paul Chavard
c086f6d580
Add a job to remove discarded dossiers
2020-03-25 17:28:25 +01:00
Paul Chavard
5b5ae5a7a5
Do not send notifications or create operation logs on brouillon demarches
2020-03-25 15:04:52 +01:00
Pierre de La Morinerie
f895570b00
dossier: make the upload label a real label
2020-03-25 14:43:09 +01:00
maatinito
1af32b29fd
#4807 Use now() instead of Date.time.today (better code homogeneity)
2020-03-24 17:09:14 -10:00
maatinito
f5c2dc03c5
#4807 better method/variable naming
2020-03-24 16:46:23 -10:00
Christian Lautier
e61c53f267
Fix #4807 48h before closing a procedure, notify users their draft is not submitted
2020-03-24 16:46:23 -10:00
clemkeirua
5896aedeeb
added extension bouton to en_construction dossiers bound to expire
2020-03-24 18:10:51 +01:00
clemkeirua
6d02e6e9e8
replaced helper has_html_label? with inheritance
2020-03-24 16:54:36 +00:00
simon lehericey
378443eb5b
Fix admin/new manager page
2020-03-24 15:52:37 +01:00
Pierre de La Morinerie
a716713ed6
locales: fix translation of champ value
...
Due to the extra 's', the names of Champs attributes were never
translated.
2020-03-24 15:42:02 +01:00
Paul Chavard
5c2eba1dd1
Always add a reason to dossier deletion
2020-03-24 09:30:11 +01:00
Paul Chavard
9243ae69df
Add reason to DeletedDossier
...
# Conflicts:
# db/schema.rb
2020-03-24 09:30:11 +01:00
Paul Chavard
903cf0cef5
Keep operation logs after dossier removal
2020-03-24 09:18:45 +01:00
kara Diaby
1f27652cd3
add files validations to models
2020-03-23 11:28:13 +01:00
kara Diaby
eb8df80c18
fix the email notifications data bug
2020-03-20 16:38:57 +01:00
Paul Chavard
77018b9e2b
Add expiration scopes to dossier
2020-03-18 15:25:02 +01:00
Paul Chavard
f35ccc9d92
Move process_expired_dossiers_brouillon to a service
2020-03-18 15:25:02 +01:00
kara Diaby
395af2fbb0
instructors : receive daily emails for declarative folders
2020-03-17 15:54:50 +01:00
clemkeirua
ca7f81b6ed
add a feature-flip for procedure PDF export
2020-03-17 15:00:03 +01:00
Paul Chavard
3cd4597006
Update rubocop roules
2020-03-17 11:25:21 +01:00
Christophe Robillard
d8d9b0922d
remove orphan services when destroying admin
2020-03-16 21:40:05 +01:00
Christophe Robillard
b5030b8972
highlight demandes when groupe instructeur updated on procedure list
2020-03-04 14:56:59 +01:00
Christophe Robillard
50007b2aac
highlight demande tab when groupe instructeur updated
2020-03-04 14:56:59 +01:00
Christophe Robillard
924702699f
highlight routing criteria label when updated
2020-03-04 14:56:59 +01:00
kara Diaby
b32ed88f9b
add attachment when instructor asking for a review
2020-03-04 13:35:29 +00:00
Paul Chavard
c46e012c10
Use dossier.assign_to_groupe_instructeur
2020-03-03 10:30:49 +01:00
kara Diaby
4a70a7fcc8
remove email_notifications_enabled column because of the new daily_email_notifications_enabled
2020-02-27 11:09:19 +01:00
clemkeirua
cfc584f496
suppression des preconditions sur sorted_ids et filtered_ids
...
Ces preconditions induisent un probleme de n+1. On peut résoudre le problème en supprimant la précondition, ou en incluant les procedures dans les dossiers
J'ai opté pour la suppression de la précondition, qui avait fait débat lors de son introduction:
667deae5cc (diff-b6be6196cd739f8b31e0b195677e46d6R176)
2020-02-26 15:21:42 +01:00
Christophe Robillard
2bd6f01009
log changer_groupe_instructeur
2020-02-26 11:25:07 +01:00
Christophe Robillard
e0f4957dfd
notify instructeur after groupe_instructeur changed
2020-02-26 11:25:07 +01:00
Christophe Robillard
fb3d7e45ba
unfollow stale instructeurs
...
when the group instructeur of a dossier is changed, unfollow the
instructeurs who don't belong to the new groupe instructeur
2020-02-26 11:25:07 +01:00
kara Diaby
6102ba6039
Do not permit to upload a GIF file via javascript
2020-02-25 23:33:15 +01:00
Paul Chavard
24d237de9e
A cloned procedure should not have canonical relationship
2020-02-25 15:26:43 +01:00
Pierre de La Morinerie
8eb6dd78a1
mailers: fix procedure_after_confirmation in the confirmation email
...
As mailers are run asynchronously, they don't have access to the
CurrentConfirmation defined in an earlier request.
For the procedure_after_confirmation to be serialized to the Mailer,
we need to pass it at creation time.
2020-02-25 15:17:09 +01:00
Pierre de La Morinerie
6664965961
mailers: add procedure context to the confirmation link
...
This allows to redirect the user to the procedure they signed up for
even when the browser session is not available (like if they changed
of browser).
Fix #4738
2020-02-25 11:45:36 +00:00
Paul Chavard
be66a8986c
Activate champ integer number on all the new procedures
2020-02-25 11:26:37 +01:00
clemkeirua
ae14599245
#4700 : export files are antivirus-safe
2020-02-24 16:14:58 +00:00
kara Diaby
5dc5230791
Step1 : add new column to Assign_tos and make sure that the data is saved on form submit
2020-02-20 16:14:56 +01:00
clemkeirua
48d2093577
tag 'groupe instructeur' uniquement si la procedure est routee
2020-02-20 14:48:14 +00:00
clemkeirua
059d80ea34
#4785 ajout d'une balise 'groupe instructeur'
2020-02-20 14:48:14 +00:00
Paul Chavard
b7051da278
Remove old export code
2020-02-19 18:19:17 +01:00
Christophe Robillard
9f7b78ff8b
supprime les colonnes ignorées
2020-02-17 19:03:43 +01:00
Pierre de La Morinerie
d6a9318d05
champ: fix siblings
for repetition champs
...
Fix a crash when requesting the `section_index` of a section header
in a repetition champ.
2020-02-17 17:11:17 +01:00
Christophe Robillard
6e0d1eaee3
remove email ignored column for admin and instructeur
2020-02-17 15:01:40 +01:00
Paul Chavard
1ce1c1e6d0
use discard
2020-02-13 12:31:59 +01:00
Pierre de La Morinerie
f8ed7ec051
form: display index of section in header
2020-02-13 11:18:46 +01:00
kara Diaby
0b8a59d5e9
Add the possibility to disable weekly email notifications (instructeur) && rename the column email_notifications_enabled to daily_email_notification_enabled
2020-02-12 13:02:31 +00:00
Pierre de La Morinerie
e3ba2ed96c
Revert "form: add number to section headers"
...
This reverts commit f42977e40a
.
2020-02-12 13:54:44 +01:00
Paul Chavard
7afeae1408
remove dossier.linked_dossiers
2020-02-11 17:49:22 +01:00
Paul Chavard
0d55743d9f
linked_dossiers_for should include dossiers_from_avis
2020-02-11 17:38:58 +01:00
Paul Chavard
f0ea96772d
Only invite experts to dossiers instructeur have access to
2020-02-11 17:38:57 +01:00
Pierre de La Morinerie
f42977e40a
form: add number to section headers
2020-02-11 17:36:50 +01:00
Christophe Robillard
91f1722088
admin: always eager load the user relationship
...
Now that `Administrateur.email` is merely an alias to
`administrateur.user.email`,
and we changed every occurence of `administrateurs.pluck(:email)` to
`administrateurs.map(&:email)`, the new version using `map` may cause N+1
queries if the users have not been preloaded.
It makes sense to always preload the user when fetching an
Administrateur:
- Administrateur and User have a strongly coupled relationship
- It avoids N+1 queries everywhere in the app
Of course fetching an administrateur without needing its user will now do
an unecessary fetch of the associated user. But it seems better than
leaving a risk of N+1 queries in many places.
2020-02-04 16:21:42 +01:00
Christophe Robillard
4a1980e95a
admin: disable the email column
2020-02-04 16:21:42 +01:00
Christophe Robillard
ed970d3f3c
admin: create without providing email
2020-02-04 16:21:42 +01:00
Christophe Robillard
2bb161c3cb
admin: alias Administrateur.email
2020-02-04 16:21:42 +01:00
Christophe Robillard
055918aabc
admin: replace calls to Administrateur.find_by(email: ...)
2020-02-04 16:21:42 +01:00
Christophe Robillard
c137917396
fix typo
2020-02-04 16:07:01 +01:00
Christophe Robillard
deb11f281f
remove useless relation between administrateur and dossiers
2020-02-04 16:07:01 +01:00
Christophe Robillard
5a46effcbc
remove useless condition to admin that can be deleted
...
administrateur can be deleted only if he/she has a procedure where
he/she is the only admin
2020-02-04 16:07:01 +01:00
Christophe Robillard
6fc8a27bd7
destroys not all dossiers
...
but only dossiers for a specific user
2020-02-04 16:07:01 +01:00
Christophe Robillard
cee4c5b8fb
Revert "Revert "4127 fix superadmin supprime compte usager""
...
This reverts commit 751f24f7bb
.
2020-02-04 16:07:01 +01:00
clemkeirua
fcea7c4f85
remove invalid excel worksheet characters
2020-01-29 11:45:56 +01:00
Pierre de La Morinerie
96932faa3f
models: add a Dossier#with_hidden scope, and remove unscoped
usages
2020-01-28 17:32:38 +01:00
Pierre de La Morinerie
1448d5b098
models: add a Procedure#with_hidden scope, and remove unscoped
usages
...
This avoids the broad use of `unscoped` to remove the `hidden_at`
clause.
2020-01-28 17:32:38 +01:00
Paul Chavard
eec38bad73
Ajouter les informations de l’instructeur et de l’expert dans l’export des avis
...
fix #4667
2020-01-28 15:09:41 +01:00
Pierre de La Morinerie
9da4fa9f4d
dossier: ensure the dossier groupe_instructeur is always present
...
Otherwise we loose the link to the dossier's procedure, which is
definitely a bad thing.
2020-01-28 14:58:34 +01:00
clemkeirua
696e39761f
deal with secondary_options that can be nil
2020-01-28 14:30:26 +01:00
clemkeirua
65b4bcf3a1
Permet de déposer un dossier lorsqu'un menu déroulant lié obligatoire n'a pas de valeur (car la liste est légitimement vide) dans le second champ.
2020-01-28 14:30:26 +01:00
Paul Chavard
517ab25783
Register canonical procedure when demarche republished under existing path
2020-01-28 12:49:53 +01:00
Pierre de La Morinerie
751f24f7bb
Revert "4127 fix superadmin supprime compte usager"
2020-01-21 18:57:54 +01:00
Christophe Robillard
88e73d4039
raise exception if problem with destroy
2020-01-21 15:05:33 +01:00
Christophe Robillard
675bbdad15
transfere les services lors de suppression admin
...
Lorsqu'un administrateur est supprimé, ses services sont transférés à un
autre administrateur pour chacune de ses procédures
2020-01-21 15:05:33 +01:00
Christophe Robillard
d9570eedc6
empêche suppression d'un user qui est instructeur
2020-01-21 15:05:33 +01:00
Christophe Robillard
a6d007dbd3
supprime un instructeur
2020-01-21 15:05:33 +01:00
Christophe Robillard
d4de5769ee
empêche la suppression d'un user qui est admin
2020-01-21 15:05:33 +01:00
Christophe Robillard
d8a51f986f
supprime un utilisateur qui a des dossiers cachés
2020-01-21 15:05:33 +01:00
clemkeirua
12430a8068
ajout d'un écran intermediaire pour gérer la reaffectation des dossiers
2020-01-20 16:15:02 +01:00
clemkeirua
d6e7799370
removed routing condition in weekly summary
2020-01-20 14:23:19 +01:00
clemkeirua
7e15c6a4a4
add filtering by group in procedure_overview
...
The weekly overview do not work for instructeurs in procedures with multiples groups ;
they see dossiers that they do not have access to. Now the correct filter is added
2020-01-20 14:23:19 +01:00
Paul Chavard
4edc7b00cf
Use geocoder
2020-01-15 15:04:04 +01:00
Paul Chavard
14295db9ad
Revert "Revert "Merge pull request #4552 from tchak/champ-communes""
...
This reverts commit 4373cb22cb
.
2020-01-14 18:46:07 +01:00
clemkeirua
4373cb22cb
Revert "Merge pull request #4552 from tchak/champ-communes"
...
This reverts commit 4cec26f73a
, reversing
changes made to 0ef25ef36c
.
2020-01-13 16:26:27 +01:00
Christophe Robillard
0f881f942b
raise if trying to del a user who can't be deleted
2020-01-13 10:06:43 +01:00
Christophe Robillard
696a058280
delete adminis with procs managed by other admins
2020-01-13 10:06:43 +01:00
Christophe Robillard
9a62d3fe0c
delete a user
2020-01-13 10:06:43 +01:00
Christophe Robillard
58ef36ff57
tells if a user can be deleted
2020-01-13 10:06:43 +01:00
Paul Chavard
785a09b326
Use service_url instead of blob_url on secure attachments
2020-01-08 14:43:05 +01:00
Paul Chavard
cccb04d725
ActiveStorage url should expire after an hour
2020-01-08 14:43:05 +01:00
Pierre de La Morinerie
b3558c497d
dossiers: make build_default_individual
explicit
...
It avoid the use of callbacks, and may avoid situations where an empty
individual is implicitely created.
2020-01-08 10:48:22 +01:00
Pierre de La Morinerie
5e05556ee8
dossiers: add a validation on dossier individual
...
Validate that a dossier on a `for_individual?` procedure always has
an `individual` associated record.
For this, the individual needs to be built before the record is
validated (i.e. even before the `before_create` callback is run).
This should help with #4596 : now if a dossier is created without an
`individual`, or if the `invividual` record is later removed, the
validation will fail.
2020-01-08 10:48:22 +01:00
Paul Chavard
4bbd16576b
Add champ communes
2020-01-07 11:52:51 +01:00
Paul Chavard
22aa2d4ee0
Make all location champs autocomplete
2020-01-07 11:52:51 +01:00
Paul Chavard
fa2eea81aa
Cleanup demarche archivee state
2020-01-07 11:13:42 +01:00
simon lehericey
d0939ae1a4
Add Export Model
2019-12-18 13:13:15 +01:00
Paul Chavard
2f060fc30a
Add depubliee state to procedures
2019-12-04 16:52:41 +01:00
Paul Chavard
e429c79eb1
Allow administrators to set themselves démarches as déclaratives
2019-12-04 12:30:26 +01:00
Christophe Robillard
4e7c779116
refuse les numéros de tel invalides
...
rend facultatif les numéros de téléphone
2019-12-04 05:34:43 +01:00
simon lehericey
006e426a11
Work on deletion mail
2019-12-03 17:18:53 +01:00
simon lehericey
79bfb8b143
Delete expired dossiers
2019-12-03 17:18:53 +01:00
simon lehericey
03b7e81ca4
Send deletion notice for near expired brouillon
2019-12-03 17:18:53 +01:00
Paul Chavard
7b947feae4
Rename demarche archivée to demarche close
2019-11-28 15:07:16 +01:00
Paul Chavard
c1c8ab7ac6
Disable transition from publiée to brouillon
2019-11-28 14:17:47 +01:00
Paul Chavard
3e334a3306
Drop test_started_at
...
# Conflicts:
# spec/models/procedure_spec.rb
2019-11-28 14:17:47 +01:00
maatinito
9de9a1fd71
Use time.zone functions instead of server time functions
...
(Time.zone.today vs Date.today)
2019-11-26 14:26:36 +01:00
simon lehericey
f45ede7f44
href should not contain space
2019-11-21 15:34:59 +01:00
Paul Chavard
0c6705f7fd
Drop old export service
2019-11-21 10:25:40 +01:00
Paul Chavard
ba03dbf8dd
[GraphQL] Add dossierEnvoyerMessage mutation
2019-11-13 19:54:27 +01:00
Pierre de La Morinerie
88373ddf20
individual: raise when the individual object cannot be created
...
Currently, a number of dossiers in production are for procedures for
individuals, but don't have a `individual` object.
This is probably because creating the Individual from France Connect
infos fails – but fails quietly, and nullify the relationship.
As a first step, we now raise an exception when the creation from FC
infos fails. We will then identify the issue, and see if we can fix it –
or if we should be resilient to this kind of issues.
2019-11-12 18:29:37 +01:00
Paul Chavard
990c867c2e
[GraphQL] Add more filters to dossiers
2019-11-07 22:07:42 +01:00
Paul Chavard
f22b39b7c5
Handle non unique champ repetable labels
...
fix #4466
2019-11-07 14:27:52 +01:00
Paul Chavard
2a61ed5b1c
Export etablissement information in csv
...
fix #4440
2019-11-07 14:27:52 +01:00
clemkeirua
04c13190c3
introduce smtp_key in order to use 2 different sendinblue keys
...
client_key is exposed to the client via gon, so if we use it for sending email too we are exposing a key so anybody could send an email.
The current client_key has a different level of right and can't send emails so it's ok to expose it.
2019-11-06 13:34:36 +01:00
clemkeirua
959aacdea5
Sendinblue email balancing using proper credentials
...
This reverts commit c61981e795
.
2019-11-06 13:34:36 +01:00
Paul Chavard
0562e2728f
Fix type_de_champ validation error
2019-11-06 12:54:07 +01:00
Paul Chavard
ee62d6fca4
Fix move type de champs
2019-11-06 12:54:07 +01:00
simon lehericey
9f5169eb7d
Remove unused Administrateur.reset_password method
2019-11-05 14:10:39 +01:00
simon lehericey
395aba8bbc
Remove administrateur active notion
2019-11-05 14:10:39 +01:00
simon lehericey
5643e671a0
Code use user.active?
2019-11-05 14:10:39 +01:00
simon lehericey
b193dd1465
User get the active notion
2019-11-05 14:10:39 +01:00
simon lehericey
e3d7688e66
[ fix #4473 ] Invite_administrateur!: do not reset password if the user is active
2019-11-05 10:29:39 +01:00
simon lehericey
243bc2887f
Invite_administrateur!: remove unused return
2019-11-05 10:29:39 +01:00
clemkeirua
c61981e795
Revert "Sendinblue email balancing using interceptor"
...
This reverts commit b2135b6576
.
2019-11-04 15:55:08 +01:00
Chaïb Martinez
b2135b6576
Sendinblue email balancing using interceptor
...
Signed-off-by: Chaïb Martinez <chaibax@gmail.com>
2019-11-04 15:30:44 +01:00
Pierre de La Morinerie
2e8d365b93
instructeurs: disable the email column
2019-11-04 10:44:24 +01:00
Pierre de La Morinerie
f8358b3ae9
instructeurs: create without providing the email
2019-11-04 10:44:24 +01:00
Pierre de La Morinerie
8e6930d257
instructeurs: fix ProcedurePresentation to use instructeur.user.email
...
The `joins` are declared explicitely in order to associate a predictable
name to the joined table.
Otherwise, when the query is joined with `:users`, ActiveRecord will
alias the join automatically to solve the conflict. Unfortunately, the
automatic resolution means that the table name becomes unpredictable,
and thus unsuitable to perform queries on.
2019-11-04 10:44:24 +01:00
Pierre de La Morinerie
8b8213c301
instructeurs: always eager load the user relationship
...
Now that `Instructeur.email` is merely an alias to `instructeur.user.email`,
and we changed every occurence of `instructeurs.pluck(:email)` to
`instructeurs.map(&:email)`, the new version using `map` may cause N+1 queries
if the users have not been preloaded.
It makes sense to always preload the user when fetching an Instructeur:
- Instructeur and User have a strongly coupled relationship
- It avoids N+1 queries everywhere in the app
Of course fetching an instructeur without needing its user will now do an
unecessary fetch of the associated user. But it seems better than leaving
a risk of N+1 queries in many places.
2019-11-04 10:44:24 +01:00
Pierre de La Morinerie
a462edb9bc
instructeurs: alias instructeur.email
...
This also means we need to replace instances of `pluck` on the email
column.
2019-11-04 10:44:24 +01:00
Pierre de La Morinerie
cd478b489e
instructeurs: replace calls to Instructeur.find_by(email: …)
2019-11-04 10:44:23 +01:00
Paul Chavard
839b0d7e6d
Add Entreprise raison sociale to dossier export
...
fix #4422
2019-10-31 17:11:46 +01:00
simon lehericey
4febf1851f
notifications_for_procedure is now based on instructeur.groupe_instructeurs
2019-10-25 09:42:17 +02:00
simon lehericey
e290fc3674
No need to update column as the sign_up process activates the user
2019-10-24 18:32:48 +02:00
simon lehericey
8ae592fe25
[ fix #4361 ] administrateur active
2019-10-24 18:32:48 +02:00
clemkeirua
d9e993571c
add a warning during export generation
2019-10-24 16:27:10 +02:00
clemkeirua
da590cc73a
sequence async file generation so that the queue flag is cleared
2019-10-24 16:27:10 +02:00
simon lehericey
1fa149575c
Add constraints to GroupeInstructeur
2019-10-23 21:47:20 +02:00
Paul Chavard
86b271997b
Invite experts to linked dossiers
...
closes #3669
2019-10-23 13:10:09 +02:00
clemkeirua
87741f4b49
introduce constant for exports
2019-10-22 09:51:14 +02:00
clemkeirua
cdab08b198
UI work
2019-10-22 09:51:14 +02:00
clemkeirua
43424e4f4e
merge with the work of paul, using 3 links
2019-10-22 09:51:14 +02:00
clemkeirua
70ea5e167e
procedure download is performed through a controller in order not to leak the URL
2019-10-22 09:50:58 +02:00
simon lehericey
6b8cefa551
Procedure: defaut_groupe_instructeur is the first group
...
Especially useful when the defaut groupe is renamed ...
2019-10-17 15:48:14 +02:00
simon lehericey
5897464224
Build Dossier champ only once
2019-10-17 15:48:14 +02:00
simon lehericey
0c15326df6
User: inactive user have never signed_in
2019-10-08 10:09:16 +02:00
simon lehericey
3e0f1b9c66
User: eager load instructeur and administrateur to remove 2 db requests per http request
2019-10-08 09:53:40 +02:00
simon lehericey
451387d32d
Dossier: add conditions on joins for with_notifications scope
2019-09-26 15:46:20 +02:00
Nicolas Bouilleaud
03c950ea97
Move followed_dossiers_with_notifications to a Dossier scope
...
Instead of instructeur.followed_dossiers_with_notifications, we can now write instructeur.followed_dossiers.with_notifications.
Yay composition!
2019-09-25 14:10:00 +02:00
Nicolas Bouilleaud
a4166d3c57
Refactor Instructeur.notifications_* methods
...
- rename `dossiers_id_with_notifications` to `followed_dossiers_with_notifications`,
- rename `notifications_per_procedure` to `procedures_with_notifications`,
- return an ActiveRecord::Relation instead of the result of the query, so that the call place can compose it,
- `merge` with the wanted Dossier scope in the call places, don’t bother passing it as a parameter,
- use the “state” (now “scope”) parameter as a scope method that can be just applied on `Dossier`.
2019-09-25 14:10:00 +02:00
Paul Chavard
eb7aba18e6
Add dossier champs and annotations types
2019-09-24 10:47:21 +02:00
Paul Chavard
8928eaba11
Add demarche champs and annotations types
2019-09-24 10:47:21 +02:00
Paul Chavard
a7fc4df09b
Resolve models and types
2019-09-24 10:47:21 +02:00
Paul Chavard
2e854f2ac3
Add graph loading scopes to Dossier and Procedure
2019-09-24 10:47:21 +02:00
Nicolas Bouilleaud
f74fde3f80
Avoid sending notification emails about archived dossiers
2019-09-20 11:06:33 +02:00
Nicolas Bouilleaud
769621de46
Explicitly pass the “state” param in notifications_*_procedure methods
2019-09-20 11:06:33 +02:00
Nicolas Bouilleaud
8a06c01f13
Reorder methods in instructeur.rb
...
Move token stuff together, out of notification-related stuff.
2019-09-20 10:48:08 +02:00
Nicolas Bouilleaud
4f0871dab0
Use a single query in dossiers_id_with_notifications (instead of four)
...
This is used in /procedures#show and /procedures#index, to display badges on the “suivis” and “traités” tabs of each procedure. Rails cache helps when it’s the exact same query, but it’s not the case for different tabs.
I’m not certain it’ll be a visible performance improvement but it shouldn’t hurt.
2019-09-20 09:45:59 +02:00
simon lehericey
faddbc23ef
Eager load procedure: :groupe_instructeurs for export
2019-09-19 12:30:12 +02:00
simon lehericey
a2f82ab8be
Add groupe_instructeur_label to export v2
2019-09-19 12:30:12 +02:00
simon lehericey
3bc20bdb06
Procedure.routee?
2019-09-19 12:30:12 +02:00
simon lehericey
8660d4af30
Instructeur: only export its dossiers
2019-09-19 12:24:40 +02:00
simon lehericey
e2acb0a946
ProcedurePresentation: can use groupe instructeur
2019-09-18 15:51:02 +02:00
simon lehericey
9b16bd2037
Dossier: retrieve all dossiers for a procedure
2019-09-18 15:51:02 +02:00
simon lehericey
21577a0f0b
Instructeur: dedup procedures with multiple gi
2019-09-18 15:51:02 +02:00
Paul Chavard
8fcf1353f3
Remove duplicated attachments
2019-09-17 18:12:53 +02:00
Nicolas Bouilleaud
0c98f29d59
Move the cached procedure stats queries to a ProcedureStatsConcern
2019-09-17 16:43:48 +02:00
Nicolas Bouilleaud
c26a701a17
Refactor and redesign publish modal
...
* remove the autocomplete menu
* use ujs to pre-validate the procedure
* tweak the UI
2019-09-17 16:30:48 +02:00
Nicolas Bouilleaud
bd1e0aba38
Add Procedure path suggestion
2019-09-17 16:30:48 +02:00
Nicolas Bouilleaud
8806eab8d6
Properly validate Procedure.lien_site_web is set when publishing
2019-09-17 16:30:48 +02:00
Nicolas Bouilleaud
00c37eccb3
Simplify procedure.path and publish event
...
* Get rid of the “reopen” event, merge it with “publish” (it’s the same code)
* Remove the “availability” states; “available with brouillon” makes no sense since the brouillons path are always uuids
* Instead of checking if publish can happen, just try it and handle the errors
2019-09-17 16:30:48 +02:00
Nicolas Bouilleaud
b9968b76b0
Remove “avec_lien” helpers now that Procedure.path cannot be nil
2019-09-17 16:30:48 +02:00
Nicolas Bouilleaud
8fa630d2bb
Remove Gestionnaire.visible_procedures
...
It is actually the same thing as Gestionnaire.procedures. It already included the procedures with paths as well as the archived procedures, and in production, there were no Gestionnaire for who procedures was returning a different result than visible_procedures (expect for two baddata brouillon procedures with a nil path).
In addition, Procedure.path is now nonnull, which means the Procedure.avec_lien scope is pointless.
Finally, the current spec showed that the only procedure not visible to the gestion was the one he was not assigned to.
2019-09-17 16:30:48 +02:00
Nicolas Bouilleaud
e9c6ed80e4
Migration: Index and make Procedure.path nonnull
2019-09-17 16:30:48 +02:00
Paul Chavard
88842918f9
Prepare to drop columns
2019-09-17 12:37:37 +02:00
simon lehericey
acb99609ba
Move defaut_groupe_instructeur as has_one and eager_load
2019-09-16 15:57:07 +02:00
Paul Chavard
b97cbd3402
Serialize champ repetition for tags
...
closes #4272
2019-09-12 17:23:18 +02:00
Paul Chavard
3b8d3b7967
Add Style/CollectionMethods to rubocop
2019-09-12 14:48:18 +02:00
Paul Chavard
c370c2f475
Cleanup FlipFlop
2019-09-10 23:52:44 +02:00
Paul Chavard
65e227c44b
Migrate to flipper
2019-09-10 16:10:14 +02:00
Paul Chavard
3eb3ae001e
Rename “Passé en construction le” to 'Déposé le' for clarity
2019-09-10 14:59:10 +02:00
Paul Chavard
434210de2e
Ignore to be removed columns
2019-09-10 10:49:12 +02:00
Paul Chavard
7ffb98e616
Remove carrierwave uploaders
2019-09-10 10:49:12 +02:00
Pierre de La Morinerie
2724f4667b
groupe_instructeur: unsassign instructeurs on group destroy
...
Fix #4282
2019-09-09 17:29:29 +02:00
simon lehericey
ad7ef6c739
Link assign_to and procedure by groupe_instructeur
2019-09-03 06:47:02 +02:00
simon lehericey
d0bfb62fec
Procedure Factory: use procedure.new_dossier
2019-09-03 06:47:02 +02:00
simon lehericey
3cc8f0c792
Link Dossier and GroupeInstructeur
2019-09-03 06:47:02 +02:00
simon lehericey
a82d49aa60
Procedure: save procedure while cloning
...
This is required to be able to assign the administrateur.instructeur to the defaut_groupe_instructeur of the new procedure
2019-09-02 11:41:12 +02:00
simon lehericey
31cb056351
Procedure: remove direct instructeurs access
...
Add shortcut for the spec to assign instructeurs directly to the defaut groupe
2019-09-02 11:41:12 +02:00
simon lehericey
ba24958035
Procedure add missing_instructeurs?
2019-09-02 11:41:12 +02:00
simon lehericey
85499365a0
Instructeur has_many procedures through groupe_instructeur
2019-09-02 11:41:12 +02:00
simon lehericey
25991c2892
Assign a procedure assign a group as well
2019-09-02 11:41:12 +02:00
simon lehericey
97884c4349
Link AssignTo et GroupeInstructeur
2019-09-02 11:41:12 +02:00
simon lehericey
115d91387c
A procedure has a default groupe instructeur
2019-09-02 11:41:12 +02:00
simon lehericey
f296318072
Create GroupeInstructeur
2019-09-02 11:41:12 +02:00
Paul Chavard
3c6b35d720
Fix attestation preview
2019-08-28 16:33:51 +02:00
Paul Chavard
a19b10b118
Migrate attestation files to active_storage
2019-08-27 17:42:52 +02:00
clemkeirua
188e0fd6b2
removed ask_birthday for new procedures & dossiers
2019-08-27 15:32:17 +02:00
Paul Chavard
d02e0fc556
Fix and test migrate_procedure_logo task
2019-08-22 11:28:03 +02:00
Paul Chavard
cc35a04e26
Migrate procedure logo to active_storage
2019-08-21 11:15:00 +02:00
Paul Chavard
b7b46e9a82
Improve clone of procedure attachements
2019-08-20 17:30:44 +02:00
simon lehericey
c1a622efa1
Add User.create_or_promote_to_administrateur
2019-08-20 12:20:12 +02:00
simon lehericey
97d0855d47
add User.create_or_promote_to_instructeur
2019-08-20 12:20:12 +02:00
simon lehericey
e913b01c52
fix_manager_reset_password
2019-08-20 12:12:20 +02:00
simon lehericey
ebe871819d
Fix admin deletion by an administration
2019-08-20 12:01:36 +02:00
Paul Chavard
e9ba7700d4
Remove commentaire file uploader
2019-08-20 10:24:13 +02:00
simon lehericey
dab1519b8c
Remove credenticals synchronisation logic
2019-08-16 11:35:19 +02:00
simon lehericey
e3e6bc7689
! NEED JOB REBOOT Move remind activation logic to user
2019-08-14 16:34:50 +02:00
simon lehericey
d0ac1c3301
Fix manager invite administrateur
2019-08-14 16:34:50 +02:00
simon lehericey
1b38d4071d
temporary remove password complexity check
2019-08-14 15:06:16 +02:00
simon lehericey
840be2408e
Remove administrateur devise methods
2019-08-14 15:06:15 +02:00
simon lehericey
81f44fa76b
Link user and administrateur
2019-08-14 15:06:15 +02:00
simon lehericey
5fdac38cb2
Fix instructeur invitation
2019-08-13 15:15:16 +02:00
simon lehericey
47b7dc368b
Remove or fix now nonsense code
2019-08-13 15:15:16 +02:00
simon lehericey
a84e07a376
Remove instructeur devise methods
2019-08-13 15:15:16 +02:00
simon lehericey
dd4ffb926c
Link user and instructeur
2019-08-13 15:15:16 +02:00
simon lehericey
3fde2a6f70
Rename gestionnaire in code to instructeur
2019-08-12 13:47:01 +02:00
simon lehericey
6902f84b85
Brutally rename gestionnaire filename to instructeur
2019-08-12 13:47:01 +02:00
clemkeirua
1e6847bc6f
introduce constants for M./Mme
2019-08-01 17:42:32 +02:00
clemkeirua
d7105cb6f8
added spec for dossier#update_with_france_connect
2019-08-01 17:42:32 +02:00
clemkeirua
707e8a0004
dossier_controller#new uses info from FC if any
2019-08-01 17:42:32 +02:00
maatinito
0b0ef8a318
#3928 Zxcvbn service to compute password complexity
2019-08-01 17:12:14 +02:00
Paul Chavard
02904f55b1
Fix champ policy
2019-08-01 16:41:53 +02:00
Paul Chavard
c75e39884e
Save selection utilisateur as geo area
2019-08-01 11:38:09 +02:00
clemkeirua
f5d3818e3c
remove unnecessary retransition methods
2019-08-01 10:40:08 +02:00
clemkeirua
38b48f4217
transition from accepte to instruction as superadmin
2019-08-01 10:29:51 +02:00
Paul Chavard
b266915892
Add repetitions to api
2019-08-01 10:04:35 +02:00
Paul Chavard
fba195c0b5
Add attestation url to dossier on api
2019-07-31 18:30:40 +02:00
Paul Chavard
25db21467d
Stop using Flipflop as switch for Fog
2019-07-31 15:15:09 +02:00
Paul Chavard
fc75580a3c
Start using pundit
2019-07-30 18:09:28 +02:00
Paul Chavard
8c72470a6c
Add default etablissement champ name
2019-07-30 17:17:36 +02:00
Paul Chavard
ab1170bcfc
Fix export dossier n+1 query
2019-07-30 17:17:36 +02:00
Pierre de La Morinerie
95e24392f9
models: remove old pieces justificatives
2019-07-30 16:11:17 +02:00
Pierre de La Morinerie
ea1c8ea7e3
models: remove associations to old pieces justificatives
2019-07-30 16:11:17 +02:00
Pierre de La Morinerie
0da0a2b446
model: remove support for cloning procedures with old pj
2019-07-30 16:11:17 +02:00
Pierre de La Morinerie
f69f325236
api: remove export of old pieces justificatives
2019-07-30 16:11:17 +02:00
Pierre de La Morinerie
e975fe4ade
tasks: remove task to migrate old pieces justificatives
2019-07-30 16:11:17 +02:00
Pierre de La Morinerie
0018f36b44
gestionnaire: remove UI for filtering pieces justificatives
2019-07-30 16:11:16 +02:00
Pierre de La Morinerie
0c4cb3b498
admin: remove UI for managing old pj
2019-07-30 16:11:16 +02:00
pedong
8d03a6747c
add lockable to User, Gestionnaire, administration, Administrateur
2019-07-29 17:48:44 +02:00
Nicolas Bouilleaud
b066ccbc89
Make sure Procedure.path is not null in our data
2019-07-29 13:53:33 +02:00
clemkeirua
6f47655301
rendu lien_site_web obligatoire au moment de la publication
2019-07-25 15:46:04 +02:00
Pierre de La Morinerie
1c837eb901
mailers: improve wording of transactional emails and default templates
2019-07-25 12:25:50 +02:00
Pierre de La Morinerie
8313752663
mailers: add CTA to templated emails
2019-07-25 12:25:50 +02:00
clemkeirua
f166077f5e
ajout d'un bouton de suppression des admin dans le manager
2019-07-23 16:11:15 +02:00
Pierre de La Morinerie
45abb6ebc2
mailers: move default templates to a specific subdirectory
...
It makes more understandable that they are templates (and not views
rendered directly by Rails).
2019-07-22 16:22:20 +02:00
clemkeirua
d62740c198
extraction de la taille max des fichiers dans une constante
2019-07-18 17:19:39 +02:00
clemkeirua
ee8a1092e4
extracted MonAvisEmbedValidator
2019-07-17 18:04:32 +02:00
clemkeirua
6d43465ee5
renammed into monavis_embed
2019-07-17 18:04:32 +02:00
clemkeirua
8d2c5cfa14
validation par regex
2019-07-17 18:04:32 +02:00
Pierre de La Morinerie
727702ad4b
emails: mention the procedure name in the email title
2019-07-17 15:01:19 +02:00
clemkeirua
7eeddc0b79
using a shared example + scoped to state TERMINE
2019-07-17 11:53:16 +02:00
clemkeirua
b8fa567c81
ajout du tag 'lien document justificatif'
2019-07-17 11:53:16 +02:00
Pierre de La Morinerie
a8354bd103
dossiers: unify deletion of dossiers between manager and user
...
The code paths for deleting a dossier were different, depending on
whether the dossier was deleted by the user, or from the Manager.
This commit unifies the two code paths into one.
This has the effect of:
- An operation log is now recorded when an user deletes its own dossier;
- Gestionnaires are now notified even when the dossier is deleted from
the Manager;
- The `support:delete_user_account` task now requires the email address
of the author.
2019-07-16 16:22:20 +02:00
clemkeirua
25f81f1d3c
download a dossier as zip with all attachments
2019-07-16 09:11:25 +02:00
Pierre de La Morinerie
d5f360c85f
manager: fix the deletion email not being sent
...
When deleting a dossier from the manager, the deletion notification
email was not being sent. This is because the returned object from
`Dossier#hide!` was invalid.
2019-07-15 10:01:16 +02:00
Pierre de La Morinerie
619f663e1a
procedure: remove individual_with_siret
column
2019-07-11 15:57:46 +02:00
Pierre de La Morinerie
a047ee356b
procedure: remove expects_multiple_submissions
column
2019-07-11 15:57:46 +02:00
Pierre de La Morinerie
35c3795f56
dossier: make messagerie available on archived procedures
...
An Admin may archive a procedure to make it unavailable to
the general public, but before all dossiers are handled. In this case,
the messagerie needs to be available.
Fix #4089
2019-07-11 15:37:04 +02:00
Pierre de La Morinerie
10065df8ce
champs: put champ label in numeric fields validation messages
...
Replaces
> La valeur du champ doit être un nombre entier (sans chiffres après
> la virgule)
by
> La valeur du champ « Nombre de parents » doit être un nombre entier
> (sans chiffres après la virgule)
2019-07-11 15:12:48 +02:00
Pierre de La Morinerie
fdca7c025a
procedure: ignore :expects_multiple_submissions
on the correct model
2019-07-11 12:14:25 +02:00
Pierre de La Morinerie
c2c9b19b3b
procedure: remove individual_with_siret
...
It isn't used anymore (see #3077 )
2019-07-11 11:58:21 +02:00
Paul Chavard
3cb39c2840
Refactor message attachements to use active_storage
2019-07-10 15:35:29 +02:00
Pierre de La Morinerie
ecfccae6f0
dossiers: remove support for Dossier#expects_multiple_submissions
2019-07-09 14:50:11 +02:00
Paul Chavard
ad0a74ea7c
Fix dates in dossiers export
2019-07-09 10:02:08 +02:00
Nicolas Bouilleaud
930fd345de
Validate messagerie_available? when creating a new Commentaire
...
Commentaires bu Users and Gestionnaire need the messagerie to be available; Automatic system Commentaires can be created anytime.
This reintroduces Commentaire validation that was introduced in #3979 and disabled in #4018
2019-07-08 16:13:43 +02:00
Nicolas Bouilleaud
3f439ac07a
Add Commentaire.is_sent_by_system? and .is_sent_by(someone)
...
And use it in CommentaireHelper and in the _message_icon and _message_issuer partials
2019-07-08 16:06:44 +02:00
Nicolas Bouilleaud
2abd93d360
Display the full User
email in Commentaires
...
* Only redact gestionnaires’ emails
* Also, rename Commentaire.sender to Commentaire.redacted_email
2019-07-08 16:06:44 +02:00
Nicolas Bouilleaud
3bf19de124
Remove Commentaire::columns override
...
It was used for a cleanup migration a long time ago (see #233 , #3033 , #3043 )
2019-07-08 16:06:44 +02:00
Nicolas Bouilleaud
4d73275bab
Drop Procedure.administrateur_id
2019-07-04 17:01:12 +02:00
Paul Chavard
e582ff729c
Add aasm to dossiers state
2019-07-03 13:37:27 +02:00
Mathieu Magnin
10d3ba10f2
Before save copy body in rich_body
2019-07-03 13:15:49 +02:00
Mathieu Magnin
d13b7f953f
Migrate mail body to ActionText
2019-07-03 13:15:49 +02:00
simon lehericey
b2c987ff0d
[ fix #3683 ] Dossier: add repasser_en_instruction!
2019-07-02 18:40:20 +02:00
Paul Chavard
fb0ef15e3c
Export dossiers v2
2019-07-02 14:20:29 +02:00
Paul Chavard
46c1bbbc6f
Official support for declarative demarches
2019-07-02 14:12:26 +02:00
Nicolas Bouilleaud
bd47bf2691
Disable Messagerie in archived Dossiers and procedures
...
* Use the existing Dossier#messagerie_available? method
* Raise when attempting to build a Commentaire if not messagerie_available?
* Disable the Messagerie form if not messagerie_available?
* Add tests :)
* Tweak the Horaires formatting while we’re here.
2019-07-01 09:39:39 +02:00
Paul Chavard
0d80c48b7e
Add avis to api
2019-06-27 14:40:17 +02:00
Paul Chavard
c5704fa22f
Remove unused code from Commentaire
2019-06-25 17:04:29 +02:00
Nicolas Bouilleaud
f355f849a6
Add BillSignature Model
2019-06-17 16:16:28 +02:00
Nicolas Bouilleaud
7e80b8a4dc
Enable the Rails/InverseOf cop and add missing inverse_of
2019-06-17 13:44:07 +02:00
Pierre de La Morinerie
51aacabf13
models: fix touch not propagating when using nested attributes
...
Sometimes, when using nested attributes, touch doesn’t propagate to
parent relationships. (see https://github.com/rails/rails/issues/26726 )
Specifically, this happens in our app when updating a dossier with
only new attachements (but without changing the value of any fields).
To work around this, we need to define the parent relationship
explicitely. This is good practice anyway.
Fix #3906
2019-06-17 13:44:07 +02:00
simon lehericey
ee296f2b44
Use default format for date and datetime champ
2019-06-12 17:48:12 +02:00
Nicolas Bouilleaud
5acb7a3f1b
Make rubocop happy
...
I did make some changes some lines above this 🤷 .
2019-06-12 17:33:53 +02:00
Nicolas Bouilleaud
6b90bc1ea1
Add “previously followed” dossiers and gestionnaires
...
Using an “inactive” Follow scope, similar to the “active” scope.
(I was tempted to use a default_scope, but this breaks when trying to `unscope` it in associations.)
2019-06-12 17:33:53 +02:00
Nicolas Bouilleaud
be4c575622
Add Follow.unfollowed_at
...
The active scopes is used indirectly in the dossier<->gestionnaire associations: the existing tests in dossier and gestionnaire just work™.
2019-06-12 17:33:53 +02:00
Nicolas Bouilleaud
d417907f36
Just rely on the constraints to avoid duplicate Follows
...
Don’t check manually in advance: just try to create the new Follow and silently fail.
Since we have both Rails validation and DB constraints in place, we have two types of errors to check. I’m not actually sure this change improves the legibility of the code.
2019-06-12 17:33:53 +02:00
Nicolas Bouilleaud
ba48a1da6e
Ensure Follow dates can not be not null
...
* Add Follow.unfollowed_at
* Change the unicity constraint to gestionnaire/dossier AND unfollowed_at
2019-06-12 17:33:53 +02:00
Paul Chavard
d5911071f8
Return dossiers on api with stable order
2019-06-04 15:34:49 +02:00
Pierre de La Morinerie
d410e31344
active_storage: document the virus scan hooks
2019-05-28 11:39:22 +02:00
Paul Chavard
4a9ef5d12e
Always use purge_later
2019-05-21 14:05:33 +02:00
Paul Chavard
42235e81b1
Use active storage load hook to extend blob
2019-05-16 20:43:01 +02:00
Paul Chavard
9ce1f0d0a6
Set keep_until on operation_log if available on procedure
2019-05-14 14:31:03 +02:00
Paul Chavard
b8bf662c6d
Track dossier demander un avis
2019-05-14 14:31:03 +02:00
Paul Chavard
9c472e6524
Track dossier private annotations modifications
2019-05-14 14:31:03 +02:00
Paul Chavard
dba8d65137
Track dossier operations with author and subject
2019-05-14 14:31:03 +02:00
clemkeirua
afa6711564
refacto suite à simplification virusscan
2019-05-07 08:54:29 +02:00
clemkeirua
d0794f42d1
fix tag_substitution_concern links for lien attestation
2019-05-07 08:54:29 +02:00
clemkeirua
0e26bda186
cleanup the tag substitution concern & uniformization
2019-05-07 08:54:29 +02:00
clemkeirua
e4259466b4
nettoyage du tag_substitution_concern
2019-05-07 08:54:29 +02:00
clemkeirua
b3956bc072
introduce virus scans
2019-05-07 08:54:29 +02:00
clemkeirua
f8a2598647
ajout du lien vers le justificatif dans la balise --lien attestation--
2019-05-07 08:54:29 +02:00
clemkeirua
4aab72be68
implementation du systeme de PJ de motivation
2019-05-07 08:54:29 +02:00
Nicolas Bouilleaud
0590cc1e28
Ignore the Procedure.administrateur_id column again
...
following #3822
2019-05-06 16:19:08 +02:00
Nicolas Bouilleaud
df865e71dc
Make sure that there always is at least one administrator per Procedure
2019-05-06 16:19:08 +02:00
maatinito
2308b3bc5c
[Fix 3827] Champ Pays: la ligne de tirets ne devrait pas être selectionnable
2019-05-06 14:55:29 +02:00
Paul Chavard
91f2d7d706
Remove deprecated virus_scan model
2019-05-03 11:07:19 +02:00
Paul Chavard
f113d108c9
Save virus scan status to blob metadata
2019-05-02 15:58:09 +02:00
Pierre de La Morinerie
d855468cb6
dossiers: display the estimate of the entire processing time
...
Displaying separate estimations for en_construction and en_instruction
doesn't really make sense for the users: they want to know how
long it is going to take overall, not the petty details of our workflow.
2019-04-30 15:56:27 +02:00
Pierre de La Morinerie
8bd1064532
tasks: populate Procedure.administrateurs even for hidden procedures
...
The previous procedure migration (created in
f7af01e0dc
) worked fine, but didn't run
on hidden procedures (due to the default scope).
2019-04-29 16:35:34 +02:00
Paul Chavard
8d093bd9ba
Fix missing dossier_id on champs inside repetition
2019-04-18 16:55:35 +02:00
simon lehericey
e65e21a72f
Email notification: use the right method for procedures
2019-04-18 15:07:01 +02:00
Pierre de La Morinerie
1f955db2c7
gestionnaire: ignore when the gestionnaire already follows the dossier
...
Fix #3720
2019-04-18 11:41:24 +02:00
Paul Chavard
9beff5ee9a
Always create menu deroulant champs with a value
2019-04-11 14:38:21 +02:00
Nicolas Bouilleaud
c5122ee7f5
Allow filtering ProcedurePresentation by followers_gestionnaires
...
fixes #3464
2019-04-10 14:32:51 +02:00
Nicolas Bouilleaud
988df15c6b
Refactor ProcedurePresentation::sanitize_columns to use model reflection
...
The passed “table” is actually an association, and may not match the table name. Use model reflection instead of manually pluralizing.
2019-04-10 14:32:51 +02:00
Paul Chavard
639facaf2a
Add new types_de_champ#move api
2019-04-03 14:38:07 +02:00
Mathieu Magnin
71e0969bc0
[ Fix #3692 ] Ensure SIRET is correct on server
2019-03-28 18:03:53 +01:00
Mathieu Magnin
27c8e9dcb8
Use the same clone_attachment method for all attributes on procedure.clone
2019-03-28 17:17:29 +01:00
clemkeirua
0d71120f98
[ fix #306 ] Possibilité de joindre un document à un avis
2019-03-28 15:45:14 +01:00
Pierre de La Morinerie
abeb58caa5
dossiers: displays an "Start an other dossier" item in action dropdown
2019-03-28 15:26:15 +01:00
pedong
c0a928ac7a
[ fix #3440 ] use attachment.download for get attachment file
2019-03-26 17:11:59 +01:00
Mathieu Magnin
4e27872a25
[ Fix #3650 ] when cloning a procedure, do not forget pj_templates
2019-03-26 15:31:09 +01:00
Pierre de La Morinerie
b1a7018d30
procedure: ignore bad data when computing usual_instruction_time
...
Fix #3655
2019-03-20 17:48:54 +01:00
Mathieu Magnin
6570bed09c
[ Fix #3641 ] Do not change PJ value in API if PJ is safe
2019-03-20 11:37:31 +01:00
Pierre de La Morinerie
ce9c5da6e1
dossier: add a messagerie_available? method
2019-03-20 10:42:57 +01:00
Paul Chavard
69a51e3296
Save SIRET data on search
2019-03-19 16:22:42 +01:00
Pierre de La Morinerie
ed1f6ec38d
procedure: fix verification delay
...
The verification delay was ignoring all dossiers not closed yet.
2019-03-19 15:51:51 +01:00
simon lehericey
6607de4827
Notification: add service to send notifications
2019-03-18 16:37:51 +01:00
simon lehericey
1644fd9059
Notification: add gestionnaire.procedures_with_email_notifications scope
2019-03-18 16:19:36 +01:00
Paul Chavard
4a9ff29391
Fix administration page
2019-03-12 15:34:30 +01:00
Paul Chavard
48701e80bd
Enable flipflop for instructeurs
2019-03-12 12:14:34 +01:00
Paul Chavard
bb8ba75d22
Explicitly pass current_administrateur on publish
2019-03-12 11:59:01 +01:00
Paul Chavard
01b966ff66
Check demarche ownership on multiple administrateurs
2019-03-12 11:59:01 +01:00
Mathieu Magnin
44f28ec565
Remove feature flag for publish draft
2019-03-12 11:26:07 +01:00
Frederic Merizen
d08b478cfd
Now that we don't have the type column anymore, we don't need to neuter it
2019-03-11 19:00:47 +01:00
Frederic Merizen
02f35e655d
[ #3477 ] Minor simplification
2019-03-11 17:14:17 +01:00
Frederic Merizen
b4790e5009
[ #3477 ] Slightly more compact
2019-03-11 17:14:17 +01:00
Frederic Merizen
e8747f7c38
[ #3477 ] Extract helper method
2019-03-11 17:14:17 +01:00
Frederic Merizen
656f0df377
[ #3477 ] Remove clunky extra method
2019-03-11 17:14:17 +01:00
Frederic Merizen
f64ade355f
[ #3477 ] Fix a copy-paste mistake
2019-03-11 17:14:17 +01:00
Frederic Merizen
7d09624bbe
[ #3477 ] We only use the table anyway
2019-03-11 17:14:17 +01:00
Frederic Merizen
c9ad2995f1
[ #3477 ] Remove extraneous variable
2019-03-11 17:14:17 +01:00
Frederic Merizen
4646e10864
[ #3477 ] The where clause doesn't do what it's supposed to do
2019-03-11 17:14:17 +01:00
Frederic Merizen
cf3f2409dd
[ #3477 ] Clarify what the previous code of eager_load_displayed_fields does
2019-03-11 17:14:17 +01:00
Frederic Merizen
f0d83b1de8
[ #3477 ] ignore invalid dates for now
2019-03-11 17:14:17 +01:00
Frederic Merizen
0ba3515d41
[ #3477 ] Filter by 'column ilike values' as a scope
2019-03-11 17:14:17 +01:00
Frederic Merizen
a87e3ac697
[ #3477 ] Make filtering by datetimes a proper scope
2019-03-11 17:14:17 +01:00
Frederic Merizen
9096f923b1
[ #3477 ] Cleaner way to return no dossiers
2019-03-11 17:14:17 +01:00
Frederic Merizen
d24fb5d186
[ #3477 ] Let where_ilike take care of necessary sanitizing
2019-03-11 17:14:17 +01:00
Frederic Merizen
e098779c5e
[ #3477 ] Accept symbol arguments to sanitized_column
2019-03-11 17:14:17 +01:00
Frederic Merizen
f34e65c207
[ #3477 ] Make sanitized_column a class method
2019-03-11 17:14:17 +01:00
Frederic Merizen
7241e43a7c
[ #3477 ] Allow calling sanitized_column with individual fields
...
rather than a hash
2019-03-11 17:14:17 +01:00
Frederic Merizen
00ca2e0cbb
[ #3477 ] Make sanitized_column dryer
2019-03-11 17:14:17 +01:00
Frederic Merizen
1f34d971d1
[ #3477 ] where_equals is trivial, inline it
2019-03-11 17:14:17 +01:00
Frederic Merizen
91e6671cfb
[ #3477 ] Do not use string interpolation for where_equals
2019-03-11 17:14:17 +01:00
Frederic Merizen
3c96c2e83d
[ #3477 ] Do not use string interpolation for where_datetime_matches
2019-03-11 17:14:17 +01:00
Frederic Merizen
664956d8c6
[ #3477 ] Move compact nearer to the nil-generating place
2019-03-11 17:14:17 +01:00
Frederic Merizen
55d4dcc174
[ #3477 ] Introduce column variable
2019-03-11 17:14:17 +01:00
Frederic Merizen
35d5322a9b
[ #3477 ] Clarify variable name
2019-03-11 17:14:17 +01:00
Frederic Merizen
cf2b40f6a0
[ #3477 ] Extract all variables from sort hash
2019-03-11 17:14:17 +01:00
Frederic Merizen
21128d94b6
[ #3477 ] Inline only use of variable
2019-03-11 17:14:17 +01:00
Frederic Merizen
43243e73d4
[ #3477 ] Merge two ordering cases
2019-03-11 17:14:17 +01:00
Frederic Merizen
71f766c434
[ #3477 ] Prefer pluck over map
2019-03-11 17:14:17 +01:00
Frederic Merizen
c53370e14c
[ #3477 ] Reuse existing filtering facility
2019-03-11 17:14:17 +01:00
Frederic Merizen
393f1b1971
[ #3477 ] Move eager_load_displayed_fields to model
2019-03-11 17:14:17 +01:00
Frederic Merizen
70bf6aecf6
[ #3477 ] Filter by mutliple values
2019-03-11 17:14:17 +01:00
Frederic Merizen
1431de5cc2
[ #3477 ] Handle multiply-valued filters
2019-03-11 17:14:17 +01:00
Frederic Merizen
54cb65b8a7
[ #3477 ] Extract helper
2019-03-11 17:14:17 +01:00
Frederic Merizen
02a72507b9
Remove compatibility code for legacy values in database column
...
They were fixed by a data migration long ago
2019-03-11 11:41:28 +01:00
Frederic Merizen
c75983710c
Force stable order on champ fields
2019-03-11 11:32:17 +01:00
Frederic Merizen
b428406fc7
[ Fix #3578 ] No tags for champs that cannot have user input anyway
2019-03-11 10:26:27 +01:00
Frederic Merizen
610d2e7e2b
[ Fix #3572 ] Use champ with correct type for balise
2019-03-08 18:32:35 +01:00
Mathieu Magnin
fed1f3e921
Use query filter instead of array.reject
2019-02-26 12:05:49 +01:00
clemkeirua
236f73f838
ajout d'une balise pour le nom du service
2019-02-21 12:18:44 +01:00
Paul Chavard
84383fc3c1
Assigne admins to procedure.administrateurs
2019-02-20 17:10:57 +01:00
Mathieu Magnin
f7650135f4
[ Fix #3375 ] on the API display safe files only
2019-02-19 18:10:35 +01:00
simon lehericey
2f66625f18
Manager: improve dossier view
2019-02-19 14:30:14 +01:00
Mathieu Magnin
cf610bbd91
Merge branch 'dev' into enforce-rubocop-timezone
2019-02-18 17:41:41 +01:00
simon lehericey
0b8619be77
Gestionnaire: login_token! -> create_trusted_device_token
2019-02-18 17:21:46 +01:00
simon lehericey
47e3b57e81
TrustedDeviceToken: valid for one week
2019-02-18 17:20:49 +01:00
simon lehericey
7de3a18fd1
valid period depend on trusted_device_token.created_at
2019-02-18 17:20:49 +01:00
simon lehericey
d664f130fd
trustedDeviceToken: move token youth
2019-02-18 17:20:49 +01:00
simon lehericey
23db8a160c
move token validity to trusted_device_token
2019-02-18 17:20:49 +01:00
simon lehericey
b9b83cca3a
use multiple trusted_device_token
2019-02-18 17:20:42 +01:00
simon lehericey
bee9a108c5
split login and trusted_device logic
2019-02-18 17:20:00 +01:00
simon lehericey
9d92e43d8d
[ fix #3315 ] Migrate service organisme
2019-02-18 16:50:44 +01:00
Mathieu Magnin
dd27167c5d
Enforce Timezone rule in Rubocop
2019-02-18 16:19:42 +01:00
simon lehericey
a7e068003a
[ fix #3427 ] Administration can soft delete a dossier
2019-02-14 18:09:08 +01:00
Frederic Merizen
eb7cd28504
Fix undefined method for nil:NilClass
2019-02-13 19:22:38 +01:00
Frederic Merizen
41ab7246cf
[ #3424 ] Improve formatting of addresses with missing components
2019-02-13 09:57:33 +01:00
Paul Chavard
5da5f75c5f
[Types de Champ Editeur] Save on change and only edited model
2019-02-07 17:05:55 +01:00
Paul Chavard
a0a1ce11c8
Add repetition to apercu
2019-02-07 12:29:27 +01:00
Pierre de La Morinerie
a6704c4cd6
dossiers: allow users to delete "en construction" dossiers
2019-02-07 11:07:07 +01:00
Pierre de La Morinerie
d251ebc2f4
dossiers: shorten method name
2019-02-06 18:20:35 +01:00
Paul Chavard
6b39128be3
Clone nested types_de_champ
2019-02-06 10:05:27 +01:00
simon lehericey
5715cdaa4c
[ fix #3363 ] use organisation_name in dossier summary
2019-02-05 17:41:51 +01:00
Frederic Merizen
a255e61556
[ #3356 ] Improve formatting for menus that only have a primary value
2019-02-05 17:35:30 +01:00
Frederic Merizen
a3d7c8de55
[ Fix #3356 ] Add tags for primary menu only / secondary menu only
2019-02-05 17:35:30 +01:00
Frederic Merizen
d3498e10bd
[ #3356 ] Let dynamic type handle tag generation
2019-02-05 17:35:30 +01:00
Frederic Merizen
4a3d402a32
[ #3356 ] No need for special treatment
2019-02-05 17:35:30 +01:00
Frederic Merizen
a8b9da9d3b
[ #3356 ] Remove redundant method
2019-02-05 17:35:30 +01:00
Frederic Merizen
5bc8bbbaa2
[ #3356 ] Let tags handle their own substitution
2019-02-05 17:35:30 +01:00
Frederic Merizen
656061b21a
[ #3356 ] Clarify naming
2019-02-05 17:35:30 +01:00
Frederic Merizen
140a65cb36
[ #3356 ] Simplify detection of handling champ
2019-02-05 17:35:30 +01:00
Frederic Merizen
bcfc0f2535
[ #3356 ] Let types de champ decide their tags
2019-02-05 17:35:30 +01:00
Frederic Merizen
d67af741d5
[ #3356 ] Prepare for multiples tags per type de champ
2019-02-05 17:35:30 +01:00
Paul Chavard
071448e1d9
Champ Repetition dossier editor
2019-02-04 16:19:07 +01:00
Paul Chavard
a4a421a91a
Champ Repetition dossier display
2019-02-04 15:46:39 +01:00
Paul Chavard
9b7b59f67e
Champs editor should handle repetition type
2019-02-04 11:58:26 +01:00
simon lehericey
41ae1f46f4
Trusted_device: cleaner time comparison
2019-02-01 10:54:20 +01:00
Paul Chavard
7678d8eb0b
Revert for_api value on yes_no champs
2019-01-29 15:23:09 +01:00
Pierre de La Morinerie
db8289a19d
procedure: ensure a procedure can't be deleted while it has dossiers
2019-01-23 17:19:36 +01:00
Frederic Merizen
5e37400834
[ #2180 ] Only retain old PJ API when cloning for same admin
2019-01-17 17:40:40 +01:00
Frederic Merizen
d1c0418c89
[ #2180 ] Refactor - extract local variable
2019-01-17 17:40:40 +01:00
Frederic Merizen
8cb509d192
[ #2180 ] Keep information that this type de champ was cloned from a PJ
2019-01-17 17:40:40 +01:00
Frederic Merizen
651fd6149b
[ #2180 ] When cloning a procedure, convert types de PJ to types de champ PJ
2019-01-17 17:40:40 +01:00
Mathieu Magnin
2ce6d01aec
Procedure has a default generated path when created
2019-01-17 14:04:58 +01:00
Paul Chavard
41c9b21509
Use new editor
2019-01-17 11:20:31 +01:00
Paul Chavard
e1a1a2b2ad
Add new admin procedure update action
2019-01-17 11:20:31 +01:00
simon lehericey
99bfd19b41
[ fix #3268 ] Jobs: use automatic_operation
2019-01-16 17:20:12 +01:00
simon lehericey
6ab2d124f9
Dossier: #accepter_automatiquement!
2019-01-16 17:20:12 +01:00
simon lehericey
0f3dedb0b6
Dossier: #passer_automatiquement_en_instruction!
2019-01-16 17:12:32 +01:00
Mathieu Magnin
31c45fe2e5
Fix Sentry 161
2019-01-10 15:21:40 +01:00
simon lehericey
eb6ef1eb46
Gestionnaire: increase validity token to 45 minutes
2019-01-10 12:06:35 +01:00
simon lehericey
29fff9ee68
[ fix #3269 ] bufferize login token email
2019-01-10 12:06:35 +01:00
simon lehericey
a197285742
[ fix #2612 ] Admin: add missing steps to admin UI
2019-01-09 16:25:00 +01:00
simon lehericey
8ca7eb1c54
Procedure: cloning set the current admin gestionnaire of the procedure
2019-01-09 16:25:00 +01:00
simon lehericey
f0139c5962
Spec Factory: an administrateur always has a gestionnaire
2019-01-09 13:49:47 +01:00
Paul Chavard
1beefe4469
Fix champ repetition belongs_to associations
2019-01-08 11:56:33 +00:00
gregoirenovel
55419b92a8
Simplify code
2019-01-08 12:32:27 +01:00
gregoirenovel
864bb38d8a
Add #for_api methods to CheckboxChamp and YesNoChamp
...
Otherwise, we return nil instead of “off” / “non”,
so we don’t expose the data properly
2019-01-08 12:32:27 +01:00
gregoirenovel
0846bad1c8
Mutualize code in methods
...
As done in YesNoChamp
2019-01-08 12:32:27 +01:00
gregoirenovel
866c74ce63
Add Champ#for_api
2019-01-08 12:32:27 +01:00
gregoirenovel
c00aac2f80
We can now replace processing in #formatted_value by #to_s calls
2019-01-08 12:32:26 +01:00
gregoirenovel
f27717ab23
Make the CheckboxChamp export similar to YesNoChamp
...
Previously, nil values would be returned as nil
and not as off
2019-01-08 12:32:26 +01:00
gregoirenovel
4a6930b60a
Remove from EngagementChamp a method it’s inheriting
2019-01-08 12:32:26 +01:00
gregoirenovel
66d1b7ba10
Use ternary conditions
2019-01-08 12:32:26 +01:00
gregoirenovel
9e42190148
Remove the proxy value_for_export method
...
Overload for_export instead
2019-01-08 12:32:26 +01:00
gregoirenovel
7cd50531cf
Remove the proxy string_value method
...
Overload to_s instead
2019-01-08 12:32:26 +01:00
gregoirenovel
9a2341c56c
Remove the useless #for_display proxy method
2019-01-08 12:32:26 +01:00
gregoirenovel
2e6c91e9b0
Move #selected_options to the only relevant model
2019-01-08 12:32:26 +01:00
gregoirenovel
c4b9a0b79e
Rename DropDownList#selected_options_without_decorator
2019-01-08 12:32:26 +01:00
simon lehericey
7b935a6486
login_token: lets constantize
2019-01-07 08:18:29 +01:00
gregoirenovel
5fa5f2aa37
Bump development gems
...
- rubocop (0.61.1 → 0.62.0)
2019-01-05 11:47:55 +01:00
Pierre de La Morinerie
d77530c461
Make Procedure state consistent after switching types de champ order
...
Fixes an issue where, after clicking the "move champ up" button,
the new form is rendered with an incoherent order.
2019-01-03 15:13:14 +01:00
gregoirenovel
b41764ec03
Remove ChampDecorator
2019-01-03 12:08:25 +01:00
gregoirenovel
0596d53ac2
Enable the Lint/UnusedBlockArgument cop
2019-01-03 10:53:50 +01:00
gregoirenovel
baf7977786
Enable the Lint/StringConversionInInterpolation cop
2019-01-03 10:53:50 +01:00
gregoirenovel
186e362701
Enable the Layout/SpaceInsideArrayLiteralBrackets
2019-01-03 10:53:50 +01:00
gregoirenovel
386fbce776
Enable the Layout/SpaceBeforeBlockBraces cop
2019-01-03 10:53:50 +01:00
gregoirenovel
8b0b8162f0
Enable the Layout/SpaceAfterComma cop
2019-01-03 10:53:50 +01:00
gregoirenovel
03eb47016c
Fix a gestionnaire sign in bug
2018-12-26 18:14:04 +01:00
Mathieu Magnin
b40c706d98
[ Fix #3192 ] Clone service if procedure is transferred
2018-12-20 15:45:48 +01:00
Paul Chavard
eb9edc1cee
Order types de champ in scope
2018-12-20 14:14:15 +01:00
Frederic Merizen
2a758d0759
[ Fix #3196 ] Convert YAML to JSON
2018-12-19 23:17:55 +01:00
Frederic Merizen
36d6a43084
[ #3196 ] Make TypeDeChamp#options compatible with raw JSON
...
instead of YAML inside a JSON string.
We still need to support the YAML form until the data has been migrated
2018-12-19 18:43:56 +01:00
Paul Chavard
5d1c24f3d8
Add type de champ repetition models (with row)
2018-12-19 15:31:11 +01:00
gregoirenovel
df7e0a9881
Remove dead code
2018-12-19 14:59:15 +01:00
gregoirenovel
4b0e632abb
Enable the Style/ColonMethodCall cop
2018-12-19 13:56:10 +01:00
gregoirenovel
fba8d97256
Enable the Stlye/BlockDelimiters cop
2018-12-19 13:56:10 +01:00
Frederic Merizen
d1cfe4468d
Encourager la création de champs PJ plutôt que de vieilles PJS
2018-12-19 11:57:23 +01:00
gregoirenovel
129df93fb1
Add a blank line to ease readability
2018-12-18 22:49:27 +01:00
gregoirenovel
3ce3d203d4
Simplify some code
2018-12-18 22:49:27 +01:00
pedong
f70f276ae9
[ fix #2813 ] set lien_notice nil when clone a procedure
2018-12-06 21:28:08 +01:00
Paul Chavard
35494df78e
Procedure export dossiers with champs siret
2018-12-05 17:09:39 +01:00
Pierre de La Morinerie
e206f3d4d4
gestionnaire: display draft procedures in the list
...
Fix #3088
2018-12-05 15:38:20 +01:00
Paul Chavard
a08f170dbd
Assign users and gestionnaires to commentaires
...
fix #2052
2018-12-05 13:40:57 +01:00
Paul Chavard
e873b6a9c4
Expose selection utilisateur size on champ carte
2018-12-03 12:49:03 +01:00
Paul Chavard
d77a5c9f15
More tests and fixes on carte champ
2018-11-30 13:28:30 +01:00
Paul Chavard
097a15d624
Test and fix all possible cases of champ carte serialization
2018-11-30 12:02:27 +01:00
Paul Chavard
35d2bc36fc
cleanup selection_utilisateur geo_json
2018-11-29 17:10:14 +01:00
Paul Chavard
ca147969ab
Fix number champs validation
2018-11-29 15:12:31 +01:00
Paul Chavard
1883c57c87
Add stable ids to types_de_champ after every update
2018-11-29 11:41:13 +01:00
Paul Chavard
c18796d02a
Fix geojson exposed on legacy carto API
2018-11-29 08:43:51 +01:00
Paul Chavard
9b39934e8b
Destroy dossier_operation_logs when dossier is destroyed
2018-11-28 17:06:54 +01:00
Mathieu Magnin
b51bf759b1
[ Fix #3081 ] If a dossier is destroyed, then destroy the attestation
2018-11-28 16:33:12 +01:00
Paul Chavard
36f6f54337
Remove unused carto models
2018-11-27 16:11:25 +01:00
Paul Chavard
0f0ca2ec65
Lod dossier operations
2018-11-27 12:49:40 +01:00
Paul Chavard
85e3eb04f4
Add DossierOperationLog model
2018-11-27 12:49:40 +01:00
Paul Chavard
a079eaea5c
Add procedure gestionnaire_for_cron_job method
2018-11-27 12:49:40 +01:00
Paul Chavard
9843666bdc
Implement state change methods on dossier
2018-11-27 12:49:40 +01:00
gregoirenovel
251bd635c2
Prepare for champ_id deletion
2018-11-22 12:27:48 +01:00
Pierre de La Morinerie
e5303fd986
mailers: streamline the NotificationMailer
...
Notifications are now only for demarche-templated emails.
2018-11-20 14:46:31 +01:00
Paul Chavard
0b017580c5
Expose migrated legacy carto champs on api
2018-11-20 10:53:14 +01:00
Paul Chavard
d92364b90b
Add user_geo_area do champ carte
2018-11-20 10:53:14 +01:00
Paul Chavard
971a08c92a
Add expose legacy carto api flag
2018-11-20 10:53:14 +01:00
Paul Chavard
18815e88a3
Rename champ.zones to champ.geo_json
2018-11-20 10:53:14 +01:00
Paul Chavard
2462e42b53
Stop using legacy api carto after migration
2018-11-20 10:53:14 +01:00
Pierre de La Morinerie
83031b5cdd
procedure: compute the usual instruction time only for the last month
2018-11-13 17:23:31 +01:00
simon lehericey
36621bffeb
FlipFlop: enable for gestionnaire
2018-11-13 10:41:45 +01:00
simon lehericey
0d8d2de5a6
Session: add trusted_device cookie
2018-11-13 10:41:45 +01:00
simon lehericey
5690599289
Session: send a mail to confirm gestionnaire login
2018-11-13 10:41:45 +01:00
simon lehericey
2613d05a4f
An admin has always a gestionnaire role
2018-11-13 10:41:45 +01:00
Pierre de La Morinerie
e59bec51ef
procedure: use 90th percentile to estimate the completion delay
2018-11-08 18:29:17 +01:00
Pierre de La Morinerie
5c921182ea
procedure: rename mean_instruction_time
to usual_instruction_time
...
Ref #2970
2018-11-08 17:20:06 +01:00
Paul Chavard
33c6ddc452
Remove dead code related to dossier state
2018-11-08 14:56:45 +01:00
Paul Chavard
6706b9004f
Fix includes on api queries
2018-11-08 14:45:09 +01:00
Paul Chavard
80189def98
Remove n+1 calls from API queries
2018-11-08 14:45:09 +01:00
simon lehericey
9d406770a8
[ fix #2956 ] YesNo: fixing to_s
2018-11-06 16:59:47 +01:00
Frederic Merizen
c7358a8f53
[ Fix #835 ] Enable asking for multiple avis at the same time
2018-11-06 15:44:43 +01:00
gregoirenovel
9833564863
[ #835 ] Add a missing validation to avis
2018-11-06 15:44:43 +01:00
Paul Chavard
074050a91a
Add IntegerNumberChamp
2018-11-06 11:28:44 +01:00
Paul Chavard
45bfb2fd47
Add DecimalNumberChamp
2018-11-06 11:28:44 +01:00
Paul Chavard
e391fe6bec
Clarify procedure path availability code
2018-10-30 15:59:37 +01:00
Paul Chavard
b42095363e
Refactor procedure model
2018-10-30 12:01:45 +01:00
Paul Chavard
78dc582588
Remove ProcedurePath
2018-10-30 12:01:45 +01:00
Frederic Merizen
f6207bee26
Do not take time of day into account when searching dates
2018-10-26 17:53:26 +02:00
simon lehericey
a06f872a4b
ProcedurePresentation: rescue big int as a datetime value
2018-10-26 14:39:17 +02:00
simon lehericey
63db387984
ProcedurePresentation: display dossier date in d/m/Y
2018-10-26 10:10:20 +00:00
simon lehericey
3685c65fb7
[ fix #2905 ] fix DATE_TRUNC usage
...
DATE_TRUNC is played on the db where the timestamp are stored in utc.
So if a user search for 12/12/2012 in Paris timezone and that we truncate it should do something similar to :
SELECT DATE_TRUNC('day', foo.timezone) from (SELECT timestamp '2012-12-12 00:00:00' AT TIME ZONE 'Europe/Paris') as foo;
=> 2012-12-11
To avoid such pb, I suggest avoiding DATE_TRUNC when exact results are needed
2018-10-26 10:10:20 +00:00
simon lehericey
3dad743d56
remove localtime as it uses server timezone
2018-10-26 10:10:20 +00:00
simon lehericey
e684cec516
DateTime.new => Time.zone.local
2018-10-26 10:10:20 +00:00
simon lehericey
4b25d16f5a
Time.zone.parse(_, options) => Time.zone.strptime(_, options)
2018-10-26 10:10:20 +00:00
simon lehericey
f620e4aee2
DateTime.parse => Time.zone.parse
2018-10-26 10:10:20 +00:00
simon lehericey
2238e5bd9f
Time.now => Time.zone.now
2018-10-26 10:10:20 +00:00
simon lehericey
13ffa61435
DateTime.now => Time.zone.now
2018-10-26 10:10:20 +00:00
Frederic Merizen
64cb231b01
[ #2675 ] Fix notification sort order
2018-10-24 17:10:30 +02:00
Frederic Merizen
02f4ef215a
[ #2675 ] Make dossiers_id_with_notifications public
2018-10-24 17:10:30 +02:00
Frederic Merizen
dfdcfc62e2
[ #2675 ] Make dossiers_id_with_notifications self-contained
2018-10-24 17:10:30 +02:00
Paul Chavard
5a8a4b393f
Add RPG carte source
2018-10-23 18:13:44 +02:00
Paul Chavard
ed46e2c3be
Use Typhoeus in ApiGeo adapter
2018-10-23 18:13:44 +02:00
Frederic Merizen
51954a6d85
[ #2604 ] Warn that we are destroying an invalid ProcedurePresentation
2018-10-23 16:41:51 +02:00
Frederic Merizen
14fd60bee7
[ Fix #2604 ] Handle ProcedurePresentations that have gone invalid
2018-10-23 16:41:51 +02:00
Frederic Merizen
7baa239095
[ #2604 ] Introduce errors when retrieving ProcedurePresentation
2018-10-23 16:34:38 +02:00
Frederic Merizen
84cac7a5c2
[ #2604 ] Remove unneeded self in AssignTo
2018-10-23 16:34:35 +02:00
Paul Chavard
c8c75fc254
Better handle empty user selection layers
2018-10-23 09:35:25 +02:00
Paul Chavard
99e1a20d98
Add champ carte endpoint
2018-10-23 09:35:25 +02:00
Paul Chavard
a541f1fcee
Add type options on carte champ
2018-10-23 09:35:25 +02:00
Paul Chavard
df73e442e9
Explicit foreign_key on CarteChamp
2018-10-22 23:28:00 +02:00
Frederic Merizen
a2bd0582b9
[ Fix #2741 ] Filter / sort by en_construction_at
2018-10-17 12:16:51 +02:00
Paul Chavard
93ba94a9e6
Add carte champ and geo area models
2018-10-16 14:01:12 +03:00
gregoirenovel
22088b167d
Remove ApiAdresse::Geocodeur
2018-10-16 09:33:16 +02:00
gregoirenovel
76cf9ab746
ApiGeo::Driver → ApiGeo::API
2018-10-15 23:31:23 +02:00
gregoirenovel
5e9e913dce
Carto::Geocodeur → ApiAdresse::Geocodeur
2018-10-15 20:55:46 +02:00
gregoirenovel
4903a6b189
Carto::GeoAPI → ApiGeo
2018-10-15 20:55:46 +02:00
gregoirenovel
1f0af303f3
Remove the unused ModuleApiCarto#classes method
2018-10-15 16:16:16 +02:00
Paul Chavard
c63675461a
Add new carto init code
2018-10-14 12:34:43 +02:00
Frederic Merizen
3dca3c7dee
[ Fix #1961 ] Check that sorted_ids works for individual
2018-10-11 12:13:03 +02:00
Frederic Merizen
abd066c6f4
[ #1961 ] filtered_ids for individual
2018-10-11 12:13:03 +02:00
Frederic Merizen
34da620b0f
[ #1961 ] get_value for individual
2018-10-11 12:13:03 +02:00
Frederic Merizen
5d862ae92b
[ #1961 ] Add individual fields
2018-10-11 12:13:03 +02:00
Frederic Merizen
07b8838561
Remove dead code
...
Should have been removed as part of #2720 but was accidentally reintroduced
in #2770
2018-10-11 12:00:49 +02:00
Frederic Merizen
577475f26e
[ Fix #2580 ] Filter by created_at / updated_at
2018-10-10 18:18:28 +02:00
gregoirenovel
c8f872c566
InviteUser → Invite
2018-10-10 12:07:10 +02:00
gregoirenovel
ed11852300
Delete the InviteGestionnaire model
2018-10-10 12:07:10 +02:00
Frederic Merizen
fac6922b98
[ #2750 ] Set might be overkill here
2018-10-10 09:07:57 +02:00
Frederic Merizen
667deae5cc
[ #2750 ] Sanity check procedure
2018-10-10 09:07:57 +02:00
Frederic Merizen
30ef6e6d95
[ #2750 ] No need to validate table and column
...
Because they are pre-validated by rails on the model
2018-10-10 09:07:57 +02:00
Frederic Merizen
58c0ec1bbd
[ #2750 ] Validate order on model update rather than on usage
2018-10-10 09:07:57 +02:00
Frederic Merizen
026c322fce
[ #2750 ] Make ProcedurePresentation checks private
2018-10-10 09:07:57 +02:00
Frederic Merizen
40a5ff0266
[ #2750 ] do parsing of displayed_fields inside ProcedurePresentation
...
rather than in the view
2018-10-10 09:07:57 +02:00
Frederic Merizen
f59984ea70
[ #2750 ] Remove redundant references to procedure
2018-10-10 09:07:57 +02:00
Frederic Merizen
462c818025
[ #2750 ] Move fields from DossierFieldService to ProcedurePresentation
2018-10-10 09:07:57 +02:00
Frederic Merizen
9fa7a6fd0e
[ #2750 ] Move get_value to ProcedurePresentation
2018-10-10 09:07:57 +02:00
Frederic Merizen
fc157c3e4c
[ #2750 ] Move sorted_ids to ProcedurePresentation
2018-10-10 09:07:57 +02:00
Frederic Merizen
2e9dafb4c3
[ #2750 ] Move filtered_ids to ProcedurePresentation
2018-10-10 09:07:57 +02:00
Frederic Merizen
0e9b40ccf6
[ #2750 ] Move fields from Procedure to ProcedurePresentation
2018-10-10 09:07:57 +02:00
Frederic Merizen
efcac5192a
[ #2750 ] Move fields_for_select to ProcedurePresentation
2018-10-10 09:07:57 +02:00
Frederic Merizen
c1f18a164d
Remove dead, buggy code
2018-10-10 05:51:17 +02:00
Paul Chavard
bcbfc370b2
Add button in manager to transition démarche in brouillon state
...
fix #2565
2018-10-09 16:14:18 +02:00
simon lehericey
87e731bc75
Dossier: move state translation to model dossier
2018-10-08 17:55:20 +02:00
Frederic Merizen
33f29f35ab
Avoid recreating service too often
2018-10-04 18:09:39 +02:00
Frederic Merizen
eafd0e8348
Evite de cacher la whitelist trop longtemps
2018-10-04 18:09:39 +02:00
gregoirenovel
36ce94195b
Remove france_connect delegation on User
2018-10-04 13:54:07 +02:00
gregoirenovel
14c8e02aca
[ Fixes #2597 ] Remove given_name and family_name delegation
2018-10-04 13:54:07 +02:00
gregoirenovel
5107b33af8
Remove FC fields from search
2018-10-04 13:54:07 +02:00
Frederic Merizen
b36d153620
Fix missing sort columns
2018-10-03 17:09:49 +02:00
gregoirenovel
c91a1cf474
Enable Style/SymbolArray
2018-10-03 12:15:48 +02:00
gregoirenovel
a171186dd8
Enable Style/TrailingCommaInHashLiteral
2018-10-03 12:03:21 +02:00
Frederic Merizen
8bb08a1b8b
[ #2579 ] Validate columns on ProcedurePresentation model
2018-10-03 10:17:46 +02:00
Frederic Merizen
3bb6fd2d47
[ #2579 ] Remove no-op
...
(sanitize_sql_for_order does not do anything when its argument is a string)
2018-10-03 10:17:46 +02:00
Paul Chavard
941c529b2c
Remove CGU checkbox
...
fix #2725
2018-10-03 08:59:02 +02:00
gregoirenovel
b994fa4206
Do one thing per line
2018-10-01 16:15:46 +02:00
Pierre de La Morinerie
0526551e71
templates: update link to dossier
2018-09-27 17:22:59 +02:00
simon lehericey
4d4dba1550
Procedure: small renaming on mean_time
2018-09-27 15:02:38 +02:00
simon lehericey
88f7e888c3
Administrateur: do not save api_token in clear text anymore
2018-09-27 10:24:56 +02:00
simon lehericey
4a04f2e59f
ApiController: check token validity for a given admin
2018-09-27 10:24:56 +02:00
simon lehericey
8c4f8347ca
Api Token: store token in an encrypted form
2018-09-27 10:14:32 +02:00
simon lehericey
1997f45d7e
Api Token: do not generate one token by default
2018-09-27 10:14:32 +02:00
Paul Chavard
f94a24d7ce
Add path field to procedure information form
2018-09-26 10:53:45 +02:00
Paul Chavard
f6a6d8f457
Fix destroy dossiers on procedure reset
2018-09-26 10:53:45 +02:00
Mathieu Magnin
499021588d
[ Fix #1285 ] Password strength is ensured when saving an administrateur
2018-09-26 09:03:03 +02:00
Frederic Merizen
998754ab73
[ Fix #2258 ] Validate options for linked dropdown menus
2018-09-25 20:32:19 +02:00
Frederic Merizen
3fea14c07d
[ #2258 ] Let dynamic type validate the type de champ
2018-09-25 20:31:34 +02:00
Frederic Merizen
695426316c
[ #2258 ] Make linked menus more robust in the face of bad configuration
2018-09-25 20:31:06 +02:00
Frederic Merizen
9beaa293cd
[ #1421 ] Use delegation rather than STI for TypeDeChamp
2018-09-25 08:26:56 +02:00
Frederic Merizen
7d382837d9
[ Fix #2622 ] Change filters to proper JSONB
2018-09-24 19:39:01 +02:00
Frederic Merizen
1419e9b73f
[ #2622 ] Change sort to proper JSONB
2018-09-24 19:39:01 +02:00
Frederic Merizen
68608307ad
[ #2622 ] Change displayed_fields to proper JSONB
2018-09-24 19:39:01 +02:00
gregoirenovel
e4eb55a37f
Revert "[ Fix #2623 ] Ensure numbers are integers"
...
This reverts commit 68789ff43b
.
2018-09-21 15:15:11 +02:00
gregoirenovel
68789ff43b
[ Fix #2623 ] Ensure numbers are integers
2018-09-21 08:12:52 +02:00
Frederic Merizen
43d8db88d9
[ #1946 ] Check if a dossier’s retention period has expired
2018-09-20 17:44:31 +02:00
Frederic Merizen
b672377f5b
[ #1946 ] Query dossiers by remaining retention time
2018-09-20 17:44:31 +02:00
gregoirenovel
0c9628c180
Fix some files according the the .editorconfig rules
2018-09-20 16:23:09 +02:00
gregoirenovel
8ea021fb69
Factorize code in a method
2018-09-19 12:31:59 +02:00
gregoirenovel
6b98c36dad
Add Dossier#mean_traitement_time for the upcoming page de garde
2018-09-19 12:31:59 +02:00
gregoirenovel
f3a257d81d
Show the mean verification time in the Résumé tab
2018-09-19 12:31:59 +02:00
gregoirenovel
d55c9dff4d
Show the mean instruction time in the Résumé tab
2018-09-19 12:31:59 +02:00
Pierre de La Morinerie
082ef92a99
invite: move invites link to the after_confirmation
callback
...
Refactored from 6a69d958da
The `after_confirmation_path_for` isn't really made to be a callbback.
For instance, it is not executed during tests.
Moving the invitations linking to a proper documented callback allows
the linking to work in a testing environment, when invoking `user.confirm`.
2018-09-19 12:08:28 +02:00
Paul Chavard
36812793d4
Do not clone procedure path
2018-09-18 14:40:02 +02:00
Frederic Merizen
63fc0b3bc3
[ Fix #2584 ] Move Field related code to a service
2018-09-18 13:49:34 +02:00
Paul Chavard
18922122b4
Fix SQL ambiguous name error
2018-09-18 13:21:29 +02:00
Paul Chavard
b042efdcba
Update procedure path attribute when procedure_path changes
2018-09-18 13:21:29 +02:00
Paul Chavard
b772256a97
Read from path attribute instead of procedure_path when possible
2018-09-18 13:21:18 +02:00
Paul Chavard
2787f040af
Add path attribute to Procedure model
2018-09-18 13:21:18 +02:00
Paul Chavard
3f6cc668a7
Implement check_availability route
2018-09-12 12:37:15 +02:00
Paul Chavard
631df3197a
Add uniqueness validation to procedure path
2018-09-11 10:38:31 +02:00
Paul Chavard
2770f1db82
Archive only when path changes owner
2018-09-11 10:38:31 +02:00
Paul Chavard
be51802983
Add reopen aasm event
2018-09-11 10:38:31 +02:00
Paul Chavard
5a794cbb08
Use Procedure#publish_or_reopen!
2018-09-11 10:38:31 +02:00
Paul Chavard
ec3a0dc4cf
Use Procedure#publish_with_path!
2018-09-11 10:38:31 +02:00
Paul Chavard
b3f8b68b99
Add Procedure#publish_with_path!
2018-09-11 10:38:31 +02:00
Paul Chavard
e6485603c4
Add ProcedurePath#valid?
2018-09-11 10:38:31 +02:00
Paul Chavard
f2f3c54147
Procedure: update -> update!
2018-09-11 10:38:31 +02:00
Paul Chavard
7a322266fa
Make aasm related methods private
2018-09-11 10:38:31 +02:00
Paul Chavard
de908ef4be
Extract ProcedurePath#find_by_path
2018-09-11 10:38:31 +02:00
Paul Chavard
b63038faca
Allow administrateur to try dossier info on aperçu page
2018-09-07 19:41:34 +01:00
Paul Chavard
23170f54c0
Instructeur should see published drafts
2018-09-07 11:20:16 +01:00
gregoirenovel
00ecae5f93
Procédure → Démarche
2018-09-05 15:46:24 +02:00
Frederic Merizen
7326065590
[ fix #2486 ] Include all needed attributes on downloadable_sorted
...
to avoid N+1 select
2018-08-30 14:13:32 +02:00
Frederic Merizen
9403d4c042
[ #2486 ] followers_gestionnaires should not be a method
...
To help activerecord caching
2018-08-30 14:13:32 +02:00
Frederic Merizen
37c45f0d29
[ #2486 ] Always order champs
...
to help activerecord cache the champs collection
2018-08-30 14:13:32 +02:00
gregoirenovel
4b071ecf06
Use enum to the fullest with Dossier.states
2018-08-29 17:31:08 +02:00
gregoirenovel
2d3b553e4d
Use enum to the fullest with TypeDeChamp.type_champs
2018-08-29 17:31:08 +02:00
gregoirenovel
606b56033a
Use enum to the fullest with VirusScan.statuses
2018-08-29 17:31:08 +02:00
gregoirenovel
66c5f080cc
Add AR validation for Feedback rating
2018-08-28 10:36:36 +02:00
gregoirenovel
4103861f90
Add the rating column to feedbacks
2018-08-27 17:03:11 +02:00
Frederic Merizen
1134877d59
[ #2179 ] Remove newly dead code
2018-08-23 11:57:06 +02:00
Frederic Merizen
650a740642
[ #2179 ] Remove dead code
2018-08-23 11:57:06 +02:00
Frederic Merizen
3b2919a326
[ #2179 ] Use new updated value for search terms
...
Rather than old in-database value
2018-08-23 10:34:25 +02:00
Frederic Merizen
333f4e8824
[ #2179 ] update champ and individual association with default
...
That way, they are safe to read in update_search_terms, and no
reload is needed later
2018-08-23 10:34:25 +02:00
Paul Chavard
aec02a9b8a
Remove references to test_procedure
2018-08-14 16:30:43 +02:00
Paul Chavard
7237ff80cc
Drop procedure dossiers when updating brouillon
2018-08-14 11:21:05 +02:00
Paul Chavard
3be678dbe5
Add publish_draft feature flag
2018-08-13 19:27:28 +02:00
simon lehericey
b33f11115c
[ fix #2358 ] Checkbox: serialize in attestation by oui or no
2018-08-10 16:25:34 +02:00
lucien mollard
9ecc5f7928
add a user satisfaction form'
2018-08-09 11:41:26 +02:00
Paul Chavard
46e75ac8ef
Only notify on dossier supression if dossier is en_construction
2018-08-02 17:07:24 +02:00
Paul Chavard
e358e72867
Do not display gestionnaire emails in the messaging interface
...
fix #2302
2018-07-31 15:27:36 +02:00
Frederic Merizen
0e639030f9
[ #2179 ] Generate denormalized search terms value for Dossier
2018-07-27 11:11:52 +02:00
Pierre de La Morinerie
13182ad291
dossier: send deletion email also to the following gestionnaires
2018-07-25 13:49:55 +02:00
gregoirenovel
eb95fce194
[ Fix #2272 ] Add a SIRET field to the Service form
2018-07-19 15:43:13 +02:00
gregoirenovel
4d41381155
Move the attestation route inside the member block
2018-07-17 17:26:42 +02:00
Mathieu Magnin
e748b6883f
Fix comportement chelou in LinkedDropDownListChamp
2018-07-12 12:31:54 +02:00
Pierre de La Morinerie
b0a9e49549
procedures: group new_from_existing list by organization
...
As procedures are not grouped by Service (which are unique to an
administrator) but by organization, this allows procedures with the same
organization name to be displayed together.
2018-07-03 23:43:42 +02:00
Mathieu Magnin
9afbd16bbf
[ Fix #2145 ] When procedure is archived, usager should not be able to submit a dossier
2018-07-02 11:10:33 +02:00
Frederic Merizen
5192929730
[ #1421 ] Format linked dropdown menus in attestations and mails
2018-06-28 20:06:32 +02:00
Frederic Merizen
b326cb9c3e
[ #1421 ] Handle mandatory fields
2018-06-28 20:06:32 +02:00
Frederic Merizen
e794515c8e
[ #1421 ] Format linked dropdown menus in spreadsheet export
2018-06-28 20:06:32 +02:00
Frederic Merizen
04892f6c55
[ #1421 ] Format value for display
2018-06-28 20:06:32 +02:00
Paul Chavard
d0a6957862
Remove old cerfa code
2018-06-28 15:16:20 +02:00
Paul Chavard
93d6d72df5
Do not copy service info when cloning from library
2018-06-28 11:33:10 +02:00
Frederic Merizen
7fdb523b1a
We can use the shorter syntax fort ordered_champs(_private)
...
now that the old preview is gone
2018-06-28 10:27:07 +02:00
Pierre de La Morinerie
0cebf60c46
[ #1421 ] replace master/slave by primary/secondary
2018-06-27 17:02:46 +02:00
Frederic Merizen
2f206af0d6
[ #1421 ] Make label clickable for drop-down lists
2018-06-27 17:02:46 +02:00
Frederic Merizen
7b1e8c2110
[ #1421 ] Extract values for both drop down lists
2018-06-27 17:02:46 +02:00
Frederic Merizen
2214fc6b86
[ #1421 ] Extract contents of both drop down lists
2018-06-27 17:02:46 +02:00
Frederic Merizen
15e8d8af05
[ #1421 ] Add linked dropown fields
2018-06-21 16:19:20 +02:00
gregoirenovel
3c331b65a5
Remove an unused method
2018-06-20 18:30:41 +02:00
Frederic Merizen
e99931527b
[ #1421 ] Move pays to PaysChamp
2018-06-19 15:20:01 +02:00
Frederic Merizen
0239f936d7
[ #1421 ] Move departements to DepartementChamp
2018-06-19 15:20:01 +02:00
Frederic Merizen
5b59bce0b6
[ #1421 ] Move regions to RegionChamp
2018-06-19 15:20:01 +02:00
Frederic Merizen
95666238ea
[ #1421 ] Move piece justificative error code to piece justificative champ
2018-06-19 15:20:01 +02:00
Frederic Merizen
6af27a7190
[ #1421 ] Move same_hour / same_minute to typed champ
2018-06-19 15:20:01 +02:00
Frederic Merizen
41734092b2
[ #1421 ] Move type specific for_export code to typed champs
2018-06-19 15:20:01 +02:00
Frederic Merizen
ee8616fb97
[ #1421 ] Move type specific to_s implementations to typed champs
2018-06-19 15:20:01 +02:00
Frederic Merizen
c2f199c5aa
[ #1421 ] Move piece justificative specific validation to PieceJustificativeChamp
2018-06-19 15:20:01 +02:00
Frederic Merizen
c690d3819e
[ #1421 ] Move type-specific before_save to typed champs
2018-06-19 15:20:01 +02:00
Mathieu Magnin
ae6e3e345e
Task to unhide dossiers with instruction commencee
2018-06-19 10:05:00 +02:00
Mathieu Magnin
89f82ba92e
Move email sending in delete method
2018-06-19 10:05:00 +02:00
Mathieu Magnin
e05fb2d0ae
Allow dossier deletion if instruction has not started
2018-06-19 10:05:00 +02:00
Mathieu Magnin
cd4615b10d
When a new PJ is uploaded enqueue a anti virus scan job
2018-06-12 15:12:39 +02:00
Mathieu Magnin
927cd3c6f4
Create virus scan model to store clamav result
2018-06-12 15:12:38 +02:00
simon lehericey
e11392981d
[ fix #2072 ] DossierController: check the user can update the dossier
2018-06-08 16:24:29 +02:00
Frederic Merizen
74135b193a
[ Fix #2042 ] Pre-validate users for administrateurs
...
Rather kludgy but better than the double-validation that is required now
2018-06-06 17:45:48 +02:00
gregoirenovel
41e8350cbe
[ Fix #1735 ] Sign the admin account creation email
2018-06-01 20:48:50 +02:00
Frederic Merizen
346687bd33
[ #1946 ] Once durees de conservation have been set, forbid unsetting them
2018-06-01 16:46:39 +02:00
Frederic Merizen
42765efb91
[ #1946 ] Add validation to durees conservation
2018-06-01 16:46:39 +02:00
gregoirenovel
8f1579fb9e
[ Fix #886 ] Move mail templates from /mails to /notification_mailers
2018-06-01 11:47:46 +02:00
simon lehericey
c72421fb9e
Procedure: Once deliberation or cadre_juridique have been set, forbid unsetting them
2018-06-01 11:12:53 +02:00
simon lehericey
1f0e46a4ff
Procedure: required juridique stuff only if needed
2018-06-01 11:12:53 +02:00
gregoirenovel
23931a7591
Remove the contact_email locale
2018-06-01 00:00:11 +02:00
gregoirenovel
185f08f63e
Add constants for email addresses
2018-06-01 00:00:11 +02:00
simon lehericey
0e690c90cc
Procedure: clone the deliberation
2018-05-31 16:56:28 +02:00
simon lehericey
fa14db1cbf
Procedure: add deliberation
2018-05-31 16:56:28 +02:00
simon lehericey
a96889310b
Procedure: add legal reference
2018-05-31 16:55:31 +02:00
gregoirenovel
0329b1db68
Use User#owns_or_invite? instead of Dossier#owner_or_invite?
2018-05-31 14:39:43 +02:00
gregoirenovel
4e9565a5df
Adds User#owns?
2018-05-31 14:39:43 +02:00
gregoirenovel
a57e2388f6
Unify NotificationMailer methods’ signatures
2018-05-31 12:10:06 +02:00
gregoirenovel
dc045bdefb
[ Fix #1808 ] Use &. where possible
2018-05-31 11:49:25 +02:00
Mathieu Magnin
eb1fbb7dbc
Delete button, notify user and admin then delete dossier
2018-05-30 18:01:36 +02:00
Mathieu Magnin
55a3d59e38
Create new model to store deleted dossier metadatas
2018-05-30 18:01:36 +02:00
Paul Chavard
86b2cb211e
Do not attempt to archive already archived procedures
2018-05-29 14:29:26 +02:00
Paul Chavard
87d7bd4fb2
Fix clone procedure
2018-05-28 14:58:40 +02:00
Frederic Merizen
fd168c4a72
[ Fix #1972 ] Make devise mails async
2018-05-28 12:02:13 +02:00
Frederic Merizen
07b1c147d9
[ Fix #1972 ] Always send mails asynchronously
2018-05-28 12:02:13 +02:00
Paul Chavard
66b83b4508
Remove unused alias
2018-05-24 17:54:51 +02:00
Paul Chavard
753a81c2d3
Update tag substitution concern
2018-05-24 17:54:51 +02:00
Paul Chavard
ad24fd5991
Remove entreprise and rna_information models
2018-05-24 17:54:51 +02:00
Paul Chavard
7fb7d77886
Use aasm_state in scopes
2018-05-24 17:49:24 +02:00
Paul Chavard
6b683cc491
procedure AASM derived state
2018-05-23 16:31:27 +02:00
Paul Chavard
550ddc8d97
procedure AASM callbacks
2018-05-23 16:31:27 +02:00
Paul Chavard
9cf87d6063
procedure AASM states and events
2018-05-23 16:31:27 +02:00
simon lehericey
5bd589344e
Devise: confirm user email
2018-05-23 15:55:52 +02:00
Paul Chavard
94d253c6dc
Add commencer/test/:procedure_path route
2018-05-23 11:32:26 +02:00
Paul Chavard
ffef1a644c
procedure_path should check for test and regular procedure
2018-05-23 11:32:26 +02:00
Paul Chavard
4ad3932c05
Add test_procedure to procedure_path
2018-05-23 11:32:26 +02:00
Paul Chavard
785fe3410e
Clone procedure notice
2018-05-22 17:43:44 +02:00
simon lehericey
928227a610
Procedure: remove now duplicate organisation and direction
2018-05-18 16:21:27 +02:00
simon lehericey
39bb56d1d9
Service: add organisme, email, tel, horaires, adresse
2018-05-18 16:21:27 +02:00
simon lehericey
bda0ca8188
Service: sort services by name in index
2018-05-18 16:21:26 +02:00
simon lehericey
fc17b68dc1
Service: create model
2018-05-18 16:21:26 +02:00
Paul Chavard
2b8ee92074
Add aasm_state to procedures
2018-05-17 14:46:48 +02:00
Paul Chavard
0c54220c2b
Add test_started_at to procedures
2018-05-15 11:00:20 +02:00
Frederic Merizen
5ef129d960
[ #1563 ] Remove attestation mail attachment
2018-05-09 10:42:40 +02:00
Mathieu Magnin
a2bbf1b4d6
[ Fix #1907 ] A new token should be regenerated, because the one in db is encrypted
2018-05-04 14:23:05 +02:00
gregoirenovel
8848abc536
#to_sorted_values
-> #sorted_values
2018-05-03 23:35:51 +02:00
gregoirenovel
886431b120
Make some methods private
2018-05-03 23:35:51 +02:00
gregoirenovel
f020fa9e2b
Remove some useless self mentions
2018-05-03 23:35:51 +02:00
Paul Chavard
0b7cf3ae75
#full_data_strings_array
-> #export_values
2018-05-03 23:35:51 +02:00
Paul Chavard
8637a3015e
Simplify Procedure#generate_export code
2018-05-03 23:35:51 +02:00
gregoirenovel
031522cf42
Checking on entreprise has no sense, check etablissement
2018-05-03 23:35:51 +02:00
gregoirenovel
12cda1739b
#export_entreprise_data
-> #export_etablissement_data
2018-05-03 23:35:51 +02:00
simon lehericey
bb4d29ee8f
[ fix #1855 ] Gestionnaire: are now invited to create their password
2018-04-27 14:10:06 +02:00
simon lehericey
c90ddb92a6
Procedure: add #new_dossier
...
Create a new instance of a dossier and its champs without saving them in the db
2018-04-24 16:49:42 +02:00
simon lehericey
9d0b568ef5
Procedure: add parent_procedure
2018-04-24 15:48:20 +02:00
simon lehericey
28ce027025
[ fix #1832 ] Procedure Stat: display procedure cloned ratio
2018-04-24 14:22:22 +02:00
simon lehericey
f46bf5a67e
Procedure: procedure cloned from library are tagged
2018-04-24 14:22:22 +02:00
Paul Chavard
45019ce75c
Use Flipflop instead of Feature
2018-04-18 16:51:21 +02:00
Paul Chavard
3f3358db16
Add flipflop config
2018-04-18 16:51:21 +02:00
Frederic Merizen
ee67e7b154
Always create a corresponding User account for Admin accounts
2018-04-12 16:40:24 +02:00
simon lehericey
5667cfe747
[ fix #675 ] upload notice in DS
2018-04-12 10:44:58 +02:00
simon lehericey
0ab526de5a
[ fix #932 ] Let an adminstrateur upload a pj template
2018-04-09 18:19:24 +02:00
Paul Chavard
408feaa52e
Display etablissement information for siret champ
2018-04-09 13:18:10 +02:00
Paul Chavard
27592ae072
Add simple web hooks to procedures
2018-04-09 11:02:24 +02:00
Frederic Merizen
6ed7ae4b53
[ Fix #1809 ] Handle non-champ tags in attestation
2018-04-06 19:22:42 +02:00
gregoirenovel
c60c58ff8b
Fix issues spotted by @fredZen in #1802
2018-04-06 16:39:54 +02:00
kemar
b42e410da0
[ Fix #1494 ] Display a warning when accepting a dossier if needed
...
Show the accompagnateur the unspecified demande
champs and attestations privées needed for the
attestation
2018-04-06 16:15:09 +02:00
Frederic Merizen
809638df79
[ #1563 ] Determine if Attestation and Closed mail are out of sync
2018-04-06 10:18:56 +02:00
Paul Chavard
45ef32e6d9
Add SIRET Type De Champ
2018-04-05 10:29:29 +02:00
Paul Chavard
0b79a3d79d
Add Siret(TypeDe)Champ STI model
2018-04-04 18:44:08 +02:00
Paul Chavard
3cd80af6cb
Add sign and verify to etablissement
2018-04-04 18:44:08 +02:00
simon lehericey
3c8d1f13b6
Individual: remove birthdate proxy
2018-04-04 15:27:30 +02:00
simon lehericey
c019cb623a
Individual: use birthdate as a ... date :)
2018-04-04 13:19:39 +02:00
Frederic Merizen
3e56b6fe9b
[ #1563 ] Include attestation link in default closed mail when it makes sense
2018-04-04 10:44:40 +02:00
Frederic Merizen
db0937d1eb
[ #1563 ] Allow default template name to depend on procedure
2018-04-04 10:44:40 +02:00
Frederic Merizen
7bf7347b9c
[ #1563 ] Clarify constant’s role
2018-04-04 10:44:40 +02:00
Frederic Merizen
66aca60957
[ #1563 ] Remove useless self keywords
2018-04-04 10:44:40 +02:00
Frederic Merizen
84c864ed11
[ #1563 ] Add lien attestation link to closed mail template
2018-04-04 09:34:04 +02:00
Frederic Merizen
abf938ff1b
[ #1563 ] Generalise external link generation for mails
2018-04-04 09:34:04 +02:00
simon lehericey
8828663880
Individual: save the birthdate in Y
2018-04-03 16:23:15 +02:00
simon lehericey
0bff7abb0c
User: add has many relation to dossiers_invites
2018-04-03 10:48:46 +02:00
Paul Chavard
a9f078265a
Add STI types de champ models
2018-03-29 17:45:19 +02:00
Paul Chavard
e8f3fda1f0
Add STI champ models
2018-03-29 17:45:19 +02:00
Frederic Merizen
13d7149b5c
[ #1677 ] Extract Dossier#invite_for_user
2018-03-29 16:59:16 +02:00
Frederic Merizen
884c430619
[ #1677 ] No need to use emails when we have users
2018-03-29 16:59:16 +02:00
Paul Chavard
322f93afbe
Add administrateur#feature_enabled? method
2018-03-28 17:19:07 +02:00
simon lehericey
66a113c7db
Dossier: remove uncessary query on order_champ_v2
2018-03-27 16:48:38 +02:00
gregoirenovel
2385548a03
[Ref #1626 ] Add the administrateurs_procedures table and associations
2018-03-23 11:40:03 +01:00
simon lehericey
9e566596fa
[ fix #1601 ] show pipedrive demandes in manager
2018-03-22 15:37:16 +01:00
Frederic Merizen
2fa88a432b
Add missing brackets around parameters in method definitions
2018-03-20 17:54:51 +01:00
gregoirenovel
4df2eb168d
Remove mandataires_sociaux
2018-03-20 16:09:00 +01:00
gregoirenovel
d0a59058e8
Remove the mandataire_social guess
...
Rationale:
- is true for only 0.06% of Dossiers
- is not displayed anymore anyways
- will be a rare case for now
* FC adoption is not insane
* FC used more for personal than professional
matters
* not always the mandataires sociaux that fill
dossiers for their companies, so not that
relevant
- we can add it back later
2018-03-20 16:09:00 +01:00
Mathieu Magnin
621f8143bd
[ Fix #1654 ] Generate procedure export filename with libelle
2018-03-19 11:16:05 +01:00
Frederic Merizen
610058c534
[ Fix #1619 ] Do not consider invitations to deleted dossiers
2018-03-15 11:32:21 +01:00
Mathieu Magnin
69f8353b2f
[ Fix #1479 ] Sanitize Avis email before validation
2018-03-14 17:41:47 +01:00
Mathieu Magnin
a00114d03d
[ Fix #1479 ] Sanitize User email before validation
2018-03-14 17:41:47 +01:00
Mathieu Magnin
8731f7c63b
[ Fix #1479 ] Sanitize Administrateur email before validation
2018-03-14 17:41:47 +01:00
Mathieu Magnin
d9c562c59d
[ Fix #1479 ] Sanitize Gestionnaire email before validation
2018-03-14 17:41:46 +01:00
Mathieu Magnin
38e1609d73
[ Fix #1479 ] Validate Avis email format
2018-03-14 17:41:46 +01:00
Mathieu Magnin
5650c4aefe
[ Fix #1479 ] Sanitize email format for invite
2018-03-14 17:41:45 +01:00
Mathieu Magnin
e00e8ba01d
[ Fix #1479 ] Validate email format with Rails format validation
2018-03-14 17:41:45 +01:00
Mathieu Magnin
b7de632d6c
[ Fix #1479 ] Create a sanitize email concern
2018-03-14 17:41:45 +01:00
Paul Chavard
5faf4cdd84
Remove all references to old STI
2018-03-08 14:17:04 +01:00
Paul Chavard
19b58a298c
Clarify dependent relationships between etablissement and entreprise
2018-03-07 17:42:31 +01:00
Paul Chavard
d5f620a163
Mark 1to1 nested relationships as update_only
to avoid creating multiple associations
...
This fixes the invalid entreprises without etablissements
2018-03-07 17:42:02 +01:00
gregoirenovel
0a9f442260
Enable some Rails cops
2018-03-06 17:18:44 +01:00
gregoirenovel
da3d9d403a
Enable some more cops
2018-03-06 17:18:44 +01:00
gregoirenovel
e26f4148ff
Bump development gems
...
- brakeman
- rubocop
- scss_lint
2018-03-06 16:17:22 +01:00
gregoirenovel
fe7f8da636
Revert "Bump development gems"
...
This reverts commit d6ad3fc3fd
.
2018-03-06 15:11:26 +01:00
gregoirenovel
d6ad3fc3fd
Bump development gems
...
- brakeman
- rubocop
- scss_lint
2018-03-06 10:36:35 +01:00
gregoirenovel
b33fd6dd37
Fix rubocop warnings
2018-03-02 15:42:20 +01:00
gregoirenovel
0af270faa0
tps.apientreprise.fr -> demarches-simplifiees.fr
2018-03-01 10:33:53 +01:00
gregoirenovel
1b8b6a3274
TPS -> demarches-simplifiees.fr
2018-02-28 18:14:06 +01:00
Paul Chavard
896518f3d5
add SIRETService
2018-02-27 16:22:53 +01:00
Paul Chavard
da14cceadc
Refactor siade adapters
2018-02-27 16:22:53 +01:00
Paul Chavard
0b2ad653fa
Fix camelcase attribute
2018-02-27 16:22:53 +01:00
simon lehericey
d702a0c083
[ fix #1411 ] user: new form ui
2018-02-27 15:24:50 +01:00
Mathieu Magnin
2b6edc0fa4
Remove unused procedure_filter
2018-02-26 17:25:28 +01:00
Mathieu Magnin
3db941ea06
[ Fix #1475 ] Ensure date is parsable before doing it (to avoid errors)
2018-02-26 13:20:23 +01:00
gregoirenovel
3d10dbf0e4
Refactor assignement-related methods
2018-02-23 17:12:58 +01:00
gregoirenovel
ac6ba40598
Unscope the procedures on Gestionnaire and add #visible_procedures
2018-02-23 17:12:58 +01:00
gregoirenovel
1b1460c191
Move a service to the gestionnaire model
2018-02-23 17:12:24 +01:00
Paul Chavard
5470141ca4
Moulinette™ STI Champ et TypeDeChamp
2018-02-20 16:13:40 +01:00
Paul Chavard
55f15b2354
Add a way to check for notifications on dossiers terminé
2018-02-20 15:54:36 +01:00
Mathieu Magnin
9627ba43c0
[ Fix #1409 ] Identite can be updated
2018-02-20 11:01:47 +01:00
gregoirenovel
ee145180a3
Add a piece_justificative_file attribute to Champ
2018-02-15 11:15:23 +01:00
gregoirenovel
7097cad51a
Add the “piece_justificative” type de champ
2018-02-15 11:14:03 +01:00
Paul Chavard
db42c0c0cf
Fix public and private champs scopes
2018-02-14 18:13:23 +01:00
Paul Chavard
31d638ae2a
Remove TypeDeChampPublic/TypeDeChampPrivate STI
2018-02-14 11:49:06 +01:00
Paul Chavard
b3e07d8504
Use in?
in type_champ
tests
2018-02-13 17:59:27 +01:00
Paul Chavard
f80a9466b9
Delegate mandatory?
to type_de_champ
2018-02-13 14:56:55 +01:00
Paul Chavard
2e4ada98e6
Add private columns to Champ and TypeDeChamp
2018-02-13 12:35:03 +01:00
Paul Chavard
52749713ab
Remove ChampPublic/ChampPrivate STI
2018-02-13 12:07:13 +01:00
gregoirenovel
29d9b03672
Bump rails to 5.2.0.rc1
2018-02-07 16:18:42 +01:00
gregoirenovel
142241dd16
Remove notifications
2018-02-06 14:07:20 +01:00
gregoirenovel
2da724d681
Remove an unused Gestionnaire method and its tests
...
The tests would fail with rails 5.1
2018-01-30 16:56:49 +01:00
gregoirenovel
6afaf42e6a
The "through" relation used in a HasManyThrough must be declared first
2018-01-30 16:40:04 +01:00
gregoirenovel
25aef60354
Use string interpolation
2018-01-30 15:50:52 +01:00
gregoirenovel
5b62bc4f12
Use transform_keys when possible
2018-01-30 15:45:32 +01:00
gregoirenovel
db8c3030e3
Use transform_values when possible
2018-01-30 15:45:32 +01:00
gregoirenovel
b2fe1b856c
Use #sum instead of #inject when possible
2018-01-30 15:45:32 +01:00
Mathieu Magnin
50abb36c81
[ Fix #1309 ] Format datetime before save
2018-01-30 13:49:16 +01:00
Paul Chavard
fdd6cedeb8
Remove data_provide
and data_date_format
attributes
2018-01-30 13:49:16 +01:00
Mathieu Magnin
469aca999b
Revert "Remove data_provide
and data_date_format
attributes"
...
This reverts commit 273b3f2faf
.
2018-01-19 13:20:53 +01:00
Frederic Merizen
9b4ce1517c
Use lambda instead of send for etablissement tag
2018-01-18 18:35:07 +01:00
Frederic Merizen
8f41ab89cf
[ #1203 ] Do not include champs privés in accusé de réception
2018-01-18 18:26:14 +01:00
Frederic Merizen
a21dee680d
[ #1203 ] Define tags in constants rather than methods
2018-01-18 18:26:14 +01:00
Frederic Merizen
db5bf39e32
[ #1203 ] No implicit available_for_states, make it explicit
2018-01-18 18:26:14 +01:00
Frederic Merizen
21ad13cf74
[ #1203 ] Make all tags multi-line
2018-01-18 18:26:14 +01:00
Frederic Merizen
943fef3160
[ #1203 ] Move all tag definitions to mail template concern
...
Even the one that is mail-specific, because it is too easy to overlook
it when refactoring otherwise
2018-01-18 18:26:14 +01:00
Frederic Merizen
eebab14954
[ Fix #1203 ] No début d’instruction tag in accusé de réception mails
...
Doesn’t make sense functionnally
2018-01-18 18:26:14 +01:00
Frederic Merizen
9f7ffddb31
[ #1203 ] Allow filtering tags based on an arbitray status
2018-01-18 18:26:14 +01:00
Paul Chavard
273b3f2faf
Remove data_provide
and data_date_format
attributes
2018-01-18 15:13:48 +01:00
gregoirenovel
813844f9db
Enable the Layout/TrailingWhitespace cop
2018-01-18 10:55:08 +01:00
gregoirenovel
d30ea70c08
Enable the Layout/SpaceInsideParens cop
2018-01-18 10:53:35 +01:00
gregoirenovel
b138dcd876
Enable the Layout/SpaceInsideHashLiteralBraces cop
2018-01-18 10:53:35 +01:00
gregoirenovel
897a30da0c
Enable the Layout/SpaceInsideBlockBraces cop
2018-01-18 10:53:34 +01:00
gregoirenovel
9ea1106503
Enable the Layout/SpaceInLambdaLiteral cop
2018-01-18 10:53:34 +01:00
gregoirenovel
3e93bd3615
Enable the Layout/SpaceBeforeComma cop
2018-01-18 10:53:34 +01:00
gregoirenovel
7c93b2a0c2
.map -> .pluck when possible
2018-01-16 13:23:29 +01:00
gregoirenovel
80ed589a17
Use string interpolation
2018-01-16 11:08:57 +01:00
gregoirenovel
83be054884
.map.flatten -> .flat_map
2018-01-16 11:08:56 +01:00
gregoirenovel
c3754a173f
Use map instead of inject
2018-01-16 11:08:56 +01:00
gregoirenovel
a050bc20de
Add a dossiers_from_avis relation to Gestionnaire
2018-01-16 11:01:52 +01:00
Paul Chavard
0cf40f4f18
Add invitation related methods to administrateur model
2018-01-16 10:49:07 +01:00
gregoirenovel
73dd58b6cd
Enable the Layout/MultilineMethodCallIndentation cop
2018-01-15 22:33:13 +01:00
gregoirenovel
14c1747645
Enable the Layout/MultilineArrayBraceLayout cop
2018-01-15 22:33:13 +01:00
gregoirenovel
345b892956
Enable the Layout/LeadingCommentSpace cop
2018-01-15 22:33:13 +01:00
gregoirenovel
1e71188d4d
Enable the Layout/IndentationConsistency cop
2018-01-15 22:33:13 +01:00
gregoirenovel
9e0e553f80
Enable the Layout/IndentArray cop
2018-01-15 22:33:12 +01:00
gregoirenovel
9f855afdfe
Enable the Layout/FirstHashElementLineBreak cop
2018-01-15 22:14:38 +01:00
gregoirenovel
08ed400ec2
Enable the Layout/FirstArrayElementLineBreak cop
2018-01-15 22:14:38 +01:00
simon lehericey
7024e14d1c
FC information: remove funny find_by
2018-01-15 17:14:12 +01:00
simon lehericey
f8519c5345
FC initializers: remove Hashie
2018-01-15 17:08:38 +01:00
simon lehericey
ec69be0f7b
FC ParticulierClient: simplier initializer
2018-01-15 17:00:26 +01:00
Simon Lehericey
0d46f92795
FC: move FC constants under particulier namespace
2018-01-15 16:59:50 +01:00
simon lehericey
4c2da46dd8
FC ParticulierClient: simplier initialize
2018-01-15 16:59:48 +01:00
gregoirenovel
1368cd4b03
[ Fix #1120 ] Delete the old accompagnateur UI
2018-01-15 10:02:10 +01:00
gregoirenovel
bbaebe0602
!foo.nil? -> foo.present?
2018-01-12 11:32:43 +01:00
gregoirenovel
7c34807f46
Don’t use unless
2018-01-12 11:32:43 +01:00
gregoirenovel
608a8eaf67
Abstract the Procedure whitelisting
2018-01-10 17:58:10 +01:00
simon lehericey
53687bf84a
Whitelist: add whitelist button in admin
2018-01-10 17:18:44 +01:00
Frederic Merizen
56749769d6
[ Fix #1186 ] Rename object to subject for mail templates
2018-01-09 16:00:31 +01:00
Frederic Merizen
7f040a5cf8
[ Fix #1037 ] Add date tags to mail / attestation templates
...
- date de dépôt
- date de passage en instruction
2018-01-09 11:30:54 +01:00
Frederic Merizen
935a38bde0
[ #1037 ] Introduce format-date
function
2018-01-09 11:30:54 +01:00
gregoirenovel
093d853ecc
Fix some buggy error handling code in Admin::ProcedureController#clone
2018-01-09 11:05:19 +01:00
Frederic Merizen
63ca52792b
[ #1110 ] Remove legacy tags
2018-01-09 10:39:10 +01:00
gregoirenovel
ec5b9c86ce
Add the admin argument to Procedure#clone
2018-01-08 14:55:07 +01:00
Frederic Merizen
75a3d0f3db
[ #1110 ] use modern rather than legacy tags in default mail templates
2018-01-05 17:42:25 +01:00
Frederic Merizen
deea23139f
[ #1110 ] Use TagsSubstitutionConcern as engine for mail template tags
2018-01-05 17:42:25 +01:00
Frederic Merizen
ab63f80080
[ #1110 ] Motivation and date de décision are only tags for terminé dossiers
2018-01-05 16:35:29 +01:00
Frederic Merizen
e985439416
[ #1110 ] Use tags method rather than ALLOWED_TAGS class constant
2018-01-05 12:48:07 +01:00
Frederic Merizen
b9a1f707f5
[ #1110 ] name => libelle in mail templates
...
to match attestation templates
2018-01-05 12:48:07 +01:00
Frederic Merizen
8d77cd58c6
[ #1110 ] Make linked procedure available to mail model
2018-01-05 12:48:07 +01:00
Frederic Merizen
ad0462f7ff
[ #1110 ] Port libellé procédure tag from mail templates
2018-01-05 11:51:08 +01:00
Frederic Merizen
ee109b24e3
[ #1110 ] Port date de décision tag from mail templates
2018-01-05 11:51:08 +01:00
Frederic Merizen
3dfc37826a
[ #1110 ] Extract document template concern from attestation template class
2018-01-05 10:57:27 +01:00
Frederic Merizen
b603af1ec7
[ #1110 ] Simplification: directly use symbols
2018-01-04 16:20:08 +01:00
Mathieu Magnin
7c0fdbc9f8
[ Fix #1096 ] Github Oauth
2017-12-22 11:10:24 +01:00
Simon Lehericey
40b9a77395
Dossier: replace nouveau scope by en_construction
2017-12-15 17:37:30 +01:00
Simon Lehericey
4be6cb9126
Dossier: delete state_nouveaux which is similar to en_construction
2017-12-15 17:37:30 +01:00
LeSim
7cc69de543
Dossier: remove useless state methods and const
2017-12-15 17:37:30 +01:00
Simon Lehericey
9c354e18eb
[fix 363] Dossier: remove next_step!
2017-12-15 15:43:30 +01:00
Simon Lehericey
e78f5b3a2d
[fix 363] Dossier: remove next_step! role var
2017-12-15 15:43:30 +01:00
Simon Lehericey
201862d450
[fix 363] Dossier: remove next_step! action = initiate, role = user
2017-12-15 15:43:30 +01:00
Simon Lehericey
907db89371
[fix 363] Dossier: remove next_step! action = follow
2017-12-15 15:43:30 +01:00
Simon Lehericey
11c010859c
[fix 363] Dossier: remove next_step! action = update
2017-12-15 15:43:30 +01:00
Simon Lehericey
629cccbf27
[fix 363] Dossier: remove next_step! action = comment
2017-12-15 15:43:30 +01:00
Simon Lehericey
c83552f423
[ fix #504 ] Dossier: without_continuation -> sans_suite
2017-12-15 12:10:54 +01:00
Simon Lehericey
2be9b8d2ba
[ fix #504 ] Dossier: refused -> refuse
2017-12-15 12:10:54 +01:00
Simon Lehericey
a13256f73d
[ fix #504 ] Dossier: closed -> accepte
2017-12-15 12:10:54 +01:00
LeSim
3dda27b281
[ fix #504 ] Dossier: received -> en_instruction
2017-12-15 12:10:54 +01:00
Simon Lehericey
72bae2c374
[ fix #504 ] Dossier: draft -> brouillon
2017-12-15 11:52:09 +01:00
LeSim
56545933a9
[ fix #504 ] Dossier: initiated -> en_construction
...
The change must not impact the api
2017-12-15 11:52:09 +01:00
Frederic Merizen
94f1a1fa0c
[ Fix #866 ] Allow use of non-breaking spaces in balise in attestation template
2017-12-14 17:22:21 +00:00
Mathieu Magnin
c6be745067
[ Fix #1016 ] display notifications for champs publics
2017-12-14 13:57:15 +01:00
gregoirenovel
e26911a47a
An Etablissement’s libelle is its Libellé NAF, not its name
2017-12-07 16:26:59 +01:00
Simon Lehericey
e2bbd2a37a
[ fix #992 ] export: dossiers are order by initiated_at
2017-12-01 13:45:53 +01:00
Mathieu Magnin
53bb7b07da
[ Fix #775 ] If champ type is a multiple drop down list then display it properly
2017-12-01 12:23:19 +01:00
gregoirenovel
731e1b6787
[ Fix #164 ] Make the organisme field mandatory
2017-11-29 10:36:22 +01:00
Mathieu Magnin
150ff5e7ca
New UI : Use RemoteDownloader class to hide ovh url
2017-11-28 15:07:10 +01:00
Mathieu Magnin
4d12aa222c
Validate body is present
2017-11-28 15:07:10 +01:00
Mathieu Magnin
6c39aba978
Validates commentaire file size
2017-11-28 15:07:10 +01:00
Mathieu Magnin
76cb54988d
Validate virus free with Clamav
2017-11-28 15:07:10 +01:00
Mathieu Magnin
5775901868
Add commentaire file uploader
2017-11-28 15:07:09 +01:00
Simon Lehericey
28a047a64b
[ Fix #508 ]Api GeoJson: export dossier.json_latlngs to geojson
2017-11-28 14:41:08 +01:00
Simon Lehericey
e28b18d978
Dossier: add statut method
2017-11-23 09:34:18 +01:00
Simon Lehericey
a71574b8dd
[ fix #445 ]: add title to pages
2017-11-21 17:47:27 +01:00
Mathieu Magnin
7bfafb6fc2
Fix export for yes_no champs
2017-11-21 10:36:24 +01:00
Simon Lehericey
ed4e885e6f
Notification: new acknowledgment system
2017-11-10 16:29:45 +01:00
Simon Lehericey
155a5f7826
Notification: add methods to retrieve notifications
2017-11-10 16:29:44 +01:00
Simon Lehericey
909ecf2142
Notification: add timestamp to champs, pieces jusitificatives and follows
2017-11-10 16:29:44 +01:00
Simon Lehericey
f4a8ff31b9
Champ: export multiple_drop_down_list as a [].join(', ')
2017-10-30 17:14:31 +01:00
Simon Lehericey
b658f8c8dc
Champ: export yes_no champ with oui non
2017-10-30 17:14:31 +01:00
Simon Lehericey
338911d1a8
[ fix #905 ] Champ: add for_export method which strips tag for textarea champ
2017-10-30 17:14:31 +01:00
Simon Lehericey
3f2419a2a3
Dossier: rename data_with_champs to to_sorted_values
2017-10-30 17:14:31 +01:00
Simon Lehericey
f0373f6bc2
Dossier: remove useless return
2017-10-30 17:14:31 +01:00
Simon Lehericey
fc987a730d
[ Fix #925 ] strip avis email input
2017-10-30 14:19:20 +01:00
Simon Lehericey
8dedf6fdca
[ fix #575 ] dossier updated_at is ... updated when children are updated
2017-10-24 18:12:25 +02:00
Mathieu Magnin
02c83766e5
[ Fix #839 ] Fix mail template modification by side effect
2017-10-23 14:36:52 +02:00
Mathieu Magnin
a8ec374252
[ Fix #813 ] When a brouillon is created, send an email to user
2017-10-20 12:13:55 +02:00
Simon Lehericey
3dce5b9b5e
AttestationTemplate: store logo and signature with uuid
2017-10-19 15:32:04 +02:00
gregoirenovel
9ea396cc8b
Avoid loading the association for the without_followers scope
...
As seen in https://stackoverflow.com/questions/5319400/want-to-find-records-with-no-associated-records-in-rails-3
2017-10-17 14:10:34 +02:00
Simon Lehericey
5257d20ba0
[fix #845 ] Attestation: affiche les dates au format français
2017-10-16 18:54:19 +02:00
Mathieu Magnin
0f945e2fea
Simplify mailer parameters to be serializable (even if mail_template.id is nil)
2017-10-13 21:27:17 +02:00
Mathieu Magnin
3ba5de88b6
[ Fix #839 ] Send notification email in async to avoid sending same email to different users
2017-10-13 17:41:02 +02:00
gregoirenovel
fd08bb8c57
Eager-load data for downloadable dossiers
...
So that the export is faster
2017-10-11 12:38:00 +02:00
Mathieu Magnin
17ce3885fd
Force commentaire order to avoid tests to fail randomly
2017-10-06 11:04:09 +02:00
Simon Lehericey
19b3416361
Gestionnaire: add unfollow method
2017-10-05 16:59:26 +02:00
gregoirenovel
a611cace5f
Do not allow to filter by explication fields
2017-10-05 14:46:09 +02:00
gregoirenovel
0705efde30
Add filtering to the dossiers table
2017-10-02 17:45:22 +02:00
gregoirenovel
3df9356021
Add field sort to the dossiers table
2017-10-02 17:45:22 +02:00
gregoirenovel
88ad986143
Remove the ordering from the dossier scopes
2017-10-02 17:45:22 +02:00
gregoirenovel
e1bdbec815
Allow the customization of the dossiers table
2017-10-02 17:45:22 +02:00
gregoirenovel
7036f9778b
Add ProcedurePresentation
2017-10-02 17:03:30 +02:00
Simon Lehericey
2b760c85c4
[ Fix #763 ] Add annotations_privees to buggy annotation system
2017-09-27 15:08:34 +02:00
Simon Lehericey
f2e1480c73
Notifications: add annotations_privees
2017-09-27 12:16:33 +02:00
Simon Lehericey
04d1e0f0e8
Notification: instruction -> avis
2017-09-27 12:16:33 +02:00
Simon Lehericey
fb5472d3f6
Dossier: remove a_instruire scope
...
As it s a duplication of en_instruction
2017-09-26 14:42:54 +02:00
Simon Lehericey
1cfeb10ce9
[ Fix #503 ] Dossier: remove updated
2017-09-26 14:42:54 +02:00
Simon Lehericey
633b55aca0
[ Fix #503 ] Dossier: remove replied
2017-09-26 14:42:54 +02:00
Simon Lehericey
030a11d98c
[ Fix #503 ] Dossier: remove unused ouvert state
2017-09-26 14:42:54 +02:00
Simon Lehericey
73357c5144
[ Fix #503 ] Dossier: Remove waiting for gestionnaire scope
2017-09-26 14:42:54 +02:00
Simon Lehericey
460cd3e237
[ Fix #503 ] Dossier: Remove waiting for user scope
2017-09-26 14:42:54 +02:00
Simon Lehericey
fdbf34f04b
Avis instruction: only authorized avis
2017-09-20 15:42:26 +02:00
Mathieu Magnin
31995c270c
[ Fix #721 ] If an avis is created with uppercase email, downcase it before save
2017-09-13 10:59:59 +02:00
Simon Lehericey
a298c48e8f
Dossier: add notification icon
2017-09-06 11:13:50 +02:00
Simon Lehericey
fbd16b8c75
Procedure show: add notification icon
2017-09-06 11:11:47 +02:00
Simon Lehericey
3e93d21bf5
Procedure Index: add notification icon
2017-09-06 11:11:47 +02:00
Simon Lehericey
faf2d2814b
Champ: fix indentation
2017-09-06 11:11:40 +02:00
Simon Lehericey
3e5d0dce6a
NewDesign: can add annotations
2017-09-06 11:11:37 +02:00
Simon Lehericey
d4bbcdf682
Champ: add before save logic to serialize datetime and dropdownlist fields
2017-09-06 11:11:35 +02:00
Simon Lehericey
74c71a3776
Form: use rails form helper
2017-09-06 11:11:34 +02:00
Simon Lehericey
9c2e71afa3
Form: add various champs html and style
2017-09-06 11:11:29 +02:00
gregoirenovel
7ff7710803
A gestionnaire can only see procédures publiées
2017-09-06 11:11:26 +02:00
Simon Lehericey
0d27ca3bca
Commentaire: use scope to order commentaires association
2017-09-06 11:11:25 +02:00
Simon Lehericey
95fbd1824a
Follow: remove old backoffice follow and toggle_follow
2017-09-06 11:11:22 +02:00
Simon Lehericey
e68f3332c1
Gestionnaire: add follow(dossier) method
2017-09-06 11:11:21 +02:00
Simon Lehericey
033f08524f
Gestionnaire: refactor follow?
2017-09-06 11:11:21 +02:00
Simon Lehericey
0d3c145ef3
NewDesign: procedure show add dossier actions
2017-09-06 11:11:12 +02:00
Simon Lehericey
013f2463d1
NewDesign: procedure show add dossier status
2017-09-06 11:11:12 +02:00
Simon Lehericey
b48af51ee9
NewDesign: procedure show only header
2017-09-06 11:11:11 +02:00
Simon Lehericey
5737ebd090
Dossier: workaround preview bug linked to champs with dossier.id == 0
2017-08-29 16:30:34 +02:00
gregoirenovel
79eccb2de0
Add a method to speed up a conditional statement
2017-08-29 14:57:23 +02:00
gregoirenovel
0a8ac645d8
Shave some requests in build_default_champs
2017-08-29 14:22:14 +02:00
Simon Lehericey
a7b00ee847
Rubocop: enable Layout/SpaceAroundOperators
2017-08-28 13:39:13 +02:00
Simon Lehericey
62f1b9c712
Rubocop: enable indentation width rule
2017-08-28 12:20:58 +02:00
Mathieu Magnin
dd1fea78ac
[ Fix #658 ] when dossier linked to avis is hidden, do not crash application
2017-08-28 10:11:50 +02:00
Simon Lehericey
d40eef284d
Dossier: fixup n+1 champ query
2017-08-03 13:02:13 +02:00
Simon Lehericey
1363999621
Dossier: fixup n+1 private champ query
2017-08-03 13:01:55 +02:00
Mathieu Magnin
539fc682a0
Format date to iso with dedicated method
2017-08-01 16:47:44 +02:00
Mathieu Magnin
03fde0a502
[ FIX #589 ] Force birthdate format when saving
2017-08-01 16:47:43 +02:00
Simon Lehericey
7016bdc49a
Avis: move assign_gestionnaire logic to avis model
2017-07-21 11:22:16 +02:00
Simon Lehericey
fe1b97b738
Avis: move notify_gestionnaire to private method
2017-07-21 11:19:18 +02:00
Simon Lehericey
5ec0e2ed18
Dossier: remove unused ordered_commentaires
...
as commentaires are sorted on the view _messagerie.haml.html
dossier_facade.commentaires.object.sort
2017-07-20 11:03:10 +02:00
Mathieu Magnin
b0c0477622
[ Fix #315 ] Order champs by procedure order in export
2017-07-19 16:31:30 +02:00
gregoirenovel
1c1a47d83a
publiee_ou_archivee -> publiees_ou_archivees
2017-07-17 15:06:36 +02:00
gregoirenovel
32e0fa9f69
Add Procedure#publiee_ou_archivee?
2017-07-13 17:01:39 +02:00
gregoirenovel
2b7a148540
Remove Procedure#published?
2017-07-13 17:01:38 +02:00
gregoirenovel
36bee67085
Add Procedure#brouillon?
2017-07-13 17:01:38 +02:00
gregoirenovel
9a7d5d1833
Add Procedure#publiee?
2017-07-13 15:44:18 +02:00
gregoirenovel
cfec05506a
Rename Procedure#archived? -> #archivee?
2017-07-13 15:32:13 +02:00
gregoirenovel
07d390db09
Remove comments that were wrong
...
Having a foo_at column automatically generates the
#foo_at? method, not the #foo? method
2017-07-13 14:46:09 +02:00
gregoirenovel
c43f3fa415
Improve the formatting of the Procedure scopes
2017-07-13 14:46:09 +02:00
gregoirenovel
2f4f10683f
Delete now unused scopes on Procedure
2017-07-13 14:46:09 +02:00
gregoirenovel
75aebe4f07
Add the archivees scope on Procedure
2017-07-13 14:46:09 +02:00
gregoirenovel
89feb6cdf7
Add the brouillons scope on Procedure
2017-07-13 14:46:08 +02:00
gregoirenovel
fc2540649f
Add the publiees scope on Procedure
2017-07-13 14:46:07 +02:00
gregoirenovel
ab9cf1c351
Rename the published scope on Procedure
2017-07-13 14:40:41 +02:00
gregoirenovel
bb10e13e2f
[Ref #145 ] Don't use Procedure.archived anymore
2017-07-11 15:03:35 +02:00
gregoirenovel
f55b7914cf
[Ref #144 ] Don't use Procedure.published anymore
2017-07-11 14:51:43 +02:00
gregoirenovel
6a381caaee
Add the archived scope to Procedure
2017-07-10 17:24:53 +02:00
gregoirenovel
31b23ac74e
Add the not_published Procedure scope
2017-07-10 17:24:39 +02:00
gregoirenovel
3a602b05a4
Use the archived and not_archived Dossier scopes
2017-07-10 16:54:02 +02:00
gregoirenovel
f480f26bd4
Use the state_not_brouillon Dossier scope
2017-07-10 16:54:02 +02:00
gregoirenovel
09d596eec1
Remove a useless call to all
2017-07-10 16:54:02 +02:00
gregoirenovel
5f50f76341
Add the published scope en Procedure
2017-07-10 16:54:01 +02:00
Mathieu Magnin
ce171208da
Fix redirect loop for gestionnaire if hidden procedure is saved in procedure_filter
2017-07-04 14:34:26 +02:00
Mathieu Magnin
be3304f71e
Add a scope to Dossier to check if procedure is not hidden
2017-07-04 14:34:16 +02:00
Mathieu Magnin
760efcdad3
Add hidden_at on procedure
2017-07-04 14:33:40 +02:00
gregoirenovel
6b90e0ccfa
[Ref #145 ] Record archived_at when archiving a procedure
2017-07-03 10:18:49 +02:00
Simon Lehericey
603e2dd020
ProcedureOverview: reboot model and layout
2017-06-29 16:07:46 +02:00
Simon Lehericey
ee415c4aa6
[ FIX #509 ] add dossier id tag in attestation template
2017-06-28 10:59:14 +02:00
gregoirenovel
aeeb0dd22f
[ Fix #170 ] Keep drop down menu values for annot. privées when cloning
2017-06-27 14:31:33 +02:00
gregoirenovel
556359cd05
[ Fix #318 ] Add annotations privées to exported files
2017-06-27 14:27:02 +02:00
gregoirenovel
cf5398fe99
Record published_at when publishing a procedure
2017-06-27 13:55:17 +02:00
Simon Lehericey
3d99407495
[ Fix #499 ] Attestation: add maxlength to footer
2017-06-27 13:35:01 +02:00
Simon Lehericey
84e3d8fbe0
Attestation_template: use etablissement inline_adresse
2017-06-27 11:15:25 +02:00
Simon Lehericey
d69d0f8a78
Etablissement: add inline_adresse
2017-06-27 11:15:25 +02:00
Simon Lehericey
e60ce35ae8
[ Fix #196 ] Attestation: join the attestation to the closed mail
...
Add a upper limit to the attachment size as it could be a problem with Mailjet and receiver
(https://www.mailjet.com/support/what-is-the-size-limit-for-attachments-files-sent-via-mailjet,289.htm )
If the attestation cannot be sent, it is logged in sentry
2017-06-16 12:11:10 +02:00
Simon Lehericey
602527a09d
[ Fix #196 ] Attestation: building logic from template
2017-06-16 12:11:09 +02:00
Simon Lehericey
b443b5cefd
[ Fix #196 ] Dossier: add Attestation
2017-06-16 12:11:09 +02:00
Simon Lehericey
fdb4d15bcf
[ Fix #196 ] AttestationTemplate: add edition
2017-06-16 12:11:09 +02:00
Simon Lehericey
d7ff3d6139
[ Fix #196 ] AttestationTemplate: add model
2017-06-16 11:35:13 +02:00
gregoirenovel
0120995533
[ Fix #197 ] Add the TAG_MOTIVATION email tag
2017-06-13 15:14:50 +02:00
gregoirenovel
b58c02180c
[ Fix #197 ] Allow a gestionnaire to add a motivation
2017-06-13 15:14:50 +02:00
gregoirenovel
f1d66e40c3
Enable the Layout/EmptyLinesAroundModuleBody cop
2017-06-13 10:35:34 +02:00
gregoirenovel
82eb66cfe8
Enable the Layout/EmptyLinesAroundMethodBody cop
2017-06-13 10:35:33 +02:00
gregoirenovel
24e7537c49
Enable the Layout/EmptyLinesAroundClassBody cop
2017-06-13 10:35:32 +02:00
gregoirenovel
f1907f4d0e
Enable the Layout/EmptyLinesAroundBlockBody cop
2017-06-13 10:35:23 +02:00
gregoirenovel
9439e1abb1
Enable the Layout/AlignParameters cop
2017-06-13 10:35:16 +02:00
gregoirenovel
50fad54538
Enable the Layout/AlignArray cop
2017-06-13 10:35:15 +02:00
gregoirenovel
3f44b963c8
Fix the wording of the initiated email’s subject
2017-06-12 16:17:07 +02:00
Mathieu Magnin
b9522ce404
[ Fix #376 ] Before save format champ date to ISO
2017-06-12 14:05:31 +02:00
Mathieu Magnin
41a5ed59f3
[ Fix #376 ] Force every browser to use native input[type=date] on date champ
2017-06-12 14:05:31 +02:00
gregoirenovel
2a74207d15
you_are_invited_on_dossier -> avis_invitation
...
- shorter
- clearer
2017-06-12 10:53:59 +02:00
gregoirenovel
107c322062
[ Fix #323 ] Refactor received dossier notification: use a callback
2017-06-08 15:06:01 +02:00
gregoirenovel
585a5bcaba
Add TEMPLATE_NAME to Mail classes
2017-06-08 12:22:49 +02:00
gregoirenovel
ec69086ebc
Don’t use alias_method_chain, use a proxy method
2017-06-08 12:22:48 +02:00
gregoirenovel
07ea0ceea1
Make MailTemplateConcern.slug a constant
2017-06-08 12:22:44 +02:00
gregoirenovel
9988444459
Remove useless blank lines
2017-06-08 12:22:40 +02:00
gregoirenovel
e06ddeb168
Make all Mails classes inherit from ApplicationRecord
2017-06-08 12:22:38 +02:00
gregoirenovel
5a59115df4
Refactor the TAGS management in MailTemplateConcern
2017-06-08 12:22:36 +02:00
gregoirenovel
1794da5a30
[ Fix #234 ] Remove dynamic email templates handling code in Procedure
2017-06-07 10:10:15 +02:00
gregoirenovel
d5023a3d38
Use the same order for constants and scopes in Dossier
2017-06-01 11:08:26 +02:00
gregoirenovel
0971ede57e
Add a termine scope to Dossier
2017-06-01 11:08:00 +02:00
gregoirenovel
68da2ecbae
Use symbols instead of strings in for the order arg in scopes
2017-06-01 11:07:30 +02:00
gregoirenovel
8fb6a41386
Remove an unused argument in some Dossier scopes
2017-06-01 11:07:04 +02:00
gregoirenovel
e0a3a48f76
Improve the formatting of Dossier scopes
2017-06-01 11:05:51 +02:00
gregoirenovel
ddac4bbfdb
Change the order in the all_state scope for consistency
2017-06-01 10:58:09 +02:00
gregoirenovel
7055aec634
Add some more state scopes and use them
2017-06-01 10:58:09 +02:00
gregoirenovel
9c2c0346b6
[ Fix #125 ] Transform some Dossier class methods into scopes
2017-06-01 10:58:08 +02:00
gregoirenovel
ab1c19c09b
Rename some Dossier scopes
2017-06-01 10:58:08 +02:00
gregoirenovel
51dd6df1c0
Improve the formatting of the Dossier state enum
2017-06-01 10:58:08 +02:00
gregoirenovel
1816aef7d0
Group the Dossier scopes and move them at the top
2017-06-01 10:58:07 +02:00
gregoirenovel
6731f28e23
Move the state constants below the state enum
2017-06-01 10:58:07 +02:00
Mathieu Magnin
068b635b7c
Add the weekly avis answer time average to Stats
2017-05-31 14:24:32 +02:00
gregoirenovel
9268da8236
Refactor Procedure#switch_list_order
2017-05-30 15:54:49 +02:00
gregoirenovel
04845efdfc
Remove inconsistent and useless blank lines in models
2017-05-30 15:53:19 +02:00
gregoirenovel
d47e8b3702
Reformat Notification correctly
2017-05-30 15:53:19 +02:00
gregoirenovel
9f6edc5d1e
Format the TypeDeChamp type_champs enum correctly
2017-05-30 15:52:29 +02:00
gregoirenovel
843bb9fd2c
Format the User loged_in_with_france_connect enum correctly
2017-05-30 15:52:28 +02:00
gregoirenovel
258a80b0d7
Use the Procedure not_archived scope
2017-05-30 15:52:28 +02:00
gregoirenovel
9d478609d0
Move the Procedure scopes at the top
2017-05-30 15:52:28 +02:00
gregoirenovel
4655707eb5
[ Fix #319 ] Include archived dossiers in the export
2017-05-30 15:41:35 +02:00
gregoirenovel
5253f07b69
Use the order_by_updated_at scope in Dossier
2017-05-30 15:41:35 +02:00
gregoirenovel
7eed44d430
Use the not_archived scope in Dossier
2017-05-30 15:41:35 +02:00
gregoirenovel
f2fe06e86f
Add the not_brouillon scope on Dossier
2017-05-30 15:41:35 +02:00
Simon Lehericey
ae8b126594
ProcedureOverview: use procedure_url to link with absolute path in email
2017-05-30 15:03:51 +02:00
Simon Lehericey
64f7cab3cf
Avis: add claimant gestionnaire to track who asks for an avis
2017-05-29 11:44:28 +02:00
Simon Lehericey
cdcd5b951f
AvisController: add a notification when a avis has been received
2017-05-29 11:44:28 +02:00
Simon Lehericey
aaf155df72
Avis: add sign_up logic for new tps gestionnaire
2017-05-29 11:44:28 +02:00
Mathieu Magnin
4e064dbaed
Add a method to link multiple avis to a gestionnaire by his email
2017-05-29 11:44:28 +02:00
Mathieu Magnin
efdac753c6
When an Avis is created an email is sent to the Gestionnaire
2017-05-29 11:44:28 +02:00
Simon Lehericey
f6359cb7aa
gestionnaire invited on dossier for avis, can update Avis
2017-05-29 11:44:28 +02:00
Mathieu Magnin
f24e4a77d3
Gestionnaire can view dossier if he is invited on dossier
2017-05-29 11:44:28 +02:00
Mathieu Magnin
d07943a55d
Add by_latest scope in Avis
2017-05-29 11:44:28 +02:00
Mathieu Magnin
7c662aa7b2
Gestionnaire invited on dossier for avis, cannot see private form / change dossier state / follow dossier / see invited people / see others avis
2017-05-29 11:44:28 +02:00
Mathieu Magnin
43f481b7ff
Gestionnaire can list dossiers where he is invited for avis
2017-05-29 11:44:28 +02:00
Mathieu Magnin
c3bf15d49f
Create and list Avis on Dossier detail page
2017-05-29 11:44:28 +02:00
Mathieu Magnin
72494de76f
Create new model Avis
2017-05-29 11:44:28 +02:00
Simon Lehericey
e630548110
Gestionnaire: add last_week_overview method
2017-05-23 17:12:18 +02:00
Simon Lehericey
e7d39ca650
ProcedureOverview: add object to contain overview logic
2017-05-23 17:12:18 +02:00
gregoirenovel
a58a8684d9
[ Fix #285 ] Gestionnaire.dossiers_follow -> followed_dossiers
2017-05-15 15:51:51 +02:00
gregoirenovel
f67aa63766
[ Fix #285 ] Use a has_many through for Gestionnaire#dossiers_follow
2017-05-15 15:51:51 +02:00
gregoirenovel
8ba55a0d5d
Mutualize the email address in a localised string
2017-05-12 16:53:03 +02:00
gregoirenovel
8a5420301c
Add Commentaire#notify to dispatch notifications
2017-05-12 16:31:03 +02:00
gregoirenovel
1235fce34a
Refactor Commentaire#notify_user
2017-05-12 16:31:02 +02:00
gregoirenovel
c07b83b266
Commentaire#notify_user_with_mail -> #notify_user
2017-05-12 16:31:02 +02:00
gregoirenovel
9c3cde2b2e
Move CommentairesController#notify_user_user_with_mail to Commentaire
2017-05-12 16:31:02 +02:00
gregoirenovel
cae3e1f420
Commentaire#internal_notification => #notify_gestionnaires
2017-05-12 16:31:02 +02:00
Mathieu Magnin
58abd9eaf1
Fix #276 Rewrite #dossiers_with_notifications_count_for_procedure and add tests
2017-05-12 15:42:33 +02:00
Mathieu Magnin
8f5fdfa81f
Rename dossier_with_notification_for
2017-05-12 15:42:33 +02:00
Simon Lehericey
cebb197994
Fix #171 : add localtime to a bunch of date
2017-05-11 15:10:49 +02:00
gregoirenovel
2582b44f07
[ Fix #204 ] Add the date_de_decision tag
2017-05-04 16:17:53 +02:00
gregoirenovel
3bd5e32dff
Add a system to restrain the email templates tags to specific templates
2017-05-04 16:17:39 +02:00
gregoirenovel
30cf475485
Add missing brackets in mail_template_concern.rb
2017-05-04 16:17:39 +02:00
gregoirenovel
f389bbeb53
Fix indentation in mail_template_concern.rb
2017-05-04 16:17:38 +02:00
gregoirenovel
4303dcef2c
Organisation -> Organisme
2017-05-04 11:35:22 +02:00
gregoirenovel
d3a84eb20a
Démarche -> Procédure
2017-05-04 11:33:26 +02:00
gregoirenovel
988947696e
[ Fix #161 ] Remove incorrect commas from Dossier#text_summary
2017-05-04 11:25:33 +02:00
Mathieu Magnin
6ef6a66c3f
Remove @facade_data_view from left_panel view
2017-04-26 16:55:22 +02:00
gregoirenovel
f5c5ad532d
Add Dossier#text_summary
2017-04-26 15:59:17 +02:00
Mathieu Magnin
887512c26c
Procedure path can contain dashes and can be longer
2017-04-21 16:32:48 +02:00
Mathieu Magnin
757af12d42
Add invites to API
2017-04-21 14:51:35 +02:00
Mathieu Magnin
40d897f538
Add accompagnateurs emails in API
2017-04-21 14:51:35 +02:00
Mathieu Magnin
822c7cdd96
Add human version translation for state
2017-04-21 14:51:35 +02:00
Mathieu Magnin
762a11fc6f
Define .termine as a scope and remove archived=false filter
2017-04-21 14:36:50 +02:00
Mathieu Magnin
320ff4839f
Define .en_instruction as a scope and remove archived=false filter
2017-04-21 14:36:50 +02:00
Mathieu Magnin
7a9fd77af0
Remove archived=false filter from en_construction scope (Fix : archived dossier is not shown to user)
2017-04-21 14:36:50 +02:00
Mathieu Magnin
688a3d8f31
Define .brouillon as a scope and remove archived=false filter
2017-04-21 14:36:50 +02:00
Mathieu Magnin
21a2a5402b
Remove unused service
2017-04-21 14:36:50 +02:00
gregoirenovel
b00eb914da
Use case statements instead of if statements where appropriated
2017-04-19 11:57:49 +02:00
gregoirenovel
ddf02ccd6d
Use a non-breaking space after the “numéro” contraction
2017-04-19 11:19:53 +02:00
gregoirenovel
aa41349f0c
Lowercase the “n” of “numéro” contraction where needed
2017-04-19 11:19:53 +02:00
gregoirenovel
ba4ee68019
Use masculine ordinal indicator instead of the degree sign
...
It’s the right way to contract “numéro”
We should use the superscript lowercase o but
it’s hard to do in places where only raw text is
available
2017-04-19 11:19:53 +02:00
Simon Lehericey
4c74b04a91
Commentaire: use fr local to display date
2017-04-19 10:06:22 +02:00
Mathieu Magnin
1612b60126
Remove useless code
2017-04-13 16:54:00 +02:00
Mathieu Magnin
320d5da40f
Add individual infos to flat table export serializer
2017-04-13 16:54:00 +02:00