├── public ├── favicon.ico ├── robots.txt ├── .htaccess ├── web.config └── index.php ├── database ├── seeds │ ├── .gitkeep │ ├── DatabaseSeeder.php │ └── UserGenerateSeeder.php ├── .gitignore ├── migrations │ └── .gitkeep └── factories │ └── ModelFactory.php ├── resources ├── views │ ├── vendor │ │ └── .gitkeep │ ├── power-management │ │ ├── common │ │ │ ├── admin.blade.php │ │ │ └── sidebar.blade.php │ │ └── admin │ │ │ └── member │ │ │ └── user │ │ │ └── index.blade.php │ ├── welcome.blade.php │ └── errors │ │ └── 503.blade.php ├── assets │ ├── sass │ │ └── bootstrap.scss │ └── less │ │ ├── bootstrap-less │ │ ├── mixins │ │ │ ├── center-block.less │ │ │ ├── text-emphasis.less │ │ │ ├── size.less │ │ │ ├── background-variant.less │ │ │ ├── opacity.less │ │ │ ├── text-overflow.less │ │ │ ├── tab-focus.less │ │ │ ├── labels.less │ │ │ ├── resize.less │ │ │ ├── progress-bar.less │ │ │ ├── nav-divider.less │ │ │ ├── reset-filter.less │ │ │ ├── alerts.less │ │ │ ├── nav-vertical-align.less │ │ │ ├── responsive-visibility.less │ │ │ ├── pagination.less │ │ │ ├── border-radius.less │ │ │ ├── reset-text.less │ │ │ ├── panels.less │ │ │ ├── list-group.less │ │ │ ├── hide-text.less │ │ │ ├── clearfix.less │ │ │ ├── table-row.less │ │ │ ├── image.less │ │ │ └── buttons.less │ │ ├── wells.less │ │ ├── breadcrumbs.less │ │ ├── responsive-embed.less │ │ ├── component-animations.less │ │ ├── close.less │ │ ├── thumbnails.less │ │ ├── utilities.less │ │ ├── media.less │ │ ├── pager.less │ │ ├── jumbotron.less │ │ ├── mixins.less │ │ ├── bootstrap.less │ │ ├── index.less │ │ ├── labels.less │ │ ├── badges.less │ │ ├── code.less │ │ ├── grid.less │ │ ├── alerts.less │ │ ├── progress-bars.less │ │ ├── pagination.less │ │ └── print.less │ │ └── adminlte │ │ ├── invoice.less │ │ ├── carousel.less │ │ ├── skins │ │ ├── _all-skins.less │ │ ├── skin-red-light.less │ │ ├── skin-red.less │ │ ├── skin-green-light.less │ │ ├── skin-green.less │ │ ├── skin-purple-light.less │ │ ├── skin-purple.less │ │ ├── skin-yellow-light.less │ │ ├── skin-yellow.less │ │ ├── skin-blue.less │ │ ├── skin-blue-light.less │ │ ├── skin-black-light.less │ │ └── skin-black.less │ │ ├── labels.less │ │ ├── profile.less │ │ ├── .csslintrc │ │ ├── users-list.less │ │ ├── alerts.less │ │ ├── 404_500_errors.less │ │ ├── login_and_register.less │ │ ├── products.less │ │ ├── callout.less │ │ ├── print.less │ │ ├── table.less │ │ ├── info-box.less │ │ ├── lockscreen.less │ │ ├── mailbox.less │ │ ├── modal.less │ │ ├── social-widgets.less │ │ ├── small-box.less │ │ ├── AdminLTE.less │ │ ├── fullcalendar.less │ │ ├── progress-bars.less │ │ ├── forms.less │ │ └── timeline.less ├── lang │ ├── zh-hans │ │ ├── power-m.php │ │ ├── pagination.php │ │ ├── auth.php │ │ └── passwords.php │ └── en │ │ ├── pagination.php │ │ ├── auth.php │ │ ├── power-m.php │ │ └── passwords.php └── elixir-extensions │ └── elixir-uglify.js ├── bootstrap ├── cache │ └── .gitignore ├── autoload.php └── app.php ├── storage ├── logs │ └── .gitignore ├── app │ ├── public │ │ └── .gitignore │ └── .gitignore └── framework │ ├── cache │ └── .gitignore │ ├── views │ └── .gitignore │ ├── sessions │ └── .gitignore │ └── .gitignore ├── .gitattributes ├── .gitignore ├── app ├── Foundation │ ├── Http │ │ ├── Requests │ │ │ └── Request.php │ │ ├── Middleware │ │ │ ├── EncryptCookies.php │ │ │ ├── VerifyCsrfToken.php │ │ │ ├── RedirectIfAuthenticated.php │ │ │ └── Authenticate.php │ │ ├── Controllers │ │ │ ├── Controller.php │ │ │ └── Auth │ │ │ │ ├── PasswordController.php │ │ │ │ └── AuthController.php │ │ └── Kernel.php │ ├── Providers │ │ ├── AppServiceProvider.php │ │ ├── AuthServiceProvider.php │ │ ├── EventServiceProvider.php │ │ └── RouteServiceProvider.php │ ├── Authentication │ │ ├── UserRelateTrait.php │ │ ├── User.php │ │ ├── Admin │ │ │ └── Role.php │ │ └── Administrator.php │ ├── Jobs │ │ └── Job.php │ ├── Console │ │ ├── Commands │ │ │ └── Inspire.php │ │ └── Kernel.php │ └── Exceptions │ │ └── Handler.php ├── Business │ ├── Contracts │ │ ├── Consumable.php │ │ ├── ShoppingCartItem.php │ │ ├── OrderSpecification.php │ │ ├── OrderArchive.php │ │ └── Order.php │ ├── SupplyChain │ │ ├── Consumables │ │ │ ├── Goods │ │ │ │ ├── GoodsClass.php │ │ │ │ ├── CategoryTrait.php │ │ │ │ ├── GoodsSpecification.php │ │ │ │ ├── GoodsComment.php │ │ │ │ ├── GoodsEvaluate.php │ │ │ │ └── Goods.php │ │ │ ├── Brand.php │ │ │ ├── Category.php │ │ │ └── Consumable.php │ │ ├── Store.php │ │ └── BusinessContributorTrait.php │ ├── OrderSystem │ │ ├── ShoppingCartItem.php │ │ ├── OrderStatusInterface.php │ │ ├── OrderSpecification.php │ │ ├── OrderStatusHandler.php │ │ ├── OrderArchive.php │ │ └── OrderNumberGenerator.php │ ├── Exceptions │ │ └── OrderStatusTransitionException.php │ └── User.php ├── PowerManagement │ ├── Http │ │ ├── Controllers │ │ │ ├── BaseController.php │ │ │ ├── SellerCentral │ │ │ │ └── AuthController.php │ │ │ └── AdminPanel │ │ │ │ ├── DashboardController.php │ │ │ │ ├── Member │ │ │ │ └── UserController.php │ │ │ │ └── AuthController.php │ │ ├── Requests │ │ │ ├── Request.php │ │ │ └── LoginRequest.php │ │ └── Middleware │ │ │ ├── AdminAuth.php │ │ │ ├── SellerCentral.php │ │ │ └── AdministratorControlPanel.php │ ├── Providers │ │ ├── PowerManagementProvider.php │ │ └── RouteServiceProvider.php │ └── Frame │ │ ├── BootstrapPaginationPresenter.php │ │ └── SidebarManager.php └── BusinessPlatform │ ├── Http │ ├── BaseController.php │ └── WelcomeController.php │ └── Providers │ └── RouterRegisterProvider.php ├── package.json ├── config ├── router.php ├── compile.php ├── view.php ├── services.php ├── broadcasting.php ├── filesystems.php ├── cache.php └── queue.php ├── readme.md ├── .env.example ├── tests ├── TestCase.php └── PowerManagement │ └── SidebarManagerTest.php ├── server.php ├── Vagrantfile ├── phpunit.xml ├── gulpfile.js ├── composer.json └── artisan /public/favicon.ico: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /database/seeds/.gitkeep: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /database/.gitignore: -------------------------------------------------------------------------------- 1 | *.sqlite 2 | -------------------------------------------------------------------------------- /database/migrations/.gitkeep: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /resources/views/vendor/.gitkeep: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /bootstrap/cache/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | -------------------------------------------------------------------------------- /storage/logs/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | -------------------------------------------------------------------------------- /public/robots.txt: -------------------------------------------------------------------------------- 1 | User-agent: * 2 | Disallow: 3 | -------------------------------------------------------------------------------- /storage/app/public/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | -------------------------------------------------------------------------------- /storage/app/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !public/ 3 | !.gitignore 4 | -------------------------------------------------------------------------------- /storage/framework/cache/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | -------------------------------------------------------------------------------- /storage/framework/views/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | -------------------------------------------------------------------------------- /storage/framework/sessions/.gitignore: -------------------------------------------------------------------------------- 1 | * 2 | !.gitignore 3 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto 2 | *.css linguist-vendored 3 | *.scss linguist-vendored 4 | -------------------------------------------------------------------------------- /resources/assets/sass/bootstrap.scss: -------------------------------------------------------------------------------- 1 | @import "node_modules/bootstrap-sass/assets/stylesheets/bootstrap"; 2 | 3 | -------------------------------------------------------------------------------- /storage/framework/.gitignore: -------------------------------------------------------------------------------- 1 | config.php 2 | routes.php 3 | schedule-* 4 | compiled.php 5 | services.json 6 | events.scanned.php 7 | routes.scanned.php 8 | down 9 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /vendor 2 | /node_modules 3 | /public/build 4 | /public/assets 5 | /.idea 6 | /.vagrant 7 | Homestead.yaml 8 | Homestead.json 9 | .env 10 | .ide-helper.php 11 | phpunit.local.xml 12 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/center-block.less: -------------------------------------------------------------------------------- 1 | // Center-align a block level element 2 | 3 | .center-block() { 4 | display: block; 5 | margin-left: auto; 6 | margin-right: auto; 7 | } 8 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/text-emphasis.less: -------------------------------------------------------------------------------- 1 | // Typography 2 | 3 | .text-emphasis-variant(@color) { 4 | color: @color; 5 | a&:hover { 6 | color: darken(@color, 10%); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/size.less: -------------------------------------------------------------------------------- 1 | // Sizing shortcuts 2 | 3 | .size(@width; @height) { 4 | width: @width; 5 | height: @height; 6 | } 7 | 8 | .square(@size) { 9 | .size(@size; @size); 10 | } 11 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/background-variant.less: -------------------------------------------------------------------------------- 1 | // Contextual backgrounds 2 | 3 | .bg-variant(@color) { 4 | background-color: @color; 5 | a&:hover { 6 | background-color: darken(@color, 10%); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/opacity.less: -------------------------------------------------------------------------------- 1 | // Opacity 2 | 3 | .opacity(@opacity) { 4 | opacity: @opacity; 5 | // IE8 filter 6 | @opacity-ie: (@opacity * 100); 7 | filter: ~"alpha(opacity=@{opacity-ie})"; 8 | } 9 | -------------------------------------------------------------------------------- /app/Foundation/Http/Requests/Request.php: -------------------------------------------------------------------------------- 1 | .striped(); 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/invoice.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Page: Invoice 3 | * ------------- 4 | */ 5 | 6 | .invoice { 7 | position: relative; 8 | background: #fff; 9 | border: 1px solid #f4f4f4; 10 | padding: 20px; 11 | margin: 10px 25px; 12 | } 13 | 14 | .invoice-title { 15 | margin-top: 0; 16 | } 17 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/nav-divider.less: -------------------------------------------------------------------------------- 1 | // Horizontal dividers 2 | // 3 | // Dividers (basically an hr) within dropdowns and nav lists 4 | 5 | .nav-divider(@color: #e5e5e5) { 6 | height: 1px; 7 | margin: ((@line-height-computed / 2) - 1) 0; 8 | overflow: hidden; 9 | background-color: @color; 10 | } 11 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/reset-filter.less: -------------------------------------------------------------------------------- 1 | // Reset filters for IE 2 | // 3 | // When you need to remove a gradient background, do not forget to use this to reset 4 | // the IE filter for IE9 and below. 5 | 6 | .reset-filter() { 7 | filter: e(%("progid:DXImageTransform.Microsoft.gradient(enabled = false)")); 8 | } 9 | -------------------------------------------------------------------------------- /database/seeds/DatabaseSeeder.php: -------------------------------------------------------------------------------- 1 | call(UsersTableSeeder::class); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "private": true, 3 | "scripts": { 4 | "prod": "gulp --production", 5 | "dev": "gulp watch" 6 | }, 7 | "devDependencies": { 8 | "bootstrap-less": "^3.3.8", 9 | "bootstrap-sass": "^3.0.0", 10 | "gulp": "^3.9.1", 11 | "gulp-uglify": "^1.5.4", 12 | "laravel-elixir": "^5.0.0" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /config/router.php: -------------------------------------------------------------------------------- 1 | [ 11 | ActLoudBur\BusinessPlatform\Providers\RouterRegisterProvider::class, 12 | ActLoudBur\PowerManagement\Providers\RouteServiceProvider::class, 13 | ] 14 | ]; -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/alerts.less: -------------------------------------------------------------------------------- 1 | // Alerts 2 | 3 | .alert-variant(@background; @border; @text-color) { 4 | background-color: @background; 5 | border-color: @border; 6 | color: @text-color; 7 | 8 | hr { 9 | border-top-color: darken(@border, 5%); 10 | } 11 | .alert-link { 12 | color: darken(@text-color, 10%); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /app/Business/Contracts/Consumable.php: -------------------------------------------------------------------------------- 1 | .fa { 11 | font-size: 40px; 12 | position: absolute; 13 | top: 50%; 14 | z-index: 5; 15 | display: inline-block; 16 | margin-top: -20px; 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /app/Business/Contracts/ShoppingCartItem.php: -------------------------------------------------------------------------------- 1 | = 5.5.9 12 | - OpenSSL PHP Extension 13 | - PDO PHP Extension 14 | - Mbstring PHP Extension 15 | - Tokenizer PHP Extension 16 | - Node.js >= 4.4.7 17 | 18 | ## License 19 | 20 | MIT License -------------------------------------------------------------------------------- /app/Foundation/Http/Middleware/VerifyCsrfToken.php: -------------------------------------------------------------------------------- 1 | 8 | Hi, {{ Auth::guard(config('power-m.auth.guard'))->user()->account }} 10 | 13 | 14 | @endsection -------------------------------------------------------------------------------- /.env.example: -------------------------------------------------------------------------------- 1 | APP_ENV=local 2 | APP_DEBUG=true 3 | APP_KEY=SomeRandomString 4 | APP_URL=http://localhost 5 | 6 | DB_CONNECTION=mysql 7 | DB_HOST=127.0.0.1 8 | DB_PORT=3306 9 | DB_DATABASE=homestead 10 | DB_USERNAME=homestead 11 | DB_PASSWORD=secret 12 | 13 | CACHE_DRIVER=file 14 | SESSION_DRIVER=file 15 | QUEUE_DRIVER=sync 16 | 17 | REDIS_HOST=127.0.0.1 18 | REDIS_PASSWORD=null 19 | REDIS_PORT=6379 20 | 21 | MAIL_DRIVER=smtp 22 | MAIL_HOST=mailtrap.io 23 | MAIL_PORT=2525 24 | MAIL_USERNAME=null 25 | MAIL_PASSWORD=null 26 | MAIL_ENCRYPTION=null 27 | -------------------------------------------------------------------------------- /resources/lang/zh-hans/power-m.php: -------------------------------------------------------------------------------- 1 | [ 11 | 'login' => [ 12 | 'remember-me' => '记住我', 13 | 'login-form-guide' => '登录以启动会话', 14 | 'sign-in' => '登录', 15 | 'account' => '账户', 16 | 'password' => '密码', 17 | ], 18 | ], 19 | 'framework' => [ 20 | 'dashboard' => '控制台', 21 | ], 22 | ]; -------------------------------------------------------------------------------- /app/Foundation/Http/Controllers/Controller.php: -------------------------------------------------------------------------------- 1 | li { 5 | > a, 6 | > span { 7 | padding: @padding-vertical @padding-horizontal; 8 | font-size: @font-size; 9 | } 10 | &:first-child { 11 | > a, 12 | > span { 13 | .border-left-radius(@border-radius); 14 | } 15 | } 16 | &:last-child { 17 | > a, 18 | > span { 19 | .border-right-radius(@border-radius); 20 | } 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/border-radius.less: -------------------------------------------------------------------------------- 1 | // Single side border-radius 2 | 3 | .border-top-radius(@radius) { 4 | border-top-right-radius: @radius; 5 | border-top-left-radius: @radius; 6 | } 7 | .border-right-radius(@radius) { 8 | border-bottom-right-radius: @radius; 9 | border-top-right-radius: @radius; 10 | } 11 | .border-bottom-radius(@radius) { 12 | border-bottom-right-radius: @radius; 13 | border-bottom-left-radius: @radius; 14 | } 15 | .border-left-radius(@radius) { 16 | border-bottom-left-radius: @radius; 17 | border-top-left-radius: @radius; 18 | } 19 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/reset-text.less: -------------------------------------------------------------------------------- 1 | .reset-text() { 2 | font-family: @font-family-base; 3 | // We deliberately do NOT reset font-size. 4 | font-style: normal; 5 | font-weight: normal; 6 | letter-spacing: normal; 7 | line-break: auto; 8 | line-height: @line-height-base; 9 | text-align: left; // Fallback for where `start` is not supported 10 | text-align: start; 11 | text-decoration: none; 12 | text-shadow: none; 13 | text-transform: none; 14 | white-space: normal; 15 | word-break: normal; 16 | word-spacing: normal; 17 | word-wrap: normal; 18 | } 19 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/profile.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Page: Profile 3 | * ------------- 4 | */ 5 | 6 | .profile-user-img { 7 | margin: 0 auto; 8 | width: 100px; 9 | padding: 3px; 10 | border: 3px solid @gray; 11 | } 12 | 13 | .profile-username { 14 | font-size: 21px; 15 | margin-top: 5px; 16 | } 17 | 18 | .post { 19 | border-bottom: 1px solid @gray; 20 | margin-bottom: 15px; 21 | padding-bottom: 15px; 22 | color: #666; 23 | &:last-of-type { 24 | border-bottom: 0; 25 | margin-bottom: 0; 26 | padding-bottom: 0; 27 | } 28 | .user-block { 29 | margin-bottom: 15px; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /resources/elixir-extensions/elixir-uglify.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Created by chongyi on 16/7/3. 3 | */ 4 | 5 | var gulp = require('gulp'); 6 | var uglify = require('gulp-uglify'); 7 | var rename = require('gulp-rename'); 8 | var Elixir = require('laravel-elixir'); 9 | 10 | var Task = Elixir.Task; 11 | 12 | Elixir.extend('uglify', function (src, target) { 13 | 14 | new Task('uglify', function () { 15 | return gulp.src(src) 16 | .pipe(rename({suffix: '.min'})) 17 | .pipe(uglify({ 18 | compress: true 19 | })).pipe(gulp.dest(target)); 20 | }); 21 | 22 | }); -------------------------------------------------------------------------------- /app/Foundation/Authentication/UserRelateTrait.php: -------------------------------------------------------------------------------- 1 | belongsTo(User::class, 'user_id', 'id'); 28 | } 29 | } -------------------------------------------------------------------------------- /resources/lang/en/pagination.php: -------------------------------------------------------------------------------- 1 | '« Previous', 17 | 'next' => 'Next »', 18 | 19 | ]; 20 | -------------------------------------------------------------------------------- /public/.htaccess: -------------------------------------------------------------------------------- 1 | 2 | 3 | Options -MultiViews 4 | 5 | 6 | RewriteEngine On 7 | 8 | # Redirect Trailing Slashes If Not A Folder... 9 | RewriteCond %{REQUEST_FILENAME} !-d 10 | RewriteRule ^(.*)/$ /$1 [L,R=301] 11 | 12 | # Handle Front Controller... 13 | RewriteCond %{REQUEST_FILENAME} !-d 14 | RewriteCond %{REQUEST_FILENAME} !-f 15 | RewriteRule ^ index.php [L] 16 | 17 | # Handle Authorization Header 18 | RewriteCond %{HTTP:Authorization} . 19 | RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}] 20 | 21 | -------------------------------------------------------------------------------- /resources/lang/zh-hans/pagination.php: -------------------------------------------------------------------------------- 1 | '« Previous', 17 | 'next' => 'Next »', 18 | 19 | ]; 20 | -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Goods/CategoryTrait.php: -------------------------------------------------------------------------------- 1 | hasMany(Goods::class, 'category_id', 'id'); 26 | } 27 | } -------------------------------------------------------------------------------- /tests/TestCase.php: -------------------------------------------------------------------------------- 1 | make(Illuminate\Contracts\Console\Kernel::class)->bootstrap(); 22 | 23 | return $app; 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /app/Business/Contracts/OrderSpecification.php: -------------------------------------------------------------------------------- 1 | 8 | */ 9 | 10 | $uri = urldecode( 11 | parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) 12 | ); 13 | 14 | // This file allows us to emulate Apache's "mod_rewrite" functionality from the 15 | // built-in PHP web server. This provides a convenient way to test a Laravel 16 | // application without having installed a "real" web server software here. 17 | if ($uri !== '/' && file_exists(__DIR__.'/public'.$uri)) { 18 | return false; 19 | } 20 | 21 | require_once __DIR__.'/public/index.php'; 22 | -------------------------------------------------------------------------------- /app/Foundation/Jobs/Job.php: -------------------------------------------------------------------------------- 1 | morphTo(); 30 | } 31 | } -------------------------------------------------------------------------------- /resources/assets/less/adminlte/.csslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "adjoining-classes": false, 3 | "box-sizing": false, 4 | "box-model": false, 5 | "compatible-vendor-prefixes": false, 6 | "floats": false, 7 | "font-sizes": false, 8 | "gradients": false, 9 | "important": false, 10 | "known-properties": false, 11 | "outline-none": false, 12 | "qualified-headings": false, 13 | "regex-selectors": false, 14 | "shorthand": false, 15 | "text-indent": false, 16 | "unique-headings": false, 17 | "universal-selector": false, 18 | "unqualified-attributes": false, 19 | "ids": false, 20 | "fallback-colors": false, 21 | "vendor-prefix": false, 22 | "import": false 23 | } 24 | -------------------------------------------------------------------------------- /app/PowerManagement/Http/Middleware/AdminAuth.php: -------------------------------------------------------------------------------- 1 | guest()) { 26 | return redirect()->route('power-m.auth.login-form'); 27 | } 28 | 29 | return $next($request); 30 | } 31 | } -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/panels.less: -------------------------------------------------------------------------------- 1 | // Panels 2 | 3 | .panel-variant(@border; @heading-text-color; @heading-bg-color; @heading-border) { 4 | border-color: @border; 5 | 6 | & > .panel-heading { 7 | color: @heading-text-color; 8 | background-color: @heading-bg-color; 9 | border-color: @heading-border; 10 | 11 | + .panel-collapse > .panel-body { 12 | border-top-color: @border; 13 | } 14 | .badge { 15 | color: @heading-bg-color; 16 | background-color: @heading-text-color; 17 | } 18 | } 19 | & > .panel-footer { 20 | + .panel-collapse > .panel-body { 21 | border-bottom-color: @border; 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/wells.less: -------------------------------------------------------------------------------- 1 | // 2 | // Wells 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base class 7 | .well { 8 | min-height: 20px; 9 | padding: 19px; 10 | margin-bottom: 20px; 11 | background-color: @well-bg; 12 | border: 1px solid @well-border; 13 | border-radius: @border-radius-base; 14 | .box-shadow(inset 0 1px 1px rgba(0,0,0,.05)); 15 | blockquote { 16 | border-color: #ddd; 17 | border-color: rgba(0,0,0,.15); 18 | } 19 | } 20 | 21 | // Sizes 22 | .well-lg { 23 | padding: 24px; 24 | border-radius: @border-radius-large; 25 | } 26 | .well-sm { 27 | padding: 9px; 28 | border-radius: @border-radius-small; 29 | } 30 | -------------------------------------------------------------------------------- /app/Foundation/Http/Middleware/RedirectIfAuthenticated.php: -------------------------------------------------------------------------------- 1 | check()) { 21 | return redirect('/'); 22 | } 23 | 24 | return $next($request); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/list-group.less: -------------------------------------------------------------------------------- 1 | // List Groups 2 | 3 | .list-group-item-variant(@state; @background; @color) { 4 | .list-group-item-@{state} { 5 | color: @color; 6 | background-color: @background; 7 | 8 | a& { 9 | color: @color; 10 | 11 | .list-group-item-heading { 12 | color: inherit; 13 | } 14 | 15 | &:hover, 16 | &:focus { 17 | color: @color; 18 | background-color: darken(@background, 5%); 19 | } 20 | &.active, 21 | &.active:hover, 22 | &.active:focus { 23 | color: #fff; 24 | background-color: @color; 25 | border-color: @color; 26 | } 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/hide-text.less: -------------------------------------------------------------------------------- 1 | // CSS image replacement 2 | // 3 | // Heads up! v3 launched with with only `.hide-text()`, but per our pattern for 4 | // mixins being reused as classes with the same name, this doesn't hold up. As 5 | // of v3.0.1 we have added `.text-hide()` and deprecated `.hide-text()`. 6 | // 7 | // Source: https://github.com/h5bp/html5-boilerplate/commit/aa0396eae757 8 | 9 | // Deprecated as of v3.0.1 (will be removed in v4) 10 | .hide-text() { 11 | font: ~"0/0" a; 12 | color: transparent; 13 | text-shadow: none; 14 | background-color: transparent; 15 | border: 0; 16 | } 17 | 18 | // New mixin to use as of v3.0.1 19 | .text-hide() { 20 | .hide-text(); 21 | } 22 | -------------------------------------------------------------------------------- /resources/lang/en/auth.php: -------------------------------------------------------------------------------- 1 | 'These credentials do not match our records.', 17 | 'throttle' => 'Too many login attempts. Please try again in :seconds seconds.', 18 | 19 | ]; 20 | -------------------------------------------------------------------------------- /resources/lang/zh-hans/auth.php: -------------------------------------------------------------------------------- 1 | 'These credentials do not match our records.', 17 | 'throttle' => 'Too many login attempts. Please try again in :seconds seconds.', 18 | 19 | ]; 20 | -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Brand.php: -------------------------------------------------------------------------------- 1 | belongsToMany(Category::class, 'brand_category', 'branch_id', 'category_id'); 30 | } 31 | } -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/clearfix.less: -------------------------------------------------------------------------------- 1 | // Clearfix 2 | // 3 | // For modern browsers 4 | // 1. The space content is one way to avoid an Opera bug when the 5 | // contenteditable attribute is included anywhere else in the document. 6 | // Otherwise it causes space to appear at the top and bottom of elements 7 | // that are clearfixed. 8 | // 2. The use of `table` rather than `block` is only necessary if using 9 | // `:before` to contain the top-margins of child elements. 10 | // 11 | // Source: http://nicolasgallagher.com/micro-clearfix-hack/ 12 | 13 | .clearfix() { 14 | &:before, 15 | &:after { 16 | content: " "; // 1 17 | display: table; // 2 18 | } 19 | &:after { 20 | clear: both; 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/breadcrumbs.less: -------------------------------------------------------------------------------- 1 | // 2 | // Breadcrumbs 3 | // -------------------------------------------------- 4 | 5 | 6 | .breadcrumb { 7 | padding: @breadcrumb-padding-vertical @breadcrumb-padding-horizontal; 8 | margin-bottom: @line-height-computed; 9 | list-style: none; 10 | background-color: @breadcrumb-bg; 11 | border-radius: @border-radius-base; 12 | 13 | > li { 14 | display: inline-block; 15 | 16 | + li:before { 17 | content: "@{breadcrumb-separator}\00a0"; // Unicode space added since inline-block means non-collapsing white-space 18 | padding: 0 5px; 19 | color: @breadcrumb-color; 20 | } 21 | } 22 | 23 | > .active { 24 | color: @breadcrumb-active-color; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/responsive-embed.less: -------------------------------------------------------------------------------- 1 | // Embeds responsive 2 | // 3 | // Credit: Nicolas Gallagher and SUIT CSS. 4 | 5 | .embed-responsive { 6 | position: relative; 7 | display: block; 8 | height: 0; 9 | padding: 0; 10 | overflow: hidden; 11 | 12 | .embed-responsive-item, 13 | iframe, 14 | embed, 15 | object, 16 | video { 17 | position: absolute; 18 | top: 0; 19 | left: 0; 20 | bottom: 0; 21 | height: 100%; 22 | width: 100%; 23 | border: 0; 24 | } 25 | 26 | // Modifier class for 16:9 aspect ratio 27 | &.embed-responsive-16by9 { 28 | padding-bottom: 56.25%; 29 | } 30 | 31 | // Modifier class for 4:3 aspect ratio 32 | &.embed-responsive-4by3 { 33 | padding-bottom: 75%; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /app/Business/OrderSystem/OrderStatusInterface.php: -------------------------------------------------------------------------------- 1 | 'required', 35 | 'password' => 'required', 36 | ]; 37 | } 38 | 39 | } -------------------------------------------------------------------------------- /database/factories/ModelFactory.php: -------------------------------------------------------------------------------- 1 | define(ActLoudBur\Foundation\User::class, function (Faker\Generator $faker) { 15 | return [ 16 | 'name' => $faker->name, 17 | 'email' => $faker->safeEmail, 18 | 'password' => bcrypt(str_random(10)), 19 | 'remember_token' => str_random(10), 20 | ]; 21 | }); 22 | -------------------------------------------------------------------------------- /resources/lang/en/power-m.php: -------------------------------------------------------------------------------- 1 | [ 11 | 'login' => [ 12 | 'remember-me' => 'Remember Me', 13 | 'login-form-guide' => 'Sign in to start your session', 14 | 'sign-in' => 'Sign In', 15 | 'account' => 'Account', 16 | 'password' => 'Password', 17 | 'login-title' => 'Log In', 18 | ], 19 | ], 20 | 'framework' => [ 21 | 'quick-navigation' => 'QUICK NAVIGATION', 22 | 'main-navigation' => 'MAIN NAVIGATION', 23 | 'example' => 'Example', 24 | 'dashboard' => 'Dashboard', 25 | ], 26 | ]; -------------------------------------------------------------------------------- /app/Foundation/Console/Commands/Inspire.php: -------------------------------------------------------------------------------- 1 | comment(PHP_EOL.Inspiring::quote().PHP_EOL); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /app/Foundation/Console/Kernel.php: -------------------------------------------------------------------------------- 1 | command('inspire') 28 | // ->hourly(); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/users-list.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Users List 3 | * --------------------- 4 | */ 5 | .users-list { 6 | &:extend(.list-unstyled); 7 | > li { 8 | width: 25%; 9 | float: left; 10 | padding: 10px; 11 | text-align: center; 12 | img { 13 | .border-radius(50%); 14 | max-width: 100%; 15 | height: auto; 16 | } 17 | > a:hover { 18 | &, 19 | .users-list-name { 20 | color: #999; 21 | } 22 | } 23 | } 24 | } 25 | 26 | .users-list-name, 27 | .users-list-date { 28 | display: block; 29 | } 30 | 31 | .users-list-name { 32 | font-weight: 600; 33 | color: #444; 34 | overflow: hidden; 35 | white-space: nowrap; 36 | text-overflow: ellipsis; 37 | } 38 | 39 | .users-list-date { 40 | color: #999; 41 | font-size: 12px; 42 | } 43 | -------------------------------------------------------------------------------- /app/Foundation/Authentication/Admin/Role.php: -------------------------------------------------------------------------------- 1 | belongsToMany(Administrator::class, 'administrator_role', 'role_id', 'administrator_id') 31 | ->withTimestamps(); 32 | } 33 | } -------------------------------------------------------------------------------- /app/PowerManagement/Providers/PowerManagementProvider.php: -------------------------------------------------------------------------------- 1 | app->singleton(SidebarManager::class); 33 | } 34 | } -------------------------------------------------------------------------------- /app/Foundation/Http/Middleware/Authenticate.php: -------------------------------------------------------------------------------- 1 | guest()) { 21 | if ($request->ajax() || $request->wantsJson()) { 22 | return response('Unauthorized.', 401); 23 | } else { 24 | return redirect()->guest('login'); 25 | } 26 | } 27 | 28 | return $next($request); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/table-row.less: -------------------------------------------------------------------------------- 1 | // Tables 2 | 3 | .table-row-variant(@state; @background) { 4 | // Exact selectors below required to override `.table-striped` and prevent 5 | // inheritance to nested tables. 6 | .table > thead > tr, 7 | .table > tbody > tr, 8 | .table > tfoot > tr { 9 | > td.@{state}, 10 | > th.@{state}, 11 | &.@{state} > td, 12 | &.@{state} > th { 13 | background-color: @background; 14 | } 15 | } 16 | 17 | // Hover states for `.table-hover` 18 | // Note: this is not available for cells or rows within `thead` or `tfoot`. 19 | .table-hover > tbody > tr { 20 | > td.@{state}:hover, 21 | > th.@{state}:hover, 22 | &.@{state}:hover > td, 23 | &:hover > .@{state}, 24 | &.@{state}:hover > th { 25 | background-color: darken(@background, 5%); 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/alerts.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: alert 3 | * ---------------- 4 | */ 5 | 6 | .alert { 7 | .border-radius(3px); 8 | h4 { 9 | font-weight: 600; 10 | } 11 | .icon { 12 | margin-right: 10px; 13 | } 14 | .close { 15 | color: #000; 16 | .opacity(.2); 17 | &:hover { 18 | .opacity(.5); 19 | } 20 | } 21 | a { 22 | color: #fff; 23 | text-decoration: underline; 24 | } 25 | } 26 | 27 | //Alert Variants 28 | .alert-success { 29 | &:extend(.bg-green); 30 | border-color: darken(@green, 5%); 31 | } 32 | 33 | .alert-danger, 34 | .alert-error { 35 | &:extend(.bg-red); 36 | border-color: darken(@red, 5%); 37 | } 38 | 39 | .alert-warning { 40 | &:extend(.bg-yellow); 41 | border-color: darken(@yellow, 5%); 42 | } 43 | 44 | .alert-info { 45 | &:extend(.bg-aqua); 46 | border-color: darken(@aqua, 5%); 47 | } 48 | -------------------------------------------------------------------------------- /resources/lang/en/passwords.php: -------------------------------------------------------------------------------- 1 | 'Passwords must be at least six characters and match the confirmation.', 17 | 'reset' => 'Your password has been reset!', 18 | 'sent' => 'We have e-mailed your password reset link!', 19 | 'token' => 'This password reset token is invalid.', 20 | 'user' => "We can't find a user with that e-mail address.", 21 | 22 | ]; 23 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/404_500_errors.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Page: 400 and 500 error pages 3 | * ------------------------------ 4 | */ 5 | .error-page { 6 | width: 600px; 7 | margin: 20px auto 0 auto; 8 | @media (max-width: @screen-sm-max) { 9 | width: 100%; 10 | } 11 | //For the error number e.g: 404 12 | > .headline { 13 | float: left; 14 | font-size: 100px; 15 | font-weight: 300; 16 | @media (max-width: @screen-sm-max) { 17 | float: none; 18 | text-align: center; 19 | } 20 | } 21 | //For the message 22 | > .error-content { 23 | margin-left: 190px; 24 | @media (max-width: @screen-sm-max) { 25 | margin-left: 0; 26 | } 27 | > h3 { 28 | font-weight: 300; 29 | font-size: 25px; 30 | @media (max-width: @screen-sm-max) { 31 | text-align: center; 32 | } 33 | } 34 | display: block; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /resources/lang/zh-hans/passwords.php: -------------------------------------------------------------------------------- 1 | 'Passwords must be at least six characters and match the confirmation.', 17 | 'reset' => 'Your password has been reset!', 18 | 'sent' => 'We have e-mailed your password reset link!', 19 | 'token' => 'This password reset token is invalid.', 20 | 'user' => "We can't find a user with that e-mail address.", 21 | 22 | ]; 23 | -------------------------------------------------------------------------------- /app/Business/Exceptions/OrderStatusTransitionException.php: -------------------------------------------------------------------------------- 1 | order = $order; 36 | } 37 | } -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/component-animations.less: -------------------------------------------------------------------------------- 1 | // 2 | // Component animations 3 | // -------------------------------------------------- 4 | 5 | // Heads up! 6 | // 7 | // We don't use the `.opacity()` mixin here since it causes a bug with text 8 | // fields in IE7-8. Source: https://github.com/twbs/bootstrap/pull/3552. 9 | 10 | .fade { 11 | opacity: 0; 12 | .transition(opacity .15s linear); 13 | &.in { 14 | opacity: 1; 15 | } 16 | } 17 | 18 | .collapse { 19 | display: none; 20 | visibility: hidden; 21 | 22 | &.in { display: block; visibility: visible; } 23 | tr&.in { display: table-row; } 24 | tbody&.in { display: table-row-group; } 25 | } 26 | 27 | .collapsing { 28 | position: relative; 29 | height: 0; 30 | overflow: hidden; 31 | .transition-property(~"height, visibility"); 32 | .transition-duration(.35s); 33 | .transition-timing-function(ease); 34 | } 35 | -------------------------------------------------------------------------------- /app/Foundation/Authentication/Administrator.php: -------------------------------------------------------------------------------- 1 | belongsToMany(Role::class, 'administrator_role', 'administrator_id', 'role_id') 33 | ->withTimestamps(); 34 | } 35 | } -------------------------------------------------------------------------------- /app/Foundation/Providers/AuthServiceProvider.php: -------------------------------------------------------------------------------- 1 | 'ActLoudBur\Foundation\Policies\ModelPolicy', 17 | ]; 18 | 19 | /** 20 | * Register any application authentication / authorization services. 21 | * 22 | * @param \Illuminate\Contracts\Auth\Access\Gate $gate 23 | * @return void 24 | */ 25 | public function boot(GateContract $gate) 26 | { 27 | $this->registerPolicies($gate); 28 | 29 | // 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /app/BusinessPlatform/Providers/RouterRegisterProvider.php: -------------------------------------------------------------------------------- 1 | group(['namespace' => 'ActLoudBur\BusinessPlatform\Http'], function (Router $router) { 33 | $router->get('/', 'WelcomeController@index'); 34 | }); 35 | } 36 | 37 | } -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/close.less: -------------------------------------------------------------------------------- 1 | // 2 | // Close icons 3 | // -------------------------------------------------- 4 | 5 | 6 | .close { 7 | float: right; 8 | font-size: (@font-size-base * 1.5); 9 | font-weight: @close-font-weight; 10 | line-height: 1; 11 | color: @close-color; 12 | text-shadow: @close-text-shadow; 13 | .opacity(.2); 14 | 15 | &:hover, 16 | &:focus { 17 | color: @close-color; 18 | text-decoration: none; 19 | cursor: pointer; 20 | .opacity(.5); 21 | } 22 | 23 | // Additional properties for button version 24 | // iOS requires the button element instead of an anchor tag. 25 | // If you want the anchor version, it requires `href="#"`. 26 | // See https://developer.mozilla.org/en-US/docs/Web/Events/click#Safari_Mobile 27 | button& { 28 | padding: 0; 29 | cursor: pointer; 30 | background: transparent; 31 | border: 0; 32 | -webkit-appearance: none; 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/thumbnails.less: -------------------------------------------------------------------------------- 1 | // 2 | // Thumbnails 3 | // -------------------------------------------------- 4 | 5 | 6 | // Mixin and adjust the regular image class 7 | .thumbnail { 8 | display: block; 9 | padding: @thumbnail-padding; 10 | margin-bottom: @line-height-computed; 11 | line-height: @line-height-base; 12 | background-color: @thumbnail-bg; 13 | border: 1px solid @thumbnail-border; 14 | border-radius: @thumbnail-border-radius; 15 | .transition(border .2s ease-in-out); 16 | 17 | > img, 18 | a > img { 19 | &:extend(.img-responsive); 20 | margin-left: auto; 21 | margin-right: auto; 22 | } 23 | 24 | // Add a hover state for linked versions only 25 | a&:hover, 26 | a&:focus, 27 | a&.active { 28 | border-color: @link-color; 29 | } 30 | 31 | // Image captions 32 | .caption { 33 | padding: @thumbnail-caption-padding; 34 | color: @thumbnail-caption-color; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /app/Foundation/Providers/EventServiceProvider.php: -------------------------------------------------------------------------------- 1 | [ 17 | 'ActLoudBur\Foundation\Listeners\EventListener', 18 | ], 19 | ]; 20 | 21 | /** 22 | * Register any other events for your application. 23 | * 24 | * @param \Illuminate\Contracts\Events\Dispatcher $events 25 | * @return void 26 | */ 27 | public function boot(DispatcherContract $events) 28 | { 29 | parent::boot($events); 30 | 31 | // 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/login_and_register.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Page: Login & Register 3 | * ---------------------- 4 | */ 5 | 6 | .login-logo, 7 | .register-logo { 8 | font-size: 35px; 9 | text-align: center; 10 | margin-bottom: 25px; 11 | font-weight: 300; 12 | a { 13 | color: #444; 14 | } 15 | } 16 | 17 | .login-page, 18 | .register-page { 19 | background: @gray; 20 | } 21 | 22 | .login-box, 23 | .register-box { 24 | width: 360px; 25 | margin: 7% auto; 26 | @media (max-width: @screen-sm) { 27 | width: 90%; 28 | margin-top: 20px; 29 | } 30 | } 31 | 32 | .login-box-body, 33 | .register-box-body { 34 | background: #fff; 35 | padding: 20px; 36 | border-top: 0; 37 | color: #666; 38 | .form-control-feedback { 39 | color: #777; 40 | } 41 | } 42 | 43 | .login-box-msg, 44 | .register-box-msg { 45 | margin: 0; 46 | text-align: center; 47 | padding: 0 20px 20px 20px; 48 | } 49 | 50 | .social-auth-links { 51 | margin: 10px 0; 52 | } 53 | -------------------------------------------------------------------------------- /app/PowerManagement/Http/Controllers/AdminPanel/DashboardController.php: -------------------------------------------------------------------------------- 1 | route('power-m.dashboard'); 30 | } 31 | 32 | /** 33 | * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View 34 | */ 35 | public function index() 36 | { 37 | return view('power-management.common.admin'); 38 | } 39 | } -------------------------------------------------------------------------------- /public/web.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/products.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Products List 3 | * ------------------------ 4 | */ 5 | .products-list { 6 | list-style: none; 7 | margin: 0; 8 | padding: 0; 9 | > .item { 10 | .border-radius(@box-border-radius); 11 | .box-shadow(@box-boxshadow); 12 | .clearfix(); 13 | padding: 10px 0; 14 | background: #fff; 15 | } 16 | .product-img { 17 | float: left; 18 | img { 19 | width: 50px; 20 | height: 50px; 21 | } 22 | } 23 | .product-info { 24 | margin-left: 60px; 25 | } 26 | .product-title { 27 | font-weight: 600; 28 | } 29 | .product-description { 30 | display: block; 31 | color: #999; 32 | overflow: hidden; 33 | white-space: nowrap; 34 | text-overflow: ellipsis; 35 | } 36 | } 37 | 38 | .product-list-in-box > .item { 39 | .box-shadow(none); 40 | .border-radius(0); 41 | border-bottom: 1px solid @box-border-color; 42 | &:last-of-type { 43 | border-bottom-width: 0; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /Vagrantfile: -------------------------------------------------------------------------------- 1 | require 'json' 2 | require 'yaml' 3 | 4 | VAGRANTFILE_API_VERSION ||= "2" 5 | confDir = $confDir ||= File.expand_path("vendor/laravel/homestead", File.dirname(__FILE__)) 6 | 7 | homesteadYamlPath = "Homestead.yaml" 8 | homesteadJsonPath = "Homestead.json" 9 | afterScriptPath = "after.sh" 10 | aliasesPath = "aliases" 11 | 12 | require File.expand_path(confDir + '/scripts/homestead.rb') 13 | 14 | Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| 15 | if File.exists? aliasesPath then 16 | config.vm.provision "file", source: aliasesPath, destination: "~/.bash_aliases" 17 | end 18 | 19 | if File.exists? homesteadYamlPath then 20 | Homestead.configure(config, YAML::load(File.read(homesteadYamlPath))) 21 | elsif File.exists? homesteadJsonPath then 22 | Homestead.configure(config, JSON.parse(File.read(homesteadJsonPath))) 23 | end 24 | 25 | if File.exists? afterScriptPath then 26 | config.vm.provision "shell", path: afterScriptPath 27 | end 28 | end 29 | -------------------------------------------------------------------------------- /database/seeds/UserGenerateSeeder.php: -------------------------------------------------------------------------------- 1 | 'administrator', 21 | 'password' => bcrypt('administrator'), 22 | ]); 23 | 24 | User::create([ 25 | 'name' => 'Dumper', 26 | 'email' => 'dumper@gmail.com', 27 | 'password' => bcrypt('123456'), 28 | ]); 29 | 30 | User::create([ 31 | 'name' => 'Controller', 32 | 'email' => 'controller@gmail.com', 33 | 'password' => bcrypt('123456'), 34 | ]); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /app/Foundation/Http/Controllers/Auth/PasswordController.php: -------------------------------------------------------------------------------- 1 | middleware('guest'); 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/utilities.less: -------------------------------------------------------------------------------- 1 | // 2 | // Utility classes 3 | // -------------------------------------------------- 4 | 5 | 6 | // Floats 7 | // ------------------------- 8 | 9 | .clearfix { 10 | .clearfix(); 11 | } 12 | .center-block { 13 | .center-block(); 14 | } 15 | .pull-right { 16 | float: right !important; 17 | } 18 | .pull-left { 19 | float: left !important; 20 | } 21 | 22 | 23 | // Toggling content 24 | // ------------------------- 25 | 26 | // Note: Deprecated .hide in favor of .hidden or .sr-only (as appropriate) in v3.0.1 27 | .hide { 28 | display: none !important; 29 | } 30 | .show { 31 | display: block !important; 32 | } 33 | .invisible { 34 | visibility: hidden; 35 | } 36 | .text-hide { 37 | .text-hide(); 38 | } 39 | 40 | 41 | // Hide from screenreaders and browsers 42 | // 43 | // Credit: HTML5 Boilerplate 44 | 45 | .hidden { 46 | display: none !important; 47 | visibility: hidden !important; 48 | } 49 | 50 | 51 | // For Affix plugin 52 | // ------------------------- 53 | 54 | .affix { 55 | position: fixed; 56 | } 57 | -------------------------------------------------------------------------------- /app/Business/User.php: -------------------------------------------------------------------------------- 1 | attributes['type'] == self::PURCHASER; 43 | } 44 | 45 | /** 46 | * 是否是供应者、卖家 47 | * 48 | * @return bool 49 | */ 50 | public function isProvider() 51 | { 52 | return $this->attributes['type'] == self::PROVIDER; 53 | } 54 | } -------------------------------------------------------------------------------- /resources/assets/less/adminlte/callout.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Callout 3 | * ------------------ 4 | */ 5 | 6 | // Base styles (regardless of theme) 7 | .callout { 8 | .border-radius(3px); 9 | margin: 0 0 20px 0; 10 | padding: 15px 30px 15px 15px; 11 | border-left: 5px solid #eee; 12 | a { 13 | color: #fff; 14 | text-decoration: underline; 15 | &:hover { 16 | color: #eee; 17 | } 18 | } 19 | h4 { 20 | margin-top: 0; 21 | font-weight: 600; 22 | } 23 | p:last-child { 24 | margin-bottom: 0; 25 | } 26 | code, 27 | .highlight { 28 | background-color: #fff; 29 | } 30 | 31 | // Themes for different contexts 32 | &.callout-danger { 33 | &:extend(.bg-red); 34 | border-color: darken(@red, 10%); 35 | } 36 | &.callout-warning { 37 | &:extend(.bg-yellow); 38 | border-color: darken(@yellow, 10%); 39 | } 40 | &.callout-info { 41 | &:extend(.bg-aqua); 42 | border-color: darken(@aqua, 10%); 43 | } 44 | &.callout-success { 45 | &:extend(.bg-green); 46 | border-color: darken(@green, 10%); 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/media.less: -------------------------------------------------------------------------------- 1 | .media { 2 | // Proper spacing between instances of .media 3 | margin-top: 15px; 4 | 5 | &:first-child { 6 | margin-top: 0; 7 | } 8 | } 9 | 10 | .media, 11 | .media-body { 12 | zoom: 1; 13 | overflow: hidden; 14 | } 15 | 16 | .media-body { 17 | width: 10000px; 18 | } 19 | 20 | .media-object { 21 | display: block; 22 | } 23 | 24 | .media-right, 25 | .media > .pull-right { 26 | padding-left: 10px; 27 | } 28 | 29 | .media-left, 30 | .media > .pull-left { 31 | padding-right: 10px; 32 | } 33 | 34 | .media-left, 35 | .media-right, 36 | .media-body { 37 | display: table-cell; 38 | vertical-align: top; 39 | } 40 | 41 | .media-middle { 42 | vertical-align: middle; 43 | } 44 | 45 | .media-bottom { 46 | vertical-align: bottom; 47 | } 48 | 49 | // Reset margins on headings for tighter default spacing 50 | .media-heading { 51 | margin-top: 0; 52 | margin-bottom: 5px; 53 | } 54 | 55 | // Media list variation 56 | // 57 | // Undo default ul/ol styles 58 | .media-list { 59 | padding-left: 0; 60 | list-style: none; 61 | } 62 | -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Goods/GoodsSpecification.php: -------------------------------------------------------------------------------- 1 | belongsTo(Store::class, 'store_id', 'id'); 31 | } 32 | 33 | /** 34 | * 关联的所属的商品 SPU 模型 35 | * 36 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 37 | */ 38 | public function goods() 39 | { 40 | return $this->belongsTo(GoodsSpecification::class, 'goods_id', 'id'); 41 | } 42 | } -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Category.php: -------------------------------------------------------------------------------- 1 | hasMany(Consumable::class, 'category_id', 'id'); 33 | } 34 | 35 | /** 36 | * 关联的品牌 37 | * 38 | * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany 39 | */ 40 | public function brands() 41 | { 42 | return $this->belongsToMany(Brand::class, 'brand_category', 'category_id', 'brand_id'); 43 | } 44 | } -------------------------------------------------------------------------------- /app/PowerManagement/Frame/BootstrapPaginationPresenter.php: -------------------------------------------------------------------------------- 1 | hasPages()) { 31 | return new HtmlString(sprintf( 32 | '', 33 | $this->getPreviousButton(), 34 | $this->getLinks(), 35 | $this->getNextButton() 36 | )); 37 | } 38 | 39 | return ''; 40 | } 41 | 42 | } -------------------------------------------------------------------------------- /config/compile.php: -------------------------------------------------------------------------------- 1 | [ 17 | // 18 | ], 19 | 20 | /* 21 | |-------------------------------------------------------------------------- 22 | | Compiled File Providers 23 | |-------------------------------------------------------------------------- 24 | | 25 | | Here you may list service providers which define a "compiles" function 26 | | that returns additional files that should be compiled, providing an 27 | | easy way to get common files from any packages you are utilizing. 28 | | 29 | */ 30 | 31 | 'providers' => [ 32 | // 33 | ], 34 | 35 | ]; 36 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/pager.less: -------------------------------------------------------------------------------- 1 | // 2 | // Pager pagination 3 | // -------------------------------------------------- 4 | 5 | 6 | .pager { 7 | padding-left: 0; 8 | margin: @line-height-computed 0; 9 | list-style: none; 10 | text-align: center; 11 | &:extend(.clearfix all); 12 | li { 13 | display: inline; 14 | > a, 15 | > span { 16 | display: inline-block; 17 | padding: 5px 14px; 18 | background-color: @pager-bg; 19 | border: 1px solid @pager-border; 20 | border-radius: @pager-border-radius; 21 | } 22 | 23 | > a:hover, 24 | > a:focus { 25 | text-decoration: none; 26 | background-color: @pager-hover-bg; 27 | } 28 | } 29 | 30 | .next { 31 | > a, 32 | > span { 33 | float: right; 34 | } 35 | } 36 | 37 | .previous { 38 | > a, 39 | > span { 40 | float: left; 41 | } 42 | } 43 | 44 | .disabled { 45 | > a, 46 | > a:hover, 47 | > a:focus, 48 | > span { 49 | color: @pager-disabled-color; 50 | background-color: @pager-bg; 51 | cursor: @cursor-disabled; 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /phpunit.xml: -------------------------------------------------------------------------------- 1 | 2 | 11 | 12 | 13 | ./tests 14 | 15 | 16 | 17 | 18 | ./app 19 | 20 | ./app/Http/routes.php 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Consumable.php: -------------------------------------------------------------------------------- 1 | morphTo(); 31 | } 32 | 33 | /** 34 | * 关联的店铺 35 | * 36 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 37 | */ 38 | public function store() 39 | { 40 | return $this->belongsTo(Store::class, 'store_id', 'id'); 41 | } 42 | 43 | /** 44 | * 关联的发布者 45 | * 46 | * @return \Illuminate\Database\Eloquent\Relations\MorphTo 47 | */ 48 | public function publisher() 49 | { 50 | return $this->morphTo(); 51 | } 52 | } -------------------------------------------------------------------------------- /config/view.php: -------------------------------------------------------------------------------- 1 | [ 17 | realpath(base_path('resources/views')), 18 | ], 19 | 20 | /* 21 | |-------------------------------------------------------------------------- 22 | | Compiled View Path 23 | |-------------------------------------------------------------------------- 24 | | 25 | | This option determines where all the compiled Blade templates will be 26 | | stored for your application. Typically, this is within the storage 27 | | directory. However, as usual, you are free to change this value. 28 | | 29 | */ 30 | 31 | 'compiled' => realpath(storage_path('framework/views')), 32 | 33 | ]; 34 | -------------------------------------------------------------------------------- /config/services.php: -------------------------------------------------------------------------------- 1 | [ 18 | 'domain' => env('MAILGUN_DOMAIN'), 19 | 'secret' => env('MAILGUN_SECRET'), 20 | ], 21 | 22 | 'ses' => [ 23 | 'key' => env('SES_KEY'), 24 | 'secret' => env('SES_SECRET'), 25 | 'region' => 'us-east-1', 26 | ], 27 | 28 | 'sparkpost' => [ 29 | 'secret' => env('SPARKPOST_SECRET'), 30 | ], 31 | 32 | 'stripe' => [ 33 | 'model' => ActLoudBur\Foundation\User::class, 34 | 'key' => env('STRIPE_KEY'), 35 | 'secret' => env('STRIPE_SECRET'), 36 | ], 37 | 38 | ]; 39 | -------------------------------------------------------------------------------- /app/Business/SupplyChain/Store.php: -------------------------------------------------------------------------------- 1 | hasMany(Consumable::class, 'store_id', 'id'); 37 | } 38 | 39 | /** 40 | * 店铺下的商品 41 | * 42 | * @return \Illuminate\Database\Eloquent\Relations\HasMany 43 | */ 44 | public function goods() 45 | { 46 | return $this->hasMany(Goods::class, 'store_id', 'id'); 47 | } 48 | } -------------------------------------------------------------------------------- /bootstrap/autoload.php: -------------------------------------------------------------------------------- 1 | .table tr th, 50 | > .table tr td { 51 | white-space: normal !important; 52 | } 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/image.less: -------------------------------------------------------------------------------- 1 | // Image Mixins 2 | // - Responsive image 3 | // - Retina image 4 | 5 | 6 | // Responsive image 7 | // 8 | // Keep images from scaling beyond the width of their parents. 9 | .img-responsive(@display: block) { 10 | display: @display; 11 | max-width: 100%; // Part 1: Set a maximum relative to the parent 12 | height: auto; // Part 2: Scale the height according to the width, otherwise you get stretching 13 | } 14 | 15 | 16 | // Retina image 17 | // 18 | // Short retina mixin for setting background-image and -size. Note that the 19 | // spelling of `min--moz-device-pixel-ratio` is intentional. 20 | .img-retina(@file-1x; @file-2x; @width-1x; @height-1x) { 21 | background-image: url("@{file-1x}"); 22 | 23 | @media 24 | only screen and (-webkit-min-device-pixel-ratio: 2), 25 | only screen and ( min--moz-device-pixel-ratio: 2), 26 | only screen and ( -o-min-device-pixel-ratio: 2/1), 27 | only screen and ( min-device-pixel-ratio: 2), 28 | only screen and ( min-resolution: 192dpi), 29 | only screen and ( min-resolution: 2dppx) { 30 | background-image: url("@{file-2x}"); 31 | background-size: @width-1x @height-1x; 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /resources/views/welcome.blade.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Laravel 5 | 6 | 7 | 8 | 37 | 38 | 39 |
40 |
41 |
Laravel 5
42 |
43 |
44 | 45 | 46 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/jumbotron.less: -------------------------------------------------------------------------------- 1 | // 2 | // Jumbotron 3 | // -------------------------------------------------- 4 | 5 | 6 | .jumbotron { 7 | padding: @jumbotron-padding (@jumbotron-padding / 2); 8 | margin-bottom: @jumbotron-padding; 9 | color: @jumbotron-color; 10 | background-color: @jumbotron-bg; 11 | 12 | h1, 13 | .h1 { 14 | color: @jumbotron-heading-color; 15 | } 16 | 17 | p { 18 | margin-bottom: (@jumbotron-padding / 2); 19 | font-size: @jumbotron-font-size; 20 | font-weight: 200; 21 | } 22 | 23 | > hr { 24 | border-top-color: darken(@jumbotron-bg, 10%); 25 | } 26 | 27 | .container &, 28 | .container-fluid & { 29 | border-radius: @border-radius-large; // Only round corners at higher resolutions if contained in a container 30 | } 31 | 32 | .container { 33 | max-width: 100%; 34 | } 35 | 36 | @media screen and (min-width: @screen-sm-min) { 37 | padding: (@jumbotron-padding * 1.6) 0; 38 | 39 | .container &, 40 | .container-fluid & { 41 | padding-left: (@jumbotron-padding * 2); 42 | padding-right: (@jumbotron-padding * 2); 43 | } 44 | 45 | h1, 46 | .h1 { 47 | font-size: (@font-size-base * 4.5); 48 | } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/table.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Table 3 | * ---------------- 4 | */ 5 | 6 | .table { 7 | //Cells 8 | > thead, 9 | > tbody, 10 | > tfoot { 11 | > tr { 12 | > th, 13 | > td { 14 | border-top: 1px solid @box-border-color; 15 | } 16 | } 17 | } 18 | //thead cells 19 | > thead > tr > th { 20 | border-bottom: 2px solid @box-border-color; 21 | } 22 | //progress bars in tables 23 | tr td .progress { 24 | margin-top: 5px; 25 | } 26 | } 27 | 28 | //Bordered Table 29 | .table-bordered { 30 | border: 1px solid @box-border-color; 31 | > thead, 32 | > tbody, 33 | > tfoot { 34 | > tr { 35 | > th, 36 | > td { 37 | border: 1px solid @box-border-color; 38 | } 39 | } 40 | } 41 | > thead > tr { 42 | > th, 43 | > td { 44 | border-bottom-width: 2px; 45 | } 46 | } 47 | } 48 | 49 | .table.no-border { 50 | &, 51 | td, 52 | th { 53 | border: 0; 54 | } 55 | } 56 | 57 | /* .text-center in tables */ 58 | table.text-center { 59 | &, td, th { 60 | text-align: center; 61 | } 62 | } 63 | 64 | .table.align { 65 | th { 66 | text-align: left; 67 | } 68 | td { 69 | text-align: right; 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Goods/GoodsComment.php: -------------------------------------------------------------------------------- 1 | morphTo(); 32 | } 33 | 34 | /** 35 | * 关联的商品 36 | * 37 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 38 | */ 39 | public function goods() 40 | { 41 | return $this->belongsTo(Goods::class, 'goods_id', 'id'); 42 | } 43 | 44 | /** 45 | * 关联的评价 46 | * 47 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 48 | */ 49 | public function evaluate() 50 | { 51 | return $this->belongsTo(GoodsComment::class, 'evaluate_id', 'id'); 52 | } 53 | } -------------------------------------------------------------------------------- /app/Business/SupplyChain/BusinessContributorTrait.php: -------------------------------------------------------------------------------- 1 | hasOne(Store::class, 'user_id', 'id'); 31 | } 32 | 33 | /** 34 | * 关联的消费品模型 35 | * 36 | * @return \Illuminate\Database\Eloquent\Relations\MorphMany 37 | */ 38 | public function consumables() 39 | { 40 | return $this->morphMany(Consumable::class, 'publisher'); 41 | } 42 | 43 | /** 44 | * 关联的商品模型 45 | * 46 | * @return \Illuminate\Database\Eloquent\Relations\MorphMany 47 | */ 48 | public function goods() 49 | { 50 | return $this->morphMany(Goods::class, 'publisher'); 51 | } 52 | } -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-red-light.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Red 3 | * --------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-red-light { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@red; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@red, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@red, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(@red); 40 | } 41 | 42 | li.user-header { 43 | background-color: @red; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-light-sidebar(@red); 54 | } 55 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-red.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Red 3 | * --------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-red { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@red; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@red, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@red, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(darken(@red, 5%)); 40 | } 41 | 42 | li.user-header { 43 | background-color: @red; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-dark-sidebar(@red); 54 | } 55 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins.less: -------------------------------------------------------------------------------- 1 | // Mixins 2 | // -------------------------------------------------- 3 | // Utilities 4 | @import "mixins/hide-text.less"; 5 | @import "mixins/opacity.less"; 6 | @import "mixins/image.less"; 7 | @import "mixins/labels.less"; 8 | @import "mixins/reset-filter.less"; 9 | @import "mixins/resize.less"; 10 | @import "mixins/responsive-visibility.less"; 11 | @import "mixins/size.less"; 12 | @import "mixins/tab-focus.less"; 13 | @import "mixins/reset-text.less"; 14 | @import "mixins/text-emphasis.less"; 15 | @import "mixins/text-overflow.less"; 16 | @import "mixins/vendor-prefixes.less"; 17 | // Components 18 | @import "mixins/alerts.less"; 19 | @import "mixins/buttons.less"; 20 | @import "mixins/panels.less"; 21 | @import "mixins/pagination.less"; 22 | @import "mixins/list-group.less"; 23 | @import "mixins/nav-divider.less"; 24 | @import "mixins/forms.less"; 25 | @import "mixins/progress-bar.less"; 26 | @import "mixins/table-row.less"; 27 | // Skins 28 | @import "mixins/background-variant.less"; 29 | @import "mixins/border-radius.less"; 30 | @import "mixins/gradients.less"; 31 | // Layout 32 | @import "mixins/clearfix.less"; 33 | @import "mixins/center-block.less"; 34 | @import "mixins/nav-vertical-align.less"; 35 | @import "mixins/grid-framework.less"; 36 | @import "mixins/grid.less"; 37 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-green-light.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Green 3 | * ----------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-green-light { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@green; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@green, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@green, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(@green); 40 | } 41 | 42 | li.user-header { 43 | background-color: @green; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-light-sidebar(@green); 54 | 55 | } 56 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-green.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Green 3 | * ----------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-green { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@green; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@green, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@green, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(darken(@green, 5%)); 40 | } 41 | 42 | li.user-header { 43 | background-color: @green; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-dark-sidebar(@green); 54 | 55 | } 56 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-purple-light.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Purple 3 | * ------------ 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-purple-light { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@purple; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@purple, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@purple, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(@purple); 40 | } 41 | 42 | li.user-header { 43 | background-color: @purple; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-light-sidebar(@purple); 54 | } 55 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-purple.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Purple 3 | * ------------ 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-purple { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@purple; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@purple, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@purple, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(darken(@purple, 5%)); 40 | } 41 | 42 | li.user-header { 43 | background-color: @purple; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-dark-sidebar(@purple); 54 | } 55 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-yellow-light.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Yellow 3 | * ------------ 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-yellow-light { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@yellow; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@yellow, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@yellow, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(@yellow); 40 | } 41 | 42 | li.user-header { 43 | background-color: @yellow; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-light-sidebar(@yellow); 54 | } 55 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-yellow.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Yellow 3 | * ------------ 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-yellow { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@yellow; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@yellow, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@yellow, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(darken(@yellow, 5%)); 40 | } 41 | 42 | li.user-header { 43 | background-color: @yellow; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-dark-sidebar(@yellow); 54 | } 55 | -------------------------------------------------------------------------------- /resources/views/errors/503.blade.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Be right back. 5 | 6 | 7 | 8 | 39 | 40 | 41 |
42 |
43 |
Be right back.
44 |
45 |
46 | 47 | 48 | -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Goods/GoodsEvaluate.php: -------------------------------------------------------------------------------- 1 | user(); 35 | } 36 | 37 | /** 38 | * 关联的商品 39 | * 40 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 41 | */ 42 | public function goods() 43 | { 44 | return $this->belongsTo(Goods::class, 'goods_id', 'id'); 45 | } 46 | 47 | /** 48 | * 关联的评价 49 | * 50 | * @return \Illuminate\Database\Eloquent\Relations\HasMany 51 | */ 52 | public function comments() 53 | { 54 | return $this->hasMany(GoodsComment::class, 'evaluate_id', 'id'); 55 | } 56 | } -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/mixins/buttons.less: -------------------------------------------------------------------------------- 1 | // Button variants 2 | // 3 | // Easily pump out default styles, as well as :hover, :focus, :active, 4 | // and disabled options for all buttons 5 | 6 | .button-variant(@color; @background; @border) { 7 | color: @color; 8 | background-color: @background; 9 | border-color: @border; 10 | 11 | &:hover, 12 | &:focus, 13 | &.focus, 14 | &:active, 15 | &.active, 16 | .open > .dropdown-toggle& { 17 | color: @color; 18 | background-color: darken(@background, 10%); 19 | border-color: darken(@border, 12%); 20 | } 21 | &:active, 22 | &.active, 23 | .open > .dropdown-toggle& { 24 | background-image: none; 25 | } 26 | &.disabled, 27 | &[disabled], 28 | fieldset[disabled] & { 29 | &, 30 | &:hover, 31 | &:focus, 32 | &.focus, 33 | &:active, 34 | &.active { 35 | background-color: @background; 36 | border-color: @border; 37 | } 38 | } 39 | 40 | .badge { 41 | color: @background; 42 | background-color: @color; 43 | } 44 | } 45 | 46 | // Button sizes 47 | .button-size(@padding-vertical; @padding-horizontal; @font-size; @line-height; @border-radius) { 48 | padding: @padding-vertical @padding-horizontal; 49 | font-size: @font-size; 50 | line-height: @line-height; 51 | border-radius: @border-radius; 52 | } 53 | -------------------------------------------------------------------------------- /gulpfile.js: -------------------------------------------------------------------------------- 1 | var elixir = require('laravel-elixir'); 2 | 3 | require('./resources/elixir-extensions/elixir-uglify'); 4 | 5 | /* 6 | |-------------------------------------------------------------------------- 7 | | Elixir Asset Management 8 | |-------------------------------------------------------------------------- 9 | | 10 | | Elixir provides a clean, fluent API for defining some basic Gulp tasks 11 | | for your Laravel application. By default, we are compiling the Sass 12 | | file for our application, as well as publishing vendor resources. 13 | | 14 | */ 15 | 16 | elixir(function (mix) { 17 | // PowerManagement 18 | mix.less('adminlte/AdminLTE.less', 'public/assets/power-m/css/app.min.css', {compress: true}) 19 | .less('adminlte/skins/skin-purple.less', 'public/assets/power-m/css/all-skins.min.css', {compress: true}) 20 | .less('bootstrap-less/bootstrap.less', 'public/assets/common/css/bootstrap.min.css', {compress: true}) 21 | .scripts(['app.js', 'plugins/jquery.slimscroll.min.js'], 'public/assets/power-m/js/app.js') 22 | .uglify('public/assets/power-m/js/app.js', 'public/assets/power-m/js'); 23 | 24 | mix.version([ 25 | 'assets/power-m/css/app.min.css', 26 | 'assets/power-m/css/all-skins.min.css', 27 | 'assets/power-m/js/app.min.js', 28 | 'assets/common/css/bootstrap.min.css' 29 | ]); 30 | }); 31 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/bootstrap.less: -------------------------------------------------------------------------------- 1 | // Core variables and mixins 2 | @import "variables.less"; 3 | @import "mixins.less"; 4 | 5 | // Reset and dependencies 6 | @import "normalize.less"; 7 | @import "print.less"; 8 | @import "glyphicons.less"; 9 | 10 | // Core CSS 11 | @import "scaffolding.less"; 12 | @import "type.less"; 13 | @import "code.less"; 14 | @import "grid.less"; 15 | @import "tables.less"; 16 | @import "forms.less"; 17 | @import "buttons.less"; 18 | 19 | // Components 20 | @import "component-animations.less"; 21 | @import "dropdowns.less"; 22 | @import "button-groups.less"; 23 | @import "input-groups.less"; 24 | @import "navs.less"; 25 | @import "navbar.less"; 26 | @import "breadcrumbs.less"; 27 | @import "pagination.less"; 28 | @import "pager.less"; 29 | @import "labels.less"; 30 | @import "badges.less"; 31 | @import "jumbotron.less"; 32 | @import "thumbnails.less"; 33 | @import "alerts.less"; 34 | @import "progress-bars.less"; 35 | @import "media.less"; 36 | @import "list-group.less"; 37 | @import "panels.less"; 38 | @import "responsive-embed.less"; 39 | @import "wells.less"; 40 | @import "close.less"; 41 | 42 | // Components w/ JavaScript 43 | @import "modals.less"; 44 | @import "tooltip.less"; 45 | @import "popovers.less"; 46 | @import "carousel.less"; 47 | 48 | // Utility classes 49 | @import "utilities.less"; 50 | @import "responsive-utilities.less"; 51 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/index.less: -------------------------------------------------------------------------------- 1 | // Core variables and mixins 2 | @import "variables.less"; 3 | @import "mixins.less"; 4 | 5 | // Reset and dependencies 6 | @import "normalize.less"; 7 | @import "print.less"; 8 | @import "glyphicons.less"; 9 | 10 | // Core CSS 11 | @import "scaffolding.less"; 12 | @import "type.less"; 13 | @import "code.less"; 14 | @import "grid.less"; 15 | @import "tables.less"; 16 | @import "forms.less"; 17 | @import "buttons.less"; 18 | 19 | // Components 20 | @import "component-animations.less"; 21 | @import "dropdowns.less"; 22 | @import "button-groups.less"; 23 | @import "input-groups.less"; 24 | @import "navs.less"; 25 | @import "navbar.less"; 26 | @import "breadcrumbs.less"; 27 | @import "pagination.less"; 28 | @import "pager.less"; 29 | @import "labels.less"; 30 | @import "badges.less"; 31 | @import "jumbotron.less"; 32 | @import "thumbnails.less"; 33 | @import "alerts.less"; 34 | @import "progress-bars.less"; 35 | @import "media.less"; 36 | @import "list-group.less"; 37 | @import "panels.less"; 38 | @import "responsive-embed.less"; 39 | @import "wells.less"; 40 | @import "close.less"; 41 | 42 | // Components w/ JavaScript 43 | @import "modals.less"; 44 | @import "tooltip.less"; 45 | @import "popovers.less"; 46 | @import "carousel.less"; 47 | 48 | // Utility classes 49 | @import "utilities.less"; 50 | @import "responsive-utilities.less"; 51 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/labels.less: -------------------------------------------------------------------------------- 1 | // 2 | // Labels 3 | // -------------------------------------------------- 4 | 5 | .label { 6 | display: inline; 7 | padding: .2em .6em .3em; 8 | font-size: 75%; 9 | font-weight: bold; 10 | line-height: 1; 11 | color: @label-color; 12 | text-align: center; 13 | white-space: nowrap; 14 | vertical-align: baseline; 15 | border-radius: .25em; 16 | 17 | // Add hover effects, but only for links 18 | a& { 19 | &:hover, 20 | &:focus { 21 | color: @label-link-hover-color; 22 | text-decoration: none; 23 | cursor: pointer; 24 | } 25 | } 26 | 27 | // Empty labels collapse automatically (not available in IE8) 28 | &:empty { 29 | display: none; 30 | } 31 | 32 | // Quick fix for labels in buttons 33 | .btn & { 34 | position: relative; 35 | top: -1px; 36 | } 37 | } 38 | 39 | // Colors 40 | // Contextual variations (linked labels get darker on :hover) 41 | 42 | .label-default { 43 | .label-variant(@label-default-bg); 44 | } 45 | 46 | .label-primary { 47 | .label-variant(@label-primary-bg); 48 | } 49 | 50 | .label-success { 51 | .label-variant(@label-success-bg); 52 | } 53 | 54 | .label-info { 55 | .label-variant(@label-info-bg); 56 | } 57 | 58 | .label-warning { 59 | .label-variant(@label-warning-bg); 60 | } 61 | 62 | .label-danger { 63 | .label-variant(@label-danger-bg); 64 | } 65 | -------------------------------------------------------------------------------- /tests/PowerManagement/SidebarManagerTest.php: -------------------------------------------------------------------------------- 1 | sidebarManager->add('test', []); 17 | $this->sidebarManager->add('header', [], true); 18 | $this->sidebarManager->add('test-multi.a', []); 19 | $this->sidebarManager->add('test-multi.b', []); 20 | $this->sidebarManager->add('test-multi.b.foo', []); 21 | 22 | $this->assertAttributeEquals([ 23 | 'test' => 'test', 24 | 'header' => null, 25 | 'test-multi' => [ 26 | 'a' => 'test-multi.a', 27 | 'b' => [ 28 | 'foo' => 'test-multi.b.foo', 29 | ], 30 | ], 31 | ], 'items', $this->sidebarManager); 32 | } 33 | 34 | /** 35 | * Setup the test environment. 36 | * 37 | * @return void 38 | */ 39 | protected function setUp() 40 | { 41 | parent::setUp(); 42 | 43 | $this->sidebarManager = new \ActLoudBur\PowerManagement\Frame\SidebarManager(); 44 | } 45 | 46 | 47 | } 48 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-blue.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Blue 3 | * ---------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-blue { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@light-blue; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@light-blue, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@light-blue, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(darken(@light-blue, 5%)); 40 | } 41 | 42 | li.user-header { 43 | background-color: @light-blue; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-dark-sidebar(@light-blue); 54 | } 55 | 56 | .skin-blue.layout-top-nav .main-header > .logo { 57 | .logo-variant(@light-blue); 58 | } 59 | -------------------------------------------------------------------------------- /app/Foundation/Exceptions/Handler.php: -------------------------------------------------------------------------------- 1 | img { 41 | max-width: 100%; 42 | } 43 | } 44 | 45 | .info-box-content { 46 | padding: 5px 10px; 47 | margin-left: 90px; 48 | } 49 | 50 | .info-box-number { 51 | display: block; 52 | font-weight: bold; 53 | font-size: 18px; 54 | } 55 | 56 | .progress-description, 57 | .info-box-text { 58 | display: block; 59 | font-size: 14px; 60 | white-space: nowrap; 61 | overflow: hidden; 62 | text-overflow: ellipsis; 63 | } 64 | 65 | .info-box-text { 66 | text-transform: uppercase; 67 | } 68 | 69 | .info-box-more { 70 | display: block; 71 | } 72 | 73 | .progress-description { 74 | margin: 0; 75 | } 76 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/lockscreen.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Page: Lock Screen 3 | * ----------------- 4 | */ 5 | /* ADD THIS CLASS TO THE TAG */ 6 | .lockscreen { 7 | background: @gray; 8 | } 9 | 10 | .lockscreen-logo { 11 | font-size: 35px; 12 | text-align: center; 13 | margin-bottom: 25px; 14 | font-weight: 300; 15 | a { 16 | color: #444; 17 | } 18 | } 19 | 20 | .lockscreen-wrapper { 21 | max-width: 400px; 22 | margin: 0 auto; 23 | margin-top: 10%; 24 | } 25 | 26 | /* User name [optional] */ 27 | .lockscreen .lockscreen-name { 28 | text-align: center; 29 | font-weight: 600; 30 | } 31 | 32 | /* Will contain the image and the sign in form */ 33 | .lockscreen-item { 34 | .border-radius(4px); 35 | padding: 0; 36 | background: #fff; 37 | position: relative; 38 | margin: 10px auto 30px auto; 39 | width: 290px; 40 | } 41 | 42 | /* User image */ 43 | .lockscreen-image { 44 | .border-radius(50%); 45 | position: absolute; 46 | left: -10px; 47 | top: -25px; 48 | background: #fff; 49 | padding: 5px; 50 | z-index: 10; 51 | > img { 52 | .border-radius(50%); 53 | width: 70px; 54 | height: 70px; 55 | } 56 | } 57 | 58 | /* Contains the password input and the login button */ 59 | .lockscreen-credentials { 60 | margin-left: 70px; 61 | .form-control { 62 | border: 0; 63 | } 64 | .btn { 65 | background-color: #fff; 66 | border: 0; 67 | padding: 0 10px; 68 | } 69 | } 70 | 71 | .lockscreen-footer { 72 | margin-top: 10px; 73 | } 74 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/badges.less: -------------------------------------------------------------------------------- 1 | // 2 | // Badges 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base class 7 | .badge { 8 | display: inline-block; 9 | min-width: 10px; 10 | padding: 3px 7px; 11 | font-size: @font-size-small; 12 | font-weight: @badge-font-weight; 13 | color: @badge-color; 14 | line-height: @badge-line-height; 15 | vertical-align: baseline; 16 | white-space: nowrap; 17 | text-align: center; 18 | background-color: @badge-bg; 19 | border-radius: @badge-border-radius; 20 | 21 | // Empty badges collapse automatically (not available in IE8) 22 | &:empty { 23 | display: none; 24 | } 25 | 26 | // Quick fix for badges in buttons 27 | .btn & { 28 | position: relative; 29 | top: -1px; 30 | } 31 | 32 | .btn-xs & { 33 | top: 0; 34 | padding: 1px 5px; 35 | } 36 | 37 | // Hover state, but only for links 38 | a& { 39 | &:hover, 40 | &:focus { 41 | color: @badge-link-hover-color; 42 | text-decoration: none; 43 | cursor: pointer; 44 | } 45 | } 46 | 47 | // Account for badges in navs 48 | .list-group-item.active > &, 49 | .nav-pills > .active > a > & { 50 | color: @badge-active-color; 51 | background-color: @badge-active-bg; 52 | } 53 | 54 | .list-group-item > & { 55 | float: right; 56 | } 57 | 58 | .list-group-item > & + & { 59 | margin-right: 5px; 60 | } 61 | 62 | .nav-pills > li > a > & { 63 | margin-left: 3px; 64 | } 65 | } 66 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-blue-light.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Blue 3 | * ---------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | .skin-blue-light { 11 | //Navbar 12 | .main-header { 13 | .navbar { 14 | .navbar-variant(@light-blue; #fff); 15 | .sidebar-toggle { 16 | color: #fff; 17 | &:hover { 18 | background-color: darken(@light-blue, 5%); 19 | } 20 | } 21 | @media (max-width: @screen-header-collapse) { 22 | .dropdown-menu { 23 | li { 24 | &.divider { 25 | background-color: rgba(255, 255, 255, 0.1); 26 | } 27 | a { 28 | color: #fff; 29 | &:hover { 30 | background: darken(@light-blue, 5%); 31 | } 32 | } 33 | } 34 | } 35 | } 36 | } 37 | //Logo 38 | .logo { 39 | .logo-variant(@light-blue); 40 | } 41 | 42 | li.user-header { 43 | background-color: @light-blue; 44 | } 45 | } 46 | 47 | //Content Header 48 | .content-header { 49 | background: transparent; 50 | } 51 | 52 | //Create the sidebar skin 53 | .skin-light-sidebar(@light-blue); 54 | .main-footer { 55 | border-top-color: @gray; 56 | } 57 | } 58 | 59 | .skin-blue.layout-top-nav .main-header > .logo { 60 | .logo-variant(@light-blue); 61 | } 62 | -------------------------------------------------------------------------------- /app/PowerManagement/Http/Controllers/AdminPanel/Member/UserController.php: -------------------------------------------------------------------------------- 1 | query('search')) { 35 | $query->where(function (Builder $query) use ($search) { 36 | $query->where('name', 'like', "%$search%") 37 | ->orWhere('email', 'like', "%$search%") 38 | ->orWhere('id', $search); 39 | }); 40 | } 41 | 42 | $collection = $query->paginate($request->query('per_page', parent::PER_PAGE)); 43 | 44 | return view('power-management.admin.member.user.index', ['collection' => $collection, 'request' => $request]); 45 | } 46 | } -------------------------------------------------------------------------------- /app/Business/OrderSystem/OrderSpecification.php: -------------------------------------------------------------------------------- 1 | order()->getResults(); 33 | } 34 | 35 | /** 36 | * 关联的订单 37 | * 38 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 39 | */ 40 | public function order() 41 | { 42 | return $this->belongsTo(Order::class, 'order_id', 'id'); 43 | } 44 | 45 | /** 46 | * 获取订单档案 47 | * 48 | * @return OrderArchive 49 | */ 50 | public function getArchive() 51 | { 52 | return $this->archive()->getResults(); 53 | } 54 | 55 | /** 56 | * 关联的订单档案 57 | * 58 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 59 | */ 60 | public function archive() 61 | { 62 | return $this->belongsTo(OrderArchive::class, 'archive_id', 'id'); 63 | } 64 | 65 | 66 | } -------------------------------------------------------------------------------- /app/PowerManagement/Http/Middleware/SellerCentral.php: -------------------------------------------------------------------------------- 1 | sidebar = $sidebar; 40 | } 41 | 42 | public function handle($request, Closure $next) 43 | { 44 | if (Auth::guard('web')->guest()) { 45 | return redirect()->route('power-m.auth.login-form'); 46 | } 47 | 48 | // 验证通过则表示可以展示面板数据 49 | // 添加自定义分页样式 50 | Paginator::presenter(function (AbstractPaginator $paginator) { 51 | return new BootstrapPaginationPresenter($paginator); 52 | }); 53 | 54 | // 生成侧边栏 55 | $this->generateSideBar(); 56 | 57 | return $next($request); 58 | } 59 | 60 | protected function generateSideBar() 61 | { 62 | 63 | } 64 | } -------------------------------------------------------------------------------- /config/broadcasting.php: -------------------------------------------------------------------------------- 1 | env('BROADCAST_DRIVER', 'pusher'), 17 | 18 | /* 19 | |-------------------------------------------------------------------------- 20 | | Broadcast Connections 21 | |-------------------------------------------------------------------------- 22 | | 23 | | Here you may define all of the broadcast connections that will be used 24 | | to broadcast events to other systems or over websockets. Samples of 25 | | each available type of connection are provided inside this array. 26 | | 27 | */ 28 | 29 | 'connections' => [ 30 | 31 | 'pusher' => [ 32 | 'driver' => 'pusher', 33 | 'key' => env('PUSHER_KEY'), 34 | 'secret' => env('PUSHER_SECRET'), 35 | 'app_id' => env('PUSHER_APP_ID'), 36 | 'options' => [ 37 | // 38 | ], 39 | ], 40 | 41 | 'redis' => [ 42 | 'driver' => 'redis', 43 | 'connection' => 'default', 44 | ], 45 | 46 | 'log' => [ 47 | 'driver' => 'log', 48 | ], 49 | 50 | ], 51 | 52 | ]; 53 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-black-light.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Black 3 | * ----------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | /* skin-black navbar */ 11 | .skin-black-light { 12 | //Navbar & Logo 13 | .main-header { 14 | .box-shadow(0px 1px 1px rgba(0, 0, 0, 0.05)); 15 | .navbar-toggle { 16 | color: #333; 17 | } 18 | .navbar-brand { 19 | color: #333; 20 | border-right: 1px solid #eee; 21 | } 22 | .navbar { 23 | .navbar-variant(#fff; #333; #999; #fff); 24 | > .sidebar-toggle { 25 | color: #333; 26 | border-right: 1px solid #eee; 27 | } 28 | .navbar-nav { 29 | > li > a { 30 | border-right: 1px solid #eee; 31 | } 32 | } 33 | .navbar-custom-menu .navbar-nav, 34 | .navbar-right { 35 | > li { 36 | > a { 37 | border-left: 1px solid #eee; 38 | border-right-width: 0; 39 | } 40 | } 41 | } 42 | } 43 | > .logo { 44 | .logo-variant(#fff; #333); 45 | border-right: 1px solid #eee; 46 | @media (max-width: @screen-header-collapse) { 47 | .logo-variant(#222; #fff); 48 | border-right: none; 49 | } 50 | } 51 | 52 | li.user-header { 53 | background-color: #222; 54 | } 55 | } 56 | 57 | //Content Header 58 | .content-header { 59 | background: transparent; 60 | box-shadow: none; 61 | } 62 | //Create the sidebar skin 63 | .skin-light-sidebar(#fff); 64 | } 65 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/mailbox.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Page: Mailbox 3 | * ------------- 4 | */ 5 | .mailbox-messages { 6 | > .table { 7 | margin: 0; 8 | } 9 | } 10 | 11 | .mailbox-controls { 12 | padding: 5px; 13 | &.with-border { 14 | border-bottom: 1px solid @box-border-color; 15 | } 16 | } 17 | 18 | .mailbox-read-info { 19 | border-bottom: 1px solid @box-border-color; 20 | padding: 10px; 21 | h3 { 22 | font-size: 20px; 23 | margin: 0; 24 | } 25 | h5 { 26 | margin: 0; 27 | padding: 5px 0 0 0; 28 | } 29 | } 30 | 31 | .mailbox-read-time { 32 | color: #999; 33 | font-size: 13px; 34 | } 35 | 36 | .mailbox-read-message { 37 | padding: 10px; 38 | } 39 | 40 | .mailbox-attachments { 41 | &:extend(.list-unstyled); 42 | li { 43 | float: left; 44 | width: 200px; 45 | border: 1px solid #eee; 46 | margin-bottom: 10px; 47 | margin-right: 10px; 48 | } 49 | } 50 | 51 | .mailbox-attachment-name { 52 | font-weight: bold; 53 | color: #666; 54 | } 55 | 56 | .mailbox-attachment-icon, 57 | .mailbox-attachment-info, 58 | .mailbox-attachment-size { 59 | display: block; 60 | } 61 | 62 | .mailbox-attachment-info { 63 | padding: 10px; 64 | background: #f4f4f4; 65 | } 66 | 67 | .mailbox-attachment-size { 68 | color: #999; 69 | font-size: 12px; 70 | } 71 | 72 | .mailbox-attachment-icon { 73 | text-align: center; 74 | font-size: 65px; 75 | color: #666; 76 | padding: 20px 10px; 77 | &.has-img { 78 | padding: 0; 79 | > img { 80 | max-width: 100%; 81 | height: auto; 82 | } 83 | } 84 | } 85 | 86 | .mailbox-attachment-close { 87 | &:extend(.close); 88 | } 89 | -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "dybasedev/actloudbur", 3 | "description": "Used to quickly build electric business platform", 4 | "keywords": ["business", "laravel"], 5 | "license": "MIT", 6 | "type": "project", 7 | "require": { 8 | "php": ">=5.5.9", 9 | "laravel/framework": "5.2.*", 10 | "barryvdh/laravel-ide-helper": "^2.2", 11 | "laravel/homestead": "^3.0", 12 | "zedisdog/laravel-schema-extend": "^0.6.0" 13 | }, 14 | "require-dev": { 15 | "fzaninotto/faker": "~1.4", 16 | "mockery/mockery": "0.9.*", 17 | "phpunit/phpunit": "~4.0", 18 | "symfony/css-selector": "2.8.*|3.0.*", 19 | "symfony/dom-crawler": "2.8.*|3.0.*" 20 | }, 21 | "autoload": { 22 | "classmap": [ 23 | "database" 24 | ], 25 | "psr-4": { 26 | "ActLoudBur\\": "app/" 27 | } 28 | }, 29 | "autoload-dev": { 30 | "classmap": [ 31 | "tests/TestCase.php" 32 | ] 33 | }, 34 | "scripts": { 35 | "post-root-package-install": [ 36 | "php -r \"copy('.env.example', '.env');\"" 37 | ], 38 | "post-create-project-cmd": [ 39 | "php artisan key:generate" 40 | ], 41 | "post-install-cmd": [ 42 | "Illuminate\\Foundation\\ComposerScripts::postInstall", 43 | "php artisan optimize" 44 | ], 45 | "post-update-cmd": [ 46 | "Illuminate\\Foundation\\ComposerScripts::postUpdate", 47 | "php artisan optimize" 48 | ] 49 | }, 50 | "config": { 51 | "preferred-install": "dist" 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/modal.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: modal 3 | * ---------------- 4 | */ 5 | .modal { 6 | background: rgba(0, 0, 0, .3); 7 | } 8 | 9 | .modal-content { 10 | .border-radius(0); 11 | .box-shadow(0 2px 3px rgba(0, 0, 0, .125)); 12 | border: 0; 13 | @media (min-width: @screen-sm-min) { 14 | .box-shadow(0 2px 3px rgba(0, 0, 0, .125)); 15 | } 16 | } 17 | 18 | .modal-header { 19 | border-bottom-color: @box-border-color; 20 | } 21 | 22 | .modal-footer { 23 | border-top-color: @box-border-color; 24 | } 25 | 26 | //Modal variants 27 | .modal-primary { 28 | .modal-body { 29 | &:extend(.bg-light-blue); 30 | } 31 | .modal-header, 32 | .modal-footer { 33 | &:extend(.bg-light-blue-active); 34 | border-color: darken(@light-blue, 10%); 35 | } 36 | } 37 | 38 | .modal-warning { 39 | .modal-body { 40 | &:extend(.bg-yellow); 41 | } 42 | .modal-header, 43 | .modal-footer { 44 | &:extend(.bg-yellow-active); 45 | border-color: darken(@yellow, 10%); 46 | } 47 | } 48 | 49 | .modal-info { 50 | .modal-body { 51 | &:extend(.bg-aqua); 52 | } 53 | .modal-header, 54 | .modal-footer { 55 | &:extend(.bg-aqua-active); 56 | border-color: darken(@aqua, 10%); 57 | } 58 | } 59 | 60 | .modal-success { 61 | .modal-body { 62 | &:extend(.bg-green); 63 | } 64 | .modal-header, 65 | .modal-footer { 66 | &:extend(.bg-green-active); 67 | border-color: darken(@green, 10%); 68 | } 69 | } 70 | 71 | .modal-danger { 72 | .modal-body { 73 | &:extend(.bg-red); 74 | } 75 | .modal-header, 76 | .modal-footer { 77 | &:extend(.bg-red-active); 78 | border-color: darken(@red, 10%); 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /resources/views/power-management/common/sidebar.blade.php: -------------------------------------------------------------------------------- 1 | @if(isset($sidebarItems)) 2 | @foreach($sidebarItems as $name => $item) 3 | @if(is_null($item)) 4 |
  • {{ $sidebar->get($name)['title'] }}
  • 5 | @continue 6 | @endif 7 | @if(is_array($item)) 8 | get($fullName); 11 | ?> 12 |
  • 13 | 14 | {{ $itemData['title'] }} 15 | 16 | 17 | 18 | 19 | 22 |
  • 23 | @else 24 | get($item); ?> 25 |
  • 26 | 27 | {{ $itemData['title'] }} 28 | 29 | 30 | 31 | 32 |
  • 33 | @endif 34 | @endforeach 35 | @endif -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/code.less: -------------------------------------------------------------------------------- 1 | // 2 | // Code (inline and block) 3 | // -------------------------------------------------- 4 | 5 | 6 | // Inline and block code styles 7 | code, 8 | kbd, 9 | pre, 10 | samp { 11 | font-family: @font-family-monospace; 12 | } 13 | 14 | // Inline code 15 | code { 16 | padding: 2px 4px; 17 | font-size: 90%; 18 | color: @code-color; 19 | background-color: @code-bg; 20 | border-radius: @border-radius-base; 21 | } 22 | 23 | // User input typically entered via keyboard 24 | kbd { 25 | padding: 2px 4px; 26 | font-size: 90%; 27 | color: @kbd-color; 28 | background-color: @kbd-bg; 29 | border-radius: @border-radius-small; 30 | box-shadow: inset 0 -1px 0 rgba(0,0,0,.25); 31 | 32 | kbd { 33 | padding: 0; 34 | font-size: 100%; 35 | font-weight: bold; 36 | box-shadow: none; 37 | } 38 | } 39 | 40 | // Blocks of code 41 | pre { 42 | display: block; 43 | padding: ((@line-height-computed - 1) / 2); 44 | margin: 0 0 (@line-height-computed / 2); 45 | font-size: (@font-size-base - 1); // 14px to 13px 46 | line-height: @line-height-base; 47 | word-break: break-all; 48 | word-wrap: break-word; 49 | color: @pre-color; 50 | background-color: @pre-bg; 51 | border: 1px solid @pre-border-color; 52 | border-radius: @border-radius-base; 53 | 54 | // Account for some code outputs that place code tags in pre tags 55 | code { 56 | padding: 0; 57 | font-size: inherit; 58 | color: inherit; 59 | white-space: pre-wrap; 60 | background-color: transparent; 61 | border-radius: 0; 62 | } 63 | } 64 | 65 | // Enable scrollable blocks of code 66 | .pre-scrollable { 67 | max-height: @pre-scrollable-max-height; 68 | overflow-y: scroll; 69 | } 70 | -------------------------------------------------------------------------------- /app/Business/OrderSystem/OrderStatusHandler.php: -------------------------------------------------------------------------------- 1 | handlers[$code] = $handler; 56 | } else { 57 | throw new RuntimeException('Undefined handler class.'); 58 | } 59 | } 60 | /** 61 | * 获取状态控制器 62 | * 63 | * @param Order $order 64 | * @param $code 65 | * 66 | * @return OrderStatusInterface 67 | */ 68 | public function getHandler(Order $order, $code) 69 | { 70 | if (is_null($code)) { 71 | return null; 72 | } 73 | 74 | $handlerClass = $this->handlers[$code]; 75 | 76 | return new $handlerClass($order); 77 | } 78 | } -------------------------------------------------------------------------------- /app/PowerManagement/Frame/SidebarManager.php: -------------------------------------------------------------------------------- 1 | items, $name, $header ? null : $name); 44 | 45 | $this->itemDataSet[$name] = $parameters; 46 | 47 | return $this; 48 | } 49 | 50 | /** 51 | * @param null $name 52 | * 53 | * @return mixed 54 | */ 55 | public function get($name = null) 56 | { 57 | if (is_null($name)) { 58 | return $this->items; 59 | } 60 | 61 | return $this->itemDataSet[$name]; 62 | } 63 | 64 | /** 65 | * Retrieve an external iterator 66 | * @link http://php.net/manual/en/iteratoraggregate.getiterator.php 67 | * @return Traversable An instance of an object implementing Iterator or 68 | * Traversable 69 | * @since 5.0.0 70 | */ 71 | public function getIterator() 72 | { 73 | return new ArrayIterator($this->items); 74 | } 75 | } -------------------------------------------------------------------------------- /resources/assets/less/adminlte/social-widgets.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Social Widgets 3 | * ------------------------- 4 | */ 5 | //General widget style 6 | .box-widget { 7 | border: none; 8 | position: relative; 9 | } 10 | 11 | //User Widget Style 1 12 | .widget-user { 13 | //User name container 14 | .widget-user-header { 15 | padding: 20px; 16 | height: 120px; 17 | .border-top-radius(@box-border-radius); 18 | } 19 | //User name 20 | .widget-user-username { 21 | margin-top: 0; 22 | margin-bottom: 5px; 23 | font-size: 25px; 24 | font-weight: 300; 25 | text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2); 26 | } 27 | //User single line description 28 | .widget-user-desc { 29 | margin-top: 0; 30 | } 31 | //User image container 32 | .widget-user-image { 33 | position: absolute; 34 | top: 65px; 35 | left: 50%; 36 | margin-left: -45px; 37 | > img { 38 | width: 90px; 39 | height: auto; 40 | border: 3px solid #fff; 41 | } 42 | } 43 | .box-footer { 44 | padding-top: 30px; 45 | } 46 | } 47 | 48 | //User Widget Style 2 49 | .widget-user-2 { 50 | //User name container 51 | .widget-user-header { 52 | padding: 20px; 53 | .border-top-radius(@box-border-radius); 54 | } 55 | //User name 56 | .widget-user-username { 57 | margin-top: 5px; 58 | margin-bottom: 5px; 59 | font-size: 25px; 60 | font-weight: 300; 61 | } 62 | //User single line description 63 | .widget-user-desc { 64 | margin-top: 0; 65 | } 66 | .widget-user-username, 67 | .widget-user-desc { 68 | margin-left: 75px; 69 | } 70 | //User image container 71 | .widget-user-image { 72 | > img { 73 | width: 65px; 74 | height: auto; 75 | float: left; 76 | } 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/grid.less: -------------------------------------------------------------------------------- 1 | // 2 | // Grid system 3 | // -------------------------------------------------- 4 | 5 | 6 | // Container widths 7 | // 8 | // Set the container width, and override it for fixed navbars in media queries. 9 | 10 | .container { 11 | .container-fixed(); 12 | 13 | @media (min-width: @screen-sm-min) { 14 | width: @container-sm; 15 | } 16 | @media (min-width: @screen-md-min) { 17 | width: @container-md; 18 | } 19 | @media (min-width: @screen-lg-min) { 20 | width: @container-lg; 21 | } 22 | } 23 | 24 | 25 | // Fluid container 26 | // 27 | // Utilizes the mixin meant for fixed width containers, but without any defined 28 | // width for fluid, full width layouts. 29 | 30 | .container-fluid { 31 | .container-fixed(); 32 | } 33 | 34 | 35 | // Row 36 | // 37 | // Rows contain and clear the floats of your columns. 38 | 39 | .row { 40 | .make-row(); 41 | } 42 | 43 | 44 | // Columns 45 | // 46 | // Common styles for small and large grid columns 47 | 48 | .make-grid-columns(); 49 | 50 | 51 | // Extra small grid 52 | // 53 | // Columns, offsets, pushes, and pulls for extra small devices like 54 | // smartphones. 55 | 56 | .make-grid(xs); 57 | 58 | 59 | // Small grid 60 | // 61 | // Columns, offsets, pushes, and pulls for the small device range, from phones 62 | // to tablets. 63 | 64 | @media (min-width: @screen-sm-min) { 65 | .make-grid(sm); 66 | } 67 | 68 | 69 | // Medium grid 70 | // 71 | // Columns, offsets, pushes, and pulls for the desktop device range. 72 | 73 | @media (min-width: @screen-md-min) { 74 | .make-grid(md); 75 | } 76 | 77 | 78 | // Large grid 79 | // 80 | // Columns, offsets, pushes, and pulls for the large desktop device range. 81 | 82 | @media (min-width: @screen-lg-min) { 83 | .make-grid(lg); 84 | } 85 | -------------------------------------------------------------------------------- /app/Business/OrderSystem/OrderArchive.php: -------------------------------------------------------------------------------- 1 | belongsTo(Order::class, 'order_id', 'id'); 34 | } 35 | 36 | /** 37 | * 获取订单主体 38 | * 39 | * @return Order 40 | */ 41 | public function getOrder() 42 | { 43 | return $this->order()->getResults(); 44 | } 45 | 46 | /** 47 | * 获取订单明细 48 | * 49 | * @param Closure $callback 查询回调 50 | * 51 | * @return Collection 52 | */ 53 | public function getSpecifications(Closure $callback = null) 54 | { 55 | if (is_null($callback)) { 56 | return $this->specifications()->getResults(); 57 | } 58 | 59 | return call_user_func($callback, $this->specifications()->getQuery()); 60 | } 61 | 62 | /** 63 | * 关联的订单明细 64 | * 65 | * @return \Illuminate\Database\Eloquent\Relations\HasMany 66 | */ 67 | public function specifications() 68 | { 69 | return $this->hasMany(OrderSpecification::class, 'archive_id', 'id'); 70 | } 71 | 72 | 73 | } -------------------------------------------------------------------------------- /app/Business/SupplyChain/Consumables/Goods/Goods.php: -------------------------------------------------------------------------------- 1 | belongsTo(Store::class, 'store_id', 'id'); 32 | } 33 | 34 | /** 35 | * 关联的分类 36 | * 37 | * @return \Illuminate\Database\Eloquent\Relations\BelongsTo 38 | */ 39 | public function category() 40 | { 41 | return $this->belongsTo(Category::class, 'category_id', 'id'); 42 | } 43 | 44 | /** 45 | * 关联的发布者 46 | * 47 | * @return \Illuminate\Database\Eloquent\Relations\MorphTo 48 | */ 49 | public function publisher() 50 | { 51 | return $this->morphTo(); 52 | } 53 | 54 | /** 55 | * 关联所属的商品 SKU 对象 56 | * 57 | * @return \Illuminate\Database\Eloquent\Relations\HasMany 58 | */ 59 | public function skuItems() 60 | { 61 | return $this->hasMany(GoodsSpecification::class, 'goods_id', 'id'); 62 | } 63 | 64 | /** 65 | * 关联的商品评价 66 | * 67 | * @return \Illuminate\Database\Eloquent\Relations\HasMany 68 | */ 69 | public function evaluates() 70 | { 71 | return $this->hasMany(GoodsEvaluate::class, 'goods_id', 'id'); 72 | } 73 | } -------------------------------------------------------------------------------- /resources/assets/less/adminlte/skins/skin-black.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Skin: Black 3 | * ----------- 4 | */ 5 | @import "../../bootstrap-less/mixins.less"; 6 | @import "../../bootstrap-less/variables.less"; 7 | @import "../variables.less"; 8 | @import "../mixins.less"; 9 | 10 | /* skin-black navbar */ 11 | .skin-black { 12 | //Navbar & Logo 13 | .main-header { 14 | .box-shadow(0px 1px 1px rgba(0, 0, 0, 0.05)); 15 | .navbar-toggle { 16 | color: #333; 17 | } 18 | .navbar-brand { 19 | color: #333; 20 | border-right: 1px solid #eee; 21 | } 22 | .navbar { 23 | .navbar-variant(#fff; #333; #999; #fff); 24 | > .sidebar-toggle { 25 | color: #333; 26 | border-right: 1px solid #eee; 27 | } 28 | .navbar-nav { 29 | > li > a { 30 | border-right: 1px solid #eee; 31 | } 32 | } 33 | .navbar-custom-menu .navbar-nav, 34 | .navbar-right { 35 | > li { 36 | > a { 37 | border-left: 1px solid #eee; 38 | border-right-width: 0; 39 | } 40 | } 41 | } 42 | } 43 | > .logo { 44 | .logo-variant(#fff; #333); 45 | border-right: 1px solid #eee; 46 | @media (max-width: @screen-header-collapse) { 47 | .logo-variant(#222; #fff); 48 | border-right: none; 49 | } 50 | } 51 | 52 | li.user-header { 53 | background-color: #222; 54 | } 55 | } 56 | 57 | //Content Header 58 | .content-header { 59 | background: transparent; 60 | box-shadow: none; 61 | } 62 | //Create the sidebar skin 63 | .skin-dark-sidebar(#fff); 64 | 65 | .pace { 66 | .pace-progress { 67 | background: #222; 68 | } 69 | .pace-activity { 70 | border-top-color: #222; 71 | border-left-color: #222; 72 | } 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /artisan: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env php 2 | make(Illuminate\Contracts\Console\Kernel::class); 32 | 33 | $status = $kernel->handle( 34 | $input = new Symfony\Component\Console\Input\ArgvInput, 35 | new Symfony\Component\Console\Output\ConsoleOutput 36 | ); 37 | 38 | /* 39 | |-------------------------------------------------------------------------- 40 | | Shutdown The Application 41 | |-------------------------------------------------------------------------- 42 | | 43 | | Once Artisan has finished running. We will fire off the shutdown events 44 | | so that any final work may be done by the application before we shut 45 | | down the process. This is the last thing to happen to the request. 46 | | 47 | */ 48 | 49 | $kernel->terminate($input, $status); 50 | 51 | exit($status); 52 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/small-box.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Small Box 3 | * -------------------- 4 | */ 5 | 6 | .small-box { 7 | .border-radius(2px); 8 | position: relative; 9 | display: block; 10 | margin-bottom: 20px; 11 | box-shadow: @box-boxshadow; 12 | // content wrapper 13 | > .inner { 14 | padding: 10px; 15 | } 16 | 17 | > .small-box-footer { 18 | position: relative; 19 | text-align: center; 20 | padding: 3px 0; 21 | color: #fff; 22 | color: rgba(255, 255, 255, 0.8); 23 | display: block; 24 | z-index: 10; 25 | background: rgba(0, 0, 0, 0.1); 26 | text-decoration: none; 27 | &:hover { 28 | color: #fff; 29 | background: rgba(0, 0, 0, 0.15); 30 | } 31 | } 32 | 33 | h3 { 34 | font-size: 38px; 35 | font-weight: bold; 36 | margin: 0 0 10px 0; 37 | white-space: nowrap; 38 | padding: 0; 39 | 40 | } 41 | 42 | p { 43 | font-size: 15px; 44 | > small { 45 | display: block; 46 | color: #f9f9f9; 47 | font-size: 13px; 48 | margin-top: 5px; 49 | } 50 | } 51 | 52 | h3, p { 53 | z-index: 5; 54 | } 55 | 56 | // the icon 57 | .icon { 58 | .transition(all @transition-speed linear); 59 | position: absolute; 60 | top: -10px; 61 | right: 10px; 62 | z-index: 0; 63 | font-size: 90px; 64 | color: rgba(0, 0, 0, 0.15); 65 | } 66 | 67 | // Small box hover state 68 | &:hover { 69 | text-decoration: none; 70 | color: #f9f9f9; 71 | // Animate icons on small box hover 72 | .icon { 73 | font-size: 95px; 74 | } 75 | } 76 | } 77 | 78 | @media (max-width: @screen-xs-max) { 79 | // No need for icons on very small devices 80 | .small-box { 81 | text-align: center; 82 | .icon { 83 | display: none; 84 | } 85 | p { 86 | font-size: 12px; 87 | } 88 | } 89 | } 90 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/alerts.less: -------------------------------------------------------------------------------- 1 | // 2 | // Alerts 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base styles 7 | // ------------------------- 8 | 9 | .alert { 10 | padding: @alert-padding; 11 | margin-bottom: @line-height-computed; 12 | border: 1px solid transparent; 13 | border-radius: @alert-border-radius; 14 | 15 | // Headings for larger alerts 16 | h4 { 17 | margin-top: 0; 18 | // Specified for the h4 to prevent conflicts of changing @headings-color 19 | color: inherit; 20 | } 21 | 22 | // Provide class for links that match alerts 23 | .alert-link { 24 | font-weight: @alert-link-font-weight; 25 | } 26 | 27 | // Improve alignment and spacing of inner content 28 | > p, 29 | > ul { 30 | margin-bottom: 0; 31 | } 32 | 33 | > p + p { 34 | margin-top: 5px; 35 | } 36 | } 37 | 38 | // Dismissible alerts 39 | // 40 | // Expand the right padding and account for the close button's positioning. 41 | 42 | .alert-dismissable, // The misspelled .alert-dismissable was deprecated in 3.2.0. 43 | .alert-dismissible { 44 | padding-right: (@alert-padding + 20); 45 | 46 | // Adjust close link position 47 | .close { 48 | position: relative; 49 | top: -2px; 50 | right: -21px; 51 | color: inherit; 52 | } 53 | } 54 | 55 | // Alternate styles 56 | // 57 | // Generate contextual modifier classes for colorizing the alert. 58 | 59 | .alert-success { 60 | .alert-variant(@alert-success-bg; @alert-success-border; @alert-success-text); 61 | } 62 | 63 | .alert-info { 64 | .alert-variant(@alert-info-bg; @alert-info-border; @alert-info-text); 65 | } 66 | 67 | .alert-warning { 68 | .alert-variant(@alert-warning-bg; @alert-warning-border; @alert-warning-text); 69 | } 70 | 71 | .alert-danger { 72 | .alert-variant(@alert-danger-bg; @alert-danger-border; @alert-danger-text); 73 | } 74 | -------------------------------------------------------------------------------- /bootstrap/app.php: -------------------------------------------------------------------------------- 1 | singleton( 30 | Illuminate\Contracts\Http\Kernel::class, 31 | ActLoudBur\Foundation\Http\Kernel::class 32 | ); 33 | 34 | $app->singleton( 35 | Illuminate\Contracts\Console\Kernel::class, 36 | ActLoudBur\Foundation\Console\Kernel::class 37 | ); 38 | 39 | $app->singleton( 40 | Illuminate\Contracts\Debug\ExceptionHandler::class, 41 | ActLoudBur\Foundation\Exceptions\Handler::class 42 | ); 43 | 44 | /* 45 | |-------------------------------------------------------------------------- 46 | | Return The Application 47 | |-------------------------------------------------------------------------- 48 | | 49 | | This script returns the application instance. The instance is given to 50 | | the calling script so we can separate the building of the instances 51 | | from the actual running of the application and sending responses. 52 | | 53 | */ 54 | 55 | return $app; 56 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/AdminLTE.less: -------------------------------------------------------------------------------- 1 | /*! 2 | * AdminLTE v2.3.4 3 | * Author: Almsaeed Studio 4 | * Website: Almsaeed Studio 5 | * License: Open source - MIT 6 | * Please visit http://opensource.org/licenses/MIT for more information 7 | !*/ 8 | //google fonts 9 | @import url(http://fonts.useso.com/css?family=Source+Sans+Pro:300,400,600,700,300italic,400italic,600italic); 10 | //Bootstrap Variables & Mixins 11 | //The core bootstrap code have not been modified. These files 12 | //are included only for reference. 13 | @import (reference) "../bootstrap-less/mixins.less"; 14 | @import (reference) "../bootstrap-less/variables.less"; 15 | //MISC 16 | //---- 17 | @import "core.less"; 18 | @import "variables.less"; 19 | @import "mixins.less"; 20 | //COMPONENTS 21 | //----------- 22 | @import "header.less"; 23 | @import "sidebar.less"; 24 | @import "sidebar-mini.less"; 25 | @import "control-sidebar.less"; 26 | @import "dropdown.less"; 27 | @import "forms.less"; 28 | @import "progress-bars.less"; 29 | @import "small-box.less"; 30 | @import "boxes.less"; 31 | @import "info-box.less"; 32 | @import "timeline.less"; 33 | @import "buttons.less"; 34 | @import "callout.less"; 35 | @import "alerts.less"; 36 | @import "navs.less"; 37 | @import "products.less"; 38 | @import "table.less"; 39 | @import "labels.less"; 40 | @import "direct-chat.less"; 41 | @import "users-list.less"; 42 | @import "carousel.less"; 43 | @import "modal.less"; 44 | @import "social-widgets.less"; 45 | //PAGES 46 | //------ 47 | @import "mailbox.less"; 48 | @import "lockscreen.less"; 49 | @import "login_and_register.less"; 50 | @import "404_500_errors.less"; 51 | @import "invoice.less"; 52 | @import "profile"; 53 | //Plugins 54 | //-------- 55 | @import "bootstrap-social.less"; 56 | @import "fullcalendar.less"; 57 | @import "select2.less"; 58 | //Miscellaneous 59 | //------------- 60 | @import "miscellaneous.less"; 61 | @import "print.less"; 62 | -------------------------------------------------------------------------------- /app/Foundation/Providers/RouteServiceProvider.php: -------------------------------------------------------------------------------- 1 | mapWebRoutes($router); 43 | 44 | // 45 | } 46 | 47 | /** 48 | * Define the "web" routes for the application. 49 | * 50 | * These routes all receive session state, CSRF protection, etc. 51 | * 52 | * @param \Illuminate\Routing\Router $router 53 | * 54 | * @return void 55 | */ 56 | protected function mapWebRoutes(Router $router) 57 | { 58 | $router->group(['namespace' => $this->namespace], function (Router $router) { 59 | // 60 | }); 61 | 62 | $repository = new ProviderRepository($this->app, $this->app->make(Filesystem::class), 63 | base_path('bootstrap/cache/router-services.php')); 64 | 65 | $repository->load($this->app['config']['router.providers']); 66 | } 67 | } 68 | -------------------------------------------------------------------------------- /public/index.php: -------------------------------------------------------------------------------- 1 | 8 | */ 9 | 10 | /* 11 | |-------------------------------------------------------------------------- 12 | | Register The Auto Loader 13 | |-------------------------------------------------------------------------- 14 | | 15 | | Composer provides a convenient, automatically generated class loader for 16 | | our application. We just need to utilize it! We'll simply require it 17 | | into the script here so that we don't have to worry about manual 18 | | loading any of our classes later on. It feels nice to relax. 19 | | 20 | */ 21 | 22 | require __DIR__.'/../bootstrap/autoload.php'; 23 | 24 | /* 25 | |-------------------------------------------------------------------------- 26 | | Turn On The Lights 27 | |-------------------------------------------------------------------------- 28 | | 29 | | We need to illuminate PHP development, so let us turn on the lights. 30 | | This bootstraps the framework and gets it ready for use, then it 31 | | will load up this application so that we can run it and send 32 | | the responses back to the browser and delight our users. 33 | | 34 | */ 35 | 36 | $app = require_once __DIR__.'/../bootstrap/app.php'; 37 | 38 | /* 39 | |-------------------------------------------------------------------------- 40 | | Run The Application 41 | |-------------------------------------------------------------------------- 42 | | 43 | | Once we have the application, we can handle the incoming request 44 | | through the kernel, and send the associated response back to 45 | | the client's browser allowing them to enjoy the creative 46 | | and wonderful application we have prepared for them. 47 | | 48 | */ 49 | 50 | $kernel = $app->make(Illuminate\Contracts\Http\Kernel::class); 51 | 52 | $response = $kernel->handle( 53 | $request = Illuminate\Http\Request::capture() 54 | ); 55 | 56 | $response->send(); 57 | 58 | $kernel->terminate($request, $response); 59 | -------------------------------------------------------------------------------- /app/PowerManagement/Providers/RouteServiceProvider.php: -------------------------------------------------------------------------------- 1 | group(['namespace' => $this->namespace, 'prefix' => 'admin', 'middleware' => ['web']], 38 | function (Router $router) { 39 | $router->group(['namespace' => 'AdminPanel', 'prefix' => 'web'], function (Router $router) { 40 | $router->get('login', ['uses' => 'AuthController@getLoginForm', 'as' => 'power-m.admin.auth.login-form']); 41 | $router->post('login', ['uses' => 'AuthController@login', 'as' => 'power-m.admin.auth.login']); 42 | $router->any('logout', ['uses' => 'AuthController@logout', 'as' => 'power-m.admin.auth.logout']); 43 | 44 | $router->group(['middleware' => ['admin-auth', 'admin-panel']], function (Router $router) { 45 | $router->get('dashboard', ['uses' => 'DashboardController@index', 'as' => 'power-m.admin.dashboard']); 46 | $router->resource('member/user', 'Member\UserController', 47 | ['names' => ['index' => 'power-m.admin.member.user.index']]); 48 | }); 49 | }); 50 | 51 | $router->get('/', 'AdminPanel\DashboardController@visit'); 52 | }); 53 | } 54 | 55 | } -------------------------------------------------------------------------------- /app/Business/Contracts/Order.php: -------------------------------------------------------------------------------- 1 | app = $app; 37 | } 38 | 39 | /** 40 | * @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View 41 | */ 42 | public function getLoginForm() 43 | { 44 | return view('power-management.login'); 45 | } 46 | 47 | /** 48 | * @param LoginRequest $request 49 | * 50 | * @return \Illuminate\Http\RedirectResponse 51 | */ 52 | public function login(LoginRequest $request) 53 | { 54 | if (Auth::guard($this->app['config']['power-m.auth.guard']) 55 | ->attempt($request->only([ 56 | $this->app['config']['power-m.auth.identifier'], 57 | $this->app['config']['power-m.auth.password'], 58 | ])) 59 | ) { 60 | return redirect()->route('power-m.dashboard'); 61 | } 62 | 63 | return back()->withErrors(['forbidden' => trans('auth.failed')]); 64 | } 65 | 66 | /** 67 | * @return \Illuminate\Http\RedirectResponse 68 | */ 69 | public function logout() 70 | { 71 | Auth::guard($this->app['config']['power-m.auth.guard'])->logout(); 72 | 73 | return back(); 74 | } 75 | } -------------------------------------------------------------------------------- /app/Foundation/Http/Kernel.php: -------------------------------------------------------------------------------- 1 | [ 29 | \ActLoudBur\Foundation\Http\Middleware\EncryptCookies::class, 30 | \Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class, 31 | \Illuminate\Session\Middleware\StartSession::class, 32 | \Illuminate\View\Middleware\ShareErrorsFromSession::class, 33 | \ActLoudBur\Foundation\Http\Middleware\VerifyCsrfToken::class, 34 | ], 35 | 36 | 'api' => [ 37 | 'throttle:60,1', 38 | ], 39 | ]; 40 | 41 | /** 42 | * The application's route middleware. 43 | * 44 | * These middleware may be assigned to groups or used individually. 45 | * 46 | * @var array 47 | */ 48 | protected $routeMiddleware = [ 49 | 'auth' => \ActLoudBur\Foundation\Http\Middleware\Authenticate::class, 50 | 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class, 51 | 'can' => \Illuminate\Foundation\Http\Middleware\Authorize::class, 52 | 'guest' => \ActLoudBur\Foundation\Http\Middleware\RedirectIfAuthenticated::class, 53 | 'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class, 54 | 'admin-panel' => AdministratorControlPanel::class, 55 | 'admin-auth' => AdminAuth::class, 56 | ]; 57 | } 58 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/fullcalendar.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Plugin: Full Calendar 3 | * --------------------- 4 | */ 5 | //Fullcalendar buttons 6 | .fc-button { 7 | background: #f4f4f4; 8 | background-image: none; 9 | color: #444; 10 | border-color: #ddd; 11 | border-bottom-color: #ddd; 12 | &:hover, 13 | &:active, 14 | &.hover { 15 | background-color: #e9e9e9; 16 | } 17 | } 18 | 19 | // Calendar title 20 | .fc-header-title h2 { 21 | font-size: 15px; 22 | line-height: 1.6em; 23 | color: #666; 24 | margin-left: 10px; 25 | } 26 | 27 | .fc-header-right { 28 | padding-right: 10px; 29 | } 30 | 31 | .fc-header-left { 32 | padding-left: 10px; 33 | } 34 | 35 | // Calendar table header cells 36 | .fc-widget-header { 37 | background: #fafafa; 38 | } 39 | 40 | .fc-grid { 41 | width: 100%; 42 | border: 0; 43 | } 44 | 45 | .fc-widget-header:first-of-type, 46 | .fc-widget-content:first-of-type { 47 | border-left: 0; 48 | border-right: 0; 49 | } 50 | 51 | .fc-widget-header:last-of-type, 52 | .fc-widget-content:last-of-type { 53 | border-right: 0; 54 | } 55 | 56 | .fc-toolbar { 57 | padding: @box-padding; 58 | margin: 0; 59 | } 60 | 61 | .fc-day-number { 62 | font-size: 20px; 63 | font-weight: 300; 64 | padding-right: 10px; 65 | } 66 | 67 | .fc-color-picker { 68 | list-style: none; 69 | margin: 0; 70 | padding: 0; 71 | > li { 72 | float: left; 73 | font-size: 30px; 74 | margin-right: 5px; 75 | line-height: 30px; 76 | .fa { 77 | .transition-transform(linear .3s); 78 | &:hover { 79 | .rotate(30deg); 80 | } 81 | } 82 | } 83 | } 84 | 85 | #add-new-event { 86 | .transition(all linear .3s); 87 | } 88 | 89 | .external-event { 90 | padding: 5px 10px; 91 | font-weight: bold; 92 | margin-bottom: 4px; 93 | box-shadow: @box-boxshadow; 94 | text-shadow: @box-boxshadow; 95 | border-radius: @box-border-radius; 96 | cursor: move; 97 | &:hover { 98 | box-shadow: inset 0 0 90px rgba(0, 0, 0, 0.2); 99 | } 100 | } 101 | -------------------------------------------------------------------------------- /app/PowerManagement/Http/Middleware/AdministratorControlPanel.php: -------------------------------------------------------------------------------- 1 | sidebar = $sidebar; 39 | } 40 | 41 | /** 42 | * @param $request 43 | * @param Closure $next 44 | */ 45 | public function handle($request, Closure $next) 46 | { 47 | // 添加自定义分页样式 48 | Paginator::presenter(function (AbstractPaginator $paginator) { 49 | return new BootstrapPaginationPresenter($paginator); 50 | }); 51 | 52 | $this->sidebar->add('quick-navigation', ['title' => trans('power-m.framework.quick-navigation')], true); 53 | $this->sidebar->add('dashboard', [ 54 | 'title' => trans('power-m.framework.dashboard'), 55 | 'href' => route('power-m.dashboard'), 56 | 'icon' => 'fa fa-dashboard', 57 | ]); 58 | $this->sidebar->add('module-navigation', ['title' => 'MODULE NAVIGATION'], true); 59 | $this->sidebar->add('member', ['title' => 'Member']); 60 | $this->sidebar->add('member.user', 61 | ['title' => 'User', 'href' => route('power-m.admin.member.user.index'), 'icon' => 'fa fa-user']); 62 | 63 | view()->share(['sidebarItems' => $this->sidebar, 'sidebar' => $this->sidebar]); 64 | 65 | return $next($request); 66 | } 67 | } -------------------------------------------------------------------------------- /config/filesystems.php: -------------------------------------------------------------------------------- 1 | 'local', 19 | 20 | /* 21 | |-------------------------------------------------------------------------- 22 | | Default Cloud Filesystem Disk 23 | |-------------------------------------------------------------------------- 24 | | 25 | | Many applications store files both locally and in the cloud. For this 26 | | reason, you may specify a default "cloud" driver here. This driver 27 | | will be bound as the Cloud disk implementation in the container. 28 | | 29 | */ 30 | 31 | 'cloud' => 's3', 32 | 33 | /* 34 | |-------------------------------------------------------------------------- 35 | | Filesystem Disks 36 | |-------------------------------------------------------------------------- 37 | | 38 | | Here you may configure as many filesystem "disks" as you wish, and you 39 | | may even configure multiple disks of the same driver. Defaults have 40 | | been setup for each driver as an example of the required options. 41 | | 42 | */ 43 | 44 | 'disks' => [ 45 | 46 | 'local' => [ 47 | 'driver' => 'local', 48 | 'root' => storage_path('app'), 49 | ], 50 | 51 | 'public' => [ 52 | 'driver' => 'local', 53 | 'root' => storage_path('app/public'), 54 | 'visibility' => 'public', 55 | ], 56 | 57 | 's3' => [ 58 | 'driver' => 's3', 59 | 'key' => 'your-key', 60 | 'secret' => 'your-secret', 61 | 'region' => 'your-region', 62 | 'bucket' => 'your-bucket', 63 | ], 64 | 65 | ], 66 | 67 | ]; 68 | -------------------------------------------------------------------------------- /app/Foundation/Http/Controllers/Auth/AuthController.php: -------------------------------------------------------------------------------- 1 | middleware($this->guestMiddleware(), ['except' => 'logout']); 41 | } 42 | 43 | /** 44 | * Get a validator for an incoming registration request. 45 | * 46 | * @param array $data 47 | * @return \Illuminate\Contracts\Validation\Validator 48 | */ 49 | protected function validator(array $data) 50 | { 51 | return Validator::make($data, [ 52 | 'name' => 'required|max:255', 53 | 'email' => 'required|email|max:255|unique:users', 54 | 'password' => 'required|min:6|confirmed', 55 | ]); 56 | } 57 | 58 | /** 59 | * Create a new user instance after a valid registration. 60 | * 61 | * @param array $data 62 | * @return User 63 | */ 64 | protected function create(array $data) 65 | { 66 | return User::create([ 67 | 'name' => $data['name'], 68 | 'email' => $data['email'], 69 | 'password' => bcrypt($data['password']), 70 | ]); 71 | } 72 | } 73 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/progress-bars.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Progress Bar 3 | * ----------------------- 4 | */ 5 | 6 | //General CSS 7 | .progress, 8 | .progress > .progress-bar { 9 | .box-shadow(none); 10 | &, .progress-bar { 11 | .border-radius(@progress-bar-border-radius); 12 | } 13 | } 14 | 15 | /* size variation */ 16 | .progress.sm, 17 | .progress-sm { 18 | height: 10px; 19 | &, .progress-bar { 20 | .border-radius(@progress-bar-sm-border-radius); 21 | } 22 | } 23 | 24 | .progress.xs, 25 | .progress-xs { 26 | height: 7px; 27 | &, .progress-bar { 28 | .border-radius(@progress-bar-xs-border-radius); 29 | } 30 | } 31 | 32 | .progress.xxs, 33 | .progress-xxs { 34 | height: 3px; 35 | &, .progress-bar { 36 | .border-radius(@progress-bar-xs-border-radius); 37 | } 38 | } 39 | 40 | /* Vertical bars */ 41 | .progress.vertical { 42 | position: relative; 43 | width: 30px; 44 | height: 200px; 45 | display: inline-block; 46 | margin-right: 10px; 47 | > .progress-bar { 48 | width: 100%; 49 | position: absolute; 50 | bottom: 0; 51 | } 52 | 53 | //Sizes 54 | &.sm, 55 | &.progress-sm { 56 | width: 20px; 57 | } 58 | 59 | &.xs, 60 | &.progress-xs { 61 | width: 10px; 62 | } 63 | &.xxs, 64 | &.progress-xxs { 65 | width: 3px; 66 | } 67 | } 68 | 69 | //Progress Groups 70 | .progress-group { 71 | .progress-text { 72 | font-weight: 600; 73 | } 74 | .progress-number { 75 | float: right; 76 | } 77 | } 78 | 79 | /* Remove margins from progress bars when put in a table */ 80 | .table { 81 | tr > td .progress { 82 | margin: 0; 83 | } 84 | } 85 | 86 | // Variations 87 | // ------------------------- 88 | .progress-bar-light-blue, 89 | .progress-bar-primary { 90 | .progress-bar-variant(@light-blue); 91 | } 92 | 93 | .progress-bar-green, 94 | .progress-bar-success { 95 | .progress-bar-variant(@green); 96 | } 97 | 98 | .progress-bar-aqua, 99 | .progress-bar-info { 100 | .progress-bar-variant(@aqua); 101 | } 102 | 103 | .progress-bar-yellow, 104 | .progress-bar-warning { 105 | .progress-bar-variant(@yellow); 106 | } 107 | 108 | .progress-bar-red, 109 | .progress-bar-danger { 110 | .progress-bar-variant(@red); 111 | } 112 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/progress-bars.less: -------------------------------------------------------------------------------- 1 | // 2 | // Progress bars 3 | // -------------------------------------------------- 4 | 5 | 6 | // Bar animations 7 | // ------------------------- 8 | 9 | // WebKit 10 | @-webkit-keyframes progress-bar-stripes { 11 | from { background-position: 40px 0; } 12 | to { background-position: 0 0; } 13 | } 14 | 15 | // Spec and IE10+ 16 | @keyframes progress-bar-stripes { 17 | from { background-position: 40px 0; } 18 | to { background-position: 0 0; } 19 | } 20 | 21 | 22 | // Bar itself 23 | // ------------------------- 24 | 25 | // Outer container 26 | .progress { 27 | overflow: hidden; 28 | height: @line-height-computed; 29 | margin-bottom: @line-height-computed; 30 | background-color: @progress-bg; 31 | border-radius: @progress-border-radius; 32 | .box-shadow(inset 0 1px 2px rgba(0,0,0,.1)); 33 | } 34 | 35 | // Bar of progress 36 | .progress-bar { 37 | float: left; 38 | width: 0%; 39 | height: 100%; 40 | font-size: @font-size-small; 41 | line-height: @line-height-computed; 42 | color: @progress-bar-color; 43 | text-align: center; 44 | background-color: @progress-bar-bg; 45 | .box-shadow(inset 0 -1px 0 rgba(0,0,0,.15)); 46 | .transition(width .6s ease); 47 | } 48 | 49 | // Striped bars 50 | // 51 | // `.progress-striped .progress-bar` is deprecated as of v3.2.0 in favor of the 52 | // `.progress-bar-striped` class, which you just add to an existing 53 | // `.progress-bar`. 54 | .progress-striped .progress-bar, 55 | .progress-bar-striped { 56 | #gradient > .striped(); 57 | background-size: 40px 40px; 58 | } 59 | 60 | // Call animation for the active one 61 | // 62 | // `.progress.active .progress-bar` is deprecated as of v3.2.0 in favor of the 63 | // `.progress-bar.active` approach. 64 | .progress.active .progress-bar, 65 | .progress-bar.active { 66 | .animation(progress-bar-stripes 2s linear infinite); 67 | } 68 | 69 | 70 | // Variations 71 | // ------------------------- 72 | 73 | .progress-bar-success { 74 | .progress-bar-variant(@progress-bar-success-bg); 75 | } 76 | 77 | .progress-bar-info { 78 | .progress-bar-variant(@progress-bar-info-bg); 79 | } 80 | 81 | .progress-bar-warning { 82 | .progress-bar-variant(@progress-bar-warning-bg); 83 | } 84 | 85 | .progress-bar-danger { 86 | .progress-bar-variant(@progress-bar-danger-bg); 87 | } 88 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/forms.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Form 3 | * --------------- 4 | */ 5 | .form-control { 6 | .border-radius(@input-radius); 7 | box-shadow: none; 8 | border-color: @gray; 9 | &:focus { 10 | border-color: @light-blue; 11 | box-shadow: none; 12 | } 13 | &::-moz-placeholder, 14 | &:-ms-input-placeholder, 15 | &::-webkit-input-placeholder { 16 | color: #bbb; 17 | opacity: 1; 18 | } 19 | 20 | &:not(select) { 21 | -webkit-appearance: none; 22 | -moz-appearance: none; 23 | appearance: none; 24 | } 25 | } 26 | 27 | .form-group { 28 | &.has-success { 29 | label { 30 | color: @green; 31 | } 32 | .form-control { 33 | border-color: @green; 34 | box-shadow: none; 35 | } 36 | .help-block { 37 | color: @green; 38 | } 39 | } 40 | 41 | &.has-warning { 42 | label { 43 | color: @yellow; 44 | } 45 | .form-control { 46 | border-color: @yellow; 47 | box-shadow: none; 48 | } 49 | .help-block { 50 | color: @yellow; 51 | } 52 | } 53 | 54 | &.has-error { 55 | label { 56 | color: @red; 57 | } 58 | .form-control { 59 | border-color: @red; 60 | box-shadow: none; 61 | } 62 | .help-block { 63 | color: @red; 64 | } 65 | } 66 | } 67 | 68 | /* Input group */ 69 | .input-group { 70 | .input-group-addon { 71 | .border-radius(@input-radius); 72 | border-color: @gray; 73 | background-color: #fff; 74 | } 75 | } 76 | 77 | /* button groups */ 78 | .btn-group-vertical { 79 | .btn { 80 | &.btn-flat:first-of-type, &.btn-flat:last-of-type { 81 | .border-radius(0); 82 | } 83 | } 84 | } 85 | 86 | .icheck > label { 87 | padding-left: 0; 88 | } 89 | 90 | /* support Font Awesome icons in form-control */ 91 | .form-control-feedback.fa { 92 | line-height: @input-height-base; 93 | } 94 | 95 | .input-lg + .form-control-feedback.fa, 96 | .input-group-lg + .form-control-feedback.fa, 97 | .form-group-lg .form-control + .form-control-feedback.fa { 98 | line-height: @input-height-large; 99 | } 100 | 101 | .input-sm + .form-control-feedback.fa, 102 | .input-group-sm + .form-control-feedback.fa, 103 | .form-group-sm .form-control + .form-control-feedback.fa { 104 | line-height: @input-height-small; 105 | } 106 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/pagination.less: -------------------------------------------------------------------------------- 1 | // 2 | // Pagination (multiple pages) 3 | // -------------------------------------------------- 4 | .pagination { 5 | display: inline-block; 6 | padding-left: 0; 7 | margin: @line-height-computed 0; 8 | border-radius: @border-radius-base; 9 | 10 | > li { 11 | display: inline; // Remove list-style and block-level defaults 12 | > a, 13 | > span { 14 | position: relative; 15 | float: left; // Collapse white-space 16 | padding: @padding-base-vertical @padding-base-horizontal; 17 | line-height: @line-height-base; 18 | text-decoration: none; 19 | color: @pagination-color; 20 | background-color: @pagination-bg; 21 | border: 1px solid @pagination-border; 22 | margin-left: -1px; 23 | } 24 | &:first-child { 25 | > a, 26 | > span { 27 | margin-left: 0; 28 | .border-left-radius(@border-radius-base); 29 | } 30 | } 31 | &:last-child { 32 | > a, 33 | > span { 34 | .border-right-radius(@border-radius-base); 35 | } 36 | } 37 | } 38 | 39 | > li > a, 40 | > li > span { 41 | &:hover, 42 | &:focus { 43 | color: @pagination-hover-color; 44 | background-color: @pagination-hover-bg; 45 | border-color: @pagination-hover-border; 46 | } 47 | } 48 | 49 | > .active > a, 50 | > .active > span { 51 | &, 52 | &:hover, 53 | &:focus { 54 | z-index: 2; 55 | color: @pagination-active-color; 56 | background-color: @pagination-active-bg; 57 | border-color: @pagination-active-border; 58 | cursor: default; 59 | } 60 | } 61 | 62 | > .disabled { 63 | > span, 64 | > span:hover, 65 | > span:focus, 66 | > a, 67 | > a:hover, 68 | > a:focus { 69 | color: @pagination-disabled-color; 70 | background-color: @pagination-disabled-bg; 71 | border-color: @pagination-disabled-border; 72 | cursor: @cursor-disabled; 73 | } 74 | } 75 | } 76 | 77 | // Sizing 78 | // -------------------------------------------------- 79 | 80 | // Large 81 | .pagination-lg { 82 | .pagination-size(@padding-large-vertical; @padding-large-horizontal; @font-size-large; @border-radius-large); 83 | } 84 | 85 | // Small 86 | .pagination-sm { 87 | .pagination-size(@padding-small-vertical; @padding-small-horizontal; @font-size-small; @border-radius-small); 88 | } 89 | -------------------------------------------------------------------------------- /app/Business/OrderSystem/OrderNumberGenerator.php: -------------------------------------------------------------------------------- 1 | application = $application; 46 | $this->userId = (int)$this->application->make('auth') 47 | ->guard($this->application('config')->get('auth.defaults.guard')) 48 | ->id(); 49 | } 50 | 51 | /** 52 | * 获取单号生成器实例 53 | * 54 | * @param Application|null $application 55 | * 56 | * @return OrderNumberGenerator|static 57 | */ 58 | public static function getInstance(Application $application = null) 59 | { 60 | if (is_null(static::$instance)) { 61 | if (is_null($application)) { 62 | $application = App::getInstance(); 63 | } 64 | 65 | return static::$instance = new static($application); 66 | } 67 | 68 | return static::$instance; 69 | } 70 | 71 | /** 72 | * 生成订单号 73 | * 74 | * @param Order $order 75 | * 76 | * @return string 77 | */ 78 | public function serialize(Order $order) 79 | { 80 | $id = (int)$order->getAttribute('id'); 81 | 82 | return (string)($id * 1000 + $this->userId) . (string)rand(100, 999); 83 | } 84 | 85 | /** 86 | * 获取真实订单 ID 87 | * 88 | * @param $orderNumber 89 | * 90 | * @return int 91 | */ 92 | public function unserialize($orderNumber) 93 | { 94 | $actual = (int)substr($orderNumber, 0, -3); 95 | 96 | return $actual - $this->userId; 97 | } 98 | } -------------------------------------------------------------------------------- /config/cache.php: -------------------------------------------------------------------------------- 1 | env('CACHE_DRIVER', 'file'), 17 | 18 | /* 19 | |-------------------------------------------------------------------------- 20 | | Cache Stores 21 | |-------------------------------------------------------------------------- 22 | | 23 | | Here you may define all of the cache "stores" for your application as 24 | | well as their drivers. You may even define multiple stores for the 25 | | same cache driver to group types of items stored in your caches. 26 | | 27 | */ 28 | 29 | 'stores' => [ 30 | 31 | 'apc' => [ 32 | 'driver' => 'apc', 33 | ], 34 | 35 | 'array' => [ 36 | 'driver' => 'array', 37 | ], 38 | 39 | 'database' => [ 40 | 'driver' => 'database', 41 | 'table' => 'cache', 42 | 'connection' => null, 43 | ], 44 | 45 | 'file' => [ 46 | 'driver' => 'file', 47 | 'path' => storage_path('framework/cache'), 48 | ], 49 | 50 | 'memcached' => [ 51 | 'driver' => 'memcached', 52 | 'servers' => [ 53 | [ 54 | 'host' => env('MEMCACHED_HOST', '127.0.0.1'), 55 | 'port' => env('MEMCACHED_PORT', 11211), 56 | 'weight' => 100, 57 | ], 58 | ], 59 | ], 60 | 61 | 'redis' => [ 62 | 'driver' => 'redis', 63 | 'connection' => 'default', 64 | ], 65 | 66 | ], 67 | 68 | /* 69 | |-------------------------------------------------------------------------- 70 | | Cache Key Prefix 71 | |-------------------------------------------------------------------------- 72 | | 73 | | When utilizing a RAM based store such as APC or Memcached, there might 74 | | be other applications utilizing the same cache. So, we'll specify a 75 | | value to get prefixed to all our keys so we can avoid collisions. 76 | | 77 | */ 78 | 79 | 'prefix' => 'laravel', 80 | 81 | ]; 82 | -------------------------------------------------------------------------------- /resources/assets/less/adminlte/timeline.less: -------------------------------------------------------------------------------- 1 | /* 2 | * Component: Timeline 3 | * ------------------- 4 | */ 5 | 6 | .timeline { 7 | position: relative; 8 | margin: 0 0 30px 0; 9 | padding: 0; 10 | list-style: none; 11 | 12 | // The line 13 | &:before { 14 | content: ''; 15 | position: absolute; 16 | top: 0; 17 | bottom: 0; 18 | width: 4px; 19 | background: #ddd; 20 | left: 31px; 21 | margin: 0; 22 | .border-radius(2px); 23 | } 24 | 25 | > li { 26 | position: relative; 27 | margin-right: 10px; 28 | margin-bottom: 15px; 29 | .clearfix(); 30 | 31 | // The content 32 | > .timeline-item { 33 | .box-shadow(@box-boxshadow); 34 | .border-radius(@box-border-radius); 35 | margin-top: 0; 36 | background: #fff; 37 | color: #444; 38 | margin-left: 60px; 39 | margin-right: 15px; 40 | padding: 0; 41 | position: relative; 42 | 43 | // The time and header 44 | > .time { 45 | color: #999; 46 | float: right; 47 | padding: 10px; 48 | font-size: 12px; 49 | } 50 | > .timeline-header { 51 | margin: 0; 52 | color: #555; 53 | border-bottom: 1px solid @box-border-color; 54 | padding: 10px; 55 | font-size: 16px; 56 | line-height: 1.1; 57 | > a { 58 | font-weight: 600; 59 | } 60 | } 61 | // Item body and footer 62 | > .timeline-body, > .timeline-footer { 63 | padding: 10px; 64 | } 65 | 66 | } 67 | 68 | // The icons 69 | > .fa, 70 | > .glyphicon, 71 | > .ion { 72 | width: 30px; 73 | height: 30px; 74 | font-size: 15px; 75 | line-height: 30px; 76 | position: absolute; 77 | color: #666; 78 | background: @gray; 79 | border-radius: 50%; 80 | text-align: center; 81 | left: 18px; 82 | top: 0; 83 | } 84 | } 85 | 86 | // Time label 87 | > .time-label { 88 | > span { 89 | font-weight: 600; 90 | padding: 5px; 91 | display: inline-block; 92 | background-color: #fff; 93 | 94 | .border-radius(4px); 95 | } 96 | } 97 | } 98 | 99 | .timeline-inverse { 100 | > li { 101 | > .timeline-item { 102 | background: #f0f0f0; 103 | border: 1px solid #ddd; 104 | .box-shadow(none); 105 | > .timeline-header { 106 | border-bottom-color: #ddd; 107 | } 108 | } 109 | } 110 | } 111 | -------------------------------------------------------------------------------- /resources/assets/less/bootstrap-less/print.less: -------------------------------------------------------------------------------- 1 | /*! Source: https://github.com/h5bp/html5-boilerplate/blob/master/src/css/main.css */ 2 | 3 | // ========================================================================== 4 | // Print styles. 5 | // Inlined to avoid the additional HTTP request: h5bp.com/r 6 | // ========================================================================== 7 | 8 | @media print { 9 | *, 10 | *:before, 11 | *:after { 12 | background: transparent !important; 13 | color: #000 !important; // Black prints faster: h5bp.com/s 14 | box-shadow: none !important; 15 | text-shadow: none !important; 16 | } 17 | 18 | a, 19 | a:visited { 20 | text-decoration: underline; 21 | } 22 | 23 | a[href]:after { 24 | content: " (" attr(href) ")"; 25 | } 26 | 27 | abbr[title]:after { 28 | content: " (" attr(title) ")"; 29 | } 30 | 31 | // Don't show links that are fragment identifiers, 32 | // or use the `javascript:` pseudo protocol 33 | a[href^="#"]:after, 34 | a[href^="javascript:"]:after { 35 | content: ""; 36 | } 37 | 38 | pre, 39 | blockquote { 40 | border: 1px solid #999; 41 | page-break-inside: avoid; 42 | } 43 | 44 | thead { 45 | display: table-header-group; // h5bp.com/t 46 | } 47 | 48 | tr, 49 | img { 50 | page-break-inside: avoid; 51 | } 52 | 53 | img { 54 | max-width: 100% !important; 55 | } 56 | 57 | p, 58 | h2, 59 | h3 { 60 | orphans: 3; 61 | widows: 3; 62 | } 63 | 64 | h2, 65 | h3 { 66 | page-break-after: avoid; 67 | } 68 | 69 | // Bootstrap specific changes start 70 | // 71 | // Chrome (OSX) fix for https://github.com/twbs/bootstrap/issues/11245 72 | // Once fixed, we can just straight up remove this. 73 | select { 74 | background: #fff !important; 75 | } 76 | 77 | // Bootstrap components 78 | .navbar { 79 | display: none; 80 | } 81 | .btn, 82 | .dropup > .btn { 83 | > .caret { 84 | border-top-color: #000 !important; 85 | } 86 | } 87 | .label { 88 | border: 1px solid #000; 89 | } 90 | 91 | .table { 92 | border-collapse: collapse !important; 93 | 94 | td, 95 | th { 96 | background-color: #fff !important; 97 | } 98 | } 99 | .table-bordered { 100 | th, 101 | td { 102 | border: 1px solid #ddd !important; 103 | } 104 | } 105 | 106 | // Bootstrap specific changes end 107 | } 108 | -------------------------------------------------------------------------------- /config/queue.php: -------------------------------------------------------------------------------- 1 | env('QUEUE_DRIVER', 'sync'), 19 | 20 | /* 21 | |-------------------------------------------------------------------------- 22 | | Queue Connections 23 | |-------------------------------------------------------------------------- 24 | | 25 | | Here you may configure the connection information for each server that 26 | | is used by your application. A default configuration has been added 27 | | for each back-end shipped with Laravel. You are free to add more. 28 | | 29 | */ 30 | 31 | 'connections' => [ 32 | 33 | 'sync' => [ 34 | 'driver' => 'sync', 35 | ], 36 | 37 | 'database' => [ 38 | 'driver' => 'database', 39 | 'table' => 'jobs', 40 | 'queue' => 'default', 41 | 'expire' => 60, 42 | ], 43 | 44 | 'beanstalkd' => [ 45 | 'driver' => 'beanstalkd', 46 | 'host' => 'localhost', 47 | 'queue' => 'default', 48 | 'ttr' => 60, 49 | ], 50 | 51 | 'sqs' => [ 52 | 'driver' => 'sqs', 53 | 'key' => 'your-public-key', 54 | 'secret' => 'your-secret-key', 55 | 'prefix' => 'https://sqs.us-east-1.amazonaws.com/your-account-id', 56 | 'queue' => 'your-queue-name', 57 | 'region' => 'us-east-1', 58 | ], 59 | 60 | 'redis' => [ 61 | 'driver' => 'redis', 62 | 'connection' => 'default', 63 | 'queue' => 'default', 64 | 'expire' => 60, 65 | ], 66 | 67 | ], 68 | 69 | /* 70 | |-------------------------------------------------------------------------- 71 | | Failed Queue Jobs 72 | |-------------------------------------------------------------------------- 73 | | 74 | | These options configure the behavior of failed queue job logging so you 75 | | can control which database and table are used to store the jobs that 76 | | have failed. You may change them to any database / table you wish. 77 | | 78 | */ 79 | 80 | 'failed' => [ 81 | 'database' => env('DB_CONNECTION', 'mysql'), 82 | 'table' => 'failed_jobs', 83 | ], 84 | 85 | ]; 86 | -------------------------------------------------------------------------------- /resources/views/power-management/admin/member/user/index.blade.php: -------------------------------------------------------------------------------- 1 | @extends('power-management.common.admin') 2 | 3 | @section('module-title', 'User') 4 | @section('module-subtitle', 'The website\'s user manage') 5 | @section('module-breadcrumb', 'User') 6 | 7 | @section('module-content') 8 |
    9 |
    10 |
    11 |
    12 |

    User List

    13 | 14 |
    15 |
    16 |
    17 | 18 | 19 |
    20 | 21 |
    22 |
    23 |
    24 |
    25 |
    26 | 27 |
    28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | @forelse($collection as $item) 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | @empty 45 | 46 | 47 | 48 | @endforelse 49 |
    IDNameEmailCreated AtAction
    {{ $item->id }}{{ $item->name }}{{ $item->email }}{{ $item->created_at->format('Y-m-d H:i') }}edit
    No data
    50 |
    51 | 52 | @if(!$collection->isEmpty() && $collection->count() > \ActLoudBur\PowerManagement\Http\BaseController::PER_PAGE) 53 | 56 | @endif 57 |
    58 | 59 |
    60 |
    61 | @endsection --------------------------------------------------------------------------------