Giter VIP home page Giter VIP logo

solutech's Introduction

Laravel Logo

Build Status Total Downloads Latest Stable Version License

Solutech

This is a Laravel backend test project.



About the project

Based on a given ERD, this is a task management system where users can create tasks, assign them to themselves or other users, set due dates, track the status of tasks using the status table, and add comments or remarks to tasks. The system should also allow for the creation and deletion of users, tasks, and statuses, as well as the ability to update and modify existing records. Finally, the system should keep track of timestamps for when records were created, updated, and deleted.



Getting Started

Follow the steps below to set up the project on your local machine.


#Prerequisites - PHP 8.1 or later - Composer - A local development environment such as XAMPP, MAMP, or WAMP - API Platform for software testing such as Postman, or Insomnia



#Installing

  • Clone the repository using git clone https://github.com/iamrikie/solutech.git.
  • Navigate to the project directory using cd solutech.
  • Install the required dependencies using composer install.
  • Copy the .env.example file to .env using cp .env.example .env.
  • Generate a new application key using php artisan key:generate.
  • Configure the database connection in the .env file.
  • Migrate the database tables and seeders using php artisan migrate --seed.
  • Start the development server using php artisan serve.



#Usage

  • Access the application by visiting http://localhost:8000 in your web browser.
  • To test the APIs, you can utilize Postman. You may either use the collection I used for testing, which I can provide to you, or create your own. For testing, make use of the URL http://127.0.0.1:8000/api/v1/...



Endpoints Testing

#Steps

  • Create a Collection and give it a name eg. Solutech

  • Create folders under the collection you've created to group endpoints based on the kind of payload each handle. e.g. Task endpoint, Status endpoints, UserTask endpoints, Users endpoint, Auth endpoints.

  • Add requests under each folder you've created. e.g.

    GET - Retrieve Tasks - http://127.0.0.1:8000/api/v1/tasks

    POST - Add Tasks - http://127.0.0.1:8000/api/v1/tasks

    GET - Retrieve Tasks By Id - http://127.0.0.1:8000/api/v1/tasks/3

    PUT - Update task - http://127.0.0.1:8000/api/v1/tasks/4

    DELETE - Delete task - http://127.0.0.1:8000/api/v1/tasks/5

    POST - Login - http://127.0.0.1:8000/api/v1/login
    - Set Key "Content_Type" and Value "application/json"
    - You don't need to provide a token to login or register, but you will need to provide a valid token to log out.
    - To generate a valid token, you may use laravel tinker, (run "php artisan tinker" on your terminal to start the tinker cli - Then type the next command "$user = \User::first();" That will return user id: 1 data. Proceed to the next command, "$user->createToken('put-any-name-here');" - That will generate a token. Copy paste it on postman.
    - On the "Body" tab select the "raw" option, and enter the login credentials in JSON format.
    For example:
    {
    "email": "[email protected]",
    "password": "Password123"
    }
    Note: Your pass has to be a minimum of 8 characters to be validated as I have defined in the AuthController.

    With that example, proceed testing the remaining endpoints. Check the api Routes for a better understanding on how to proceed.



Ps: Code Optimization in Progress...



Built With

Laravel [v10]




The results of the API testing below illustrate both the interrelation between users, tasks, and status and the sequence of events in compliance with the provided Entity-Relationship Diagram (ERD).

Screenshot 2023-04-23 122123

Screenshot 2023-04-23 122221

Screenshot 2023-04-23 155620

Screenshot 2023-04-23 121816

Screenshot 2023-04-23 121948

Screenshot 2023-04-23 123059

Screenshot 2023-04-23 233711

Screenshot 2023-04-23 235049

From this point, I added functionalities for administrators, allowing them to register new users and assign tasks exclusively to regular users(employees), among other capabilities that they could perform from their dashboard. Backend not fully implemented for that but that's the idea

image

image

image

image

image

image

image

solutech's People

Contributors

iamrikie avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.