initial commit

This commit is contained in:
2023-09-07 14:23:30 -05:00
commit 857aa1af52
213 changed files with 5930 additions and 0 deletions

View File

@@ -0,0 +1,5 @@
h1 Opponents
- for opponent in opponents
a.Panel-cell href=url_for( opponent_path :team_id=>team.id, :opponent_id=>opponent.id)
li #{opponent.name}

View File

@@ -0,0 +1,36 @@
.Panel
.Panel-header
.Panel-title #{opponent.name}
.Panel-body
.Panel-row.Panel-row--withCells
.Panel-cell.Panel-cell--header ID
.panel-cell =opponent.id
Button class="Button" onclick="navigator.clipboard.writeText('#{opponent.id}');"
i.bi.bi-clipboard.Icon
.Panel-row.Panel-row--withCells
.Panel-cell.Panel-cell--header Contact Name
.panel-cell #{opponent.contacts_name}
.Panel-row.Panel-row--withCells
.Panel-cell.Panel-cell--header Contact Phone
.panel-cell #{opponent.contacts_phone}
.Panel-row.Panel-row--withCells
.Panel-cell.Panel-cell--header Contact Email
.panel-cell #{opponent.contacts_email}
.Panel-row.Panel-row--withCells
.Panel-cell.Panel-cell--header Logo
.panel-cell
- if opponent_logo
img(src="#{opponent_logo.medium_url}" width="64" height="64")
a class="Button" target="_blank" rel="noopener noreferrer" href="https://go.teamsnap.com/#{team.id}/files/view/#{opponent_logo.id}"
i class="bi bi-asterisk Icon"
- else
- if opponent_logo.team_media_group.id
a class="Button" target="_blank" rel="noopener noreferrer" href="https://go.teamsnap.com/#{team.id}/files/list/#{opponent_logo.team_media_group.id}" Upload
- else
a class="Button" target="_blank" rel="noopener noreferrer" href="https://go.teamsnap.com/#{team.id}/files/" Upload
Button class="Button" onclick="navigator.clipboard.writeText('opponent-logo-#{opponent.id}.png')"
i.bi.bi-clipboard.Icon
span Copy Filename
.Panel-row.Panel-row--withCells
.Panel-cell.Panel-cell--header Notes
.panel-cell #{opponent.notes}

View File

@@ -0,0 +1,9 @@
= form_with url: "/#{team_id}/opponent/#{opponent_id}/upload_logo", method: :post do |form|
.Panel
.Panel-header
.Panel-title Upload
.Panel-body
.Panel-row.Panel-row--withCells
.Panel-cell.Panel-cell--header = form.label :file, "Select file"
.Panel-cell = form.file_field :file
.Panel-cell = form.submit "Submit", class: 'Button'