Skip to content

Instantly share code, notes, and snippets.

@gbozee
Last active February 16, 2021 09:52
Show Gist options
  • Save gbozee/b7d57e0122782167f8a259cd3c5b9666 to your computer and use it in GitHub Desktop.
Save gbozee/b7d57e0122782167f8a259cd3c5b9666 to your computer and use it in GitHub Desktop.
Search result snapshot
export const SAMPLESEARCH_RESULTS = [
[
{
userId: "tutorId1",
firstName: "Jumoke",
lastName: "Benson",
gender: "female",
photo:
"http://res.cloudinary.com/tuteria/image/upload/v1510931421/profile_pics/neizg4691lidnczc36nx.jpg",
level: "premium",
delivery: ["physical"],
dateOfBirth: "1998-10-12",
successScore: 89,
distance: 32,
rating: 4.6,
ratingCount: 46,
isIdVerified: true,
isBackgroundChecked: true,
videoURL: "http://www.videoURL",
image_url:
"https://www.eatright.org/-/media/homefoodsafety/foursteps/cook/cookingwithkid.jpg?h=450&w=600&la=en&hash=4C3E2619B8361095885036C3CDD0878C1CA5BC91",
lessonsTaught: 203,
students: 98,
isIndemand: true,
newTutorDiscount: null,
isNewTutor: false,
country: "Nigeria",
state: "Lagos",
region: "Ajah",
vicinity: "Sangotedo",
specialNeedExpertise: [],
examsExperience: ["WAEC", "BECE", "Checkpoints"],
curriculum: ["Nigerian", "Montessori", "British", "American"],
classesTaught: ["JSS 1", "JSS 2", "JSS 3", "SSS 1", "SSS 2", "SSS 3"],
levelsTaught: ["Beginner", "Intermediate", "Advanced"],
entranceSchools: [],
education: [
{
school: "University College, London",
country: "United Kingdom",
course: "Applied Mathematics",
grade: "First Class",
degree: "PhD",
startYear: "2007",
endYear: "2013",
isVerified: false,
},
],
workHistory: [
{
company: "Akintola Williams Deloitte",
role: "Consultant",
startYear: "2015",
endYear: "2015",
isCurrent: false,
isTeachingRole: false,
showOnProfile: true,
isVerified: false,
},
],
subjects: [
{
hourlyRate: 7500,
hourlyDiscount: 25, // 0, 25, 50
discountForExtraStudents: 10, //0, 10, 20, 30, 40, 50
passRate: 100,
name: "Primary Mathematics",
shortName: "Primary Math",
profileURL: null,
isCertified: false,
headline:
"Certified IGCSE, Checkpoints and Entrance Prep Tutor. 10+ Years' Experience",
description:
"My first student came to me because he heard me speaking in the corridor at my workplace. He wasn't sure what he needed but he surely knew he wanted to improve his German. He wanted to be able to speak up in class and also excel in his studies when he finally moves abroad. \n\nI learnt how to speak German in Germany. I understand that it is harder if you are outside of the country and of course everyday life circumstances comes in between.\n\nI would like to bridge that gap for you. If you are already experienced with the German Language we will only speak German. If you are a fresher I am glad to switch in between. Whatever works best for you to become better in the Language.\n\nI enjoy conversing. Talking about your everyday life and why you are learning German because at the end of the day all this is necessary to describe your experiences to others speaking the language.",
related: ["Literacy & Numeracy", "Literature"],
},
],
reviewPoints: [
{ "Teaching method": 4.2 },
{
Communication: 4.75,
},
{ Patience: 4.8 },
{ Punctuality: 5.0 },
{ "Improved outcome": 4.5 },
{ Committment: 4.5 },
],
}
],
];
export const SAMPLEREQUEST = {
contactDetails: {
customerType: "parent",
title: "Mrs.",
firstName: "Adenike",
lastName: "Toluwani",
email: "adeniketolu@example.com",
phone: "2347083266188",
vicinity: "Agungi",
region: "Lekki",
state: "Lagos",
country: "Nigeria",
medium: "Facebook",
},
lessonDetails: {
lessonType: "physical",
lessonSchedule: {
lessonDuration: 4,
lessonHours: 2,
lessonDays: ["Monday", "Wednesday", "Friday", "Saturday"],
lessonTime: "4:00 PM",
lessonUrgency: "few_days",
},
},
childDetails: [
{
firstName: "Yetunde",
gender: "female",
classDetail: {
class: "JSS 1",
purpose: "General Home Lessons",
subjects: ["JSS Math", "JSS English"],
},
learningNeed: "Falling behind",
curriculum: ["Nigerian", "British"],
expectation:
"Yetunde has some challenges with Math, I'll like her to improve in her numbers ahead of her Year 9 exams",
special_needs: "None",
},
{
firstName: "Toyin",
gender: "female",
classDetail: {
class: "Preschool",
purpose: "Early Child Education",
subjects: ["Literacy & Numeracy", "Phonics", "Handwriting"],
},
learningNeed: "Falling behind",
curriculum: ["Nigerian", "British", "American"],
expectation:
"My daughter needs to improve in her reading, writing and love for learning",
special_needs: "None",
},
{
firstName: "Adams",
gender: "male",
classDetail: {
class: "Primary 5",
purpose: "Common Entrance Exam",
subjects: ["Primary Math", "Primary English"],
},
learningNeed: "Falling behind",
curriculum: ["British"],
expectation:
"Adams needs a lot of help with his spellings, math and english",
special_needs: "None",
},
],
splitRequests: [
{
teacherOption: "Specialized teachers",
purposes: ["Common Entrance Exam", "Early Child Education"],
class: ["Primary 5", "Preschool"],
names: ["Adams", "Toyin"],
specialNeeds: [],
subjectGroup: [
"Primary Math",
"Primary English",
"Literacy & Numeracy",
"Phonics",
"Handwriting",
],
learningNeed: ["Falling behind"],
curriculum: ["Nigerian", "British", "American"],
searchSubject: "Primary Math",
lessonDays: ["Monday", "Wednesday", "Friday", "Saturday"],
forTeacher: [
{
name: "Toyin",
gender: "female",
classDetail: {
class: "Preschool",
purpose: "Early Child Education",
subjects: ["Literacy & Numeracy", "Phonics", "Handwriting"],
},
learningNeed: "Falling behind",
curriculum: ["Nigerian", "British", "American"],
expectation:
"My daughter needs to improve in her reading, writing and love for learning",
special_needs: "Dyslexia",
},
{
name: "Adams",
gender: "male",
classDetail: {
class: "Primary 5",
purpose: "Common Entrance Exam",
subjects: ["Primary Math", "Primary English"],
},
learningNeed: "Falling behind",
curriculum: ["British"],
expectation:
"Adams needs a lot of help with his spellings, math and english",
special_needs: "Dyslexia",
},
],
},
{
teacherOption: "Specialized teachers",
purposes: ["General Home Lessons"],
class: ["JSS 1"],
names: ["Yetunde"],
specialNeeds: ["Dyslexia"],
subjectGroup: ["JSS English"],
learningNeed: ["Falling behind"],
curriculum: ["Nigerian", "British"],
searchSubject: "JSS English",
lessonDays: ["Monday", "Wednesday"],
forTeacher: [
{
name: "Yetunde",
gender: "female",
classDetail: {
class: "JSS 1",
purpose: "General Home Lessons",
subjects: ["JSS English"],
},
learningNeed: "Falling behind",
curriculum: ["Nigerian", "British"],
expectation:
"Yetunde has some challenges with Math, I'll like her to improve in her numbers ahead of her Year 9 exams",
special_needs: "Dyslexia",
},
],
},
{
teacherOption: "Specialized teachers",
purposes: ["Common Entrance Exam"],
class: ["JSS 1"],
names: ["Yetunde"],
specialNeeds: [],
subjectGroup: ["JSS Math"],
learningNeed: ["Falling behind"],
curriculum: ["Nigerian", "British"],
searchSubject: "JSS Math",
lessonDays: ["Friday", "Saturday"],
forTeacher: [
{
name: "Yetunde",
gender: "female",
classDetail: {
class: "JSS 1",
purpose: "General Home Lessons",
subjects: ["JSS Math"],
},
learningNeed: "Falling behind",
curriculum: ["Nigerian", "British"],
expectation:
"Yetunde has some challenges with Math, I'll like her to improve in her numbers ahead of her Year 9 exams",
special_needs: null,
},
],
},
],
subjectDetails: {
name: "hometutoring", //IELTS, GRE
shortName: "hometutoring",
examType: "General Test",
modules: ["Writing", "Reading"],
},
filters: {
gender: ["male", "female"],
sortBy: "Recommended",
showPremium: false,
minPrice: 0,
maxPrice: 0,
lessonType: "physical",
educationDegrees: [],
educationCountries: [],
educationGrades: [],
maxAge: 0,
minExperience: "",
},
};
/**The fields on the search query that need to be indexed */
/**
* userId
* firstName
* lastName
* gender
* level
* delivery
* dateOfBirth
* country
* state
* region
* vicinity
* examsExperience
* curriculum
* classesTaught
* levelsTaught
* entranceSchools,
* education.school
* education.country
* education.course
* education.grade
* education.degree
* workHistory.isTeachingRole
* workHistory.role
* workHistory.company
* subjects.hourlyRate
* subjects.name,
* subjects.shortName,
* subjects.headline
* subject.description
* subject.related.
* dateJoined
* lessonsTaught (no of lessons taught so far.)
* students (no of students taught)
* specialNeedExpertise
*/
/**
* Table:
===========================
* auth_user (users)
*==========================
* userId: "slug",
* firstName: "first_name"
* lastName: "last_name",
* dateJoined: "created",
* "country": "country"
* (special records in db)
* "data_dump": [
* level,
* delivery,
* successScore,
* specialNeedExpertise,
* examsExperience,
* curriculum
* classesTaught
* levelsTaught,
* entranceSchools,
* state
* region
* vicinity
* education.school
* education.course
* education.degree
* education.grade
* education.startyear
* education.endyear
*
* workHistory.company
* workHistory.role
* workHistory.startYear
* workHistory.endYear
* workHistory.isCurrent
* workHistory.isTeachingRole
*
* ]
*
* ========================
* user_profile (profile)
* =======================
* gender,
* photo: "image"
* "curriculum",
* "videoURL": "video",
*
*
* =======================
* location
* ======================
* state
* region
* vicinity
*
* =========================
* education
* ========================
* school
* course
* grade
* degree
*
* =======================
* work experience
* =========================
* company
* role
* isCurrent
*
* =============================
* tutorskill
* ========================
* hourlyRate: price
* name: skill.name =>
* headline: heading
* description: description.
* tutor_exhibition: {'image'}
*
*
*
*
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment