Get 获取互动信息
(ctx context.Context, postId uint)
| 77 | |
| 78 | // Get 获取互动信息 |
| 79 | func (i *InteractiveRepositoryImpl) Get(ctx context.Context, postId uint) (domain.Interactive, error) { |
| 80 | ic, err := i.dao.Get(ctx, postId) |
| 81 | if err != nil { |
| 82 | i.l.Error(PostGetInteractiveERROR, zap.Error(err)) |
| 83 | return domain.Interactive{}, err |
| 84 | } |
| 85 | return toDomain(ic), nil |
| 86 | } |
| 87 | |
| 88 | // Liked 检查是否已点赞 |
| 89 | func (i *InteractiveRepositoryImpl) Liked(ctx context.Context, postId uint, uid int64) (bool, error) { |