nft stake task logic
This commit is contained in:
@@ -6,10 +6,9 @@ import (
|
||||
"nova_task/internal/model"
|
||||
"nova_task/internal/pkg/errs"
|
||||
"nova_task/internal/pkg/utils"
|
||||
"time"
|
||||
|
||||
"nova_task/internal/svc"
|
||||
"nova_task/internal/types"
|
||||
"time"
|
||||
|
||||
"github.com/zeromicro/go-zero/core/logx"
|
||||
)
|
||||
@@ -53,7 +52,9 @@ func (l *GetNftListLogic) GetNftList() (*types.UserNftList, error) {
|
||||
nft, err := l.svcCtx.StakeNftModel.FindOneByUidTokenId(l.ctx, uid, token)
|
||||
if err == nil {
|
||||
hasStake = nft.State == 1
|
||||
stakeAt = nft.UpdatedAt.Format(time.DateOnly)
|
||||
if hasStake {
|
||||
stakeAt = nft.UpdatedAt.Format(time.DateOnly)
|
||||
}
|
||||
}
|
||||
nftList = append(nftList, types.UserNft{
|
||||
TokenId: token,
|
||||
|
||||
Reference in New Issue
Block a user