diff --git a/README.md b/README.md index ac868e6..76a9c16 100644 --- a/README.md +++ b/README.md @@ -1,15 +1,25 @@ # CarsInCommonServer -frontend app code: https://github.com/idoctnef/carsincommonApp -images server: https://github.com/arnaucode/goImgServer +- frontend app code: https://github.com/arnaucode/carsincommonApp +- images server: https://github.com/arnaucode/goImgServer **Backend:** - Nodejs + Express + MongoDB + +- Nodejs + Express + MongoDB +- Go --> for the images server **Frontend:** - Angularjs + Ionic + MaterialDesign + +- Angularjs + Ionic + +App: + +![carsincommon](https://raw.githubusercontent.com/arnaucode/carsincommonApp/master/carsincommon.png "carsincommon") +code: https://github.com/arnaucode/carsincommonApp + +-------------------- **To Do Backend and Frontend:** @@ -19,9 +29,6 @@ images server: https://github.com/arnaucode/goImgServer ``` --------------------- - - #### RESOURCES using: initial avatars users: [http://www.flaticon.com/packs/animal-icon-collection](http://www.flaticon.com/packs/animal-icon-collection) diff --git a/config.js b/config.js index b015c33..2cc9a34 100644 --- a/config.js +++ b/config.js @@ -5,5 +5,4 @@ module.exports = { 'database': 'mongodb://localhost/carsincommon', "port" : process.env.PORT || 3000, "pageSize": 20 - }; diff --git a/controllers/travelController.js b/controllers/travelController.js index 3d8b8ae..187ef84 100644 --- a/controllers/travelController.js +++ b/controllers/travelController.js @@ -153,7 +153,7 @@ exports.addJoinPetition = function(req, res) { concept: "join", message: "user "+userJoining.username+" joins your travel "+travel.title, date: new Date(), - icon: 'join.png', + icon: 'ion-person-add', link: "travels/" + travel._id, user: user._id }); @@ -212,7 +212,7 @@ exports.unJoin = function(req, res) { concept: "unjoin", message: "user "+userJoining.username+" unjoins your travel "+travel.title, date: new Date(), - icon: 'unjoin.png', + icon: 'ion-arrow-return-left', link: "travels/" + travel._id, user: user._id }); @@ -281,7 +281,7 @@ exports.declineJoin = function(req, res) { concept: "travel", message: "user "+userOwner.username+" declines your petition for "+travel.title, date: new Date(), - icon: 'travel.png', + icon: 'ion-close', link: "travels/" + travel._id, user: user._id }); @@ -350,7 +350,7 @@ exports.acceptJoin = function(req, res) { concept: "travel", message: "user "+userOwner.username+" accepts your petition for "+travel.title, date: new Date(), - icon: 'travel.png', + icon: 'ion-checkmark', link: "travels/" + travel._id, user: user._id }); @@ -409,7 +409,7 @@ exports.leave = function(req, res) { concept: "leave", message: "user "+userLeaving.username+" leaves your travel "+travel.title, date: new Date(), - icon: 'leave.png', + icon: 'ion-log-out', link: "travels/" + travel._id, user: user._id }); diff --git a/controllers/userController.js b/controllers/userController.js index 80b5c9d..c9da98f 100644 --- a/controllers/userController.js +++ b/controllers/userController.js @@ -418,7 +418,7 @@ exports.likeUser = function(req, res) { concept: "like", message: "user " + userL.username + " adds a like to you", date: new Date(), - icon: 'like.png', + icon: 'ion-heart', link: "users/" + user._id, user: user._id }); @@ -469,7 +469,7 @@ exports.unlikeUser = function(req, res) { concept: "like", message: "user " + userL.username + " removes like on you", date: new Date(), - icon: 'like.png', + icon: 'ion-heart-broken', link: "users/" + user._id, user: user._id }); diff --git a/models/notificationModel.js b/models/notificationModel.js index fedd559..b4d74fa 100644 --- a/models/notificationModel.js +++ b/models/notificationModel.js @@ -14,7 +14,8 @@ var notificationSchema = new Schema({ message: {type: String}, link: {type: String},//aquĆ­ oju, a la app i a la web calen links diferents date: {type: Date}, - dateviewed: {type: Date} + dateviewed: {type: Date}, + icon: {type: String} }) notificationSchema.plugin(mongooseUniqueValidator);