mirror of
https://github.com/semaphoreui/semaphore.git
synced 2025-01-24 03:40:52 +01:00
24 lines
375 B
JavaScript
24 lines
375 B
JavaScript
|
var models = require('../../models')
|
||
|
|
||
|
exports.unauthorized = function (app, template) {
|
||
|
template([
|
||
|
'add'
|
||
|
], {
|
||
|
prefix: 'playbook'
|
||
|
});
|
||
|
}
|
||
|
|
||
|
exports.httpRouter = function () {
|
||
|
|
||
|
}
|
||
|
|
||
|
exports.router = function (app) {
|
||
|
app.get('/playbooks', getPlaybooks)
|
||
|
}
|
||
|
|
||
|
function getPlaybooks (req, res) {
|
||
|
models.Playbook.find({
|
||
|
}, function (err, playbooks) {
|
||
|
res.send(playbooks)
|
||
|
})
|
||
|
}
|