Skip to content

Commit

Permalink
Merge pull request #6 from SomnathMore/master
Browse files Browse the repository at this point in the history
Added post call for new employee
  • Loading branch information
ijason authored Jun 10, 2022
2 parents 7ce3bcb + b271217 commit 32790cd
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions EmployeeDB/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,14 @@ app.get('/employee/new', function(req, res) {
});
});


//new employee with post
app.post('/employee/new', function(req, res) {
res.render('employee_new', {
title: 'New Employee'
});
});

//save new employee
app.post('/employee/new', function(req, res){
employeeProvider.save({
Expand Down

0 comments on commit 32790cd

Please sign in to comment.