forked from silverbux/laravel-angular-admin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
201 changed files
with
11,842 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
engines: | ||
eslint: | ||
enabled: true | ||
ratings: | ||
paths: | ||
- angular/** | ||
- "**.js" | ||
languages: | ||
Ruby: false | ||
JavaScript: true | ||
PHP: true | ||
Python: false | ||
exclude_paths: | ||
- "public/js/vendor.js" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
indent_style = space | ||
indent_size = 4 | ||
trim_trailing_whitespace = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
|
||
|
||
[{package.json,bower.json,.jscs.json}] | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
|
||
[*.yml] | ||
indent_style = space | ||
indent_size = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
APP_ENV=local | ||
APP_DEBUG=true | ||
APP_KEY=SomeRandomString | ||
|
||
API_PREFIX=api | ||
|
||
DB_HOST=127.0.0.1 | ||
DB_DATABASE=homestead | ||
DB_USERNAME=homestead | ||
DB_PASSWORD=secret | ||
|
||
CACHE_DRIVER=file | ||
SESSION_DRIVER=file | ||
QUEUE_DRIVER=sync | ||
|
||
REDIS_HOST=127.0.0.1 | ||
REDIS_PASSWORD=null | ||
REDIS_PORT=6379 | ||
|
||
MAIL_DRIVER=smtp | ||
MAIL_HOST=mailtrap.io | ||
MAIL_PORT=2525 | ||
MAIL_USERNAME=null | ||
MAIL_PASSWORD=null | ||
MAIL_ENCRYPTION=null | ||
|
||
GITHUB_CLIENT_ID = null | ||
GITHUB_CLIENT_SECRET = null | ||
GITHUB_REDIRECT = http://yourdomain.com/auth/github/callback | ||
|
||
GOOGLE_CLIENT_ID = null | ||
GOOGLE_CLIENT_SECRET = null | ||
GOOGLE_REDIRECT = http://yourdomain.com/auth/google/callback | ||
|
||
FACEBOOK_CLIENT_ID = null | ||
FACEBOOK_CLIENT_SECRET = null | ||
FACEBOOK_REDIRECT = http://yourdomain.com/auth/facebook/callback |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"extends": "eslint:recommended", | ||
"plugins": ["angular"], | ||
"rules": { | ||
"angular/no-service-method": 0 | ||
}, | ||
"env": { | ||
"es6": true, | ||
"browser": true, | ||
"jasmine": true | ||
}, | ||
"ecmaFeatures": { | ||
"modules": true | ||
}, | ||
"globals": { | ||
"angular": true, | ||
"module": true, | ||
"inject": true | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
* text=auto | ||
*.css linguist-vendored | ||
*.less linguist-vendored |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# OS generated files | ||
.DS_Store | ||
.DS_Store? | ||
._* | ||
.Spotlight-V100 | ||
.Trashes | ||
ehthumbs.db | ||
Thumbs.db | ||
|
||
# Logs and databases | ||
*.log | ||
*.sql | ||
*.sqlite | ||
|
||
/vendor | ||
/node_modules | ||
Homestead.yaml | ||
Homestead.json | ||
.env | ||
.idea/ | ||
/bower_components | ||
npm-debug.log | ||
public/storage | ||
public/views | ||
public/js | ||
public/fonts | ||
public/css | ||
public/build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
language: php | ||
|
||
php: | ||
- 5.5.9 | ||
- 5.5 | ||
- 5.6 | ||
- 7.0 | ||
- hhvm | ||
|
||
sudo: false | ||
|
||
services: | ||
- mysql | ||
|
||
before_install: | ||
- nvm install 5.1 | ||
|
||
before_script: | ||
- mysql -e 'create database laravel;' | ||
- export DB_DATABASE=laravel | ||
- export DB_USERNAME=travis | ||
- export DB_PASSWORD= | ||
|
||
script: npm install -g gulp bower && npm install && bower install && php artisan migrate --force && gulp && vendor/bin/phpunit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
### v0.0.1 | ||
|
||
+ Initial Commit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,85 @@ | ||
# laravel-angular-admin | ||
# Laravel Angular Admin | ||
Laravel + Angularjs + Bootstrap + AdminLTE binded by Gulp workflow Admin Dashboard Boilerplate. | ||
Plus with social media and JWT authentication on the side. | ||
|
||
## Screenshots | ||
 | ||
|
||
 | ||
|
||
## Demo | ||
[Click here for a live demo](http://laravel-admin.herokuapp.com) | ||
|
||
## Installation | ||
``` | ||
$ composer install | ||
$ npm install -g gulp bower | ||
$ npm install && bower install | ||
$ gulp | ||
``` | ||
|
||
Copy ```.env.example``` to ```.env``` and enter necessary config for DB and Oauth Providers Settings. | ||
|
||
``` | ||
$ php artisan migrate | ||
``` | ||
|
||
## Work Flow | ||
|
||
**General Workflow** | ||
|
||
``` | ||
$ gulp && gulp watch | ||
$ php artisan serve | ||
``` | ||
|
||
**Watching assets** | ||
|
||
``` | ||
$ gulp && gulp watch | ||
``` | ||
|
||
**Angular Generators** | ||
|
||
``` | ||
$ artisan ng:page name #New page inside angular/app/pages/ | ||
$ artisan ng:dialog name #New custom dialog inside angular/dialogs/ | ||
$ artisan ng:component name #New component inside angular/app/components/ | ||
$ artisan ng:service name #New service inside angular/services/ | ||
$ artisan ng:filter name #New filter inside angular/filters/ | ||
$ artisan ng:config name #New config inside angular/config/ | ||
``` | ||
[Laravel Angular Generator] (https://github.com/jadjoubran/laravel-ng-artisan-generators) | ||
|
||
#### More docs to come... | ||
|
||
## Features | ||
* [JWT-Auth] (https://github.com/tymondesigns/jwt-auth) | ||
* [Socialite] (https://github.com/laravel/socialite) | ||
* [Dingo/API] (https://github.com/dingo/api) | ||
* [Restangular] (https://github.com/mgonto/restangular) | ||
* [UI-Router] (https://github.com/angular-ui/ui-router/) | ||
|
||
## Built With | ||
* [Laravel] (http://laravel.com) | ||
* [Angularjs] (https://angularjs.org) | ||
* [Twitter Bootstrap] (https://getbootstrap.com) | ||
* [Composer] (https://getcomposer.org/) | ||
* [Gulp.JS] (http://gulpjs.com/) | ||
* [BOWER] (http://bower.io/) | ||
* [NPM] (https://www.npmjs.com/) | ||
|
||
## Contributing | ||
|
||
Please read [code_of_conduct.md](code_of_conduct.md) for details on our code of conduct, and the process for submitting pull requests to us. | ||
|
||
## Acknowledgments / Credits | ||
This project wont be possible without the following, We acknowledge and are grateful to these developers for their contributions to open source. **All necessary credits are given**. | ||
|
||
* [Laravel-Angular (Material)] (https://laravel-angular.readme.io) | ||
* [AdminLTE] (https://laravel-angular.readme.io) | ||
|
||
## License | ||
|
||
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details |
Empty file.
12 changes: 12 additions & 0 deletions
12
angular/app/components/create_post_form/create_post_form.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<form ng-submit="vm.submit()"> | ||
<md-input-container> | ||
<label>Name</label> | ||
<input type="text" ng-model="vm.name"> | ||
</md-input-container> | ||
|
||
<md-input-container> | ||
<label>Topic</label> | ||
<input type="text" ng-model="vm.topic"> | ||
</md-input-container> | ||
<md-button type="submit" class="md-primary md-raised">Create post</md-button> | ||
</form> |
26 changes: 26 additions & 0 deletions
26
angular/app/components/create_post_form/create_post_form.component.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
class CreatePostFormController{ | ||
constructor(API, ToastService){ | ||
'ngInject'; | ||
|
||
this.API = API; | ||
this.ToastService = ToastService; | ||
} | ||
|
||
submit(){ | ||
var data = { | ||
name: this.name, | ||
topic: this.topic, | ||
}; | ||
|
||
this.API.all('posts').post(data).then((response) => { | ||
this.ToastService.show('Post added successfully'); | ||
}); | ||
} | ||
} | ||
|
||
export const CreatePostFormComponent = { | ||
templateUrl: './views/app/components/create_post_form/create_post_form.component.html', | ||
controller: CreatePostFormController, | ||
controllerAs: 'vm', | ||
bindings: {} | ||
} |
Empty file.
39 changes: 39 additions & 0 deletions
39
angular/app/components/login-form/login-form.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<form ng-submit="vm.login()" method="post"> | ||
<div class="callout callout-danger" ng-if="vm.loginfailed"> | ||
<h4>Login Failed</h4> | ||
<p>Incorrect Email/Username or Password.</p> | ||
</div> | ||
<div class="callout callout-success" ng-if="vm.registerSuccess"> | ||
<h4>Registration Success!</h4> | ||
<p>A verification link has been sent to your Email Account. Thank You!</p> | ||
</div> | ||
<div class="form-group has-feedback"> | ||
<input type="email" class="form-control" placeholder="Email" ng-model="vm.email"> | ||
<span class="glyphicon glyphicon-envelope form-control-feedback"></span> | ||
</div> | ||
<div class="form-group has-feedback"> | ||
<input type="password" class="form-control" placeholder="Password" ng-model="vm.password"> | ||
<span class="glyphicon glyphicon-lock form-control-feedback"></span> | ||
</div> | ||
<div class="row"> | ||
<div class="col-xs-8"> | ||
<div class="checkbox icheck"> | ||
<label> | ||
<input type="checkbox"> Remember Me | ||
</label> | ||
</div> | ||
</div> | ||
<div class="col-xs-4"> | ||
<button type="submit" class="btn btn-primary btn-block btn-flat">Sign In</button> | ||
</div> | ||
</div> | ||
</form> | ||
<div class="social-auth-links text-center"> | ||
<p>- OR -</p> | ||
<a href="/auth/github" class="btn btn-block btn-social btn-github btn-flat"><i class="fa fa-github"></i> Sign in using Github+</a> | ||
<a href="/auth/google" class="btn btn-block btn-social btn-google btn-flat"><i class="fa fa-google"></i> Sign in using Google</a> | ||
<a href="/auth/facebook" class="btn btn-block btn-social btn-facebook btn-flat"><i class="fa fa-facebook"></i> Sign in using Facebook</a> | ||
</div> | ||
<a href="#">I forgot my password</a> | ||
<br> | ||
<a ui-sref="app.register" class="text-center">Register a new membership</a> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
class LoginFormController { | ||
constructor($auth, $state, $stateParams, API) { | ||
'ngInject'; | ||
|
||
this.$auth = $auth; | ||
this.$state = $state; | ||
this.$stateParams = $stateParams; | ||
|
||
this.registerSuccess = $stateParams.registerSuccess; | ||
this.loginfailed = false; | ||
this.email = ''; | ||
this.password = ''; | ||
} | ||
|
||
login() { | ||
var user = { | ||
email: this.email, | ||
password: this.password | ||
}; | ||
|
||
this.$auth.login(user) | ||
.then((response) => { | ||
this.$auth.setToken(response.data); | ||
this.$state.go('app.landing') | ||
}) | ||
.catch(this.failedLogin.bind(this)); | ||
} | ||
|
||
failedLogin(response) { | ||
this.loginfailed = true; | ||
} | ||
} | ||
|
||
export const LoginFormComponent = { | ||
templateUrl: './views/app/components/login-form/login-form.component.html', | ||
controller: LoginFormController, | ||
controllerAs: 'vm', | ||
bindings: {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
.btn-github:hover { | ||
color: #fff | ||
} | ||
|
||
.btn-facebook:hover { | ||
color: #fff | ||
} | ||
|
||
.btn-google:hover { | ||
color: #fff | ||
} |
1 change: 1 addition & 0 deletions
1
angular/app/components/login-loader/login-loader.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Logging in... |
Oops, something went wrong.