Sails v12.14 connecting to MongoDB with Waterline
Is there a way to do a find query for all records created within the last 7 days from the current date? I've tried searching for an answer, but I'm guessing I'm not hitting the right keywords to come…
I'm using SailsJS with MongoDB. When users are authenticated, their data is stored in a collection named "Sessions".
I'd like to know how I could access this collection so that I can remove all the data in order to force all users to have to log in…
I'm using a Vue Resource to send HTTP requests to my Sails.JS backend.
Everything is working fine, except the only problem is the where clause in Sails isn't implementing the way it should.
Here's my code:
My Template:
I am using Sails Js and MongoDB database. I want to optimize below Query.
Users.findOne({id:user_id})
.populate('educations')
.populate('educations.educationlinks')
.populate('educations.educationlinks.verify_request_id')
…
I have a multi-region database (MongoDB) infrastructure with replication. I want to record data to master DB and read data from other DB (replication) in the same region with the application server.
How to implement it?
Thanks
I'm creating an api using Sails JS v1.0.0
I have an action to upload an image to the server and it's working great but the problem I'm having is that I want to save the image URL to the user uploaded the image. It's the user profile image.
The code…
i want to create Dynamic collection/table in mongoDB using SailsJS.
Example
1- New User Registration.
2- On Registration Success, User's Unique (userID + table) table Create in MongoDB.
3- How can we access this table (UserID + table) from…
I'm really new at sails.js and at the moment I'm using sails 1.0 . I've got the problem when I try to validate my signup page that the once the form is invalid the error message is shown above the form as expected but when I do the refresh it is…
Hey guys I'm really new at sails.js and I'm using version 1.0 of it. I just tried to create a CRUD application on adding article to my list and showing them. All goes right but when I want to delete or edit it says 404 error. I am going through this…
I would like to update the value multiple times using sails js and mongodb. However, when I try to update the value with the same value that exist previously, its giving me an error even though I've set unique: 'false':
"code": "E_VALIDATION",
…
I am new to sailsJS.
I want to add record in collection named skills.
I have refered this document of sails js https://sailsjs.com/documentation/reference/waterline-orm/models/create
I have request as :
{
"skillName": "tblPreffered…
I am working with SailsJs+MongoDB API. I have to create New colletion in mongoDB .Name of colletion will be in request Parameter.
example:
Suppose I want to create 'Users' collection in 'mongoDbDatabase' database
by following request.
{
…
I am new to using SailsJS and also I am using mongodb for the database to connect. I tried using Robo 3T to make sure that my connection is valid and check that the models are in it. However, when I tried lifting using sails lift I encountered this…
I am using sails in my node js application. And want to implement swagger api documentation. And I follow Swagger Sails JS document. I got the result from my api doc. And my expected result from api doc . I have write the route in router.js file…
I'm refactoring my Angular4+sails app so that both the views and the backend are available on localhost:1337. I've specified the routes in config/routes.js
module.exports.routes = {
'/': {
view: 'homepage'
},
'/register':{
…