init commit
This commit is contained in:
86
backend/models/Resume.js
Normal file
86
backend/models/Resume.js
Normal file
@ -0,0 +1,86 @@
|
||||
const mongoose = require("mongoose");
|
||||
|
||||
const ResumeSchema = new mongoose.Schema(
|
||||
{
|
||||
userId: {
|
||||
type: mongoose.Schema.Types.ObjectId,
|
||||
ref: "User",
|
||||
required: true,
|
||||
},
|
||||
title: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
thumbnailLink: {
|
||||
type: String,
|
||||
},
|
||||
template:{
|
||||
theme: String,
|
||||
colorPalette: [String]
|
||||
},
|
||||
profileInfo: {
|
||||
profilePreviewUrl: String,
|
||||
fullName: String,
|
||||
designation: String,
|
||||
summary: String,
|
||||
},
|
||||
contactInfo: {
|
||||
email: String,
|
||||
phone: String,
|
||||
location: String,
|
||||
linkedin: String,
|
||||
github: String,
|
||||
website: String,
|
||||
},
|
||||
workExperience: [
|
||||
{
|
||||
company: String,
|
||||
role: String,
|
||||
startDate: String,
|
||||
endDate: String,
|
||||
description: String,
|
||||
},
|
||||
],
|
||||
education: [
|
||||
{
|
||||
degree: String,
|
||||
institution: String,
|
||||
startDate: String,
|
||||
endDate: String,
|
||||
},
|
||||
],
|
||||
skills: [
|
||||
{
|
||||
name: String,
|
||||
progress: Number,
|
||||
},
|
||||
],
|
||||
projects: [
|
||||
{
|
||||
title: String,
|
||||
description: String,
|
||||
github: String,
|
||||
liveDemo: String,
|
||||
},
|
||||
],
|
||||
certifications: [
|
||||
{
|
||||
title: String,
|
||||
issuer: String,
|
||||
year: String,
|
||||
},
|
||||
],
|
||||
languages: [
|
||||
{
|
||||
name: String,
|
||||
progress: Number,
|
||||
},
|
||||
],
|
||||
interests: [String],
|
||||
},
|
||||
{
|
||||
timestamps: { createdAt: "createdAt", updatedAt: "updatedAt" },
|
||||
}
|
||||
);
|
||||
|
||||
module.exports = mongoose.model("Resume", ResumeSchema);
|
||||
13
backend/models/User.js
Normal file
13
backend/models/User.js
Normal file
@ -0,0 +1,13 @@
|
||||
const mongoose = require("mongoose");
|
||||
|
||||
const UserSchema = new mongoose.Schema(
|
||||
{
|
||||
name: { type: String, required: true },
|
||||
email: { type: String, required: true, unique: true },
|
||||
password: { type: String, required: true },
|
||||
profileImageUrl: { type: String, default: null },
|
||||
},
|
||||
{ timestamps: true }
|
||||
);
|
||||
|
||||
module.exports = mongoose.model("User", UserSchema);
|
||||
Reference in New Issue
Block a user