id ,
id as regionId,
name ,
parent_id as parentId,
group_id as groupId,
store_id as storeId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
syn_ding_dept_id as synDingDeptId,
region_type as regionType,
region_path as regionPath,
deleted as deleted,
third_dept_id as thirdDeptId,
third_region_type as thirdRegionType
select
id ,
id as regionId,
name
from region_${enterpriseId} where id in
#{regionId, jdbcType=BIGINT}
select
id ,
id as regionId,
name as name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
syn_ding_dept_id as synDingDeptId,
region_type as regionType,
region_path as regionPath,
store_num as storeCount
from region_${enterpriseId} where id = #{regionId, jdbcType=BIGINT} and deleted = 0
select
id ,
id as regionId,
name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
syn_ding_dept_id as synDingDeptId,
update_time as updateTime,
update_name as updateName,
region_path as regionPath,
store_num as storeNum,
store_id as storeId,
region_type as regionType,
is_external_node as isExternalNode,
third_dept_id as thirdDeptId,
third_region_type as thirdRegionType
from region_${enterpriseId} where id in
#{regionId, jdbcType=BIGINT}
and deleted = 0
select
id ,
id as regionId,
name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
store_id as storeId,
order_num as orderNum,
deleted as deleted,
region_path as regionPath
from region_${enterpriseId}
where id in (
#{item}
)
select
id ,
id as regionId,
name as name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
syn_ding_dept_id as synDingDeptId,
store_id as storeId,
region_type as regionType,
region_path as regionPath,
deleted,
store_num as storeNum,
third_region_type as thirdRegionType
from region_${enterpriseId}
where id = #{regionId}
select
id ,
region_id as regionId,
name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
region_path as regionPath,
region_type as regionType,
store_num as storeNum,
store_id as storeId
from region_${enterpriseId}
where parent_id = #{parentId} and deleted = 0
order by region_type
select
id ,
region_id as regionId,
name as name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
vds_group_corp_id as vdsGroupCorpId,
syn_ding_dept_id as synDingDeptId,
region_type as regionType,
deleted as deleted,
region_path as regionPath,
store_num as storeNum
from region_${enterpriseId}
where deleted = 0
and id in (
#{regionId}
)
select
id ,
region_id as regionId,
name as name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
vds_group_corp_id as vdsGroupCorpId,
syn_ding_dept_id as synDingDeptId,
region_type as regionType,
deleted as deleted
from region_${enterpriseId}
where deleted = 0
and region_path like concat("%/",#{regionPath},"/%")
select
id,
name,
region_path
from region_${enterpriseId}
where id in (
#{item}
)
select
id ,
region_id as regionId,
name ,
parent_id as parentId,
create_time as createTime,
update_time as updateTime,
order_num as orderNum,
deleted as deleted
from region_${enterpriseId} where id != 1
and region_path like concat('%/',#{regionId},'/%')
order by id
select
id ,
id as regionId,
name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
syn_ding_dept_id as synDingDeptId,
update_time as updateTime,
update_name as updateName,
region_path as regionPath,
store_num as storeNum,
store_id as storeId,
region_type as regionType,
syn_ding_dept_id as synDingDeptId
from region_${enterpriseId}
where deleted = 0 and parent_id = #{parentId}
select
id ,
id as regionId,
name as name ,
parent_id as parentId,
group_id as groupId,
create_time as createTime,
create_name as createName,
update_time as updateTime,
update_name as updateName,
syn_ding_dept_id as synDingDeptId,
store_id as storeId,
region_type as regionType,
region_path as regionPath,
deleted,
store_num as storeNum
from region_${enterpriseId}
where id = #{regionId} and deleted = 0;
select
id
from
region_${enterpriseId}
where
deleted = 0
and
region_path like concat("%/",#{regionPath},"/%")
select
id
from
region_${enterpriseId}
where
deleted = 0
and
region_path like concat("%/", #{region}, "/%")
select
store_id
from
region_${enterpriseId}
where
deleted = 0
and
region_path like concat("%/", #{region}, "/%")
select
id
from
region_${enterpriseId}
where
deleted = 0
and region_type = 'path'
and
region_path like concat("%/",#{regionPath},"/%")
select
region_path
from
region_${enterpriseId}
where
deleted = 0
and
id in #{region}
select
from region_${enterpriseId}
where region_type = 'path'
and deleted = 0
and (
region_path like
concat('%/',#{id},'/%')
)
select
count(0)
from region_${enterpriseId}
where id in (
#{item}
)
select
from region_${enterpriseId}
WHERE
deleted = 0
AND parent_id in (
#{id}
)
select
from region_${enterpriseId}
where deleted = 0
and parent_id= #{parentId}
and third_region_type = #{thirdRegionType}
select
from region_${enterpriseId}
where deleted = 0
and store_id = #{storeId}
and region_type = 'store'
select
from region_${enterpriseId}
where deleted = 0
and id = (
SELECT parent_id
FROM region_${enterpriseId}
WHERE id = #{regionId}
)
select
from region_${enterpriseId}
where deleted = 0
and third_region_type = '2'
AND id in (
#{id}
)
select
from region_${enterpriseId}
where deleted = 0
and syn_ding_dept_id = #{synDingDeptId}
select
id
from
region_${enterpriseId}
where
deleted = 0
and
region_path like
concat("%/", #{region}, "/%")
select
from region_${enterpriseId}
where deleted = 0
and parent_id = #{regionId}
and region_type = #{regionType}
select
from region_${enterpriseId}
where deleted = 0
and name in (
#{region}
)
and region_type = 'path'