fans,liked
This commit is contained in:
parent
218485c711
commit
6834b4a129
@ -28,7 +28,7 @@ spring:
|
||||
max-active: 200 # 连接池最大连接数
|
||||
max-wait: 100 # 连接池最大阻塞等待时间, -1表示没有限制
|
||||
min-idle: 4 # 最小空闲连接
|
||||
timeout: 5000
|
||||
timeout: 50000
|
||||
data:
|
||||
mongodb:
|
||||
# uri: mongodb://root:root@192.168.1.202:27017
|
||||
|
@ -8,5 +8,7 @@
|
||||
<id column="id" property="id" jdbcType="VARCHAR" />
|
||||
<result column="user_id" property="userId" jdbcType="VARCHAR" />
|
||||
<result column="vlog_id" property="vlogId" jdbcType="VARCHAR" />
|
||||
<result column="created_time" property="createdTime" jdbcType="TIMESTAMP" />
|
||||
|
||||
</resultMap>
|
||||
</mapper>
|
@ -3,8 +3,10 @@ package com.imooc.pojo;
|
||||
import org.springframework.data.annotation.Id;
|
||||
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Table;
|
||||
import java.util.Date;
|
||||
|
||||
@Table(name = "t_fans")
|
||||
public class Fans {
|
||||
@Id
|
||||
private String id;
|
||||
|
@ -3,6 +3,7 @@ package com.imooc.pojo;
|
||||
import org.springframework.data.annotation.Id;
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Table;
|
||||
import java.util.Date;
|
||||
|
||||
@Table(name = "t_my_liked_vlog")
|
||||
public class MyLikedVlog {
|
||||
@ -21,6 +22,9 @@ public class MyLikedVlog {
|
||||
@Column(name = "vlog_id")
|
||||
private String vlogId;
|
||||
|
||||
@Column(name = "created_time")
|
||||
private Date createdTime;
|
||||
|
||||
/**
|
||||
* @return id
|
||||
*/
|
||||
@ -70,4 +74,9 @@ public class MyLikedVlog {
|
||||
public void setVlogId(String vlogId) {
|
||||
this.vlogId = vlogId;
|
||||
}
|
||||
|
||||
|
||||
public void setCreatedTime(Date date) {
|
||||
this.createdTime = date;
|
||||
}
|
||||
}
|
@ -202,6 +202,7 @@ public class VlogServiceImpl extends BaseInfoProperties implements VlogService {
|
||||
likedVlog.setId(rid);
|
||||
likedVlog.setVlogId(vlogId);
|
||||
likedVlog.setUserId(userId);
|
||||
likedVlog.setCreatedTime(new Date());
|
||||
|
||||
myLikedVlogMapper.insert(likedVlog);
|
||||
// System.out.println(vlogId);
|
||||
|
Loading…
x
Reference in New Issue
Block a user