src/com/itbaizhan/entity/Indent.java
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
package com.itbaizhan.entity;
import java.util.Date;
import java.util.List;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Transient;
import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;
@Entity // 注解为hibernate实体 对应数据库中同名表
public class Indent {
@Id // 注解主键
@GeneratedValue //id生成策略 默认auto 相当于hibernate的native - 自增字段
private int id;
private float total;
private int amount;
private int status;
private String name;
private String phone;
private String address;
private Date systime;
@ManyToOne()
@NotFound(action=NotFoundAction.IGNORE)
private Users user;
@OneToMany
@Transient // 不持久化
private List<Items> itemList;
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public Users getUser() {
return user;
}
public void setUser(Users user) {
this.user = user;
}
public float getTotal() {
return total;
}
public void setTotal(float total) {
this.total = (float)Math.round(total*100)/100;
}
public Date getSystime() {
return systime;
}
public void setSystime(Date systime) {
this.systime = systime;
}
后面还有 38 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。