
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
<?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.takensoft.common.file.dao.FileDAO">
<!-- 파일 resultMap -->
<resultMap id="fileMap" type="HashMap">
<result property="fileId" column="file_id" />
<result property="fileMngId" column="file_mng_id" />
<result property="fileNm" column="file_nm" />
<result property="maskNm" column="mask_nm" />
<result property="fileType" column="file_type" />
<result property="absltPath" column="abslt_path" />
<result property="rltPath" column="rlt_path" />
<result property="extnNm" column="extn_nm" />
<result property="fileSz" column="file_sz" />
<result property="rgtr" column="rgtr" />
<result property="regDt" column="reg_dt" />
</resultMap>
<!--
작 성 자 : 박정하
작 성 일 : 2024.03.26
내 용 : 파일 등록
-->
<insert id="fileInsert" parameterType="HashMap">
INSERT INTO com_file (
file_mng_id
, file_nm
, mask_nm
, file_type
, abslt_path
, rlt_path
, extn_nm
, file_sz
, rgtr
, reg_dt
) VALUES (
#{fileMngId}
, #{fileNm}
, #{maskNm}
, #{fileType}
, #{absltPath}
, #{rltPath}
, #{extnNm}
, #{fileSz}
, #{rgtr}
, now()
)
</insert>
<!--
작 성 자 : 박정하
작 성 일 : 2024.03.26
내 용 : 파일 목록 조회
-->
<select id="fileSelectList" parameterType="String" resultMap="fileMap">
SELECT file_id
, file_mng_id
, file_nm
, mask_nm
, file_type
, abslt_path
, rlt_path
, extn_nm
, file_sz
, rgtr
, reg_dt
FROM com_file
WHERE file_mng_id = #{fileMngId}
ORDER BY file_id ASC
</select>
<!--
작 성 자 : 박정하
작 성 일 : 2024.03.27
내 용 : 파일 삭제
-->
<delete id="fileDelete" parameterType="HashMap">
DELETE
FROM com_file
WHERE file_id = #{fileId}
</delete>
<!--
작 성 자 : 방선주
작 성 일 : 2024.05.21
내 용 : 파일 단일 조회
-->
<select id="fileSelectOne" parameterType="Integer" resultType="FileVO">
SELECT file_id
, file_mng_id
, file_nm
, mask_nm
, file_type
, abslt_path
, rlt_path
, extn_nm
, file_sz
, rgtr
, reg_dt
FROM com_file
WHERE file_id = #{fileId}
</select>
</mapper>