12 lines
591 B
Text
12 lines
591 B
Text
.piece-justificative
|
|
- if pj.attached?
|
|
.piece-justificative-actions{ id: "piece_justificative_#{object.id}" }
|
|
.piece-justificative-action
|
|
= render partial: "shared/attachment/show", locals: { attachment: pj.attachment, user_can_upload: true }
|
|
.piece-justificative-action
|
|
= button_tag 'Remplacer', type: 'button', class: 'button small', data: { 'toggle-target': "#champs_#{object.id}" }
|
|
|
|
= form.file_field :piece_justificative_file,
|
|
id: "champs_#{object.id}",
|
|
class: "piece-justificative-input #{'hidden' if pj.attached?}",
|
|
direct_upload: true
|