Attendance Application-Human Resource System

Project address Bee

introduce

Bee is a attendance application in human resources system. Its main function is to apply for leave forms. Bee has high performance and extensibility, including front-end separation, plug-in rule validation (verifier), data filtering (decorator), message queue, etc. The back-end adds Services, Repositories layer to Laravel MVC mode, clarifies the responsibilities of each class, and uses Passport's password mode to obtain interface data.

Technology stack

  • Server: Linux (Centos 7), Nginx
  • Front end: Element, Vue, Vue-Router, Vuex, Webpack, V-calendar
  • Resources: Elephant
  • Backend: Laravel
  • Caching: Redis

Others are basic tools, such as node, npm (cnpm), composer, git, etc.

Demonstration

1. login

2. application

3. editor

4. approval

5. search

install

1. Download
git clone git@github.com:SexyPhoenix/Bee.git 
2. Laravel
composer install
chmod -R 777 storage
php artisan key:generate
3. Upload folders
mkdir -p uploads/bee
chmod -R 777 uploads
4. Configuration. env
cp .env.example .env
APP_URL=http://localhost
ASSET_URL=http://localhost

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=homestead
DB_USERNAME=homestead
DB_PASSWORD=secret

REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379
5. database
php artisan migrate
6. Passport
php artisan passport:keys
php artisan passport:client --password --name='bee'  //name customization
7. Open the message queue
php artisan queue:work bee --queue=apply --sleep=3 --tries=3 & > /dev/null
8. Nginx
server {
    listen 80;
    server_name dev.bee.goods; // custom
    index index.html index.htm index.php;

    location / {
        rewrite ^/(.*)$ /index.php/$1 last;
        try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ /uploads/ {
       root "/var/www/Bee"; // custom
    }

    location ~ \.(html|gif|jpg|jpeg|css|js|eot|svg|ttf|woff|woff2|png)$ {
      root "/var/www/Bee/public"; // custom
    }

    location ~ (.+\.php)(.*)$ {

        root /var/www/Bee/public; // custom
        fastcgi_split_path_info ^(.+\.php)(.+)$;
        fastcgi_pass unix:/var/run/php-fpm/php7-fpm.sock;  // custom
        fastcgi_index index.php;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param PATH_INFO $fastcgi_path_info;

        fastcgi_intercept_errors off;
        fastcgi_buffer_size 16k;
        fastcgi_buffers 4 16k;
        fastcgi_connect_timeout 300;
        fastcgi_send_timeout 300;
        fastcgi_read_timeout 300;
     }
}
9. front end
cnpm install //cnpm.

export const API_DOMAIN = 'http://Modify domain names in xxx/beeapi'//resourcesjsconfigbee.js file
npm run dev
10. Import basic data (database sqlbee. sql)

Finally, pay attention to configuring domain names to host.

open http://xxx/bee#/
Account: zhangxiaofan@qq.com password: 123456

Keywords: PHP git Laravel Nginx

Added by mattachoo on Thu, 03 Oct 2019 04:52:37 +0300