This project is a Laravel application that includes various models to manage different entities such as Users, Posts, Products, Appointments, and more. Below is a brief overview of the key models and their functionalities.
The User
model represents the users of the application. It includes attributes like name
, email
, password
, customer_id
, and role
.
- File: app/Models/User.php
- Policies: app/Policies/UserPolicy.php
The Post
model represents the posts created by users. It includes attributes like title
, content
, and author_id
.
- File: app/Models/Post.php
- Resource: app/Filament/App/Resources/PostResource.php
- Policies: app/Policies/PostPolicy.php
The Product
model represents the products available in the application. It includes attributes like name
, description
, price
, and stock
.
- File: app/Models/Product.php
- Policies: app/Policies/ProductPolicy.php
The Appointment
model represents the appointments scheduled in the application. It includes attributes like date
, time
, user_id
, and status
.
- File: app/Models/Appointment.php
- Policies: app/Policies/AppointmentPolicy.php
The ProductCategory
model represents the categories for products. It includes attributes like name
and description
.
- File: app/Models/ProductCategory.php
- Policies: app/Policies/ProductCategoryPolicy.php
The SectorSeeder
seeds the database with initial data for sectors.
The StatsOverview
widget provides an overview of various statistics like the count of appointments, posts, and products.
The hasModelPermission
function checks if a user has permission to perform actions on a model.
- File: app/Helpers/helper.php
The environment variables are configured in the .env
file. An example configuration is provided in the .env.example
file.
- File: .env.example
- Clone the repository.
- Run
composer install
to install PHP dependencies. - Run
npm install
to install JavaScript dependencies. - Copy
.env.example
to.env
and configure your environment variables. - Run
php artisan migrate
to run the database migrations. - Run
php artisan db:seed
to seed the database.
To start the application, run:
php artisan serve