|
@@ -23,19 +23,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectNoticeDemandVo">
|
|
|
- select id, member_id, purchase_title, summary_of_needs, demand_details, contacts, contact_number, release_time, status, create_by, create_time, update_by, update_time, del_flag, remark from notice_demand
|
|
|
+ select id, member_id, purchase_title,purchase_title_en, summary_of_needs,summary_of_needs_en, demand_details,demand_details_en, contacts,contacts_en, contact_number,contact_number_en, release_time,release_time_en, status, create_by, create_time, update_by, update_time, del_flag, remark from notice_demand
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectNoticeDemandList" parameterType="NoticeDemand" resultMap="NoticeDemandResult">
|
|
|
<include refid="selectNoticeDemandVo"/>
|
|
|
<where>
|
|
|
<if test="memberId != null "> and member_id = #{memberId}</if>
|
|
|
- <if test="purchaseTitle != null and purchaseTitle != ''"> and purchase_title = #{purchaseTitle}</if>
|
|
|
- <if test="summaryOfNeeds != null and summaryOfNeeds != ''"> and summary_of_needs = #{summaryOfNeeds}</if>
|
|
|
- <if test="demandDetails != null and demandDetails != ''"> and demand_details = #{demandDetails}</if>
|
|
|
- <if test="contacts != null and contacts != ''"> and contacts = #{contacts}</if>
|
|
|
- <if test="contactNumber != null and contactNumber != ''"> and contact_number = #{contactNumber}</if>
|
|
|
- <if test="releaseTime != null "> and release_time = #{releaseTime}</if>
|
|
|
+ <if test="purchaseTitle != null and purchaseTitle != ''"> and purchase_title = #{purchaseTitle} or purchase_title_en = #{purchaseTitle}</if>
|
|
|
+ <if test="summaryOfNeeds != null and summaryOfNeeds != ''"> and summary_of_needs = #{summaryOfNeeds} or summary_of_needs_en = #{summaryOfNeeds}</if>
|
|
|
+ <if test="demandDetails != null and demandDetails != ''"> and demand_details = #{demandDetails} or demand_details_en = #{demandDetails}</if>
|
|
|
+ <if test="contacts != null and contacts != ''"> and contacts = #{contacts} or contacts_en = #{contacts}</if>
|
|
|
+ <if test="contactNumber != null and contactNumber != ''"> and contact_number = #{contactNumber} or contact_number_en = #{contactNumber}</if>
|
|
|
+ <if test="releaseTime != null "> and release_time = #{releaseTime} or release_time_en = #{releaseTime}</if>
|
|
|
<if test="status != null and status != ''"> and status = #{status}</if>
|
|
|
</where>
|
|
|
</select>
|
|
@@ -50,11 +50,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
<if test="memberId != null ">member_id,</if>
|
|
|
<if test="purchaseTitle != null and purchaseTitle != ''">purchase_title,</if>
|
|
|
+ <if test="purchaseTitleEn != null and purchaseTitleEn != ''">purchase_title_en,</if>
|
|
|
<if test="summaryOfNeeds != null and summaryOfNeeds != ''">summary_of_needs,</if>
|
|
|
+ <if test="summaryOfNeedsEn != null and summaryOfNeedsEn != ''">summary_of_needs_en,</if>
|
|
|
<if test="demandDetails != null and demandDetails != ''">demand_details,</if>
|
|
|
+ <if test="demandDetailsEn != null and demandDetailsEn != ''">demand_details_en,</if>
|
|
|
<if test="contacts != null and contacts != ''">contacts,</if>
|
|
|
+ <if test="contactsEn != null and contactsEn != ''">contacts_en,</if>
|
|
|
<if test="contactNumber != null and contactNumber != ''">contact_number,</if>
|
|
|
+ <if test="contactNumberEn != null and contactNumberEn != ''">contact_number_en,</if>
|
|
|
<if test="releaseTime != null ">release_time,</if>
|
|
|
+ <if test="releaseTimeEn != null ">release_time_en,</if>
|
|
|
<if test="status != null and status != ''">status,</if>
|
|
|
<if test="createBy != null and createBy != ''">create_by,</if>
|
|
|
<if test="createTime != null ">create_time,</if>
|
|
@@ -66,11 +72,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="memberId != null ">#{memberId},</if>
|
|
|
<if test="purchaseTitle != null and purchaseTitle != ''">#{purchaseTitle},</if>
|
|
|
+ <if test="purchaseTitleEn != null and purchaseTitleEn != ''">#{purchaseTitleEn},</if>
|
|
|
<if test="summaryOfNeeds != null and summaryOfNeeds != ''">#{summaryOfNeeds},</if>
|
|
|
+ <if test="summaryOfNeedsEn != null and summaryOfNeedsEn != ''">#{summaryOfNeedsEn},</if>
|
|
|
<if test="demandDetails != null and demandDetails != ''">#{demandDetails},</if>
|
|
|
+ <if test="demandDetailsEn != null and demandDetailsEn != ''">#{demandDetailsEn},</if>
|
|
|
<if test="contacts != null and contacts != ''">#{contacts},</if>
|
|
|
+ <if test="contactsEn != null and contactsEn != ''">#{contactsEn},</if>
|
|
|
<if test="contactNumber != null and contactNumber != ''">#{contactNumber},</if>
|
|
|
+ <if test="contactNumberEn != null and contactNumberEn != ''">#{contactNumberEn},</if>
|
|
|
<if test="releaseTime != null ">#{releaseTime},</if>
|
|
|
+ <if test="releaseTimeEn != null ">#{releaseTimeEn},</if>
|
|
|
<if test="status != null and status != ''">#{status},</if>
|
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
|
|
<if test="createTime != null ">#{createTime},</if>
|
|
@@ -86,11 +98,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
<if test="memberId != null ">member_id = #{memberId},</if>
|
|
|
<if test="purchaseTitle != null and purchaseTitle != ''">purchase_title = #{purchaseTitle},</if>
|
|
|
+ <if test="purchaseTitleEn != null and purchaseTitleEn != ''">purchase_title_en = #{purchaseTitleEn},</if>
|
|
|
<if test="summaryOfNeeds != null and summaryOfNeeds != ''">summary_of_needs = #{summaryOfNeeds},</if>
|
|
|
+ <if test="summaryOfNeedsEn != null and summaryOfNeedsEn != ''">summary_of_needs_en = #{summaryOfNeedsEn},</if>
|
|
|
<if test="demandDetails != null and demandDetails != ''">demand_details = #{demandDetails},</if>
|
|
|
+ <if test="demandDetailsEn != null and demandDetailsEn != ''">demand_details_en = #{demandDetailsEn},</if>
|
|
|
<if test="contacts != null and contacts != ''">contacts = #{contacts},</if>
|
|
|
+ <if test="contactsEn != null and contactsEn != ''">contacts_en = #{contactsEn},</if>
|
|
|
<if test="contactNumber != null and contactNumber != ''">contact_number = #{contactNumber},</if>
|
|
|
+ <if test="contactNumberEn != null and contactNumberEn != ''">contact_number_en = #{contactNumberEn},</if>
|
|
|
<if test="releaseTime != null ">release_time = #{releaseTime},</if>
|
|
|
+ <if test="releaseTimeEn != null ">release_time_en = #{releaseTimeEn},</if>
|
|
|
<if test="status != null and status != ''">status = #{status},</if>
|
|
|
<if test="createBy != null and createBy != ''">create_by = #{createBy},</if>
|
|
|
<if test="createTime != null ">create_time = #{createTime},</if>
|
|
@@ -115,7 +133,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
|
|
|
<select id="getDemandInfoTenList" resultMap="NoticeDemandResult">
|
|
|
- select id, member_id, purchase_title,release_time from notice_demand
|
|
|
+ select id, member_id, purchase_title,purchase_title_en,release_time,release_time_en from notice_demand
|
|
|
order by release_time desc limit 0,6
|
|
|
|
|
|
</select>
|