Compare commits
2 Commits
add-me-sui
...
show-perso
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ed7d8511d5 | ||
|
|
f4899ae6b0 |
Binary file not shown.
|
Before Width: | Height: | Size: 26 KiB |
@@ -6,7 +6,7 @@
|
||||
<%= form.email_field :email, class: "form-group" %>
|
||||
<%= form.password_field :password %>
|
||||
<%= form.text_field :account_name, label: 'Account Name' %>
|
||||
<%= form.select :interested_product_name, options_for_select(["I'm interested in all products", "ME Suite PRO", "DirectME", "ReleaseME", "CastME", "EditME", "DeliverME", "ExpenseME"]), { label: "What product are you most interested in?" }, { class: "form-control custom-select" } %>
|
||||
<%= form.select :interested_product_name, options_for_select(["I'm interested in all products", "DirectME", "ReleaseME", "CastME", "EditME", "DeliverME", "ExpenseME"]), { label: "What product are you most interested in?" }, { class: "form-control custom-select" } %>
|
||||
<div class="pt-3">
|
||||
<%= form.submit "Start Free Trial", class: "btn btn-block btn-danger font-weight-bold" %>
|
||||
</div>
|
||||
|
||||
@@ -4,9 +4,6 @@
|
||||
<h3>Welcome To <%= suite_wordmark("d-inline-block") %></h3>
|
||||
<div class="mt-4">
|
||||
<p>Sign up for a <strong>14 Day Free Trial</strong> which includes full access to the following products. No credit card required!</p>
|
||||
<div class="d-flex justify-content-between pb-2">
|
||||
<div><%= image_tag "ME_PRO_black.png", width: "96.66%" %></div>
|
||||
</div>
|
||||
<div class="d-flex justify-content-between pb-2">
|
||||
<div><%= image_tag "logo_directme.png", width: "90%" %></div>
|
||||
<div><%= image_tag "logo_releaseme.png", width: "90%" %></div>
|
||||
|
||||
37
app/views/contracts/_logo_page.html.erb
Normal file
37
app/views/contracts/_logo_page.html.erb
Normal file
@@ -0,0 +1,37 @@
|
||||
<% has_logo = local_assigns[:logo] %>
|
||||
<% has_user_photo = releasable.model_name == "AppearanceRelease" && releasable.person_photo.attached? %>
|
||||
|
||||
<% if has_logo || has_user_photo %>
|
||||
<table class="heading-table">
|
||||
<tr>
|
||||
<td>
|
||||
<% if has_logo %>
|
||||
<div class="logo">
|
||||
<%= render "blank_contracts/logo", logo: logo %>
|
||||
</div>
|
||||
<% end %>
|
||||
</td>
|
||||
<td class="embed-person-photo">
|
||||
<% if has_user_photo %>
|
||||
<%= image_tag releasable.photos.first.variant(auto_orient: true, resize: "200x200"), id: "top-person-photo" %>
|
||||
<% end %>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<hr>
|
||||
<% end %>
|
||||
|
||||
<% if preview %>
|
||||
<h1>PREVIEW ONLY</h1>
|
||||
<% end %>
|
||||
|
||||
<% if contract_template.body.present? %>
|
||||
<%= contract_template.body %>
|
||||
<br/>
|
||||
<% end %>
|
||||
|
||||
<% if releasable.minor? && contract_template.guardian_clause.present? %>
|
||||
<p class="text-left"><strong>Guardian Clause</strong></p>
|
||||
<%= contract_template.guardian_clause %>
|
||||
<% end %>
|
||||
@@ -1,33 +1,12 @@
|
||||
<% if local_assigns[:logo] %>
|
||||
<div class="logo">
|
||||
<%= render "contracts/logo", logo: logo %>
|
||||
<% logo = local_assigns[:logo] ? local_assigns[:logo] : nil %>
|
||||
|
||||
<% if logo || (releasable.model_name == 'AppearanceRelease' && releasable.person_photo.attached?) ||
|
||||
contract_template.body.present? || (releasable.minor? && contract_template.guardian_clause.present?) %>
|
||||
<div class="page">
|
||||
<%= render "contracts/logo_page", logo: logo, preview: preview, releasable: releasable, contract_template: contract_template %>
|
||||
</div>
|
||||
<hr>
|
||||
<% end %>
|
||||
|
||||
<div class="page">
|
||||
<% if preview %>
|
||||
<h1>PREVIEW ONLY</h1>
|
||||
<% end %>
|
||||
|
||||
<% if releasable.model_name == "AppearanceRelease" && releasable.person_photo.attached? %>
|
||||
<div class="embed-person-photo">
|
||||
<%= image_tag releasable.photos.first.variant(auto_orient: true, resize: "200x200"), id: "top-person-photo" %>
|
||||
</div>
|
||||
<hr>
|
||||
<% end %>
|
||||
|
||||
<% if contract_template.body.present? %>
|
||||
<%= contract_template.body %>
|
||||
<br/>
|
||||
<% end %>
|
||||
|
||||
<% if releasable.minor? && contract_template.guardian_clause.present? %>
|
||||
<p class="text-left"><strong>Guardian Clause</strong></p>
|
||||
<%= contract_template.guardian_clause %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<% if contract_template.present? && contract_template.has_questionnaire? %>
|
||||
<div class="page">
|
||||
<%= render "contracts/questionnaire", releasable: releasable, contract_template: contract_template, preview: preview %>
|
||||
|
||||
@@ -1,13 +1,6 @@
|
||||
require "rails_helper"
|
||||
|
||||
feature "Guest account sign up" do
|
||||
scenario "guest can select ME Suite PRO in 'interested in' dropdown" do
|
||||
visit new_account_path
|
||||
|
||||
expect(page).to have_selector("img[src*='ME_PRO_black']")
|
||||
select "ME Suite PRO", from: interested_in_product_dropdown
|
||||
end
|
||||
|
||||
scenario "creates a new account and signs in successfully" do
|
||||
visit new_account_path
|
||||
|
||||
@@ -45,10 +38,4 @@ feature "Guest account sign up" do
|
||||
|
||||
expect(page).to have_content "Sign Up"
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def interested_in_product_dropdown
|
||||
"user[interested_product_name]"
|
||||
end
|
||||
end
|
||||
|
||||
@@ -684,6 +684,15 @@ feature 'User managing appearance releases' do
|
||||
expect(page).to have_selector("#top-person-photo[src^='#{person_photo_url}']")
|
||||
end
|
||||
|
||||
scenario "viewing the contract PDF - it shows person photo on first page if person photo is attached" do
|
||||
appearance_release = create(:appearance_release_with_contract_template, :native, :minor_with_guardian_photo, project: project)
|
||||
|
||||
visit view_release_pdf_html_preview_link_for(appearance_release)
|
||||
|
||||
person_photo_url = url_for(appearance_release.person_photo.variant(auto_orient: true, resize: "200x200")).to_s
|
||||
expect(page).to have_selector("#top-person-photo[src^='#{person_photo_url}']")
|
||||
end
|
||||
|
||||
scenario 'deleting a release', js: true do
|
||||
appearance_release = create(:appearance_release, project: project)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user