enabled: true,
requireBase: false
})
- $urlRouterProvider.otherwise('/board/new')
+ $urlRouterProvider.otherwise('/')
$httpProvider.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest'
})
--- /dev/null
+'use strict';
+
+angular.module('zephyrApp')
+.controller('LoginController', function ($scope, $modal, Restangular, $state) {
+
+
+});
--- /dev/null
+body {
+ /*padding-top: 40px;*/
+ /*padding-bottom: 40px;*/
+ background-color: #eee;
+}
+
+.form-signin {
+ max-width: 330px;
+ padding: 15px;
+ margin: 0 auto;
+}
+.form-signin .form-signin-heading,
+.form-signin .checkbox {
+ margin-bottom: 10px;
+}
+.form-signin .checkbox {
+ font-weight: normal;
+}
+.form-signin .form-control {
+ position: relative;
+ height: auto;
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+ padding: 10px;
+ font-size: 16px;
+}
+.form-signin .form-control:focus {
+ z-index: 2;
+}
+.form-signin input[type="email"] {
+ margin-bottom: -1px;
+ border-bottom-right-radius: 0;
+ border-bottom-left-radius: 0;
+}
+.form-signin input[type="password"] {
+ margin-bottom: 10px;
+ border-top-left-radius: 0;
+ border-top-right-radius: 0;
+}
+
--- /dev/null
+<div class="container">
+
+<form class="form-signin" method="post" action="/auth/login" ng-model="auth" >
+ <h2 class="form-signin-heading">Login</h2>
+ <label for="inputEmail" class="sr-only">Email address</label>
+ <input type="email" id="inputEmail" class="form-control" placeholder="Email address" required autofocus>
+ <label for="inputPassword" class="sr-only">Password</label>
+ <input type="password" id="inputPassword" class="form-control" placeholder="Password" required>
+ <div class="checkbox">
+ <label>
+ <input type="checkbox" value="remember-me"> Remember me
+ </label>
+ </div>
+ <button class="btn btn-lg btn-primary btn-block" type="submit">Sign in</button>
+</form>
+
+</div>
--- /dev/null
+'use strict';
+
+angular.module('zephyrApp')
+.config(function($stateProvider) {
+ $stateProvider
+ .state('login', {
+ url:'/',
+ templateUrl:'/client/app/components/login/login.html',
+ controller: 'LoginController',
+ css: '/client/app/components/login/login.css'
+ })
+ /*
+ .state('note', {
+ url: '/board/:note'
+ //templateUrl:'/client/app/components/board/board.html',
+ //controller: 'BoardController'
+ })
+ */
+});
<link rel="stylesheet" href="/client/assets/vendor/bootstrap.min.css">
<link rel="stylesheet" href="/client/assets/vendor/font-awesome.min.css">
<!-- endinject -->
+ <!-- components:css -->
+ <link rel="stylesheet" href="/client/app/components/login/login.css">
+ <!-- endinject -->
</head>
<body ng-app="zephyrApp">
<div ui-view></div>
<!-- endinject -->
<!-- shared:js -->
- <script src="/client/app/shared/navbar/navbar.controller.js"></script>
- <script src="/client/app/shared/navbar/navbar.directive.js"></script>
<script src="/client/app/shared/my-command/my-command.controller.js"></script>
<script src="/client/app/shared/my-command/my-command.js"></script>
+ <script src="/client/app/shared/navbar/navbar.controller.js"></script>
+ <script src="/client/app/shared/navbar/navbar.directive.js"></script>
<script src="/client/app/shared/tagFileter/tagFilter.filter.js"></script>
<!-- endinject -->
<!-- components:js -->
<script src="/client/app/components/board/board.controller.js"></script>
<script src="/client/app/components/board/board.js"></script>
+ <script src="/client/app/components/commandModal/commandModal.controller.js"></script>
+ <script src="/client/app/components/login/login.controller.js"></script>
+ <script src="/client/app/components/login/login.js"></script>
<script src="/client/app/components/notes/notes.controller.js"></script>
<script src="/client/app/components/notes/notes.js"></script>
- <script src="/client/app/components/commandModal/commandModal.controller.js"></script>
<script src="/client/app/components/previewModal/previewModal.controller.js"></script>
<script src="/client/app/components/saveFileModal/saveFileModal.controller.js"></script>
<script src="/client/app/components/workspace/workspace.controller.js"></script>
vendor : ['./client/assets/vendor/*.js', './client/assets/vendor/*.css'],
app : ['./client/app/*.js'],
shared : ['./client/app/shared/**/*.js'],
- components : ['./client/app/components/**/*.js'],
+ components : ['./client/app/components/**/*.js', './client/app/components/**/*.css'],
templates : ['./client/app/**/*.html']
};
"ejs": "^2.3.1",
"express": "^4.12.3",
"lodash": "^3.8.0",
+ "passport": "^0.2.2",
+ "sqlite3": "^3.0.9",
"thunkify": "^2.1.2"
},
"devDependencies": {
--- /dev/null
+'use strict'
+
+var express = require('express'),
+ router = express.Router(),
+ path = require('path')
+
+router.post('/', function(req, res) {
+ console.log(req)
+ res.sendStatus(401)
+})
+
+module.exports = router
app.use('/api/commandExecution', require('./api/commandExecution'))
app.use('/api/noteCreation', require('./api/noteCreation'))
app.use('/api/noteInfo', require('./api/noteInfo'))
+ app.use('/auth/login', require('./auth/login'))
app.route('/*')
.get(function(req, res) {
if(app.get('env') === 'development') {