Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
P
pms
概览
概览
详情
活动
周期分析
版本库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
问题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程表
图表
维基
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
iuav
pms
Commits
cf50eb08
提交
cf50eb08
authored
8月 21, 2023
作者:
张小凤
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Industry(update)
上级
5e7df5fb
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
56 行增加
和
52 行删除
+56
-52
IndustryTypeController.java
...mmc/pms/controller/inspection/IndustryTypeController.java
+9
-9
IndustryTypeDao.java
...main/java/com/mmc/pms/dao/inspection/IndustryTypeDao.java
+1
-1
IndustryTypeService.java
...a/com/mmc/pms/service/inspection/IndustryTypeService.java
+1
-1
IndustryTypeServiceImpl.java
.../pms/service/inspection/impl/IndustryTypeServiceImpl.java
+2
-2
IndustryTypeDao.xml
src/main/resources/mapper/inspection/IndustryTypeDao.xml
+41
-37
not-check.yml
src/main/resources/not-check.yml
+2
-2
没有找到文件。
src/main/java/com/mmc/pms/controller/inspection/IndustryTypeController.java
浏览文件 @
cf50eb08
...
@@ -30,49 +30,49 @@ public class IndustryTypeController {
...
@@ -30,49 +30,49 @@ public class IndustryTypeController {
@ApiOperation
(
value
=
"新增行业"
)
@ApiOperation
(
value
=
"新增行业"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@PostMapping
(
"insert"
)
@PostMapping
(
"insert"
)
public
ResultBody
insert
(
@RequestBody
IndustryTypeVO
industryTypeVO
){
public
ResultBody
insert
(
@RequestBody
IndustryTypeVO
industryTypeVO
)
{
return
industryTypeService
.
insert
(
industryTypeVO
);
return
industryTypeService
.
insert
(
industryTypeVO
);
}
}
@ApiOperation
(
value
=
"修改行业"
)
@ApiOperation
(
value
=
"修改行业"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@PostMapping
(
"update"
)
@PostMapping
(
"update"
)
public
ResultBody
update
(
@RequestBody
IndustryTypeVO
industryTypeVO
){
public
ResultBody
update
(
@RequestBody
IndustryTypeVO
industryTypeVO
)
{
return
industryTypeService
.
update
(
industryTypeVO
);
return
industryTypeService
.
update
(
industryTypeVO
);
}
}
@ApiOperation
(
value
=
"删除行业"
)
@ApiOperation
(
value
=
"删除行业"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@GetMapping
(
"remove"
)
@GetMapping
(
"remove"
)
public
ResultBody
remove
(
@RequestParam
Integer
id
){
public
ResultBody
remove
(
@RequestParam
Integer
id
)
{
return
industryTypeService
.
remove
(
id
);
return
industryTypeService
.
remove
(
id
);
}
}
@ApiOperation
(
value
=
"一级行业列表"
)
@ApiOperation
(
value
=
"一级行业列表"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
ResultBody
.
class
)})
@PostMapping
(
"listPages"
)
@PostMapping
(
"listPages"
)
public
ResultBody
<
IndustryTypeDTO
>
listPages
(
@Validated
(
value
=
{
Page
.
class
})
@RequestBody
IndustryTypeQO
industryTypeQO
){
public
ResultBody
<
IndustryTypeDTO
>
listPages
(
@Validated
(
value
=
{
Page
.
class
})
@RequestBody
IndustryTypeQO
industryTypeQO
)
{
return
industryTypeService
.
listPages
(
industryTypeQO
);
return
industryTypeService
.
listPages
(
industryTypeQO
);
}
}
@ApiOperation
(
value
=
"根据一级行业id查询二级服务列表"
)
@ApiOperation
(
value
=
"根据一级行业id查询二级服务列表"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
IndustryTypeDTO
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
IndustryTypeDTO
.
class
)})
@GetMapping
(
"listInspectionsByIndustryTypeId"
)
@GetMapping
(
"listInspectionsByIndustryTypeId"
)
public
ResultBody
<
IndustryTypeDTO
>
listInspectionsByIndustryTypeId
(
@RequestParam
Integer
id
){
public
ResultBody
<
IndustryTypeDTO
>
listInspectionsByIndustryTypeId
(
@RequestParam
Integer
id
)
{
return
industryTypeService
.
listInspectionsByIndustryTypeId
(
id
);
return
industryTypeService
.
listInspectionsByIndustryTypeId
(
id
);
}
}
@ApiOperation
(
value
=
"一级行业详情-全部"
)
@ApiOperation
(
value
=
"一级行业详情-全部"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
IndustryTypeDTO
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
IndustryTypeDTO
.
class
)})
@GetMapping
(
"getIndustryTypeById"
)
@GetMapping
(
"getIndustryTypeById"
)
public
ResultBody
<
IndustryTypeDTO
>
getIndustryTypeById
(
@RequestParam
Integer
id
){
public
ResultBody
<
IndustryTypeDTO
>
getIndustryTypeById
(
@RequestParam
Integer
id
)
{
return
industryTypeService
.
getIndustryTypeById
(
id
);
return
industryTypeService
.
getIndustryTypeById
(
id
);
}
}
@ApiOperation
(
value
=
"一级行业列表-全部"
)
@ApiOperation
(
value
=
"一级行业列表-全部"
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
List
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
List
.
class
)})
@
Pos
tMapping
(
"listIndustry"
)
@
Ge
tMapping
(
"listIndustry"
)
public
List
<
IndustryTypeDTO
>
listIndustry
(
@Validated
(
value
=
{
Page
.
class
})
@RequestBody
IndustryTypeQO
industryTypeQO
)
{
public
List
<
IndustryTypeDTO
>
listIndustry
(
)
{
return
industryTypeService
.
listIndustry
(
industryTypeQO
);
return
industryTypeService
.
listIndustry
();
}
}
}
}
src/main/java/com/mmc/pms/dao/inspection/IndustryTypeDao.java
浏览文件 @
cf50eb08
...
@@ -25,7 +25,7 @@ public interface IndustryTypeDao {
...
@@ -25,7 +25,7 @@ public interface IndustryTypeDao {
List
<
IndustryTypeDO
>
listPages
(
IndustryTypeQO
industryTypeQO
);
List
<
IndustryTypeDO
>
listPages
(
IndustryTypeQO
industryTypeQO
);
List
<
IndustryTypeDO
>
listIndustry
(
IndustryTypeQO
industryTypeQO
);
List
<
IndustryTypeDO
>
listIndustry
();
List
<
InspectionDO
>
listInspectionsByIndustryTypeIdId
(
Integer
industryTypeId
);
List
<
InspectionDO
>
listInspectionsByIndustryTypeIdId
(
Integer
industryTypeId
);
...
...
src/main/java/com/mmc/pms/service/inspection/IndustryTypeService.java
浏览文件 @
cf50eb08
...
@@ -24,5 +24,5 @@ public interface IndustryTypeService {
...
@@ -24,5 +24,5 @@ public interface IndustryTypeService {
ResultBody
<
IndustryTypeDTO
>
getIndustryTypeById
(
Integer
id
);
ResultBody
<
IndustryTypeDTO
>
getIndustryTypeById
(
Integer
id
);
List
<
IndustryTypeDTO
>
listIndustry
(
IndustryTypeQO
industryTypeQO
);
List
<
IndustryTypeDTO
>
listIndustry
();
}
}
src/main/java/com/mmc/pms/service/inspection/impl/IndustryTypeServiceImpl.java
浏览文件 @
cf50eb08
...
@@ -93,8 +93,8 @@ public class IndustryTypeServiceImpl implements IndustryTypeService {
...
@@ -93,8 +93,8 @@ public class IndustryTypeServiceImpl implements IndustryTypeService {
}
}
@Override
@Override
public
List
<
IndustryTypeDTO
>
listIndustry
(
IndustryTypeQO
industryTypeQO
)
{
public
List
<
IndustryTypeDTO
>
listIndustry
()
{
List
<
IndustryTypeDO
>
industryTypeDOS
=
industryTypeDao
.
listIndustry
(
industryTypeQO
);
List
<
IndustryTypeDO
>
industryTypeDOS
=
industryTypeDao
.
listIndustry
();
if
(
CollectionUtils
.
isNotEmpty
(
industryTypeDOS
))
{
if
(
CollectionUtils
.
isNotEmpty
(
industryTypeDOS
))
{
List
<
IndustryTypeDTO
>
industryTypeDTOS
=
industryTypeDOS
.
stream
().
map
(
IndustryTypeDO:
:
buildIndustryTypeDTO
).
collect
(
Collectors
.
toList
());
List
<
IndustryTypeDTO
>
industryTypeDTOS
=
industryTypeDOS
.
stream
().
map
(
IndustryTypeDO:
:
buildIndustryTypeDTO
).
collect
(
Collectors
.
toList
());
return
industryTypeDTOS
;
return
industryTypeDTOS
;
...
...
src/main/resources/mapper/inspection/IndustryTypeDao.xml
浏览文件 @
cf50eb08
...
@@ -18,38 +18,51 @@
...
@@ -18,38 +18,51 @@
</resultMap>
</resultMap>
<select
id=
"listInspectionsByIndustryTypeIdId"
resultType=
"com.mmc.pms.entity.inspection.InspectionDO"
>
<select
id=
"listInspectionsByIndustryTypeIdId"
resultType=
"com.mmc.pms.entity.inspection.InspectionDO"
>
select ins.id , ins.inspection_no, ins.inspection_name, ins.industry_type_id, ins.inspection_img,
select ins.id,
ins.inspection_description, ins.sale_state as ins_sale_state, ins.case_img, ins.case_video, ins.create_time
ins.inspection_no,
from inspection ins
ins.inspection_name,
where ins.is_deleted = 0 and ins.industry_type_id = #{industryTypeId} order by ins.id desc
ins.industry_type_id,
ins.inspection_img,
ins.inspection_description,
ins.sale_state as ins_sale_state,
ins.case_img,
ins.case_video,
ins.create_time
from inspection ins
where ins.is_deleted = 0
and ins.industry_type_id = #{industryTypeId}
order by ins.id desc
</select>
</select>
<insert
id=
"insert"
parameterType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
keyProperty=
"id"
useGeneratedKeys=
"true"
>
<insert
id=
"insert"
parameterType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
keyProperty=
"id"
useGeneratedKeys=
"true"
>
insert into industry_type(type_name, type_img, description, sale_state, create_time)
insert into industry_type(type_name, type_img, description, sale_state, create_time)
values(#{typeName}, #{typeImg}, #{description}, #{saleState}, NOW())
values
(#{typeName}, #{typeImg}, #{description}, #{saleState}, NOW())
</insert>
</insert>
<update
id=
"update"
parameterType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
>
<update
id=
"update"
parameterType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
>
update industry_type
update industry_type
<set>
<set>
<if
test=
"typeName != null"
>
<if
test=
"typeName != null"
>
type_name = #{typeName},
type_name = #{typeName},
</if>
</if>
<if
test=
"typeImg != null"
>
<if
test=
"typeImg != null"
>
type_img = #{typeImg},
type_img = #{typeImg},
</if>
</if>
<if
test=
"description != null"
>
<if
test=
"description != null"
>
description = #{description},
description = #{description},
</if>
</if>
<if
test=
"saleState != null"
>
<if
test=
"saleState != null"
>
sale_state = #{saleState}
sale_state = #{saleState}
</if>
</if>
</set>
</set>
where id = #{id}
where id = #{id}
</update>
</update>
<update
id=
"remove"
>
<update
id=
"remove"
>
update industry_type set is_deleted = 1 where id = #{id}
update industry_type
set is_deleted = 1
where id = #{id}
</update>
</update>
<select
id=
"countSameName"
resultType=
"java.lang.Integer"
>
<select
id=
"countSameName"
resultType=
"java.lang.Integer"
>
...
@@ -65,7 +78,7 @@
...
@@ -65,7 +78,7 @@
<select
id=
"countListPages"
resultType=
"java.lang.Integer"
<select
id=
"countListPages"
resultType=
"java.lang.Integer"
parameterType=
"com.mmc.pms.model.qo.IndustryTypeQO"
>
parameterType=
"com.mmc.pms.model.qo.IndustryTypeQO"
>
select count(*) from industry_type it
select count(*) from industry_type it
where it.is_deleted = 0
where it.is_deleted = 0
<if
test=
"id != null"
>
<if
test=
"id != null"
>
and it.id = #{id}
and it.id = #{id}
</if>
</if>
...
@@ -77,8 +90,8 @@
...
@@ -77,8 +90,8 @@
<select
id=
"listPages"
resultMap=
"industryTypeResMap"
<select
id=
"listPages"
resultMap=
"industryTypeResMap"
parameterType=
"com.mmc.pms.model.qo.IndustryTypeQO"
>
parameterType=
"com.mmc.pms.model.qo.IndustryTypeQO"
>
select it.id, it.type_name, it.type_img, it.description, it.sale_state, it.is_deleted, it.create_time
select it.id, it.type_name, it.type_img, it.description, it.sale_state, it.is_deleted, it.create_time
from industry_type it
from industry_type it
where it.is_deleted = 0
where it.is_deleted = 0
<if
test=
"id != null"
>
<if
test=
"id != null"
>
and it.id = #{id}
and it.id = #{id}
</if>
</if>
...
@@ -92,19 +105,11 @@
...
@@ -92,19 +105,11 @@
<select
id=
"listIndustry"
resultType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
>
<select
id=
"listIndustry"
resultType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
>
select it.id, it.type_name, it.type_img, it.description, it.sale_state, it.is_deleted, it.create_time
select it.id, it.type_name, it.type_img, it.description, it.sale_state, it.is_deleted, it.create_time
from industry_type it
from industry_type it
where 1 = 1
<if
test=
"id != null"
>
and it.id = #{id}
</if>
<if
test=
"typeName != null"
>
and it.type_name like concat('%',#{typeName},'%')
</if>
order by it.id DESC
</select>
</select>
<select
id=
"getIndustryTypeById"
resultType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
>
<select
id=
"getIndustryTypeById"
resultType=
"com.mmc.pms.entity.inspection.IndustryTypeDO"
>
select it.id, it.type_name, it.type_img, it.description, it.sale_state, it.is_deleted, it.create_time
select it.id, it.type_name, it.type_img, it.description, it.sale_state, it.is_deleted, it.create_time
from industry_type it
from industry_type it
where it.id = #{id}
where it.id = #{id}
</select>
</select>
</mapper>
</mapper>
\ No newline at end of file
src/main/resources/not-check.yml
浏览文件 @
cf50eb08
...
@@ -34,4 +34,5 @@ data-filter:
...
@@ -34,4 +34,5 @@ data-filter:
-
/pms/company-inspection/listAPPCompanyInspectionPage
-
/pms/company-inspection/listAPPCompanyInspectionPage
-
/pms/company-inspection/getCompanyInspectionById
-
/pms/company-inspection/getCompanyInspectionById
-
/pms/company-inspection/listInspectionPriceUnit
-
/pms/company-inspection/listInspectionPriceUnit
-
/pms/lease/goods/feignLeaseGoodsInfoByAddressId
-
/pms/lease/goods/feignLeaseGoodsInfoByAddressId
\ No newline at end of file
-
/pms/industry/listIndustry
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论