diff --git a/app/Http/Controllers/GithubController.php b/app/Http/Controllers/GithubController.php index 0d65b5b8..964cf62c 100644 --- a/app/Http/Controllers/GithubController.php +++ b/app/Http/Controllers/GithubController.php @@ -2,10 +2,10 @@ namespace App\Http\Controllers; -use App\Notification; +use App\Org; use App\Repo; use Auth; -use GrahamCampbell\GitHub\Facades\GitHub; +use GitHub; class GithubController extends Controller { @@ -14,118 +14,81 @@ public function __construct() $this->middleware('auth'); } - public function getNotifications() + public function syncOrgs() { - Github::authenticate(Auth::user()->token, null, 'http_token'); - $notifications = GitHub::api('notification')->all(); - $this->storeNotifications($notifications); - $this->storeRepos($notifications); - - return redirect('notifications'); + $this->listOrgs(); + $this->checkPerm(); + return redirect('dashboard'); } - public function getNotification($id) + public function listOrgs() { Github::authenticate(Auth::user()->token, null, 'http_token'); - $notification = GitHub::api('notification')->id($id); - $type = ($notification['subject'])['type']; - $url = ($notification['subject'])['url']; - $processed_url = explode('/', $url); - $user = $processed_url[4]; - $repo = $processed_url[5]; - $id = $processed_url[7]; - if ($type == 'PullRequest') { - $pullRequest = $this->getPR($user, $repo, $id); - - return redirect($pullRequest['html_url']); - } elseif ($type == 'Issue') { - $issue = $this->getIssue($user, $repo, $id); - - return redirect($issue['html_url']); - } elseif ($type == 'Commit') { - $commit = $this->getCommit($user, $repo, $id); - - return redirect($commit['html_url']); - } elseif ($type == 'Release') { - $release = $this->getRelease($user, $repo, $id); + $orgs = GitHub::api('user')->orgs(); + $this->storeOrgs($orgs); + } - return redirect($release['html_url']); - } else { - return redirect('wip'); + public function storeOrgs($orgs) + { + foreach ($orgs as $organization) { + if (!Org::where('id', '=', $organization['id'])->exists()) { + if (Org::find($organization['id']) == null) { + $org = new Org(); + $org->id = $organization['id']; + $org->name = $organization['login']; + $org->url = $organization['url']; + $org->description = $organization['description']; + $org->avatar = $organization['avatar_url']; + $org->userid = Auth::id(); + $org->username = Auth::user()->github_username; + $org->save(); + } + } } } - public function getIssue($user, $repo, $id) + public function checkPerm() { Github::authenticate(Auth::user()->token, null, 'http_token'); - $issue = Github::api('issue')->show($user, $repo, $id); - - return $issue; + $orgs = Org::where('userid', '=', Auth::id())->get(); + foreach ($orgs as $organization) { + if ($organization->role != 'admin') { + $membership = GitHub::api('organizations')->members()->member($organization->name, $organization->username); + $organization->role = $membership['role']; + $organization->save(); + } + } } - public function getPR($user, $repo, $id) + public function getReferers($id) { Github::authenticate(Auth::user()->token, null, 'http_token'); - $pullRequest = Github::api('pull_request')->show($user, $repo, $id); + $repo = Repo::find($id); - return $pullRequest; + return Github::api('repo')->traffic()->referers($repo->owner, $repo->name); } - public function getCommit($user, $repo, $id) + public function getPaths($id) { Github::authenticate(Auth::user()->token, null, 'http_token'); - $commit = Github::api('repo')->commits()->show($user, $repo, $id); + $repo = Repo::find($id); - return $commit; + return Github::api('repo')->traffic()->paths($repo->owner, $repo->name); } - public function getRelease($user, $repo, $id) + public function getViews($id) { Github::authenticate(Auth::user()->token, null, 'http_token'); - $release = Github::api('repo')->releases()->show($user, $repo, $id); + $repo = Repo::find($id); - return $release; + return Github::api('repo')->traffic()->views($repo->owner, $repo->name); } - public function storeNotifications($notifications) + public function getClones($id) { - foreach ($notifications as $rawnotif) { - if (!Notification::where('id', '=', $rawnotif['id'])->exists()) { - $subject = $rawnotif['subject']; - $repo = $rawnotif['repository']; - $notification = new Notification(); - $notification->id = $rawnotif['id']; - $notification->unread = $rawnotif['unread']; - $notification->reason = $rawnotif['reason']; - $notification->title = $subject['title']; - $notification->url = $subject['url']; - $notification->type = $subject['type']; - $notification->private = $repo['private']; - $notification->repoid = $repo['id']; - $notification->userid = Auth::user()->id; - $notification->save(); - } - } - } + Github::authenticate(Auth::user()->token, null, 'http_token'); + $repo = Repo::find($id); - public function storeRepos($notifications) - { - foreach ($notifications as $notification) { - $repo = $notification['repository']; - if (!Repo::where('id', '=', $repo['id'])->exists()) { - $user = $repo['owner']; - if (Repo::find($repo['id']) == null) { - $repository = new Repo(); - $repository->id = $repo['id']; - $repository->name = $repo['name']; - $repository->full_name = $repo['full_name']; - $repository->owner = $user['login']; - $repository->html_url = $repo['html_url']; - $repository->description = $repo['description']; - $repository->userid = Auth::user()->id; - $repository->save(); - } - } - } + return Github::api('repo')->traffic()->clones($repo->owner, $repo->name); } } diff --git a/app/Http/Controllers/LoginController.php b/app/Http/Controllers/LoginController.php index 41a2ec02..b3b38ab4 100644 --- a/app/Http/Controllers/LoginController.php +++ b/app/Http/Controllers/LoginController.php @@ -28,6 +28,7 @@ public function loginUser(Request $request) $user->email = $details->email; $user->name = $details->full_name; $user->token = $details->access_token; + $user->github_username = $details->nickname; $user->save(); }); } catch (ApplicationRejectedException $e) { diff --git a/app/Org.php b/app/Org.php new file mode 100644 index 00000000..4b2b9816 --- /dev/null +++ b/app/Org.php @@ -0,0 +1,10 @@ +hasMany('App\Org', 'userid'); + } } diff --git a/composer.json b/composer.json index ac74cf1b..97651238 100755 --- a/composer.json +++ b/composer.json @@ -7,7 +7,10 @@ "require": { "php": ">=5.6.4", "adamwathan/eloquent-oauth-l5": "^0.5.1", - "laravel/framework": "5.3.*" + "graham-campbell/github": "^5.1", + "laravel/framework": "5.3.*", + "m1guelpf/github-api": "dev-packagist", + "php-http/guzzle6-adapter": "^1.1" }, "require-dev": { "fzaninotto/faker": "~1.4", diff --git a/composer.lock b/composer.lock old mode 100755 new mode 100644 index bf208b2c..7f4e6be6 --- a/composer.lock +++ b/composer.lock @@ -4,8 +4,8 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "hash": "e30a1cb488f568ae2ecd636fe30f1a9b", - "content-hash": "6346f75eaaf5d85d97bcd1c0f0e2dcb0", + "hash": "d421c0030df90ebbdaf62160acc95659", + "content-hash": "ecf5342ba853e096da32fe709c085529", "packages": [ { "name": "adamwathan/eloquent-oauth", @@ -158,6 +158,55 @@ ], "time": "2016-09-16 12:50:15" }, + { + "name": "clue/stream-filter", + "version": "v1.3.0", + "source": { + "type": "git", + "url": "https://github.com/clue/php-stream-filter.git", + "reference": "e3bf9415da163d9ad6701dccb407ed501ae69785" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/clue/php-stream-filter/zipball/e3bf9415da163d9ad6701dccb407ed501ae69785", + "reference": "e3bf9415da163d9ad6701dccb407ed501ae69785", + "shasum": "" + }, + "require": { + "php": ">=5.3" + }, + "type": "library", + "autoload": { + "psr-4": { + "Clue\\StreamFilter\\": "src/" + }, + "files": [ + "src/functions.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Christian Lück", + "email": "christian@lueck.tv" + } + ], + "description": "A simple and modern approach to stream filtering in PHP", + "homepage": "https://github.com/clue/php-stream-filter", + "keywords": [ + "bucket brigade", + "callback", + "filter", + "php_user_filter", + "stream", + "stream_filter_append", + "stream_filter_register" + ], + "time": "2015-11-08 23:41:30" + }, { "name": "dnoegel/php-xdg-base-dir", "version": "0.1", @@ -258,6 +307,133 @@ ], "time": "2015-11-06 14:35:42" }, + { + "name": "graham-campbell/github", + "version": "v5.1.0", + "source": { + "type": "git", + "url": "https://github.com/GrahamCampbell/Laravel-GitHub.git", + "reference": "47b968c60f9d2a2f0cf3a61f86b61c9375dc4b13" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/GrahamCampbell/Laravel-GitHub/zipball/47b968c60f9d2a2f0cf3a61f86b61c9375dc4b13", + "reference": "47b968c60f9d2a2f0cf3a61f86b61c9375dc4b13", + "shasum": "" + }, + "require": { + "graham-campbell/manager": "^2.3", + "illuminate/contracts": "5.1.*|5.2.*|5.3.*|5.4.*", + "illuminate/support": "5.1.*|5.2.*|5.3.*|5.4.*", + "m1guelpf/github-api": "dev-packagist", + "php": ">=5.5.9" + }, + "require-dev": { + "graham-campbell/testbench": "^3.1", + "madewithlove/illuminate-psr-cache-bridge": "^1.0", + "mockery/mockery": "^0.9.4", + "php-http/guzzle6-adapter": "^1.0", + "phpunit/phpunit": "^4.8|^5.0" + }, + "suggest": { + "madewithlove/illuminate-psr-cache-bridge": "Allows caching GitHub HTTP requests" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.1-dev" + } + }, + "autoload": { + "psr-4": { + "GrahamCampbell\\GitHub\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" + } + ], + "description": "GitHub Is A GitHub Bridge For Laravel 5", + "keywords": [ + "Bridge", + "Graham Campbell", + "GrahamCampbell", + "Laravel GitHub", + "Laravel-GitHub", + "PHP GitHub API", + "framework", + "github", + "github bridge", + "laravel", + "php-github-api" + ], + "time": "2017-01-01 13:32:28" + }, + { + "name": "graham-campbell/manager", + "version": "v2.5.0", + "source": { + "type": "git", + "url": "https://github.com/GrahamCampbell/Laravel-Manager.git", + "reference": "e6ab47a8971da6fd18bc7ced546f0d24cb7ebe3a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/GrahamCampbell/Laravel-Manager/zipball/e6ab47a8971da6fd18bc7ced546f0d24cb7ebe3a", + "reference": "e6ab47a8971da6fd18bc7ced546f0d24cb7ebe3a", + "shasum": "" + }, + "require": { + "illuminate/contracts": "5.1.*|5.2.*|5.3.*|5.4.*", + "illuminate/support": "5.1.*|5.2.*|5.3.*|5.4.*", + "php": ">=5.5.9" + }, + "require-dev": { + "graham-campbell/testbench-core": "^1.1", + "mockery/mockery": "^0.9.4", + "phpunit/phpunit": "^4.8|^5.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.5-dev" + } + }, + "autoload": { + "psr-4": { + "GrahamCampbell\\Manager\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" + } + ], + "description": "Manager Provides Some Manager Functionality For Laravel 5", + "keywords": [ + "Graham Campbell", + "GrahamCampbell", + "Laravel Manager", + "Laravel-Manager", + "connector", + "framework", + "interface", + "laravel", + "manager" + ], + "time": "2017-01-01 13:08:54" + }, { "name": "guzzlehttp/guzzle", "version": "6.2.2", @@ -745,12 +921,603 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1-dev" + "dev-master": "1.1-dev" + } + }, + "autoload": { + "psr-4": { + "League\\Flysystem\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Frank de Jonge", + "email": "info@frenky.net" + } + ], + "description": "Filesystem abstraction: Many filesystems, one API.", + "keywords": [ + "Cloud Files", + "WebDAV", + "abstraction", + "aws", + "cloud", + "copy.com", + "dropbox", + "file systems", + "files", + "filesystem", + "filesystems", + "ftp", + "rackspace", + "remote", + "s3", + "sftp", + "storage" + ], + "time": "2016-10-19 20:38:46" + }, + { + "name": "m1guelpf/github-api", + "version": "dev-packagist", + "source": { + "type": "git", + "url": "https://github.com/m1guelpf/php-github-api.git", + "reference": "a7c357385d026a91cdce905a8599235cb333a47a" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/m1guelpf/php-github-api/zipball/a7c357385d026a91cdce905a8599235cb333a47a", + "reference": "a7c357385d026a91cdce905a8599235cb333a47a", + "shasum": "" + }, + "require": { + "php": "^5.5 || ^7.0", + "php-http/cache-plugin": "^1.2", + "php-http/client-common": "^1.3", + "php-http/client-implementation": "^1.0", + "php-http/discovery": "^1.0", + "php-http/httplug": "^1.1", + "psr/cache": "^1.0", + "psr/http-message": "^1.0" + }, + "replace": { + "knplabs/github-api": "dev-master" + }, + "require-dev": { + "guzzlehttp/psr7": "^1.2", + "php-http/guzzle6-adapter": "^1.0", + "phpunit/phpunit": "^4.0 || ^5.5", + "sllh/php-cs-fixer-styleci-bridge": "^1.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Github\\": "lib/Github/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Thibault Duplessis", + "email": "thibault.duplessis@gmail.com", + "homepage": "http://ornicar.github.com" + }, + { + "name": "KnpLabs Team", + "homepage": "http://knplabs.com" + }, + { + "name": "Miguel Piedrafita", + "email": "soy@miguelpiedrafita.com", + "homepage": "https://miguelpiedrafita.com" + } + ], + "description": "GitHub API v3 client", + "homepage": "https://github.com/m1guelpf/php-github-api", + "keywords": [ + "api", + "gh", + "gist", + "github" + ], + "time": "2017-01-14 11:57:38" + }, + { + "name": "monolog/monolog", + "version": "1.22.0", + "source": { + "type": "git", + "url": "https://github.com/Seldaek/monolog.git", + "reference": "bad29cb8d18ab0315e6c477751418a82c850d558" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Seldaek/monolog/zipball/bad29cb8d18ab0315e6c477751418a82c850d558", + "reference": "bad29cb8d18ab0315e6c477751418a82c850d558", + "shasum": "" + }, + "require": { + "php": ">=5.3.0", + "psr/log": "~1.0" + }, + "provide": { + "psr/log-implementation": "1.0.0" + }, + "require-dev": { + "aws/aws-sdk-php": "^2.4.9 || ^3.0", + "doctrine/couchdb": "~1.0@dev", + "graylog2/gelf-php": "~1.0", + "jakub-onderka/php-parallel-lint": "0.9", + "php-amqplib/php-amqplib": "~2.4", + "php-console/php-console": "^3.1.3", + "phpunit/phpunit": "~4.5", + "phpunit/phpunit-mock-objects": "2.3.0", + "ruflin/elastica": ">=0.90 <3.0", + "sentry/sentry": "^0.13", + "swiftmailer/swiftmailer": "~5.3" + }, + "suggest": { + "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", + "doctrine/couchdb": "Allow sending log messages to a CouchDB server", + "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", + "ext-mongo": "Allow sending log messages to a MongoDB server", + "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", + "mongodb/mongodb": "Allow sending log messages to a MongoDB server via PHP Driver", + "php-amqplib/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib", + "php-console/php-console": "Allow sending log messages to Google Chrome", + "rollbar/rollbar": "Allow sending log messages to Rollbar", + "ruflin/elastica": "Allow sending log messages to an Elastic Search server", + "sentry/sentry": "Allow sending log messages to a Sentry server" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "psr-4": { + "Monolog\\": "src/Monolog" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "Sends your logs to files, sockets, inboxes, databases and various web services", + "homepage": "http://github.com/Seldaek/monolog", + "keywords": [ + "log", + "logging", + "psr-3" + ], + "time": "2016-11-26 00:15:39" + }, + { + "name": "mtdowling/cron-expression", + "version": "v1.1.0", + "source": { + "type": "git", + "url": "https://github.com/mtdowling/cron-expression.git", + "reference": "c9ee7886f5a12902b225a1a12f36bb45f9ab89e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/mtdowling/cron-expression/zipball/c9ee7886f5a12902b225a1a12f36bb45f9ab89e5", + "reference": "c9ee7886f5a12902b225a1a12f36bb45f9ab89e5", + "shasum": "" + }, + "require": { + "php": ">=5.3.2" + }, + "require-dev": { + "phpunit/phpunit": "~4.0|~5.0" + }, + "type": "library", + "autoload": { + "psr-0": { + "Cron": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https://github.com/mtdowling" + } + ], + "description": "CRON for PHP: Calculate the next or previous run date and determine if a CRON expression is due", + "keywords": [ + "cron", + "schedule" + ], + "time": "2016-01-26 21:23:30" + }, + { + "name": "nesbot/carbon", + "version": "1.21.0", + "source": { + "type": "git", + "url": "https://github.com/briannesbitt/Carbon.git", + "reference": "7b08ec6f75791e130012f206e3f7b0e76e18e3d7" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/7b08ec6f75791e130012f206e3f7b0e76e18e3d7", + "reference": "7b08ec6f75791e130012f206e3f7b0e76e18e3d7", + "shasum": "" + }, + "require": { + "php": ">=5.3.0", + "symfony/translation": "~2.6|~3.0" + }, + "require-dev": { + "phpunit/phpunit": "~4.0|~5.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "Carbon\\": "src/Carbon/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Brian Nesbitt", + "email": "brian@nesbot.com", + "homepage": "http://nesbot.com" + } + ], + "description": "A simple API extension for DateTime.", + "homepage": "http://carbon.nesbot.com", + "keywords": [ + "date", + "datetime", + "time" + ], + "time": "2015-11-04 20:07:17" + }, + { + "name": "nikic/php-parser", + "version": "v3.0.2", + "source": { + "type": "git", + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "adf44419c0fc014a0f191db6f89d3e55d4211744" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/adf44419c0fc014a0f191db6f89d3e55d4211744", + "reference": "adf44419c0fc014a0f191db6f89d3e55d4211744", + "shasum": "" + }, + "require": { + "ext-tokenizer": "*", + "php": ">=5.5" + }, + "require-dev": { + "phpunit/phpunit": "~4.0|~5.0" + }, + "bin": [ + "bin/php-parse" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, + "autoload": { + "psr-4": { + "PhpParser\\": "lib/PhpParser" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Nikita Popov" + } + ], + "description": "A PHP parser written in PHP", + "keywords": [ + "parser", + "php" + ], + "time": "2016-12-06 11:30:35" + }, + { + "name": "paragonie/random_compat", + "version": "v2.0.4", + "source": { + "type": "git", + "url": "https://github.com/paragonie/random_compat.git", + "reference": "a9b97968bcde1c4de2a5ec6cbd06a0f6c919b46e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/a9b97968bcde1c4de2a5ec6cbd06a0f6c919b46e", + "reference": "a9b97968bcde1c4de2a5ec6cbd06a0f6c919b46e", + "shasum": "" + }, + "require": { + "php": ">=5.2.0" + }, + "require-dev": { + "phpunit/phpunit": "4.*|5.*" + }, + "suggest": { + "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + }, + "type": "library", + "autoload": { + "files": [ + "lib/random.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Paragon Initiative Enterprises", + "email": "security@paragonie.com", + "homepage": "https://paragonie.com" + } + ], + "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "keywords": [ + "csprng", + "pseudorandom", + "random" + ], + "time": "2016-11-07 23:38:38" + }, + { + "name": "php-http/cache-plugin", + "version": "v1.2.0", + "source": { + "type": "git", + "url": "https://github.com/php-http/cache-plugin.git", + "reference": "b4e421cb5214ad9ef8b25bb32214ed4b71a8b356" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-http/cache-plugin/zipball/b4e421cb5214ad9ef8b25bb32214ed4b71a8b356", + "reference": "b4e421cb5214ad9ef8b25bb32214ed4b71a8b356", + "shasum": "" + }, + "require": { + "php": "^5.4 || ^7.0", + "php-http/client-common": "^1.1", + "php-http/message-factory": "^1.0", + "psr/cache": "^1.0", + "symfony/options-resolver": "^2.6 || ^3.0" + }, + "require-dev": { + "henrikbjorn/phpspec-code-coverage": "^1.0", + "phpspec/phpspec": "^2.5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.2-dev" + } + }, + "autoload": { + "psr-4": { + "Http\\Client\\Common\\Plugin\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" + } + ], + "description": "PSR-6 Cache plugin for HTTPlug", + "homepage": "http://httplug.io", + "keywords": [ + "cache", + "http", + "httplug", + "plugin" + ], + "time": "2016-08-16 12:12:50" + }, + { + "name": "php-http/client-common", + "version": "v1.4.0", + "source": { + "type": "git", + "url": "https://github.com/php-http/client-common.git", + "reference": "3cf7eb93a2e19bded055efff1a267a1fa6d46074" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-http/client-common/zipball/3cf7eb93a2e19bded055efff1a267a1fa6d46074", + "reference": "3cf7eb93a2e19bded055efff1a267a1fa6d46074", + "shasum": "" + }, + "require": { + "php": ">=5.4", + "php-http/httplug": "^1.1", + "php-http/message": "^1.2", + "php-http/message-factory": "^1.0", + "symfony/options-resolver": "^2.6 || ^3.0" + }, + "require-dev": { + "henrikbjorn/phpspec-code-coverage": "^1.0", + "phpspec/phpspec": "^2.4" + }, + "suggest": { + "php-http/cache-plugin": "PSR-6 Cache plugin", + "php-http/logger-plugin": "PSR-3 Logger plugin", + "php-http/stopwatch-plugin": "Symfony Stopwatch plugin" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.5-dev" + } + }, + "autoload": { + "psr-4": { + "Http\\Client\\Common\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" + } + ], + "description": "Common HTTP Client implementations and tools for HTTPlug", + "homepage": "http://httplug.io", + "keywords": [ + "client", + "common", + "http", + "httplug" + ], + "time": "2016-11-04 09:19:15" + }, + { + "name": "php-http/discovery", + "version": "v1.1.1", + "source": { + "type": "git", + "url": "https://github.com/php-http/discovery.git", + "reference": "47fc36bd73ab615b55c31f4134e6bae70f1c04c1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-http/discovery/zipball/47fc36bd73ab615b55c31f4134e6bae70f1c04c1", + "reference": "47fc36bd73ab615b55c31f4134e6bae70f1c04c1", + "shasum": "" + }, + "require": { + "php": "^5.5 || ^7.0" + }, + "require-dev": { + "henrikbjorn/phpspec-code-coverage": "^2.0.2", + "php-http/httplug": "^1.0", + "php-http/message-factory": "^1.0", + "phpspec/phpspec": "^2.4", + "puli/composer-plugin": "1.0.0-beta10" + }, + "suggest": { + "php-http/message": "Allow to use Guzzle, Diactoros or Slim Framework factories", + "puli/composer-plugin": "Sets up Puli which is recommended for Discovery to work. Check http://docs.php-http.org/en/latest/discovery.html for more details." + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.2-dev" + } + }, + "autoload": { + "psr-4": { + "Http\\Discovery\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" + } + ], + "description": "Finds installed HTTPlug implementations and PSR-7 message factories", + "homepage": "http://php-http.org", + "keywords": [ + "adapter", + "client", + "discovery", + "factory", + "http", + "message", + "psr7" + ], + "time": "2016-11-27 12:21:25" + }, + { + "name": "php-http/guzzle6-adapter", + "version": "v1.1.1", + "source": { + "type": "git", + "url": "https://github.com/php-http/guzzle6-adapter.git", + "reference": "a56941f9dc6110409cfcddc91546ee97039277ab" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-http/guzzle6-adapter/zipball/a56941f9dc6110409cfcddc91546ee97039277ab", + "reference": "a56941f9dc6110409cfcddc91546ee97039277ab", + "shasum": "" + }, + "require": { + "guzzlehttp/guzzle": "^6.0", + "php": ">=5.5.0", + "php-http/httplug": "^1.0" + }, + "provide": { + "php-http/async-client-implementation": "1.0", + "php-http/client-implementation": "1.0" + }, + "require-dev": { + "ext-curl": "*", + "php-http/adapter-integration-tests": "^0.4" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.2-dev" } }, "autoload": { "psr-4": { - "League\\Flysystem\\": "src/" + "Http\\Adapter\\Guzzle6\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -759,88 +1526,54 @@ ], "authors": [ { - "name": "Frank de Jonge", - "email": "info@frenky.net" + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" + }, + { + "name": "David de Boer", + "email": "david@ddeboer.nl" } ], - "description": "Filesystem abstraction: Many filesystems, one API.", + "description": "Guzzle 6 HTTP Adapter", + "homepage": "http://httplug.io", "keywords": [ - "Cloud Files", - "WebDAV", - "abstraction", - "aws", - "cloud", - "copy.com", - "dropbox", - "file systems", - "files", - "filesystem", - "filesystems", - "ftp", - "rackspace", - "remote", - "s3", - "sftp", - "storage" + "Guzzle", + "http" ], - "time": "2016-10-19 20:38:46" + "time": "2016-05-10 06:13:32" }, { - "name": "monolog/monolog", - "version": "1.22.0", + "name": "php-http/httplug", + "version": "v1.1.0", "source": { "type": "git", - "url": "https://github.com/Seldaek/monolog.git", - "reference": "bad29cb8d18ab0315e6c477751418a82c850d558" + "url": "https://github.com/php-http/httplug.git", + "reference": "1c6381726c18579c4ca2ef1ec1498fdae8bdf018" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Seldaek/monolog/zipball/bad29cb8d18ab0315e6c477751418a82c850d558", - "reference": "bad29cb8d18ab0315e6c477751418a82c850d558", + "url": "https://api.github.com/repos/php-http/httplug/zipball/1c6381726c18579c4ca2ef1ec1498fdae8bdf018", + "reference": "1c6381726c18579c4ca2ef1ec1498fdae8bdf018", "shasum": "" }, "require": { - "php": ">=5.3.0", - "psr/log": "~1.0" - }, - "provide": { - "psr/log-implementation": "1.0.0" + "php": ">=5.4", + "php-http/promise": "^1.0", + "psr/http-message": "^1.0" }, "require-dev": { - "aws/aws-sdk-php": "^2.4.9 || ^3.0", - "doctrine/couchdb": "~1.0@dev", - "graylog2/gelf-php": "~1.0", - "jakub-onderka/php-parallel-lint": "0.9", - "php-amqplib/php-amqplib": "~2.4", - "php-console/php-console": "^3.1.3", - "phpunit/phpunit": "~4.5", - "phpunit/phpunit-mock-objects": "2.3.0", - "ruflin/elastica": ">=0.90 <3.0", - "sentry/sentry": "^0.13", - "swiftmailer/swiftmailer": "~5.3" - }, - "suggest": { - "aws/aws-sdk-php": "Allow sending log messages to AWS services like DynamoDB", - "doctrine/couchdb": "Allow sending log messages to a CouchDB server", - "ext-amqp": "Allow sending log messages to an AMQP server (1.0+ required)", - "ext-mongo": "Allow sending log messages to a MongoDB server", - "graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server", - "mongodb/mongodb": "Allow sending log messages to a MongoDB server via PHP Driver", - "php-amqplib/php-amqplib": "Allow sending log messages to an AMQP server using php-amqplib", - "php-console/php-console": "Allow sending log messages to Google Chrome", - "rollbar/rollbar": "Allow sending log messages to Rollbar", - "ruflin/elastica": "Allow sending log messages to an Elastic Search server", - "sentry/sentry": "Allow sending log messages to a Sentry server" + "henrikbjorn/phpspec-code-coverage": "^1.0", + "phpspec/phpspec": "^2.4" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "1.1-dev" } }, "autoload": { "psr-4": { - "Monolog\\": "src/Monolog" + "Http\\Client\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -849,89 +1582,118 @@ ], "authors": [ { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" + "name": "Eric GELOEN", + "email": "geloen.eric@gmail.com" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" } ], - "description": "Sends your logs to files, sockets, inboxes, databases and various web services", - "homepage": "http://github.com/Seldaek/monolog", + "description": "HTTPlug, the HTTP client abstraction for PHP", + "homepage": "http://httplug.io", "keywords": [ - "log", - "logging", - "psr-3" + "client", + "http" ], - "time": "2016-11-26 00:15:39" + "time": "2016-08-31 08:30:17" }, { - "name": "mtdowling/cron-expression", - "version": "v1.1.0", + "name": "php-http/message", + "version": "v1.4.1", "source": { "type": "git", - "url": "https://github.com/mtdowling/cron-expression.git", - "reference": "c9ee7886f5a12902b225a1a12f36bb45f9ab89e5" + "url": "https://github.com/php-http/message.git", + "reference": "bfd895a4e753bdde99bed64d75b999e0c9fa6147" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/mtdowling/cron-expression/zipball/c9ee7886f5a12902b225a1a12f36bb45f9ab89e5", - "reference": "c9ee7886f5a12902b225a1a12f36bb45f9ab89e5", + "url": "https://api.github.com/repos/php-http/message/zipball/bfd895a4e753bdde99bed64d75b999e0c9fa6147", + "reference": "bfd895a4e753bdde99bed64d75b999e0c9fa6147", "shasum": "" }, "require": { - "php": ">=5.3.2" + "clue/stream-filter": "^1.3", + "php": ">=5.4", + "php-http/message-factory": "^1.0.2", + "psr/http-message": "^1.0" }, "require-dev": { - "phpunit/phpunit": "~4.0|~5.0" + "akeneo/phpspec-skip-example-extension": "^1.0", + "coduo/phpspec-data-provider-extension": "^1.0", + "ext-zlib": "*", + "guzzlehttp/psr7": "^1.0", + "henrikbjorn/phpspec-code-coverage": "^1.0", + "phpspec/phpspec": "^2.4", + "slim/slim": "^3.0", + "zendframework/zend-diactoros": "^1.0" + }, + "suggest": { + "ext-zlib": "Used with compressor/decompressor streams", + "guzzlehttp/psr7": "Used with Guzzle PSR-7 Factories", + "slim/slim": "Used with Slim Framework PSR-7 implementation", + "zendframework/zend-diactoros": "Used with Diactoros Factories" }, "type": "library", - "autoload": { - "psr-0": { - "Cron": "src/" + "extra": { + "branch-alias": { + "dev-master": "1.5-dev" } }, + "autoload": { + "psr-4": { + "Http\\Message\\": "src/" + }, + "files": [ + "src/filters.php" + ] + }, "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], "authors": [ { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" } ], - "description": "CRON for PHP: Calculate the next or previous run date and determine if a CRON expression is due", + "description": "HTTP Message related tools", + "homepage": "http://php-http.org", "keywords": [ - "cron", - "schedule" + "http", + "message", + "psr-7" ], - "time": "2016-01-26 21:23:30" + "time": "2016-12-16 21:09:21" }, { - "name": "nesbot/carbon", - "version": "1.21.0", + "name": "php-http/message-factory", + "version": "v1.0.2", "source": { "type": "git", - "url": "https://github.com/briannesbitt/Carbon.git", - "reference": "7b08ec6f75791e130012f206e3f7b0e76e18e3d7" + "url": "https://github.com/php-http/message-factory.git", + "reference": "a478cb11f66a6ac48d8954216cfed9aa06a501a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/7b08ec6f75791e130012f206e3f7b0e76e18e3d7", - "reference": "7b08ec6f75791e130012f206e3f7b0e76e18e3d7", + "url": "https://api.github.com/repos/php-http/message-factory/zipball/a478cb11f66a6ac48d8954216cfed9aa06a501a1", + "reference": "a478cb11f66a6ac48d8954216cfed9aa06a501a1", "shasum": "" }, "require": { - "php": ">=5.3.0", - "symfony/translation": "~2.6|~3.0" - }, - "require-dev": { - "phpunit/phpunit": "~4.0|~5.0" + "php": ">=5.4", + "psr/http-message": "^1.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, "autoload": { "psr-4": { - "Carbon\\": "src/Carbon/" + "Http\\Message\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -940,99 +1702,98 @@ ], "authors": [ { - "name": "Brian Nesbitt", - "email": "brian@nesbot.com", - "homepage": "http://nesbot.com" + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" } ], - "description": "A simple API extension for DateTime.", - "homepage": "http://carbon.nesbot.com", + "description": "Factory interfaces for PSR-7 HTTP Message", + "homepage": "http://php-http.org", "keywords": [ - "date", - "datetime", - "time" + "factory", + "http", + "message", + "stream", + "uri" ], - "time": "2015-11-04 20:07:17" + "time": "2015-12-19 14:08:53" }, { - "name": "nikic/php-parser", - "version": "v3.0.2", + "name": "php-http/promise", + "version": "v1.0.0", "source": { "type": "git", - "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "adf44419c0fc014a0f191db6f89d3e55d4211744" + "url": "https://github.com/php-http/promise.git", + "reference": "dc494cdc9d7160b9a09bd5573272195242ce7980" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/adf44419c0fc014a0f191db6f89d3e55d4211744", - "reference": "adf44419c0fc014a0f191db6f89d3e55d4211744", + "url": "https://api.github.com/repos/php-http/promise/zipball/dc494cdc9d7160b9a09bd5573272195242ce7980", + "reference": "dc494cdc9d7160b9a09bd5573272195242ce7980", "shasum": "" }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.5" - }, "require-dev": { - "phpunit/phpunit": "~4.0|~5.0" + "henrikbjorn/phpspec-code-coverage": "^1.0", + "phpspec/phpspec": "^2.4" }, - "bin": [ - "bin/php-parse" - ], "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "1.1-dev" } }, "autoload": { "psr-4": { - "PhpParser\\": "lib/PhpParser" + "Http\\Promise\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Nikita Popov" + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com" + }, + { + "name": "Joel Wurtz", + "email": "joel.wurtz@gmail.com" } ], - "description": "A PHP parser written in PHP", + "description": "Promise used for asynchronous HTTP requests", + "homepage": "http://httplug.io", "keywords": [ - "parser", - "php" + "promise" ], - "time": "2016-12-06 11:30:35" + "time": "2016-01-26 13:27:02" }, { - "name": "paragonie/random_compat", - "version": "v2.0.4", + "name": "psr/cache", + "version": "1.0.1", "source": { "type": "git", - "url": "https://github.com/paragonie/random_compat.git", - "reference": "a9b97968bcde1c4de2a5ec6cbd06a0f6c919b46e" + "url": "https://github.com/php-fig/cache.git", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/a9b97968bcde1c4de2a5ec6cbd06a0f6c919b46e", - "reference": "a9b97968bcde1c4de2a5ec6cbd06a0f6c919b46e", + "url": "https://api.github.com/repos/php-fig/cache/zipball/d11b50ad223250cf17b86e38383413f5a6764bf8", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8", "shasum": "" }, "require": { - "php": ">=5.2.0" - }, - "require-dev": { - "phpunit/phpunit": "4.*|5.*" - }, - "suggest": { - "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + "php": ">=5.3.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, "autoload": { - "files": [ - "lib/random.php" - ] + "psr-4": { + "Psr\\Cache\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -1040,18 +1801,17 @@ ], "authors": [ { - "name": "Paragon Initiative Enterprises", - "email": "security@paragonie.com", - "homepage": "https://paragonie.com" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "description": "Common interface for caching libraries", "keywords": [ - "csprng", - "pseudorandom", - "random" + "cache", + "psr", + "psr-6" ], - "time": "2016-11-07 23:38:38" + "time": "2016-08-06 20:24:11" }, { "name": "psr/http-message", @@ -2014,6 +2774,60 @@ "homepage": "https://symfony.com", "time": "2017-01-12 20:43:39" }, + { + "name": "symfony/options-resolver", + "version": "v3.2.2", + "source": { + "type": "git", + "url": "https://github.com/symfony/options-resolver.git", + "reference": "855429e3e9014b9dafee2a667de304c3aaa86fe6" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/855429e3e9014b9dafee2a667de304c3aaa86fe6", + "reference": "855429e3e9014b9dafee2a667de304c3aaa86fe6", + "shasum": "" + }, + "require": { + "php": ">=5.5.9" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.2-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\OptionsResolver\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony OptionsResolver Component", + "homepage": "https://symfony.com", + "keywords": [ + "config", + "configuration", + "options" + ], + "time": "2017-01-02 20:32:22" + }, { "name": "symfony/polyfill-mbstring", "version": "v1.3.0", @@ -4062,7 +4876,9 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": { + "m1guelpf/github-api": 20 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { diff --git a/config/app.php b/config/app.php index 738847b4..041f1562 100755 --- a/config/app.php +++ b/config/app.php @@ -168,6 +168,7 @@ */ AdamWathan\EloquentOAuthL5\EloquentOAuthServiceProvider::class, + GrahamCampbell\GitHub\GitHubServiceProvider::class, /* * Application Service Providers... @@ -226,6 +227,7 @@ 'Validator' => Illuminate\Support\Facades\Validator::class, 'View' => Illuminate\Support\Facades\View::class, 'SocialAuth' => AdamWathan\EloquentOAuth\Facades\OAuth::class, + 'GitHub' => GrahamCampbell\GitHub\Facades\GitHub::class, ], diff --git a/config/github.php b/config/github.php new file mode 100644 index 00000000..95f52699 --- /dev/null +++ b/config/github.php @@ -0,0 +1,72 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +return [ + + /* + |-------------------------------------------------------------------------- + | Default Connection Name + |-------------------------------------------------------------------------- + | + | Here you may specify which of the connections below you wish to use as + | your default connection for all work. Of course, you may use many + | connections at once using the manager class. + | + */ + + 'default' => 'main', + + /* + |-------------------------------------------------------------------------- + | GitHub Connections + |-------------------------------------------------------------------------- + | + | Here are each of the connections setup for your application. Example + | configuration has been included, but you may add as many connections as + | you would like. Note that the 3 supported authentication methods are: + | "application", "password", and "token". + | + */ + + 'connections' => [ + + 'main' => [ + 'token' => 'your-token', + 'method' => 'token', + // 'backoff' => false, + // 'cache' => false, + // 'version' => 'v3', + // 'enterprise' => false, + ], + + 'alternative' => [ + 'clientId' => 'your-client-id', + 'clientSecret' => 'your-client-secret', + 'method' => 'application', + // 'backoff' => false, + // 'cache' => false, + // 'version' => 'v3', + // 'enterprise' => false, + ], + + 'other' => [ + 'username' => 'your-username', + 'password' => 'your-password', + 'method' => 'password', + // 'backoff' => false, + // 'cache' => false, + // 'version' => 'v3', + // 'enterprise' => false, + ], + + ], + +]; diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php index 1b63a761..30f1e3c3 100755 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ b/database/migrations/2014_10_12_000000_create_users_table.php @@ -18,6 +18,7 @@ public function up() $table->string('name'); $table->string('email')->unique(); $table->string('token'); + $table->string('github_username'); $table->rememberToken(); $table->timestamps(); }); diff --git a/database/migrations/2017_01_14_125908_create_orgs_table.php b/database/migrations/2017_01_14_125908_create_orgs_table.php new file mode 100644 index 00000000..3715b2cf --- /dev/null +++ b/database/migrations/2017_01_14_125908_create_orgs_table.php @@ -0,0 +1,37 @@ +integer('id')->unique(); + $table->string('name'); + $table->string('url'); + $table->string('description')->nullable(); + $table->string('avatar'); + $table->integer('userid'); + $table->string('username'); + $table->string('role')->default('undefined'); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::dropIfExists('orgs'); + } +} diff --git a/public/css/join.css b/public/css/join.css new file mode 100644 index 00000000..660afa90 --- /dev/null +++ b/public/css/join.css @@ -0,0 +1,120 @@ + + html, body { + background-color: #fff; + color: #636b6f; + font-family: 'Raleway', sans-serif; + font-weight: 100; + height: 100vh; + margin: 0; + } + + .full-height { + height: 100vh; + } + + .flex-center { + align-items: center; + display: flex; + justify-content: center; + } + + .position-ref { + position: relative; + } + + .top-right { + position: absolute; + right: 10px; + top: 18px; + } + + .content { + text-align: center; + } + + .title { + font-size: 84px; + } + + .join > a { + color: #636b6f; + padding: 0 25px; + font-size: 12px; + font-weight: 600; + letter-spacing: .1rem; + text-decoration: none; + text-transform: uppercase; + } + + .m-b-md { + margin-bottom: 30px; + } + .submit-button { +-webkit-box-sizing: content-box; +-moz-box-sizing: content-box; +box-sizing: content-box; +width: 250px; +height: 70px; +cursor: pointer; +margin: 0 auto; +border: 2px solid rgb(30,205,151); +-webkit-border-radius: 40px; +border-radius: 40px; +font: normal 37px/70px "Advent Pro", Helvetica, sans-serif; +color: rgb(30, 205, 151); +text-align: center; +-o-text-overflow: clip; +text-overflow: clip; +letter-spacing: 1px; +background: rgba(0,0,0,0); +-webkit-transition: background-color 0.3s cubic-bezier(0, 0, 0, 0), color 0.3s cubic-bezier(0, 0, 0, 0), width 0.3s cubic-bezier(0, 0, 0, 0), border-width 0.3s cubic-bezier(0, 0, 0, 0), border-color 0.3s cubic-bezier(0, 0, 0, 0); +-moz-transition: background-color 0.3s cubic-bezier(0, 0, 0, 0), color 0.3s cubic-bezier(0, 0, 0, 0), width 0.3s cubic-bezier(0, 0, 0, 0), border-width 0.3s cubic-bezier(0, 0, 0, 0), border-color 0.3s cubic-bezier(0, 0, 0, 0); +-o-transition: background-color 0.3s cubic-bezier(0, 0, 0, 0), color 0.3s cubic-bezier(0, 0, 0, 0), width 0.3s cubic-bezier(0, 0, 0, 0), border-width 0.3s cubic-bezier(0, 0, 0, 0), border-color 0.3s cubic-bezier(0, 0, 0, 0); +transition: background-color 0.3s cubic-bezier(0, 0, 0, 0), color 0.3s cubic-bezier(0, 0, 0, 0), width 0.3s cubic-bezier(0, 0, 0, 0), border-width 0.3s cubic-bezier(0, 0, 0, 0), border-color 0.3s cubic-bezier(0, 0, 0, 0); +} + +.submit-button:hover { +color: rgba(255,255,255,1); +background: rgb(30, 205, 151); +} + +.submit-button:active { +border: 2px solid rgba(33,224,163,1); +background: rgba(33,224,163,1); +-webkit-transition: none; +-moz-transition: none; +-o-transition: none; +transition: none; +} +.email { +display: inline-block; +-webkit-box-sizing: content-box; +-moz-box-sizing: content-box; +box-sizing: content-box; +padding: 6px 20px; +border: none; +-webkit-border-radius: 32px / 54px; +border-radius: 32px / 54px; +font: normal 18px/normal "Coda", Helvetica, sans-serif; +color: rgba(0,142,198,1); +-o-text-overflow: ellipsis; +text-overflow: ellipsis; +background: rgba(232,252,252,1); +-webkit-box-shadow: 0 1px 2px 0 rgba(0,0,0,0.2) inset; +box-shadow: 0 1px 2px 0 rgba(0,0,0,0.2) inset; +text-shadow: 1px 1px 0 rgba(255,255,255,0.66) ; +-webkit-transition: all 200ms cubic-bezier(0.42, 0, 0.58, 1); +-moz-transition: all 200ms cubic-bezier(0.42, 0, 0.58, 1); +-o-transition: all 200ms cubic-bezier(0.42, 0, 0.58, 1); +transition: all 200ms cubic-bezier(0.42, 0, 0.58, 1); +} + +.email:hover { +background: rgba(232,249,255,1); +-webkit-box-shadow: 0 2px 2px 0 rgba(90,90,90,0.2) inset; +box-shadow: 0 2px 2px 0 rgba(90,90,90,0.2) inset; +} + +.email:focus { +background: rgba(255,253,232,1); +} diff --git a/resources/views/dashboard.blade.php b/resources/views/dashboard.blade.php old mode 100644 new mode 100755 diff --git a/resources/views/join.blade.php b/resources/views/join.blade.php new file mode 100755 index 00000000..6f7ed00b --- /dev/null +++ b/resources/views/join.blade.php @@ -0,0 +1,41 @@ + + + + + + + + Join {{ $org->name }} + + + + + + + + +
+ + @endif + +
+
+ Join {{ $org->name }} +
+
+ Enter your email adress to join {{ $org->name }}:

+
+ {{ csrf_field() }} +

+ +
+
+
+
+ + diff --git a/resources/views/login.blade.php b/resources/views/login.blade.php old mode 100644 new mode 100755 diff --git a/resources/views/vendor/notifications/email-plain.blade.php b/resources/views/vendor/notifications/email-plain.blade.php new file mode 100755 index 00000000..acefa652 --- /dev/null +++ b/resources/views/vendor/notifications/email-plain.blade.php @@ -0,0 +1,22 @@ + + + + + + + + + + + 'margin: 0; padding: 0; width: 100%; background-color: #F2F4F6;', + 'email-wrapper' => 'width: 100%; margin: 0; padding: 0; background-color: #F2F4F6;', + + /* Masthead ----------------------- */ + + 'email-masthead' => 'padding: 25px 0; text-align: center;', + 'email-masthead_name' => 'font-size: 16px; font-weight: bold; color: #2F3133; text-decoration: none; text-shadow: 0 1px 0 white;', + + 'email-body' => 'width: 100%; margin: 0; padding: 0; border-top: 1px solid #EDEFF2; border-bottom: 1px solid #EDEFF2; background-color: #FFF;', + 'email-body_inner' => 'width: auto; max-width: 570px; margin: 0 auto; padding: 0;', + 'email-body_cell' => 'padding: 35px;', + + 'email-footer' => 'width: auto; max-width: 570px; margin: 0 auto; padding: 0; text-align: center;', + 'email-footer_cell' => 'color: #AEAEAE; padding: 35px; text-align: center;', + + /* Body ------------------------------ */ + + 'body_action' => 'width: 100%; margin: 30px auto; padding: 0; text-align: center;', + 'body_sub' => 'margin-top: 25px; padding-top: 25px; border-top: 1px solid #EDEFF2;', + + /* Type ------------------------------ */ + + 'anchor' => 'color: #3869D4;', + 'header-1' => 'margin-top: 0; color: #2F3133; font-size: 19px; font-weight: bold; text-align: left;', + 'paragraph' => 'margin-top: 0; color: #74787E; font-size: 16px; line-height: 1.5em;', + 'paragraph-sub' => 'margin-top: 0; color: #74787E; font-size: 12px; line-height: 1.5em;', + 'paragraph-center' => 'text-align: center;', + + /* Buttons ------------------------------ */ + + 'button' => 'display: block; display: inline-block; width: 200px; min-height: 20px; padding: 10px; + background-color: #3869D4; border-radius: 3px; color: #ffffff; font-size: 15px; line-height: 25px; + text-align: center; text-decoration: none; -webkit-text-size-adjust: none;', + + 'button--green' => 'background-color: #22BC66;', + 'button--red' => 'background-color: #dc4d2f;', + 'button--blue' => 'background-color: #3869D4;', +]; +?> + + + + + + + + +
+ + + + + + + + + + + + + + + +
+ + {{ config('app.name') }} + +
+ + + + +
+ +

+ @if (! empty($greeting)) + {{ $greeting }} + @else + @if ($level == 'error') + Whoops! + @else + Hello! + @endif + @endif +

+ + + @foreach ($introLines as $line) +

+ {{ $line }} +

+ @endforeach + + + @if (isset($actionText)) + + + + +
+ + + + {{ $actionText }} + +
+ @endif + + + @foreach ($outroLines as $line) +

+ {{ $line }} +

+ @endforeach + + +

+ Regards,
{{ config('app.name') }} +

+ + + @if (isset($actionText)) + + + + +
+

+ If you’re having trouble clicking the "{{ $actionText }}" button, + copy and paste the URL below into your web browser: +

+ +

+ + {{ $actionUrl }} + +

+
+ @endif +
+
+ + + + +
+

+ © {{ date('Y') }} + {{ config('app.name') }}. + All rights reserved. +

+
+
+
+ + diff --git a/resources/views/vendor/pagination/bootstrap-4.blade.php b/resources/views/vendor/pagination/bootstrap-4.blade.php new file mode 100755 index 00000000..3f984557 --- /dev/null +++ b/resources/views/vendor/pagination/bootstrap-4.blade.php @@ -0,0 +1,36 @@ +@if ($paginator->hasPages()) + +@endif diff --git a/resources/views/vendor/pagination/default.blade.php b/resources/views/vendor/pagination/default.blade.php new file mode 100755 index 00000000..4e795ff4 --- /dev/null +++ b/resources/views/vendor/pagination/default.blade.php @@ -0,0 +1,36 @@ +@if ($paginator->hasPages()) + +@endif diff --git a/resources/views/vendor/pagination/simple-bootstrap-4.blade.php b/resources/views/vendor/pagination/simple-bootstrap-4.blade.php new file mode 100755 index 00000000..98653d31 --- /dev/null +++ b/resources/views/vendor/pagination/simple-bootstrap-4.blade.php @@ -0,0 +1,17 @@ +@if ($paginator->hasPages()) + +@endif diff --git a/resources/views/vendor/pagination/simple-default.blade.php b/resources/views/vendor/pagination/simple-default.blade.php new file mode 100755 index 00000000..cf53b897 --- /dev/null +++ b/resources/views/vendor/pagination/simple-default.blade.php @@ -0,0 +1,17 @@ +@if ($paginator->hasPages()) + +@endif diff --git a/resources/views/welcome.blade.php b/resources/views/welcome.blade.php deleted file mode 100755 index fb70ae5c..00000000 --- a/resources/views/welcome.blade.php +++ /dev/null @@ -1,92 +0,0 @@ - - - - - - - - {{ config('app.name', 'Laravel') }} - - - - - - - - -
- - @endif - -
-
- {{ config('app.name', 'Laravel') }} -
- - -
-
- - diff --git a/routes/web.php b/routes/web.php index 1443bc59..8103c6a8 100755 --- a/routes/web.php +++ b/routes/web.php @@ -1,5 +1,5 @@