forked from pisces-hub/muchat
-
Notifications
You must be signed in to change notification settings - Fork 0
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
73 changed files
with
601 additions
and
262 deletions.
There are no files selected for viewing
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
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
2 changes: 1 addition & 1 deletion
2
im-commom/im-common-core/src/main/java/io/pisceshub/muchat/common/core/enums/ChatType.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
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 |
---|---|---|
|
@@ -6,7 +6,7 @@ spring: | |
host: 127.0.0.1 | ||
port: 6379 | ||
database: 1 | ||
password: lilishop | ||
password: root | ||
|
||
app: | ||
ip: 127.0.0.1 | ||
|
22 changes: 22 additions & 0 deletions
22
im-server/src/main/java/io/pisceshub/muchat/server/common/dto/ChatSessionInfoDto.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 io.pisceshub.muchat.server.common.dto; | ||
|
||
import io.pisceshub.muchat.common.core.enums.ChatType; | ||
import lombok.Data; | ||
|
||
import javax.validation.constraints.NotNull; | ||
import java.io.Serializable; | ||
|
||
/** | ||
* @author xiaochangbai | ||
* @date 2023-06-17 16:34 | ||
*/ | ||
@Data | ||
public class ChatSessionInfoDto implements Serializable { | ||
|
||
@NotNull(message = "对方id不能为空") | ||
private Long targetId; | ||
|
||
@NotNull(message = "聊天类型不能为空") | ||
private ChatType chatType; | ||
|
||
} |
2 changes: 1 addition & 1 deletion
2
...isceshub/muchat/server/entity/Friend.java → ...b/muchat/server/common/entity/Friend.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
2 changes: 1 addition & 1 deletion
2
...pisceshub/muchat/server/entity/Group.java → ...ub/muchat/server/common/entity/Group.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
2 changes: 1 addition & 1 deletion
2
...hub/muchat/server/entity/GroupMember.java → ...hat/server/common/entity/GroupMember.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
2 changes: 1 addition & 1 deletion
2
...ub/muchat/server/entity/GroupMessage.java → ...at/server/common/entity/GroupMessage.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
2 changes: 1 addition & 1 deletion
2
.../muchat/server/entity/PrivateMessage.java → .../server/common/entity/PrivateMessage.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
2 changes: 1 addition & 1 deletion
2
.../pisceshub/muchat/server/entity/User.java → ...hub/muchat/server/common/entity/User.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
9 changes: 9 additions & 0 deletions
9
im-server/src/main/java/io/pisceshub/muchat/server/common/package-info.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,9 @@ | ||
package io.pisceshub.muchat.server.common; | ||
|
||
|
||
/** | ||
* vo:接收前端参数,与响应前端结果 | ||
* xxxReq请求参数、xxxResp响应结果 | ||
* dto:业务之间传输 | ||
* entity:数据库表字段 | ||
*/ |
21 changes: 21 additions & 0 deletions
21
im-server/src/main/java/io/pisceshub/muchat/server/common/vo/common/PageReq.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,21 @@ | ||
package io.pisceshub.muchat.server.common.vo.common; | ||
|
||
import lombok.Data; | ||
|
||
/** | ||
* @author xiaochangbai | ||
* @date 2023-06-17 16:40 | ||
*/ | ||
@Data | ||
public class PageReq { | ||
|
||
/** | ||
* 页码 | ||
*/ | ||
private Long page = 1L; | ||
|
||
/** | ||
* 每页大小 | ||
*/ | ||
private Long size = 15L; | ||
} |
29 changes: 29 additions & 0 deletions
29
im-server/src/main/java/io/pisceshub/muchat/server/common/vo/common/PageResp.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,29 @@ | ||
package io.pisceshub.muchat.server.common.vo.common; | ||
|
||
import lombok.Data; | ||
|
||
import java.util.List; | ||
|
||
/** | ||
* @author xiaochangbai | ||
* @date 2023-06-17 16:40 | ||
*/ | ||
@Data | ||
public class PageResp<T> { | ||
|
||
/** | ||
* 当前页码 | ||
*/ | ||
private Long page; | ||
|
||
/** | ||
* 总数量 | ||
*/ | ||
private Long total; | ||
|
||
|
||
/** | ||
* 数据集 | ||
*/ | ||
private List<T> list; | ||
} |
4 changes: 2 additions & 2 deletions
4
...eshub/muchat/server/vo/UploadImageVO.java → ...ver/common/vo/common/UploadImageResp.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
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
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
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
25 changes: 25 additions & 0 deletions
25
im-server/src/main/java/io/pisceshub/muchat/server/common/vo/user/ChatSessionAddReq.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,25 @@ | ||
package io.pisceshub.muchat.server.common.vo.user; | ||
|
||
import io.pisceshub.muchat.common.core.enums.ChatType; | ||
import lombok.Data; | ||
|
||
import javax.validation.constraints.NotNull; | ||
import java.io.Serializable; | ||
import java.util.Objects; | ||
|
||
/** | ||
* @author xiaochangbai | ||
* @date 2023-06-15 21:44 | ||
*/ | ||
@Data | ||
public class ChatSessionAddReq implements Serializable { | ||
|
||
|
||
@NotNull(message = "对方id不能为空") | ||
private Long targetId; | ||
|
||
@NotNull(message = "聊天类型不能为空") | ||
private ChatType chatType; | ||
|
||
|
||
} |
66 changes: 66 additions & 0 deletions
66
im-server/src/main/java/io/pisceshub/muchat/server/common/vo/user/ChatSessionInfoResp.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,66 @@ | ||
package io.pisceshub.muchat.server.common.vo.user; | ||
|
||
import io.pisceshub.muchat.common.core.enums.ChatType; | ||
import io.swagger.annotations.ApiModelProperty; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Builder; | ||
import lombok.Data; | ||
import lombok.NoArgsConstructor; | ||
|
||
import javax.validation.constraints.NotNull; | ||
import java.io.Serializable; | ||
import java.util.Objects; | ||
|
||
/** | ||
* @author xiaochangbai | ||
* @date 2023-06-15 21:44 | ||
*/ | ||
@Data | ||
@Builder | ||
@AllArgsConstructor | ||
@NoArgsConstructor | ||
public class ChatSessionInfoResp implements Serializable { | ||
|
||
|
||
/** | ||
* 对方的id:好友id或群id | ||
*/ | ||
private Long targetId; | ||
|
||
|
||
/** | ||
* 聊天类型 | ||
*/ | ||
private ChatType chatType; | ||
|
||
/** | ||
* 好友昵称或群名称 | ||
*/ | ||
private String name; | ||
|
||
|
||
/** | ||
* 头像 | ||
*/ | ||
private String headImage; | ||
|
||
|
||
/** | ||
* 未读消息数量 | ||
*/ | ||
private Long unReadCount; | ||
|
||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) return true; | ||
if (o == null || getClass() != o.getClass()) return false; | ||
ChatSessionInfoResp that = (ChatSessionInfoResp) o; | ||
return Objects.equals(targetId, that.targetId) && chatType == that.chatType; | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(targetId, chatType); | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
.../pisceshub/muchat/server/vo/FriendVO.java → ...uchat/server/common/vo/user/FriendVO.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
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
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
2 changes: 1 addition & 1 deletion
2
...o/pisceshub/muchat/server/vo/GroupVO.java → ...muchat/server/common/vo/user/GroupVO.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
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
4 changes: 2 additions & 2 deletions
4
...o/pisceshub/muchat/server/vo/LoginVO.java → ...chat/server/common/vo/user/LoginResp.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
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
Oops, something went wrong.