You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
304 lines
12 KiB
304 lines
12 KiB
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
|
<mapper namespace="cc.hiver.mall.dao.mapper.ShopAreaMapper" >
|
|
<resultMap id="BaseResultMap" type="cc.hiver.mall.entity.ShopArea" >
|
|
<id column="id" property="id" jdbcType="VARCHAR" />
|
|
<result column="create_by" property="createBy" jdbcType="VARCHAR" />
|
|
<result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
|
|
<result column="del_flag" property="delFlag" jdbcType="INTEGER" />
|
|
<result column="update_by" property="updateBy" jdbcType="VARCHAR" />
|
|
<result column="update_time" property="updateTime" jdbcType="TIMESTAMP" />
|
|
<result column="is_parent" property="isParent" jdbcType="BIT" />
|
|
<result column="parent_id" property="parentId" jdbcType="VARCHAR" />
|
|
<result column="sort_order" property="sortOrder" jdbcType="DECIMAL" />
|
|
<result column="status" property="status" jdbcType="INTEGER" />
|
|
<result column="title" property="title" jdbcType="VARCHAR" />
|
|
<result column="is_canteen" property="isCanteen" jdbcType="INTEGER" />
|
|
<result column="delivery_enabled" property="deliveryEnabled" jdbcType="INTEGER" />
|
|
<result column="parent_agent_id" property="parentAgentId" jdbcType="VARCHAR" />
|
|
<result column="parent_agent_name" property="parentAgentName" jdbcType="VARCHAR" />
|
|
<result column="commission_ratio" property="commissionRatio" jdbcType="INTEGER" />
|
|
<result column="center_lng" property="centerLng" jdbcType="DECIMAL" />
|
|
<result column="center_lat" property="centerLat" jdbcType="DECIMAL" />
|
|
<result column="radius_meters" property="radiusMeters" jdbcType="INTEGER" />
|
|
<result column="geo_polygon" property="geoPolygon" jdbcType="LONGVARCHAR" />
|
|
<result column="area_kind" property="areaKind" jdbcType="INTEGER" />
|
|
<result column="express_errand_enabled" property="expressErrandEnabled" jdbcType="INTEGER" />
|
|
<result column="errand_planet_visible" property="errandPlanetVisible" jdbcType="INTEGER" />
|
|
</resultMap>
|
|
<sql id="Base_Column_List" >
|
|
id, create_by, create_time, del_flag, update_by, update_time, is_parent, parent_id,
|
|
sort_order, status, title, is_canteen, delivery_enabled, parent_agent_id, parent_agent_name,
|
|
commission_ratio, center_lng, center_lat, radius_meters, geo_polygon, area_kind, express_errand_enabled,
|
|
errand_planet_visible
|
|
</sql>
|
|
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
|
|
select
|
|
<include refid="Base_Column_List" />
|
|
from t_shop_area
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
</select>
|
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
|
|
delete from t_shop_area
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
</delete>
|
|
<insert id="insert" parameterType="cc.hiver.mall.entity.ShopArea" >
|
|
insert into t_shop_area (id, create_by, create_time,
|
|
del_flag, update_by, update_time,
|
|
is_parent, parent_id, sort_order,
|
|
status, title, is_canteen, delivery_enabled, parent_agent_id, parent_agent_name,
|
|
commission_ratio, center_lng, center_lat, radius_meters, geo_polygon, area_kind, express_errand_enabled,
|
|
errand_planet_visible)
|
|
values (#{id,jdbcType=VARCHAR}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
|
|
#{delFlag,jdbcType=INTEGER}, #{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP},
|
|
#{isParent,jdbcType=BIT}, #{parentId,jdbcType=VARCHAR}, #{sortOrder,jdbcType=DECIMAL},
|
|
#{status,jdbcType=INTEGER}, #{title,jdbcType=VARCHAR}, #{isCanteen,jdbcType=INTEGER}, #{deliveryEnabled,jdbcType=INTEGER},
|
|
#{parentAgentId,jdbcType=VARCHAR}, #{parentAgentName,jdbcType=VARCHAR}, #{commissionRatio,jdbcType=INTEGER},
|
|
#{centerLng,jdbcType=DECIMAL}, #{centerLat,jdbcType=DECIMAL}, #{radiusMeters,jdbcType=INTEGER},
|
|
#{geoPolygon,jdbcType=LONGVARCHAR}, #{areaKind,jdbcType=INTEGER}, #{expressErrandEnabled,jdbcType=INTEGER},
|
|
#{errandPlanetVisible,jdbcType=INTEGER})
|
|
</insert>
|
|
<insert id="insertSelective" parameterType="cc.hiver.mall.entity.ShopArea" >
|
|
insert into t_shop_area
|
|
<trim prefix="(" suffix=")" suffixOverrides="," >
|
|
<if test="id != null" >
|
|
id,
|
|
</if>
|
|
<if test="createBy != null" >
|
|
create_by,
|
|
</if>
|
|
<if test="createTime != null" >
|
|
create_time,
|
|
</if>
|
|
<if test="delFlag != null" >
|
|
del_flag,
|
|
</if>
|
|
<if test="updateBy != null" >
|
|
update_by,
|
|
</if>
|
|
<if test="updateTime != null" >
|
|
update_time,
|
|
</if>
|
|
<if test="isParent != null" >
|
|
is_parent,
|
|
</if>
|
|
<if test="parentId != null" >
|
|
parent_id,
|
|
</if>
|
|
<if test="sortOrder != null" >
|
|
sort_order,
|
|
</if>
|
|
<if test="status != null" >
|
|
status,
|
|
</if>
|
|
<if test="title != null" >
|
|
title,
|
|
</if>
|
|
<if test="isCanteen != null" >
|
|
is_canteen,
|
|
</if>
|
|
<if test="deliveryEnabled != null" >
|
|
delivery_enabled,
|
|
</if>
|
|
<if test="parentAgentId != null" >
|
|
parent_agent_id,
|
|
</if>
|
|
<if test="parentAgentName != null" >
|
|
parent_agent_name,
|
|
</if>
|
|
<if test="commissionRatio != null" >
|
|
commission_ratio,
|
|
</if>
|
|
<if test="centerLng != null" >
|
|
center_lng,
|
|
</if>
|
|
<if test="centerLat != null" >
|
|
center_lat,
|
|
</if>
|
|
<if test="radiusMeters != null" >
|
|
radius_meters,
|
|
</if>
|
|
<if test="geoPolygon != null" >
|
|
geo_polygon,
|
|
</if>
|
|
<if test="areaKind != null" >
|
|
area_kind,
|
|
</if>
|
|
<if test="expressErrandEnabled != null" >
|
|
express_errand_enabled,
|
|
</if>
|
|
<if test="errandPlanetVisible != null" >
|
|
errand_planet_visible,
|
|
</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides="," >
|
|
<if test="id != null" >
|
|
#{id,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createBy != null" >
|
|
#{createBy,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createTime != null" >
|
|
#{createTime,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="delFlag != null" >
|
|
#{delFlag,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="updateBy != null" >
|
|
#{updateBy,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="updateTime != null" >
|
|
#{updateTime,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="isParent != null" >
|
|
#{isParent,jdbcType=BIT},
|
|
</if>
|
|
<if test="parentId != null" >
|
|
#{parentId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="sortOrder != null" >
|
|
#{sortOrder,jdbcType=DECIMAL},
|
|
</if>
|
|
<if test="status != null" >
|
|
#{status,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="title != null" >
|
|
#{title,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="isCanteen != null" >
|
|
#{isCanteen,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="deliveryEnabled != null" >
|
|
#{deliveryEnabled,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="parentAgentId != null" >
|
|
#{parentAgentId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="parentAgentName != null" >
|
|
#{parentAgentName,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="commissionRatio != null" >
|
|
#{commissionRatio,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="centerLng != null" >
|
|
#{centerLng,jdbcType=DECIMAL},
|
|
</if>
|
|
<if test="centerLat != null" >
|
|
#{centerLat,jdbcType=DECIMAL},
|
|
</if>
|
|
<if test="radiusMeters != null" >
|
|
#{radiusMeters,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="geoPolygon != null" >
|
|
#{geoPolygon,jdbcType=LONGVARCHAR},
|
|
</if>
|
|
<if test="areaKind != null" >
|
|
#{areaKind,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="expressErrandEnabled != null" >
|
|
#{expressErrandEnabled,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="errandPlanetVisible != null" >
|
|
#{errandPlanetVisible,jdbcType=INTEGER},
|
|
</if>
|
|
</trim>
|
|
</insert>
|
|
<update id="updateByPrimaryKeySelective" parameterType="cc.hiver.mall.entity.ShopArea" >
|
|
update t_shop_area
|
|
<set >
|
|
<if test="createBy != null" >
|
|
create_by = #{createBy,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createTime != null" >
|
|
create_time = #{createTime,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="delFlag != null" >
|
|
del_flag = #{delFlag,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="updateBy != null" >
|
|
update_by = #{updateBy,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="updateTime != null" >
|
|
update_time = #{updateTime,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="isParent != null" >
|
|
is_parent = #{isParent,jdbcType=BIT},
|
|
</if>
|
|
<if test="parentId != null" >
|
|
parent_id = #{parentId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="sortOrder != null" >
|
|
sort_order = #{sortOrder,jdbcType=DECIMAL},
|
|
</if>
|
|
<if test="status != null" >
|
|
status = #{status,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="title != null" >
|
|
title = #{title,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="isCanteen != null" >
|
|
is_canteen = #{isCanteen,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="deliveryEnabled != null" >
|
|
delivery_enabled = #{deliveryEnabled,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="parentAgentId != null" >
|
|
parent_agent_id = #{parentAgentId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="parentAgentName != null" >
|
|
parent_agent_name = #{parentAgentName,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="commissionRatio != null" >
|
|
commission_ratio = #{commissionRatio,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="centerLng != null" >
|
|
center_lng = #{centerLng,jdbcType=DECIMAL},
|
|
</if>
|
|
<if test="centerLat != null" >
|
|
center_lat = #{centerLat,jdbcType=DECIMAL},
|
|
</if>
|
|
<if test="radiusMeters != null" >
|
|
radius_meters = #{radiusMeters,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="geoPolygon != null" >
|
|
geo_polygon = #{geoPolygon,jdbcType=LONGVARCHAR},
|
|
</if>
|
|
<if test="areaKind != null" >
|
|
area_kind = #{areaKind,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="expressErrandEnabled != null" >
|
|
express_errand_enabled = #{expressErrandEnabled,jdbcType=INTEGER},
|
|
</if>
|
|
<if test="errandPlanetVisible != null" >
|
|
errand_planet_visible = #{errandPlanetVisible,jdbcType=INTEGER},
|
|
</if>
|
|
</set>
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
</update>
|
|
<update id="updateByPrimaryKey" parameterType="cc.hiver.mall.entity.ShopArea" >
|
|
update t_shop_area
|
|
set create_by = #{createBy,jdbcType=VARCHAR},
|
|
create_time = #{createTime,jdbcType=TIMESTAMP},
|
|
del_flag = #{delFlag,jdbcType=INTEGER},
|
|
update_by = #{updateBy,jdbcType=VARCHAR},
|
|
update_time = #{updateTime,jdbcType=TIMESTAMP},
|
|
is_parent = #{isParent,jdbcType=BIT},
|
|
parent_id = #{parentId,jdbcType=VARCHAR},
|
|
sort_order = #{sortOrder,jdbcType=DECIMAL},
|
|
status = #{status,jdbcType=INTEGER},
|
|
title = #{title,jdbcType=VARCHAR},
|
|
is_canteen = #{isCanteen,jdbcType=VARCHAR},
|
|
delivery_enabled = #{deliveryEnabled,jdbcType=INTEGER},
|
|
parent_agent_id = #{parentAgentId,jdbcType=VARCHAR},
|
|
parent_agent_name = #{parentAgentName,jdbcType=VARCHAR},
|
|
commission_ratio = #{commissionRatio,jdbcType=INTEGER},
|
|
center_lng = #{centerLng,jdbcType=DECIMAL},
|
|
center_lat = #{centerLat,jdbcType=DECIMAL},
|
|
radius_meters = #{radiusMeters,jdbcType=INTEGER},
|
|
geo_polygon = #{geoPolygon,jdbcType=LONGVARCHAR},
|
|
area_kind = #{areaKind,jdbcType=INTEGER},
|
|
express_errand_enabled = #{expressErrandEnabled,jdbcType=INTEGER},
|
|
errand_planet_visible = #{errandPlanetVisible,jdbcType=INTEGER}
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
</update>
|
|
</mapper>
|