mma-gpacts-app/tasks.js
2020-04-04 15:50:15 -07:00

42 lines
939 B
JavaScript

// Library of functions used in the app
// ------------------------------------
const {google} = require('googleapis');
var config = require('./config.js');
var auth = require('./auth.js');
var page = require('./page.js');
function not_found(req, res) {
var pg = page.head("Page Not Found");
pg += `<p class="content">404 - Page Not Found</p>`;
pg += page.tail();
res.status(404).send(pg);
}
function home_page(req, res) {
var pg = page.head("Home");
pg += `<p class="content">Welcome Home</p>`;
pg += page.tail();
res.send(pg);
}
function tiny_photos(req, res) {
var pg = page.head("Tiny photos");
pg += `<p class="content">These are the tiny photos in your library</p>`;
pg += page.tail();
res.send(pg);
}
// Exported functions
module.exports = {
not_found: not_found,
home_page: home_page,
tiny_photos: tiny_photos
}
// vim: ai ts=4 sts=4 et sw=4 ft=javascript