diff --git a/app.js b/app.js index e6a623d..809671d 100644 --- a/app.js +++ b/app.js @@ -16,7 +16,7 @@ const bodyParser = require("body-parser"); const helmet = require("helmet"); const cors = require("cors"); const path = require("path"); - +const csp_header_dict = require("./config/csp-headers"); //Passport config require("./config/passport-google")(passport); //passport is for authenticating only @@ -41,6 +41,10 @@ app.use( extended: true, }) ); +const { + cloudinaryConfig +} = require('./config/cloudinary_support') + app.use(bodyParser.json()); app.use(cors()); @@ -48,77 +52,17 @@ app.use( expressCspHeader({ directives: { "default-src": [ - SELF, - "*.google.com", - "https://*/", - "https://kit.fontawesome.com/", - "https://images.squarespace-cdn.com/", - "https://fonts.gstatic.com/", - "*.googleapis.com", - "kit.fontawesome.com", - "https://apis.google.com/js/", - "https://kit.fontawesome.com/*", - "*.google.com", - "https://kit.fontawesome.com/", - "https://images.squarespace-cdn.com/", - "https://fonts.gstatic.com/", - "*.googleapis.com", - "kit.fontawesome.com", - "https://apis.google.com/js/", - "data:", - "https://apis.google.com/js/api.js", - "apis.google.com", - "self", - + ...csp_header_dict.defaultSrc, SELF, INLINE, ], "script-src": [ + ...csp_header_dict.scriptSrc, SELF, - "*.google.com", - "https://kit.fontawesome.com/", - "https://images.squarespace-cdn.com/", - "https://fonts.gstatic.com/", - "*.googleapis.com", - "kit.fontawesome.com", - "https://apis.google.com/js/", - "https://kit.fontawesome.com/*", - "*.google.com", - "https://kit.fontawesome.com/", - "https://images.squarespace-cdn.com/", - "https://fonts.gstatic.com/", - "*.googleapis.com", - "kit.fontawesome.com", - "https://apis.google.com/js/", - "data:", - "https://apis.google.com/js/api.js", - "apis.google.com", - "self", - "data: *", INLINE, ], - "img-src": ["data:image/svg+xml", SELF, - "*.google.com", - "https://*/", - "https://kit.fontawesome.com/", - "https://images.squarespace-cdn.com/", - "https://fonts.gstatic.com/", - "*.googleapis.com", - "kit.fontawesome.com", - "https://apis.google.com/js/", - "https://kit.fontawesome.com/*", - "*.google.com", - "https://kit.fontawesome.com/", - "https://images.squarespace-cdn.com/", - "https://fonts.gstatic.com/", - "*.googleapis.com", - "kit.fontawesome.com", - "https://apis.google.com/js/", - "data:", - "https://apis.google.com/js/api.js", - "apis.google.com", - "self", - + "img-src": [ + ...csp_header_dict.imgSrc, SELF, INLINE, ], @@ -158,6 +102,7 @@ app.use(passport.initialize()); // app.use((req, res, next) => [ // res.setHeader("default-src 'self'; script-src 'report-sample' 'self' https://apis.google.com/js/api.js https://kit.fontawesome.com/5a3d56a40e.js; style-src 'report-sample' 'self' https://fonts.googleapis.com https://kit-free.fontawesome.com; object-src 'none'; base-uri 'self'; connect-src 'self'; font-src 'self' https://fonts.gstatic.com https://kit-free.fontawesome.com; frame-src 'self' https://accounts.google.com; img-src 'self'; manifest-src 'self'; media-src 'self'; report-uri https://5f4b9f5fb641482c3e7cfaaa.endpoint.csper.io/; worker-src 'self';") // ]) +app.use(cloudinaryConfig) app.use("/public", express.static("public")); //Routes diff --git a/config/.passport-google.js.un~ b/config/.passport-google.js.un~ deleted file mode 100644 index fcbc920..0000000 Binary files a/config/.passport-google.js.un~ and /dev/null differ diff --git a/config/cloudinary_support.js b/config/cloudinary_support.js new file mode 100644 index 0000000..c421cce --- /dev/null +++ b/config/cloudinary_support.js @@ -0,0 +1,27 @@ +const { + config, + uploader +} = require('cloudinary'); +const cloudinaryConfig = () => config({ + cloud_name: process.env.CLOUDINARY_CLOUD_NAME, + api_key: process.env.CLOUDINARY_API_KEY, + api_secret: process.env.CLOUDINARY_API_SECRET, +}); + +function parseImage(req, res, next) { + if (req.file) { + const Datauri = require('datauri'); + const datauri = new Datauri(); + datauri.format(path.extname(req.file.originalname).toString(), req.file.buffer); + req.file.encodedUri = datauri.content; + } else { + res.status(400).json({ + error: 'Please include image in the request' + }); + } +} +module.exports = { + cloudinaryConfig, + uploader, + parseImage +}; \ No newline at end of file diff --git a/config/csp-headers.js b/config/csp-headers.js new file mode 100644 index 0000000..797ab39 --- /dev/null +++ b/config/csp-headers.js @@ -0,0 +1,67 @@ +module.exports = { + "defaultSrc": [ + "*.google.com", + "https://*/", + "https://kit.fontawesome.com/", + "https://images.squarespace-cdn.com/", + "https://fonts.gstatic.com/", + "*.googleapis.com", + "kit.fontawesome.com", + "https://apis.google.com/js/", + "https://kit.fontawesome.com/*", + "*.google.com", + "https://kit.fontawesome.com/", + "https://images.squarespace-cdn.com/", + "https://fonts.gstatic.com/", + "*.googleapis.com", + "kit.fontawesome.com", + "https://apis.google.com/js/", + "data:", + "https://apis.google.com/js/api.js", + "apis.google.com", + "self", + ], + "scriptSrc": ["*.google.com", + "https://kit.fontawesome.com/", + "https://images.squarespace-cdn.com/", + "https://fonts.gstatic.com/", + "*.googleapis.com", + "kit.fontawesome.com", + "https://apis.google.com/js/", + "https://kit.fontawesome.com/*", + "*.google.com", + "https://kit.fontawesome.com/", + "https://images.squarespace-cdn.com/", + "https://fonts.gstatic.com/", + "*.googleapis.com", + "kit.fontawesome.com", + "https://apis.google.com/js/", + "data:", + "https://apis.google.com/js/api.js", + "apis.google.com", + "self", + "data: *", + ], + "imgSrc": ["data:image/svg+xml", + "*.google.com", + "https://*/", + "https://kit.fontawesome.com/", + "https://images.squarespace-cdn.com/", + "https://fonts.gstatic.com/", + "*.googleapis.com", + "kit.fontawesome.com", + "https://apis.google.com/js/", + "https://kit.fontawesome.com/*", + "*.google.com", + "https://kit.fontawesome.com/", + "https://images.squarespace-cdn.com/", + "https://fonts.gstatic.com/", + "*.googleapis.com", + "kit.fontawesome.com", + "https://apis.google.com/js/", + "data:", + "https://apis.google.com/js/api.js", + "apis.google.com", + "self", + ], +} \ No newline at end of file diff --git a/config/keys.js b/config/keys.js index 1e32270..ac7f398 100644 --- a/config/keys.js +++ b/config/keys.js @@ -1,3 +1,3 @@ module.exports = { - MongoURI: 'mongodb+srv://dipin:dipin@cluster0.jskbn.mongodb.net/TestDB?retryWrites=true&w=majority' -} \ No newline at end of file + MongoURI: process.env.MONGO_URI +} diff --git a/config/multer_support.js b/config/multer_support.js index bb7d0c6..2f81f7b 100644 --- a/config/multer_support.js +++ b/config/multer_support.js @@ -1,4 +1,6 @@ const multer = require('multer'); +const Datauri = require("datauri"); + const storage = multer.diskStorage({ destination: (req, file, cb) => { cb(null, "public/images"); @@ -11,8 +13,9 @@ const imageFileFilter = (req, file, cb) => { cb(null, true); }; const upload = multer({ - storage: storage, + storage: multer.memoryStorage(), fileFilter: imageFileFilter }); + module.exports = upload \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 9919703..8c4d7fd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -433,6 +433,22 @@ "mimic-response": "^1.0.0" } }, + "cloudinary": { + "version": "1.23.0", + "resolved": "https://registry.npmjs.org/cloudinary/-/cloudinary-1.23.0.tgz", + "integrity": "sha512-akOxzroonvwWkuSVq7BI50nYpZPRXc5DbQIYETCVeKX9ZoToH2Gvc3MdUH63UtKiszuGYE51q2B+jQsJkBp2AQ==", + "requires": { + "cloudinary-core": "^2.10.2", + "core-js": "3.6.5", + "lodash": "^4.17.11", + "q": "^1.5.1" + } + }, + "cloudinary-core": { + "version": "2.11.3", + "resolved": "https://registry.npmjs.org/cloudinary-core/-/cloudinary-core-2.11.3.tgz", + "integrity": "sha512-ZRnpjSgvx+LbSf+aEz5NKzxDB4Z0436aY/0BSDa90kAHiwAyd84VyEi95I74SE80e15Ri9t5S2xtksTXpzk9Xw==" + }, "color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", @@ -514,6 +530,11 @@ "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", "integrity": "sha1-4wOogrNCzD7oylE6eZmXNNqzriw=" }, + "core-js": { + "version": "3.6.5", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.6.5.tgz", + "integrity": "sha512-vZVEEwZoIsI+vPEuoF9Iqf5H7/M3eeQqWlQnYa8FSKKePuYTf5MWnxb5SDAzCa60b3JBRS5g9b+Dq7b1y/RCrA==" + }, "core-util-is": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", @@ -538,6 +559,15 @@ "resolved": "https://registry.npmjs.org/csp-header/-/csp-header-2.1.1.tgz", "integrity": "sha512-JuUi95nVFMuVOcI/A10+8CwpWflq3TS/sgperD109BG0xg7pEY1x1E1Aqv0LIpIKHdgkCK0nIZqu1RVRRRoMJA==" }, + "datauri": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/datauri/-/datauri-3.0.0.tgz", + "integrity": "sha512-NeDFuUPV1YCpCn8MUIcDk1QnuyenUHs7f4Q5P0n9FFA0neKFrfEH9esR+YMW95BplbYfdmjbs0Pl/ZGAaM2QHQ==", + "requires": { + "image-size": "0.8.3", + "mimer": "1.1.0" + } + }, "date-fns": { "version": "2.15.0", "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.15.0.tgz", @@ -1075,6 +1105,14 @@ "resolved": "https://registry.npmjs.org/ignore-by-default/-/ignore-by-default-1.0.1.tgz", "integrity": "sha1-SMptcvbGo68Aqa1K5odr44ieKwk=" }, + "image-size": { + "version": "0.8.3", + "resolved": "https://registry.npmjs.org/image-size/-/image-size-0.8.3.tgz", + "integrity": "sha512-SMtq1AJ+aqHB45c3FsB4ERK0UCiA2d3H1uq8s+8T0Pf8A3W4teyBQyaFaktH6xvZqh+npwlKU7i4fJo0r7TYTg==", + "requires": { + "queue": "6.0.1" + } + }, "import-lazy": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/import-lazy/-/import-lazy-2.1.0.tgz", @@ -1386,6 +1424,11 @@ "mime-db": "1.44.0" } }, + "mimer": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/mimer/-/mimer-1.1.0.tgz", + "integrity": "sha512-y9dVfy2uiycQvDNiAYW6zp49ZhFlXDMr5wfdOiMbdzGM/0N5LNR6HTUn3un+WUQcM0koaw8FMTG1bt5EnHJdvQ==" + }, "mimic-response": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-1.0.1.tgz", @@ -1825,11 +1868,24 @@ "escape-goat": "^2.0.0" } }, + "q": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", + "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=" + }, "qs": { "version": "6.7.0", "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", "integrity": "sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==" }, + "queue": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/queue/-/queue-6.0.1.tgz", + "integrity": "sha512-AJBQabRCCNr9ANq8v77RJEv73DPbn55cdTb+Giq4X0AVnNVZvMHlYp7XlQiN+1npCZj1DuSmaA2hYVUUDgxFDg==", + "requires": { + "inherits": "~2.0.3" + } + }, "random-bytes": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/random-bytes/-/random-bytes-1.0.0.tgz", diff --git a/package.json b/package.json index e80ca1e..b901a2c 100644 --- a/package.json +++ b/package.json @@ -19,8 +19,10 @@ "dependencies": { "bcryptjs": "^2.4.3", "body-parser": "^1.19.0", + "cloudinary": "^1.23.0", "concurrently": "^5.3.0", "cors": "^2.8.5", + "datauri": "^3.0.0", "dotenv": "^8.2.0", "express": "^4.17.1", "express-csp-header": "^4.0.0", diff --git a/routes/api_menu.js b/routes/api_menu.js index b50c48b..355dbf0 100644 --- a/routes/api_menu.js +++ b/routes/api_menu.js @@ -4,10 +4,18 @@ const router = express.Router(); const _ = require("lodash"); const Menu = require("../models/Menu"); const Dish = require("../models/Dish"); -const { ensureAuthenticated, ensureCafe } = require("../config/auth"); +const { + ensureAuthenticated, + ensureCafe +} = require("../config/auth"); const upload = require("../config/multer_support"); - -const { Cafe } = require("../models/Cafe"); +const { + uploader, + parseImage +} = require('../config/cloudinary_support') +const { + Cafe +} = require("../models/Cafe"); //working api endpoint /api/menu //returns list of all cafes router.get("/", async(req, res) => { @@ -90,13 +98,20 @@ router.post("/", ensureCafe, (req, res) => { router.post( "/withImage", ensureCafe, - upload.single("dishImage"), + upload.single("dishImage"), parseImage, (req, res) => { console.log(req.body); let deepClone = JSON.parse(JSON.stringify(req.body)); console.log(req.file); if (req.file != undefined) { - deepClone.pictureURL = req.file.path; + uploader.upload(req.file.encodedUri) + .then((result) => { + deepClone.pictureURL = result.url; + }) + .catch(err => res.status(500).json({ + error: 'Could not upload' + })); + } deepClone.cafe_id = req.user._id; deepClone.availability = deepClone.availability == "true"; @@ -130,13 +145,16 @@ router.post( router.patch( "/withImage", ensureCafe, - upload.single("dishImage"), + upload.single("dishImage"), parseImage, (req, res) => { console.log(req.body); let deepClone = JSON.parse(JSON.stringify(req.body)); console.log(req.file); if (req.file != undefined) { - deepClone.pictureURL = req.file.path; + uploader.upload(req.file.encodedUri) + .then((result) => { + deepClone.pictureURL = result.url; + }); } deepClone.cafe_id = req.user._id; if (deepClone.availability !== undefined) { @@ -177,8 +195,7 @@ router.patch( router.put( "/:dish_id/onlyImage/", ensureCafe, - upload.single("dishImage"), - async(req, res) => { + upload.single("dishImage"), parseImage, async(req, res) => { try { let workingMenu = await Menu.findOne({ cafe_id: req.user._id, @@ -196,7 +213,10 @@ router.put( }); } if (req.file != undefined) { - workingDish.pictureURL = req.file.path; + uploader.upload(req.file.encodedUri) + .then((result) => { + workingDish.pictureURL = result.url; + }); } let newMenu = await workingMenu.save(); res.status(200).json({ diff --git a/routes/api_profile.js b/routes/api_profile.js index c3f24d8..0dfdf51 100644 --- a/routes/api_profile.js +++ b/routes/api_profile.js @@ -21,8 +21,12 @@ const Cafe = require('../models/Cafe').Cafe; const upload = require('../config/multer_support') const authService = require('../services/authService_user'); const jwt = require('jsonwebtoken'); - -//working api route is /api/profile +const { + cloudinaryConfig, + uploader, + parseImage +} = require('../config/cloudinary_support') + //working api route is /api/profile //get request to working api sends back the user document currently logged in //if not logged in sends 401 @@ -136,11 +140,29 @@ router.post('/register/images', upload.fields([{ let workingCafe = await Cafe.findOne({ _id: req.user._id }); + const Datauri = require('datauri'); if (req.files.logoImage !== undefined) { - workingCafe.logoURL = req.files.logoImage[0].path + + const datauri = new Datauri(); + datauri.format(path.extname(req.files.logoImage[0].originalname).toString(), req.files.logoImage[0].buffer); + uploader.upload(datauri.content) + .then((result) => { + workingCafe.logoURL = result.url; + }) + .catch(err => res.status(500).json({ + error: 'Could not upload' + })) } if (req.files.cafeImage !== undefined) { - workingCafe.imageURL = req.files.cafeImage[0].path + let datauri1 = new Datauri(); + datauri1.format(path.extname(req.files.cafeImage[0].originalname).toString(), req.files.cafeImage[0].buffer); + uploader.upload(datauri1.content) + .then((result) => { + workingCafe.imageURL = result.url; + }) + .catch(err => res.status(500).json({ + error: 'Could not upload' + })) } try { let savedCafe = await workingCafe.save(); @@ -220,6 +242,30 @@ router.post('/register/cafe/withImage', upload.fields([{ }) } else { console.log('registering Cafe ', req.body); + let logoURL, imageURL; + if (req.files.logoImage !== undefined) { + + const datauri = new Datauri(); + datauri.format(path.extname(req.files.logoImage[0].originalname).toString(), req.files.logoImage[0].buffer); + uploader.upload(datauri.content) + .then((result) => { + logoURL = result.url; + }) + .catch(err => res.status(500).json({ + error: 'Could not upload' + })) + } + if (req.files.cafeImage !== undefined) { + let datauri1 = new Datauri(); + datauri1.format(path.extname(req.files.cafeImage[0].originalname).toString(), req.files.cafeImage[0].buffer); + uploader.upload(datauri1.content) + .then((result) => { + imageURL = result.url; + }) + .catch(err => res.status(500).json({ + error: 'Could not upload' + })) + } var newAcc = new Cafe({ name: req.body.name, @@ -231,8 +277,8 @@ router.post('/register/cafe/withImage', upload.fields([{ role: 'Cafe', description: req.body.description, password: bcrypt.hashSync(req.body.password, 10), - logoURL: req.files.logoImage !== undefined ? req.files.logoImage[0].path : '', - imageURL: req.files.cafeImage !== undefined ? req.files.cafeImage[0].path : '', + logoURL, + imageURL, }) try { @@ -265,16 +311,16 @@ router.post('/login/cafe', passport.authenticate('local', { authService.signToken(req, res); }) //checks whether a user(User or Cafe) is logged in or not -/*router.get('/check', (req, res) => { - console.log('checking'); - if (req.user) { - res.status.json({ - user: req.user - }); - } else { - res.sendStatus(404); - } - })*/ + /*router.get('/check', (req, res) => { + console.log('checking'); + if (req.user) { + res.status.json({ + user: req.user + }); + } else { + res.sendStatus(404); + } + })*/ //allows User login using google oauth 2 (login only if from iiti domain name) // router.get('/login/user', // passport.authenticate("google", { diff --git a/scripts/Aladeens/aladeens.txt b/scripts/Aladeens/aladeens.txt new file mode 100644 index 0000000..d0a2d2f --- /dev/null +++ b/scripts/Aladeens/aladeens.txt @@ -0,0 +1,3 @@ +Aladeens is a student run food venture founded by three students of 2014 batch of IIM Indore, Mr. Amogh Jawa, Mr. Jaihit Soni and Mr. Aashish Ranjan. Aladeens serves a delicious, healthy and rich North Indian cuisine. Whether it’s the Tikkas or Rotis, they believe in a little barbequing. +The have a saying “If you can’t go to Delhi, we will bring Delhi to you.” +They are providing services at IIT Indore since January 2018. \ No newline at end of file diff --git a/scripts/Aladeens/butter chicken.jpg b/scripts/Aladeens/butter chicken.jpg new file mode 100644 index 0000000..f49dd15 Binary files /dev/null and b/scripts/Aladeens/butter chicken.jpg differ diff --git a/scripts/Aladeens/butter paneer masala.jpg b/scripts/Aladeens/butter paneer masala.jpg new file mode 100644 index 0000000..daa2a30 Binary files /dev/null and b/scripts/Aladeens/butter paneer masala.jpg differ diff --git a/scripts/Aladeens/cafe.jpg b/scripts/Aladeens/cafe.jpg new file mode 100644 index 0000000..b3629cb Binary files /dev/null and b/scripts/Aladeens/cafe.jpg differ diff --git a/scripts/Aladeens/chicken biryani.jpg b/scripts/Aladeens/chicken biryani.jpg new file mode 100644 index 0000000..15ee93f Binary files /dev/null and b/scripts/Aladeens/chicken biryani.jpg differ diff --git a/scripts/Aladeens/chicken lollipop.jpg b/scripts/Aladeens/chicken lollipop.jpg new file mode 100644 index 0000000..d463bc0 Binary files /dev/null and b/scripts/Aladeens/chicken lollipop.jpg differ diff --git a/scripts/Aladeens/chicken roll.jpg b/scripts/Aladeens/chicken roll.jpg new file mode 100644 index 0000000..bfa7b71 Binary files /dev/null and b/scripts/Aladeens/chicken roll.jpg differ diff --git a/scripts/Aladeens/dal fry.jpg b/scripts/Aladeens/dal fry.jpg new file mode 100644 index 0000000..f2848e1 Binary files /dev/null and b/scripts/Aladeens/dal fry.jpg differ diff --git a/scripts/Aladeens/dal tadka.jpg b/scripts/Aladeens/dal tadka.jpg new file mode 100644 index 0000000..7fd039b Binary files /dev/null and b/scripts/Aladeens/dal tadka.jpg differ diff --git a/scripts/Aladeens/egg bhurji.jpg b/scripts/Aladeens/egg bhurji.jpg new file mode 100644 index 0000000..8710070 Binary files /dev/null and b/scripts/Aladeens/egg bhurji.jpg differ diff --git a/scripts/Aladeens/garlic naan.jpg b/scripts/Aladeens/garlic naan.jpg new file mode 100644 index 0000000..4886614 Binary files /dev/null and b/scripts/Aladeens/garlic naan.jpg differ diff --git a/scripts/Aladeens/jeera rice.jpg b/scripts/Aladeens/jeera rice.jpg new file mode 100644 index 0000000..11211ce Binary files /dev/null and b/scripts/Aladeens/jeera rice.jpg differ diff --git a/scripts/Aladeens/kadhai paneer.jpg b/scripts/Aladeens/kadhai paneer.jpg new file mode 100644 index 0000000..782b62c Binary files /dev/null and b/scripts/Aladeens/kadhai paneer.jpg differ diff --git a/scripts/Aladeens/logo.jpg b/scripts/Aladeens/logo.jpg new file mode 100644 index 0000000..296bfe8 Binary files /dev/null and b/scripts/Aladeens/logo.jpg differ diff --git a/scripts/Aladeens/mutter paneer.jpg b/scripts/Aladeens/mutter paneer.jpg new file mode 100644 index 0000000..359f885 Binary files /dev/null and b/scripts/Aladeens/mutter paneer.jpg differ diff --git a/scripts/Aladeens/oreo shake.jpg b/scripts/Aladeens/oreo shake.jpg new file mode 100644 index 0000000..57aa36a Binary files /dev/null and b/scripts/Aladeens/oreo shake.jpg differ diff --git a/scripts/Aladeens/paneer roll.jpg b/scripts/Aladeens/paneer roll.jpg new file mode 100644 index 0000000..05a4fcf Binary files /dev/null and b/scripts/Aladeens/paneer roll.jpg differ diff --git a/scripts/Aladeens/tandoori chicken recipe.jpg b/scripts/Aladeens/tandoori chicken recipe.jpg new file mode 100644 index 0000000..08c3dce Binary files /dev/null and b/scripts/Aladeens/tandoori chicken recipe.jpg differ diff --git a/scripts/Aladeens/tandoori chicken tikka.jpg b/scripts/Aladeens/tandoori chicken tikka.jpg new file mode 100644 index 0000000..16d7b2d Binary files /dev/null and b/scripts/Aladeens/tandoori chicken tikka.jpg differ diff --git a/scripts/Aladeens/tandoori paneer tikka.jpg b/scripts/Aladeens/tandoori paneer tikka.jpg new file mode 100644 index 0000000..296bfe8 Binary files /dev/null and b/scripts/Aladeens/tandoori paneer tikka.jpg differ diff --git a/scripts/Aladeens/tandoori roti butter.jpg b/scripts/Aladeens/tandoori roti butter.jpg new file mode 100644 index 0000000..606a864 Binary files /dev/null and b/scripts/Aladeens/tandoori roti butter.jpg differ diff --git a/scripts/Aladeens/tandoori roti plain.jpg b/scripts/Aladeens/tandoori roti plain.jpg new file mode 100644 index 0000000..3317246 Binary files /dev/null and b/scripts/Aladeens/tandoori roti plain.jpg differ diff --git a/scripts/Aladeens/veg biryani.jpg b/scripts/Aladeens/veg biryani.jpg new file mode 100644 index 0000000..8c45098 Binary files /dev/null and b/scripts/Aladeens/veg biryani.jpg differ diff --git a/scripts/Aladeens/veg manchurian.jpg b/scripts/Aladeens/veg manchurian.jpg new file mode 100644 index 0000000..331ba07 Binary files /dev/null and b/scripts/Aladeens/veg manchurian.jpg differ diff --git a/scripts/Jucilicious/banana shake.jpg b/scripts/Jucilicious/banana shake.jpg new file mode 100644 index 0000000..1207619 Binary files /dev/null and b/scripts/Jucilicious/banana shake.jpg differ diff --git a/scripts/Jucilicious/cafe.jpg b/scripts/Jucilicious/cafe.jpg new file mode 100644 index 0000000..9031758 Binary files /dev/null and b/scripts/Jucilicious/cafe.jpg differ diff --git a/scripts/Jucilicious/chiku shake.jpg b/scripts/Jucilicious/chiku shake.jpg new file mode 100644 index 0000000..5042fbf Binary files /dev/null and b/scripts/Jucilicious/chiku shake.jpg differ diff --git a/scripts/Jucilicious/cold coffee.jpg b/scripts/Jucilicious/cold coffee.jpg new file mode 100644 index 0000000..7af790f Binary files /dev/null and b/scripts/Jucilicious/cold coffee.jpg differ diff --git a/scripts/Jucilicious/kullad tea.jpg b/scripts/Jucilicious/kullad tea.jpg new file mode 100644 index 0000000..a78552d Binary files /dev/null and b/scripts/Jucilicious/kullad tea.jpg differ diff --git a/scripts/Jucilicious/lemon water.jpg b/scripts/Jucilicious/lemon water.jpg new file mode 100644 index 0000000..0eb740e Binary files /dev/null and b/scripts/Jucilicious/lemon water.jpg differ diff --git a/scripts/Jucilicious/logo.jpg b/scripts/Jucilicious/logo.jpg new file mode 100644 index 0000000..36b601e Binary files /dev/null and b/scripts/Jucilicious/logo.jpg differ diff --git a/scripts/Jucilicious/logo.png b/scripts/Jucilicious/logo.png new file mode 100644 index 0000000..a46b386 Binary files /dev/null and b/scripts/Jucilicious/logo.png differ diff --git a/scripts/Jucilicious/oreo shake.jpg b/scripts/Jucilicious/oreo shake.jpg new file mode 100644 index 0000000..2916301 Binary files /dev/null and b/scripts/Jucilicious/oreo shake.jpg differ diff --git a/scripts/Taste Buds/aloo puff.jpg b/scripts/Taste Buds/aloo puff.jpg new file mode 100644 index 0000000..f55ece2 Binary files /dev/null and b/scripts/Taste Buds/aloo puff.jpg differ diff --git a/scripts/Taste Buds/cafe.jpg b/scripts/Taste Buds/cafe.jpg new file mode 100644 index 0000000..2ad713a Binary files /dev/null and b/scripts/Taste Buds/cafe.jpg differ diff --git a/scripts/Taste Buds/chole bhature.jpg b/scripts/Taste Buds/chole bhature.jpg new file mode 100644 index 0000000..7937a25 Binary files /dev/null and b/scripts/Taste Buds/chole bhature.jpg differ diff --git a/scripts/Taste Buds/dosa.jpg b/scripts/Taste Buds/dosa.jpg new file mode 100644 index 0000000..b2f681a Binary files /dev/null and b/scripts/Taste Buds/dosa.jpg differ diff --git a/scripts/Taste Buds/logo.jpg b/scripts/Taste Buds/logo.jpg new file mode 100644 index 0000000..7937a25 Binary files /dev/null and b/scripts/Taste Buds/logo.jpg differ diff --git a/scripts/Taste Buds/pav bhaji.jpg b/scripts/Taste Buds/pav bhaji.jpg new file mode 100644 index 0000000..5af1ce5 Binary files /dev/null and b/scripts/Taste Buds/pav bhaji.jpg differ diff --git a/scripts/Taste Buds/taste buds.txt b/scripts/Taste Buds/taste buds.txt new file mode 100644 index 0000000..9b5b90b --- /dev/null +++ b/scripts/Taste Buds/taste buds.txt @@ -0,0 +1,4 @@ +Taste Buds is a eatery facility at IIT Indore managed by Bhopal Caterers. +Bhopal Caterers is a professionally managed organization in catering and food business with over 12 years of experience. +They are engaged in “On-site catering solutions” since 2001 and has achieved expertise in customized institutional catering. +They are providing services at IIT Indore since April 2016. \ No newline at end of file diff --git a/scripts/Taste Buds/veg manchurian.jpg b/scripts/Taste Buds/veg manchurian.jpg new file mode 100644 index 0000000..cfbe203 Binary files /dev/null and b/scripts/Taste Buds/veg manchurian.jpg differ diff --git a/scripts/Teapost/cafe.jpg b/scripts/Teapost/cafe.jpg new file mode 100644 index 0000000..c2ee724 Binary files /dev/null and b/scripts/Teapost/cafe.jpg differ diff --git a/scripts/Teapost/full tea.jpg b/scripts/Teapost/full tea.jpg new file mode 100644 index 0000000..e98ea61 Binary files /dev/null and b/scripts/Teapost/full tea.jpg differ diff --git a/scripts/Teapost/garlic bread.jpg b/scripts/Teapost/garlic bread.jpg new file mode 100644 index 0000000..0b79974 Binary files /dev/null and b/scripts/Teapost/garlic bread.jpg differ diff --git a/scripts/Teapost/half tea.jpg b/scripts/Teapost/half tea.jpg new file mode 100644 index 0000000..e98ea61 Binary files /dev/null and b/scripts/Teapost/half tea.jpg differ diff --git a/scripts/Teapost/logo.jpg b/scripts/Teapost/logo.jpg new file mode 100644 index 0000000..8a4f801 Binary files /dev/null and b/scripts/Teapost/logo.jpg differ diff --git a/scripts/Teapost/maska bun.png b/scripts/Teapost/maska bun.png new file mode 100644 index 0000000..9f64718 Binary files /dev/null and b/scripts/Teapost/maska bun.png differ diff --git a/scripts/Teapost/mexican cheese sandwich.png b/scripts/Teapost/mexican cheese sandwich.png new file mode 100644 index 0000000..8e7fa7b Binary files /dev/null and b/scripts/Teapost/mexican cheese sandwich.png differ diff --git a/scripts/Teapost/poha.jpg b/scripts/Teapost/poha.jpg new file mode 100644 index 0000000..aaf0ad7 Binary files /dev/null and b/scripts/Teapost/poha.jpg differ diff --git a/scripts/Teapost/teapost.txt b/scripts/Teapost/teapost.txt new file mode 100644 index 0000000..d7d585e --- /dev/null +++ b/scripts/Teapost/teapost.txt @@ -0,0 +1,4 @@ +Tea Post Pvt. Ltd. is a company with its root founded way back in 1975 as an old fashioned auction, retail tea shop but then in 2006 it diversified to be a well established tea company. +Now, the company has ventured in serving tea with a hygienic and pleasant ambience named as TEA POST. +The company saw a rapid growth in a short span via huge satisfied customer base and high return on low investment formula. +Tea Post has started it's services at IIT Indore since January 2018. \ No newline at end of file diff --git a/scripts/Teapost/thepla.png b/scripts/Teapost/thepla.png new file mode 100644 index 0000000..4b80829 Binary files /dev/null and b/scripts/Teapost/thepla.png differ diff --git a/scripts/Teapost/veg puff.png b/scripts/Teapost/veg puff.png new file mode 100644 index 0000000..32ec283 Binary files /dev/null and b/scripts/Teapost/veg puff.png differ diff --git a/scripts/Teapost/veggie fingers.png b/scripts/Teapost/veggie fingers.png new file mode 100644 index 0000000..5a17a6e Binary files /dev/null and b/scripts/Teapost/veggie fingers.png differ diff --git a/scripts/Zippy/cafe.jpg b/scripts/Zippy/cafe.jpg new file mode 100644 index 0000000..480790b Binary files /dev/null and b/scripts/Zippy/cafe.jpg differ diff --git a/scripts/Zippy/chicken biryani.jpg b/scripts/Zippy/chicken biryani.jpg new file mode 100644 index 0000000..200b9f1 Binary files /dev/null and b/scripts/Zippy/chicken biryani.jpg differ diff --git a/scripts/Zippy/egg omelet.jpg b/scripts/Zippy/egg omelet.jpg new file mode 100644 index 0000000..08e1fb6 Binary files /dev/null and b/scripts/Zippy/egg omelet.jpg differ diff --git a/scripts/Zippy/logo.jpg b/scripts/Zippy/logo.jpg new file mode 100644 index 0000000..200b9f1 Binary files /dev/null and b/scripts/Zippy/logo.jpg differ diff --git a/scripts/Zippy/samosa.jpg b/scripts/Zippy/samosa.jpg new file mode 100644 index 0000000..c0744bf Binary files /dev/null and b/scripts/Zippy/samosa.jpg differ diff --git a/scripts/Zippy/schezwan fried rice.png b/scripts/Zippy/schezwan fried rice.png new file mode 100644 index 0000000..316a63d Binary files /dev/null and b/scripts/Zippy/schezwan fried rice.png differ diff --git a/scripts/Zippy/tandoori chicken.png b/scripts/Zippy/tandoori chicken.png new file mode 100644 index 0000000..bc54799 Binary files /dev/null and b/scripts/Zippy/tandoori chicken.png differ diff --git a/scripts/Zippy/veg biryani.jpg b/scripts/Zippy/veg biryani.jpg new file mode 100644 index 0000000..9337309 Binary files /dev/null and b/scripts/Zippy/veg biryani.jpg differ diff --git a/scripts/Zippy/veg hakka noodles.jpg b/scripts/Zippy/veg hakka noodles.jpg new file mode 100644 index 0000000..0ffd31d Binary files /dev/null and b/scripts/Zippy/veg hakka noodles.jpg differ diff --git a/scripts/aladeens.json b/scripts/aladeens.json new file mode 100644 index 0000000..b171e3e --- /dev/null +++ b/scripts/aladeens.json @@ -0,0 +1,505 @@ +[{ + "name": "Paneer roll", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Tandoori paneer tikka", + "description": " ", + "image": " ", + "category": "Appetizer", + "label": " ", + "price": "85", + "featured": "false" + }, + { + "name": "Chilli paneer dry", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "100", + "featured": "false" + }, + { + "name": "Chilli paneer gravy", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Paneer 65 Dry", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "100", + "featured": "false" + }, + { + "name": "Paneer 65 gravy", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Butter paneer masala", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "115", + "featured": "false" + }, + { + "name": "Paneer tikka masala", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "115", + "featured": "false" + }, + { + "name": "Kadhai paneer", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "115", + "featured": "false" + }, + { + "name": "Mutter paneer", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "115", + "featured": "false" + }, + { + "name": "Schezwan paneer", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "115", + "featured": "false" + }, + { + "name": "Dal fry", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "60", + "featured": "false" + }, + { + "name": "Dal tadka", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Veg Manchurian", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Veg fried rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "100", + "featured": "false" + }, + { + "name": "Veg biryani", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "100", + "featured": "false" + }, + { + "name": "Paneer roll", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Plain rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Jeera rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Chicken roll", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "75", + "featured": "false" + }, + { + "name": "Tandoori chicken tikka", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Tandoori chicken", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "145", + "featured": "false" + }, + { + "name": "Chicken Lollipop", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "115", + "featured": "false" + }, + { + "name": "Chilli chicken dry", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Chilli chicken gravy", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "130", + "featured": "false" + }, + { + "name": "Chicken 65 dry", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Chicken 65 gravy", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "130", + "featured": "false" + }, + { + "name": "Butter chicken", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "145", + "featured": "false" + }, + { + "name": "Chicken masala", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "145", + "featured": "false" + }, + { + "name": "Kadhai chicken", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "145", + "featured": "false" + }, + { + "name": "Chicken homestyle", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "145", + "featured": "false" + }, + { + "name": "Egg bhurji curry", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "60", + "featured": "false" + }, + { + "name": "Chicken fried rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "100", + "featured": "false" + }, + { + "name": "Chicken tikka biryani", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Chicken dum biryani", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Tandori roti plain", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "8", + "featured": "false" + }, + { + "name": "Tandoori roti butter", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "10", + "featured": "false" + }, + { + "name": "Plain naan", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "15", + "featured": "false" + }, + { + "name": "Butter naan", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Cheese naan", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Garlic naan", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Plain maggi", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Veg maggi", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Cheese maggi", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Strawberry shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Black current shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Black current shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Mango shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Butterscotch shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Oreo shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Lemon soda", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Thums up", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Coke", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Fanta", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Sprite", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Maaza", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "20", + "featured": "false" + } +] \ No newline at end of file diff --git a/scripts/jucilicious.json b/scripts/jucilicious.json new file mode 100644 index 0000000..7383454 --- /dev/null +++ b/scripts/jucilicious.json @@ -0,0 +1,64 @@ +[{ + "name": "Kullad tea half", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "12", + "featured": "false" + }, + { + "name": "Kullad tea full", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "24", + "featured": "false" + }, + { + "name": "Banana shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Chiku shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Cold coffee", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Nimbu Pani", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Oreo shake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "60", + "featured": "false" + } +] \ No newline at end of file diff --git a/scripts/script.py b/scripts/script.py new file mode 100644 index 0000000..7111169 --- /dev/null +++ b/scripts/script.py @@ -0,0 +1,67 @@ +import os +import requests +import json +import sys +cafe_names = [f.name for f in os.scandir('.') if f.is_dir()] +cafe_json = [f.name for f in os.scandir('.') if f.is_file()] +print(cafe_json) +print(cafe_names) +base_url = "" # api endpoint route, usually http://localhost:5000/api + + +def uploadDish(token, name, price, description, featured, path): + url = base_url+'/menu/withImage' + payload = {'dish_name': name, + 'price': int(price)*100, + 'availablity': 'true', + 'description': description, + 'featured': featured} + files = [ + ('dishImage', open(path, 'rb')) + ] + headers = { + 'x-auth-token': token + } + + response = requests.request( + "POST", url, headers=headers, data=payload, files=files) + + print(response.text.encode('utf8')) + + +for cafe_name in cafe_names: + cafe_description = '' + files = [f for f in os.listdir( + cafe_name) if os.path.isfile(os.path.join(cafe_name, f))] + if(os.path.exists(os.path.join(cafe_name, cafe_name.lower()+'.txt'))): + with open(os.path.join(cafe_name, cafe_name.lower()+'.txt'), 'r', encoding='utf-8') as f: + cafe_description = f.read() + payload = {'name': cafe_name, + 'email': cafe_name.lower()+'@email.com', + 'password': cafe_name.lower(), 'description': cafe_description} + files_ = [] + + if(os.path.exists(os.path.join(cafe_name, 'cafe.jpg'))): + files_.append( + ('cafeImage', open(os.path.join(cafe_name, 'cafe.jpg'), 'rb'))) + if(os.path.exists(os.path.join(cafe_name, 'logo.jpg'))): + files_.append( + ('logoImage', open(os.path.join(cafe_name, 'logo.jpg'), 'rb'))) + response = requests.request( + "POST", base_url+'/profile/register/cafe/withImage', headers={}, data=payload, files=files_) + response_dict = json.loads(response.text) + if not "token" in response_dict: + print('no token found, ending script') + sys.exit() + token = response_dict['token'] + + if cafe_name.lower()+'.json' in cafe_json: + print('Currently working wih cafe name', cafe_name) + with open(cafe_name+'.json', 'r', encoding='utf-8') as f: + dishes = json.load(f) + for dish in dishes: + for dish_picture_name in files: + if os.path.splitext(dish_picture_name)[0] in dish["name"].lower(): + print(dish['name']) + uploadDish( + token, dish['name'], dish['price'], dish['description'], dish['featured'], os.path.join(cafe_name, dish_picture_name)) diff --git a/scripts/taste buds.json b/scripts/taste buds.json new file mode 100644 index 0000000..0cc98fb --- /dev/null +++ b/scripts/taste buds.json @@ -0,0 +1,658 @@ +[{ + "name": "Aloo paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "55", + "featured": "false" + }, + { + "name": "Paneer paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Tawa roti", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Butter chicken w/ paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "155", + "featured": "false" + }, + { + "name": "Butter chicken w/ rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "155", + "featured": "false" + }, + { + "name": "Chicken curry w/ paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "155", + "featured": "false" + }, + { + "name": "Chicken curry w/ rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "155", + "featured": "false" + }, + { + "name": "Butter paneer w/ paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "110", + "featured": "false" + }, + { + "name": "Butter paneer w/ rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "110", + "featured": "false" + }, + { + "name": "Veg biryani", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "110", + "featured": "false" + }, + { + "name": "Chicken biryani", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "135", + "featured": "false" + }, + { + "name": "Chicken fried rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "100", + "featured": "false" + }, + { + "name": "Egg fried rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "95", + "featured": "false" + }, + { + "name": "Veg fried rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Chicken hakka noodles", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "115", + "featured": "false" + }, + { + "name": "Veg hakka noodles", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "95", + "featured": "false" + }, + { + "name": "Chilli paneer", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "110", + "featured": "false" + }, + { + "name": "Chilli chicken", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "150", + "featured": "false" + }, + { + "name": "Veg manchurian", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "110", + "featured": "false" + }, + { + "name": "Pasta alfredo", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "110", + "featured": "false" + }, + { + "name": "Pasta arrabiata", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "110", + "featured": "false" + }, + { + "name": "Chicken spring roll", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "95", + "featured": "false" + }, + { + "name": "veg spring roll", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Chola bhatura", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Pav bhaji", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Sada Dosa", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Uttapam", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "90", + "featured": "false" + }, + { + "name": "Masala Dosa", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Pav bhaji", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Idli sambar", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Tea", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "10", + "featured": "false" + }, + { + "name": "Tea", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Hot coffee", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "15", + "featured": "false" + }, + { + "name": "Cookies 250", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "250", + "featured": "false" + }, + { + "name": "Cookies 300", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "300", + "featured": "false" + }, + { + "name": "Cookies 350", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "350", + "featured": "false" + }, + { + "name": "Puff 180", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "180", + "featured": "false" + }, + { + "name": "Puff 200", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "200", + "featured": "false" + }, + { + "name": "Muffin", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Dry cake", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "E/L Brownie", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Rum Ball", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "25", + "featured": "false" + }, + { + "name": "Pineapple pastry", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Chocolate doughnuts", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Black forest pastry", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Truffle pastry", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Aloo mutter", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "15", + "featured": "false" + }, + { + "name": "Patties", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Paneer patties", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Spring patties", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Chicken patties", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Cream roll", + "description": " ", + "image": " ", + "category": "Dessert", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Gulab Jamun", + "description": " ", + "image": " ", + "category": "Dessert", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Kala Jamun", + "description": " ", + "image": " ", + "category": "Dessert", + "label": " ", + "price": "15", + "featured": "false" + }, + { + "name": "Samosa", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "65", + "featured": "false" + }, + { + "name": "Cold coffee with ice-cream", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "45", + "featured": "false" + }, + { + "name": "Cold coffee", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Shakes with ice-cream", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Chocolate shakes", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "55", + "featured": "false" + }, + { + "name": "Mini veg Pizza", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "25", + "featured": "false" + }, + { + "name": "Roll chilli paneer", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "25", + "featured": "false" + }, + { + "name": "Roll Chowmin", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Veg burger cheese", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Coleslaw sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Paneer tikka sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "55", + "featured": "false" + }, + { + "name": "Roasted veg sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "55", + "featured": "false" + }, + { + "name": "Chicken mayonnaise sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Chicken tikka sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "60", + "featured": "false" + }, + { + "name": "Jeera rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "35", + "featured": "false" + }, + { + "name": "Bread Omelette", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "25", + "featured": "false" + }, + { + "name": "Omelette", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "10", + "featured": "false" + }, + { + "name": "Plain paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Dal mini bowl", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "30", + "featured": "false" + } +] \ No newline at end of file diff --git a/scripts/teapost.json b/scripts/teapost.json new file mode 100644 index 0000000..d3fdd16 --- /dev/null +++ b/scripts/teapost.json @@ -0,0 +1,271 @@ +[{ + "name": "Half tea", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "12", + "featured": "false" + }, + { + "name": "Full tea", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Flavour tea", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "35", + "featured": "false" + }, + { + "name": "Ice tea", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Hot Bournvita", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Cold Bournvita", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "60", + "featured": "false" + }, + { + "name": "Chocolate milkshake", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Black coffee", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "25", + "featured": "false" + }, + { + "name": "Hot coffee", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "35", + "featured": "false" + }, + { + "name": "Cold coffee", + "description": " ", + "image": " ", + "category": "Beverage", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Thepla", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "25", + "featured": "false" + }, + { + "name": "Poha", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Handvo", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Upma", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Maska Bun", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "25", + "featured": "false" + }, + { + "name": "Oats", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "French fries", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Veggie fingers", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Cheese garlic bread", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "60", + "featured": "false" + }, + { + "name": "Bread butter sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Mexican cheese sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Tandoori paneer sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "80", + "featured": "false" + }, + { + "name": "Vegetable sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Cheese chilli sandwich", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "50", + "featured": "false" + }, + { + "name": "Aloo puff ", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Cheese puff", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "35", + "featured": "false" + }, + { + "name": "Mexican puff", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Noodles", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Bhakhri", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Khakhra", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "10", + "featured": "false" + } +] \ No newline at end of file diff --git a/scripts/zippy.json b/scripts/zippy.json new file mode 100644 index 0000000..dca25bb --- /dev/null +++ b/scripts/zippy.json @@ -0,0 +1,127 @@ +[{ + "name": "Chicken Biryani", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Veg Biryani", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "90", + "featured": "false" + }, + { + "name": "Egg omelette", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Samosa", + "description": " ", + "image": " ", + "category": "Snacks", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Schezwan fried rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Tandoori chicken", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "120", + "featured": "false" + }, + { + "name": "Veg hakka noodles", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "90", + "featured": "false" + }, + { + "name": "Paneer bhurji", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "60", + "featured": "false" + }, + { + "name": "Roti", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "5", + "featured": "false" + }, + { + "name": "Plain paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "20", + "featured": "false" + }, + { + "name": "Aloo paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "30", + "featured": "false" + }, + { + "name": "Paneer paratha", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "40", + "featured": "false" + }, + { + "name": "Dal rice", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "70", + "featured": "false" + }, + { + "name": "Veg thali", + "description": " ", + "image": " ", + "category": "Main", + "label": " ", + "price": "80", + "featured": "false" + } +] \ No newline at end of file