SpringData JPA implement CRUD

  application.properties Configuration

First, create an entity class and automatically generate database table

 

 

 Two, dao layer inherit JpaRepository

 

 

 

 

 Three, controller operations increase

result:

 

Delete operations:

 

 Modify operations:

 

 

 

 

 

Guess you like

Origin www.cnblogs.com/mayuan01/p/12005812.html