Coder Social home page Coder Social logo

brs's Introduction

1. Practices main

  • Background RESTful API, OOP, MVC, SRP (Single Responsibility Principle), Microservice
  • Implementation service such as: register, login, import csv, list
  • Inter-service communication: authencation before upload file csv with more than 1 million row and insert into mysql.

2 Folder project

  • framework: laravel 8.4
  • package: passport
  • Technical: Queues and Job Batching

3 Step by step run on local computer

3.1 Requirement

  • Install xampp server (PHP Version >= 7.3.7 && Mysql)
  • Install composer

3.2 Config database

create database name brsdb or import database sample ready in folder document>database

3.3 open terminal run command

  1. npm install
  2. composer install
  3. php artisan key:generate
  4. php artisan migrate
  5. php artisan queue:work

(note: not kill or close windown when run command php artisan queue:work)

4. TEST API By Postman

  • use csv sample ready in folder document>transaction-csv-sample!
  • step by step includes: register account -> login -> upload file csv

IMPORT Collection to postman

https://www.postman.com/collections/85d0de331d463cac1612 or you import a file BRS.postman_collection.json to postman

END-POINT document https://documenter.getpostman.com/view/11594629/TzRVfRkf


  • account login if you use database sample
  • username: chienktv90
  • password: 123456

'headers' => [ 'Accept' => 'application/json', 'Authorization' => 'Bearer '.$accessToken, ]


  1. Auth http://localhost/brs/public/api/register http://localhost/brs/public/api/login

  2. Transaction import file csv http://localhost/brs/public/api/upload

  3. Top 5 latest transaction and total records http://localhost/brs/public/api/transaction

5. Continue developing

  • import file excel
  • validation data

brs's People

Contributors

chienktv90 avatar

Watchers

James Cloos avatar  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.