Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
ae8fef62
Commit
ae8fef62
authored
Oct 20, 2022
by
wujiang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' of
http://39.98.45.134:8090/moa/amos-boot-biz
into developer
parents
ee63db78
005b7ce1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
53 additions
and
19 deletions
+53
-19
ControllerAop.java
...a/com/yeejoin/amos/boot/biz/common/aop/ControllerAop.java
+0
-3
SuperviseRuleDto.java
...eejoin/amos/boot/module/ugp/api/dto/SuperviseRuleDto.java
+1
-3
InstallNoticeMsgMapper.xml
...-api/src/main/resources/mapper/InstallNoticeMsgMapper.xml
+2
-2
ProjectResourceMapper.xml
...p-api/src/main/resources/mapper/ProjectResourceMapper.xml
+2
-2
SuperviseRuleController.java
...ot/module/ugp/biz/controller/SuperviseRuleController.java
+48
-9
No files found.
amos-boot-biz-common/src/main/java/com/yeejoin/amos/boot/biz/common/aop/ControllerAop.java
View file @
ae8fef62
...
@@ -95,9 +95,6 @@ public class ControllerAop {
...
@@ -95,9 +95,6 @@ public class ControllerAop {
// 不需要校验token的接口直接返回
// 不需要校验token的接口直接返回
if
(
joinPoint
.
getSignature
()
instanceof
MethodSignature
)
{
if
(
joinPoint
.
getSignature
()
instanceof
MethodSignature
)
{
if
(!((
MethodSignature
)
joinPoint
.
getSignature
()).
getMethod
().
getAnnotation
(
TycloudOperation
.
class
).
needAuth
()
&&
!
request
.
getParameterMap
().
containsKey
(
"token"
)
&&
ValidationUtil
.
isEmpty
(
token
))
{
return
;
}
}
}
// 平台studio配置的下载接口token从url里取
// 平台studio配置的下载接口token从url里取
...
...
amos-boot-system-ugp/amos-boot-module-ugp-api/src/main/java/com/yeejoin/amos/boot/module/ugp/api/dto/SuperviseRuleDto.java
View file @
ae8fef62
...
@@ -12,7 +12,7 @@ import java.util.Date;
...
@@ -12,7 +12,7 @@ import java.util.Date;
* 监管区域规则表
* 监管区域规则表
*
*
* @author system_generator
* @author system_generator
* @date 2022-
09-22
* @date 2022-
10-18
*/
*/
@Data
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@EqualsAndHashCode
(
callSuper
=
true
)
...
@@ -39,6 +39,4 @@ public class SuperviseRuleDto extends BaseDto {
...
@@ -39,6 +39,4 @@ public class SuperviseRuleDto extends BaseDto {
@ApiModelProperty
(
value
=
"创建时间"
)
@ApiModelProperty
(
value
=
"创建时间"
)
private
Date
createDate
;
private
Date
createDate
;
}
}
amos-boot-system-ugp/amos-boot-module-ugp-api/src/main/resources/mapper/InstallNoticeMsgMapper.xml
View file @
ae8fef62
...
@@ -19,10 +19,10 @@
...
@@ -19,10 +19,10 @@
where tz_ugp_project.sequence_nbr = tz_ugp_install_notice.project_id
where tz_ugp_project.sequence_nbr = tz_ugp_install_notice.project_id
and tz_ugp_install_notice_msg.install_notice_id = tz_ugp_install_notice.sequence_nbr
and tz_ugp_install_notice_msg.install_notice_id = tz_ugp_install_notice.sequence_nbr
<if
test=
"name != null and name != ''"
>
<if
test=
"name != null and name != ''"
>
and tz_ugp_project.name
= #{name}
and tz_ugp_project.name
like '%${name}%'
</if>
</if>
<if
test=
"installationUnit != null and installationUnit != ''"
>
<if
test=
"installationUnit != null and installationUnit != ''"
>
and tz_ugp_project.installationUnit
= #{installationUnit}
and tz_ugp_project.installationUnit
like '%${installationUnit}%'
</if>
</if>
</select>
</select>
<select
id=
"selectByName"
resultType=
"com.yeejoin.amos.boot.module.ugp.api.dto.InstallNoticeMsgPageDto"
>
<select
id=
"selectByName"
resultType=
"com.yeejoin.amos.boot.module.ugp.api.dto.InstallNoticeMsgPageDto"
>
...
...
amos-boot-system-ugp/amos-boot-module-ugp-api/src/main/resources/mapper/ProjectResourceMapper.xml
View file @
ae8fef62
...
@@ -22,10 +22,10 @@
...
@@ -22,10 +22,10 @@
tz_ugp_attachment.type = 'enuipment'
tz_ugp_attachment.type = 'enuipment'
<where>
<where>
<if
test=
"name != null and name != ''"
>
<if
test=
"name != null and name != ''"
>
and tz_ugp_equipment.name
= #{name}
and tz_ugp_equipment.name
like '%${name}%'
</if>
</if>
<if
test=
"type != null and type != ''"
>
<if
test=
"type != null and type != ''"
>
and tz_ugp_equipment.type
= #{type}
and tz_ugp_equipment.type
like '%${type}%'
</if>
</if>
</where>
</where>
</select>
</select>
...
...
amos-boot-system-ugp/amos-boot-module-ugp-biz/src/main/java/com/yeejoin/amos/boot/module/ugp/biz/controller/SuperviseRuleController.java
View file @
ae8fef62
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ugp
.
biz
.
controller
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ugp
.
biz
.
controller
;
import
com.yeejoin.amos.boot.module.common.api.entity.OrgUsr
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.OrgServiceImpl
;
import
com.yeejoin.amos.component.feign.model.FeignClientResult
;
import
com.yeejoin.amos.feign.systemctl.Systemctl
;
import
com.yeejoin.amos.feign.systemctl.model.RegionModel
;
import
org.springframework.http.HttpStatus
;
import
org.springframework.http.HttpStatus
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
...
@@ -8,10 +13,7 @@ import org.springframework.web.bind.annotation.RestController;
...
@@ -8,10 +13,7 @@ import org.springframework.web.bind.annotation.RestController;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
java.sql.SQLIntegrityConstraintViolationException
;
import
java.sql.SQLIntegrityConstraintViolationException
;
import
java.util.Arrays
;
import
java.util.*
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.TreeSet
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.SuperviseRuleServiceImpl
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.SuperviseRuleServiceImpl
;
...
@@ -32,7 +34,7 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType;
...
@@ -32,7 +34,7 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType;
* 监管区域规则表
* 监管区域规则表
*
*
* @author system_generator
* @author system_generator
* @date 2022-
09-22
* @date 2022-
10-18
*/
*/
@RestController
@RestController
@Api
(
tags
=
"监管区域规则表Api"
)
@Api
(
tags
=
"监管区域规则表Api"
)
...
@@ -41,8 +43,11 @@ public class SuperviseRuleController extends BaseController {
...
@@ -41,8 +43,11 @@ public class SuperviseRuleController extends BaseController {
@Autowired
@Autowired
SuperviseRuleServiceImpl
superviseRuleServiceImpl
;
SuperviseRuleServiceImpl
superviseRuleServiceImpl
;
//private int current;
@Autowired
OrgServiceImpl
orgServiceImpl
;
/**
/**
* 新增监管区域规则表
* 新增监管区域规则表
*
*
* @return
* @return
...
@@ -52,10 +57,29 @@ public class SuperviseRuleController extends BaseController {
...
@@ -52,10 +57,29 @@ public class SuperviseRuleController extends BaseController {
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增监管区域规则表"
,
notes
=
"新增监管区域规则表"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增监管区域规则表"
,
notes
=
"新增监管区域规则表"
)
public
ResponseModel
<
SuperviseRuleDto
>
save
(
@RequestBody
SuperviseRuleDto
model
)
{
public
ResponseModel
<
SuperviseRuleDto
>
save
(
@RequestBody
SuperviseRuleDto
model
)
{
model
.
setCreateDate
(
new
Date
());
model
.
setCreateDate
(
new
Date
());
model
=
superviseRuleServiceImpl
.
createWithModel
(
model
);
//外网调不到内网,所以报错,暂时预留
// Collection<RegionModel> result = Systemctl.regionClient.queryForTree(null).getResult();
// //result是一个树结构的集合,需要递归
// Map<String,String> map = new HashMap<>();
// getMap(map,result);
// //获取的Map中key是code,value是name
// model.setAdminRegion(map.get(model.getAdminRegionCode()));
//外网调不到内网 暂时预留
// OrgUsr orgUsr = orgServiceImpl.getOrgUsr();
// model.setSequenceNbr(orgUsr.getSequenceNbr());
model
=
superviseRuleServiceImpl
.
createWithModel
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
}
public
void
getMap
(
Map
map
,
Collection
<
RegionModel
>
collection
){
Iterator
<
RegionModel
>
iterator
=
collection
.
iterator
();
if
(
iterator
.
hasNext
()){
RegionModel
regionModel
=
iterator
.
next
();
map
.
put
(
regionModel
.
getRegionCode
(),
regionModel
.
getRegionName
());
getMap
(
map
,
regionModel
.
getChildren
());
}
}
/**
/**
* 根据sequenceNbr更新
* 根据sequenceNbr更新
*
*
...
@@ -115,11 +139,12 @@ public class SuperviseRuleController extends BaseController {
...
@@ -115,11 +139,12 @@ public class SuperviseRuleController extends BaseController {
public
ResponseModel
<
Page
<
SuperviseRuleDto
>>
queryForPage
(
public
ResponseModel
<
Page
<
SuperviseRuleDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
value
=
"size"
)
int
size
,
int
adminRegionCode
,
@RequestParam
(
value
=
"adminRegionCode"
,
required
=
false
)
String
adminRegionCode
,
@RequestParam
(
value
=
"superviseDeptId"
,
required
=
false
)
Long
superviseDeptId
,
@RequestParam
(
value
=
"superviseDeptId"
,
required
=
false
)
Long
superviseDeptId
,
@RequestParam
(
value
=
"inspectionUnitId"
,
required
=
false
)
Long
inspectionUnitId
@RequestParam
(
value
=
"inspectionUnitId"
,
required
=
false
)
Long
inspectionUnitId
)
{
)
{
Page
<
SuperviseRuleDto
>
page
=
new
Page
<
SuperviseRuleDto
>();
//this.current = current;
Page
<
SuperviseRuleDto
>
page
=
new
Page
<
SuperviseRuleDto
>();
page
.
setCurrent
(
current
);
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
superviseRuleServiceImpl
.
queryForSuperviseRulePage
(
page
,
superviseDeptId
,
inspectionUnitId
));
return
ResponseHelper
.
buildResponse
(
superviseRuleServiceImpl
.
queryForSuperviseRulePage
(
page
,
superviseDeptId
,
inspectionUnitId
));
...
@@ -136,4 +161,18 @@ public class SuperviseRuleController extends BaseController {
...
@@ -136,4 +161,18 @@ public class SuperviseRuleController extends BaseController {
public
ResponseModel
<
List
<
SuperviseRuleDto
>>
selectForList
()
{
public
ResponseModel
<
List
<
SuperviseRuleDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
superviseRuleServiceImpl
.
queryForSuperviseRuleList
());
return
ResponseHelper
.
buildResponse
(
superviseRuleServiceImpl
.
queryForSuperviseRuleList
());
}
}
/**
* 根据sequenceNbr查询标准规则库
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@GetMapping
(
value
=
"/queryBySeq/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询监管区域规则表"
,
notes
=
"根据sequenceNbr查询监管区域规则表"
)
public
ResponseModel
<
SuperviseRuleDto
>
queryBySeq
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
superviseRuleServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment