salix/services/loopback/common/methods/ticket/list.js

20 lines
467 B
JavaScript
Raw Normal View History

module.exports = function(Ticket) {
Ticket.remoteMethod('list', {
description: 'List tickets for production',
returns: {
arg: 'tickets',
type: 'object'
},
http: {
verb: 'get',
path: '/list'
}
});
Ticket.list = function(cb) {
var params = [1, 0];
2017-10-31 08:26:11 +00:00
var query = 'CALL production_control_source(?, ?)';
Ticket.rawSql(query, params, cb);
2017-10-25 11:47:39 +00:00
};
};