import {DataTypes} from 'nodejs-express-utils';
import ContactUs from '../models/ContactUs';

// Get data from the database
const extraQuery = 'WHERE timestamp=:timestamp';
const params = {timestamp: 1631318513};
const fields = ['id', 'body'];

ContactUs.get(extraQuery, params, fields)
    .then((res) => console.log(res))
    .catch((err) => console.error(err));
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter