Coder Social home page Coder Social logo

webapipaginatedasynccrud's Introduction

Introduction

This is a project mean to be used for learning basic CRUD operations and Pagination using

  • AspNet Web Api 2 (Not Asp Net Core, for the Asp Net Core I have another app, look links below)
  • Entity Framework

Full-stack Applications

E-commerce (shopping cart)

Server side implementations

The next to come are:

  • Spring Boot + Spring Data Hibernate + Kotlin
  • Spring Boot + Jax-RS Jersey + Hibernate + Kotlin
  • Spring Boot + mybatis
  • Spring Boot + mybatis + Kotlin
  • Asp.Net Web Api v2
  • Elixir
  • Golang + Beego
  • Golang + Iris
  • Golang + Echo
  • Golang + Mux
  • Golang + Revel
  • Golang + Kit
  • Flask + Flask-Restful
  • AspNetCore + NHibernate
  • AspNetCore + Dapper

Client side implementations

This client side E-commerce application is also implemented using other client side technologies:

Blog/CMS

Server side implementations

Client side

The next come are

  • Angular NgRx-Store
  • Angular + Material
  • React + Material
  • React + Redux + Material
  • Vue + Material
  • Vue + Vuex + Material
  • Ember

Simple CRUD(Create, Read, Update, Delete)

Server side implementations

Client side implementations

The next come are

  • Angular NgRx-Store
  • Angular + Material
  • React + Material
  • React + Redux + Material
  • Vue + Material
  • Vue + Vuex + Material
  • Ember
  • Vanilla javascript

CRUD + Pagination

Server side implementations

The next come are

  • NodeJs Express + Knex
  • Flask + Flask-Restful
  • Laravel + Fractal
  • Laravel + ApiResources
  • Go with Mux
  • AspNet Web Api 2
  • Jersey
  • Elixir

Client side implementations

The next come are

  • Angular NgRx-Store
  • Angular + Material
  • React + Material
  • React + Redux + Material
  • Vue + Material
  • Vue + Vuex + Material
  • Ember
  • Vanilla javascript

Understanding the project

I have controllers, services that deal with the database, Dtos that filter which thing is returned or not as response. The controllers all return HttpResponseMessage, which is somewhat the old way, which means this code is more portable, If for some reason you wanna return the new IHttpActionResult, it is easy, just wrap the HttpResponseMessage into ResponseMessage, the example for the GetTodos Action in TodosController would be:

public async Task<IHttpActionResult> GetTodos([FromUri] int page = 1, [FromUri] int pageSize = 5)
{
    var result = await _todosService.FetchMany(page, pageSize, TodoShow.All);
    return ResponseMessage(StatusCodeAndDtoWrapper.BuildSuccess(TodoListResponse.Build(result.Item2,
        Request.RequestUri.LocalPath, page,
        pageSize, result.Item1)));

}

More on this topic:

I drop/create and seed database each time the app is run, this is not what we want for a more serious app, what we would want is to use migrations. A really cool and simple guide can be found at official Microsoft docs(1min article read): https://docs.microsoft.com/en-us/aspnet/web-api/overview/data/using-web-api-with-entity-framework/part-3

The next come are:

  • NodeJs Express + Knex
  • Flask + Flask-Restful
  • Laravel + Fractal
  • Laravel + ApiResources
  • Go with Mux
  • Jersey
  • Elixir

Social media links

Resources

webapipaginatedasynccrud's People

Contributors

melardev avatar

Watchers

 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.