|
@@ -11,32 +11,36 @@
|
|
|
<result property="name" column="name" />
|
|
|
<result property="startTime" column="start_time" />
|
|
|
<result property="endTime" column="end_time" />
|
|
|
+ <result property="price" column="price" />
|
|
|
<result property="status" column="status" />
|
|
|
<result property="collectionsNumber" column="collections_number" />
|
|
|
<result property="collectionsStory" column="collections_story" />
|
|
|
<result property="image" column="image" />
|
|
|
<result property="createTime" column="create_time" />
|
|
|
<result property="updateTime" column="update_time" />
|
|
|
- <result property="createUser" column="create_user" />
|
|
|
- <result property="updateUser" column="update_user" />
|
|
|
+ <result property="createBy" column="create_by" />
|
|
|
+ <result property="updateBy" column="update_by" />
|
|
|
<result property="delFlag" column="del_flag" />
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectPostCollectionsVo">
|
|
|
- select id, system_id, issuer_id, name, start_time, end_time, status, collections_number, collections_story, image, create_time, update_time, create_user, update_user, del_flag from post_collections
|
|
|
+ select id, system_id, issuer_id, name, start_time, end_time,price, status, collections_number, collections_story, image, create_time, update_time, create_by, update_by, del_flag from post_collections
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectPostCollectionsList" parameterType="PostCollections" resultMap="PostCollectionsResult">
|
|
|
<include refid="selectPostCollectionsVo"/>
|
|
|
<where>
|
|
|
- <if test="systemId != null "> and system_id = #{id}</if>
|
|
|
+ <if test="systemId != null "> and system_id = #{id}</if><!--条件套系id等于前端传过来的id-->
|
|
|
and del_flag = '0'
|
|
|
</where>
|
|
|
</select>
|
|
|
-
|
|
|
- <select id="selectPostCollectionsById" parameterType="Long" resultMap="PostCollectionsResult">
|
|
|
- <include refid="selectPostCollectionsVo"/>
|
|
|
- where id = #{id} and del_flag = '0'
|
|
|
+ <!--查询藏品详细信息,查发行方名称字段-->
|
|
|
+ <select id="selectPostCollectionsById" parameterType="Long" resultType="PostCollectionsVo">
|
|
|
+ select c.image , c.name , c.price , c.start_time, c.end_time ,c.collections_number,c.collections_story , i.Issuer_name issuerName
|
|
|
+ from post_collections c
|
|
|
+ left join issuer i
|
|
|
+ on c.issuer_id = i.id
|
|
|
+ where c.id = #{id} and c.del_flag = '0'
|
|
|
</select>
|
|
|
|
|
|
<insert id="insertPostCollections" parameterType="PostCollections" useGeneratedKeys="true" keyProperty="id">
|
|
@@ -47,14 +51,15 @@
|
|
|
<if test="name != null">name,</if>
|
|
|
<if test="startTime != null">start_time,</if>
|
|
|
<if test="endTime != null">end_time,</if>
|
|
|
+ <if test="price != null">price,</if>
|
|
|
<if test="status != null">status,</if>
|
|
|
<if test="collectionsNumber != null">collections_number,</if>
|
|
|
<if test="collectionsStory != null">collections_story,</if>
|
|
|
<if test="image != null">image,</if>
|
|
|
<if test="createTime != null">create_time,</if>
|
|
|
<if test="updateTime != null">update_time,</if>
|
|
|
- <if test="createUser != null">create_user,</if>
|
|
|
- <if test="updateUser != null">update_user,</if>
|
|
|
+ <if test="createBy != null">create_by,</if>
|
|
|
+ <if test="updateBy != null">update_by,</if>
|
|
|
<if test="delFlag != null">del_flag,</if>
|
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
@@ -63,14 +68,15 @@
|
|
|
<if test="name != null">#{name},</if>
|
|
|
<if test="startTime != null">#{startTime},</if>
|
|
|
<if test="endTime != null">#{endTime},</if>
|
|
|
+ <if test="price != null">#{price},</if>
|
|
|
<if test="status != null">#{status},</if>
|
|
|
<if test="collectionsNumber != null">#{collectionsNumber},</if>
|
|
|
<if test="collectionsStory != null">#{collectionsStory},</if>
|
|
|
<if test="image != null">#{image},</if>
|
|
|
<if test="createTime != null">#{createTime},</if>
|
|
|
<if test="updateTime != null">#{updateTime},</if>
|
|
|
- <if test="createUser != null">#{createUser},</if>
|
|
|
- <if test="updateUser != null">#{updateUser},</if>
|
|
|
+ <if test="createBy != null">#{createBy},</if>
|
|
|
+ <if test="updateBy != null">#{updateBy},</if>
|
|
|
<if test="delFlag != null">#{delFlag},</if>
|
|
|
</trim>
|
|
|
</insert>
|
|
@@ -83,14 +89,15 @@
|
|
|
<if test="name != null">name = #{name},</if>
|
|
|
<if test="startTime != null">start_time = #{startTime},</if>
|
|
|
<if test="endTime != null">end_time = #{endTime},</if>
|
|
|
+ <if test="price != null">#{price},</if>
|
|
|
<if test="status != null">status = #{status},</if>
|
|
|
<if test="collectionsNumber != null">collections_number = #{collectionsNumber},</if>
|
|
|
<if test="collectionsStory != null">collections_story = #{collectionsStory},</if>
|
|
|
<if test="image != null">image = #{image},</if>
|
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
- <if test="createUser != null">create_user = #{createUser},</if>
|
|
|
- <if test="updateUser != null">update_user = #{updateUser},</if>
|
|
|
+ <if test="createBy != null">create_by = #{createBy},</if>
|
|
|
+ <if test="updateBy != null">update_by = #{updateBy},</if>
|
|
|
<if test="delFlag != null">del_flag = #{delFlag},</if>
|
|
|
</trim>
|
|
|
where id = #{id}
|