From bcdf8d980f08de17a97e6a48165b18f556694344 Mon Sep 17 00:00:00 2001
From: Andy Zhao
Date: Tue, 7 May 2019 07:03:06 -0400
Subject: [PATCH] Minor adjustments to listings (#2731)
* Add periods for consistency
* Update category cost with potential correction
* Update product cost with potential correction
* Display correct text dependent on purchaser
* Use name instead of org username
---
app/models/classified_listing.rb | 6 +++---
app/views/credits/new.html.erb | 8 ++++----
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/app/models/classified_listing.rb b/app/models/classified_listing.rb
index 2fb911494..5adc13067 100644
--- a/app/models/classified_listing.rb
+++ b/app/models/classified_listing.rb
@@ -67,10 +67,10 @@ class ClassifiedListing < ApplicationRecord
"education" => { cost: 1, name: "Education/Courses", rules: "Educational material and/or schools/bootcamps." },
"jobs" => { cost: 25, name: "Job Listings", rules: "Companies offering employment right now." },
"mentors" => { cost: 1, name: "Offering Mentorship", rules: "You are available to mentor someone." },
- "products" => { cost: 10, name: "Products/Tools", rules: "Must be available right now." },
+ "products" => { cost: 5, name: "Products/Tools", rules: "Must be available right now." },
"mentees" => { cost: 1, name: "Seeking a Mentor", rules: "You are looking for a mentor." },
- "forsale" => { cost: 1, name: "Stuff for Sale", rules: "Personally owned physical items for sale" },
- "events" => { cost: 1, name: "Upcoming Events", rules: "In-person or online events with date included" },
+ "forsale" => { cost: 1, name: "Stuff for Sale", rules: "Personally owned physical items for sale." },
+ "events" => { cost: 1, name: "Upcoming Events", rules: "In-person or online events with date included." },
"misc" => { cost: 1, name: "Miscellaneous", rules: "Must not fit in any other category." }
}
end
diff --git a/app/views/credits/new.html.erb b/app/views/credits/new.html.erb
index 53208b026..c3de7d5fe 100644
--- a/app/views/credits/new.html.erb
+++ b/app/views/credits/new.html.erb
@@ -32,7 +32,7 @@
$2.50/per credit
-
+
Contact biz@dev.to to for custom bulk pricing and partnerships.
@@ -45,7 +45,7 @@
-
- products/tools: 5 credits
+ products/tools: 10 credits
-
job listings: 25 credits
@@ -61,11 +61,11 @@
- How many credits do I currently have?
+ How many credits <%= params[:purchaser] == "organization" ? "does #{@purchaser.name}" : "do I currently" %> have?
- You have <%= current_user.credits.where(spent: false).size %> credits
+ <%= params[:purchaser] == "organization" ? "#{@purchaser.name} has" : "You have" %> <%= @purchaser.credits.where(spent: false).size %> credits.