{{title}}
9 |Looks like you got a 404.
10 |├── .bowerrc
├── .gitignore
├── LICENSE
├── Makefile
├── README.md
├── assets.js
├── bin
├── configure.js
├── start.js
└── stop.js
├── example-nginx-vhost
├── gulpfile.js
├── package.json
├── public
├── Theme
│ ├── .DS_Store
│ ├── assets
│ │ ├── .DS_Store
│ │ ├── css
│ │ │ ├── .DS_Store
│ │ │ ├── bootstrap.css
│ │ │ ├── style-responsive.css
│ │ │ ├── style.css
│ │ │ ├── table-responsive.css
│ │ │ ├── to-do.css
│ │ │ └── zabuto_calendar.css
│ │ ├── font-awesome
│ │ │ ├── .DS_Store
│ │ │ ├── css
│ │ │ │ ├── .DS_Store
│ │ │ │ └── font-awesome.css
│ │ │ └── fonts
│ │ │ │ ├── .DS_Store
│ │ │ │ ├── FontAwesome.otf
│ │ │ │ ├── fontawesome-webfont.eot
│ │ │ │ ├── fontawesome-webfont.svg
│ │ │ │ ├── fontawesome-webfont.ttf
│ │ │ │ └── fontawesome-webfont.woff
│ │ ├── fonts
│ │ │ ├── .DS_Store
│ │ │ ├── glyphicons-halflings-regular.eot
│ │ │ ├── glyphicons-halflings-regular.svg
│ │ │ ├── glyphicons-halflings-regular.ttf
│ │ │ └── glyphicons-halflings-regular.woff
│ │ ├── img
│ │ │ ├── .DS_Store
│ │ │ ├── blog-bg.jpg
│ │ │ ├── checkbox-gray.png
│ │ │ ├── friends
│ │ │ │ ├── .DS_Store
│ │ │ │ ├── fr-01.jpg
│ │ │ │ ├── fr-02.jpg
│ │ │ │ ├── fr-03.jpg
│ │ │ │ ├── fr-04.jpg
│ │ │ │ ├── fr-05.jpg
│ │ │ │ ├── fr-06.jpg
│ │ │ │ ├── fr-07.jpg
│ │ │ │ ├── fr-08.jpg
│ │ │ │ ├── fr-09.jpg
│ │ │ │ ├── fr-10.jpg
│ │ │ │ └── fr-11.jpg
│ │ │ ├── instagram.jpg
│ │ │ ├── login-bg.jpg
│ │ │ ├── lorde.jpg
│ │ │ ├── mask.png
│ │ │ ├── ny.jpg
│ │ │ ├── portfolio
│ │ │ │ ├── .DS_Store
│ │ │ │ ├── port01.jpg
│ │ │ │ ├── port02.jpg
│ │ │ │ ├── port03.jpg
│ │ │ │ ├── port04.jpg
│ │ │ │ ├── port05.jpg
│ │ │ │ └── port06.jpg
│ │ │ ├── product.jpg
│ │ │ ├── product.png
│ │ │ ├── profile-01.jpg
│ │ │ ├── profile-02.jpg
│ │ │ ├── radio-gray.png
│ │ │ ├── ui-danro.jpg
│ │ │ ├── ui-divya.jpg
│ │ │ ├── ui-sam.jpg
│ │ │ ├── ui-sherman.jpg
│ │ │ ├── ui-zac.jpg
│ │ │ ├── weather.jpg
│ │ │ └── zoom.png
│ │ ├── js
│ │ │ ├── .DS_Store
│ │ │ ├── bootstrap-inputmask
│ │ │ │ ├── .DS_Store
│ │ │ │ └── bootstrap-inputmask.min.js
│ │ │ ├── bootstrap-switch.js
│ │ │ ├── bootstrap.min.js
│ │ │ ├── calendar-conf-events.js
│ │ │ ├── chart-master
│ │ │ │ ├── .DS_Store
│ │ │ │ └── Chart.js
│ │ │ ├── chartjs-conf.js
│ │ │ ├── common-scripts.js
│ │ │ ├── easy-pie-chart.js
│ │ │ ├── fancybox
│ │ │ │ ├── .DS_Store
│ │ │ │ ├── jquery.fancybox.css
│ │ │ │ └── jquery.fancybox.js
│ │ │ ├── form-component.js
│ │ │ ├── fullcalendar
│ │ │ │ ├── .DS_Store
│ │ │ │ ├── bootstrap-fullcalendar.css
│ │ │ │ └── fullcalendar.min.js
│ │ │ ├── gritter-conf.js
│ │ │ ├── gritter
│ │ │ │ ├── .DS_Store
│ │ │ │ ├── css
│ │ │ │ │ ├── .DS_Store
│ │ │ │ │ ├── jquery.gritter.css
│ │ │ │ │ └── jquery.gritter0.css
│ │ │ │ ├── images
│ │ │ │ │ ├── .DS_Store
│ │ │ │ │ ├── gritter-light.png
│ │ │ │ │ ├── gritter-long.png
│ │ │ │ │ ├── gritter.png
│ │ │ │ │ └── ie-spacer.gif
│ │ │ │ └── js
│ │ │ │ │ ├── .DS_Store
│ │ │ │ │ └── jquery.gritter.js
│ │ │ ├── jquery-1.8.3.min.js
│ │ │ ├── jquery-easy-pie-chart
│ │ │ │ ├── .DS_Store
│ │ │ │ ├── jquery.easy-pie-chart.css
│ │ │ │ └── jquery.easy-pie-chart.js
│ │ │ ├── jquery-ui-1.9.2.custom.min.js
│ │ │ ├── jquery.backstretch.min.js
│ │ │ ├── jquery.dcjqaccordion.2.7.js
│ │ │ ├── jquery.js
│ │ │ ├── jquery.nicescroll.js
│ │ │ ├── jquery.scrollTo.min.js
│ │ │ ├── jquery.sparkline.js
│ │ │ ├── jquery.tagsinput.js
│ │ │ ├── jquery.ui.touch-punch.min.js
│ │ │ ├── morris-conf.js
│ │ │ ├── sparkline-chart.js
│ │ │ ├── tasks.js
│ │ │ └── zabuto_calendar.js
│ │ └── lineicons
│ │ │ ├── .DS_Store
│ │ │ ├── fonts
│ │ │ ├── .DS_Store
│ │ │ ├── linecons.eot
│ │ │ ├── linecons.svg
│ │ │ ├── linecons.ttf
│ │ │ └── linecons.woff
│ │ │ ├── index.html
│ │ │ ├── lte-ie7.js
│ │ │ └── style.css
│ ├── basic_table.html
│ ├── blank.html
│ ├── buttons.html
│ ├── calendar.html
│ ├── chartjs.html
│ ├── form_component.html
│ ├── gallery.html
│ ├── general.html
│ ├── index.html
│ ├── lock_screen.html
│ ├── login.html
│ ├── morris.html
│ ├── panels.html
│ ├── responsive_table.html
│ └── todo_list.html
├── bower_components
│ └── .gitkeep
├── css
│ ├── bootstrap.css
│ ├── datepicker.css
│ ├── font-awesome
│ │ ├── .DS_Store
│ │ ├── css
│ │ │ ├── .DS_Store
│ │ │ └── font-awesome.css
│ │ └── fonts
│ │ │ ├── .DS_Store
│ │ │ ├── FontAwesome.otf
│ │ │ ├── fontawesome-webfont.eot
│ │ │ ├── fontawesome-webfont.svg
│ │ │ ├── fontawesome-webfont.ttf
│ │ │ └── fontawesome-webfont.woff
│ ├── lineicons
│ │ ├── .DS_Store
│ │ ├── fonts
│ │ │ ├── .DS_Store
│ │ │ ├── linecons.eot
│ │ │ ├── linecons.svg
│ │ │ ├── linecons.ttf
│ │ │ └── linecons.woff
│ │ ├── index.html
│ │ ├── lte-ie7.js
│ │ └── style.css
│ ├── notify.css
│ ├── style-responsive.css
│ ├── style.css
│ ├── table-responsive.css
│ ├── to-do.css
│ └── zabuto_calendar.css
├── fonts
│ ├── .DS_Store
│ ├── glyphicons-halflings-regular.eot
│ ├── glyphicons-halflings-regular.svg
│ ├── glyphicons-halflings-regular.ttf
│ └── glyphicons-halflings-regular.woff
├── img
│ ├── .gitkeep
│ ├── blog-bg.jpg
│ ├── checkbox-gray.png
│ ├── friends
│ │ ├── .DS_Store
│ │ ├── fr-01.jpg
│ │ ├── fr-02.jpg
│ │ ├── fr-03.jpg
│ │ ├── fr-04.jpg
│ │ ├── fr-05.jpg
│ │ ├── fr-06.jpg
│ │ ├── fr-07.jpg
│ │ ├── fr-08.jpg
│ │ ├── fr-09.jpg
│ │ ├── fr-10.jpg
│ │ └── fr-11.jpg
│ ├── instagram.jpg
│ ├── login-bg.jpg
│ ├── lorde.jpg
│ ├── mask.png
│ ├── ny.jpg
│ ├── portfolio
│ │ ├── .DS_Store
│ │ ├── port01.jpg
│ │ ├── port02.jpg
│ │ ├── port03.jpg
│ │ ├── port04.jpg
│ │ ├── port05.jpg
│ │ └── port06.jpg
│ ├── process_start.png
│ ├── product.jpg
│ ├── product.png
│ ├── profile-01.jpg
│ ├── profile-02.jpg
│ ├── radio-gray.png
│ ├── ui-danro.jpg
│ ├── ui-divya.jpg
│ ├── ui-sam.jpg
│ ├── ui-sherman.jpg
│ ├── ui-zac.jpg
│ ├── weather.jpg
│ └── zoom.png
└── js
│ ├── .gitkeep
│ ├── auth.js
│ ├── bootstrap-datepicker.js
│ ├── bootstrap-inputmask
│ ├── .DS_Store
│ └── bootstrap-inputmask.min.js
│ ├── bootstrap-switch.js
│ ├── bootstrap.min.js
│ ├── calendar-conf-events.js
│ ├── chart-master
│ ├── .DS_Store
│ └── Chart.js
│ ├── chartjs-conf.js
│ ├── chat.js
│ ├── common-scripts.js
│ ├── easy-pie-chart.js
│ ├── fancybox2
│ ├── blank.gif
│ ├── fancybox_loading.gif
│ ├── fancybox_loading@2x.gif
│ ├── fancybox_overlay.png
│ ├── fancybox_sprite.png
│ ├── fancybox_sprite@2x.png
│ ├── helpers
│ │ ├── fancybox_buttons.png
│ │ ├── jquery.fancybox-buttons.css
│ │ ├── jquery.fancybox-buttons.js
│ │ ├── jquery.fancybox-media.js
│ │ ├── jquery.fancybox-thumbs.css
│ │ └── jquery.fancybox-thumbs.js
│ ├── jquery.fancybox.css
│ ├── jquery.fancybox.js
│ └── jquery.fancybox.pack.js
│ ├── form-component.js
│ ├── fullcalendar
│ ├── .DS_Store
│ ├── bootstrap-fullcalendar.css
│ └── fullcalendar.min.js
│ ├── gritter-conf.js
│ ├── gritter
│ ├── .DS_Store
│ ├── css
│ │ ├── .DS_Store
│ │ ├── jquery.gritter.css
│ │ └── jquery.gritter0.css
│ ├── images
│ │ ├── .DS_Store
│ │ ├── gritter-light.png
│ │ ├── gritter-long.png
│ │ ├── gritter.png
│ │ └── ie-spacer.gif
│ └── js
│ │ ├── .DS_Store
│ │ └── jquery.gritter.js
│ ├── jquery-1.8.3.min.js
│ ├── jquery-easy-pie-chart
│ ├── .DS_Store
│ ├── jquery.easy-pie-chart.css
│ └── jquery.easy-pie-chart.js
│ ├── jquery-ui-1.9.2.custom.min.js
│ ├── jquery.backstretch.min.js
│ ├── jquery.dcjqaccordion.2.7.js
│ ├── jquery.js
│ ├── jquery.nicescroll.js
│ ├── jquery.notify.js
│ ├── jquery.scrollTo.min.js
│ ├── jquery.sparkline.js
│ ├── jquery.tagsinput.js
│ ├── jquery.ui.touch-punch.min.js
│ ├── morris-conf.js
│ ├── socket.io.js
│ ├── sparkline-chart.js
│ ├── tasks.js
│ ├── watable
│ ├── demo.watable.js
│ ├── index.html
│ ├── jquery.watable.js
│ └── watable.css
│ └── zabuto_calendar.js
├── servers
├── api
│ ├── User
│ │ ├── index.js
│ │ └── package.json
│ ├── package.json
│ └── server.js
└── gui
│ ├── auth
│ ├── index.js
│ └── package.json
│ ├── config
│ ├── plugins.js
│ ├── routes.js
│ └── settings.js
│ ├── controllers
│ ├── assets.js
│ └── base.js
│ ├── models
│ └── .gitkeep
│ ├── server.js
│ ├── socketIO
│ ├── index.html
│ └── index.js
│ └── views
│ ├── 404.html
│ ├── about.html
│ ├── basic-table.html
│ ├── blank.html
│ ├── buttons.html
│ ├── calendar.html
│ ├── chartjs.html
│ ├── chat.html
│ ├── form-components.html
│ ├── gallery.html
│ ├── general.html
│ ├── includes
│ ├── foot.html
│ └── head.html
│ ├── index.html
│ ├── layouts
│ ├── auth.html
│ └── default.html
│ ├── lock-screen.html
│ ├── login.html
│ ├── morris.html
│ ├── panels.html
│ ├── partials
│ ├── basic-table.html
│ ├── footer.html
│ ├── sidebar.html
│ └── topbar.html
│ ├── register.html
│ ├── reset.html
│ ├── template.html
│ ├── to-do.html
│ └── watable.html
└── tmp
└── logs
└── .gitignore
/.bowerrc:
--------------------------------------------------------------------------------
1 | {
2 | "directory": "public/bower_components"
3 | }
4 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | lib-cov
2 | *.seed
3 | *.log
4 | *.csv
5 | *.dat
6 | *.out
7 | *.pid
8 | *.gz
9 |
10 | pids
11 | results
12 | npm-debug.log
13 | config.js
14 | config.old.js
15 | node_modules
16 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | The MIT License (MIT)
2 |
3 | Copyright (c) 2013 Simon Maxwell-Stewart
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy of
6 | this software and associated documentation files (the "Software"), to deal in
7 | the Software without restriction, including without limitation the rights to
8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9 | the Software, and to permit persons to whom the Software is furnished to do so,
10 | subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21 |
--------------------------------------------------------------------------------
/Makefile:
--------------------------------------------------------------------------------
1 | test:
2 | @node node_modules/lab/bin/lab
3 | test-cov:
4 | @node node_modules/lab/bin/lab -t 100
5 | test-cov-html:
6 | @node node_modules/lab/bin/lab -r html -o coverage.html
7 | .PHONY: test test-cov test-cov-html
8 |
--------------------------------------------------------------------------------
/assets.js:
--------------------------------------------------------------------------------
1 | // assets to be used by the 'hapi-assets' module based on process.env.NODE_ENV
2 | module.exports = {
3 | development: {
4 | js: ['js/jquery.js',
5 | 'js/bootstrap.min.js',
6 | 'js/jquery-ui-1.9.2.custom.min.js',
7 | 'js/bootstrap-datepicker.js',
8 | 'js/fullcalendar/fullcalendar.min.js',
9 | 'js/jquery.ui.touch-punch.min.js',
10 | 'js/jquery.dcjqaccordion.2.7.js',
11 | 'js/jquery.scrollTo.min.js',
12 | 'js/jquery.nicescroll.js',
13 | 'js/jquery.notify.js',
14 | 'js/common-scripts.js'
15 | ],
16 | css: ['css/bootstrap.css',
17 | 'css/font-awesome/css/font-awesome.css',
18 | 'css/datepicker.css',
19 | 'css/notify.css',
20 | 'js/fullcalendar/bootstrap-fullcalendar.css',
21 | 'css/style.css',
22 | 'css/style-responsive.css',
23 | 'css/to-do.css'
24 | ]
25 | },
26 | production: {
27 | js: ['js/scripts.js'],
28 | css: ['css/styles.css']
29 | }
30 | }
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/bin/start.js:
--------------------------------------------------------------------------------
1 | var exec = require('child_process').exec;
2 | var config = require('../config')
3 |
4 | // This is where we launch all of our different servers.
5 | // They are on different processes so scaling parts of our web app is more manageable
6 | // and crashing errors only bring down their local server, not the whole app!
7 |
8 | // Basic procedure is
9 | // 1. stop existing processes started by this script
10 | // 2. start processes
11 | // 3.
12 |
13 |
14 |
15 | // Start up function
16 | var start = function() {
17 | var startApi = exec('pm2 start '+__dirname+'/../servers/api/server.js --watch --name "'+config.app.name+' API" -e tmp/logs/api-err.log -o tmp/logs/api.log -f -x',
18 | function(err, stdout, stderr) {
19 | if (err) return console.log(err)
20 | }
21 | );
22 | var startGui = exec('pm2 start '+__dirname+'/../servers/gui/server.js --watch --name "'+config.app.name+' GUI" -e tmp/logs/gui-err.log -o tmp/logs/gui.log -f -x',
23 | function(err, stdout, stderr) {
24 | if (err) return console.log(err)
25 | }
26 | );
27 | var startedApi = false;
28 | var startedGui = false;
29 |
30 | startApi.on('close', function (data) {
31 | startedApi = true;
32 | if(startedGui && startedApi) {
33 | list()
34 | }
35 | });
36 |
37 | startGui.on('close', function (data) {
38 | startedGui = true;
39 | if(startedGui && startedApi) {
40 | list()
41 | }
42 | });
43 |
44 | }
45 |
46 | // Display all our processes
47 | var list = function() {
48 | var processes = exec('pm2 list', function(err, stdout, stderr) {
49 | if (err) return console.log(err)
50 | });
51 |
52 | processes.stdout.on('data', function (data) {
53 | console.log(data);
54 | })
55 | }
56 |
57 | start();
58 |
--------------------------------------------------------------------------------
/bin/stop.js:
--------------------------------------------------------------------------------
1 | var exec = require('child_process').exec;
2 | var config = require('../config')
3 |
4 | var stopApi = exec('pm2 stop "'+config.app.name+' API"', function(err, stdout, stderr) {
5 | if (err) return console.error(err)
6 | });
7 | var stopGui = exec('pm2 stop "'+config.app.name+' GUI"', function(err, stdout, stderr) {
8 | if (err) return console.error(err)
9 | });
10 | var stoppedApi = false;
11 | var stoppedGui = false;
12 |
13 | // Event handelrs for stop executions
14 | stopApi.on('close', function (data) {
15 | stoppedApi = true;
16 |
17 | if(stoppedApi && stoppedGui) {
18 | list()
19 | }
20 | });
21 |
22 | stopGui.on('close', function (data) {
23 | stoppedGui = true;
24 | if(stoppedApi && stoppedGui) {
25 | list()
26 | }
27 | });
28 |
29 | // Display all our processes
30 | var list = function() {
31 | var processes = exec('pm2 list', function(err, stdout, stderr) {
32 | if (err) return console.log(err)
33 | });
34 |
35 | processes.stdout.on('data', function (data) {
36 | console.log(data);
37 | })
38 | }
--------------------------------------------------------------------------------
/example-nginx-vhost:
--------------------------------------------------------------------------------
1 | upstream gui {
2 | server 0.0.0.0:3030;
3 | keepalive 64;
4 | }
5 | upstream hApi {
6 | server 127.0.0.1:3000;
7 | keepalive 64;
8 | }
9 |
10 | server {
11 | listen 80;
12 |
13 | server_name localhost;
14 |
15 | error_page 400 404 500 502 503 504 /50x.html;
16 | location /50x.html {
17 | internal;
18 | root /usr/share/nginx/www;
19 | }
20 |
21 | # Serve frontend files
22 | location ~ ^/(landingPage/|images/|img/|javascript/|js/|css/|stylesheets/|flash/|media/|static/|robots.txt|humans.txt|favicon.ico|home/|html|xml|pdf) {
23 | root /va/rwww/mediaScanner/public;
24 | access_log off;
25 | expires 0m;
26 | }
27 |
28 |
29 | # Open up the api. This location limiting to specifc routes
30 | location ~ ^/(api) {
31 | proxy_redirect off;
32 | proxy_set_header X-Real-IP $remote_addr;
33 | proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
34 | proxy_set_header X-Forwarded-Proto $scheme;
35 | proxy_set_header Host $http_host;
36 | proxy_set_header X-NginX-Proxy true;
37 | proxy_set_header Connection "";
38 | proxy_http_version 1.1;
39 | proxy_pass http://hApi;
40 | proxy_intercept_errors off;
41 | }
42 |
43 | location / {
44 | proxy_redirect off;
45 | proxy_set_header X-Real-IP $remote_addr;
46 | proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
47 | proxy_set_header X-Forwarded-Proto $scheme;
48 | proxy_set_header Host $http_host;
49 | proxy_set_header X-NginX-Proxy true;
50 | proxy_set_header Connection "";
51 | proxy_http_version 1.1;
52 | proxy_pass http://gui;
53 | proxy_intercept_errors off;
54 | }
55 |
56 |
57 |
58 |
59 | }
60 |
61 |
62 |
--------------------------------------------------------------------------------
/gulpfile.js:
--------------------------------------------------------------------------------
1 | /**
2 | * Dependencies.
3 | */
4 | var gulp = require("gulp"),
5 | util = require('gulp-util'),
6 | concat = require('gulp-concat'),
7 | minifycss = require('gulp-minify-css'),
8 | uglify = require('gulp-uglify'),
9 | imagemin = require('gulp-imagemin');
10 |
11 | // assets is where you define your application assets and you can pass them into gulp.
12 | var assets = require('./assets');
13 |
14 | // change the working directory to the public folder, where your assets are located.
15 | var gulpFileCwd = __dirname +'/public';
16 | process.chdir(gulpFileCwd);
17 | // print the working directory
18 | util.log('Working directory changed to', util.colors.magenta(gulpFileCwd));
19 |
20 | // the default task that is run with the command 'gulp'
21 | gulp.task('default', function(){
22 |
23 | // concat and minify your css
24 | gulp.src(assets.development.css)
25 | .pipe(concat("styles.css"))
26 | .pipe(minifycss())
27 | .pipe(gulp.dest('./css/'));
28 |
29 | // concat and minify your js
30 | gulp.src(assets.development.js)
31 | .pipe(concat("scripts.js"))
32 | .pipe(uglify())
33 | .pipe(gulp.dest('./js/'));
34 |
35 | // optimize your images
36 | gulp.src('./img/*')
37 | .pipe(imagemin())
38 | .pipe(gulp.dest('./img/'));
39 |
40 | });
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "hapi-dash",
3 | "description": "Boilerplate Hapi Web and API Server Example, with frontend dashboard.",
4 | "version": "0.1.0",
5 | "author": "Simon Maxwell-Stewart",
6 | "private": false,
7 | "repository": {
8 | "type": "git",
9 | "url": "https://github.com/smaxwellstewart/hapi-dash.git"
10 | },
11 | "main": "start.js",
12 | "engines": {
13 | "node": "0.10.x"
14 | },
15 | "scripts": {
16 | "test": "make test-cov",
17 | "start": "node start.js"
18 | },
19 | "dependencies": {
20 | "bcryptjs": "^2.0.2",
21 | "bower": "^1.6.5",
22 | "extend": "^3.0.0",
23 | "good": "^6.4.0",
24 | "good-console": "^5.2.0",
25 | "hapi": "^11.1.0",
26 | "hapi-assets": "~0.3.0",
27 | "hapi-auth-cookie": "^3.1.0",
28 | "hapi-auth-hawk": "^3.0.0",
29 | "hapi-cache-buster": "~0.4.0",
30 | "hapi-named-routes": "~0.3.0",
31 | "hawk": "^4.0.0",
32 | "inert": "^3.2.0",
33 | "joi": "^7.0.0",
34 | "jsonwebtoken": "^5.4.1",
35 | "marked": "^0.3.2",
36 | "mongodb": "^2.0.48",
37 | "nipple": "^2.5.3",
38 | "nodemailer": "1.9.0",
39 | "prompt": "^0.2.13",
40 | "require-directory": "~2.1.1",
41 | "socket.io": "^1.0.6",
42 | "swig": "~1.4.2",
43 | "toothache": "^2.0.0",
44 | "vision": "^4.0.1"
45 | },
46 | "devDependencies": {
47 | "gulp": "~3.9.0",
48 | "gulp-concat": "~2.6.0",
49 | "gulp-imagemin": "~2.4.0",
50 | "gulp-minify-css": "~1.2.1",
51 | "gulp-uglify": "~ 1.4.2",
52 | "gulp-util": "~3.0.7"
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/public/Theme/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/css/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/css/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/css/table-responsive.css:
--------------------------------------------------------------------------------
1 | /*Unseen Column*/
2 | @media only screen and (max-width: 800px) {
3 | #unseen table td:nth-child(2),
4 | #unseen table th:nth-child(2) {display: none;}
5 | }
6 |
7 | @media only screen and (max-width: 640px) {
8 | #unseen table td:nth-child(4),
9 | #unseen table th:nth-child(4),
10 | #unseen table td:nth-child(7),
11 | #unseen table th:nth-child(7),
12 | #unseen table td:nth-child(8),
13 | #unseen table th:nth-child(8){display: none;}
14 | }
15 |
16 | /*flip-scroll*/
17 |
18 | @media only screen and (max-width: 800px) {
19 | #flip-scroll .cf:after { visibility: hidden; display: block; font-size: 0; content: " "; clear: both; height: 0; }
20 | #flip-scroll * html .cf { zoom: 1; }
21 | #flip-scroll *:first-child+html .cf { zoom: 1; }
22 | #flip-scroll table { width: 100%; border-collapse: collapse; border-spacing: 0; }
23 |
24 | #flip-scroll th,
25 | #flip-scroll td { margin: 0; vertical-align: top; }
26 | #flip-scroll th { text-align: left; }
27 | #flip-scroll table { display: block; position: relative; width: 100%; }
28 | #flip-scroll thead { display: block; float: left; }
29 | #flip-scroll tbody { display: block; width: auto; position: relative; overflow-x: auto; white-space: nowrap; }
30 | #flip-scroll thead tr { display: block; }
31 | #flip-scroll th { display: block; text-align: right; }
32 | #flip-scroll tbody tr { display: inline-block; vertical-align: top; }
33 | #flip-scroll td { display: block; min-height: 1.25em; text-align: left; }
34 |
35 |
36 | /* sort out borders */
37 |
38 | #flip-scroll th { border-bottom: 0; border-left: 0; }
39 | #flip-scroll td { border-left: 0; border-right: 0; border-bottom: 0; }
40 | #flip-scroll tbody tr { border-left: 1px solid #babcbf; }
41 | #flip-scroll th:last-child,
42 | #flip-scroll td:last-child { border-bottom: 1px solid #babcbf; }
43 | }
44 |
45 | /*no more table*/
46 |
47 | @media only screen and (max-width: 800px) {
48 | /* Force table to not be like tables anymore */
49 | #no-more-tables table,
50 | #no-more-tables thead,
51 | #no-more-tables tbody,
52 | #no-more-tables th,
53 | #no-more-tables td,
54 | #no-more-tables tr {
55 | display: block;
56 | }
57 |
58 | /* Hide table headers (but not display: none;, for accessibility) */
59 | #no-more-tables thead tr {
60 | position: absolute;
61 | top: -9999px;
62 | left: -9999px;
63 | }
64 |
65 | #no-more-tables tr { border: 1px solid #ccc; }
66 |
67 | #no-more-tables td {
68 | /* Behave like a "row" */
69 | border: none;
70 | border-bottom: 1px solid #eee;
71 | position: relative;
72 | padding-left: 50%;
73 | white-space: normal;
74 | text-align:left;
75 | }
76 |
77 | #no-more-tables td:before {
78 | /* Now like a table header */
79 | position: absolute;
80 | /* Top/left values mimic padding */
81 | top: 6px;
82 | left: 6px;
83 | width: 45%;
84 | padding-right: 10px;
85 | white-space: nowrap;
86 | text-align:left;
87 | font-weight: bold;
88 | }
89 |
90 | /*
91 | Label the data
92 | */
93 | #no-more-tables td:before { content: attr(data-title); }
94 | }
--------------------------------------------------------------------------------
/public/Theme/assets/css/to-do.css:
--------------------------------------------------------------------------------
1 | /*--------------Tasks Widget--------------*/
2 |
3 | .task-content {
4 | margin-bottom: 30px;
5 | }
6 |
7 | .task-panel {
8 | background: #fff;
9 | text-align: left;
10 | box-shadow: 0px 3px 2px #aab2bd;
11 | margin: 5px;
12 | }
13 |
14 | .tasks-widget .task-content:after {
15 | clear: both;
16 | }
17 |
18 | .tasks-widget .task-footer {
19 | margin-top: 5px;
20 | }
21 |
22 | .tasks-widget .task-footer:after,
23 | .tasks-widget .task-footer:before {
24 | content: "";
25 | display: table;
26 | line-height: 0;
27 | }
28 |
29 | .tasks-widget .task-footer:after {
30 | clear: both;
31 | }
32 |
33 | .tasks-widget .task-list {
34 | padding:0;
35 | margin:0;
36 | }
37 |
38 | .tasks-widget .task-list > li {
39 | position:relative;
40 | padding:10px 5px;
41 | border-bottom:1px dashed #eaeaea;
42 | }
43 |
44 | .tasks-widget .task-list li.last-line {
45 | border-bottom:none;
46 | }
47 |
48 | .tasks-widget .task-list li > .task-bell {
49 | margin-left:10px;
50 | }
51 |
52 | .tasks-widget .task-list li > .task-checkbox {
53 | float:left;
54 | width:30px;
55 | }
56 |
57 | .tasks-widget .task-list li > .task-title {
58 | overflow:hidden;
59 | margin-right:10px;
60 | }
61 |
62 | .tasks-widget .task-list li > .task-config {
63 | position:absolute;
64 | top:10px;
65 | right:10px;
66 | }
67 |
68 | .tasks-widget .task-list li .task-title .task-title-sp {
69 | margin-right:5px;
70 | }
71 |
72 | .tasks-widget .task-list li.task-done .task-title-sp {
73 | text-decoration:line-through;
74 | color: #bbbbbb;
75 | }
76 |
77 | .tasks-widget .task-list li.task-done {
78 | background:#f6f6f6;
79 | }
80 |
81 | .tasks-widget .task-list li.task-done:hover {
82 | background:#f4f4f4;
83 | }
84 |
85 | .tasks-widget .task-list li:hover {
86 | background:#f9f9f9;
87 | }
88 |
89 | .tasks-widget .task-list li .task-config {
90 | display:none;
91 | }
92 |
93 | .tasks-widget .task-list li:hover > .task-config {
94 | display:block;
95 | margin-bottom:0 !important;
96 | }
97 |
98 |
99 | @media only screen and (max-width: 320px) {
100 |
101 | .tasks-widget .task-config-btn {
102 | float:inherit;
103 | display:block;
104 | }
105 |
106 | .tasks-widget .task-list-projects li > .label {
107 | margin-bottom:5px;
108 | }
109 |
110 | }
--------------------------------------------------------------------------------
/public/Theme/assets/css/zabuto_calendar.css:
--------------------------------------------------------------------------------
1 | /**
2 | * Zabuto Calendar
3 | */
4 |
5 | div.zabuto_calendar {
6 | margin: 0;
7 | padding: 10px;
8 | }
9 |
10 | .calendar-month-header {font-size:116%!important;}
11 | .calendar-month-header th {font-weight:600!important;}
12 |
13 | div.zabuto_calendar .table {
14 | width: 100%;
15 | margin: 0;
16 | padding: 0px;
17 | }
18 |
19 | div.zabuto_calendar .table th,
20 | div.zabuto_calendar .table td {
21 | padding: 11.9px 0px;
22 | text-align: center;
23 | }
24 |
25 | div.zabuto_calendar .table tr th,
26 | div.zabuto_calendar .table tr td {
27 | background-color:;
28 | }
29 |
30 | div.zabuto_calendar .table tr.calendar-month-header th {
31 | background-color:;
32 | }
33 |
34 | div.zabuto_calendar .table tr.calendar-month-header th span {
35 | cursor: pointer;
36 | display: inline-block;
37 | padding-bottom:0px;
38 |
39 | }
40 |
41 | div.zabuto_calendar .table tr.calendar-dow-header th {
42 | background-color:;
43 | }
44 |
45 | div.zabuto_calendar .table tr:last-child {
46 | border-bottom: 0px solid #dddddd;
47 | }
48 |
49 | div.zabuto_calendar .table tr.calendar-month-header th {
50 | padding:10px;
51 |
52 | }
53 |
54 | div.zabuto_calendar .table-bordered tr.calendar-month-header th {
55 | border-left: 0;
56 | border-right: 0;
57 | }
58 |
59 | div.zabuto_calendar .table-bordered tr.calendar-month-header th:first-child {
60 | border-left: 0px solid #dddddd;
61 | }
62 |
63 | div.zabuto_calendar div.calendar-month-navigation {
64 | cursor: pointer;
65 | margin: 0;
66 | padding: 0;
67 | padding-top:0px;
68 | }
69 |
70 | div.zabuto_calendar tr.calendar-dow-header th,
71 | div.zabuto_calendar tr.calendar-dow td {
72 | width: 14%;
73 | }
74 |
75 | div.zabuto_calendar .table tr td div.day {
76 | margin: 0px;
77 | padding-top: 0px;
78 | padding-bottom: 0px;
79 | }
80 |
81 | /* actions and events */
82 | div.zabuto_calendar .table tr td.event div.day,
83 | div.zabuto_calendar ul.legend li.event {
84 | background-color:;
85 | }
86 |
87 | div.zabuto_calendar .table tr td.dow-clickable,
88 | div.zabuto_calendar .table tr td.event-clickable {
89 | cursor: pointer;
90 | }
91 |
92 | /* badge */
93 | div.zabuto_calendar .badge-today,
94 | div.zabuto_calendar div.legend span.badge-today {
95 | background-color:;
96 | color: #ffffff;
97 | text-shadow: none;
98 | }
99 |
100 | div.zabuto_calendar .badge-event,
101 | div.zabuto_calendar div.legend span.badge-event {
102 | background-color:;
103 | color: #ffffff;
104 | text-shadow: none;
105 | }
106 |
107 | div.zabuto_calendar .badge-event {
108 | font-size: 0.95em;
109 | padding-left: 8px;
110 | padding-right: 8px;
111 | padding-bottom: 4px;
112 | }
113 |
114 | /* legend */
115 | div.zabuto_calendar div.legend {
116 | margin-top: 15px;
117 | text-align: right;
118 | padding-right:10px;
119 | padding-bottom:10px;
120 | }
121 |
122 | div.zabuto_calendar div.legend span {
123 | font-size: 10px;
124 | font-weight: normal;
125 | }
126 |
127 | div.zabuto_calendar div.legend span.legend-text:after,
128 | div.zabuto_calendar div.legend span.legend-block:after,
129 | div.zabuto_calendar div.legend span.legend-list:after,
130 | div.zabuto_calendar div.legend span.legend-spacer:after {
131 | content: ' ';
132 | }
133 |
134 | div.zabuto_calendar div.legend span.legend-spacer {
135 | padding-left: 25px;
136 | }
137 |
138 | div.zabuto_calendar ul.legend > span {
139 | padding-left: 2px;
140 | }
141 |
142 | div.zabuto_calendar ul.legend {
143 | display: inline-block;
144 | list-style: none outside none;
145 | margin: 0;
146 | padding: 0;
147 | }
148 |
149 | div.zabuto_calendar ul.legend li {
150 | display: inline-block;
151 | height: 8px;
152 | width: 8px;
153 | margin-left: 5px;
154 | }
155 |
156 | div.zabuto_calendar ul.legend
157 | div.zabuto_calendar ul.legend li:first-child {
158 | margin-left: 7px;
159 | }
160 |
161 | div.zabuto_calendar ul.legend li:last-child {
162 | margin-right: 5px;
163 | }
164 |
165 | div.zabuto_calendar div.legend span.badge {
166 | font-size: 0.9em;
167 | border-radius: 5px 5px 5px 5px;
168 | padding-left: 5px;
169 | padding-right: 5px;
170 | padding-top: 2px;
171 | padding-bottom: 3px;
172 | }
173 |
174 | /* responsive */
175 | @media (max-width: 979px) {
176 | div.zabuto_calendar .table th,
177 | div.zabuto_calendar .table td {
178 | padding: 2px 1px;
179 | }
180 | }
181 |
--------------------------------------------------------------------------------
/public/Theme/assets/font-awesome/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/font-awesome/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/font-awesome/css/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/font-awesome/css/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/font-awesome/fonts/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/font-awesome/fonts/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/font-awesome/fonts/FontAwesome.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/font-awesome/fonts/FontAwesome.otf
--------------------------------------------------------------------------------
/public/Theme/assets/font-awesome/fonts/fontawesome-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/font-awesome/fonts/fontawesome-webfont.eot
--------------------------------------------------------------------------------
/public/Theme/assets/font-awesome/fonts/fontawesome-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/font-awesome/fonts/fontawesome-webfont.ttf
--------------------------------------------------------------------------------
/public/Theme/assets/font-awesome/fonts/fontawesome-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/font-awesome/fonts/fontawesome-webfont.woff
--------------------------------------------------------------------------------
/public/Theme/assets/fonts/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/fonts/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/fonts/glyphicons-halflings-regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/fonts/glyphicons-halflings-regular.eot
--------------------------------------------------------------------------------
/public/Theme/assets/fonts/glyphicons-halflings-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/fonts/glyphicons-halflings-regular.ttf
--------------------------------------------------------------------------------
/public/Theme/assets/fonts/glyphicons-halflings-regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/fonts/glyphicons-halflings-regular.woff
--------------------------------------------------------------------------------
/public/Theme/assets/img/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/img/blog-bg.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/blog-bg.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/checkbox-gray.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/checkbox-gray.png
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-01.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-01.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-02.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-02.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-03.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-03.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-04.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-04.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-05.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-05.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-06.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-06.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-07.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-07.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-08.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-08.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-09.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-09.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-10.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-10.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/friends/fr-11.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/friends/fr-11.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/instagram.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/instagram.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/login-bg.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/login-bg.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/lorde.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/lorde.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/mask.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/mask.png
--------------------------------------------------------------------------------
/public/Theme/assets/img/ny.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/ny.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/portfolio/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/portfolio/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/img/portfolio/port01.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/portfolio/port01.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/portfolio/port02.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/portfolio/port02.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/portfolio/port03.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/portfolio/port03.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/portfolio/port04.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/portfolio/port04.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/portfolio/port05.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/portfolio/port05.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/portfolio/port06.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/portfolio/port06.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/product.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/product.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/product.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/product.png
--------------------------------------------------------------------------------
/public/Theme/assets/img/profile-01.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/profile-01.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/profile-02.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/profile-02.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/radio-gray.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/radio-gray.png
--------------------------------------------------------------------------------
/public/Theme/assets/img/ui-danro.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/ui-danro.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/ui-divya.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/ui-divya.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/ui-sam.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/ui-sam.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/ui-sherman.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/ui-sherman.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/ui-zac.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/ui-zac.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/weather.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/weather.jpg
--------------------------------------------------------------------------------
/public/Theme/assets/img/zoom.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/img/zoom.png
--------------------------------------------------------------------------------
/public/Theme/assets/js/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/bootstrap-inputmask/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/bootstrap-inputmask/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/calendar-conf-events.js:
--------------------------------------------------------------------------------
1 | var Script = function () {
2 |
3 |
4 | /* initialize the external events
5 | -----------------------------------------------------------------*/
6 |
7 | $('#external-events div.external-event').each(function() {
8 |
9 | // create an Event Object (http://arshaw.com/fullcalendar/docs/event_data/Event_Object/)
10 | // it doesn't need to have a start or end
11 | var eventObject = {
12 | title: $.trim($(this).text()) // use the element's text as the event title
13 | };
14 |
15 | // store the Event Object in the DOM element so we can get to it later
16 | $(this).data('eventObject', eventObject);
17 |
18 | // make the event draggable using jQuery UI
19 | $(this).draggable({
20 | zIndex: 999,
21 | revert: true, // will cause the event to go back to its
22 | revertDuration: 0 // original position after the drag
23 | });
24 |
25 | });
26 |
27 |
28 | /* initialize the calendar
29 | -----------------------------------------------------------------*/
30 |
31 | var date = new Date();
32 | var d = date.getDate();
33 | var m = date.getMonth();
34 | var y = date.getFullYear();
35 |
36 | $('#calendar').fullCalendar({
37 | header: {
38 | left: 'prev,next today',
39 | center: 'title',
40 | right: 'month,basicWeek,basicDay'
41 | },
42 | editable: true,
43 | droppable: true, // this allows things to be dropped onto the calendar !!!
44 | drop: function(date, allDay) { // this function is called when something is dropped
45 |
46 | // retrieve the dropped element's stored Event Object
47 | var originalEventObject = $(this).data('eventObject');
48 |
49 | // we need to copy it, so that multiple events don't have a reference to the same object
50 | var copiedEventObject = $.extend({}, originalEventObject);
51 |
52 | // assign it the date that was reported
53 | copiedEventObject.start = date;
54 | copiedEventObject.allDay = allDay;
55 |
56 | // render the event on the calendar
57 | // the last `true` argument determines if the event "sticks" (http://arshaw.com/fullcalendar/docs/event_rendering/renderEvent/)
58 | $('#calendar').fullCalendar('renderEvent', copiedEventObject, true);
59 |
60 | // is the "remove after drop" checkbox checked?
61 | if ($('#drop-remove').is(':checked')) {
62 | // if so, remove the element from the "Draggable Events" list
63 | $(this).remove();
64 | }
65 |
66 | },
67 | events: [
68 | {
69 | title: 'All Day Event',
70 | start: new Date(y, m, 1)
71 | },
72 | {
73 | title: 'Long Event',
74 | start: new Date(y, m, d-5),
75 | end: new Date(y, m, d-2)
76 | },
77 | {
78 | id: 999,
79 | title: 'Repeating Event',
80 | start: new Date(y, m, d-3, 16, 0),
81 | allDay: false
82 | },
83 | {
84 | id: 999,
85 | title: 'Repeating Event',
86 | start: new Date(y, m, d+4, 16, 0),
87 | allDay: false
88 | },
89 | {
90 | title: 'Meeting',
91 | start: new Date(y, m, d, 10, 30),
92 | allDay: false
93 | },
94 | {
95 | title: 'Lunch',
96 | start: new Date(y, m, d, 12, 0),
97 | end: new Date(y, m, d, 14, 0),
98 | allDay: false
99 | },
100 | {
101 | title: 'Birthday Party',
102 | start: new Date(y, m, d+1, 19, 0),
103 | end: new Date(y, m, d+1, 22, 30),
104 | allDay: false
105 | },
106 | {
107 | title: 'Click for Google',
108 | start: new Date(y, m, 28),
109 | end: new Date(y, m, 29),
110 | url: 'http://google.com/'
111 | }
112 | ]
113 | });
114 |
115 |
116 | }();
--------------------------------------------------------------------------------
/public/Theme/assets/js/chart-master/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/chart-master/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/chartjs-conf.js:
--------------------------------------------------------------------------------
1 | var Script = function () {
2 |
3 |
4 | var doughnutData = [
5 | {
6 | value: 30,
7 | color:"#1abc9c"
8 | },
9 | {
10 | value : 50,
11 | color : "#2ecc71"
12 | },
13 | {
14 | value : 100,
15 | color : "#3498db"
16 | },
17 | {
18 | value : 40,
19 | color : "#9b59b6"
20 | },
21 | {
22 | value : 120,
23 | color : "#34495e"
24 | }
25 |
26 | ];
27 | var lineChartData = {
28 | labels : ["","","","","","",""],
29 | datasets : [
30 | {
31 | fillColor : "rgba(220,220,220,0.5)",
32 | strokeColor : "rgba(220,220,220,1)",
33 | pointColor : "rgba(220,220,220,1)",
34 | pointStrokeColor : "#fff",
35 | data : [65,59,90,81,56,55,40]
36 | },
37 | {
38 | fillColor : "rgba(151,187,205,0.5)",
39 | strokeColor : "rgba(151,187,205,1)",
40 | pointColor : "rgba(151,187,205,1)",
41 | pointStrokeColor : "#fff",
42 | data : [28,48,40,19,96,27,100]
43 | }
44 | ]
45 |
46 | };
47 | var pieData = [
48 | {
49 | value: 30,
50 | color:"#1abc9c"
51 | },
52 | {
53 | value : 50,
54 | color : "#16a085"
55 | },
56 | {
57 | value : 100,
58 | color : "#27ae60"
59 | }
60 |
61 | ];
62 | var barChartData = {
63 | labels : ["January","February","March","April","May","June","July"],
64 | datasets : [
65 | {
66 | fillColor : "rgba(220,220,220,0.5)",
67 | strokeColor : "rgba(220,220,220,1)",
68 | data : [65,59,90,81,56,55,40]
69 | },
70 | {
71 | fillColor : "rgba(151,187,205,0.5)",
72 | strokeColor : "rgba(151,187,205,1)",
73 | data : [28,48,40,19,96,27,100]
74 | }
75 | ]
76 |
77 | };
78 | var chartData = [
79 | {
80 | value : Math.random(),
81 | color: "#D97041"
82 | },
83 | {
84 | value : Math.random(),
85 | color: "#C7604C"
86 | },
87 | {
88 | value : Math.random(),
89 | color: "#21323D"
90 | },
91 | {
92 | value : Math.random(),
93 | color: "#9D9B7F"
94 | },
95 | {
96 | value : Math.random(),
97 | color: "#7D4F6D"
98 | },
99 | {
100 | value : Math.random(),
101 | color: "#584A5E"
102 | }
103 | ];
104 | var radarChartData = {
105 | labels : ["","","","","","",""],
106 | datasets : [
107 | {
108 | fillColor : "rgba(220,220,220,0.5)",
109 | strokeColor : "rgba(220,220,220,1)",
110 | pointColor : "rgba(220,220,220,1)",
111 | pointStrokeColor : "#fff",
112 | data : [65,59,90,81,56,55,40]
113 | },
114 | {
115 | fillColor : "rgba(151,187,205,0.5)",
116 | strokeColor : "rgba(151,187,205,1)",
117 | pointColor : "rgba(151,187,205,1)",
118 | pointStrokeColor : "#fff",
119 | data : [28,48,40,19,96,27,100]
120 | }
121 | ]
122 |
123 | };
124 | new Chart(document.getElementById("doughnut").getContext("2d")).Doughnut(doughnutData);
125 | new Chart(document.getElementById("line").getContext("2d")).Line(lineChartData);
126 | new Chart(document.getElementById("radar").getContext("2d")).Radar(radarChartData);
127 | new Chart(document.getElementById("polarArea").getContext("2d")).PolarArea(chartData);
128 | new Chart(document.getElementById("bar").getContext("2d")).Bar(barChartData);
129 | new Chart(document.getElementById("pie").getContext("2d")).Pie(pieData);
130 |
131 |
132 | }();
--------------------------------------------------------------------------------
/public/Theme/assets/js/common-scripts.js:
--------------------------------------------------------------------------------
1 | /*---LEFT BAR ACCORDION----*/
2 | $(function() {
3 | $('#nav-accordion').dcAccordion({
4 | eventType: 'click',
5 | autoClose: true,
6 | saveState: true,
7 | disableLink: true,
8 | speed: 'slow',
9 | showCount: false,
10 | autoExpand: true,
11 | // cookie: 'dcjq-accordion-1',
12 | classExpand: 'dcjq-current-parent'
13 | });
14 | });
15 |
16 | var Script = function () {
17 |
18 |
19 | // sidebar dropdown menu auto scrolling
20 |
21 | jQuery('#sidebar .sub-menu > a').click(function () {
22 | var o = ($(this).offset());
23 | diff = 250 - o.top;
24 | if(diff>0)
25 | $("#sidebar").scrollTo("-="+Math.abs(diff),500);
26 | else
27 | $("#sidebar").scrollTo("+="+Math.abs(diff),500);
28 | });
29 |
30 |
31 |
32 | // sidebar toggle
33 |
34 | $(function() {
35 | function responsiveView() {
36 | var wSize = $(window).width();
37 | if (wSize <= 768) {
38 | $('#container').addClass('sidebar-close');
39 | $('#sidebar > ul').hide();
40 | }
41 |
42 | if (wSize > 768) {
43 | $('#container').removeClass('sidebar-close');
44 | $('#sidebar > ul').show();
45 | }
46 | }
47 | $(window).on('load', responsiveView);
48 | $(window).on('resize', responsiveView);
49 | });
50 |
51 | $('.fa-bars').click(function () {
52 | if ($('#sidebar > ul').is(":visible") === true) {
53 | $('#main-content').css({
54 | 'margin-left': '0px'
55 | });
56 | $('#sidebar').css({
57 | 'margin-left': '-210px'
58 | });
59 | $('#sidebar > ul').hide();
60 | $("#container").addClass("sidebar-closed");
61 | } else {
62 | $('#main-content').css({
63 | 'margin-left': '210px'
64 | });
65 | $('#sidebar > ul').show();
66 | $('#sidebar').css({
67 | 'margin-left': '0'
68 | });
69 | $("#container").removeClass("sidebar-closed");
70 | }
71 | });
72 |
73 | // custom scrollbar
74 | $("#sidebar").niceScroll({styler:"fb",cursorcolor:"#4ECDC4", cursorwidth: '3', cursorborderradius: '10px', background: '#404040', spacebarenabled:false, cursorborder: ''});
75 |
76 | $("html").niceScroll({styler:"fb",cursorcolor:"#4ECDC4", cursorwidth: '6', cursorborderradius: '10px', background: '#404040', spacebarenabled:false, cursorborder: '', zindex: '1000'});
77 |
78 | // widget tools
79 |
80 | jQuery('.panel .tools .fa-chevron-down').click(function () {
81 | var el = jQuery(this).parents(".panel").children(".panel-body");
82 | if (jQuery(this).hasClass("fa-chevron-down")) {
83 | jQuery(this).removeClass("fa-chevron-down").addClass("fa-chevron-up");
84 | el.slideUp(200);
85 | } else {
86 | jQuery(this).removeClass("fa-chevron-up").addClass("fa-chevron-down");
87 | el.slideDown(200);
88 | }
89 | });
90 |
91 | jQuery('.panel .tools .fa-times').click(function () {
92 | jQuery(this).parents(".panel").parent().remove();
93 | });
94 |
95 |
96 | // tool tips
97 |
98 | $('.tooltips').tooltip();
99 |
100 | // popovers
101 |
102 | $('.popovers').popover();
103 |
104 |
105 |
106 | // custom bar chart
107 |
108 | if ($(".custom-bar-chart")) {
109 | $(".bar").each(function () {
110 | var i = $(this).find(".value").html();
111 | $(this).find(".value").html("");
112 | $(this).find(".value").animate({
113 | height: i
114 | }, 2000)
115 | })
116 | }
117 |
118 |
119 | }();
--------------------------------------------------------------------------------
/public/Theme/assets/js/easy-pie-chart.js:
--------------------------------------------------------------------------------
1 | var Script = function () {
2 |
3 | // easy pie chart
4 |
5 | $('.percentage').easyPieChart({
6 | animate: 1000,
7 | size: 135,
8 | barColor:'#ff6c60'
9 | });
10 | $('.percentage-light').easyPieChart({
11 | barColor: function(percent) {
12 | percent /= 100;
13 | return "rgb(" + Math.round(255 * (1-percent)) + ", " + Math.round(255 * percent) + ", 0)";
14 | },
15 | trackColor: '#666',
16 | scaleColor: false,
17 | lineCap: 'butt',
18 | lineWidth: 15,
19 | animate: 1000
20 | });
21 |
22 | $('.update-easy-pie-chart').click(function(){
23 | $('.easy-pie-chart .percentage').each(function() {
24 | var newValue = Math.floor(100*Math.random());
25 | $(this).data('easyPieChart').update(newValue);
26 | $('span', this).text(newValue);
27 | });
28 | });
29 |
30 | $('.updateEasyPieChart').on('click', function(e) {
31 | e.preventDefault();
32 | $('.percentage, .percentage-light').each(function() {
33 | var newValue = Math.round(100*Math.random());
34 | $(this).data('easyPieChart').update(newValue);
35 | $('span', this).text(newValue);
36 | });
37 | });
38 |
39 | }();
--------------------------------------------------------------------------------
/public/Theme/assets/js/fancybox/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/fancybox/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/fullcalendar/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/fullcalendar/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/css/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/css/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/css/jquery.gritter.css:
--------------------------------------------------------------------------------
1 | /* the norm */
2 | #gritter-notice-wrapper {
3 | position:fixed;
4 | top:20px;
5 | right:20px;
6 | width:301px;
7 | z-index:9999;
8 | }
9 | #gritter-notice-wrapper.top-left {
10 | left: 20px;
11 | right: auto;
12 | }
13 | #gritter-notice-wrapper.bottom-right {
14 | top: auto;
15 | left: auto;
16 | bottom: 20px;
17 | right: 20px;
18 | }
19 | #gritter-notice-wrapper.bottom-left {
20 | top: auto;
21 | right: auto;
22 | bottom: 20px;
23 | left: 20px;
24 | }
25 | .gritter-item-wrapper {
26 | position:relative;
27 | margin:0 0 10px 0;
28 | background:url('../images/ie-spacer.gif'); /* ie7/8 fix */
29 | }
30 | .gritter-top {
31 | background:url(../images/gritter.png) no-repeat left -30px;
32 | height:10px;
33 | }
34 | .hover .gritter-top {
35 | background-position:right -30px;
36 | }
37 | .gritter-bottom {
38 | background:url(../images/gritter.png) no-repeat left bottom;
39 | height:8px;
40 | margin:0;
41 | }
42 | .hover .gritter-bottom {
43 | background-position: bottom right;
44 | }
45 | .gritter-item {
46 | display:block;
47 | background:url(../images/gritter.png) no-repeat left -40px;
48 | color:#eee;
49 | padding:2px 11px 8px 11px;
50 | font-size: 11px;
51 | font-family:verdana;
52 | }
53 | .hover .gritter-item {
54 | background-position:right -40px;
55 | }
56 | .gritter-item p {
57 | padding:0;
58 | margin:0;
59 | word-wrap:break-word;
60 | }
61 | .gritter-close {
62 | display:none;
63 | position:absolute;
64 | top:5px;
65 | left:3px;
66 | background:url(../images/gritter.png) no-repeat left top;
67 | cursor:pointer;
68 | width:30px;
69 | height:30px;
70 | text-indent:-9999em;
71 | }
72 | .gritter-title {
73 | font-size:14px;
74 | font-weight:bold;
75 | padding:0 0 7px 0;
76 | display:block;
77 | text-shadow:1px 1px 0 #000; /* Not supported by IE :( */
78 | }
79 | .gritter-image {
80 | width:48px;
81 | height:48px;
82 | float:left;
83 | }
84 | .gritter-with-image,
85 | .gritter-without-image {
86 | padding:0;
87 | }
88 | .gritter-with-image {
89 | width:220px;
90 | float:right;
91 | }
92 | /* for the light (white) version of the gritter notice */
93 | .gritter-light .gritter-item,
94 | .gritter-light .gritter-bottom,
95 | .gritter-light .gritter-top,
96 | .gritter-light .gritter-close {
97 | background-image: url(../images/gritter-light.png);
98 | color: #222;
99 | }
100 | .gritter-light .gritter-title {
101 | text-shadow: none;
102 | }
103 |
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/css/jquery.gritter0.css:
--------------------------------------------------------------------------------
1 | /* the norm */
2 | #gritter-notice-wrapper {
3 | position:fixed;
4 | top:20px;
5 | right:20px;
6 | width:301px;
7 | z-index:9999;
8 | }
9 | #gritter-notice-wrapper.top-left {
10 | left: 20px;
11 | right: auto;
12 | }
13 | #gritter-notice-wrapper.bottom-right {
14 | top: auto;
15 | left: auto;
16 | bottom: 20px;
17 | right: 20px;
18 | }
19 | #gritter-notice-wrapper.bottom-left {
20 | top: auto;
21 | right: auto;
22 | bottom: 20px;
23 | left: 20px;
24 | }
25 | .gritter-item-wrapper {
26 | position:relative;
27 | margin:0 0 10px 0;
28 | background:url('../images/ie-spacer.gif'); /* ie7/8 fix */
29 | }
30 | .gritter-top {
31 | background:url("..images/gritter.png") no-repeat left -30px;
32 | height:10px;
33 | }
34 | .hover .gritter-top {
35 | background-position:right -30px;
36 | }
37 | .gritter-bottom {
38 | background:url("../images/gritter.png") no-repeat left bottom;
39 | height:8px;
40 | margin:0;
41 | }
42 | .hover .gritter-bottom {
43 | background-position: bottom right;
44 | }
45 | .gritter-item {
46 | display:block;
47 | background:url("../images/gritter.png") no-repeat left -40px;
48 | color:#eee;
49 | padding:2px 11px 8px 11px;
50 | font-size: 11px;
51 | font-family:verdana;
52 | }
53 | .hover .gritter-item {
54 | background-position:right -40px;
55 | }
56 | .gritter-item p {
57 | padding:0;
58 | margin:0;
59 | word-wrap:break-word;
60 | }
61 | .gritter-close {
62 | display:none;
63 | position:absolute;
64 | top:5px;
65 | left:3px;
66 | background:url("../images/gritter.png") no-repeat left top;
67 | cursor:pointer;
68 | width:30px;
69 | height:30px;
70 | }
71 | .gritter-title {
72 | font-size:14px;
73 | font-weight:bold;
74 | padding:0 0 7px 0;
75 | display:block;
76 | text-shadow:1px 1px 0 #000; /* Not supported by IE :( */
77 | }
78 | .gritter-image {
79 | width:48px;
80 | height:48px;
81 | float:left;
82 | }
83 | .gritter-with-image,
84 | .gritter-without-image {
85 | padding:0;
86 | }
87 | .gritter-with-image {
88 | width:220px;
89 | float:right;
90 | }
91 | /* for the light (white) version of the gritter notice */
92 | .gritter-light .gritter-item,
93 | .gritter-light .gritter-bottom,
94 | .gritter-light .gritter-top,
95 | .gritter-light .gritter-close {
96 | background-image: url("../images/gritter-light.png");
97 | color: #222;
98 | }
99 | .gritter-light .gritter-title {
100 | text-shadow: none;
101 | }
102 |
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/images/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/images/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/images/gritter-light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/images/gritter-light.png
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/images/gritter-long.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/images/gritter-long.png
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/images/gritter.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/images/gritter.png
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/images/ie-spacer.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/images/ie-spacer.gif
--------------------------------------------------------------------------------
/public/Theme/assets/js/gritter/js/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/gritter/js/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/jquery-easy-pie-chart/.DS_Store:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/public/Theme/assets/js/jquery-easy-pie-chart/.DS_Store
--------------------------------------------------------------------------------
/public/Theme/assets/js/jquery-easy-pie-chart/jquery.easy-pie-chart.css:
--------------------------------------------------------------------------------
1 | .easyPieChart {
2 | position: relative;
3 | text-align: center;
4 | }
5 |
6 | .easyPieChart canvas {
7 | position: absolute;
8 | top: 0;
9 | left: 0;
10 | }
11 |
--------------------------------------------------------------------------------
/public/Theme/assets/js/jquery.backstretch.min.js:
--------------------------------------------------------------------------------
1 | /*! Backstretch - v2.0.3 - 2012-11-30
2 | * http://srobbin.com/jquery-plugins/backstretch/
3 | * Copyright (c) 2012 Scott Robbin; Licensed MIT */
4 | (function(e,t,n){"use strict";e.fn.backstretch=function(r,s){return(r===n||r.length===0)&&e.error("No images were supplied for Backstretch"),e(t).scrollTop()===0&&t.scrollTo(0,0),this.each(function(){var t=e(this),n=t.data("backstretch");n&&(s=e.extend(n.options,s),n.destroy(!0)),n=new i(this,r,s),t.data("backstretch",n)})},e.backstretch=function(t,n){return e("body").backstretch(t,n).data("backstretch")},e.expr[":"].backstretch=function(t){return e(t).data("backstretch")!==n},e.fn.backstretch.defaults={centeredX:!0,centeredY:!0,duration:5e3,fade:0};var r={wrap:{left:0,top:0,overflow:"hidden",margin:0,padding:0,height:"100%",width:"100%",zIndex:-999999},img:{position:"absolute",display:"none",margin:0,padding:0,border:"none",width:"auto",height:"auto",maxWidth:"none",zIndex:-999999}},i=function(n,i,o){this.options=e.extend({},e.fn.backstretch.defaults,o||{}),this.images=e.isArray(i)?i:[i],e.each(this.images,function(){e("")[0].src=this}),this.isBody=n===document.body,this.$container=e(n),this.$wrap=e('
http://wootapa-watable.appspot.com/
17 | 18 | 19 | 22 | 23 | -------------------------------------------------------------------------------- /public/js/watable/watable.css: -------------------------------------------------------------------------------- 1 | .watable * { 2 | white-space: nowrap; 3 | font-size: 12px !important; 4 | } 5 | 6 | .watable.table { 7 | width: auto; 8 | } 9 | 10 | .watable p { 11 | margin: 0; 12 | } 13 | 14 | .watable th, 15 | .watable td { 16 | border-width: 1px !important; 17 | } 18 | 19 | .watable .glyphicon { 20 | margin: 0 0 0 2px; 21 | opacity: 0.5; 22 | } 23 | 24 | .watable span.filter { 25 | background-color: #999; 26 | } 27 | 28 | .watable .indeterminate { 29 | opacity: 0.4; 30 | -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=40)"; 31 | filter: alpha(opacity=40); 32 | } 33 | 34 | .watable .columnpicker li, 35 | .watable .actions li { 36 | padding-left: 5px; 37 | } 38 | 39 | .watable .btn-toolbar { 40 | margin-bottom: -5px; 41 | } 42 | 43 | .watable .pagination { 44 | margin: 0; 45 | } 46 | 47 | .watable input[type=checkbox] { 48 | margin: 0; 49 | padding: 0; 50 | } 51 | 52 | .watable input[type=text].filter { 53 | margin: 0; 54 | padding: 0; 55 | box-shadow: none; 56 | border: none; 57 | width: 80px; 58 | float: left; 59 | background-color: transparent; 60 | } 61 | 62 | .watable .date-wrap { 63 | width: 100%; 64 | min-width: 115px; 65 | } 66 | 67 | .watable .dateWrap .add-on { 68 | margin: 0; 69 | padding: 0; 70 | background: none; 71 | border: none; 72 | float: right; 73 | cursor: pointer; 74 | } 75 | 76 | .watable .dropdown-menu { 77 | max-height: 250px; 78 | overflow: auto; 79 | } 80 | 81 | .watable .actions a { 82 | padding: 0; 83 | margin: 0; 84 | } 85 | 86 | /* Only for demo purposes */ 87 | .watable div.green { 88 | background: -moz-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(0,140,37,0.38) 38%, rgba(0,140,37,1) 100%); /* FF3.6+ */ 89 | background: -webkit-gradient(linear, left top, right top, color-stop(0%,rgba(255,255,255,0)), color-stop(38%,rgba(0,140,37,0.38)), color-stop(100%,rgba(0,140,37,1))); /* Chrome,Safari4+ */ 90 | background: -webkit-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(0,140,37,0.38) 38%,rgba(0,140,37,1) 100%); /* Chrome10+,Safari5.1+ */ 91 | background: -o-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(0,140,37,0.38) 38%,rgba(0,140,37,1) 100%); /* Opera 11.10+ */ 92 | background: -ms-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(0,140,37,0.38) 38%,rgba(0,140,37,1) 100%); /* IE10+ */ 93 | background: linear-gradient(to right, rgba(255,255,255,0) 0%,rgba(0,140,37,0.38) 38%,rgba(0,140,37,1) 100%); /* W3C */ 94 | filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#00ffffff', endColorstr='#008c25',GradientType=1 ); /* IE6-9 */ 95 | } 96 | 97 | .watable div.yellow { 98 | background: -moz-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(188,179,0,0.38) 38%, rgba(188,179,0,1) 100%); /* FF3.6+ */ 99 | background: -webkit-gradient(linear, left top, right top, color-stop(0%,rgba(255,255,255,0)), color-stop(38%,rgba(188,179,0,0.38)), color-stop(100%,rgba(188,179,0,1))); /* Chrome,Safari4+ */ 100 | background: -webkit-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(188,179,0,0.38) 38%,rgba(188,179,0,1) 100%); /* Chrome10+,Safari5.1+ */ 101 | background: -o-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(188,179,0,0.38) 38%,rgba(188,179,0,1) 100%); /* Opera 11.10+ */ 102 | background: -ms-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(188,179,0,0.38) 38%,rgba(188,179,0,1) 100%); /* IE10+ */ 103 | background: linear-gradient(to right, rgba(255,255,255,0) 0%,rgba(188,179,0,0.38) 38%,rgba(188,179,0,1) 100%); /* W3C */ 104 | filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#00ffffff', endColorstr='#bcb300',GradientType=1 ); /* IE6-9 */ 105 | } 106 | 107 | .watable div.red { 108 | background: -moz-linear-gradient(left, rgba(255,255,255,0) 0%, rgba(147,22,0,0.38) 38%, rgba(147,22,0,1) 100%); /* FF3.6+ */ 109 | background: -webkit-gradient(linear, left top, right top, color-stop(0%,rgba(255,255,255,0)), color-stop(38%,rgba(147,22,0,0.38)), color-stop(100%,rgba(147,22,0,1))); /* Chrome,Safari4+ */ 110 | background: -webkit-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(147,22,0,0.38) 38%,rgba(147,22,0,1) 100%); /* Chrome10+,Safari5.1+ */ 111 | background: -o-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(147,22,0,0.38) 38%,rgba(147,22,0,1) 100%); /* Opera 11.10+ */ 112 | background: -ms-linear-gradient(left, rgba(255,255,255,0) 0%,rgba(147,22,0,0.38) 38%,rgba(147,22,0,1) 100%); /* IE10+ */ 113 | background: linear-gradient(to right, rgba(255,255,255,0) 0%,rgba(147,22,0,0.38) 38%,rgba(147,22,0,1) 100%); /* W3C */ 114 | filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#00ffffff', endColorstr='#931600',GradientType=1 ); /* IE6-9 */ 115 | } -------------------------------------------------------------------------------- /servers/api/User/index.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by kidtronnix on 20/05/14. 3 | */ 4 | 5 | // Packages for validation 6 | var Joi = require('joi'); 7 | 8 | // Internal config stuff 9 | var CRUD = { 10 | collection: 'users', 11 | create: { 12 | bcrypt: 'password', 13 | date: 'created', 14 | payload: Joi.object().keys({ 15 | email: Joi.string().required(), 16 | password: Joi.string().required(), 17 | fname: Joi.string().required(), 18 | lname: Joi.string().required(), 19 | access: Joi.string(), 20 | apiToken: Joi.string().required(), 21 | }), 22 | defaults: { 23 | access: 'normal', 24 | activated: false 25 | }, 26 | }, 27 | update: { 28 | bcrypt: 'password', 29 | date: 'updated', 30 | payload: Joi.object().keys({ 31 | password: Joi.string(), 32 | fname: Joi.string(), 33 | lname: Joi.string(), 34 | activated: Joi.boolean(), 35 | access: Joi.string(), 36 | guiToken: [Joi.string(), Joi.boolean()], 37 | forgotToken: [Joi.string(), Joi.boolean()] 38 | }) 39 | }, 40 | validationOpts: { 41 | abortEarly: false 42 | } 43 | }; 44 | 45 | 46 | exports.register = function(server, options, next) { 47 | 48 | // Add db to our config 49 | CRUD.db = options.db; 50 | 51 | // Require User functions 52 | var User = require('toothache')(CRUD); 53 | console.log(User); 54 | var apiGenKey = function(request, next) { 55 | var generate = function(length) { 56 | // Just produces random string using these chars 57 | var chars = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'; 58 | var result = ''; 59 | for (var i = length; i > 0; --i) result += chars[Math.round(Math.random() * (chars.length - 1))]; 60 | return result; 61 | } 62 | 63 | var apiKey = generate(64); 64 | 65 | // Add to payload and return 66 | request.payload.apiToken = apiKey; 67 | next(apiKey); 68 | } 69 | 70 | // Create 71 | server.route({ 72 | path: "/api/user", 73 | method: "POST", 74 | config: { 75 | auth: 'core', 76 | pre: [ 77 | { method: apiGenKey, assign: 'apiGenKey' } 78 | ], 79 | handler: User.create 80 | } 81 | }); 82 | 83 | // Get all 84 | server.route({ 85 | path: "/api/user/{id}", 86 | method: "GET", 87 | config: { 88 | auth: 'core', 89 | handler: User.get, 90 | validate: { 91 | params: { 92 | id: Joi.string().min(12) 93 | } 94 | } 95 | } 96 | }); 97 | 98 | // Get ind. 99 | server.route({ 100 | path: "/api/user", 101 | method: "GET", 102 | config: { 103 | auth: 'core', 104 | handler: User.find 105 | } 106 | }); 107 | 108 | // Update 109 | server.route({ 110 | path: "/api/user/{id}", 111 | method: "PUT", 112 | config: { 113 | auth: 'core', 114 | handler: User.update, 115 | validate: { 116 | params: { 117 | id: Joi.string().min(12) 118 | } 119 | } 120 | } 121 | }); 122 | 123 | // Delete 124 | server.route({ 125 | path: "/api/user/{id}", 126 | method: "DELETE", 127 | config: { 128 | auth: 'core', 129 | handler: User.del, 130 | validate: { 131 | params: { 132 | id: Joi.string().min(12) 133 | } 134 | } 135 | } 136 | }); 137 | 138 | next(); 139 | } 140 | 141 | exports.register.attributes = { 142 | name: 'user', 143 | version: '1.0.0' 144 | }; 145 | -------------------------------------------------------------------------------- /servers/api/User/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "User", 3 | "version": "0.0.0", 4 | "description": "Controls user stuff", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "smaxwellstewart", 10 | "license": "ISC" 11 | } 12 | -------------------------------------------------------------------------------- /servers/api/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Api", 3 | "version": "0.0.0", 4 | "description": "Media Scanner API", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "s.maxwell-stewart@mobicow.com", 10 | "license": "ISC", 11 | "dependencies": { 12 | "utf8": "^2.0.0" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /servers/api/server.js: -------------------------------------------------------------------------------- 1 | var Hapi = require('hapi'); 2 | var MongoDB = require('mongodb').Db; 3 | var Server = require('mongodb').Server; 4 | var ObjectId = require('mongodb').ObjectID; 5 | var apiIP = "127.0.0.1:3000"; 6 | 7 | var config = require('../../config'); 8 | 9 | 10 | // API SERVER 11 | var apiServer = new Hapi.Server(); 12 | apiServer.connection({ host: config.api.host, port: config.api.port }); 13 | 14 | var connected = false; 15 | var db = new MongoDB(config.db.name, new Server(config.db.host, config.db.port, {auto_reconnect: true}), {w: 1}); 16 | db.open(function(e, d) { 17 | if (e) { 18 | console.log(e); 19 | } else if (config.db.un != "" && config.db.pw != "") { 20 | db.authenticate(config.db.un, config.db.pw, function(err, result){ 21 | if (err) { 22 | console.log(err); 23 | } else { 24 | connected = true; 25 | } 26 | }); 27 | } else { 28 | connected = true; 29 | } 30 | if (connected) { 31 | console.log('connected to database :: '+config.db.name); 32 | } 33 | }) 34 | 35 | // CORE AUTHENTICATION LOOKUP 36 | var getCoreCredentials = function (id, callback) { 37 | // Core creds 38 | var credentials = {}; 39 | credentials[config.coreCreds.id] = { 40 | key: config.coreCreds.key, 41 | access: 'admin', 42 | algorithm: 'sha256' 43 | } 44 | 45 | // Just return with core creds if supplied 46 | if(credentials[id] !== undefined) { 47 | console.log('Core auth lookup: '+id+ ' >> valid'); 48 | return callback(null, credentials[id]); 49 | } else { 50 | console.log('Core auth lookup: '+id+ ' >> invalid'); 51 | return callback(null, null); 52 | } 53 | }; 54 | 55 | 56 | // WEB AUTHENTICATION LOOKUP 57 | var getCredentials = function (id, callback) { 58 | 59 | // Core creds 60 | var credentials = config.coreCreds; 61 | 62 | // Just return with core creds if supplied 63 | if(credentials[id] !== undefined) { 64 | console.log('Web auth lookup: '+id+ ' >> valid as core'); 65 | return callback(null, credentials[id]); 66 | } else { 67 | 68 | var collection = db 69 | .collection('users') 70 | .findOne({"_id": ObjectId(id)}, function(err, user) { 71 | if(err) throw err; 72 | 73 | var credentials = null; 74 | if(user) { 75 | console.log('Web auth lookup: '+id+ ' >> valid as '+user.access); 76 | credentials = { 77 | key: user.apiToken, 78 | access: user.access, 79 | algorithm: 'sha256' 80 | } 81 | } else { 82 | console.log('Web auth lookup: '+id+ ' >> invalid'); 83 | } 84 | 85 | return callback(null, credentials) 86 | }); 87 | } 88 | }; 89 | 90 | var goodOptions = { 91 | reporters: [{ 92 | reporter: require('good-console'), 93 | events: { ops: '*', response: '*', log: '*', error: '*' } 94 | }] 95 | }; 96 | 97 | apiServer.register([ 98 | { 99 | register: require('hapi-auth-hawk') 100 | }, 101 | { 102 | register: require('good'), 103 | options: goodOptions 104 | } 105 | ], function(err) { 106 | if (err) throw err; 107 | apiServer.auth.strategy('core', 'hawk', { getCredentialsFunc: getCoreCredentials }); 108 | apiServer.auth.strategy('web', 'hawk', { getCredentialsFunc: getCredentials }); 109 | }); 110 | 111 | // Endpoints 112 | apiServer.register([ 113 | { 114 | register: require('./User'), 115 | options: { 116 | db: db // passes the db connection to the plugin 117 | } 118 | } 119 | ], function(err) { 120 | if (err) throw err; 121 | }); 122 | 123 | if (!module.parent) { 124 | apiServer.start(function() { 125 | var message = 'API started at: ' + apiServer.info.uri; 126 | console.log(message); 127 | }); 128 | } 129 | 130 | module.exports = apiServer; 131 | -------------------------------------------------------------------------------- /servers/gui/auth/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "auth", 3 | "version": "0.0.0", 4 | "description": "Controls user stuff", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "smaxwellstewart", 10 | "license": "ISC" 11 | } 12 | -------------------------------------------------------------------------------- /servers/gui/config/plugins.js: -------------------------------------------------------------------------------- 1 | module.exports = function(server, config) { 2 | 3 | 4 | 5 | // DB Connection 6 | var MongoDB = require('mongodb').Db; 7 | var Server = require('mongodb').Server; 8 | 9 | var connected = false; 10 | var db = new MongoDB(config.db.name, new Server(config.db.host, config.db.port, {auto_reconnect: true}), {w: 1}); 11 | db.open(function(e, d) { 12 | if (e) { 13 | console.log(e); 14 | } else if (config.db.un != "" && config.db.pw != "") { 15 | db.authenticate(config.db.un, config.db.pw, function(err, result){ 16 | if (err) { 17 | console.log(err); 18 | } else { 19 | connected = true; 20 | } 21 | }); 22 | } else { 23 | connected = true; 24 | } 25 | if (connected) { 26 | console.log('connected to database :: '+config.db.name); 27 | } 28 | }) 29 | 30 | 31 | // Options to pass into the 'Good' plugin 32 | var goodOptions = { 33 | reporters: [{ 34 | reporter: require('good-console'), 35 | events: {ops: '*', response: '*', log: '*', error: '*'} 36 | }] 37 | }; 38 | // The Assets Configuaration Options 39 | var assetOptions = require('../../../assets'); 40 | 41 | // Add auth and start 42 | server.register([ 43 | { 44 | register: require('hapi-auth-cookie') 45 | } 46 | 47 | ], function(err) { 48 | if (err) throw err; 49 | // // Define auth strategy 50 | server.auth.strategy('session', 'cookie', { 51 | password: 'secret', 52 | cookie: 'sid-example', 53 | redirectTo: '/login', 54 | isSecure: false 55 | }); 56 | 57 | }); 58 | 59 | server.register([ 60 | // { 61 | // register: require("good"), 62 | // options: goodOptions 63 | // }, 64 | { 65 | register: require("hapi-assets"), 66 | options: assetOptions 67 | }, 68 | { 69 | register: require("hapi-named-routes") 70 | }, 71 | { 72 | register: require("hapi-cache-buster") 73 | }, 74 | { 75 | register: require('../auth'), 76 | options: { 77 | db: db, 78 | email: config.email, 79 | apiIP: config.api.host+':'+config.api.port, 80 | app: config.app, 81 | coreCreds: config.coreCreds 82 | } 83 | }, 84 | { 85 | register: require('../socketIO') 86 | } 87 | 88 | ], function(err) { 89 | if (err) throw err; 90 | }); 91 | }; 92 | -------------------------------------------------------------------------------- /servers/gui/config/routes.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Dependencies. 3 | */ 4 | var requireDirectory = require('require-directory'); 5 | 6 | module.exports = function(server) { 7 | // Bootstrap your controllers so you dont have to load them individually. This loads them all into the controller name space. https://github.com/troygoode/node-require-directory 8 | var controller = requireDirectory(module, '../controllers'); 9 | 10 | // Array of routes for Hapi 11 | var routeTable = [ 12 | { 13 | method: 'GET', 14 | path: '/', 15 | config: controller.base.index 16 | }, 17 | { 18 | method: 'GET', 19 | path: '/{path*}', 20 | config: controller.base.page 21 | }, 22 | { 23 | method: 'GET', 24 | path: '/partials/{path*}', 25 | config: controller.assets.partials 26 | }, 27 | { 28 | method: 'GET', 29 | path: '/img/{path*}', 30 | config: controller.assets.images 31 | }, 32 | { 33 | method: 'GET', 34 | path: '/css/{path*}', 35 | config: controller.assets.css 36 | }, 37 | { 38 | method: 'GET', 39 | path: '/fonts/{path*}', 40 | config: controller.assets.fonts 41 | }, 42 | { 43 | method: 'GET', 44 | path: '/js/{path*}', 45 | config: controller.assets.js 46 | }, 47 | { 48 | method: 'GET', 49 | path: '/bower_components/{path*}', 50 | config: controller.assets.bower 51 | } 52 | ]; 53 | return routeTable; 54 | } 55 | -------------------------------------------------------------------------------- /servers/gui/config/settings.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Dependencies. 3 | */ 4 | var path = require('path'), 5 | rootPath = path.normalize(__dirname + '/../../..'); 6 | 7 | // Defaults that you can access when you require this config. 8 | module.exports = { 9 | root: rootPath, 10 | port: parseInt(process.env.PORT, 10) || 3020, 11 | vision: { 12 | path: './servers/gui/views', 13 | engines: { 14 | html: require('swig') 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /servers/gui/controllers/assets.js: -------------------------------------------------------------------------------- 1 | // This is the assets controller. Goal is to serve css, js, partials, images, or bower packages. 2 | module.exports = { 3 | partials: { 4 | handler: { 5 | directory: { path: './server/views/partials' } 6 | }, 7 | app: { 8 | name: 'partials' 9 | } 10 | }, 11 | images: { 12 | handler: { 13 | directory: { path: './public/img' } 14 | }, 15 | app: { 16 | name: 'images' 17 | } 18 | }, 19 | css: { 20 | handler: { 21 | directory: { path: './public/css' } 22 | }, 23 | app: { 24 | name: 'css' 25 | } 26 | }, 27 | fonts: { 28 | handler: { 29 | directory: { path: './public/fonts' } 30 | }, 31 | app: { 32 | name: 'fonts' 33 | } 34 | }, 35 | js: { 36 | handler: { 37 | directory: { path: './public/js' } 38 | }, 39 | app: { 40 | name: 'js' 41 | } 42 | }, 43 | bower: { 44 | handler: { 45 | directory: { path: './public/bower_components' } 46 | }, 47 | app: { 48 | name: 'bower' 49 | } 50 | } 51 | } -------------------------------------------------------------------------------- /servers/gui/controllers/base.js: -------------------------------------------------------------------------------- 1 | var fs = require('fs'); 2 | var marked = require('marked'); 3 | // This is the base controller. Used for base routes, such as the default index/root path, 404 error pages, and others. 4 | module.exports = { 5 | index: { 6 | handler: function(request, reply){ 7 | var scripts = ""; 8 | var page = 'dashboard'; 9 | 10 | var markdown = fs.readFileSync(__dirname+'/../../../README.md', {encoding: 'utf8'}); 11 | 12 | // Render the view with the custom greeting 13 | reply.view('index', { 14 | title: 'Hapi Dash - Boiler Plate Dashboard', 15 | scripts: scripts, 16 | page: page, 17 | text: marked(markdown) 18 | }); 19 | }, 20 | app: { 21 | name: 'index' 22 | }, 23 | auth: { 24 | strategy: 'session' 25 | } 26 | }, 27 | page: { 28 | handler: function(request, reply){ 29 | var page = request.params.path; 30 | // Custom page specific scripts 31 | var scripts = ""; 32 | switch(page) { 33 | case "chat": 34 | scripts += ""; 35 | break; 36 | case "watable": 37 | scripts += ""; 38 | scripts += ""; 39 | scripts += ""; 40 | break; 41 | case "gallery": 42 | scripts += ""; 43 | scripts += ""; 44 | scripts += ""; 45 | break; 46 | case "chartjs": 47 | scripts += ""; 48 | break; 49 | case "morris": 50 | scripts += "\n"; 51 | scripts += ""; 52 | scripts += ""; 53 | scripts += ""; 54 | break; 55 | case "form-components": 56 | scripts += "\n"; 57 | scripts += "\n"; 58 | scripts += " \n"; 59 | break; 60 | case "to-do": 61 | scripts += "\n" 62 | scripts += "\n" 63 | scripts += "" 64 | break; 65 | case "panels": 66 | scripts += "\n"; 67 | scripts += "\n"; 68 | break; 69 | case "calendar": 70 | scripts += "\n"; 71 | break; 72 | default: 73 | scripts += ""; 74 | } 75 | 76 | 77 | if(fs.existsSync(__dirname +'/../views/'+page+'.html')) { 78 | reply.view(page, { 79 | title: 'Hapi Dash - Boiler Plate Dashboard', 80 | scripts: scripts, 81 | page: page 82 | }); 83 | } else { 84 | reply.view('404', { 85 | title: 'No page found!' 86 | }).code(404); 87 | } 88 | }, 89 | app: { 90 | name: 'about' 91 | }, 92 | auth: { 93 | strategy: 'session' 94 | } 95 | } 96 | } 97 | -------------------------------------------------------------------------------- /servers/gui/models/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kidtronnix/hapi-dash/217c8adf50dea947a19bc66a868bd738ccaf9c24/servers/gui/models/.gitkeep -------------------------------------------------------------------------------- /servers/gui/server.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Dependencies. 3 | */ 4 | var Hapi = require('hapi'), 5 | settings = require('./config/settings'), 6 | config = require('../../config'); 7 | 8 | // Create a server with a host, port, and options 9 | var server = new Hapi.Server({ 10 | debug: { 11 | request: ['error'], 12 | log: ['error'], 13 | } 14 | }); 15 | 16 | server.connection({ host: config.gui.host, port: config.gui.port }); 17 | 18 | // Bootstrap Hapi Server Plugins, passes the server object to the plugins 19 | require('./config/plugins')(server, config); 20 | 21 | // Require the routes and pass the server object. 22 | var routes = require('./config/routes')(server); 23 | 24 | 25 | server.register([require('vision'), require('inert')], function(err) { 26 | if (err) throw err; 27 | 28 | server.views(settings.vision); 29 | 30 | // Add the server routes 31 | server.route(routes); 32 | 33 | if (!module.parent) { 34 | server.start(function() { 35 | var message = 'GUI started at: ' + server.info.uri; 36 | console.log(message); 37 | }); 38 | } 39 | }); 40 | 41 | 42 | 43 | 44 | module.exports = server; 45 | -------------------------------------------------------------------------------- /servers/gui/socketIO/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |Looks like you got a 404.
10 |This is an about page. Have a look around.
13 | {% endblock %} -------------------------------------------------------------------------------- /servers/gui/views/blank.html: -------------------------------------------------------------------------------- 1 | {% extends './layouts/default.html' %} 2 | 3 | {% block title %}{{ title }}{% endblock %} 4 | 5 | {% block content %} 6 |{% autoescape false %}{{ text }}{% endautoescape %}
15 |