package thyyxxk.webserver.dao.his.technologyArchives;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import thyyxxk.webserver.entity.technologyArchives.TechnologyArchives2;

import java.util.Map;

@Mapper
public interface TechnologyArchives2Dao extends BaseMapper<TechnologyArchives2> {

    @Select(" select * from technology_archives2 where social_no = #{socialNo} and no = #{no} ")
    TechnologyArchives2 selectTechnologyArchives2ByNo(@Param("socialNo") String socialNo, @Param("no") Integer no);

    @Update(" delete from technology_archives2 where social_no = #{socialNo} and no = #{no} ")
    int delTechnologyArchives2ByCode(@Param("socialNo") String socialNo, @Param("no") Integer no);

    @Update(" update technology_archives2 set image = #{url} where social_no = #{socialNo} and no = #{no} ")
    int updateProImage(String url,@Param("socialNo") String socialNo,@Param("no") Integer no);

    @Select(" select image  from  technology_archives2 where social_no = #{socialNo} and no = #{no}")
    Map<String, Object> selectImage(@Param("socialNo") String socialNo, @Param("no") Integer no);

}
