فهرست منبع

1.打卡红包记录 2.打卡文章

wjj 1 هفته پیش
والد
کامیت
7d5515a654

+ 103 - 0
fs-admin/src/main/java/com/fs/his/controller/FsSignArticleController.java

@@ -0,0 +1,103 @@
+package com.fs.his.controller;
+
+import java.util.List;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.fs.common.annotation.Log;
+import com.fs.common.core.controller.BaseController;
+import com.fs.common.core.domain.AjaxResult;
+import com.fs.common.enums.BusinessType;
+import com.fs.his.domain.FsSignArticle;
+import com.fs.his.service.IFsSignArticleService;
+import com.fs.common.utils.poi.ExcelUtil;
+import com.fs.common.core.page.TableDataInfo;
+
+/**
+ * 打卡文章Controller
+ * 
+ * @author fs
+ * @date 2026-04-16
+ */
+@RestController
+@RequestMapping("/his/article")
+public class FsSignArticleController extends BaseController
+{
+    @Autowired
+    private IFsSignArticleService fsSignArticleService;
+
+    /**
+     * 查询打卡文章列表
+     */
+    @PreAuthorize("@ss.hasPermi('his:article:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(FsSignArticle fsSignArticle)
+    {
+        startPage();
+        List<FsSignArticle> list = fsSignArticleService.selectFsSignArticleList(fsSignArticle);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出打卡文章列表
+     */
+    @PreAuthorize("@ss.hasPermi('his:article:export')")
+    @Log(title = "打卡文章", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(FsSignArticle fsSignArticle)
+    {
+        List<FsSignArticle> list = fsSignArticleService.selectFsSignArticleList(fsSignArticle);
+        ExcelUtil<FsSignArticle> util = new ExcelUtil<FsSignArticle>(FsSignArticle.class);
+        return util.exportExcel(list, "打卡文章数据");
+    }
+
+    /**
+     * 获取打卡文章详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('his:article:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return AjaxResult.success(fsSignArticleService.selectFsSignArticleById(id));
+    }
+
+    /**
+     * 新增打卡文章
+     */
+    @PreAuthorize("@ss.hasPermi('his:article:add')")
+    @Log(title = "打卡文章", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody FsSignArticle fsSignArticle)
+    {
+        return toAjax(fsSignArticleService.insertFsSignArticle(fsSignArticle));
+    }
+
+    /**
+     * 修改打卡文章
+     */
+    @PreAuthorize("@ss.hasPermi('his:article:edit')")
+    @Log(title = "打卡文章", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody FsSignArticle fsSignArticle)
+    {
+        return toAjax(fsSignArticleService.updateFsSignArticle(fsSignArticle));
+    }
+
+    /**
+     * 删除打卡文章
+     */
+    @PreAuthorize("@ss.hasPermi('his:article:remove')")
+    @Log(title = "打卡文章", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(fsSignArticleService.deleteFsSignArticleByIds(ids));
+    }
+}

+ 64 - 0
fs-service/src/main/java/com/fs/his/domain/FsSignArticle.java

@@ -0,0 +1,64 @@
+package com.fs.his.domain;
+
+import java.math.BigDecimal;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.fs.common.annotation.Excel;
+import lombok.Data;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 打卡文章对象 fs_sign_article
+ *
+ * @author fs
+ * @date 2026-04-16
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class FsSignArticle extends BaseEntity{
+
+    /** $column.columnComment */
+    private Long id;
+
+    /** 别名 */
+    @Excel(name = "别名")
+    private String secondName;
+
+    /** 医生id */
+    @Excel(name = "医生id")
+    private Long doctorId;
+
+    /** 封面图 */
+    @Excel(name = "封面图")
+    private String imageUrl;
+
+    /** 标题 */
+    @Excel(name = "标题")
+    private String title;
+
+    /** 内容 */
+    @Excel(name = "内容")
+    private String content;
+
+    /** 浏览量 */
+    @Excel(name = "浏览量")
+    private Long views;
+
+    /** vodeoUrl */
+    @Excel(name = "vodeoUrl")
+    private String videoUrl;
+
+    /** 红包金额 */
+    @Excel(name = "红包金额")
+    private BigDecimal amount;
+
+    /** 打卡类型:1-直接打卡 2-上传图片 3-上传视频 */
+    @Excel(name = "打卡类型:1-直接打卡 2-上传图片 3-上传视频")
+    private Integer type;
+
+    /** 是否打卡 0-否 1-是 */
+    @Excel(name = "是否打卡 0-否 1-是")
+    private Integer signFlag;
+
+
+}

+ 61 - 0
fs-service/src/main/java/com/fs/his/mapper/FsSignArticleMapper.java

@@ -0,0 +1,61 @@
+package com.fs.his.mapper;
+
+import java.util.List;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fs.his.domain.FsSignArticle;
+
+/**
+ * 打卡文章Mapper接口
+ * 
+ * @author fs
+ * @date 2026-04-16
+ */
+public interface FsSignArticleMapper extends BaseMapper<FsSignArticle>{
+    /**
+     * 查询打卡文章
+     * 
+     * @param id 打卡文章主键
+     * @return 打卡文章
+     */
+    FsSignArticle selectFsSignArticleById(Long id);
+
+    /**
+     * 查询打卡文章列表
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 打卡文章集合
+     */
+    List<FsSignArticle> selectFsSignArticleList(FsSignArticle fsSignArticle);
+
+    /**
+     * 新增打卡文章
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 结果
+     */
+    int insertFsSignArticle(FsSignArticle fsSignArticle);
+
+    /**
+     * 修改打卡文章
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 结果
+     */
+    int updateFsSignArticle(FsSignArticle fsSignArticle);
+
+    /**
+     * 删除打卡文章
+     * 
+     * @param id 打卡文章主键
+     * @return 结果
+     */
+    int deleteFsSignArticleById(Long id);
+
+    /**
+     * 批量删除打卡文章
+     * 
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteFsSignArticleByIds(Long[] ids);
+}

+ 61 - 0
fs-service/src/main/java/com/fs/his/service/IFsSignArticleService.java

@@ -0,0 +1,61 @@
+package com.fs.his.service;
+
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.fs.his.domain.FsSignArticle;
+
+/**
+ * 打卡文章Service接口
+ * 
+ * @author fs
+ * @date 2026-04-16
+ */
+public interface IFsSignArticleService extends IService<FsSignArticle>{
+    /**
+     * 查询打卡文章
+     * 
+     * @param id 打卡文章主键
+     * @return 打卡文章
+     */
+    FsSignArticle selectFsSignArticleById(Long id);
+
+    /**
+     * 查询打卡文章列表
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 打卡文章集合
+     */
+    List<FsSignArticle> selectFsSignArticleList(FsSignArticle fsSignArticle);
+
+    /**
+     * 新增打卡文章
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 结果
+     */
+    int insertFsSignArticle(FsSignArticle fsSignArticle);
+
+    /**
+     * 修改打卡文章
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 结果
+     */
+    int updateFsSignArticle(FsSignArticle fsSignArticle);
+
+    /**
+     * 批量删除打卡文章
+     * 
+     * @param ids 需要删除的打卡文章主键集合
+     * @return 结果
+     */
+    int deleteFsSignArticleByIds(Long[] ids);
+
+    /**
+     * 删除打卡文章信息
+     * 
+     * @param id 打卡文章主键
+     * @return 结果
+     */
+    int deleteFsSignArticleById(Long id);
+}

+ 94 - 0
fs-service/src/main/java/com/fs/his/service/impl/FsSignArticleServiceImpl.java

@@ -0,0 +1,94 @@
+package com.fs.his.service.impl;
+
+import java.util.List;
+import com.fs.common.utils.DateUtils;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.fs.his.mapper.FsSignArticleMapper;
+import com.fs.his.domain.FsSignArticle;
+import com.fs.his.service.IFsSignArticleService;
+
+/**
+ * 打卡文章Service业务层处理
+ * 
+ * @author fs
+ * @date 2026-04-16
+ */
+@Service
+public class FsSignArticleServiceImpl extends ServiceImpl<FsSignArticleMapper, FsSignArticle> implements IFsSignArticleService {
+
+    /**
+     * 查询打卡文章
+     * 
+     * @param id 打卡文章主键
+     * @return 打卡文章
+     */
+    @Override
+    public FsSignArticle selectFsSignArticleById(Long id)
+    {
+        return baseMapper.selectFsSignArticleById(id);
+    }
+
+    /**
+     * 查询打卡文章列表
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 打卡文章
+     */
+    @Override
+    public List<FsSignArticle> selectFsSignArticleList(FsSignArticle fsSignArticle)
+    {
+        return baseMapper.selectFsSignArticleList(fsSignArticle);
+    }
+
+    /**
+     * 新增打卡文章
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 结果
+     */
+    @Override
+    public int insertFsSignArticle(FsSignArticle fsSignArticle)
+    {
+        fsSignArticle.setCreateTime(DateUtils.getNowDate());
+        return baseMapper.insertFsSignArticle(fsSignArticle);
+    }
+
+    /**
+     * 修改打卡文章
+     * 
+     * @param fsSignArticle 打卡文章
+     * @return 结果
+     */
+    @Override
+    public int updateFsSignArticle(FsSignArticle fsSignArticle)
+    {
+        fsSignArticle.setUpdateTime(DateUtils.getNowDate());
+        return baseMapper.updateFsSignArticle(fsSignArticle);
+    }
+
+    /**
+     * 批量删除打卡文章
+     * 
+     * @param ids 需要删除的打卡文章主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsSignArticleByIds(Long[] ids)
+    {
+        return baseMapper.deleteFsSignArticleByIds(ids);
+    }
+
+    /**
+     * 删除打卡文章信息
+     * 
+     * @param id 打卡文章主键
+     * @return 结果
+     */
+    @Override
+    public int deleteFsSignArticleById(Long id)
+    {
+        return baseMapper.deleteFsSignArticleById(id);
+    }
+}

+ 99 - 0
fs-service/src/main/java/com/fs/qw/domain/SignRedPacketRecord.java

@@ -0,0 +1,99 @@
+package com.fs.qw.domain;
+
+import java.math.BigDecimal;
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.fs.common.annotation.Excel;
+import lombok.Data;
+import com.fs.common.core.domain.BaseEntity;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 签到红包领取记录对象 sign_red_packet_record
+ *
+ * @author fs
+ * @date 2026-04-14
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class SignRedPacketRecord extends BaseEntity{
+
+    /** $column.columnComment */
+    private Long id;
+
+    /** 签到图片地址 */
+    @Excel(name = "签到地址")
+    private String signUrl;
+
+    /** 用户id */
+    @Excel(name = "用户id")
+    private Long userId;
+
+    /** 批次单号 */
+    @Excel(name = "批次单号")
+    private String outBatchNo;
+
+    /** $column.columnComment */
+    @Excel(name = "批次单号")
+    private String result;
+
+    /** 微信批次ID */
+    @Excel(name = "微信批次ID")
+    private String batchId;
+
+    /** 点击红包领取按钮标识 0-未生成 1-生成 */
+    @Excel(name = "点击红包领取按钮标识 0-未生成 1-生成")
+    private Integer collectTag;
+
+    /** 红包金额 */
+    @Excel(name = "红包金额")
+    private BigDecimal amount;
+
+    /** 发放时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "发放时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date sendTime;
+
+    /** 领取时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "领取时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date collectTime;
+
+    /** 领取状态(0-已发放 1-已领取 2-已失效) */
+    @Excel(name = "领取状态(0-已发放 1-已领取 2-已失效)")
+    private Integer collectType;
+
+    /** 领取用户名称 */
+    @Excel(name = "领取用户名称")
+    private String userName;
+
+    /** 销售ID */
+    @Excel(name = "销售ID")
+    private Long companyUserId;
+
+    /** 公司ID */
+    @Excel(name = "公司ID")
+    private Long companyId;
+
+    /** 公司名称 */
+    @Excel(name = "公司名称")
+    private String companyName;
+
+    /** 销售企微用户id */
+    @Excel(name = "销售企微用户id")
+    private String qwUserId;
+
+    /** 销售企微用户名 */
+    @Excel(name = "销售企微用户名")
+    private String qwUserName;
+
+    /** 文章id */
+    @Excel(name = "文章id")
+    private Long articleId;
+
+
+    /** 打卡类型 打卡类型:1-直接打卡 2-上传图片 3-上传视频 */
+    private Integer signType;
+
+}

+ 61 - 0
fs-service/src/main/java/com/fs/qw/mapper/SignRedPacketRecordMapper.java

@@ -0,0 +1,61 @@
+package com.fs.qw.mapper;
+
+import java.util.List;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.fs.qw.domain.SignRedPacketRecord;
+
+/**
+ * 签到红包领取记录Mapper接口
+ * 
+ * @author fs
+ * @date 2026-04-14
+ */
+public interface SignRedPacketRecordMapper extends BaseMapper<SignRedPacketRecord>{
+    /**
+     * 查询签到红包领取记录
+     * 
+     * @param id 签到红包领取记录主键
+     * @return 签到红包领取记录
+     */
+    SignRedPacketRecord selectSignRedPacketRecordById(Long id);
+
+    /**
+     * 查询签到红包领取记录列表
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 签到红包领取记录集合
+     */
+    List<SignRedPacketRecord> selectSignRedPacketRecordList(SignRedPacketRecord signRedPacketRecord);
+
+    /**
+     * 新增签到红包领取记录
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 结果
+     */
+    int insertSignRedPacketRecord(SignRedPacketRecord signRedPacketRecord);
+
+    /**
+     * 修改签到红包领取记录
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 结果
+     */
+    int updateSignRedPacketRecord(SignRedPacketRecord signRedPacketRecord);
+
+    /**
+     * 删除签到红包领取记录
+     * 
+     * @param id 签到红包领取记录主键
+     * @return 结果
+     */
+    int deleteSignRedPacketRecordById(Long id);
+
+    /**
+     * 批量删除签到红包领取记录
+     * 
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    int deleteSignRedPacketRecordByIds(Long[] ids);
+}

+ 61 - 0
fs-service/src/main/java/com/fs/qw/service/ISignRedPacketRecordService.java

@@ -0,0 +1,61 @@
+package com.fs.qw.service;
+
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.fs.qw.domain.SignRedPacketRecord;
+
+/**
+ * 签到红包领取记录Service接口
+ * 
+ * @author fs
+ * @date 2026-04-14
+ */
+public interface ISignRedPacketRecordService extends IService<SignRedPacketRecord>{
+    /**
+     * 查询签到红包领取记录
+     * 
+     * @param id 签到红包领取记录主键
+     * @return 签到红包领取记录
+     */
+    SignRedPacketRecord selectSignRedPacketRecordById(Long id);
+
+    /**
+     * 查询签到红包领取记录列表
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 签到红包领取记录集合
+     */
+    List<SignRedPacketRecord> selectSignRedPacketRecordList(SignRedPacketRecord signRedPacketRecord);
+
+    /**
+     * 新增签到红包领取记录
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 结果
+     */
+    int insertSignRedPacketRecord(SignRedPacketRecord signRedPacketRecord);
+
+    /**
+     * 修改签到红包领取记录
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 结果
+     */
+    int updateSignRedPacketRecord(SignRedPacketRecord signRedPacketRecord);
+
+    /**
+     * 批量删除签到红包领取记录
+     * 
+     * @param ids 需要删除的签到红包领取记录主键集合
+     * @return 结果
+     */
+    int deleteSignRedPacketRecordByIds(Long[] ids);
+
+    /**
+     * 删除签到红包领取记录信息
+     * 
+     * @param id 签到红包领取记录主键
+     * @return 结果
+     */
+    int deleteSignRedPacketRecordById(Long id);
+}

+ 94 - 0
fs-service/src/main/java/com/fs/qw/service/impl/SignRedPacketRecordServiceImpl.java

@@ -0,0 +1,94 @@
+package com.fs.qw.service.impl;
+
+import java.util.List;
+import com.fs.common.utils.DateUtils;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.fs.qw.mapper.SignRedPacketRecordMapper;
+import com.fs.qw.domain.SignRedPacketRecord;
+import com.fs.qw.service.ISignRedPacketRecordService;
+
+/**
+ * 签到红包领取记录Service业务层处理
+ * 
+ * @author fs
+ * @date 2026-04-14
+ */
+@Service
+public class SignRedPacketRecordServiceImpl extends ServiceImpl<SignRedPacketRecordMapper, SignRedPacketRecord> implements ISignRedPacketRecordService {
+
+    /**
+     * 查询签到红包领取记录
+     * 
+     * @param id 签到红包领取记录主键
+     * @return 签到红包领取记录
+     */
+    @Override
+    public SignRedPacketRecord selectSignRedPacketRecordById(Long id)
+    {
+        return baseMapper.selectSignRedPacketRecordById(id);
+    }
+
+    /**
+     * 查询签到红包领取记录列表
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 签到红包领取记录
+     */
+    @Override
+    public List<SignRedPacketRecord> selectSignRedPacketRecordList(SignRedPacketRecord signRedPacketRecord)
+    {
+        return baseMapper.selectSignRedPacketRecordList(signRedPacketRecord);
+    }
+
+    /**
+     * 新增签到红包领取记录
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 结果
+     */
+    @Override
+    public int insertSignRedPacketRecord(SignRedPacketRecord signRedPacketRecord)
+    {
+        signRedPacketRecord.setCreateTime(DateUtils.getNowDate());
+        return baseMapper.insertSignRedPacketRecord(signRedPacketRecord);
+    }
+
+    /**
+     * 修改签到红包领取记录
+     * 
+     * @param signRedPacketRecord 签到红包领取记录
+     * @return 结果
+     */
+    @Override
+    public int updateSignRedPacketRecord(SignRedPacketRecord signRedPacketRecord)
+    {
+        signRedPacketRecord.setUpdateTime(DateUtils.getNowDate());
+        return baseMapper.updateSignRedPacketRecord(signRedPacketRecord);
+    }
+
+    /**
+     * 批量删除签到红包领取记录
+     * 
+     * @param ids 需要删除的签到红包领取记录主键
+     * @return 结果
+     */
+    @Override
+    public int deleteSignRedPacketRecordByIds(Long[] ids)
+    {
+        return baseMapper.deleteSignRedPacketRecordByIds(ids);
+    }
+
+    /**
+     * 删除签到红包领取记录信息
+     * 
+     * @param id 签到红包领取记录主键
+     * @return 结果
+     */
+    @Override
+    public int deleteSignRedPacketRecordById(Long id)
+    {
+        return baseMapper.deleteSignRedPacketRecordById(id);
+    }
+}

+ 111 - 0
fs-service/src/main/resources/mapper/his/FsSignArticleMapper.xml

@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.fs.his.mapper.FsSignArticleMapper">
+    
+    <resultMap type="FsSignArticle" id="FsSignArticleResult">
+        <result property="id"    column="id"    />
+        <result property="secondName"    column="second_name"    />
+        <result property="doctorId"    column="doctor_id"    />
+        <result property="imageUrl"    column="image_url"    />
+        <result property="title"    column="title"    />
+        <result property="content"    column="content"    />
+        <result property="views"    column="views"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateTime"    column="update_time"    />
+        <result property="videoUrl"    column="video_url"    />
+        <result property="amount"    column="amount"    />
+        <result property="type"    column="type"    />
+        <result property="signFlag"    column="sign_flag"    />
+    </resultMap>
+
+    <sql id="selectFsSignArticleVo">
+        select id, second_name, doctor_id, image_url, title, content, views, create_time, update_time, video_url, amount, type, sign_flag from fs_sign_article
+    </sql>
+
+    <select id="selectFsSignArticleList" parameterType="FsSignArticle" resultMap="FsSignArticleResult">
+        <include refid="selectFsSignArticleVo"/>
+        <where>  
+            <if test="secondName != null  and secondName != ''"> and second_name like concat('%', #{secondName}, '%')</if>
+            <if test="doctorId != null "> and doctor_id = #{doctorId}</if>
+            <if test="imageUrl != null  and imageUrl != ''"> and image_url = #{imageUrl}</if>
+            <if test="title != null  and title != ''"> and title = #{title}</if>
+            <if test="content != null  and content != ''"> and content = #{content}</if>
+            <if test="views != null "> and views = #{views}</if>
+            <if test="videoUrl != null  and videoUrl != ''"> and video_url = #{videoUrl}</if>
+            <if test="amount != null "> and amount = #{amount}</if>
+            <if test="type != null "> and type = #{type}</if>
+            <if test="signFlag != null "> and sign_flag = #{signFlag}</if>
+        </where>
+    </select>
+    
+    <select id="selectFsSignArticleById" parameterType="Long" resultMap="FsSignArticleResult">
+        <include refid="selectFsSignArticleVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertFsSignArticle" parameterType="FsSignArticle">
+        insert into fs_sign_article
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="secondName != null">second_name,</if>
+            <if test="doctorId != null">doctor_id,</if>
+            <if test="imageUrl != null">image_url,</if>
+            <if test="title != null">title,</if>
+            <if test="content != null">content,</if>
+            <if test="views != null">views,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="videoUrl != null">video_url,</if>
+            <if test="amount != null">amount,</if>
+            <if test="type != null">type,</if>
+            <if test="signFlag != null">sign_flag,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="secondName != null">#{secondName},</if>
+            <if test="doctorId != null">#{doctorId},</if>
+            <if test="imageUrl != null">#{imageUrl},</if>
+            <if test="title != null">#{title},</if>
+            <if test="content != null">#{content},</if>
+            <if test="views != null">#{views},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="videoUrl != null">#{videoUrl},</if>
+            <if test="amount != null">#{amount},</if>
+            <if test="type != null">#{type},</if>
+            <if test="signFlag != null">#{signFlag},</if>
+         </trim>
+    </insert>
+
+    <update id="updateFsSignArticle" parameterType="FsSignArticle">
+        update fs_sign_article
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="secondName != null">second_name = #{secondName},</if>
+            <if test="doctorId != null">doctor_id = #{doctorId},</if>
+            <if test="imageUrl != null">image_url = #{imageUrl},</if>
+            <if test="title != null">title = #{title},</if>
+            <if test="content != null">content = #{content},</if>
+            <if test="views != null">views = #{views},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="videoUrl != null">video_url = #{videoUrl},</if>
+            <if test="amount != null">amount = #{amount},</if>
+            <if test="type != null">type = #{type},</if>
+            <if test="signFlag != null">sign_flag = #{signFlag},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteFsSignArticleById" parameterType="Long">
+        delete from fs_sign_article where id = #{id}
+    </delete>
+
+    <delete id="deleteFsSignArticleByIds" parameterType="String">
+        delete from fs_sign_article where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 149 - 0
fs-service/src/main/resources/mapper/qw/SignRedPacketRecordMapper.xml

@@ -0,0 +1,149 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.fs.qw.mapper.SignRedPacketRecordMapper">
+    
+    <resultMap type="SignRedPacketRecord" id="SignRedPacketRecordResult">
+        <result property="id"    column="id"    />
+        <result property="signUrl"    column="sign_url"    />
+        <result property="userId"    column="user_id"    />
+        <result property="outBatchNo"    column="out_batch_no"    />
+        <result property="result"    column="result"    />
+        <result property="batchId"    column="batch_id"    />
+        <result property="collectTag"    column="collect_tag"    />
+        <result property="amount"    column="amount"    />
+        <result property="sendTime"    column="send_time"    />
+        <result property="collectTime"    column="collect_time"    />
+        <result property="collectType"    column="collect_type"    />
+        <result property="updateTime"    column="update_time"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="userName"    column="user_name"    />
+        <result property="companyUserId"    column="company_user_id"    />
+        <result property="companyId"    column="company_id"    />
+        <result property="companyName"    column="company_name"    />
+        <result property="qwUserId"    column="qw_user_id"    />
+        <result property="qwUserName"    column="qw_user_name"    />
+        <result property="articleId"    column="article_id"    />
+        <result property="signType"    column="sign_type"    />
+    </resultMap>
+
+    <sql id="selectSignRedPacketRecordVo">
+        select id, sign_url, user_id, out_batch_no, result, batch_id, collect_tag, amount, send_time, collect_time, collect_type, update_time, create_time, user_name, company_user_id, company_id, company_name, qw_user_id, qw_user_name,article_id,sign_type from sign_red_packet_record
+    </sql>
+
+    <select id="selectSignRedPacketRecordList" parameterType="SignRedPacketRecord" resultMap="SignRedPacketRecordResult">
+        <include refid="selectSignRedPacketRecordVo"/>
+        <where>  
+            <if test="signUrl != null  and signUrl != ''"> and sign_url = #{signUrl}</if>
+            <if test="userId != null "> and user_id = #{userId}</if>
+            <if test="outBatchNo != null  and outBatchNo != ''"> and out_batch_no = #{outBatchNo}</if>
+            <if test="result != null  and result != ''"> and result = #{result}</if>
+            <if test="batchId != null  and batchId != ''"> and batch_id = #{batchId}</if>
+            <if test="collectTag != null "> and collect_tag = #{collectTag}</if>
+            <if test="amount != null "> and amount = #{amount}</if>
+            <if test="sendTime != null "> and send_time = #{sendTime}</if>
+            <if test="collectTime != null "> and collect_time = #{collectTime}</if>
+            <if test="collectType != null  and collectType != ''"> and collect_type = #{collectType}</if>
+            <if test="userName != null  and userName != ''"> and user_name like concat('%', #{userName}, '%')</if>
+            <if test="companyUserId != null "> and company_user_id = #{companyUserId}</if>
+            <if test="companyId != null "> and company_id = #{companyId}</if>
+            <if test="companyName != null  and companyName != ''"> and company_name like concat('%', #{companyName}, '%')</if>
+            <if test="qwUserId != null  and qwUserId != ''"> and qw_user_id = #{qwUserId}</if>
+            <if test="qwUserName != null  and qwUserName != ''"> and qw_user_name like concat('%', #{qwUserName}, '%')</if>
+        </where>
+    </select>
+    
+    <select id="selectSignRedPacketRecordById" parameterType="Long" resultMap="SignRedPacketRecordResult">
+        <include refid="selectSignRedPacketRecordVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertSignRedPacketRecord" parameterType="SignRedPacketRecord">
+        insert into sign_red_packet_record
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="signUrl != null">sign_url,</if>
+            <if test="userId != null">user_id,</if>
+            <if test="outBatchNo != null">out_batch_no,</if>
+            <if test="result != null">result,</if>
+            <if test="batchId != null">batch_id,</if>
+            <if test="collectTag != null">collect_tag,</if>
+            <if test="amount != null">amount,</if>
+            <if test="sendTime != null">send_time,</if>
+            <if test="collectTime != null">collect_time,</if>
+            <if test="collectType != null">collect_type,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="userName != null">user_name,</if>
+            <if test="companyUserId != null">company_user_id,</if>
+            <if test="companyId != null">company_id,</if>
+            <if test="companyName != null">company_name,</if>
+            <if test="qwUserId != null">qw_user_id,</if>
+            <if test="qwUserName != null">qw_user_name,</if>
+            <if test="articleId != null">article_id,</if>
+            <if test="signType != null">sign_type,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="signUrl != null">#{signUrl},</if>
+            <if test="userId != null">#{userId},</if>
+            <if test="outBatchNo != null">#{outBatchNo},</if>
+            <if test="result != null">#{result},</if>
+            <if test="batchId != null">#{batchId},</if>
+            <if test="collectTag != null">#{collectTag},</if>
+            <if test="amount != null">#{amount},</if>
+            <if test="sendTime != null">#{sendTime},</if>
+            <if test="collectTime != null">#{collectTime},</if>
+            <if test="collectType != null">#{collectType},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="userName != null">#{userName},</if>
+            <if test="companyUserId != null">#{companyUserId},</if>
+            <if test="companyId != null">#{companyId},</if>
+            <if test="companyName != null">#{companyName},</if>
+            <if test="qwUserId != null">#{qwUserId},</if>
+            <if test="qwUserName != null">#{qwUserName},</if>
+            <if test="articleId != null">#{articleId},</if>
+            <if test="signType != null">#{signType},</if>
+         </trim>
+    </insert>
+
+    <update id="updateSignRedPacketRecord" parameterType="SignRedPacketRecord">
+        update sign_red_packet_record
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="signUrl != null">sign_url = #{signUrl},</if>
+            <if test="userId != null">user_id = #{userId},</if>
+            <if test="outBatchNo != null">out_batch_no = #{outBatchNo},</if>
+            <if test="result != null">result = #{result},</if>
+            <if test="batchId != null">batch_id = #{batchId},</if>
+            <if test="collectTag != null">collect_tag = #{collectTag},</if>
+            <if test="amount != null">amount = #{amount},</if>
+            <if test="sendTime != null">send_time = #{sendTime},</if>
+            <if test="collectTime != null">collect_time = #{collectTime},</if>
+            <if test="collectType != null">collect_type = #{collectType},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="userName != null">user_name = #{userName},</if>
+            <if test="companyUserId != null">company_user_id = #{companyUserId},</if>
+            <if test="companyId != null">company_id = #{companyId},</if>
+            <if test="companyName != null">company_name = #{companyName},</if>
+            <if test="qwUserId != null">qw_user_id = #{qwUserId},</if>
+            <if test="qwUserName != null">qw_user_name = #{qwUserName},</if>
+            <if test="articleId != null">article_id = #{articleId},</if>
+            <if test="signtype != null">sign_type = #{signtype},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteSignRedPacketRecordById" parameterType="Long">
+        delete from sign_red_packet_record where id = #{id}
+    </delete>
+
+    <delete id="deleteSignRedPacketRecordByIds" parameterType="String">
+        delete from sign_red_packet_record where id in 
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 19 - 0
fs-user-app/src/main/java/com/fs/app/controller/SignRedPacketController.java

@@ -0,0 +1,19 @@
+package com.fs.app.controller;
+
+import com.fs.qw.service.ISignRedPacketRecordService;
+import io.swagger.annotations.Api;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+@Api("签到红包接口")
+@RestController
+@RequestMapping(value="/app/sign/redPacket")
+public class SignRedPacketController extends AppBaseController {
+
+    @Autowired
+    private ISignRedPacketRecordService signRedPacketRecordService;
+
+
+
+}