|
|
@@ -18,10 +18,12 @@
|
|
|
<result property="channelIndicators" column="channel_indicators" jdbcType="VARCHAR"/>
|
|
|
<result property="interviewDistribution" column="interview_distribution" jdbcType="VARCHAR"/>
|
|
|
<result property="updateTime" column="update_time" jdbcType="TIMESTAMP"/>
|
|
|
+ <result property="awardsTime" column="awards_time" jdbcType="TIMESTAMP"/>
|
|
|
+ <result property="awardsStatus" column="awards_status" jdbcType="INTEGER"/>
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="UserArchivesAllSql">
|
|
|
- id, uid, patent_count, invention_patent_count, utility_model_count, appearance_patent_count, software_works_count, other_count, financial_data, early_communication, interview_ideas, create_time, enterprise_count, channel_indicators, interview_distribution, update_time
|
|
|
+ id, uid, patent_count, invention_patent_count, utility_model_count, appearance_patent_count, software_works_count, other_count, financial_data, early_communication, interview_ideas, create_time, enterprise_count, channel_indicators, interview_distribution, update_time, awards_time, awards_status
|
|
|
</sql>
|
|
|
|
|
|
<!--查询单个-->
|
|
|
@@ -87,6 +89,12 @@
|
|
|
<if test="updateTime != null">
|
|
|
and update_time = #{updateTime}
|
|
|
</if>
|
|
|
+ <if test="awardsTime != null">
|
|
|
+ and awards_time = #{awardsTime}
|
|
|
+ </if>
|
|
|
+ <if test="awardsStatus != null">
|
|
|
+ and awards_status = #{awardsStatus}
|
|
|
+ </if>
|
|
|
</where>
|
|
|
<if test="page_sql != null">
|
|
|
${page_sql}
|
|
|
@@ -146,6 +154,12 @@
|
|
|
<if test="updateTime != null">
|
|
|
and update_time = #{updateTime}
|
|
|
</if>
|
|
|
+ <if test="awardsTime != null">
|
|
|
+ and awards_time = #{awardsTime}
|
|
|
+ </if>
|
|
|
+ <if test="awardsStatus != null">
|
|
|
+ and awards_status = #{awardsStatus}
|
|
|
+ </if>
|
|
|
</where>
|
|
|
</select>
|
|
|
|
|
|
@@ -154,37 +168,40 @@
|
|
|
insert into user_archives(uid, patent_count, invention_patent_count, utility_model_count,
|
|
|
appearance_patent_count, software_works_count, other_count, financial_data,
|
|
|
early_communication, interview_ideas, create_time, enterprise_count,
|
|
|
- channel_indicators, interview_distribution, update_time)
|
|
|
+ channel_indicators, interview_distribution, update_time, awards_time, awards_status)
|
|
|
values (#{uid}, #{patentCount}, #{inventionPatentCount}, #{utilityModelCount}, #{appearancePatentCount},
|
|
|
#{softwareWorksCount}, #{otherCount}, #{financialData}, #{earlyCommunication}, #{interviewIdeas},
|
|
|
- #{createTime}, #{enterpriseCount}, #{channelIndicators}, #{interviewDistribution}, #{updateTime})
|
|
|
+ #{createTime}, #{enterpriseCount}, #{channelIndicators}, #{interviewDistribution}, #{updateTime},
|
|
|
+ #{awardsTime}, #{awardsStatus})
|
|
|
</insert>
|
|
|
|
|
|
<insert id="insertBatch">
|
|
|
insert into user_archives(uid, patent_count, invention_patent_count, utility_model_count,
|
|
|
appearance_patent_count, software_works_count, other_count, financial_data, early_communication,
|
|
|
- interview_ideas, create_time, enterprise_count, channel_indicators, interview_distribution, update_time)
|
|
|
+ interview_ideas, create_time, enterprise_count, channel_indicators, interview_distribution, update_time,
|
|
|
+ awards_time, awards_status)
|
|
|
values
|
|
|
<foreach collection="entities" item="entity" separator=",">
|
|
|
(#{entity.uid}, #{entity.patentCount}, #{entity.inventionPatentCount}, #{entity.utilityModelCount},
|
|
|
#{entity.appearancePatentCount}, #{entity.softwareWorksCount}, #{entity.otherCount},
|
|
|
#{entity.financialData}, #{entity.earlyCommunication}, #{entity.interviewIdeas}, #{entity.createTime},
|
|
|
#{entity.enterpriseCount}, #{entity.channelIndicators}, #{entity.interviewDistribution},
|
|
|
- #{entity.updateTime})
|
|
|
+ #{entity.updateTime}, #{entity.awardsTime}, #{entity.awardsStatus})
|
|
|
</foreach>
|
|
|
</insert>
|
|
|
|
|
|
<insert id="insertOrUpdateBatch" keyProperty="id" useGeneratedKeys="true">
|
|
|
insert into user_archives(uid, patent_count, invention_patent_count, utility_model_count,
|
|
|
appearance_patent_count, software_works_count, other_count, financial_data, early_communication,
|
|
|
- interview_ideas, create_time, enterprise_count, channel_indicators, interview_distribution, update_time)
|
|
|
+ interview_ideas, create_time, enterprise_count, channel_indicators, interview_distribution, update_time,
|
|
|
+ awards_time, awards_status)
|
|
|
values
|
|
|
<foreach collection="entities" item="entity" separator=",">
|
|
|
(#{entity.uid}, #{entity.patentCount}, #{entity.inventionPatentCount}, #{entity.utilityModelCount},
|
|
|
#{entity.appearancePatentCount}, #{entity.softwareWorksCount}, #{entity.otherCount},
|
|
|
#{entity.financialData}, #{entity.earlyCommunication}, #{entity.interviewIdeas}, #{entity.createTime},
|
|
|
#{entity.enterpriseCount}, #{entity.channelIndicators}, #{entity.interviewDistribution},
|
|
|
- #{entity.updateTime})
|
|
|
+ #{entity.updateTime}, #{entity.awardsTime}, #{entity.awardsStatus})
|
|
|
</foreach>
|
|
|
on duplicate key update
|
|
|
uid = values(uid),
|
|
|
@@ -201,7 +218,9 @@
|
|
|
enterprise_count = values(enterprise_count),
|
|
|
channel_indicators = values(channel_indicators),
|
|
|
interview_distribution = values(interview_distribution),
|
|
|
- update_time = values(update_time)
|
|
|
+ update_time = values(update_time),
|
|
|
+ awards_time = values(awards_time),
|
|
|
+ awards_status = values(awards_status)
|
|
|
</insert>
|
|
|
|
|
|
<!--通过主键修改数据-->
|
|
|
@@ -253,6 +272,12 @@
|
|
|
<if test="updateTime != null">
|
|
|
update_time = #{updateTime},
|
|
|
</if>
|
|
|
+ <if test="awardsTime != null">
|
|
|
+ awards_time = #{awardsTime},
|
|
|
+ </if>
|
|
|
+ <if test="awardsStatus != null">
|
|
|
+ awards_status = #{awardsStatus},
|
|
|
+ </if>
|
|
|
</set>
|
|
|
where id = #{id}
|
|
|
</update>
|