changes in getRoleCustomer service

This commit is contained in:
Daniel Herrero 2017-11-22 13:24:36 +01:00
parent 3bd913cbd9
commit ba73869fd3
1 changed files with 1 additions and 1 deletions

View File

@ -32,7 +32,7 @@ module.exports = Client => {
});
Client.getRoleCustomer = (id, context, callback) => {
let query = `SELECT count(*) isCustomer FROM Account ac JOIN Role ON Role.id = ac.roleFK WHERE Role.\`name\`='customer' AND ac.id IN (?)`;
let query = `SELECT count(*) isCustomer FROM salix.Account ac JOIN salix.Role r ON r.id = ac.roleFK WHERE r.\`name\`='customer' AND ac.id IN (?)`;
const params = [id];
Client.rawSql(query, params, callback)
.then(response => {