达梦适配修改

This commit is contained in:
王奎兴
2025-12-05 10:47:46 +08:00
parent 5005f4291f
commit 32f12bb138
49 changed files with 254 additions and 209 deletions
@@ -17,7 +17,7 @@
a.update_by,
a.update_by_name,
a.del_flag
FROM `sys_city` a
FROM sys_city a
WHERE a.del_flag = 1
</sql>
@@ -43,7 +43,7 @@
a.update_by,
a.update_by_name,
a.del_flag
FROM `sys_city` a
FROM sys_city a
WHERE a.del_flag = 1
<include refid="common_where"></include>
</select>
@@ -71,7 +71,7 @@
city_name,
city_remark
FROM
`sys_city`
sys_city
WHERE
province_code = #{values}
ORDER BY
@@ -17,7 +17,7 @@
a.update_by,
a.update_by_name,
a.del_flag
FROM `sys_county` a
FROM sys_county a
WHERE a.del_flag = 1
</sql>
@@ -43,7 +43,7 @@
a.update_by_name,
a.del_flag
FROM
`sys_county` a
sys_county a
WHERE
a.del_flag = 1
<include refid="common_where"></include>
@@ -68,7 +68,7 @@
city_code,
county_name,
county_remark
FROM `sys_county`
FROM sys_county
WHERE city_code = #{values}
ORDER BY county_code_new DESC LIMIT 1
</select>
@@ -113,7 +113,7 @@
a.county_name as countyName,
CONCAT( c.province_name, b.city_name, a.county_name ) AS provinceCityCountyName
FROM
`sys_county` a
sys_county a
LEFT JOIN sys_city b ON a.city_code = b.city_code
LEFT JOIN sys_province c ON b.province_code = c.province_code
WHERE
@@ -15,7 +15,7 @@
a.update_by,
a.update_by_name,
a.del_flag
FROM `sys_province` a
FROM sys_province a
WHERE a.del_flag = 1
</sql>
@@ -41,7 +41,7 @@
a.update_by,
a.update_by_name,
a.del_flag
FROM `sys_province` a
FROM sys_province a
WHERE a.del_flag = 1
<include refid="common_where"></include>
</select>
@@ -75,7 +75,7 @@
c.update_by_name,
c.del_flag
FROM
`sys_county` a
sys_county a
LEFT JOIN sys_city b ON a.city_code = b.city_code
LEFT JOIN sys_province c ON b.province_code = c.province_code
UNION
@@ -94,7 +94,7 @@
b.update_by_name,
b.del_flag
FROM
`sys_county` a
sys_county a
LEFT JOIN sys_city b ON a.city_code = b.city_code
LEFT JOIN sys_province c ON b.province_code = c.province_code
UNION
@@ -113,7 +113,7 @@
a.update_by_name,
a.del_flag
FROM
`sys_county` a
sys_county a
LEFT JOIN sys_city b ON a.city_code = b.city_code
LEFT JOIN sys_province c ON b.province_code = c.province_code
) a
@@ -147,7 +147,7 @@
c.update_by_name,
c.del_flag
FROM
`sys_county` a
sys_county a
LEFT JOIN sys_city b ON a.city_code = b.city_code
LEFT JOIN sys_province c ON b.province_code = c.province_code
@@ -178,7 +178,7 @@
b.update_by_name,
b.del_flag
FROM
`sys_county` a
sys_county a
LEFT JOIN sys_city b ON a.city_code = b.city_code
LEFT JOIN sys_province c ON b.province_code = c.province_code
WHERE
@@ -208,7 +208,7 @@
a.update_by_name,
a.del_flag
FROM
`sys_county` a
sys_county a
LEFT JOIN sys_city b ON a.city_code = b.city_code
LEFT JOIN sys_province c ON b.province_code = c.province_code
WHERE
@@ -245,7 +245,7 @@
province_name,
province_remark
FROM
`sys_province`
sys_province
ORDER BY
province_code DESC
LIMIT 1
@@ -7,7 +7,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
SELECT
a.*
FROM
`basic_agreement` a
basic_agreement a
WHERE
a.del_flag = 1
</sql>
@@ -118,7 +118,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
ab1.latitude AS receive_doorplate,
ab1.address_plot AS receive_addressPlot
FROM
`common_route` cr
common_route cr
LEFT JOIN
address_book ab
ON ab.address_book_id = cr.send_address_id and ab.user_id = #{userId}
@@ -180,7 +180,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
b.doorplate,
b.remark
FROM
`manifest_throught` m
manifest_throught m
LEFT JOIN
address_book b
ON m.address_book_id = b.address_book_id
@@ -170,7 +170,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
and material_base_info_id in (SELECT
DISTINCT material_base_info_id
FROM `test_szwl_wms`.material_inventory
FROM test_szwl_wms.material_inventory
WHERE
allocation_quantity > 0
AND del_flag = 1)
@@ -29,7 +29,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<sql id="selectMaterialClassifyPo">
select material_classify_id, organization_id, organization_name, top_organization_id, code, `name`, `level`, parent_code, parent_name, code_path, name_path, remark, nullify, create_time, create_by, create_by_name, update_time, update_by, update_by_name, del_flag from material_classify
select material_classify_id, organization_id, organization_name, top_organization_id, code, name, level, parent_code, parent_name, code_path, name_path, remark, nullify, create_time, create_by, create_by_name, update_time, update_by, update_by_name, del_flag from material_classify
</sql>
<sql id="selectMaterialClassifyPo1">
@@ -47,10 +47,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
and code = #{code}
</if>
<if test="name != null and name != ''">
and `name` like concat('%', #{name}, '%')
and name like concat('%', #{name}, '%')
</if>
<if test="level != null ">
and `level` = #{level}
and level = #{level}
</if>
<if test="parentCode != null and parentCode != ''">
and parent_code = #{parentCode}
@@ -93,6 +93,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<include refid="selectMaterialClassifyPo"/>
WHERE
FIND_IN_SET(#{parentCode}, code_path) > 0
ORDER BY `level` ASC
ORDER BY level ASC
</select>
</mapper>
@@ -82,7 +82,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
and update_by_name like concat('%', #{updateByName}, '%')
</if>
<if test="number != null">
and `number` = #{number}
and number = #{number}
</if>
<if test="remark != null and remark != ''">
and remark like concat('%',#{remark},'%')
@@ -29,7 +29,7 @@
</resultMap>
<sql id="selectMenuVo">
select menu_id, menu_name, parent_id, order_num, path, component, `query`, is_frame, is_cache, menu_type, visible,sys_type, status, ifnull(perms,'') as perms, icon, create_time
select menu_id, menu_name, parent_id, order_num, path, component, query, is_frame, is_cache, menu_type, visible,sys_type, status, ifnull(perms,'') as perms, icon, create_time
from sys_menu
</sql>
@@ -54,13 +54,13 @@
</select>
<select id="selectMenuTreeAll" resultMap="SysMenuResult">
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.`query`, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.query, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
from sys_menu m where m.menu_type in ('M', 'C') and m.status = 0
order by m.parent_id, m.order_num
</select>
<select id="selectMenuListByUserId" parameterType="SysMenu" resultMap="SysMenuResult">
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.`query`, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type,m.sys_type, m.icon, m.order_num, m.create_time
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.query, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type,m.sys_type, m.icon, m.order_num, m.create_time
from sys_menu m
left join sys_role_menu rm on m.menu_id = rm.menu_id
left join sys_user_role ur on rm.role_id = ur.role_id
@@ -82,7 +82,7 @@
</select>
<select id="selectMenuTreeByUserId" parameterType="Long" resultMap="SysMenuResult">
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.`query`, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
select distinct m.menu_id, m.parent_id, m.menu_name, m.path, m.component, m.query, m.visible, m.status, ifnull(m.perms,'') as perms, m.is_frame, m.is_cache, m.menu_type, m.icon, m.order_num, m.create_time
from sys_menu m
left join sys_role_menu rm on m.menu_id = rm.menu_id
left join sys_user_role ur on rm.role_id = ur.role_id
@@ -151,7 +151,7 @@
<if test="orderNum != null">order_num = #{orderNum},</if>
<if test="path != null and path != ''">path = #{path},</if>
<if test="component != null">component = #{component},</if>
<if test="query != null">`query` = #{query},</if>
<if test="query != null">query = #{query},</if>
<if test="isFrame != null and isFrame != ''">is_frame = #{isFrame},</if>
<if test="isCache != null and isCache != ''">is_cache = #{isCache},</if>
<if test="menuType != null and menuType != ''">menu_type = #{menuType},</if>
@@ -174,7 +174,7 @@
<if test="orderNum != null">order_num,</if>
<if test="path != null and path != ''">path,</if>
<if test="component != null and component != ''">component,</if>
<if test="query != null and query != ''">`query`,</if>
<if test="query != null and query != ''">query,</if>
<if test="isFrame != null and isFrame != ''">is_frame,</if>
<if test="isCache != null and isCache != ''">is_cache,</if>
<if test="menuType != null and menuType != ''">menu_type,</if>
@@ -28,7 +28,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
a.accounting_id,
a.charge_amount,
a.tenant_phone,
a.`status`,
a.status,
a.del_flag,
a.create_by,
a.create_time,