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
a88304e9
Commit
a88304e9
authored
Oct 13, 2022
by
zhangyingbin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增获取下来选择框的值 接口( 建设单位负责人(下拉) 项目设计单位(下拉) 项目安装单位(下拉))
parent
23eef1d9
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
60 additions
and
6 deletions
+60
-6
OrgPersonEnum.java
...join/amos/boot/module/common/api/enums/OrgPersonEnum.java
+27
-5
CompanyController.java
...mos/boot/module/ugp/biz/controller/CompanyController.java
+6
-0
ProjectController.java
...mos/boot/module/ugp/biz/controller/ProjectController.java
+16
-0
OrgServiceImpl.java
...amos/boot/module/ugp/biz/service/impl/OrgServiceImpl.java
+11
-1
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/enums/OrgPersonEnum.java
View file @
a88304e9
...
@@ -3,18 +3,40 @@ package com.yeejoin.amos.boot.module.common.api.enums;
...
@@ -3,18 +3,40 @@ package com.yeejoin.amos.boot.module.common.api.enums;
import
lombok.AllArgsConstructor
;
import
lombok.AllArgsConstructor
;
import
lombok.Getter
;
import
lombok.Getter
;
import
java.util.HashMap
;
import
java.util.Map
;
@Getter
@Getter
@AllArgsConstructor
@AllArgsConstructor
public
enum
OrgPersonEnum
{
public
enum
OrgPersonEnum
{
公司
(
"COMPANY"
,
"244"
,
"公司"
),
公司
(
"COMPANY"
,
"244"
,
"公司"
,
1
),
部门
(
"DEPARTMENT"
,
"245"
,
"部门"
),
部门
(
"DEPARTMENT"
,
"245"
,
"部门"
,
2
),
人员
(
"PERSON"
,
"246"
,
"人员"
),
人员
(
"PERSON"
,
"246"
,
"人员"
,
3
),
焊工
(
"WELDER"
,
"247"
,
"焊工"
),
焊工
(
"WELDER"
,
"247"
,
"焊工"
,
3
),
企业管理员
(
"ADMIN"
,
"248"
,
"企业管理员"
);
建设单位负责人
(
"CHARGE"
,
"254"
,
"建设单位负责人"
,
3
),
企业管理员
(
"ADMIN"
,
"248"
,
"企业管理员"
,
3
),
建设单位
(
"CONSTRUCTION"
,
"249"
,
"建设单位"
,
1
),
安装单位
(
"INSTALL"
,
"250"
,
"安装单位"
,
1
),
设计单位
(
"DESIGN"
,
"251"
,
"设计单位"
,
1
),
监察单位
(
"SUPERVISION"
,
"252"
,
"监察单位"
,
1
),
监检机构
(
"MONITORING"
,
"253"
,
"监检机构"
,
1
);
private
String
key
;
private
String
key
;
private
String
code
;
private
String
code
;
private
String
name
;
private
String
name
;
/**
* 1 公司 2 部门 3 人员
*/
private
Integer
type
;
public
static
Map
map
=
new
HashMap
();
static
{
for
(
OrgPersonEnum
orgPersonEnum:
OrgPersonEnum
.
values
()){
map
.
put
(
orgPersonEnum
.
getName
(),
orgPersonEnum
.
getKey
());
}
}
}
}
amos-boot-system-ugp/amos-boot-module-ugp-biz/src/main/java/com/yeejoin/amos/boot/module/ugp/biz/controller/CompanyController.java
View file @
a88304e9
...
@@ -6,6 +6,7 @@ import com.alibaba.fastjson.JSONObject;
...
@@ -6,6 +6,7 @@ import com.alibaba.fastjson.JSONObject;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.yeejoin.amos.boot.biz.common.constants.CommonConstant
;
import
com.yeejoin.amos.boot.biz.common.constants.CommonConstant
;
import
com.yeejoin.amos.boot.module.common.api.dto.OrgUsrDto
;
import
com.yeejoin.amos.boot.module.common.api.dto.OrgUsrDto
;
import
com.yeejoin.amos.boot.module.common.api.enums.OrgPersonEnum
;
import
com.yeejoin.amos.boot.module.common.api.service.IOrgUsrService
;
import
com.yeejoin.amos.boot.module.common.api.service.IOrgUsrService
;
import
com.yeejoin.amos.boot.module.common.biz.service.impl.OrgUsrServiceImpl
;
import
com.yeejoin.amos.boot.module.common.biz.service.impl.OrgUsrServiceImpl
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.Company
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.Company
;
...
@@ -226,6 +227,11 @@ public class CompanyController extends BaseController {
...
@@ -226,6 +227,11 @@ public class CompanyController extends BaseController {
jsonObject
.
put
(
"amosOrgCode"
,
companyModelFeignClient
.
getOrgCode
());
jsonObject
.
put
(
"amosOrgCode"
,
companyModelFeignClient
.
getOrgCode
());
orgServiceImpl
.
dataHandling
(
jsonObject
,
bizOrgType
,
null
);
orgServiceImpl
.
dataHandling
(
jsonObject
,
bizOrgType
,
null
);
//企业管理员人员 动态表单存储
jsonObject
=
null
;
jsonObject
.
put
(
"name"
,
admin
);
jsonObject
.
put
(
"phone"
,
adminPhone
);
orgServiceImpl
.
dataHandling
(
jsonObject
,
OrgPersonEnum
.
企业管理员
.
getKey
(),
null
);
}
}
return
ResponseHelper
.
buildResponse
(
companyServiceImpl
.
updateById
(
company
));
return
ResponseHelper
.
buildResponse
(
companyServiceImpl
.
updateById
(
company
));
}
}
...
...
amos-boot-system-ugp/amos-boot-module-ugp-biz/src/main/java/com/yeejoin/amos/boot/module/ugp/biz/controller/ProjectController.java
View file @
a88304e9
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ugp
.
biz
.
controller
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ugp
.
biz
.
controller
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.yeejoin.amos.boot.module.common.api.entity.OrgUsr
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.Project
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.Project
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.OrgServiceImpl
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.ProjectInitiationServiceImpl
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.ProjectInitiationServiceImpl
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
@@ -38,6 +40,8 @@ public class ProjectController extends BaseController {
...
@@ -38,6 +40,8 @@ public class ProjectController extends BaseController {
ProjectServiceImpl
projectServiceImpl
;
ProjectServiceImpl
projectServiceImpl
;
@Autowired
@Autowired
ProjectInitiationServiceImpl
projectInitiationService
;
ProjectInitiationServiceImpl
projectInitiationService
;
@Autowired
OrgServiceImpl
orgServiceImpl
;
/**
/**
* 新增项目信息表
* 新增项目信息表
...
@@ -136,4 +140,16 @@ public class ProjectController extends BaseController {
...
@@ -136,4 +140,16 @@ public class ProjectController extends BaseController {
public
ResponseModel
<
List
<
JSONObject
>>
selectName
()
{
public
ResponseModel
<
List
<
JSONObject
>>
selectName
()
{
return
ResponseHelper
.
buildResponse
(
projectServiceImpl
.
selectName
());
return
ResponseHelper
.
buildResponse
(
projectServiceImpl
.
selectName
());
}
}
/**
* 获取下拉选择值
* @param type CHARGE("建设单位负责人")、INSTALL("安装单位")、DESIGN("设计单位")
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询下拉选择框的值"
,
notes
=
"查询下拉选择框的值"
)
@GetMapping
(
value
=
"/getSelectInfo"
)
public
ResponseModel
<
List
<
OrgUsr
>>
getSelectInfo
(
String
type
){
return
ResponseHelper
.
buildResponse
(
orgServiceImpl
.
getSelectInfo
(
type
));
}
}
}
amos-boot-system-ugp/amos-boot-module-ugp-biz/src/main/java/com/yeejoin/amos/boot/module/ugp/biz/service/impl/OrgServiceImpl.java
View file @
a88304e9
...
@@ -122,7 +122,7 @@ public class OrgServiceImpl {
...
@@ -122,7 +122,7 @@ public class OrgServiceImpl {
orgUsr
.
setBizOrgType
(
bizOrgType
);
orgUsr
.
setBizOrgType
(
bizOrgType
);
if
(
OrgPersonEnum
.
公司
.
getKey
().
equals
(
bizOrgType
)){
if
(
OrgPersonEnum
.
公司
.
getKey
().
equals
(
bizOrgType
)){
orgUsr
.
setOrgExpandAttr1
(
OrgPersonEnum
.
公司
.
getKey
(
));
orgUsr
.
setOrgExpandAttr1
(
jsonObject
.
getString
(
"type"
));
orgUsr
.
setBizOrgCode
(
jsonObject
.
getString
(
"creditCode"
));
orgUsr
.
setBizOrgCode
(
jsonObject
.
getString
(
"creditCode"
));
orgUsr
.
setAmosOrgId
(
jsonObject
.
getString
(
"amosOrgId"
));
orgUsr
.
setAmosOrgId
(
jsonObject
.
getString
(
"amosOrgId"
));
orgUsr
.
setAmosOrgCode
(
jsonObject
.
getString
(
"amosOrgCode"
));
orgUsr
.
setAmosOrgCode
(
jsonObject
.
getString
(
"amosOrgCode"
));
...
@@ -209,4 +209,14 @@ public class OrgServiceImpl {
...
@@ -209,4 +209,14 @@ public class OrgServiceImpl {
return
getInfo
(
String
.
valueOf
(
orgUsrServiceImpl
.
getOne
(
wrapper
).
getSequenceNbr
()));
return
getInfo
(
String
.
valueOf
(
orgUsrServiceImpl
.
getOne
(
wrapper
).
getSequenceNbr
()));
}
}
/**
* 获取下拉选择值
* @param type CHARGE("建设单位负责人")、INSTALL("安装单位")、DESIGN("设计单位")
* @return
*/
public
List
<
OrgUsr
>
getSelectInfo
(
String
type
){
LambdaQueryWrapper
<
OrgUsr
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
eq
(
OrgUsr
::
getOrgExpandAttr1
,
type
);
return
orgUsrServiceImpl
.
list
(
wrapper
);
}
}
}
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