@cnae-hrms/shared-schemas
v1.0.10
Published
Shared database schemas and types for NASTP CNAE HRMS application
Maintainers
Readme
@cnae-hrms/shared-schemas
Shared database schemas and types for the CNAE HRMS application. This package provides TypeScript types and Drizzle ORM schemas that are used by both the frontend and backend applications.
Installation
npm install @cnae-hrms/shared-schemasUsage
Importing Schemas
import { users, candidates, jobs, applications } from '@cnae-hrms/shared-schemas';Importing Types
import type { User, Candidate, Job, Application } from '@cnae-hrms/shared-schemas';Importing Insert Schemas
import type { InsertUser, InsertCandidate } from '@cnae-hrms/shared-schemas';Available Schemas
Core Tables
users- User accounts and authenticationcandidates- Candidate profiles and informationeducation- Educational backgroundexperience- Work experiencejobs- Job postingsapplications- Job applicationsskills- Candidate skillsprojects- Candidate projects
Assessment Tables
assessmentTemplates- Assessment templatesassessmentQuestions- Assessment questionsassessmentAttempts- Assessment attemptsassessmentAnswers- Assessment answers
Email & Communication
emailTemplates- Email templatessentEmails- Sent email records
Scoring & Merit
jobEducationWeights- Education weightage for jobsjobTestWeights- Test weightage for jobsjobInterviewWeights- Interview weightage for jobsjobExecutiveInterviewWeights- Executive interview weightage
Other Tables
candidateNotes- Admin notes on candidatescandidateReviews- Candidate reviewsaiScoringJobs- AI scoring batch jobsaiScoringBatches- AI scoring batchessearchQueries- Search query logsoffers- Job offersjobCosts- Job-related costscompanyInfo- Company informationuniRanking- University rankings
Available Types
Select Types
User,Candidate,Education,Experience,Job,Application, etc.
Insert Types
InsertUser,InsertCandidate,InsertEducation, etc.
Custom Types
SearchFilters- Search filter interfaceSearchResult- Search result interface
Development
Building the Package
npm run buildDevelopment Mode
npm run devPublishing
npm publishDependencies
drizzle-orm- Database ORMzod- Schema validation
License
MIT