-
Notifications
You must be signed in to change notification settings - Fork 176
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
65 additions
and
13 deletions.
There are no files selected for viewing
22 changes: 22 additions & 0 deletions
22
order/src/main/java/club/newtech/qbike/order/domain/core/entity/Candidate.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package club.newtech.qbike.order.domain.core.entity; | ||
|
||
import club.newtech.qbike.order.domain.core.root.Order; | ||
import lombok.Data; | ||
|
||
import javax.persistence.*; | ||
import java.util.Date; | ||
|
||
@Data | ||
@Entity | ||
@Table(name = "t_candidate") | ||
public class Candidate { | ||
@Id | ||
@GeneratedValue(strategy = GenerationType.IDENTITY) | ||
private int cid; | ||
@ManyToOne | ||
@JoinColumn(name = "order_id") | ||
private Order order; | ||
private String candidateDriverId; | ||
@Temporal(TemporalType.TIMESTAMP) | ||
private Date updated; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
order/src/main/java/club/newtech/qbike/order/domain/repository/CanidateRepository.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package club.newtech.qbike.order.domain.repository; | ||
|
||
import club.newtech.qbike.order.domain.core.entity.Candidate; | ||
import org.springframework.data.repository.CrudRepository; | ||
|
||
public interface CanidateRepository extends CrudRepository<Candidate, Integer> { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters