Skip to content

This is a sample MEAN app for demonstrating cloud migration patterns

Notifications You must be signed in to change notification settings

lhtan-dev/jmc-mining-app

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

82 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple Mean App

Simple application to Add, Update, Remove, Search records using MEAN stack Records generated based on field array defined in app.js list.

vm.fields = [
    {label: 'Name', key: 'name'},
    {label: 'Email', key: 'email'},
    {label: 'Phone', key: 'phone'}
];

Change above array to have your own fields, html generates input box as of now

and change below for update query in server.js

app.put('/records/:id', function(req, res, next){
    var id = req.params.id;
    records_collection.updateOne(
        {'_id': new ObjectId(id)},
        { $set: {
            'name' : req.body.name,
            'email': req.body.email,
            'phone': req.body.phone
            }
        }, function(err, results){
            console.log(results);
            res.json(results);
    });
});

This is for simple seed mean app at it basic level for learning.

About

This is a sample MEAN app for demonstrating cloud migration patterns

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 73.1%
  • HTML 26.9%