package org.jeecg.modules.system.app.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.jeecg.modules.system.app.dto.FindPageRequestDTO;
import org.jeecg.modules.system.app.dto.FindResponseDTO;
import org.jeecg.modules.system.app.entity.AppFeedback;

/**
 * @Description: 意见反馈
 * @Author: jeecg-boot
 * @Date:   2025-07-07
 * @Version: V1.0
 */
public interface AppFeedbackMapper extends BaseMapper<AppFeedback> {

    IPage<FindResponseDTO> findPage(@Param("page")Page<FindResponseDTO> page, @Param("findPageRequestDTO") FindPageRequestDTO findPageRequestDTO);
    @Select(" select  f.id,f.feedback_type,f.feedback_described,f.feedback_img,f.reply_status,f.reply_content,f.create_time,su.username,su.phone from nm_feedback f left join  sys_user su on f.user_id =su.id " +
            "       where f.del_flag =0 AND f.id = #{id}")
    FindResponseDTO findById(@Param("id") String id);

}
