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
a41e7af8
Commit
a41e7af8
authored
Feb 15, 2022
by
chenhao
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop_ccs' of
http://172.16.10.76/moa/amos-boot-biz
into develop_ccs
parents
ae362b9f
512eafdd
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
63 additions
and
3 deletions
+63
-3
OrgUsrController.java
...s/boot/module/common/biz/controller/OrgUsrController.java
+17
-0
OrgUsrServiceImpl.java
...oot/module/common/biz/service/impl/OrgUsrServiceImpl.java
+26
-0
JcsFeign.java
...src/main/java/com/yeejoin/equipmanage/fegin/JcsFeign.java
+11
-1
BuildingServiceImpl.java
...yeejoin/equipmanage/service/impl/BuildingServiceImpl.java
+9
-2
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/controller/OrgUsrController.java
View file @
a41e7af8
...
@@ -734,4 +734,20 @@ public class OrgUsrController extends BaseController {
...
@@ -734,4 +734,20 @@ public class OrgUsrController extends BaseController {
}
}
return
ResponseHelper
.
buildResponse
(
orgUserList
);
return
ResponseHelper
.
buildResponse
(
orgUserList
);
}
}
/**
* 查询多个组织机构下面的所有人员列表信息
*
* @param
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询上级单位"
,
notes
=
"查询上级单位"
)
@GetMapping
(
value
=
"/company/bizOrgCode/list"
)
public
ResponseModel
<
OrgUsrDto
>
getCompanyByBizOrgCodeList
(
@RequestParam
String
bizOrgCode
)
{
if
(
ValidationUtil
.
isEmpty
(
bizOrgCode
))
{
return
ResponseHelper
.
buildResponse
(
new
OrgUsrDto
());
}
return
ResponseHelper
.
buildResponse
(
iOrgUsrService
.
getCompanyByBizOrgCodeList
(
bizOrgCode
));
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/OrgUsrServiceImpl.java
View file @
a41e7af8
...
@@ -82,6 +82,7 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
...
@@ -82,6 +82,7 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
private
static
final
String
FIELD_CODE
=
"telephone"
;
private
static
final
String
FIELD_CODE
=
"telephone"
;
private
static
final
String
COMPANY_FIELD_CODE
=
"companyLocation,longitude,latitude"
;
private
static
final
String
COMPANY_FIELD_CODE
=
"companyLocation,longitude,latitude"
;
private
static
final
String
COMPANY_VALUE
=
"COMPANY"
;
@Autowired
@Autowired
DynamicFormInstanceServiceImpl
alertFormValueServiceImpl
;
DynamicFormInstanceServiceImpl
alertFormValueServiceImpl
;
...
@@ -2190,4 +2191,29 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
...
@@ -2190,4 +2191,29 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
return
this
.
baseMapper
.
selectPersonListByCompanyIdList
(
companyIdList
);
return
this
.
baseMapper
.
selectPersonListByCompanyIdList
(
companyIdList
);
}
}
/**
* 根据bizOrgCode查询详情
*
* @param bizOrgCode
* @return
*/
public
OrgUsrDto
getCompanyByBizOrgCodeList
(
String
bizOrgCode
)
{
LambdaQueryWrapper
<
OrgUsr
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
eq
(
OrgUsr:
:
getBizOrgCode
,
bizOrgCode
);
wrapper
.
eq
(
BaseEntity:
:
getIsDelete
,
false
);
OrgUsr
orgUsr
=
baseMapper
.
selectOne
(
wrapper
);
OrgUsrDto
orgUsrDto
=
new
OrgUsrDto
();
if
(!
orgUsr
.
getBizOrgType
().
equals
(
COMPANY_VALUE
)){
for
(
int
i
=
0
;
i
<
10
;
i
++)
{
OrgUsr
result
=
baseMapper
.
selectById
(
orgUsr
.
getParentId
());
if
(
result
.
getBizOrgType
().
equals
(
COMPANY_VALUE
)){
BeanUtils
.
copyProperties
(
result
,
orgUsrDto
);
break
;
}
}
}
return
orgUsrDto
;
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/fegin/JcsFeign.java
View file @
a41e7af8
...
@@ -16,7 +16,7 @@ import java.util.Map;
...
@@ -16,7 +16,7 @@ import java.util.Map;
/**
/**
* @author DELL
* @author DELL
*/
*/
@FeignClient
(
name
=
"${jcs.fegin.name}"
,
path
=
"jcs"
,
configuration
=
{
FeignConfiguration
.
class
})
@FeignClient
(
name
=
"${jcs.fegin.name}"
,
path
=
"jcs"
,
configuration
=
{
FeignConfiguration
.
class
})
public
interface
JcsFeign
{
public
interface
JcsFeign
{
@RequestMapping
(
value
=
"/water-resource/select_list"
,
method
=
RequestMethod
.
GET
,
consumes
=
"application/json"
)
@RequestMapping
(
value
=
"/water-resource/select_list"
,
method
=
RequestMethod
.
GET
,
consumes
=
"application/json"
)
...
@@ -133,4 +133,14 @@ public interface JcsFeign {
...
@@ -133,4 +133,14 @@ public interface JcsFeign {
*/
*/
@GetMapping
(
value
=
"/org-usr/{authKey}/listWithAuth"
)
@GetMapping
(
value
=
"/org-usr/{authKey}/listWithAuth"
)
FeignClientResult
<
List
<
OrgUsrDto
>>
getCompanyDeptListWithAuth
(
@PathVariable
String
authKey
,
@RequestParam
(
required
=
false
)
String
orgTypes
);
FeignClientResult
<
List
<
OrgUsrDto
>>
getCompanyDeptListWithAuth
(
@PathVariable
String
authKey
,
@RequestParam
(
required
=
false
)
String
orgTypes
);
/**
* 获取机场人员
*
* @return
*/
@RequestMapping
(
value
=
"/org-usr/company/bizOrgCode/list"
,
method
=
RequestMethod
.
GET
,
consumes
=
"application/json"
)
ResponseModel
<
OrgUsrDto
>
getCompanyByBizOrgCodeList
(
@RequestParam
(
required
=
false
)
String
bizOrgCode
);
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/BuildingServiceImpl.java
View file @
a41e7af8
...
@@ -29,6 +29,7 @@ import com.yeejoin.equipmanage.common.vo.BuildingTreeAndEquipVO;
...
@@ -29,6 +29,7 @@ import com.yeejoin.equipmanage.common.vo.BuildingTreeAndEquipVO;
import
com.yeejoin.equipmanage.common.vo.BuildingTreeVo
;
import
com.yeejoin.equipmanage.common.vo.BuildingTreeVo
;
import
com.yeejoin.equipmanage.context.SpringContextHolder
;
import
com.yeejoin.equipmanage.context.SpringContextHolder
;
import
com.yeejoin.equipmanage.event.SyncRiskEvent
;
import
com.yeejoin.equipmanage.event.SyncRiskEvent
;
import
com.yeejoin.equipmanage.fegin.JcsFeign
;
import
com.yeejoin.equipmanage.mapper.*
;
import
com.yeejoin.equipmanage.mapper.*
;
import
com.yeejoin.equipmanage.operation.GroupTypeOperator
;
import
com.yeejoin.equipmanage.operation.GroupTypeOperator
;
import
com.yeejoin.equipmanage.operation.PageOperation
;
import
com.yeejoin.equipmanage.operation.PageOperation
;
...
@@ -47,6 +48,7 @@ import org.springframework.util.CollectionUtils;
...
@@ -47,6 +48,7 @@ import org.springframework.util.CollectionUtils;
import
org.typroject.tyboot.core.foundation.exception.BaseException
;
import
org.typroject.tyboot.core.foundation.exception.BaseException
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.text.SimpleDateFormat
;
import
java.text.SimpleDateFormat
;
...
@@ -83,7 +85,8 @@ public class BuildingServiceImpl extends ServiceImpl<BuildingMapper, Building> i
...
@@ -83,7 +85,8 @@ public class BuildingServiceImpl extends ServiceImpl<BuildingMapper, Building> i
@Autowired
@Autowired
private
FormInstanceMapper
formInstanceMapper
;
private
FormInstanceMapper
formInstanceMapper
;
@Autowired
private
JcsFeign
jcsFeign
;
@Autowired
@Autowired
FireFightingSystemMapper
fireFightingSystemMapper
;
FireFightingSystemMapper
fireFightingSystemMapper
;
...
@@ -1229,8 +1232,12 @@ public class BuildingServiceImpl extends ServiceImpl<BuildingMapper, Building> i
...
@@ -1229,8 +1232,12 @@ public class BuildingServiceImpl extends ServiceImpl<BuildingMapper, Building> i
@Override
@Override
public
List
<
BuildingTreeVo
>
getBuildingTreeInOrgCode
(
String
bizOrgCode
)
{
public
List
<
BuildingTreeVo
>
getBuildingTreeInOrgCode
(
String
bizOrgCode
)
{
//如果传递的为部门bizOrgCode 取其上级单位下的建筑
ResponseModel
<
OrgUsrDto
>
companyByBizOrgCodeList
=
jcsFeign
.
getCompanyByBizOrgCodeList
(
bizOrgCode
);
String
resultCode
=
companyByBizOrgCodeList
.
getResult
().
getBizOrgCode
();
List
<
BuildingTreeVo
>
buildingTreeVos
=
this
.
getBuildingTreeVos
(
true
);
List
<
BuildingTreeVo
>
buildingTreeVos
=
this
.
getBuildingTreeVos
(
true
);
List
<
BuildingTreeVo
>
orgBuildingTreeVos
=
buildingTreeVos
.
stream
().
filter
(
b
->
b
.
getBizOrgCode
()
!=
null
&&
b
.
getBizOrgCode
().
contains
(
bizOrg
Code
)).
collect
(
Collectors
.
toList
());
List
<
BuildingTreeVo
>
orgBuildingTreeVos
=
buildingTreeVos
.
stream
().
filter
(
b
->
b
.
getBizOrgCode
()
!=
null
&&
b
.
getBizOrgCode
().
contains
(
result
Code
)).
collect
(
Collectors
.
toList
());
return
buildingTreeVos
.
stream
().
filter
(
b
->
"-1"
.
equals
(
b
.
getParentId
())).
peek
(
b
->
{
return
buildingTreeVos
.
stream
().
filter
(
b
->
"-1"
.
equals
(
b
.
getParentId
())).
peek
(
b
->
{
b
.
setId
(
0L
);
b
.
setId
(
0L
);
b
.
setChildren
(
this
.
getCompanyBuildingChildrenTree
(
b
.
getId
().
toString
(),
orgBuildingTreeVos
));
b
.
setChildren
(
this
.
getCompanyBuildingChildrenTree
(
b
.
getId
().
toString
(),
orgBuildingTreeVos
));
...
...
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