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

import com.yeejoin.amos.boot.module.jg.api.entity.JgUseRegistrationEq;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;

/**
 * 使用登记设备关系表 Mapper 接口
 *
 * @author system_generator
 * @date 2023-12-18
 */
public interface JgUseRegistrationEqMapper extends BaseMapper<JgUseRegistrationEq> {
    @Update("update tzs_jg_use_registration_eq set  is_invalid = 1 where equ_id = #{equipId} and equip_transfer_id != #{currentDocumentId} ")
    void updateEquipIsVaildByEquipIdAndCurrentDocumentId(@Param("equipId") String equipId, @Param("currentDocumentId") String currentDocumentId);
}
