insert into tb_pluss_notice(userId, userName, typeFirst, typeSecond, conrtent, createDt, noticeCode, orderNumber, isDeal, isApply) VALUES (#{userId}, #{userName}, #{typeFirst}, #{typeSecond}, #{conrtent}, NOW(), #{noticeCode}, #{orderNumber}, #{isDeal}, #{isApply})
insert into tb_pluss_notice(userId,userName,typeFirst,typeSecond,conrtent,createDt,noticeCode,`desc`,title,url,uniqueKey) VALUES (#{item.userId},#{item.userName},#{item.typeFirst},#{item.typeSecond},#{item.conrtent},#{item.createDt},#{item.noticeCode},#{item.desc},#{item.title},#{item.url},#{item.uniqueKey})
SELECT * from tb_pluss_notice and id = #{id} and userId = #{userId} and userName = #{userName} and typeFirst = #{typeFirst} and typeSecond = #{typeSecond} and conrtent = #{conrtent} and createDt = #{createDt} and noticeCode = #{noticeCode} and orderNumber = #{orderNumber} and isDeal = #{isDeal} and isApply = #{isApply}
SELECT * from tb_pluss_notice and id = #{id} and userId = #{userId} and userName = #{userName} and typeFirst = #{typeFirst} and typeSecond = #{typeSecond} and conrtent = #{conrtent} and createDt = #{createDt} and noticeCode = #{noticeCode} and orderNumber = #{orderNumber} and isDeal = #{isDeal} and isApply = #{isApply}
update tb_pluss_notice userId = #{userId}, userName = #{userName}, typeFirst = #{typeFirst}, typeSecond = #{typeSecond}, conrtent = #{conrtent}, createDt = #{createDt}, noticeCode = #{noticeCode}, orderNumber = #{orderNumber}, isDeal = #{isDeal}, isApply = #{isApply} where id=#{id}
DELETE FROM tb_pluss_notice where id = #{id}
SELECT n.id FROM tb_pluss_notice n and n.id = #{id} and n.userId IN ('-1', #{userId}) and userName like CONCAT("%",#{userName},"%") and typeFirst = #{typeFirst} and typeSecond = #{typeSecond} and conrtent = #{conrtent} and createDt = #{createDt} and noticeCode = #{noticeCode} and orderNumber = #{orderNumber} and isDeal = #{isDeal} and isApply = #{isApply} order by n.id desc limit #{pageSize} offset #{offset}
SELECT n.id, n.userId, n.userName, n.typeFirst, n.typeSecond, n.title, n.`desc`, n.url, n.conrtent, n.createDt, n.noticeCode, n.orderNumber, n.isDeal, n.isApply, n.uniqueKey, IF ( nrr.id IS NULL, 0, 1 ) readStatus FROM tb_pluss_notice n LEFT JOIN tb_pluss_notice_read_record nrr ON n.id = nrr.noticeId AND nrr.type='2' AND nrr.userId = #{userId} and n.id = #{id} and n.userId IN ('-1', #{userId}) and userName like CONCAT("%",#{userName},"%") and typeFirst = #{typeFirst} and typeSecond = #{typeSecond} and conrtent = #{conrtent} and createDt = #{createDt} and noticeCode = #{noticeCode} and orderNumber = #{orderNumber} and isDeal = #{isDeal} and isApply = #{isApply} order by n.id desc limit #{pageSize} offset #{offset}
SELECT count(*) from tb_pluss_notice and id = #{id} and userId = #{userId} and userName like CONCAT("%",#{userName},"%") and typeFirst = #{typeFirst} and typeSecond = #{typeSecond} and conrtent = #{conrtent} and createDt = #{createDt} and noticeCode = #{noticeCode} and isDeal = #{isDeal} and isApply = #{isApply}