项目地址Bee介绍Bee是人力资源系统中的一个考勤应用,主要功能是为员工申请休假。Bee具有高性能、可扩展性等,包括前后端分离、插件规则验证(validator)、数据过滤(decorator)、消息队列等,后端基于Laravel的MVC模型。创建Services和Repositories层,明确各类职责,使用Passport的密码方式获取接口数据。技术栈服务器:Linux(Centos7)、Nginx前端:Element、Vue、Vue-Router、Vuex、Webpack、V-calendar资源:Elephant后端:Laravel缓存:Redis其他都是一些基础工具,比如node、npm(cnpm)、composer、git等demo1.登录2.申请3.编辑4.批准5.搜索安装1.下载gitclonegit@github.com:SexyPhoenix/Bee.git2.Laravelcomposerinstallchmod-R777storagephpartisankey:generate3.上传文件夹mkdir-puploads/beechmod-R777uploads4.配置.envcp.env.example.envAPP_URL=http://localhostASSET_URL=http://localhostDB_CONNECTION=mysqlDB_HOST=127.0.0.1DB_PORT=3306DB_DATABASE=homesteadDB_USERNAME=homesteadDB_PASSWORD=secretREDIS_HOST=127.0.0.1REDIS_PASSWORD.=nullREDIS9_PORT数据库phpartisanmigrate6。Passportphpartisanpassport:keysphpartisanpassport:client--password--name='bee'//namecustom7.开启消息队列phpartisanqueue:workbee--queue=apply--sleep=3--tries=3&>/dev/null8。Nginx服务器{听80;服务器名称dev.bee.goods;//自定义索引index.htmlindex.htmindex.php;location/{重写^/(.*)$/index.php/最后1;try_files$uri$uri//index.php?$query_string;}location~/uploads/{root"/var/www/Bee";//自定义}位置~\.(html|gif|jpg|jpeg|css|js|eot|svg|ttf|woff|woff2|png)${root"/var/www/Bee/public";//自定义}位置~(.+\.php)(.*)${root/var/www/Bee/public;//自定义fastcgi_split_path_info^(.+\.php)(.+)$;fastcgi_passunix:/var/run/php-fpm/php7-fpm.sock;//自定义fastcgi_indexindex.php;包括fastcgi_params;fastcgi_paramSCRIPT_FILENAME$document_root$fastcgi_script_name;fastcgi_paramPATH_INFO$fastcgi_path_info;fastcgi_intercept_errors关闭;fastcgi_buffer_size16k;fastcgi_buffers416k;fastcgi_connect_timeout300;fastcgi_send_timeout300;fastcgi_read_timeout300;}}9.前端cnpminstall//cnpm淘宝的exportconstAPI_DOMAIN='http://xxx/beeapi'//resources\js\config\bee.js文件修改域名npmrundev10.导入基础数据(databasesqlbee.sql)最后注意配置域名到host打开http://xxx/bee#/账号:zhangxiaofan@qq.com密码:123456
