Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

update in spring boot

public void updateCustomer(CustomerDto dto) {
    Customer myCustomer = repo.findById(dto.id);
    mapper.updateCustomerFromDto(dto, myCustomer);
    repo.save(myCustomer);
}
Source by www.baeldung.com #
 
PREVIOUS NEXT
Tagged: #update #spring #boot
ADD COMMENT
Topic
Name
1+3 =