Showing
3 changed files
with
27 additions
and
3 deletions
@@ -15,6 +15,10 @@ public class SizePool { | @@ -15,6 +15,10 @@ public class SizePool { | ||
15 | private Integer updateTime; | 15 | private Integer updateTime; |
16 | 16 | ||
17 | private Integer updateUid; | 17 | private Integer updateUid; |
18 | + | ||
19 | + private Integer imageWidth; | ||
20 | + | ||
21 | + private Integer imageHeight; | ||
18 | 22 | ||
19 | public Integer getId() { | 23 | public Integer getId() { |
20 | return id; | 24 | return id; |
@@ -64,6 +68,22 @@ public class SizePool { | @@ -64,6 +68,22 @@ public class SizePool { | ||
64 | this.updateUid = updateUid; | 68 | this.updateUid = updateUid; |
65 | } | 69 | } |
66 | 70 | ||
71 | + public Integer getImageWidth() { | ||
72 | + return imageWidth; | ||
73 | + } | ||
74 | + | ||
75 | + public void setImageWidth(Integer imageWidth) { | ||
76 | + this.imageWidth = imageWidth; | ||
77 | + } | ||
78 | + | ||
79 | + public Integer getImageHeight() { | ||
80 | + return imageHeight; | ||
81 | + } | ||
82 | + | ||
83 | + public void setImageHeight(Integer imageHeight) { | ||
84 | + this.imageHeight = imageHeight; | ||
85 | + } | ||
86 | + | ||
67 | @Override | 87 | @Override |
68 | public String toString() { | 88 | public String toString() { |
69 | return JSONObject.toJSONString(this); | 89 | return JSONObject.toJSONString(this); |
@@ -8,15 +8,17 @@ | @@ -8,15 +8,17 @@ | ||
8 | <result column="image_url" property="imageUrl" jdbcType="VARCHAR" /> | 8 | <result column="image_url" property="imageUrl" jdbcType="VARCHAR" /> |
9 | <result column="update_time" property="updateTime" jdbcType="INTEGER" /> | 9 | <result column="update_time" property="updateTime" jdbcType="INTEGER" /> |
10 | <result column="update_uid" property="updateUid" jdbcType="INTEGER" /> | 10 | <result column="update_uid" property="updateUid" jdbcType="INTEGER" /> |
11 | + <result column="image_width" property="imageWidth" jdbcType="INTEGER" /> | ||
12 | + <result column="image_height" property="imageHeight" jdbcType="INTEGER" /> | ||
11 | </resultMap> | 13 | </resultMap> |
12 | 14 | ||
13 | <sql id="Base_Column_List"> | 15 | <sql id="Base_Column_List"> |
14 | - id, status, range_type, image_url, update_time, update_uid | 16 | + id, status, range_type, image_url, update_time, update_uid, image_width, image_height |
15 | </sql> | 17 | </sql> |
16 | 18 | ||
17 | <insert id="insert" useGeneratedKeys="true" keyProperty="id" parameterType="com.yoho.ufo.dal.model.SizePool"> | 19 | <insert id="insert" useGeneratedKeys="true" keyProperty="id" parameterType="com.yoho.ufo.dal.model.SizePool"> |
18 | - insert into size_pool(id, status, range_type, image_url, update_time, update_uid) | ||
19 | - values (#{id}, #{status}, #{rangeType}, #{imageUrl}, #{updateTime}, #{updateUid}) | 20 | + insert into size_pool(id, status, range_type, image_url, update_time, update_uid, image_width, image_height) |
21 | + values (#{id}, #{status}, #{rangeType}, #{imageUrl}, #{updateTime}, #{updateUid}, #{imageWidth}, #{imageHeight}) | ||
20 | </insert> | 22 | </insert> |
21 | 23 | ||
22 | <update id="updateByPrimaryKeySelective" parameterType="com.yoho.ufo.dal.model.SizePool"> | 24 | <update id="updateByPrimaryKeySelective" parameterType="com.yoho.ufo.dal.model.SizePool"> |
@@ -69,6 +69,8 @@ public class SizePoolService implements ISizePoolService{ | @@ -69,6 +69,8 @@ public class SizePoolService implements ISizePoolService{ | ||
69 | sizePool.setStatus(STATUS_OPEN);//默认开启 | 69 | sizePool.setStatus(STATUS_OPEN);//默认开启 |
70 | sizePool.setRangeType(bo.getRangeType()); | 70 | sizePool.setRangeType(bo.getRangeType()); |
71 | sizePool.setImageUrl(bo.getImageUrl()); | 71 | sizePool.setImageUrl(bo.getImageUrl()); |
72 | + sizePool.setImageWidth(bo.getImageWidth()); | ||
73 | + sizePool.setImageHeight(bo.getImageHeight()); | ||
72 | sizePool.setUpdateTime(DateUtil.getCurrentTimeSeconds()); | 74 | sizePool.setUpdateTime(DateUtil.getCurrentTimeSeconds()); |
73 | sizePool.setUpdateUid(new UserHelper().getUserId()); | 75 | sizePool.setUpdateUid(new UserHelper().getUserId()); |
74 | 76 |
-
Please register or login to post a comment