任务中心
任务列表 任务领取(不包括领取记录) 签到
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
package com.sqx.modules.userSign.controller;
|
||||
|
||||
|
||||
import com.sqx.modules.userSign.entity.UserSignRecord;
|
||||
import com.sqx.modules.userSign.service.UserSignRecordService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.sqx.common.utils.DateUtils;
|
||||
import com.sqx.common.utils.Result;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
@Slf4j
|
||||
@RestController
|
||||
@Api(value = "用户签到", tags = {"用户签到"})
|
||||
@RequestMapping(value = "/userSignRecord")
|
||||
public class UserSignRecordController {
|
||||
/**
|
||||
* 服务对象
|
||||
*/
|
||||
@Autowired
|
||||
private UserSignRecordService userSignRecordService;
|
||||
|
||||
// @GetMapping("/selectUserSignRecord")
|
||||
// @ApiOperation("查询用户签到表")
|
||||
// public Result selectUserSignRecord(Integer page, Integer limit,@RequestAttribute("userId") Long userId) {
|
||||
// return Result.success().put("data", userSignRecordService.page(new Page<>(page, limit), new QueryWrapper<UserSignRecord>().orderByAsc("create_time")));
|
||||
// }
|
||||
}
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
package com.sqx.modules.userSign.dao;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.sqx.modules.userSign.entity.UserSignRecord;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
@Mapper
|
||||
public interface UserSignRecordDao extends BaseMapper<UserSignRecord> {
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
package com.sqx.modules.userSign.entity;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.activerecord.Model;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* 用户签到表(UserSignRecord)表实体类
|
||||
*
|
||||
* @author ww
|
||||
* @since 2024-12-07 11:37:10
|
||||
*/
|
||||
@Data
|
||||
@TableName("user_sign_record")
|
||||
@ApiModel(value = "用户签到表 实体类")
|
||||
public class UserSignRecord extends Model<UserSignRecord> {
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
@ApiModelProperty("用户id")
|
||||
private Long userId;
|
||||
@ApiModelProperty("累计签到")
|
||||
private Integer day;
|
||||
@ApiModelProperty("签到日")
|
||||
private String signDay;
|
||||
@ApiModelProperty("创建时间")
|
||||
private Date createTime;
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
package com.sqx.modules.userSign.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.sqx.modules.userSign.entity.UserSignRecord;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
public interface UserSignRecordService extends IService<UserSignRecord> {
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.sqx.modules.userSign.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.sqx.modules.userSign.dao.UserSignRecordDao;
|
||||
import com.sqx.modules.userSign.entity.UserSignRecord;
|
||||
import com.sqx.modules.userSign.service.UserSignRecordService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@Service
|
||||
public class UserSignRecordServiceImpl extends ServiceImpl<UserSignRecordDao, UserSignRecord> implements UserSignRecordService {
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user