refactor: 删除版本时提示是否关联资源
This commit is contained in:
parent
6fca678bc4
commit
1569f44806
|
@ -16,4 +16,6 @@ public interface ExtProjectVersionMapper {
|
||||||
boolean isVersionEnable(@Param("projectId") String projectId);
|
boolean isVersionEnable(@Param("projectId") String projectId);
|
||||||
|
|
||||||
void changeVersionEnable(@Param("projectId") String projectId, @Param("status") boolean status);
|
void changeVersionEnable(@Param("projectId") String projectId, @Param("status") boolean status);
|
||||||
|
|
||||||
|
boolean checkForDelete(String id);
|
||||||
}
|
}
|
||||||
|
|
|
@ -65,4 +65,25 @@
|
||||||
<update id="changeVersionEnable">
|
<update id="changeVersionEnable">
|
||||||
update project set version_enable = #{status} where id = #{projectId}
|
update project set version_enable = #{status} where id = #{projectId}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
<select id="checkForDelete" resultType="boolean">
|
||||||
|
SELECT COUNT(1) > 0
|
||||||
|
FROM (
|
||||||
|
SELECT 1
|
||||||
|
FROM api_definition
|
||||||
|
WHERE version_id = #{id}
|
||||||
|
UNION
|
||||||
|
SELECT 1
|
||||||
|
FROM api_scenario
|
||||||
|
WHERE version_id = #{id}
|
||||||
|
UNION
|
||||||
|
SELECT 1
|
||||||
|
FROM api_test_case
|
||||||
|
WHERE version_id = #{id}
|
||||||
|
UNION
|
||||||
|
SELECT 1
|
||||||
|
FROM load_test
|
||||||
|
WHERE version_id = #{id}
|
||||||
|
) AS tmp
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit eba0a4c13d6c7c32c31d497e1a8631fa5f007f72
|
Subproject commit 2bc5749967e4eb931ac69eba712a345e714b7f60
|
|
@ -1 +1 @@
|
||||||
Subproject commit 3e5f85f773dc5ea4d0fc36e51594e107230af2ef
|
Subproject commit 144af6b704f315f19d3fe52fbd258d3bbe19079e
|
|
@ -766,6 +766,9 @@ export default {
|
||||||
please_input_version: 'Please input version',
|
please_input_version: 'Please input version',
|
||||||
tips: 'Note: The closed version will not appear in the system field <strong>Version</strong> drop-down box option',
|
tips: 'Note: The closed version will not appear in the system field <strong>Version</strong> drop-down box option',
|
||||||
enable: 'Enable version management',
|
enable: 'Enable version management',
|
||||||
|
latest: 'Latest',
|
||||||
|
set_latest: 'Latest',
|
||||||
|
delete_tip: 'This version has been associated with system resources. Deleting it will cause the version information lost',
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
member: {
|
member: {
|
||||||
|
|
|
@ -770,6 +770,9 @@ export default {
|
||||||
please_input_version: '请输入版本',
|
please_input_version: '请输入版本',
|
||||||
tips: '注意: 已关闭的版本不会出现在系统字段<strong>版本</strong>下拉框选项中',
|
tips: '注意: 已关闭的版本不会出现在系统字段<strong>版本</strong>下拉框选项中',
|
||||||
enable: '启用版本管理',
|
enable: '启用版本管理',
|
||||||
|
latest: '最新版',
|
||||||
|
set_latest: '设置为最新版本',
|
||||||
|
delete_tip: '此版本已经关联系统资源,删除会导致无法查询到版本信息',
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
member: {
|
member: {
|
||||||
|
|
|
@ -770,6 +770,9 @@ export default {
|
||||||
please_input_version: '請輸入版本',
|
please_input_version: '請輸入版本',
|
||||||
tips: '注意: 已關閉的版本不會出現在系統字段<strong>版本</strong>下拉框選項中',
|
tips: '注意: 已關閉的版本不會出現在系統字段<strong>版本</strong>下拉框選項中',
|
||||||
enable: '啟用版本管理',
|
enable: '啟用版本管理',
|
||||||
|
latest: '最新版',
|
||||||
|
set_latest: '設置為最新版本',
|
||||||
|
delete_tip: '此版本已經關聯繫統資源,刪除會導致無法查詢到版本信息',
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
member: {
|
member: {
|
||||||
|
|
Loading…
Reference in New Issue