diff --git a/app/components/admin/budget_phases/form_component.html.erb b/app/components/admin/budget_phases/form_component.html.erb index 9bc83b917..dc0ed15ea 100644 --- a/app/components/admin/budget_phases/form_component.html.erb +++ b/app/components/admin/budget_phases/form_component.html.erb @@ -16,11 +16,11 @@

- <%= f.date_field :starts_at, id: "start_date" %> + <%= f.date_field :starts_at, id: "start_date", hint: t("admin.budget_phases.edit.dates_help_text") %>
- <%= f.date_field :ends_at, id: "end_date" %> + <%= f.date_field :ends_at, id: "end_date", hint: t("admin.budget_phases.edit.dates_help_text") %>
diff --git a/config/locales/en/admin.yml b/config/locales/en/admin.yml index ae68400d0..0b7a95011 100644 --- a/config/locales/en/admin.yml +++ b/config/locales/en/admin.yml @@ -213,6 +213,7 @@ en: budget_phases: edit: title: "Edit phase" + dates_help_text: "For information purposes only" description_help_text: This text will appear in the header when the phase is active duration: "Phase's duration" duration_description: "These fields are used for information purposes only and do not trigger an automatic update of the active phase. In order to update it, edit the budget and select the active phase." diff --git a/config/locales/es/admin.yml b/config/locales/es/admin.yml index a77b2148a..5658d3190 100644 --- a/config/locales/es/admin.yml +++ b/config/locales/es/admin.yml @@ -212,6 +212,7 @@ es: title: "Partidas de %{budget} / %{group}" budget_phases: edit: + dates_help_text: "Solo con fines informativos" description_help_text: Este texto aparecerá en la cabecera cuando la fase esté activa duration: "Duración de la fase" duration_description: "Estos campos se utilizan únicamente con fines informativos y no provocan una actualización automática de la fase activa. Para actualizarla, edita el presupuesto y selecciona la fase activa." diff --git a/spec/system/admin/budget_phases_spec.rb b/spec/system/admin/budget_phases_spec.rb index f30cd3fc8..0ea1dd612 100644 --- a/spec/system/admin/budget_phases_spec.rb +++ b/spec/system/admin/budget_phases_spec.rb @@ -10,6 +10,7 @@ describe "Admin budget phases" do expect(page).to have_content "These fields are used for information purposes only and do not trigger "\ "an automatic update of the active phase. In order to update it, edit "\ "the budget and select the active phase." + expect(page).to have_content "For information purposes only" fill_in "start_date", with: Date.current + 1.day fill_in "end_date", with: Date.current + 12.days