├── .gitignore ├── README.md ├── app.js ├── config └── database.js ├── controllers ├── CartController.js ├── categoryController.js ├── pageController.js ├── productController.js └── productMainController.js ├── models ├── category.js ├── page.js ├── product.js └── product_image.js ├── package-lock.json ├── package.json ├── public ├── css │ ├── bootstrap-theme.css │ ├── bootstrap-theme.css.map │ ├── bootstrap-theme.min.css │ ├── bootstrap.css │ ├── bootstrap.css.map │ ├── bootstrap.min.css │ └── style.css ├── fonts │ ├── glyphicons-halflings-regular.eot │ ├── glyphicons-halflings-regular.svg │ ├── glyphicons-halflings-regular.ttf │ ├── glyphicons-halflings-regular.woff │ └── glyphicons-halflings-regular.woff2 ├── images │ ├── 1.PNG │ ├── 2.PNG │ ├── 3.PNG │ ├── 4.PNG │ ├── 5.PNG │ ├── 6.PNG │ └── noimage.png ├── js │ ├── bootstrap.js │ ├── bootstrap.min.js │ ├── dropzone.js │ ├── jquery.min.js │ └── npm.js └── product_images │ ├── vwzfg1i8jdroz9d8.png │ ├── vwzfg1i8jdroz9d9.png │ ├── vwzfg1i8jdroza5f.png │ ├── vwzfg1i8jdroza5g.png │ ├── vwzfg1i8jdroza70.png │ ├── vwzfg1i8jdrozaxj.png │ ├── vwzfg1i8jdrozbps.png │ ├── vwzfg1i8jdrozbr6.png │ ├── vwzfg1i8jdrpby3x.png │ ├── vwzfg1i8jdrpby3y.png │ ├── vwzfg1i8jdrpby3z.png │ ├── vwzfg1i8jdrpby41.png │ ├── vwzfg1i8jdrpby42.png │ ├── vwzfg1i8jdrpby43.png │ ├── vwzfg1i8jdrpby7v.png │ ├── vwzfg1i8jdrpby7x.png │ ├── vwzfg6dkjdkozxkl.png │ ├── vwzfg6f4jdphlwdf.png │ ├── vwzfg7eojdwnwv3d.png │ ├── vwzfg7eojdwnxe1u.png │ ├── vwzfg7eojdwnxyr3.png │ ├── vwzfg7eojdwnygie.png │ ├── vwzfg7eojdwnywi6.png │ ├── vwzfg7eojdwnziph.png │ ├── vwzfg7eojdwnzw2a.png │ ├── vwzfg7eojdwo0kf5.png │ ├── vwzfg7eojdwo1309.png │ └── vwzfg7eojdwo1lix.png ├── routes ├── admin_categories.js ├── admin_pages.js ├── admin_products.js ├── cartRoute.js ├── pages.js └── products_route.js ├── views ├── ProductHome │ ├── allproduct.html │ └── product_single.html ├── admin │ ├── add_page.html │ ├── edit_page.html │ └── pages.html ├── cart │ └── cartindex.html ├── category │ ├── add_page.html │ ├── edit_page.html │ └── pages.html ├── index.html ├── layouts │ ├── admin_master.html │ ├── cartmaster.html │ └── master.html ├── messages.html └── product │ ├── add_page.html │ ├── edit_page.html │ └── pages.html └── yarn.lock /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | .idea/ -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # NodeJS Ecommerce Development 2 | ## developed by tapos ghosh 3 | 4 | 5 | 6 | ![alt text](https://github.com/tapos007/eCommerce-node-js/blob/master/public/images/1.PNG "Home Page") 7 | 8 | 9 | ### Display Product ALL Information 10 | 11 | ![alt text](https://github.com/tapos007/eCommerce-node-js/blob/master/public/images/2.PNG "Product list ") 12 | 13 | 14 | ### Display Single Product View 15 | 16 | ![alt text](https://github.com/tapos007/eCommerce-node-js/blob/master/public/images/6.PNG "Product list ") 17 | 18 | 19 | 20 | ### Display Admin Product List with add Product option 21 | 22 | ![alt text](https://github.com/tapos007/eCommerce-node-js/blob/master/public/images/3.PNG "Admin Display all product") 23 | 24 | 25 | ### Display Admin Product Edit option 26 | 27 | ![alt text](https://github.com/tapos007/eCommerce-node-js/blob/master/public/images/4.PNG "Admin Product Edit") 28 | 29 | 30 | ### Display Admin Product related Image Upload 31 | 32 | ![alt text](https://github.com/tapos007/eCommerce-node-js/blob/master/public/images/5.PNG "Admin Image Upload") 33 | -------------------------------------------------------------------------------- /app.js: -------------------------------------------------------------------------------- 1 | const express = require('express'); 2 | const path = require('path'); 3 | const cons = require('consolidate'); 4 | const mongoose = require('mongoose'); 5 | const bodyParser = require('body-parser'); 6 | const cookieParser = require('cookie-parser'); 7 | const flash = require('express-flash-2'); 8 | const session = require('express-session'); 9 | const { check, validationResult } = require('express-validator/check'); 10 | const { matchedData, sanitize } = require('express-validator/filter'); 11 | const config = require('./config/database'); 12 | const fileUpload = require('express-fileupload'); 13 | const fs = require('fs-extra'); 14 | const mkdirp = require('mkdirp'); 15 | const app = express(); 16 | // connect with mongo db 17 | mongoose.connect(config.database); 18 | // assign the nunjucks engine to .html files 19 | app.engine('html', cons.nunjucks); 20 | 21 | // set .html as the default extension 22 | 23 | app.set('view engine', 'html'); 24 | app.set('views', __dirname + '/views'); 25 | // static files for image , css, javascript 26 | 27 | app.use(express.static('public')); 28 | 29 | // set global errors variable 30 | app.locals.errors = null; 31 | 32 | // Get page model 33 | var Page = require('./models/page'); 34 | var Category = require('./models/category'); 35 | 36 | Page.find({}).sort({'sorting': 1}).exec((err, pages) => { 37 | if(err){ 38 | console.log(err); 39 | }else{ 40 | app.locals.pages = pages; 41 | } 42 | }); 43 | // get all category 44 | Category.find((err, categories) => { 45 | if(err){ 46 | console.log(err); 47 | }else{ 48 | app.locals.categories = categories; 49 | } 50 | }); 51 | 52 | // add express-fileupload middleware 53 | app.use(fileUpload({ 54 | // safeFileNames: true 55 | })); 56 | 57 | 58 | // add body parser middleware 59 | 60 | // parse application/x-www-form-urlencoded 61 | app.use(bodyParser.urlencoded({ extended: false })); 62 | // parse application/json 63 | app.use(bodyParser.json()); 64 | 65 | // end add body parser middleware 66 | 67 | // add session 68 | app.use(cookieParser('keyboard cat')); 69 | app.use(session({ 70 | secret: 'keyboard cat', 71 | resave: true, 72 | saveUninitialized: true 73 | })); 74 | app.use(flash()); 75 | 76 | // end session 77 | 78 | // 79 | 80 | var db = mongoose.connection; 81 | db.on('error', console.error.bind(console, 'connection error:')); 82 | db.once('open', function() { 83 | console.log("its open now"); 84 | }); 85 | 86 | // get cart data 87 | 88 | app.get('*',(req,res,next)=>{ 89 | res.locals.cart = req.session.cart; 90 | next(); 91 | }); 92 | 93 | // set routes 94 | var pages = require('./routes/pages'); 95 | var adminPages = require('./routes/admin_pages'); 96 | var adminCategories = require('./routes/admin_categories'); 97 | var adminProduct = require('./routes/admin_products'); 98 | var ProductRoute = require('./routes/products_route'); 99 | var CartRoute = require('./routes/cartRoute'); 100 | 101 | app.use('/admin/pages',adminPages); 102 | app.use('/admin/category',adminCategories); 103 | app.use('/admin/products',adminProduct); 104 | app.use('/products',ProductRoute); 105 | app.use('/cart',CartRoute); 106 | app.use('/',pages); 107 | 108 | 109 | 110 | 111 | app.listen(3000, () => console.log('Example app listening on port 3000!')) -------------------------------------------------------------------------------- /config/database.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | database : 'mongodb://localhost/cmscart', 3 | } -------------------------------------------------------------------------------- /controllers/CartController.js: -------------------------------------------------------------------------------- 1 | const {check, validationResult} = require('express-validator/check'); 2 | const {matchedData, sanitize} = require('express-validator/filter'); 3 | const Product = require('../models/product'); 4 | require('express-async-errors'); 5 | 6 | module.exports = { 7 | ShowCartPage: async (req, res) => { 8 | res.render("cart/cartindex"); 9 | }, 10 | 11 | AddPRoductCart: async (req, res) => { 12 | try{ 13 | let nowSlug = req.params.slug; 14 | let product = await Product.findOne({slug:nowSlug}); 15 | let {title,slug,_id,price,desc,image} = product; 16 | if(typeof req.session.cart =="undefined"){ 17 | req.session.cart = []; 18 | req.session.cart.push({title,slug,_id,price,desc,image,qty:1}); 19 | }else{ 20 | var foundIndex = req.session.cart.findIndex(x => x._id == product._id); 21 | console.log("is data",foundIndex); 22 | if(foundIndex>=0){ 23 | req.session.cart[foundIndex]['qty']++; 24 | res.flash('success','Product Updated'); 25 | }else{ 26 | req.session.cart.push({title,slug,_id,price,desc,image,qty:1}); 27 | res.flash('success','Product added'); 28 | } 29 | } 30 | res.redirect('back'); 31 | }catch(err){ 32 | console.log(err); 33 | } 34 | 35 | }, 36 | 37 | CartPageProductUpdate: async (req,res)=>{ 38 | var id = req.body.id; 39 | var qty = req.body.qty; 40 | var foundIndex = req.session.cart.findIndex(x => x._id == id); 41 | if(foundIndex>=0){ 42 | req.session.cart[foundIndex]['qty'] = qty; 43 | } 44 | var total = 0; 45 | req.session.cart.forEach(x=>{ 46 | total += (x.price * x.qty); 47 | }); 48 | res.send({success:true,msg:"update sucessfully",total}); 49 | 50 | 51 | }, 52 | 53 | CartPageProductDelete: async (req,res)=>{ 54 | var id = req.body.id; 55 | var foundIndex = req.session.cart.findIndex(x => x._id == id); 56 | console.log(foundIndex); 57 | if(foundIndex>=0){ 58 | req.session.cart.splice(foundIndex, 1); 59 | } 60 | var total = 0; 61 | req.session.cart.forEach(x=>{ 62 | total += (x.price * x.qty); 63 | }); 64 | res.send({success:true,msg:"delete sucessfully",total}); 65 | 66 | 67 | } 68 | 69 | 70 | }; 71 | 72 | -------------------------------------------------------------------------------- /controllers/categoryController.js: -------------------------------------------------------------------------------- 1 | const {check, validationResult} = require('express-validator/check'); 2 | const {matchedData, sanitize} = require('express-validator/filter'); 3 | const Category = require('../models/category'); 4 | require('express-async-errors'); 5 | 6 | module.exports = { 7 | getAllCategory: async (req, res) => { 8 | Category.find({}).exec((err,categories)=>{ 9 | res.render('category/pages',{ 10 | categories 11 | }); 12 | }); 13 | }, 14 | 15 | categoryCreateGet: async (req, res) => { 16 | var title =""; 17 | var slug = ""; 18 | res.render('category/add_page',{ 19 | title, 20 | slug 21 | }); 22 | }, 23 | 24 | categoryCreatePost: async (req, res) => { 25 | 26 | let {title} = req.body; 27 | let slug = req.body.slug.replace(/\s+/g,'-').toLowerCase(); 28 | if(slug=="") slug = title.replace(/\s+/g,'-').toLowerCase(); 29 | const errors = validationResult(req); 30 | if (!errors.isEmpty()) { 31 | res.render('category/add_page', { 32 | title,slug,errors: errors.array() }); 33 | }else{ 34 | Category.findOne({ 'slug': slug }, (err, page)=> { 35 | if(page){ 36 | res.flash('danger','Category slug exits , choolse another.'); 37 | res.render('category/add_page', { title,slug }); 38 | 39 | }else{ 40 | var category = new Category({ title,slug }); 41 | category.save(function (err) { 42 | if (err) return console.log(err); 43 | 44 | res.flash('success','Category Added.'); 45 | res.redirect('/admin/category'); 46 | } 47 | ); 48 | } 49 | }); 50 | } 51 | 52 | }, 53 | categoryUpdateGet: async (req, res) => { 54 | try { 55 | var Dataslug = req.param('slug'); 56 | var category = await Category.findOne({'slug':Dataslug}); 57 | let {title,slug,content,_id}= category; 58 | res.render('category/edit_page',{title,slug,_id}); 59 | }catch(err){ 60 | res.flash('error',err.message); 61 | res.redirect('/admin/category'); 62 | } 63 | }, 64 | categoryUpdatePost: async (req, res) => { 65 | var backURL=req.header('Referer') || '/'; 66 | let {title} = req.body; 67 | let slug = title.replace(/\s+/g,'-').toLowerCase(); 68 | let id = req.body.id; 69 | const errors = validationResult(req); 70 | if (!errors.isEmpty()) { 71 | console.log(errors); 72 | // do your thang 73 | res.redirect(backURL); 74 | }else{ 75 | 76 | try{ 77 | 78 | var category = await Category.findOne({slug,_id:{'$ne':id}}); 79 | 80 | if(category){ 81 | res.flash('info','category slug exits, choose another'); 82 | // do your thang 83 | // console.log(req); 84 | res.redirect('/admin/category'); 85 | }else{ 86 | var nowCategory = await Category.findById(id); 87 | nowCategory.title = title; 88 | nowCategory.slug = slug; 89 | await nowCategory.save(); 90 | await RearrangeMenu(req); 91 | res.flash('success','Category update successfully'); 92 | res.redirect('/admin/category'); 93 | } 94 | 95 | }catch(err){ 96 | res.flash('danger',err.message); 97 | // do your thang 98 | res.redirect(backURL); 99 | } 100 | 101 | } 102 | 103 | }, 104 | 105 | categoryDeletePost:async (req, res) => { 106 | try { 107 | var slug = req.params.slug; 108 | var category = await Category.findOne({slug}); 109 | if(category){ 110 | await category.remove(); 111 | await RearrangeMenu(req); 112 | res.json({success:true,message:"category delete successfully"}); 113 | } 114 | }catch(err){ 115 | res.json({success:false,message:"category delete not success"}); 116 | } 117 | }, 118 | 119 | 120 | }; 121 | 122 | async function RearrangeMenu(req){ 123 | 124 | Category.find((err, categories) => { 125 | if(err){ 126 | console.log(err); 127 | }else{ 128 | req.app.locals.categories = categories; 129 | } 130 | }); 131 | 132 | } 133 | -------------------------------------------------------------------------------- /controllers/pageController.js: -------------------------------------------------------------------------------- 1 | const {check, validationResult} = require('express-validator/check'); 2 | const {matchedData, sanitize} = require('express-validator/filter'); 3 | const Page = require('../models/page'); 4 | require('express-async-errors'); 5 | 6 | module.exports = { 7 | getAllPage: async (req, res) => { 8 | Page.find({}).sort({'sorting': 1}).exec((err, pages) => { 9 | res.render('admin/pages', { 10 | pages: pages 11 | }); 12 | }); 13 | }, 14 | 15 | pageCreateGet: async (req, res) => { 16 | var title =""; 17 | var slug = ""; 18 | var content = ""; 19 | res.render('admin/add_page',{ 20 | title, 21 | slug, 22 | content 23 | }); 24 | }, 25 | 26 | pageCreatePost: async (req, res) => { 27 | 28 | 29 | let {title,content} = req.body; 30 | let slug = req.body.slug.replace(/\s+/g,'-').toLowerCase(); 31 | if(slug=="") slug = title.replace(/\s+/g,'-').toLowerCase(); 32 | const errors = validationResult(req); 33 | if (!errors.isEmpty()) { 34 | res.render('admin/add_page', { 35 | title,slug,content,errors: errors.array() }); 36 | }else{ 37 | Page.findOne({ 'slug': slug }, (err, page)=> { 38 | if(page){ 39 | res.flash('danger','Page slug exits , choolse another.'); 40 | res.render('admin/add_page', { title,slug,content }); 41 | 42 | }else{ 43 | var page = new Page({ title,slug,content,sorting:100 }); 44 | page.save(function (err) { 45 | if (err) return console.log(err); 46 | 47 | res.flash('success','Page Added.'); 48 | res.redirect('/admin/pages'); 49 | } 50 | ); 51 | } 52 | }); 53 | } 54 | }, 55 | pageUpdateGet: async (req, res) => { 56 | try { 57 | var Dataslug = req.param('slug'); 58 | var page = await Page.findOne({'slug':Dataslug}); 59 | let {title,slug,content,_id}= page; 60 | res.render('admin/edit_page',{title,slug,content,_id}); 61 | }catch(err){ 62 | res.flash('error',err.message); 63 | res.redirect('/admin/pages'); 64 | } 65 | }, 66 | pageUpdatePost: async (req, res) => { 67 | 68 | var backURL=req.header('Referer') || '/'; 69 | let {title,content} = req.body; 70 | let slug = title.replace(/\s+/g,'-').toLowerCase(); 71 | let id = req.body.id; 72 | const errors = validationResult(req); 73 | if (!errors.isEmpty()) { 74 | console.log(errors); 75 | // do your thang 76 | res.redirect(backURL); 77 | }else{ 78 | 79 | try{ 80 | 81 | var page = await Page.findOne({slug,_id:{'$ne':id}}); 82 | 83 | if(page){ 84 | res.flash('info','Page slug exits, choose another'); 85 | // do your thang 86 | // console.log(req); 87 | res.redirect('/admin/pages'); 88 | }else{ 89 | var nowPage = await Page.findById(id); 90 | nowPage.title = title; 91 | nowPage.slug = slug; 92 | nowPage.content = content; 93 | await nowPage.save(); 94 | await reorderMenu(req); 95 | res.redirect('/admin/pages'); 96 | } 97 | 98 | }catch(err){ 99 | res.flash('danger',err.message); 100 | // do your thang 101 | res.redirect(backURL); 102 | } 103 | 104 | } 105 | }, 106 | 107 | pageDeletePost:async (req, res) => { 108 | try { 109 | var slug = req.params.slug; 110 | var page = await Page.findOne({slug}); 111 | if(page){ 112 | await page.remove(); 113 | await reorderMenu(req); 114 | res.json({success:true,message:"page delete successfully"}); 115 | } 116 | }catch(err){ 117 | res.json({success:false,message:"page delete not success"}); 118 | } 119 | }, 120 | 121 | pageReorderPost: async (req, res) => { 122 | var ids = req.body['id[]']; 123 | await sortPages(ids); 124 | await reorderMenu(req); 125 | 126 | 127 | }, 128 | 129 | pageSinglePost: async (req, res) => { 130 | 131 | try{ 132 | var nowslug = req.params.slug; 133 | var page = await Page.findOne({'slug':nowslug}); 134 | let {title,slug,content,_id} = page; 135 | res.render('index',{title,slug,content,_id}); 136 | }catch(err){ 137 | res.redirect('/'); 138 | } 139 | }, 140 | 141 | pageSinglePostHome: async (req, res) => { 142 | try{ 143 | var nowslug = 'home'; 144 | var page = await Page.findOne({'slug':nowslug}); 145 | let {title,slug,content,_id} = page; 146 | res.render('index',{title,slug,content,_id}); 147 | }catch(err){ 148 | res.redirect('/'); 149 | } 150 | }, 151 | }; 152 | 153 | async function sortPages(ids){ 154 | var count = 0; 155 | for (let id of ids) { 156 | try { 157 | count++; 158 | const page = await Page.findById(id); 159 | page.sorting = count; 160 | await page.save(); 161 | } catch (err) { 162 | console.log(err); 163 | } 164 | } 165 | 166 | } 167 | 168 | 169 | async function reorderMenu(req){ 170 | Page.find({}).sort({'sorting': 1}).exec((err, pages) => { 171 | if(err){ 172 | console.log(err); 173 | }else{ 174 | req.app.locals.pages = pages; 175 | } 176 | }); 177 | 178 | } -------------------------------------------------------------------------------- /controllers/productController.js: -------------------------------------------------------------------------------- 1 | const {check, validationResult} = require('express-validator/check'); 2 | const {matchedData, sanitize} = require('express-validator/filter'); 3 | const Product = require('../models/product'); 4 | const Category = require('../models/category'); 5 | const fs = require('fs-extra'); 6 | const mkdirp = require('mkdirp'); 7 | const resizeImg = require('resize-img'); 8 | var uniqid = require('uniqid'); 9 | require('express-async-errors'); 10 | 11 | module.exports = { 12 | getAllProduct: async (req, res) => { 13 | 14 | try { 15 | const [count, products] = await Promise.all([ 16 | Product.count(), 17 | Product.find({}) 18 | 19 | ]); 20 | res.render('product/pages', {count, products}); 21 | 22 | } catch (err) { 23 | console.log("some error"); 24 | } 25 | }, 26 | 27 | productCreateGet: async (req, res) => { 28 | var title = ""; 29 | var desc = ""; 30 | var price = ""; 31 | var categories = await Category.find({}); 32 | res.render('product/add_page', { 33 | title, 34 | desc, 35 | price, 36 | categories 37 | }); 38 | }, 39 | 40 | productCreatePost: async (req, res) => { 41 | 42 | let {title, desc, price, category} = req.body; 43 | let slug = title.replace(/\s+/g, '-').toLowerCase(); 44 | 45 | const errors = validationResult(req); 46 | if (!errors.isEmpty()) { 47 | var categories = await Category.find({}); 48 | res.render('product/add_page', { 49 | title, desc, price, slug, category, categories, errors: errors.array() 50 | }); 51 | } else { 52 | Product.findOne({'slug': slug}, (err, page) => { 53 | if (page) { 54 | res.flash('danger', 'Product tilte exits , choose another.'); 55 | res.render('product/add_page', {title, desc, price, slug, category, categories}); 56 | 57 | } else { 58 | price = parseFloat(price).toFixed(2); 59 | let sampleFile = req.files.image; 60 | var fileName = uniqid() + ".png"; 61 | sampleFile.mv('public/product_images/' + fileName, function (err) { 62 | if (err) 63 | return res.status(500).send(err); 64 | 65 | var product = new Product({title, desc, price, slug, category, image: fileName}); 66 | product.save(function (err) { 67 | if (err) return console.log(err); 68 | res.flash('success', 'Product Added.'); 69 | res.redirect('/admin/products'); 70 | } 71 | ); 72 | }); 73 | 74 | } 75 | }); 76 | 77 | } 78 | 79 | }, 80 | productUpdateGet: async (req, res) => { 81 | try { 82 | let Dataslug = req.params.slug; 83 | const [product, categories] = await Promise.all([ 84 | Product.findOne({'slug': Dataslug}), 85 | await Category.find({}) 86 | 87 | ]); 88 | let {title, slug, desc, _id, price, category, image} = product; 89 | let location = '/product_images/'; 90 | let galaryImages = []; 91 | 92 | product.similar_image.forEach((value) => { 93 | var nowLoc = location + value.url; 94 | galaryImages.push({url: nowLoc, name: value.url}); 95 | }); 96 | 97 | 98 | res.render('product/edit_page', {title, image, galaryImages, slug, desc, _id, price, category, categories}); 99 | } catch (err) { 100 | res.flash('error', err.message); 101 | res.redirect('/admin/products'); 102 | } 103 | }, 104 | productUpdatePost: async (req, res) => { 105 | var backURL = req.header('Referer') || '/'; 106 | let {title} = req.body; 107 | let slug = title.replace(/\s+/g, '-').toLowerCase(); 108 | let id = req.body.id; 109 | const errors = validationResult(req); 110 | if (!errors.isEmpty()) { 111 | console.log(errors); 112 | // do your thang 113 | res.redirect(backURL); 114 | } else { 115 | try { 116 | 117 | var product = await Product.findOne({slug, _id: {'$ne': id}}); 118 | if (product) { 119 | res.flash('info', 'product slug exits, choose another'); 120 | // do your thang 121 | // console.log(req); 122 | res.redirect('/admin/product'); 123 | } else { 124 | var nowProduct = await Product.findById(id); 125 | nowProduct.title = title; 126 | nowProduct.slug = slug; 127 | await nowProduct.save(); 128 | res.flash('success', 'Product update successfully'); 129 | res.redirect('/admin/product'); 130 | } 131 | 132 | } catch (err) { 133 | res.flash('danger', err.message); 134 | // do your thang 135 | res.redirect(backURL); 136 | } 137 | } 138 | 139 | }, 140 | 141 | productDeletePost: async (req, res) => { 142 | try { 143 | var slug = req.params.slug; 144 | var product = await Product.findOne({slug}); 145 | if (product) { 146 | await product.remove(); 147 | res.json({success: true, message: "product delete successfully"}); 148 | } 149 | } catch (err) { 150 | res.json({success: false, message: "product delete not success"}); 151 | } 152 | }, 153 | 154 | 155 | ProductFileUpload: async (req, res) => { 156 | try { 157 | 158 | var id = req.body.product_id; 159 | var product = await Product.findById(id); 160 | if (product) { 161 | let sampleFile = req.files.file; 162 | var fileName = uniqid() + ".png"; 163 | sampleFile.mv('public/product_images/' + fileName, function (err) { 164 | if (err) 165 | return res.status(500).send(err); 166 | 167 | product.similar_image.push({url: fileName, thumb: fileName}); 168 | product.save(); 169 | res.json({success: true, message: "product image upload success"}); 170 | }); 171 | } 172 | } catch (err) { 173 | res.json({success: false, message: "product delete not success"}); 174 | } 175 | }, 176 | 177 | ProductFileDelete: async (req, res) => { 178 | try { 179 | 180 | var id = req.body.product_id; 181 | var fileName = req.body.filename; 182 | var info = await Product.update({_id: id}, {$pull: {similar_image: {url: fileName}}}); 183 | res.json({success: false, message: info}); 184 | } catch (err) { 185 | res.json({success: false, message: err.message}); 186 | } 187 | } 188 | 189 | 190 | }; 191 | -------------------------------------------------------------------------------- /controllers/productMainController.js: -------------------------------------------------------------------------------- 1 | const {check, validationResult} = require('express-validator/check'); 2 | const {matchedData, sanitize} = require('express-validator/filter'); 3 | const Product = require('../models/product'); 4 | const Category = require('../models/category'); 5 | const fs = require('fs-extra'); 6 | const mkdirp = require('mkdirp'); 7 | const resizeImg = require('resize-img'); 8 | var uniqid = require('uniqid'); 9 | require('express-async-errors'); 10 | 11 | module.exports = { 12 | getAllProduct: async (req, res) => { 13 | 14 | try { 15 | const [count, products] = await Promise.all([ 16 | Product.count(), 17 | Product.find({}) 18 | 19 | ]); 20 | res.render('ProductHome/allproduct', {title:'all products',count, products}); 21 | 22 | } catch (err) { 23 | console.log("some error"); 24 | } 25 | }, 26 | 27 | categoryWiseProduct: async (req, res) => { 28 | try { 29 | var nowSlug = req.params.slug; 30 | const [count, products] = await Promise.all([ 31 | Product.count(), 32 | Product.find({category:nowSlug}) 33 | 34 | ]); 35 | res.render('ProductHome/allproduct', {title:'all products',count, products}); 36 | 37 | } catch (err) { 38 | console.log("some error"); 39 | } 40 | }, 41 | 42 | ProductDetails: async (req, res) => { 43 | try { 44 | var nowSlug = req.params.slug; 45 | var product = await Product.findOne({slug:nowSlug}); 46 | res.render('ProductHome/product_single', {title:'all products',product}); 47 | 48 | } catch (err) { 49 | console.log("some error"); 50 | } 51 | }, 52 | 53 | 54 | 55 | 56 | }; 57 | -------------------------------------------------------------------------------- /models/category.js: -------------------------------------------------------------------------------- 1 | var mongoose = require('mongoose'); 2 | var Schema = mongoose.Schema; 3 | 4 | var CategorySchema = new Schema({ 5 | title: { 6 | type: String, 7 | required: true 8 | }, 9 | slug: { 10 | type: String, 11 | required: true 12 | } 13 | }); 14 | var Category = mongoose.model('Category', CategorySchema); 15 | 16 | // make this available to our users in our Node applications 17 | module.exports = Category; -------------------------------------------------------------------------------- /models/page.js: -------------------------------------------------------------------------------- 1 | var mongoose = require('mongoose'); 2 | var Schema = mongoose.Schema; 3 | 4 | var PageSchema = new Schema({ 5 | title: { 6 | type: String, 7 | required: true 8 | }, 9 | slug: { 10 | type: String, 11 | required: true 12 | }, 13 | content: { 14 | type: String, 15 | required: true 16 | }, 17 | sorting: { 18 | type: Number 19 | } 20 | }); 21 | var Page = mongoose.model('Page', PageSchema); 22 | 23 | // make this available to our users in our Node applications 24 | module.exports = Page; -------------------------------------------------------------------------------- /models/product.js: -------------------------------------------------------------------------------- 1 | var mongoose = require('mongoose'); 2 | var Schema = mongoose.Schema; 3 | 4 | var ProductImageSchema = new Schema({ 5 | url: { 6 | type: String, 7 | required: true 8 | }, 9 | thumb: { 10 | type: String, 11 | required: true 12 | }, 13 | 14 | }); 15 | 16 | var ProductSchema = new Schema({ 17 | title: { 18 | type: String, 19 | required: true 20 | }, 21 | slug: { 22 | type: String, 23 | required: true 24 | }, 25 | desc: { 26 | type: String, 27 | required: true 28 | }, 29 | category: { 30 | type: String, 31 | required: true 32 | }, 33 | price: { 34 | type: Number, 35 | required: true 36 | }, 37 | image: { 38 | type: String 39 | }, 40 | similar_image: { 41 | type: [ProductImageSchema], 42 | 'default': [] 43 | } 44 | }); 45 | var Product = mongoose.model('Product', ProductSchema); 46 | 47 | // make this available to our users in our Node applications 48 | module.exports = Product; -------------------------------------------------------------------------------- /models/product_image.js: -------------------------------------------------------------------------------- 1 | var mongoose = require('mongoose'); 2 | var Schema = mongoose.Schema; 3 | 4 | var ProductImageSchema = new Schema({ 5 | url: { 6 | type: String, 7 | required: true 8 | }, 9 | thumb: { 10 | type: String, 11 | required: true 12 | }, 13 | 14 | }); 15 | var ProductImage = mongoose.model('ProductImage', ProductImageSchema); 16 | 17 | // make this available to our users in our Node applications 18 | module.exports = ProductImage; -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "cmscart", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "app.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1", 8 | "start": "nodemon app.js" 9 | }, 10 | "author": "", 11 | "license": "ISC", 12 | "dependencies": { 13 | "body-parser": "^1.18.2", 14 | "bootstrap3": "^3.3.5", 15 | "connect-flash": "^0.1.1", 16 | "consolidate": "^0.15.0", 17 | "cookie-parser": "^1.4.3", 18 | "express": "^4.16.2", 19 | "express-async-errors": "^2.1.0", 20 | "express-fileupload": "^0.4.0", 21 | "express-flash": "^0.0.2", 22 | "express-flash-2": "^1.0.1", 23 | "express-messages": "^1.0.1", 24 | "express-session": "^1.15.6", 25 | "express-validator": "^4.3.0", 26 | "fs-extra": "^5.0.0", 27 | "jquery": "^3.3.1", 28 | "mkdirp": "^0.5.1", 29 | "mongoose": "^5.0.3", 30 | "nunjucks": "^3.0.1", 31 | "resize-img": "^1.1.2", 32 | "uniqid": "^4.1.1" 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /public/css/bootstrap-theme.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.3.5 (http://getbootstrap.com) 3 | * Copyright 2011-2015 Twitter, Inc. 4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 5 | */ 6 | .btn-default, 7 | .btn-primary, 8 | .btn-success, 9 | .btn-info, 10 | .btn-warning, 11 | .btn-danger { 12 | text-shadow: 0 -1px 0 rgba(0, 0, 0, .2); 13 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075); 14 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075); 15 | } 16 | .btn-default:active, 17 | .btn-primary:active, 18 | .btn-success:active, 19 | .btn-info:active, 20 | .btn-warning:active, 21 | .btn-danger:active, 22 | .btn-default.active, 23 | .btn-primary.active, 24 | .btn-success.active, 25 | .btn-info.active, 26 | .btn-warning.active, 27 | .btn-danger.active { 28 | -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125); 29 | box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125); 30 | } 31 | .btn-default.disabled, 32 | .btn-primary.disabled, 33 | .btn-success.disabled, 34 | .btn-info.disabled, 35 | .btn-warning.disabled, 36 | .btn-danger.disabled, 37 | .btn-default[disabled], 38 | .btn-primary[disabled], 39 | .btn-success[disabled], 40 | .btn-info[disabled], 41 | .btn-warning[disabled], 42 | .btn-danger[disabled], 43 | fieldset[disabled] .btn-default, 44 | fieldset[disabled] .btn-primary, 45 | fieldset[disabled] .btn-success, 46 | fieldset[disabled] .btn-info, 47 | fieldset[disabled] .btn-warning, 48 | fieldset[disabled] .btn-danger { 49 | -webkit-box-shadow: none; 50 | box-shadow: none; 51 | } 52 | .btn-default .badge, 53 | .btn-primary .badge, 54 | .btn-success .badge, 55 | .btn-info .badge, 56 | .btn-warning .badge, 57 | .btn-danger .badge { 58 | text-shadow: none; 59 | } 60 | .btn:active, 61 | .btn.active { 62 | background-image: none; 63 | } 64 | .btn-default { 65 | text-shadow: 0 1px 0 #fff; 66 | background-image: -webkit-linear-gradient(top, #fff 0%, #e0e0e0 100%); 67 | background-image: -o-linear-gradient(top, #fff 0%, #e0e0e0 100%); 68 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#e0e0e0)); 69 | background-image: linear-gradient(to bottom, #fff 0%, #e0e0e0 100%); 70 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0); 71 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 72 | background-repeat: repeat-x; 73 | border-color: #dbdbdb; 74 | border-color: #ccc; 75 | } 76 | .btn-default:hover, 77 | .btn-default:focus { 78 | background-color: #e0e0e0; 79 | background-position: 0 -15px; 80 | } 81 | .btn-default:active, 82 | .btn-default.active { 83 | background-color: #e0e0e0; 84 | border-color: #dbdbdb; 85 | } 86 | .btn-default.disabled, 87 | .btn-default[disabled], 88 | fieldset[disabled] .btn-default, 89 | .btn-default.disabled:hover, 90 | .btn-default[disabled]:hover, 91 | fieldset[disabled] .btn-default:hover, 92 | .btn-default.disabled:focus, 93 | .btn-default[disabled]:focus, 94 | fieldset[disabled] .btn-default:focus, 95 | .btn-default.disabled.focus, 96 | .btn-default[disabled].focus, 97 | fieldset[disabled] .btn-default.focus, 98 | .btn-default.disabled:active, 99 | .btn-default[disabled]:active, 100 | fieldset[disabled] .btn-default:active, 101 | .btn-default.disabled.active, 102 | .btn-default[disabled].active, 103 | fieldset[disabled] .btn-default.active { 104 | background-color: #e0e0e0; 105 | background-image: none; 106 | } 107 | .btn-primary { 108 | background-image: -webkit-linear-gradient(top, #337ab7 0%, #265a88 100%); 109 | background-image: -o-linear-gradient(top, #337ab7 0%, #265a88 100%); 110 | background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#265a88)); 111 | background-image: linear-gradient(to bottom, #337ab7 0%, #265a88 100%); 112 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff265a88', GradientType=0); 113 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 114 | background-repeat: repeat-x; 115 | border-color: #245580; 116 | } 117 | .btn-primary:hover, 118 | .btn-primary:focus { 119 | background-color: #265a88; 120 | background-position: 0 -15px; 121 | } 122 | .btn-primary:active, 123 | .btn-primary.active { 124 | background-color: #265a88; 125 | border-color: #245580; 126 | } 127 | .btn-primary.disabled, 128 | .btn-primary[disabled], 129 | fieldset[disabled] .btn-primary, 130 | .btn-primary.disabled:hover, 131 | .btn-primary[disabled]:hover, 132 | fieldset[disabled] .btn-primary:hover, 133 | .btn-primary.disabled:focus, 134 | .btn-primary[disabled]:focus, 135 | fieldset[disabled] .btn-primary:focus, 136 | .btn-primary.disabled.focus, 137 | .btn-primary[disabled].focus, 138 | fieldset[disabled] .btn-primary.focus, 139 | .btn-primary.disabled:active, 140 | .btn-primary[disabled]:active, 141 | fieldset[disabled] .btn-primary:active, 142 | .btn-primary.disabled.active, 143 | .btn-primary[disabled].active, 144 | fieldset[disabled] .btn-primary.active { 145 | background-color: #265a88; 146 | background-image: none; 147 | } 148 | .btn-success { 149 | background-image: -webkit-linear-gradient(top, #5cb85c 0%, #419641 100%); 150 | background-image: -o-linear-gradient(top, #5cb85c 0%, #419641 100%); 151 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#419641)); 152 | background-image: linear-gradient(to bottom, #5cb85c 0%, #419641 100%); 153 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0); 154 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 155 | background-repeat: repeat-x; 156 | border-color: #3e8f3e; 157 | } 158 | .btn-success:hover, 159 | .btn-success:focus { 160 | background-color: #419641; 161 | background-position: 0 -15px; 162 | } 163 | .btn-success:active, 164 | .btn-success.active { 165 | background-color: #419641; 166 | border-color: #3e8f3e; 167 | } 168 | .btn-success.disabled, 169 | .btn-success[disabled], 170 | fieldset[disabled] .btn-success, 171 | .btn-success.disabled:hover, 172 | .btn-success[disabled]:hover, 173 | fieldset[disabled] .btn-success:hover, 174 | .btn-success.disabled:focus, 175 | .btn-success[disabled]:focus, 176 | fieldset[disabled] .btn-success:focus, 177 | .btn-success.disabled.focus, 178 | .btn-success[disabled].focus, 179 | fieldset[disabled] .btn-success.focus, 180 | .btn-success.disabled:active, 181 | .btn-success[disabled]:active, 182 | fieldset[disabled] .btn-success:active, 183 | .btn-success.disabled.active, 184 | .btn-success[disabled].active, 185 | fieldset[disabled] .btn-success.active { 186 | background-color: #419641; 187 | background-image: none; 188 | } 189 | .btn-info { 190 | background-image: -webkit-linear-gradient(top, #5bc0de 0%, #2aabd2 100%); 191 | background-image: -o-linear-gradient(top, #5bc0de 0%, #2aabd2 100%); 192 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#2aabd2)); 193 | background-image: linear-gradient(to bottom, #5bc0de 0%, #2aabd2 100%); 194 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0); 195 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 196 | background-repeat: repeat-x; 197 | border-color: #28a4c9; 198 | } 199 | .btn-info:hover, 200 | .btn-info:focus { 201 | background-color: #2aabd2; 202 | background-position: 0 -15px; 203 | } 204 | .btn-info:active, 205 | .btn-info.active { 206 | background-color: #2aabd2; 207 | border-color: #28a4c9; 208 | } 209 | .btn-info.disabled, 210 | .btn-info[disabled], 211 | fieldset[disabled] .btn-info, 212 | .btn-info.disabled:hover, 213 | .btn-info[disabled]:hover, 214 | fieldset[disabled] .btn-info:hover, 215 | .btn-info.disabled:focus, 216 | .btn-info[disabled]:focus, 217 | fieldset[disabled] .btn-info:focus, 218 | .btn-info.disabled.focus, 219 | .btn-info[disabled].focus, 220 | fieldset[disabled] .btn-info.focus, 221 | .btn-info.disabled:active, 222 | .btn-info[disabled]:active, 223 | fieldset[disabled] .btn-info:active, 224 | .btn-info.disabled.active, 225 | .btn-info[disabled].active, 226 | fieldset[disabled] .btn-info.active { 227 | background-color: #2aabd2; 228 | background-image: none; 229 | } 230 | .btn-warning { 231 | background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #eb9316 100%); 232 | background-image: -o-linear-gradient(top, #f0ad4e 0%, #eb9316 100%); 233 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#eb9316)); 234 | background-image: linear-gradient(to bottom, #f0ad4e 0%, #eb9316 100%); 235 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0); 236 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 237 | background-repeat: repeat-x; 238 | border-color: #e38d13; 239 | } 240 | .btn-warning:hover, 241 | .btn-warning:focus { 242 | background-color: #eb9316; 243 | background-position: 0 -15px; 244 | } 245 | .btn-warning:active, 246 | .btn-warning.active { 247 | background-color: #eb9316; 248 | border-color: #e38d13; 249 | } 250 | .btn-warning.disabled, 251 | .btn-warning[disabled], 252 | fieldset[disabled] .btn-warning, 253 | .btn-warning.disabled:hover, 254 | .btn-warning[disabled]:hover, 255 | fieldset[disabled] .btn-warning:hover, 256 | .btn-warning.disabled:focus, 257 | .btn-warning[disabled]:focus, 258 | fieldset[disabled] .btn-warning:focus, 259 | .btn-warning.disabled.focus, 260 | .btn-warning[disabled].focus, 261 | fieldset[disabled] .btn-warning.focus, 262 | .btn-warning.disabled:active, 263 | .btn-warning[disabled]:active, 264 | fieldset[disabled] .btn-warning:active, 265 | .btn-warning.disabled.active, 266 | .btn-warning[disabled].active, 267 | fieldset[disabled] .btn-warning.active { 268 | background-color: #eb9316; 269 | background-image: none; 270 | } 271 | .btn-danger { 272 | background-image: -webkit-linear-gradient(top, #d9534f 0%, #c12e2a 100%); 273 | background-image: -o-linear-gradient(top, #d9534f 0%, #c12e2a 100%); 274 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c12e2a)); 275 | background-image: linear-gradient(to bottom, #d9534f 0%, #c12e2a 100%); 276 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0); 277 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 278 | background-repeat: repeat-x; 279 | border-color: #b92c28; 280 | } 281 | .btn-danger:hover, 282 | .btn-danger:focus { 283 | background-color: #c12e2a; 284 | background-position: 0 -15px; 285 | } 286 | .btn-danger:active, 287 | .btn-danger.active { 288 | background-color: #c12e2a; 289 | border-color: #b92c28; 290 | } 291 | .btn-danger.disabled, 292 | .btn-danger[disabled], 293 | fieldset[disabled] .btn-danger, 294 | .btn-danger.disabled:hover, 295 | .btn-danger[disabled]:hover, 296 | fieldset[disabled] .btn-danger:hover, 297 | .btn-danger.disabled:focus, 298 | .btn-danger[disabled]:focus, 299 | fieldset[disabled] .btn-danger:focus, 300 | .btn-danger.disabled.focus, 301 | .btn-danger[disabled].focus, 302 | fieldset[disabled] .btn-danger.focus, 303 | .btn-danger.disabled:active, 304 | .btn-danger[disabled]:active, 305 | fieldset[disabled] .btn-danger:active, 306 | .btn-danger.disabled.active, 307 | .btn-danger[disabled].active, 308 | fieldset[disabled] .btn-danger.active { 309 | background-color: #c12e2a; 310 | background-image: none; 311 | } 312 | .thumbnail, 313 | .img-thumbnail { 314 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075); 315 | box-shadow: 0 1px 2px rgba(0, 0, 0, .075); 316 | } 317 | .dropdown-menu > li > a:hover, 318 | .dropdown-menu > li > a:focus { 319 | background-color: #e8e8e8; 320 | background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 321 | background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 322 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8)); 323 | background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%); 324 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0); 325 | background-repeat: repeat-x; 326 | } 327 | .dropdown-menu > .active > a, 328 | .dropdown-menu > .active > a:hover, 329 | .dropdown-menu > .active > a:focus { 330 | background-color: #2e6da4; 331 | background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%); 332 | background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%); 333 | background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4)); 334 | background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%); 335 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0); 336 | background-repeat: repeat-x; 337 | } 338 | .navbar-default { 339 | background-image: -webkit-linear-gradient(top, #fff 0%, #f8f8f8 100%); 340 | background-image: -o-linear-gradient(top, #fff 0%, #f8f8f8 100%); 341 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fff), to(#f8f8f8)); 342 | background-image: linear-gradient(to bottom, #fff 0%, #f8f8f8 100%); 343 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0); 344 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 345 | background-repeat: repeat-x; 346 | border-radius: 4px; 347 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075); 348 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 5px rgba(0, 0, 0, .075); 349 | } 350 | .navbar-default .navbar-nav > .open > a, 351 | .navbar-default .navbar-nav > .active > a { 352 | background-image: -webkit-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%); 353 | background-image: -o-linear-gradient(top, #dbdbdb 0%, #e2e2e2 100%); 354 | background-image: -webkit-gradient(linear, left top, left bottom, from(#dbdbdb), to(#e2e2e2)); 355 | background-image: linear-gradient(to bottom, #dbdbdb 0%, #e2e2e2 100%); 356 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdbdbdb', endColorstr='#ffe2e2e2', GradientType=0); 357 | background-repeat: repeat-x; 358 | -webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075); 359 | box-shadow: inset 0 3px 9px rgba(0, 0, 0, .075); 360 | } 361 | .navbar-brand, 362 | .navbar-nav > li > a { 363 | text-shadow: 0 1px 0 rgba(255, 255, 255, .25); 364 | } 365 | .navbar-inverse { 366 | background-image: -webkit-linear-gradient(top, #3c3c3c 0%, #222 100%); 367 | background-image: -o-linear-gradient(top, #3c3c3c 0%, #222 100%); 368 | background-image: -webkit-gradient(linear, left top, left bottom, from(#3c3c3c), to(#222)); 369 | background-image: linear-gradient(to bottom, #3c3c3c 0%, #222 100%); 370 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0); 371 | filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); 372 | background-repeat: repeat-x; 373 | border-radius: 4px; 374 | } 375 | .navbar-inverse .navbar-nav > .open > a, 376 | .navbar-inverse .navbar-nav > .active > a { 377 | background-image: -webkit-linear-gradient(top, #080808 0%, #0f0f0f 100%); 378 | background-image: -o-linear-gradient(top, #080808 0%, #0f0f0f 100%); 379 | background-image: -webkit-gradient(linear, left top, left bottom, from(#080808), to(#0f0f0f)); 380 | background-image: linear-gradient(to bottom, #080808 0%, #0f0f0f 100%); 381 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff080808', endColorstr='#ff0f0f0f', GradientType=0); 382 | background-repeat: repeat-x; 383 | -webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25); 384 | box-shadow: inset 0 3px 9px rgba(0, 0, 0, .25); 385 | } 386 | .navbar-inverse .navbar-brand, 387 | .navbar-inverse .navbar-nav > li > a { 388 | text-shadow: 0 -1px 0 rgba(0, 0, 0, .25); 389 | } 390 | .navbar-static-top, 391 | .navbar-fixed-top, 392 | .navbar-fixed-bottom { 393 | border-radius: 0; 394 | } 395 | @media (max-width: 767px) { 396 | .navbar .navbar-nav .open .dropdown-menu > .active > a, 397 | .navbar .navbar-nav .open .dropdown-menu > .active > a:hover, 398 | .navbar .navbar-nav .open .dropdown-menu > .active > a:focus { 399 | color: #fff; 400 | background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%); 401 | background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%); 402 | background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4)); 403 | background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%); 404 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0); 405 | background-repeat: repeat-x; 406 | } 407 | } 408 | .alert { 409 | text-shadow: 0 1px 0 rgba(255, 255, 255, .2); 410 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05); 411 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .05); 412 | } 413 | .alert-success { 414 | background-image: -webkit-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%); 415 | background-image: -o-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%); 416 | background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#c8e5bc)); 417 | background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%); 418 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0); 419 | background-repeat: repeat-x; 420 | border-color: #b2dba1; 421 | } 422 | .alert-info { 423 | background-image: -webkit-linear-gradient(top, #d9edf7 0%, #b9def0 100%); 424 | background-image: -o-linear-gradient(top, #d9edf7 0%, #b9def0 100%); 425 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#b9def0)); 426 | background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%); 427 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0); 428 | background-repeat: repeat-x; 429 | border-color: #9acfea; 430 | } 431 | .alert-warning { 432 | background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%); 433 | background-image: -o-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%); 434 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#f8efc0)); 435 | background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%); 436 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0); 437 | background-repeat: repeat-x; 438 | border-color: #f5e79e; 439 | } 440 | .alert-danger { 441 | background-image: -webkit-linear-gradient(top, #f2dede 0%, #e7c3c3 100%); 442 | background-image: -o-linear-gradient(top, #f2dede 0%, #e7c3c3 100%); 443 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#e7c3c3)); 444 | background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%); 445 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0); 446 | background-repeat: repeat-x; 447 | border-color: #dca7a7; 448 | } 449 | .progress { 450 | background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%); 451 | background-image: -o-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%); 452 | background-image: -webkit-gradient(linear, left top, left bottom, from(#ebebeb), to(#f5f5f5)); 453 | background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%); 454 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0); 455 | background-repeat: repeat-x; 456 | } 457 | .progress-bar { 458 | background-image: -webkit-linear-gradient(top, #337ab7 0%, #286090 100%); 459 | background-image: -o-linear-gradient(top, #337ab7 0%, #286090 100%); 460 | background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#286090)); 461 | background-image: linear-gradient(to bottom, #337ab7 0%, #286090 100%); 462 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff286090', GradientType=0); 463 | background-repeat: repeat-x; 464 | } 465 | .progress-bar-success { 466 | background-image: -webkit-linear-gradient(top, #5cb85c 0%, #449d44 100%); 467 | background-image: -o-linear-gradient(top, #5cb85c 0%, #449d44 100%); 468 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5cb85c), to(#449d44)); 469 | background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%); 470 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0); 471 | background-repeat: repeat-x; 472 | } 473 | .progress-bar-info { 474 | background-image: -webkit-linear-gradient(top, #5bc0de 0%, #31b0d5 100%); 475 | background-image: -o-linear-gradient(top, #5bc0de 0%, #31b0d5 100%); 476 | background-image: -webkit-gradient(linear, left top, left bottom, from(#5bc0de), to(#31b0d5)); 477 | background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%); 478 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0); 479 | background-repeat: repeat-x; 480 | } 481 | .progress-bar-warning { 482 | background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #ec971f 100%); 483 | background-image: -o-linear-gradient(top, #f0ad4e 0%, #ec971f 100%); 484 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f0ad4e), to(#ec971f)); 485 | background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%); 486 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0); 487 | background-repeat: repeat-x; 488 | } 489 | .progress-bar-danger { 490 | background-image: -webkit-linear-gradient(top, #d9534f 0%, #c9302c 100%); 491 | background-image: -o-linear-gradient(top, #d9534f 0%, #c9302c 100%); 492 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9534f), to(#c9302c)); 493 | background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%); 494 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0); 495 | background-repeat: repeat-x; 496 | } 497 | .progress-bar-striped { 498 | background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent); 499 | background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent); 500 | background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent); 501 | } 502 | .list-group { 503 | border-radius: 4px; 504 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .075); 505 | box-shadow: 0 1px 2px rgba(0, 0, 0, .075); 506 | } 507 | .list-group-item.active, 508 | .list-group-item.active:hover, 509 | .list-group-item.active:focus { 510 | text-shadow: 0 -1px 0 #286090; 511 | background-image: -webkit-linear-gradient(top, #337ab7 0%, #2b669a 100%); 512 | background-image: -o-linear-gradient(top, #337ab7 0%, #2b669a 100%); 513 | background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2b669a)); 514 | background-image: linear-gradient(to bottom, #337ab7 0%, #2b669a 100%); 515 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2b669a', GradientType=0); 516 | background-repeat: repeat-x; 517 | border-color: #2b669a; 518 | } 519 | .list-group-item.active .badge, 520 | .list-group-item.active:hover .badge, 521 | .list-group-item.active:focus .badge { 522 | text-shadow: none; 523 | } 524 | .panel { 525 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, .05); 526 | box-shadow: 0 1px 2px rgba(0, 0, 0, .05); 527 | } 528 | .panel-default > .panel-heading { 529 | background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 530 | background-image: -o-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 531 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#e8e8e8)); 532 | background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%); 533 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0); 534 | background-repeat: repeat-x; 535 | } 536 | .panel-primary > .panel-heading { 537 | background-image: -webkit-linear-gradient(top, #337ab7 0%, #2e6da4 100%); 538 | background-image: -o-linear-gradient(top, #337ab7 0%, #2e6da4 100%); 539 | background-image: -webkit-gradient(linear, left top, left bottom, from(#337ab7), to(#2e6da4)); 540 | background-image: linear-gradient(to bottom, #337ab7 0%, #2e6da4 100%); 541 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0); 542 | background-repeat: repeat-x; 543 | } 544 | .panel-success > .panel-heading { 545 | background-image: -webkit-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%); 546 | background-image: -o-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%); 547 | background-image: -webkit-gradient(linear, left top, left bottom, from(#dff0d8), to(#d0e9c6)); 548 | background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%); 549 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0); 550 | background-repeat: repeat-x; 551 | } 552 | .panel-info > .panel-heading { 553 | background-image: -webkit-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%); 554 | background-image: -o-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%); 555 | background-image: -webkit-gradient(linear, left top, left bottom, from(#d9edf7), to(#c4e3f3)); 556 | background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%); 557 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0); 558 | background-repeat: repeat-x; 559 | } 560 | .panel-warning > .panel-heading { 561 | background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%); 562 | background-image: -o-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%); 563 | background-image: -webkit-gradient(linear, left top, left bottom, from(#fcf8e3), to(#faf2cc)); 564 | background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%); 565 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0); 566 | background-repeat: repeat-x; 567 | } 568 | .panel-danger > .panel-heading { 569 | background-image: -webkit-linear-gradient(top, #f2dede 0%, #ebcccc 100%); 570 | background-image: -o-linear-gradient(top, #f2dede 0%, #ebcccc 100%); 571 | background-image: -webkit-gradient(linear, left top, left bottom, from(#f2dede), to(#ebcccc)); 572 | background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%); 573 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0); 574 | background-repeat: repeat-x; 575 | } 576 | .well { 577 | background-image: -webkit-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%); 578 | background-image: -o-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%); 579 | background-image: -webkit-gradient(linear, left top, left bottom, from(#e8e8e8), to(#f5f5f5)); 580 | background-image: linear-gradient(to bottom, #e8e8e8 0%, #f5f5f5 100%); 581 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0); 582 | background-repeat: repeat-x; 583 | border-color: #dcdcdc; 584 | -webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1); 585 | box-shadow: inset 0 1px 3px rgba(0, 0, 0, .05), 0 1px 0 rgba(255, 255, 255, .1); 586 | } 587 | /*# sourceMappingURL=bootstrap-theme.css.map */ 588 | -------------------------------------------------------------------------------- /public/css/bootstrap-theme.min.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.3.5 (http://getbootstrap.com) 3 | * Copyright 2011-2015 Twitter, Inc. 4 | * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) 5 | */.btn-danger,.btn-default,.btn-info,.btn-primary,.btn-success,.btn-warning{text-shadow:0 -1px 0 rgba(0,0,0,.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 1px rgba(0,0,0,.075);box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 1px rgba(0,0,0,.075)}.btn-danger.active,.btn-danger:active,.btn-default.active,.btn-default:active,.btn-info.active,.btn-info:active,.btn-primary.active,.btn-primary:active,.btn-success.active,.btn-success:active,.btn-warning.active,.btn-warning:active{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.btn-danger.disabled,.btn-danger[disabled],.btn-default.disabled,.btn-default[disabled],.btn-info.disabled,.btn-info[disabled],.btn-primary.disabled,.btn-primary[disabled],.btn-success.disabled,.btn-success[disabled],.btn-warning.disabled,.btn-warning[disabled],fieldset[disabled] .btn-danger,fieldset[disabled] .btn-default,fieldset[disabled] .btn-info,fieldset[disabled] .btn-primary,fieldset[disabled] .btn-success,fieldset[disabled] .btn-warning{-webkit-box-shadow:none;box-shadow:none}.btn-danger .badge,.btn-default .badge,.btn-info .badge,.btn-primary .badge,.btn-success .badge,.btn-warning .badge{text-shadow:none}.btn.active,.btn:active{background-image:none}.btn-default{text-shadow:0 1px 0 #fff;background-image:-webkit-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:-o-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fff),to(#e0e0e0));background-image:linear-gradient(to bottom,#fff 0,#e0e0e0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe0e0e0', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#dbdbdb;border-color:#ccc}.btn-default:focus,.btn-default:hover{background-color:#e0e0e0;background-position:0 -15px}.btn-default.active,.btn-default:active{background-color:#e0e0e0;border-color:#dbdbdb}.btn-default.disabled,.btn-default.disabled.active,.btn-default.disabled.focus,.btn-default.disabled:active,.btn-default.disabled:focus,.btn-default.disabled:hover,.btn-default[disabled],.btn-default[disabled].active,.btn-default[disabled].focus,.btn-default[disabled]:active,.btn-default[disabled]:focus,.btn-default[disabled]:hover,fieldset[disabled] .btn-default,fieldset[disabled] .btn-default.active,fieldset[disabled] .btn-default.focus,fieldset[disabled] .btn-default:active,fieldset[disabled] .btn-default:focus,fieldset[disabled] .btn-default:hover{background-color:#e0e0e0;background-image:none}.btn-primary{background-image:-webkit-linear-gradient(top,#337ab7 0,#265a88 100%);background-image:-o-linear-gradient(top,#337ab7 0,#265a88 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#265a88));background-image:linear-gradient(to bottom,#337ab7 0,#265a88 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff265a88', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#245580}.btn-primary:focus,.btn-primary:hover{background-color:#265a88;background-position:0 -15px}.btn-primary.active,.btn-primary:active{background-color:#265a88;border-color:#245580}.btn-primary.disabled,.btn-primary.disabled.active,.btn-primary.disabled.focus,.btn-primary.disabled:active,.btn-primary.disabled:focus,.btn-primary.disabled:hover,.btn-primary[disabled],.btn-primary[disabled].active,.btn-primary[disabled].focus,.btn-primary[disabled]:active,.btn-primary[disabled]:focus,.btn-primary[disabled]:hover,fieldset[disabled] .btn-primary,fieldset[disabled] .btn-primary.active,fieldset[disabled] .btn-primary.focus,fieldset[disabled] .btn-primary:active,fieldset[disabled] .btn-primary:focus,fieldset[disabled] .btn-primary:hover{background-color:#265a88;background-image:none}.btn-success{background-image:-webkit-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:-o-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5cb85c),to(#419641));background-image:linear-gradient(to bottom,#5cb85c 0,#419641 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff419641', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#3e8f3e}.btn-success:focus,.btn-success:hover{background-color:#419641;background-position:0 -15px}.btn-success.active,.btn-success:active{background-color:#419641;border-color:#3e8f3e}.btn-success.disabled,.btn-success.disabled.active,.btn-success.disabled.focus,.btn-success.disabled:active,.btn-success.disabled:focus,.btn-success.disabled:hover,.btn-success[disabled],.btn-success[disabled].active,.btn-success[disabled].focus,.btn-success[disabled]:active,.btn-success[disabled]:focus,.btn-success[disabled]:hover,fieldset[disabled] .btn-success,fieldset[disabled] .btn-success.active,fieldset[disabled] .btn-success.focus,fieldset[disabled] .btn-success:active,fieldset[disabled] .btn-success:focus,fieldset[disabled] .btn-success:hover{background-color:#419641;background-image:none}.btn-info{background-image:-webkit-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:-o-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5bc0de),to(#2aabd2));background-image:linear-gradient(to bottom,#5bc0de 0,#2aabd2 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2aabd2', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#28a4c9}.btn-info:focus,.btn-info:hover{background-color:#2aabd2;background-position:0 -15px}.btn-info.active,.btn-info:active{background-color:#2aabd2;border-color:#28a4c9}.btn-info.disabled,.btn-info.disabled.active,.btn-info.disabled.focus,.btn-info.disabled:active,.btn-info.disabled:focus,.btn-info.disabled:hover,.btn-info[disabled],.btn-info[disabled].active,.btn-info[disabled].focus,.btn-info[disabled]:active,.btn-info[disabled]:focus,.btn-info[disabled]:hover,fieldset[disabled] .btn-info,fieldset[disabled] .btn-info.active,fieldset[disabled] .btn-info.focus,fieldset[disabled] .btn-info:active,fieldset[disabled] .btn-info:focus,fieldset[disabled] .btn-info:hover{background-color:#2aabd2;background-image:none}.btn-warning{background-image:-webkit-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:-o-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f0ad4e),to(#eb9316));background-image:linear-gradient(to bottom,#f0ad4e 0,#eb9316 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffeb9316', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#e38d13}.btn-warning:focus,.btn-warning:hover{background-color:#eb9316;background-position:0 -15px}.btn-warning.active,.btn-warning:active{background-color:#eb9316;border-color:#e38d13}.btn-warning.disabled,.btn-warning.disabled.active,.btn-warning.disabled.focus,.btn-warning.disabled:active,.btn-warning.disabled:focus,.btn-warning.disabled:hover,.btn-warning[disabled],.btn-warning[disabled].active,.btn-warning[disabled].focus,.btn-warning[disabled]:active,.btn-warning[disabled]:focus,.btn-warning[disabled]:hover,fieldset[disabled] .btn-warning,fieldset[disabled] .btn-warning.active,fieldset[disabled] .btn-warning.focus,fieldset[disabled] .btn-warning:active,fieldset[disabled] .btn-warning:focus,fieldset[disabled] .btn-warning:hover{background-color:#eb9316;background-image:none}.btn-danger{background-image:-webkit-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:-o-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9534f),to(#c12e2a));background-image:linear-gradient(to bottom,#d9534f 0,#c12e2a 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc12e2a', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-color:#b92c28}.btn-danger:focus,.btn-danger:hover{background-color:#c12e2a;background-position:0 -15px}.btn-danger.active,.btn-danger:active{background-color:#c12e2a;border-color:#b92c28}.btn-danger.disabled,.btn-danger.disabled.active,.btn-danger.disabled.focus,.btn-danger.disabled:active,.btn-danger.disabled:focus,.btn-danger.disabled:hover,.btn-danger[disabled],.btn-danger[disabled].active,.btn-danger[disabled].focus,.btn-danger[disabled]:active,.btn-danger[disabled]:focus,.btn-danger[disabled]:hover,fieldset[disabled] .btn-danger,fieldset[disabled] .btn-danger.active,fieldset[disabled] .btn-danger.focus,fieldset[disabled] .btn-danger:active,fieldset[disabled] .btn-danger:focus,fieldset[disabled] .btn-danger:hover{background-color:#c12e2a;background-image:none}.img-thumbnail,.thumbnail{-webkit-box-shadow:0 1px 2px rgba(0,0,0,.075);box-shadow:0 1px 2px rgba(0,0,0,.075)}.dropdown-menu>li>a:focus,.dropdown-menu>li>a:hover{background-color:#e8e8e8;background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-o-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f5f5f5),to(#e8e8e8));background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);background-repeat:repeat-x}.dropdown-menu>.active>a,.dropdown-menu>.active>a:focus,.dropdown-menu>.active>a:hover{background-color:#2e6da4;background-image:-webkit-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2e6da4));background-image:linear-gradient(to bottom,#337ab7 0,#2e6da4 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);background-repeat:repeat-x}.navbar-default{background-image:-webkit-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:-o-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fff),to(#f8f8f8));background-image:linear-gradient(to bottom,#fff 0,#f8f8f8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-radius:4px;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 5px rgba(0,0,0,.075);box-shadow:inset 0 1px 0 rgba(255,255,255,.15),0 1px 5px rgba(0,0,0,.075)}.navbar-default .navbar-nav>.active>a,.navbar-default .navbar-nav>.open>a{background-image:-webkit-linear-gradient(top,#dbdbdb 0,#e2e2e2 100%);background-image:-o-linear-gradient(top,#dbdbdb 0,#e2e2e2 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dbdbdb),to(#e2e2e2));background-image:linear-gradient(to bottom,#dbdbdb 0,#e2e2e2 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdbdbdb', endColorstr='#ffe2e2e2', GradientType=0);background-repeat:repeat-x;-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,.075);box-shadow:inset 0 3px 9px rgba(0,0,0,.075)}.navbar-brand,.navbar-nav>li>a{text-shadow:0 1px 0 rgba(255,255,255,.25)}.navbar-inverse{background-image:-webkit-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:-o-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#3c3c3c),to(#222));background-image:linear-gradient(to bottom,#3c3c3c 0,#222 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);background-repeat:repeat-x;border-radius:4px}.navbar-inverse .navbar-nav>.active>a,.navbar-inverse .navbar-nav>.open>a{background-image:-webkit-linear-gradient(top,#080808 0,#0f0f0f 100%);background-image:-o-linear-gradient(top,#080808 0,#0f0f0f 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#080808),to(#0f0f0f));background-image:linear-gradient(to bottom,#080808 0,#0f0f0f 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff080808', endColorstr='#ff0f0f0f', GradientType=0);background-repeat:repeat-x;-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,.25);box-shadow:inset 0 3px 9px rgba(0,0,0,.25)}.navbar-inverse .navbar-brand,.navbar-inverse .navbar-nav>li>a{text-shadow:0 -1px 0 rgba(0,0,0,.25)}.navbar-fixed-bottom,.navbar-fixed-top,.navbar-static-top{border-radius:0}@media (max-width:767px){.navbar .navbar-nav .open .dropdown-menu>.active>a,.navbar .navbar-nav .open .dropdown-menu>.active>a:focus,.navbar .navbar-nav .open .dropdown-menu>.active>a:hover{color:#fff;background-image:-webkit-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2e6da4));background-image:linear-gradient(to bottom,#337ab7 0,#2e6da4 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);background-repeat:repeat-x}}.alert{text-shadow:0 1px 0 rgba(255,255,255,.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 2px rgba(0,0,0,.05);box-shadow:inset 0 1px 0 rgba(255,255,255,.25),0 1px 2px rgba(0,0,0,.05)}.alert-success{background-image:-webkit-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:-o-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dff0d8),to(#c8e5bc));background-image:linear-gradient(to bottom,#dff0d8 0,#c8e5bc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0);background-repeat:repeat-x;border-color:#b2dba1}.alert-info{background-image:-webkit-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:-o-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9edf7),to(#b9def0));background-image:linear-gradient(to bottom,#d9edf7 0,#b9def0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0);background-repeat:repeat-x;border-color:#9acfea}.alert-warning{background-image:-webkit-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:-o-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fcf8e3),to(#f8efc0));background-image:linear-gradient(to bottom,#fcf8e3 0,#f8efc0 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0);background-repeat:repeat-x;border-color:#f5e79e}.alert-danger{background-image:-webkit-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:-o-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f2dede),to(#e7c3c3));background-image:linear-gradient(to bottom,#f2dede 0,#e7c3c3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0);background-repeat:repeat-x;border-color:#dca7a7}.progress{background-image:-webkit-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:-o-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#ebebeb),to(#f5f5f5));background-image:linear-gradient(to bottom,#ebebeb 0,#f5f5f5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0);background-repeat:repeat-x}.progress-bar{background-image:-webkit-linear-gradient(top,#337ab7 0,#286090 100%);background-image:-o-linear-gradient(top,#337ab7 0,#286090 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#286090));background-image:linear-gradient(to bottom,#337ab7 0,#286090 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff286090', GradientType=0);background-repeat:repeat-x}.progress-bar-success{background-image:-webkit-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:-o-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5cb85c),to(#449d44));background-image:linear-gradient(to bottom,#5cb85c 0,#449d44 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0);background-repeat:repeat-x}.progress-bar-info{background-image:-webkit-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:-o-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#5bc0de),to(#31b0d5));background-image:linear-gradient(to bottom,#5bc0de 0,#31b0d5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0);background-repeat:repeat-x}.progress-bar-warning{background-image:-webkit-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:-o-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f0ad4e),to(#ec971f));background-image:linear-gradient(to bottom,#f0ad4e 0,#ec971f 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0);background-repeat:repeat-x}.progress-bar-danger{background-image:-webkit-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:-o-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9534f),to(#c9302c));background-image:linear-gradient(to bottom,#d9534f 0,#c9302c 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0);background-repeat:repeat-x}.progress-bar-striped{background-image:-webkit-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:-o-linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent);background-image:linear-gradient(45deg,rgba(255,255,255,.15) 25%,transparent 25%,transparent 50%,rgba(255,255,255,.15) 50%,rgba(255,255,255,.15) 75%,transparent 75%,transparent)}.list-group{border-radius:4px;-webkit-box-shadow:0 1px 2px rgba(0,0,0,.075);box-shadow:0 1px 2px rgba(0,0,0,.075)}.list-group-item.active,.list-group-item.active:focus,.list-group-item.active:hover{text-shadow:0 -1px 0 #286090;background-image:-webkit-linear-gradient(top,#337ab7 0,#2b669a 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2b669a 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2b669a));background-image:linear-gradient(to bottom,#337ab7 0,#2b669a 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2b669a', GradientType=0);background-repeat:repeat-x;border-color:#2b669a}.list-group-item.active .badge,.list-group-item.active:focus .badge,.list-group-item.active:hover .badge{text-shadow:none}.panel{-webkit-box-shadow:0 1px 2px rgba(0,0,0,.05);box-shadow:0 1px 2px rgba(0,0,0,.05)}.panel-default>.panel-heading{background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-o-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f5f5f5),to(#e8e8e8));background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0);background-repeat:repeat-x}.panel-primary>.panel-heading{background-image:-webkit-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-o-linear-gradient(top,#337ab7 0,#2e6da4 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#337ab7),to(#2e6da4));background-image:linear-gradient(to bottom,#337ab7 0,#2e6da4 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff337ab7', endColorstr='#ff2e6da4', GradientType=0);background-repeat:repeat-x}.panel-success>.panel-heading{background-image:-webkit-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:-o-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#dff0d8),to(#d0e9c6));background-image:linear-gradient(to bottom,#dff0d8 0,#d0e9c6 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);background-repeat:repeat-x}.panel-info>.panel-heading{background-image:-webkit-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-o-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9edf7),to(#c4e3f3));background-image:linear-gradient(to bottom,#d9edf7 0,#c4e3f3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);background-repeat:repeat-x}.panel-warning>.panel-heading{background-image:-webkit-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-o-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fcf8e3),to(#faf2cc));background-image:linear-gradient(to bottom,#fcf8e3 0,#faf2cc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);background-repeat:repeat-x}.panel-danger>.panel-heading{background-image:-webkit-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-o-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f2dede),to(#ebcccc));background-image:linear-gradient(to bottom,#f2dede 0,#ebcccc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);background-repeat:repeat-x}.well{background-image:-webkit-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-o-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#e8e8e8),to(#f5f5f5));background-image:linear-gradient(to bottom,#e8e8e8 0,#f5f5f5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);background-repeat:repeat-x;border-color:#dcdcdc;-webkit-box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1)} -------------------------------------------------------------------------------- /public/css/style.css: -------------------------------------------------------------------------------- 1 | body { 2 | padding-top: 50px; 3 | } -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /public/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /public/images/1.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/images/1.PNG -------------------------------------------------------------------------------- /public/images/2.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/images/2.PNG -------------------------------------------------------------------------------- /public/images/3.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/images/3.PNG -------------------------------------------------------------------------------- /public/images/4.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/images/4.PNG -------------------------------------------------------------------------------- /public/images/5.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/images/5.PNG -------------------------------------------------------------------------------- /public/images/6.PNG: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/images/6.PNG -------------------------------------------------------------------------------- /public/images/noimage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/images/noimage.png -------------------------------------------------------------------------------- /public/js/bootstrap.min.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.3.5 (http://getbootstrap.com) 3 | * Copyright 2011-2015 Twitter, Inc. 4 | * Licensed under the MIT license 5 | */ 6 | if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");+function(a){"use strict";var b=a.fn.jquery.split(" ")[0].split(".");if(b[0]<2&&b[1]<9||1==b[0]&&9==b[1]&&b[2]<1)throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher")}(jQuery),+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]};return!1}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one("bsTransitionEnd",function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b(),a.support.transition&&(a.event.special.bsTransitionEnd={bindType:a.support.transition.end,delegateType:a.support.transition.end,handle:function(b){return a(b.target).is(this)?b.handleObj.handler.apply(this,arguments):void 0}})})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var c=a(this),e=c.data("bs.alert");e||c.data("bs.alert",e=new d(this)),"string"==typeof b&&e[b].call(c)})}var c='[data-dismiss="alert"]',d=function(b){a(b).on("click",c,this.close)};d.VERSION="3.3.5",d.TRANSITION_DURATION=150,d.prototype.close=function(b){function c(){g.detach().trigger("closed.bs.alert").remove()}var e=a(this),f=e.attr("data-target");f||(f=e.attr("href"),f=f&&f.replace(/.*(?=#[^\s]*$)/,""));var g=a(f);b&&b.preventDefault(),g.length||(g=e.closest(".alert")),g.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(g.removeClass("in"),a.support.transition&&g.hasClass("fade")?g.one("bsTransitionEnd",c).emulateTransitionEnd(d.TRANSITION_DURATION):c())};var e=a.fn.alert;a.fn.alert=b,a.fn.alert.Constructor=d,a.fn.alert.noConflict=function(){return a.fn.alert=e,this},a(document).on("click.bs.alert.data-api",c,d.prototype.close)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof b&&b;e||d.data("bs.button",e=new c(this,f)),"toggle"==b?e.toggle():b&&e.setState(b)})}var c=function(b,d){this.$element=a(b),this.options=a.extend({},c.DEFAULTS,d),this.isLoading=!1};c.VERSION="3.3.5",c.DEFAULTS={loadingText:"loading..."},c.prototype.setState=function(b){var c="disabled",d=this.$element,e=d.is("input")?"val":"html",f=d.data();b+="Text",null==f.resetText&&d.data("resetText",d[e]()),setTimeout(a.proxy(function(){d[e](null==f[b]?this.options[b]:f[b]),"loadingText"==b?(this.isLoading=!0,d.addClass(c).attr(c,c)):this.isLoading&&(this.isLoading=!1,d.removeClass(c).removeAttr(c))},this),0)},c.prototype.toggle=function(){var a=!0,b=this.$element.closest('[data-toggle="buttons"]');if(b.length){var c=this.$element.find("input");"radio"==c.prop("type")?(c.prop("checked")&&(a=!1),b.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==c.prop("type")&&(c.prop("checked")!==this.$element.hasClass("active")&&(a=!1),this.$element.toggleClass("active")),c.prop("checked",this.$element.hasClass("active")),a&&c.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var d=a.fn.button;a.fn.button=b,a.fn.button.Constructor=c,a.fn.button.noConflict=function(){return a.fn.button=d,this},a(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(c){var d=a(c.target);d.hasClass("btn")||(d=d.closest(".btn")),b.call(d,"toggle"),a(c.target).is('input[type="radio"]')||a(c.target).is('input[type="checkbox"]')||c.preventDefault()}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(b){a(b.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(b.type))})}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},c.DEFAULTS,d.data(),"object"==typeof b&&b),g="string"==typeof b?b:f.slide;e||d.data("bs.carousel",e=new c(this,f)),"number"==typeof b?e.to(b):g?e[g]():f.interval&&e.pause().cycle()})}var c=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",a.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",a.proxy(this.pause,this)).on("mouseleave.bs.carousel",a.proxy(this.cycle,this))};c.VERSION="3.3.5",c.TRANSITION_DURATION=600,c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},c.prototype.keydown=function(a){if(!/input|textarea/i.test(a.target.tagName)){switch(a.which){case 37:this.prev();break;case 39:this.next();break;default:return}a.preventDefault()}},c.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(a){return this.$items=a.parent().children(".item"),this.$items.index(a||this.$active)},c.prototype.getItemForDirection=function(a,b){var c=this.getItemIndex(b),d="prev"==a&&0===c||"next"==a&&c==this.$items.length-1;if(d&&!this.options.wrap)return b;var e="prev"==a?-1:1,f=(c+e)%this.$items.length;return this.$items.eq(f)},c.prototype.to=function(a){var b=this,c=this.getItemIndex(this.$active=this.$element.find(".item.active"));return a>this.$items.length-1||0>a?void 0:this.sliding?this.$element.one("slid.bs.carousel",function(){b.to(a)}):c==a?this.pause().cycle():this.slide(a>c?"next":"prev",this.$items.eq(a))},c.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){return this.sliding?void 0:this.slide("next")},c.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},c.prototype.slide=function(b,d){var e=this.$element.find(".item.active"),f=d||this.getItemForDirection(b,e),g=this.interval,h="next"==b?"left":"right",i=this;if(f.hasClass("active"))return this.sliding=!1;var j=f[0],k=a.Event("slide.bs.carousel",{relatedTarget:j,direction:h});if(this.$element.trigger(k),!k.isDefaultPrevented()){if(this.sliding=!0,g&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var l=a(this.$indicators.children()[this.getItemIndex(f)]);l&&l.addClass("active")}var m=a.Event("slid.bs.carousel",{relatedTarget:j,direction:h});return a.support.transition&&this.$element.hasClass("slide")?(f.addClass(b),f[0].offsetWidth,e.addClass(h),f.addClass(h),e.one("bsTransitionEnd",function(){f.removeClass([b,h].join(" ")).addClass("active"),e.removeClass(["active",h].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger(m)},0)}).emulateTransitionEnd(c.TRANSITION_DURATION)):(e.removeClass("active"),f.addClass("active"),this.sliding=!1,this.$element.trigger(m)),g&&this.cycle(),this}};var d=a.fn.carousel;a.fn.carousel=b,a.fn.carousel.Constructor=c,a.fn.carousel.noConflict=function(){return a.fn.carousel=d,this};var e=function(c){var d,e=a(this),f=a(e.attr("data-target")||(d=e.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""));if(f.hasClass("carousel")){var g=a.extend({},f.data(),e.data()),h=e.attr("data-slide-to");h&&(g.interval=!1),b.call(f,g),h&&f.data("bs.carousel").to(h),c.preventDefault()}};a(document).on("click.bs.carousel.data-api","[data-slide]",e).on("click.bs.carousel.data-api","[data-slide-to]",e),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var c=a(this);b.call(c,c.data())})})}(jQuery),+function(a){"use strict";function b(b){var c,d=b.attr("data-target")||(c=b.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"");return a(d)}function c(b){return this.each(function(){var c=a(this),e=c.data("bs.collapse"),f=a.extend({},d.DEFAULTS,c.data(),"object"==typeof b&&b);!e&&f.toggle&&/show|hide/.test(b)&&(f.toggle=!1),e||c.data("bs.collapse",e=new d(this,f)),"string"==typeof b&&e[b]()})}var d=function(b,c){this.$element=a(b),this.options=a.extend({},d.DEFAULTS,c),this.$trigger=a('[data-toggle="collapse"][href="#'+b.id+'"],[data-toggle="collapse"][data-target="#'+b.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};d.VERSION="3.3.5",d.TRANSITION_DURATION=350,d.DEFAULTS={toggle:!0},d.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},d.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b,e=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing");if(!(e&&e.length&&(b=e.data("bs.collapse"),b&&b.transitioning))){var f=a.Event("show.bs.collapse");if(this.$element.trigger(f),!f.isDefaultPrevented()){e&&e.length&&(c.call(e,"hide"),b||e.data("bs.collapse",null));var g=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[g](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var h=function(){this.$element.removeClass("collapsing").addClass("collapse in")[g](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return h.call(this);var i=a.camelCase(["scroll",g].join("-"));this.$element.one("bsTransitionEnd",a.proxy(h,this)).emulateTransitionEnd(d.TRANSITION_DURATION)[g](this.$element[0][i])}}}},d.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var e=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};return a.support.transition?void this.$element[c](0).one("bsTransitionEnd",a.proxy(e,this)).emulateTransitionEnd(d.TRANSITION_DURATION):e.call(this)}}},d.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},d.prototype.getParent=function(){return a(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(a.proxy(function(c,d){var e=a(d);this.addAriaAndCollapsedClass(b(e),e)},this)).end()},d.prototype.addAriaAndCollapsedClass=function(a,b){var c=a.hasClass("in");a.attr("aria-expanded",c),b.toggleClass("collapsed",!c).attr("aria-expanded",c)};var e=a.fn.collapse;a.fn.collapse=c,a.fn.collapse.Constructor=d,a.fn.collapse.noConflict=function(){return a.fn.collapse=e,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(d){var e=a(this);e.attr("data-target")||d.preventDefault();var f=b(e),g=f.data("bs.collapse"),h=g?"toggle":e.data();c.call(f,h)})}(jQuery),+function(a){"use strict";function b(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#[A-Za-z]/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}function c(c){c&&3===c.which||(a(e).remove(),a(f).each(function(){var d=a(this),e=b(d),f={relatedTarget:this};e.hasClass("open")&&(c&&"click"==c.type&&/input|textarea/i.test(c.target.tagName)&&a.contains(e[0],c.target)||(e.trigger(c=a.Event("hide.bs.dropdown",f)),c.isDefaultPrevented()||(d.attr("aria-expanded","false"),e.removeClass("open").trigger("hidden.bs.dropdown",f))))}))}function d(b){return this.each(function(){var c=a(this),d=c.data("bs.dropdown");d||c.data("bs.dropdown",d=new g(this)),"string"==typeof b&&d[b].call(c)})}var e=".dropdown-backdrop",f='[data-toggle="dropdown"]',g=function(b){a(b).on("click.bs.dropdown",this.toggle)};g.VERSION="3.3.5",g.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=b(e),g=f.hasClass("open");if(c(),!g){"ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(a(this)).on("click",c);var h={relatedTarget:this};if(f.trigger(d=a.Event("show.bs.dropdown",h)),d.isDefaultPrevented())return;e.trigger("focus").attr("aria-expanded","true"),f.toggleClass("open").trigger("shown.bs.dropdown",h)}return!1}},g.prototype.keydown=function(c){if(/(38|40|27|32)/.test(c.which)&&!/input|textarea/i.test(c.target.tagName)){var d=a(this);if(c.preventDefault(),c.stopPropagation(),!d.is(".disabled, :disabled")){var e=b(d),g=e.hasClass("open");if(!g&&27!=c.which||g&&27==c.which)return 27==c.which&&e.find(f).trigger("focus"),d.trigger("click");var h=" li:not(.disabled):visible a",i=e.find(".dropdown-menu"+h);if(i.length){var j=i.index(c.target);38==c.which&&j>0&&j--,40==c.which&&jdocument.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&a?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!a?this.scrollbarWidth:""})},c.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},c.prototype.checkScrollbar=function(){var a=window.innerWidth;if(!a){var b=document.documentElement.getBoundingClientRect();a=b.right-Math.abs(b.left)}this.bodyIsOverflowing=document.body.clientWidth
',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0}},c.prototype.init=function(b,c,d){if(this.enabled=!0,this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.$viewport=this.options.viewport&&a(a.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var e=this.options.trigger.split(" "),f=e.length;f--;){var g=e[f];if("click"==g)this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this));else if("manual"!=g){var h="hover"==g?"mouseenter":"focusin",i="hover"==g?"mouseleave":"focusout";this.$element.on(h+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(i+"."+this.type,this.options.selector,a.proxy(this.leave,this))}}this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.getOptions=function(b){return b=a.extend({},this.getDefaults(),this.$element.data(),b),b.delay&&"number"==typeof b.delay&&(b.delay={show:b.delay,hide:b.delay}),b},c.prototype.getDelegateOptions=function(){var b={},c=this.getDefaults();return this._options&&a.each(this._options,function(a,d){c[a]!=d&&(b[a]=d)}),b},c.prototype.enter=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusin"==b.type?"focus":"hover"]=!0),c.tip().hasClass("in")||"in"==c.hoverState?void(c.hoverState="in"):(clearTimeout(c.timeout),c.hoverState="in",c.options.delay&&c.options.delay.show?void(c.timeout=setTimeout(function(){"in"==c.hoverState&&c.show()},c.options.delay.show)):c.show())},c.prototype.isInStateTrue=function(){for(var a in this.inState)if(this.inState[a])return!0;return!1},c.prototype.leave=function(b){var c=b instanceof this.constructor?b:a(b.currentTarget).data("bs."+this.type);return c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c)),b instanceof a.Event&&(c.inState["focusout"==b.type?"focus":"hover"]=!1),c.isInStateTrue()?void 0:(clearTimeout(c.timeout),c.hoverState="out",c.options.delay&&c.options.delay.hide?void(c.timeout=setTimeout(function(){"out"==c.hoverState&&c.hide()},c.options.delay.hide)):c.hide())},c.prototype.show=function(){var b=a.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(b);var d=a.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(b.isDefaultPrevented()||!d)return;var e=this,f=this.tip(),g=this.getUID(this.type);this.setContent(),f.attr("id",g),this.$element.attr("aria-describedby",g),this.options.animation&&f.addClass("fade");var h="function"==typeof this.options.placement?this.options.placement.call(this,f[0],this.$element[0]):this.options.placement,i=/\s?auto?\s?/i,j=i.test(h);j&&(h=h.replace(i,"")||"top"),f.detach().css({top:0,left:0,display:"block"}).addClass(h).data("bs."+this.type,this),this.options.container?f.appendTo(this.options.container):f.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var k=this.getPosition(),l=f[0].offsetWidth,m=f[0].offsetHeight;if(j){var n=h,o=this.getPosition(this.$viewport);h="bottom"==h&&k.bottom+m>o.bottom?"top":"top"==h&&k.top-mo.width?"left":"left"==h&&k.left-lg.top+g.height&&(e.top=g.top+g.height-i)}else{var j=b.left-f,k=b.left+f+c;jg.right&&(e.left=g.left+g.width-k)}return e},c.prototype.getTitle=function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||("function"==typeof c.title?c.title.call(b[0]):c.title)},c.prototype.getUID=function(a){do a+=~~(1e6*Math.random());while(document.getElementById(a));return a},c.prototype.tip=function(){if(!this.$tip&&(this.$tip=a(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},c.prototype.enable=function(){this.enabled=!0},c.prototype.disable=function(){this.enabled=!1},c.prototype.toggleEnabled=function(){this.enabled=!this.enabled},c.prototype.toggle=function(b){var c=this;b&&(c=a(b.currentTarget).data("bs."+this.type),c||(c=new this.constructor(b.currentTarget,this.getDelegateOptions()),a(b.currentTarget).data("bs."+this.type,c))),b?(c.inState.click=!c.inState.click,c.isInStateTrue()?c.enter(c):c.leave(c)):c.tip().hasClass("in")?c.leave(c):c.enter(c)},c.prototype.destroy=function(){var a=this;clearTimeout(this.timeout),this.hide(function(){a.$element.off("."+a.type).removeData("bs."+a.type),a.$tip&&a.$tip.detach(),a.$tip=null,a.$arrow=null,a.$viewport=null})};var d=a.fn.tooltip;a.fn.tooltip=b,a.fn.tooltip.Constructor=c,a.fn.tooltip.noConflict=function(){return a.fn.tooltip=d,this}}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof b&&b;(e||!/destroy|hide/.test(b))&&(e||d.data("bs.popover",e=new c(this,f)),"string"==typeof b&&e[b]())})}var c=function(a,b){this.init("popover",a,b)};if(!a.fn.tooltip)throw new Error("Popover requires tooltip.js");c.VERSION="3.3.5",c.DEFAULTS=a.extend({},a.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:''}),c.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),c.prototype.constructor=c,c.prototype.getDefaults=function(){return c.DEFAULTS},c.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content").children().detach().end()[this.options.html?"string"==typeof c?"html":"append":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},c.prototype.hasContent=function(){return this.getTitle()||this.getContent()},c.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},c.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var d=a.fn.popover;a.fn.popover=b,a.fn.popover.Constructor=c,a.fn.popover.noConflict=function(){return a.fn.popover=d,this}}(jQuery),+function(a){"use strict";function b(c,d){this.$body=a(document.body),this.$scrollElement=a(a(c).is(document.body)?window:c),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",a.proxy(this.process,this)),this.refresh(),this.process()}function c(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})}b.VERSION="3.3.5",b.DEFAULTS={offset:10},b.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},b.prototype.refresh=function(){var b=this,c="offset",d=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),a.isWindow(this.$scrollElement[0])||(c="position",d=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var b=a(this),e=b.data("target")||b.attr("href"),f=/^#./.test(e)&&a(e);return f&&f.length&&f.is(":visible")&&[[f[c]().top+d,e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){b.offsets.push(this[0]),b.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.getScrollHeight(),d=this.options.offset+c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(this.scrollHeight!=c&&this.refresh(),b>=d)return g!=(a=f[f.length-1])&&this.activate(a);if(g&&b=e[a]&&(void 0===e[a+1]||b .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),b.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),h?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu").length&&b.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),e&&e()}var g=d.find("> .active"),h=e&&a.support.transition&&(g.length&&g.hasClass("fade")||!!d.find("> .fade").length);g.length&&h?g.one("bsTransitionEnd",f).emulateTransitionEnd(c.TRANSITION_DURATION):f(),g.removeClass("in")};var d=a.fn.tab;a.fn.tab=b,a.fn.tab.Constructor=c,a.fn.tab.noConflict=function(){return a.fn.tab=d,this};var e=function(c){c.preventDefault(),b.call(a(this),"show")};a(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',e).on("click.bs.tab.data-api",'[data-toggle="pill"]',e)}(jQuery),+function(a){"use strict";function b(b){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof b&&b;e||d.data("bs.affix",e=new c(this,f)),"string"==typeof b&&e[b]()})}var c=function(b,d){this.options=a.extend({},c.DEFAULTS,d),this.$target=a(this.options.target).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(b),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};c.VERSION="3.3.5",c.RESET="affix affix-top affix-bottom",c.DEFAULTS={offset:0,target:window},c.prototype.getState=function(a,b,c,d){var e=this.$target.scrollTop(),f=this.$element.offset(),g=this.$target.height();if(null!=c&&"top"==this.affixed)return c>e?"top":!1;if("bottom"==this.affixed)return null!=c?e+this.unpin<=f.top?!1:"bottom":a-d>=e+g?!1:"bottom";var h=null==this.affixed,i=h?e:f.top,j=h?g:b;return null!=c&&c>=e?"top":null!=d&&i+j>=a-d?"bottom":!1},c.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(c.RESET).addClass("affix");var a=this.$target.scrollTop(),b=this.$element.offset();return this.pinnedOffset=b.top-a},c.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},c.prototype.checkPosition=function(){if(this.$element.is(":visible")){var b=this.$element.height(),d=this.options.offset,e=d.top,f=d.bottom,g=Math.max(a(document).height(),a(document.body).height());"object"!=typeof d&&(f=e=d),"function"==typeof e&&(e=d.top(this.$element)),"function"==typeof f&&(f=d.bottom(this.$element));var h=this.getState(g,b,e,f);if(this.affixed!=h){null!=this.unpin&&this.$element.css("top","");var i="affix"+(h?"-"+h:""),j=a.Event(i+".bs.affix");if(this.$element.trigger(j),j.isDefaultPrevented())return;this.affixed=h,this.unpin="bottom"==h?this.getPinnedOffset():null,this.$element.removeClass(c.RESET).addClass(i).trigger(i.replace("affix","affixed")+".bs.affix")}"bottom"==h&&this.$element.offset({top:g-b-f})}};var d=a.fn.affix;a.fn.affix=b,a.fn.affix.Constructor=c,a.fn.affix.noConflict=function(){return a.fn.affix=d,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var c=a(this),d=c.data();d.offset=d.offset||{},null!=d.offsetBottom&&(d.offset.bottom=d.offsetBottom),null!=d.offsetTop&&(d.offset.top=d.offsetTop),b.call(c,d)})})}(jQuery); -------------------------------------------------------------------------------- /public/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdroz9d8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdroz9d8.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdroz9d9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdroz9d9.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdroza5f.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdroza5f.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdroza5g.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdroza5g.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdroza70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdroza70.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrozaxj.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrozaxj.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrozbps.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrozbps.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrozbr6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrozbr6.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby3x.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby3y.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby3y.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby3z.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby3z.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby41.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby41.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby42.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby42.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby43.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby43.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby7v.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby7v.png -------------------------------------------------------------------------------- /public/product_images/vwzfg1i8jdrpby7x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg1i8jdrpby7x.png -------------------------------------------------------------------------------- /public/product_images/vwzfg6dkjdkozxkl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg6dkjdkozxkl.png -------------------------------------------------------------------------------- /public/product_images/vwzfg6f4jdphlwdf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg6f4jdphlwdf.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwnwv3d.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwnwv3d.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwnxe1u.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwnxe1u.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwnxyr3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwnxyr3.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwnygie.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwnygie.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwnywi6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwnywi6.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwnziph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwnziph.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwnzw2a.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwnzw2a.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwo0kf5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwo0kf5.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwo1309.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwo1309.png -------------------------------------------------------------------------------- /public/product_images/vwzfg7eojdwo1lix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/tapos007/eCommerce-node-js/c24207f1f757c0bacde218d43485563ba76eaf0f/public/product_images/vwzfg7eojdwo1lix.png -------------------------------------------------------------------------------- /routes/admin_categories.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | const { check, validationResult } = require('express-validator/check'); 4 | const { matchedData, sanitize } = require('express-validator/filter'); 5 | const CategoryController = require('../controllers/categoryController'); 6 | 7 | // show all categories 8 | router.get('/', CategoryController.getAllCategory); 9 | 10 | // insert a new category get request 11 | router.get('/add-category', CategoryController.categoryCreateGet); 12 | 13 | 14 | // insert a new category post request 15 | 16 | router.post('/add-category',[ 17 | check('title').isLength({ min: 1 }).trim().withMessage('Title must have a value.'), 18 | ], CategoryController.categoryCreatePost); 19 | 20 | 21 | 22 | // update a new category get request 23 | 24 | 25 | router.get('/edit-category/:slug',CategoryController.categoryUpdateGet); 26 | 27 | 28 | // update a new category post request 29 | router.post('/update-category',[ 30 | check('title').isLength({ min: 1 }).trim().withMessage('Title must have a value.'), 31 | ], CategoryController.categoryUpdatePost); 32 | 33 | // delete category 34 | 35 | router.delete('/delete-category/:slug',CategoryController.categoryDeletePost); 36 | 37 | module.exports = router; -------------------------------------------------------------------------------- /routes/admin_pages.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | var PageController = require('../controllers/pageController'); 4 | const {check, validationResult} = require('express-validator/check'); 5 | const {matchedData, sanitize} = require('express-validator/filter'); 6 | 7 | // show all pages 8 | router.get('/', PageController.getAllPage); 9 | 10 | // insert a new page get request 11 | router.get('/add-page', PageController.pageCreateGet); 12 | 13 | // insert a new page post request 14 | 15 | router.post('/add-page', [ 16 | check('title').isLength({min: 1}).trim().withMessage('Title must have a value.'), 17 | check('content').isLength({min: 1}).trim().withMessage('Content must have a value.') 18 | ], PageController.pageCreatePost); 19 | 20 | // update a new page get request 21 | 22 | router.get('/edit-page/:slug', PageController.pageUpdateGet); 23 | 24 | 25 | // update a new page post request 26 | 27 | router.post('/update-page', [ 28 | check('title').isLength({min: 1}).trim().withMessage('Title must have a value.'), 29 | check('content').isLength({min: 1}).trim().withMessage('Content must have a value.') 30 | 31 | ], PageController.pageUpdatePost); 32 | 33 | // delete page 34 | 35 | router.delete('/delete-page/:slug', PageController.pageDeletePost); 36 | 37 | // reorder page 38 | 39 | router.post('/reorder-page', PageController.pageReorderPost); 40 | module.exports = router; -------------------------------------------------------------------------------- /routes/admin_products.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | const {check, validationResult} = require('express-validator/check'); 4 | const {matchedData, sanitize} = require('express-validator/filter'); 5 | const ProductController = require('../controllers/productController'); 6 | var path = require("path"); 7 | 8 | // show all categories 9 | router.get('/', ProductController.getAllProduct); 10 | 11 | // insert a new product get request 12 | router.get('/add-product', ProductController.productCreateGet); 13 | 14 | 15 | // insert a new product post request 16 | 17 | router.post('/add-product', [ 18 | check('title').isLength({min: 1}).trim().withMessage('Title must have a value.'), 19 | check('desc').isLength({min: 1}).trim().withMessage('Desc must have a value.'), 20 | check('price').isDecimal().withMessage('Price must have a value.'), 21 | check('category').isLength({min: 1}).trim().withMessage('Category must have a value.'), 22 | check('image', 'Please upload an image Jpeg, Png') 23 | .custom((value, {req}) => { 24 | if(!(req.files.hasOwnProperty('image'))){ 25 | return false; 26 | } 27 | var extension = (path.extname(req.files.image.name)).toLowerCase(); 28 | console.log(extension); 29 | switch (extension) { 30 | case '.jpg': 31 | return '.jpg'; 32 | case '.jpeg': 33 | return '.jpeg'; 34 | case '.png': 35 | return '.png'; 36 | default: 37 | return false; 38 | } 39 | }) 40 | ], ProductController.productCreatePost); 41 | 42 | 43 | // update a new product get request 44 | 45 | 46 | router.get('/edit-product/:slug', ProductController.productUpdateGet); 47 | 48 | 49 | // update a new product post request 50 | router.post('/update-product', [ 51 | check('title').isLength({min: 1}).trim().withMessage('Title must have a value.'), 52 | ], ProductController.productUpdatePost); 53 | 54 | // delete product 55 | 56 | router.delete('/delete-product/:slug', ProductController.productDeletePost); 57 | 58 | router.post('/file-upload',ProductController.ProductFileUpload); 59 | router.post('/delete-file',ProductController.ProductFileDelete); 60 | 61 | module.exports = router; -------------------------------------------------------------------------------- /routes/cartRoute.js: -------------------------------------------------------------------------------- 1 | var express = require('express') 2 | var router = express.Router(); 3 | var CartController = require('../controllers/CartController'); 4 | const {check, validationResult} = require('express-validator/check'); 5 | const {matchedData, sanitize} = require('express-validator/filter'); 6 | 7 | 8 | // define the home page route 9 | router.get('/', CartController.ShowCartPage); 10 | 11 | 12 | router.get('/add-product/:slug', CartController.AddPRoductCart); 13 | 14 | router.post('/update-cart',CartController.CartPageProductUpdate); 15 | router.post('/delete-cart',CartController.CartPageProductDelete); 16 | 17 | module.exports = router; -------------------------------------------------------------------------------- /routes/pages.js: -------------------------------------------------------------------------------- 1 | var express = require('express') 2 | var router = express.Router(); 3 | var PageController = require('../controllers/pageController'); 4 | const {check, validationResult} = require('express-validator/check'); 5 | const {matchedData, sanitize} = require('express-validator/filter'); 6 | 7 | 8 | // define the home page route 9 | router.get('/', PageController.pageSinglePostHome); 10 | 11 | 12 | router.get('/:slug', PageController.pageSinglePost); 13 | // define the about route 14 | 15 | module.exports = router; -------------------------------------------------------------------------------- /routes/products_route.js: -------------------------------------------------------------------------------- 1 | var express = require('express'); 2 | var router = express.Router(); 3 | const {check, validationResult} = require('express-validator/check'); 4 | const {matchedData, sanitize} = require('express-validator/filter'); 5 | const ProductController = require('../controllers/productMainController'); 6 | var path = require("path"); 7 | 8 | // show all categories 9 | router.get('/', ProductController.getAllProduct); 10 | 11 | // insert a new product get request 12 | router.get('/category/:slug', ProductController.categoryWiseProduct); 13 | router.get('/:slug', ProductController.ProductDetails); 14 | 15 | 16 | // insert a new product post request 17 | 18 | 19 | module.exports = router; -------------------------------------------------------------------------------- /views/ProductHome/allproduct.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

{{title}}

6 | 7 |
8 | 9 | {% for aProduct in products %} 10 |
11 |
12 | ... 13 |
14 |

{{aProduct.title}}

15 |

{{aProduct.desc | safe}}

16 |

Price: ${{aProduct.price}}

17 |

Details

18 |
19 |
20 |
21 | {% else %} 22 |
  • This would display if the 'item' collection were empty
  • 23 | {% endfor %} 24 | 25 |
    26 | 27 | {% endblock %} 28 | -------------------------------------------------------------------------------- /views/ProductHome/product_single.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/master.html" %} 2 | 3 | {% block main_block %} 4 | 5 | 6 | 7 | 8 |
    9 |
    10 |
    11 |
    12 | 13 |
    14 | {% for item in product.similar_image %} 15 | {% if loop.index==1 %} 16 |
    17 | {% else %} 18 |
    19 | {% endif %} 20 | {% endfor %} 21 | 22 |
    23 | 33 | 34 |
    35 |
    36 |

    {{product.title}}

    37 |

    {{product.desc | safe}}

    38 |

    current price: ${{product.price}}

    39 | 40 |
    41 | add to cart 42 | 43 |
    44 |
    45 |
    46 |
    47 |
    48 | 49 | 50 | {% endblock %} 51 | 52 | {% block css_block %} 53 | 54 | 55 | 216 | 217 | {% endblock %} 218 | -------------------------------------------------------------------------------- /views/admin/add_page.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Add a page

    6 | 7 | Back to all pages 8 |

    9 | 10 |
    11 |
    12 | 13 | 14 |
    15 |
    16 | 17 | 18 |
    19 |
    20 | 21 | 22 |
    23 | 24 |
    25 | {% endblock %} 26 | 27 | 28 | {% block js_block %} 29 | 30 | 35 | {% endblock %} 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /views/admin/edit_page.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Edit a page

    6 | 7 | Back to all pages 8 |

    9 | 10 |
    11 |
    12 | 13 | 14 | 15 |
    16 |
    17 | 18 | 19 |
    20 |
    21 | 22 | 23 |
    24 | 25 |
    26 | {% endblock %} 27 | 28 | 29 | {% block js_block %} 30 | 31 | 36 | {% endblock %} -------------------------------------------------------------------------------- /views/admin/pages.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Pages

    6 | 7 | Add a new page 8 |

    9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | {% for page in pages %} 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | {% else %} 29 | 30 | {% endfor %} 31 | 32 | 33 |
    TitleSlugEditDelete
    {{page.title}}{{page.slug}}EditDelete
    This would display if the 'item' collection were empty
    34 | {% endblock %} 35 | 36 | 37 | {% block js_block %} 38 | 39 | 40 | 82 | {% endblock %} 83 | 84 | 85 | {% block css_block %} 86 | 87 | 93 | 94 | {% endblock %} 95 | 96 | -------------------------------------------------------------------------------- /views/cart/cartindex.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/cartmaster.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    {{title}}

    6 | 7 |
    8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | {% set total = 0 %} 21 | {% for aCart in cart %} 22 | {% set total = total + (aCart.price * aCart.qty) %} 23 | 24 | 33 | 34 | 37 | 38 | 42 | 43 | 44 | {% endfor %} 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 |
    ProductPriceQuantitySubtotal
    25 |
    26 | 27 |
    28 |

    {{aCart.title}}

    29 |

    {{aCart.desc|safe}}

    30 |
    31 |
    32 |
    ${{aCart.price}} 35 | 36 | {{aCart.qty * aCart.price}} 39 | 40 | 41 |
    Total {{total}}
    Continue ShoppingCheckout
    59 | 60 |
    61 | 62 | {% endblock %} 63 | 64 | {% block css_block %} 65 | 66 | 102 | {% endblock %} 103 | 104 | {% block js_block %} 105 | 148 | 149 | {% endblock %} -------------------------------------------------------------------------------- /views/category/add_page.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Add a new Category

    6 | 7 | Back to all categories 8 |

    9 | 10 |
    11 |
    12 | 13 | 14 |
    15 |
    16 | 17 | 18 |
    19 | 20 |
    21 | {% endblock %} 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /views/category/edit_page.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Edit a category

    6 | 7 | Back to all category 8 |

    9 | 10 |
    11 |
    12 | 13 | 14 | 15 |
    16 |
    17 | 18 | 19 |
    20 | 21 |
    22 | {% endblock %} 23 | 24 | 25 | {% block js_block %} 26 | 27 | 32 | {% endblock %} -------------------------------------------------------------------------------- /views/category/pages.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Category

    6 | 7 | Add a new category 8 |

    9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | {% for category in categories %} 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | {% else %} 29 | 30 | {% endfor %} 31 | 32 | 33 |
    TitleSlugEditDelete
    {{category.title}}{{category.slug}}EditDelete
    This would display if the 'item' collection were empty
    34 | {% endblock %} 35 | 36 | 37 | {% block js_block %} 38 | 39 | 40 | 74 | {% endblock %} 75 | 76 | 77 | {% block css_block %} 78 | 79 | 85 | 86 | {% endblock %} 87 | 88 | -------------------------------------------------------------------------------- /views/index.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    {{title}}

    6 | 7 |
    8 | {{content | safe}} 9 |
    10 | 11 | {% endblock %} 12 | -------------------------------------------------------------------------------- /views/layouts/admin_master.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | Admin Area 13 | 14 | 15 | 16 | 17 | {% block css_block %}{% endblock %} 18 | 19 | 20 | 21 | 22 | 23 | 44 | 45 |
    46 | {% include "messages.html" %} 47 |
    48 |
    49 | {% if errors %} 50 | {% for error in errors %} 51 | 54 | {% endfor %} 55 | {% endif %} 56 |
    57 |
    58 | {% block main_block %}{% endblock %} 59 |
    60 |


    61 | 62 |
    63 |

    © CmsShoppingCart

    64 | 65 | 66 | 67 | {% block js_block %}{% endblock %} 68 | 69 | 70 | -------------------------------------------------------------------------------- /views/layouts/cartmaster.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | {{title}} 13 | 14 | 15 | 16 | 17 | {% block css_block %}{% endblock %} 18 | 19 | 20 | 21 | 22 | 23 | 60 | 61 |
    62 | 63 | {% include "messages.html" %} 64 |
    65 | 66 |
    67 | {% block main_block %}{% endblock %} 68 |
    69 |
    70 | 71 |
    72 | 73 |


    74 | 75 |
    76 |

    © CmsShoppingCart

    77 | 78 | 79 | {% block js_block %}{% endblock %} 80 | 81 | 82 | -------------------------------------------------------------------------------- /views/layouts/master.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | {{title}} 13 | 14 | 15 | 16 | 17 | {% block css_block %}{% endblock %} 18 | 19 | 20 | 21 | 22 | 23 | 60 | 61 |
    62 | 63 | {% include "messages.html" %} 64 |
    65 |
    66 |

    Categories

    67 | 73 |
    74 |
    75 | {% block main_block %}{% endblock %} 76 |
    77 |
    78 | 79 |
    80 | 81 |


    82 | 83 |
    84 |

    © CmsShoppingCart

    85 | 86 | 87 | {% block js_block %}{% endblock %} 88 | 89 | 90 | -------------------------------------------------------------------------------- /views/messages.html: -------------------------------------------------------------------------------- 1 |
    2 |
    3 | {% for key, value in flash %} 4 | 9 | {% endfor %} 10 | 11 |
    12 |
    13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /views/product/add_page.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Add a new Product

    6 | 7 | Back to all products 8 |

    9 | 10 |
    11 |
    12 | 13 | 14 |
    15 |
    16 | 17 | 18 |
    19 |
    20 | 21 | 27 |
    28 |
    29 | 30 | 31 | 32 |
    33 |
    34 | 35 | 36 |
    37 | 38 | 39 |
    40 | {% endblock %} 41 | 42 | 43 | {% block js_block %} 44 | 45 | 67 | {% endblock %} 68 | 69 | {% block css_block %} 70 | 77 | 78 | {% endblock %} 79 | 80 | 81 | 82 | 83 | -------------------------------------------------------------------------------- /views/product/edit_page.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Edit a Product

    6 | 7 | Back to all products 8 |

    9 | 10 |
    11 |
    12 | 13 | 14 | 15 | 16 | 17 |
    18 |
    19 | 20 | 21 |
    22 |
    23 | 24 | 35 |
    36 |
    37 | 38 |

    39 | {% if image === "" %} 40 | 41 | {% else %} 42 | 43 | {% endif %} 44 |

    45 |
    46 |
    47 | 48 | 49 | 50 |
    51 |
    52 | 53 | 55 |
    56 | 57 |
    58 | 59 |
    60 | 61 |
    62 | 63 |
    64 | 65 | 66 | 67 | Add files... 68 | 69 | 73 | 77 |
    78 | 79 |
    80 | 81 | 82 |
    84 |
    85 |
    86 |
    87 |
    88 | 89 |
    90 | 91 | 92 |
    93 | 94 |
    95 | 96 |
    97 | 98 |
    99 |
    100 |

    101 | 102 |
    103 |
    104 |

    105 |
    107 |
    108 |
    109 |
    110 |
    111 | 115 | 119 | 123 |
    124 |
    125 | 126 |
    127 | {% endblock %} 128 | 129 | 130 | {% block js_block %} 131 | 132 | 133 | 218 | {% endblock %} 219 | 220 | 221 | {% block css_block %} 222 | 229 | 288 | 289 | {% endblock %} -------------------------------------------------------------------------------- /views/product/pages.html: -------------------------------------------------------------------------------- 1 | {% extends "layouts/admin_master.html" %} 2 | 3 | {% block main_block %} 4 | 5 |

    Product

    6 | 7 | Add a new Product 8 |

    9 | {% if count == 0 %} 10 |
    11 | no product found 12 |
    13 | 14 | {% else %} 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | {% for product in products %} 29 | 30 | 31 | 32 | 33 | 40 | 41 | 43 | 44 | 45 | {% else %} 46 | 47 | 48 | 49 | {% endfor %} 50 | 51 | 52 |
    ProductPriceCategoryProduct ImageEditDelete
    {{product.title}}{{product.price}}{{product.category}} 34 | {% if product.image == "" %} 35 | 36 | {% else %} 37 | 38 | {% endif %} 39 | EditDelete 42 |
    This would display if the 'item' collection were empty
    53 | {% endif %} 54 | {% endblock %} 55 | 56 | 57 | {% block js_block %} 58 | 59 | 60 | 94 | {% endblock %} 95 | 96 | 97 | {% block css_block %} 98 | 99 | 105 | 106 | {% endblock %} 107 | 108 | --------------------------------------------------------------------------------