商品 可售时间 处理

This commit is contained in:
2024-08-14 11:34:51 +08:00
parent 57472bdf00
commit a4601fac99
5 changed files with 136 additions and 11 deletions

View File

@@ -11,6 +11,9 @@
<result column="detail" jdbcType="VARCHAR" property="detail" />
<result column="style" jdbcType="VARCHAR" property="style" />
<result column="sort" jdbcType="INTEGER" property="sort" />
<result column="use_time" jdbcType="INTEGER" property="useTime" />
<result column="sale_start_time" jdbcType="INTEGER" property="saleStartTime" />
<result column="sale_end_time" jdbcType="INTEGER" property="saleEndTime" />
<result column="created_at" jdbcType="BIGINT" property="createdAt" />
<result column="updated_at" jdbcType="BIGINT" property="updatedAt" />
</resultMap>
@@ -18,7 +21,7 @@
<result column="product_ids" jdbcType="LONGVARCHAR" property="productIds" />
</resultMap>
<sql id="Base_Column_List">
id, name, merchant_id, shop_id, pic, is_show, detail, style, sort, created_at, updated_at
id, name, merchant_id, shop_id, pic, is_show, detail, style, sort, created_at, updated_at , use_time, sale_start_time, sale_end_time
</sql>
<sql id="Blob_Column_List">
product_ids
@@ -234,4 +237,9 @@
</if>
order by sort asc
</select>
<select id="selectByProductId" resultMap="BaseResultMap">
SELECT * FROM tb_product_group WHERE `shop_id` = #{shopId,jdbcType=VARCHAR} AND is_show = 1
AND `product_ids` LIKE concat('%',#{productId,jdbcType=VARCHAR},'%')
</select>
</mapper>