Add full project files
This commit is contained in:
13
controllers/application/expertise/expertiseController.js
Normal file
13
controllers/application/expertise/expertiseController.js
Normal file
@@ -0,0 +1,13 @@
|
||||
/* eslint-disable camelcase */
|
||||
const ExpertiseModel = require('../../../models/ExpertiseModel')
|
||||
const getExpertise = async (req, res, next) => {
|
||||
try {
|
||||
const expertises = await ExpertiseModel.find().select('expertise sub_expertise')
|
||||
res.json({ expertises })
|
||||
} catch (error) {
|
||||
next(error)
|
||||
}
|
||||
}
|
||||
module.exports = {
|
||||
getExpertise
|
||||
}
|
||||
Reference in New Issue
Block a user