Skip to content

Commit c2d7eb4

Browse files
refactor: application
0 parents  commit c2d7eb4

File tree

520 files changed

+72317
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

520 files changed

+72317
-0
lines changed

.editorconfig

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
end_of_line = lf
6+
indent_size = 4
7+
indent_style = space
8+
insert_final_newline = true
9+
trim_trailing_whitespace = true
10+
11+
[*.md]
12+
trim_trailing_whitespace = false
13+
14+
[*.{yml,yaml}]
15+
indent_size = 2
16+
17+
[docker-compose.yml]
18+
indent_size = 4

.env.example

+64
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
APP_NAME=Laravel
2+
APP_ENV=local
3+
APP_KEY=
4+
APP_DEBUG=true
5+
APP_TIMEZONE=UTC
6+
APP_URL=http://localhost
7+
8+
APP_LOCALE=en
9+
APP_FALLBACK_LOCALE=en
10+
APP_FAKER_LOCALE=en_US
11+
12+
APP_MAINTENANCE_DRIVER=file
13+
APP_MAINTENANCE_STORE=database
14+
15+
BCRYPT_ROUNDS=12
16+
17+
LOG_CHANNEL=stack
18+
LOG_STACK=single
19+
LOG_DEPRECATIONS_CHANNEL=null
20+
LOG_LEVEL=debug
21+
22+
DB_CONNECTION=sqlite
23+
# DB_HOST=127.0.0.1
24+
# DB_PORT=3306
25+
# DB_DATABASE=laravel
26+
# DB_USERNAME=root
27+
# DB_PASSWORD=
28+
29+
SESSION_DRIVER=database
30+
SESSION_LIFETIME=120
31+
SESSION_ENCRYPT=false
32+
SESSION_PATH=/
33+
SESSION_DOMAIN=null
34+
35+
BROADCAST_CONNECTION=log
36+
FILESYSTEM_DISK=local
37+
QUEUE_CONNECTION=database
38+
39+
CACHE_STORE=database
40+
CACHE_PREFIX=
41+
42+
MEMCACHED_HOST=127.0.0.1
43+
44+
REDIS_CLIENT=phpredis
45+
REDIS_HOST=127.0.0.1
46+
REDIS_PASSWORD=null
47+
REDIS_PORT=6379
48+
49+
MAIL_MAILER=log
50+
MAIL_HOST=127.0.0.1
51+
MAIL_PORT=2525
52+
MAIL_USERNAME=null
53+
MAIL_PASSWORD=null
54+
MAIL_ENCRYPTION=null
55+
MAIL_FROM_ADDRESS="[email protected]"
56+
MAIL_FROM_NAME="${APP_NAME}"
57+
58+
AWS_ACCESS_KEY_ID=
59+
AWS_SECRET_ACCESS_KEY=
60+
AWS_DEFAULT_REGION=us-east-1
61+
AWS_BUCKET=
62+
AWS_USE_PATH_STYLE_ENDPOINT=false
63+
64+
VITE_APP_NAME="${APP_NAME}"

.gitattributes

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
* text=auto eol=lf
2+
3+
*.blade.php diff=html
4+
*.css diff=css
5+
*.html diff=html
6+
*.md diff=markdown
7+
*.php diff=php
8+
9+
/.github export-ignore
10+
CHANGELOG.md export-ignore
11+
.styleci.yml export-ignore

.husky/commit-msg

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/sh
2+
if ! head -1 "$1" | grep -qE "^(feat|fix|chore|docs|test|style|refactor|perf|build|ci|revert)(\(.+?\))?: .{1,}$"; then
3+
echo "Aborting commit. Your commit message is invalid." >&2
4+
exit 1
5+
fi
6+
if ! head -1 "$1" | grep -qE "^.{1,88}$"; then
7+
echo "Aborting commit. Your commit message is too long." >&2
8+
exit 1
9+
fi

.husky/pre-commit

Whitespace-only changes.

CODE_OF_CONDUCT.md

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# Code of Conduct
2+
3+
## Introduction
4+
5+
In the interest of fostering an open, welcoming, and respectful community, we pledge to respect all contributors and maintainers of the HRIS by Programing Live Community project.
6+
7+
This Code of Conduct applies to all community spaces, including GitHub, mailing lists, issue trackers, and any other forums created by the community, used for or to communicate about the project.
8+
9+
## Expected Behavior
10+
11+
We expect all members of our community to:
12+
13+
- Use welcoming and inclusive language
14+
- Be respectful of differing viewpoints and experiences
15+
- Gracefully accept constructive criticism
16+
- Focus on what is best for the community
17+
- Show empathy towards other community members
18+
19+
## Unacceptable Behavior
20+
21+
Examples of unacceptable behavior include:
22+
23+
- The use of serialized language or imagery and unwelcome sexual attention or advances
24+
- Trolling, insulting/derogatory comments, and personal or political attacks
25+
- Public or private harassment
26+
- Publishing others' private information, such as a physical or electronic address, without explicit permission
27+
- Any other conduct that could reasonably be considered inappropriate in a professional setting
28+
29+
## Enforcement
30+
31+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances.
32+
33+
Project maintainers who do not follow the Code of Conduct may be removed from the project team.
34+
35+
## Attribution
36+
37+
This Code of Conduct is adapted from the [Contributor Covenant](https://www.contributor-covenant.org), version 2.1, available at https://www.contributor-covenant.org/version/2/1/code_of_conduct.html

CONTRIBUTING.md

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# Contributing Guidelines
2+
3+
Hello! We're really excited that you are interested in contributing to HRIS by Programing Live Community. Before you start, please take the time to read these guidelines. They will give you the direction you need to get started on contributing effectively and efficiently.
4+
5+
## Code of Conduct
6+
7+
We have adopted a Code of Conduct that we expect all contributors and maintainers to uphold. Please read the [Code of Conduct](CODE_OF_CONDUCT.md) before you start contributing.
8+
9+
## Getting Started
10+
11+
- Ensure you have the latest version of PHP, SQLite and Laravel setup properly on your development machine.
12+
- Fork the repository on GitHub.
13+
- Clone the forked repository to your machine.
14+
15+
## Submitting Changes
16+
17+
- Create a new branch for each issue you're working on. Ensure the branch name clearly related to the issue at hand.
18+
- Write clear, concise commit messages that explain the changes.
19+
- Ensure your changes do not break any existing functionality.
20+
21+
## Submitting A Pull Request
22+
23+
- Push your changes to your forked repository.
24+
- Create a new pull request and reference the issue number in the pull request message.
25+
26+
## Reporting A Bug
27+
28+
If you find a bug, please create an issue in our repository on GitHub. Describe the problem with as many details as possible.
29+
30+
## Proposing Features
31+
32+
We welcome ideas for project enhancements. If you have an idea for a new feature, please create an issue providing as much detail as possible.
33+
34+
Thank you for your interest in contributing to HRIS by Programing Live Community. We look forward to your involvement!

README.md

+89
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
# HRIS By ProgramingLive Community
2+
3+
Welcome to our community-driven Human Resource Information System (HRIS) project.
4+
This open-source project is initiated and actively maintained by the Programing Live Community.
5+
6+
## Overview
7+
8+
Our HRIS solution is designed to support multiple tenants,
9+
allowing different organizations
10+
to manage their respective human resource requirements in isolated instances within the same HRIS.
11+
This improves the utility and efficiency of our system,
12+
making it a suitable choice for software service providers, organizational franchises,
13+
large scale corporations with semi-independent branches, and more.
14+
15+
<details>
16+
<summary>Minimum Viable Product (MVP)</summary>
17+
18+
The primary feature set we aim to achieve for our MVP includes:
19+
20+
1. **Company Registration:** Companies need to be able to register themselves to use this application. This process would involve providing company details, setting up an administrator account, and agreeing to any applicable terms and conditions. Once registered, the company should have its own isolated space within the application to operate independently.
21+
2. **Sister Company Management:** Aside from operating their own space, registered companies should be able to add and manage sister companies within their system. This facilitates centralized HR management for business conglomerates or franchises having multiple sister companies.
22+
23+
</details>
24+
25+
## Features
26+
27+
- Employee Management: Manage all details of your employees in one place.
28+
- Payroll System: Seamless payroll process with accurate computations.
29+
- Recruitment: Streamlined hiring process from job posting to onboarding.
30+
- Training: Keep track of employee training and professional development.
31+
- Compliance: Ensure your organization is compliant with labor laws and regulations.
32+
33+
## Getting Started
34+
35+
To get started contributing to this project, please see the [CONTRIBUTING.md](CONTRIBUTING.md) guide.
36+
37+
## Tech Stack
38+
39+
This project uses various technologies:
40+
41+
- PHP 8.2 with Laravel Framework v11.10.0
42+
- Laravel Livewire for real-time interfaces
43+
- SQLite for database
44+
- PHPUnit for testing
45+
- Various Composer and JavaScript packages
46+
47+
## Installation Instructions
48+
49+
Make sure you have PHP, Composer, Node.js and Yarn installed on your machine before starting the installation.
50+
51+
```shell
52+
# Clone the repository using git
53+
git clone https://github.com/programinglive/hris.git
54+
# Navigate into the directory
55+
cd hris
56+
# Install PHP dependencies with Composer
57+
composer install
58+
# Install Node.js dependencies with Yarn
59+
yarn install
60+
# Copy .env.example file to .env
61+
cp .env.example .env
62+
# Generate a fresh app key
63+
php artisan key:generate
64+
# Run the database migrations and seeders
65+
php artisan migrate --seed
66+
# Compile the frontend assets
67+
yarn dev
68+
# Serve the application
69+
php artisan serve
70+
```
71+
72+
The application should now be running at `http://localhost:8000`.
73+
74+
## User Testing
75+
```
76+
77+
Password: hrisproject
78+
```
79+
80+
## Contributions
81+
82+
We value your contributions!
83+
Whether it's a bug report, new feature, correction, or additional documentation, we greatly appreciate any improvements.
84+
85+
We hope you enjoy exploring our project, and we're excited to have you here!
86+
87+
## License
88+
89+
This project is licensed under the MIT License.

app/Console/Commands/SetDeleted.php

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
<?php
2+
3+
namespace App\Console\Commands;
4+
5+
use Illuminate\Console\Command;
6+
7+
class SetDeleted extends Command
8+
{
9+
/**
10+
* The name and signature of the console command.
11+
*
12+
* @var string
13+
*/
14+
protected $signature = 'app:set-deleted {model}';
15+
16+
/**
17+
* The console command description.
18+
*
19+
* @var string
20+
*/
21+
protected $description = 'Command description';
22+
23+
/**
24+
* Execute the console command.
25+
*/
26+
public function handle(): void
27+
{
28+
$model = $this->argument('model');
29+
$model = app('App\Models\\' . ucfirst($model) );
30+
31+
$models = $model->withTrashed()->get();
32+
33+
foreach($models as $data) {
34+
if($data->deleted_at){
35+
$data->code = $data->code . '-deleted-';
36+
$data->save();
37+
$this->info($data->code . ' deleted');
38+
}
39+
}
40+
41+
}
42+
}

app/Console/Kernel.php

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?php
2+
3+
namespace App\Console;
4+
5+
use Illuminate\Console\Scheduling\Schedule;
6+
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
7+
8+
class Kernel extends ConsoleKernel
9+
{
10+
/**
11+
* Define the application's command schedule.
12+
*/
13+
protected function schedule(Schedule $schedule): void
14+
{
15+
// $schedule->command('inspire')->hourly();
16+
}
17+
18+
/**
19+
* Register the commands for the application.
20+
*/
21+
protected function commands(): void
22+
{
23+
$this->load(__DIR__.'/Commands');
24+
25+
require base_path('routes/console.php');
26+
}
27+
}

app/Exceptions/Handler.php

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
3+
namespace App\Exceptions;
4+
5+
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
6+
use Throwable;
7+
8+
class Handler extends ExceptionHandler
9+
{
10+
/**
11+
* The list of the inputs that are never flashed to the session on validation exceptions.
12+
*
13+
* @var array<int, string>
14+
*/
15+
protected $dontFlash = [
16+
'current_password',
17+
'password',
18+
'password_confirmation',
19+
];
20+
21+
/**
22+
* Register the exception handling callbacks for the application.
23+
*/
24+
public function register(): void
25+
{
26+
$this->reportable(function (Throwable $e) {
27+
//
28+
});
29+
}
30+
}

0 commit comments

Comments
 (0)