History
This commit is contained in:
parent
9a53025a4b
commit
0843fbccde
@ -0,0 +1,25 @@
|
||||
package com.plannaplan.entities;
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.GeneratedValue;
|
||||
import javax.persistence.GenerationType;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.JoinColumn;
|
||||
import javax.persistence.ManyToOne;
|
||||
|
||||
@Entity
|
||||
public class HistoryElement {
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.AUTO)
|
||||
private Long id;
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "user_id")
|
||||
private User user;
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "incoming_id")
|
||||
private Groups incoming;
|
||||
@ManyToOne
|
||||
@JoinColumn(name = "outcoming_id")
|
||||
private Groups outcoming;
|
||||
|
||||
}
|
@ -0,0 +1,11 @@
|
||||
package com.plannaplan.repositories;
|
||||
|
||||
import com.plannaplan.entities.HistoryElement;
|
||||
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
@Repository
|
||||
public interface HistoryRepository extends JpaRepository<HistoryElement, Long> {
|
||||
|
||||
}
|
@ -0,0 +1,12 @@
|
||||
package com.plannaplan.services;
|
||||
|
||||
import com.plannaplan.repositories.HistoryRepository;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@Service
|
||||
public class HistoryService {
|
||||
@Autowired
|
||||
private HistoryRepository repo;
|
||||
}
|
@ -0,0 +1,5 @@
|
||||
package com.plannaplan.types;
|
||||
|
||||
public enum ActionTypes {
|
||||
ADD, DELETE, REPLACE
|
||||
}
|
155652
org.springframework.data.jpa.repository.JpaRepository
Normal file
155652
org.springframework.data.jpa.repository.JpaRepository
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user