Subversion Repositories SmartDukaan

Rev

Rev 30031 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 30031 Rev 30044
Line 5... Line 5...
5
import javax.persistence.Column;
5
import javax.persistence.Column;
6
import javax.persistence.Entity;
6
import javax.persistence.Entity;
7
import javax.persistence.GeneratedValue;
7
import javax.persistence.GeneratedValue;
8
import javax.persistence.GenerationType;
8
import javax.persistence.GenerationType;
9
import javax.persistence.Id;
9
import javax.persistence.Id;
-
 
10
import javax.persistence.NamedQueries;
-
 
11
import javax.persistence.NamedQuery;
10
import javax.persistence.Table;
12
import javax.persistence.Table;
11
 
13
 
12
@Entity
14
@Entity
13
@Table(name = "dtr.brands_limit", schema = "dtr")
15
@Table(name = "dtr.brands_limit", schema = "dtr")
-
 
16
 
-
 
17
@NamedQueries({
-
 
18
		@NamedQuery(name = "BrandLimit.selectAllPartnerBrandLimit", query = "select new com.spice.profitmandi.dao.model.PartnerBrandLimit(fs.id,bl.brandName,"
-
 
19
				+ " case when rbl.partnerId is null then bl.stockLimit else rbl.minStockLimit end) "
-
 
20
				+ " from FofoStore fs join BrandLimit bl on 1=1"
-
 
21
				+ " left join RetailerBrandsLimit rbl on (rbl.brandName = bl.brandName and rbl.partnerId = fs.id)"), })
14
public class BrandLimit {
22
public class BrandLimit {
15
	
23
 
16
	@Id
24
	@Id
17
	@Column(name = "id", unique = false, updatable = false)
25
	@Column(name = "id", unique = false, updatable = false)
18
	@GeneratedValue(strategy = GenerationType.IDENTITY)
26
	@GeneratedValue(strategy = GenerationType.IDENTITY)
19
	private int id;
27
	private int id;
20
	
28
 
21
	@Column(name = "brand_name")
29
	@Column(name = "brand_name")
22
	private String brandName;
30
	private String brandName;
23
	@Column(name = "brand_limit")
31
	@Column(name = "brand_limit")
24
	private float brandLimit;
32
	private float brandLimit;
25
	@Column(name = "created_time_stamp")
33
	@Column(name = "created_time_stamp")
26
	private LocalDateTime createdTimestamp;
34
	private LocalDateTime createdTimestamp;
27
	
35
 
28
	@Column(name = "stock_limit")
36
	@Column(name = "stock_limit")
29
	private float stockLimit;
37
	private float stockLimit;
30
 
38
 
31
	@Column(name = "updated_time_stamp")
39
	@Column(name = "updated_time_stamp")
32
	private LocalDateTime updatedTimestamp;
40
	private LocalDateTime updatedTimestamp;
Line 36... Line 44...
36
	}
44
	}
37
 
45
 
38
	public void setId(int id) {
46
	public void setId(int id) {
39
		this.id = id;
47
		this.id = id;
40
	}
48
	}
41
	
49
 
42
	public float getStockLimit() {
50
	public float getStockLimit() {
43
		return stockLimit;
51
		return stockLimit;
44
	}
52
	}
45
 
53
 
46
	public void setStockLimit(float stockLimit) {
54
	public void setStockLimit(float stockLimit) {
Line 77... Line 85...
77
 
85
 
78
	public void setUpdatedTimestamp(LocalDateTime updatedTimestamp) {
86
	public void setUpdatedTimestamp(LocalDateTime updatedTimestamp) {
79
		this.updatedTimestamp = updatedTimestamp;
87
		this.updatedTimestamp = updatedTimestamp;
80
	}
88
	}
81
 
89
 
82
	
-
 
83
 
-
 
84
	@Override
90
	@Override
85
	public String toString() {
91
	public String toString() {
86
		return "BrandLimit [id=" + id + ", brandName=" + brandName + ", brandLimit=" + brandLimit
92
		return "BrandLimit [id=" + id + ", brandName=" + brandName + ", brandLimit=" + brandLimit
87
				+ ", createdTimestamp=" + createdTimestamp + ", stockLimit=" + stockLimit + ", updatedTimestamp="
93
				+ ", createdTimestamp=" + createdTimestamp + ", stockLimit=" + stockLimit + ", updatedTimestamp="
88
				+ updatedTimestamp + "]";
94
				+ updatedTimestamp + "]";
Line 91... Line 97...
91
	public BrandLimit() {
97
	public BrandLimit() {
92
		super();
98
		super();
93
		// TODO Auto-generated constructor stub
99
		// TODO Auto-generated constructor stub
94
	}
100
	}
95
 
101
 
96
 
-
 
97
	
-
 
98
	
-
 
99
}
102
}