Questions tagged [feathers-sequelize]

81 questions
1
vote
1 answer

Non CRUD Route in FeathersJS

I have a service results that handles all CRUD Operations for the results service in feathersjs. How would I create a route /results/:id/hr_bar_graph which basically fetches the result at that particular id and uses the resulting data to create an…
1
vote
1 answer

Featherjs sequelize database adapter service methods

i want to know how it is possible to remove some service methods(endpoint) from a service while using sequelize database adapter( or any other one) // Initializes the `society` service on path `/society` const createService =…
KarimS
  • 3,812
  • 9
  • 41
  • 64
1
vote
0 answers

feathersjs sequalize Belongs-To-Many associations Invalid value

I am upgrading an Express application to Feathersjs application. I have the following model definition for belongs_to_many associations: Clase A (usergroup): userGroup.associate = function (models) { …
1
vote
1 answer

How to treat a promise inside a feathersjs hook?

I want to validate data before inserting on database. Feathersjs way is by using hooks. Before inserting a group of permissions, I must take in consideration the integrity of data provided by the user post. My solution is to find all the permissions…
1
vote
0 answers

Feathersjs -> service find with dynamic filters and column selection

So this isn't really a question, more a post on how I solved this specific situation: Desired Situation I wanted to be able to select data from a feathersjs find service call. However, I didn't want to have all columns returned, but different ones…
1
vote
1 answer

How does feathers sequelize work

I'm using angular2 on frontend, node/feathers on backend over Postgres (sequelize) db. On backend I have events service on ".../events" route, and I'm trying to reach data from db, it works fine when I want to retrieve all events so I just make…
1
vote
1 answer

Feathersjs: how to send a response and after that trigger a function?

I had some code working fine for a REST endpoint in which a message was: created in the database stepA was processed when stepA was ok, the response message was returned stepB was processed. This was the code: // POST single message …
musicformellons
  • 12,283
  • 4
  • 51
  • 86
1
vote
1 answer

FeathersJS Sequelize - Associations not working

I'm currently using Sequelize =>4.0 and finding having 2 models link together doesn't work how i assumed it would. Basically, i have 2 models: user & punch. user: id name email punch: id userId <- user id time status I would like to show the list of…
1
vote
0 answers

HTTP POST works but GET fails with feathers sequelize standard service

I am trying to get started with feathers.js and sequelize. I am following the Chat guide, but am using sequelize rather than the default db. I am using a local SQL Server 2016 instance, this is what my sequelize object looks like: const sequelize…
George Edwards
  • 8,979
  • 20
  • 78
  • 161
1
vote
1 answer

In feathers.js, how do I create an associated object after creating the initial object?

In a feathersjs project, I have two models: user and company. I'm using Sequelize/MySQL. Every user has one company. Every company belongs to one user. When a user signs up (is created) I want to create the company object at the same time (with just…
alsky
  • 325
  • 3
  • 8
1
vote
0 answers

Calling feathers's services in ember js?

I have been trying to call feathers's services in ember js, but I have not found any source for my solution! I got lost, so anyone can help me please?
Bahram
  • 11
  • 2
1
vote
1 answer

FeathersJS: Basic setup for sequelize and SQL Server

I'm an absolute beginner with Feathers, but it looks promising, so I'm trying to see if I can connect it to my SQL Server database, but I'm stuck right away. I followed the docs and used feathers generate service, then edited my connection string,…
redOctober13
  • 3,662
  • 6
  • 34
  • 61
0
votes
0 answers

Joining three table or more using Sequelize

How can we join three or more table using sequelize in NodeJS. I have tried with two tables and it work but for three table it is not working.
0
votes
1 answer

How to access the user object when it's in a feathers-sequelize many-to-many association?

I'm trying to build a hook that will restrict certain user actions to specified security roles. But I'm having trouble accessing the user record from a second hook, when the users model is associated with another table. Inside my users 'before: get'…
0
votes
1 answer

protect user fields when returned via sequelize association

I'm having trouble figuring out how to exclude certain fields from the associated model from being returned in a query. I've got a user-membership setup working, using a "users" model, which is associated to the "groups" model via a many-to-many…