Sha256: 21029da8a7c45c6c4c708273c6ae021dc5e0c1a06f59bb03c821dfb320b9ff8c

Contents?: true

Size: 1.33 KB

Versions: 74

Compression:

Stored size: 1.33 KB

Contents

= simple_form_for [patient, training_session],
                  as: :training_session,
                  html: { autocomplete: "off" },
                  wrapper: "horizontal_form" do |f|

  / This hidden input exists only so that posted form params have 'training_session' at the top
  / eg params[:training_session][:document], otherwise we just get params[:document] and that would
  / confound our .permit/.require expectations in the controller.
  = f.input :ignore_me, as: :hidden
  = f.association :training_site,
      collection: Renalware::PD::TrainingSite.ordered,
      wrapper: :horizontal_small

  = f.association :training_type,
      collection: Renalware::PD::TrainingType.ordered,
      wrapper: :horizontal_medium

  = f.simple_fields_for :document, training_session.document do |fdoc|
    = fdoc.input :started_on, as: :date_picker, wrapper: :horizontal_datepicker
    = fdoc.input :trainer, wrapper: :horizontal_medium
    = fdoc.input :training_duration,
            collection: Renalware::PD::TrainingDurationPresenter.dropdown_options,
            wrapper: :horizontal_small
    = fdoc.input :outcome, as: :inline_radio_buttons, wrapper: :horizontal_medium
    = fdoc.input :training_comments, as: :text, input_html: { rows: 5 }

  = f.submit "Save", class: "button"
  span= " or "
  = link_to "cancel", patient_pd_dashboard_path(patient)

Version data entries

74 entries across 74 versions & 1 rubygems

Version Path
renalware-core-2.0.69 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.68 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.67 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.64 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.63 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.62 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.61 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.60 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.58 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.57 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.56 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.55 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.54 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.53 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.52 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.51 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.50 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.48 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.47 app/views/renalware/pd/training_sessions/_form.html.slim
renalware-core-2.0.46 app/views/renalware/pd/training_sessions/_form.html.slim