package com.yeejoin.amos.boot.module.hygf.api.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yeejoin.amos.boot.module.hygf.api.dto.HYGFMaintenanceTicketsDto;
import com.yeejoin.amos.boot.module.hygf.api.entity.HYGFMaintenanceTickets;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

public interface HYGFMaintenanceTicketsMapper extends BaseMapper<HYGFMaintenanceTickets> {
    @Select("SELECT sn_code FROM hygf_jp_inverter WHERE third_station_id = #{stationId}")
    List<String> queryInverterSncodesByStationId(String stationId);
    @Update("update hygf_maintenance_tickets SET score = #{score} WHERE sequence_nbr = #{sequenceNbr}")
    void updateScoreBySequenceNbr(String score,Long sequenceNbr);
    List<HYGFMaintenanceTicketsDto> qureyListByQueryparams(@Param("dto") HYGFMaintenanceTicketsDto dto ,@Param("amosUserId")String amosUserId);

    List<HYGFMaintenanceTicketsDto> queryForPageList(@Param("dto") HYGFMaintenanceTicketsDto dto ,@Param("amosUserId")String amosUserId);
}
