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
a866e632
Commit
a866e632
authored
Oct 26, 2022
by
dqq
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改安装告知申请的新增,查看,修改
parent
661830c3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
41 additions
and
33 deletions
+41
-33
InstallNoticeDto.java
...eejoin/amos/boot/module/ugp/api/dto/InstallNoticeDto.java
+3
-0
InstallNoticeController.java
...ot/module/ugp/biz/controller/InstallNoticeController.java
+28
-30
InstallNoticeServiceImpl.java
...module/ugp/biz/service/impl/InstallNoticeServiceImpl.java
+10
-3
No files found.
amos-boot-system-ugp/amos-boot-module-ugp-api/src/main/java/com/yeejoin/amos/boot/module/ugp/api/dto/InstallNoticeDto.java
View file @
a866e632
...
@@ -54,4 +54,7 @@ public class InstallNoticeDto extends BaseDto {
...
@@ -54,4 +54,7 @@ public class InstallNoticeDto extends BaseDto {
@ApiModelProperty
(
value
=
"备注"
)
@ApiModelProperty
(
value
=
"备注"
)
private
String
remark
;
private
String
remark
;
@ApiModelProperty
(
value
=
"安装负责人"
)
private
String
installPri
;
}
}
amos-boot-system-ugp/amos-boot-module-ugp-biz/src/main/java/com/yeejoin/amos/boot/module/ugp/biz/controller/InstallNoticeController.java
View file @
a866e632
...
@@ -3,8 +3,10 @@ package com.yeejoin.amos.boot.module.ugp.biz.controller;
...
@@ -3,8 +3,10 @@ package com.yeejoin.amos.boot.module.ugp.biz.controller;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yeejoin.amos.boot.module.common.api.entity.OrgUsr
;
import
com.yeejoin.amos.boot.module.common.api.entity.OrgUsr
;
import
com.yeejoin.amos.boot.module.ugp.api.Enum.NoticeStatusEnum
;
import
com.yeejoin.amos.boot.module.ugp.api.Enum.NoticeStatusEnum
;
import
com.yeejoin.amos.boot.module.ugp.api.Enum.ProjectInitiationEnum
;
import
com.yeejoin.amos.boot.module.ugp.api.dto.*
;
import
com.yeejoin.amos.boot.module.ugp.api.dto.*
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.InstallNotice
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.InstallNotice
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.Project
;
import
com.yeejoin.amos.boot.module.ugp.api.entity.Project
;
...
@@ -20,12 +22,10 @@ import io.swagger.annotations.Api;
...
@@ -20,12 +22,10 @@ import io.swagger.annotations.Api;
import
org.springframework.web.bind.annotation.RestController
;
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.util.Date
;
import
java.util.*
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.InstallNoticeServiceImpl
;
import
com.yeejoin.amos.boot.module.ugp.biz.service.impl.InstallNoticeServiceImpl
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -195,23 +195,7 @@ public class InstallNoticeController extends BaseController {
...
@@ -195,23 +195,7 @@ public class InstallNoticeController extends BaseController {
@PostMapping
(
value
=
"/saveInstallNotice"
)
@PostMapping
(
value
=
"/saveInstallNotice"
)
@ApiOperation
(
httpMethod
=
"Post"
,
value
=
"新增安装告知申请"
,
notes
=
"新增安装告知申请"
)
@ApiOperation
(
httpMethod
=
"Post"
,
value
=
"新增安装告知申请"
,
notes
=
"新增安装告知申请"
)
public
ResponseModel
<
InstallNoticeDto
>
saveInstallNotice
(
@RequestBody
JSONObject
object
,
@RequestParam
(
required
=
false
)
String
noticeStatus
)
{
public
ResponseModel
<
InstallNoticeDto
>
saveInstallNotice
(
@RequestBody
JSONObject
object
,
@RequestParam
(
required
=
false
)
String
noticeStatus
)
{
InstallNoticeDto
installNoticeDto
=
new
InstallNoticeDto
();
InstallNoticeDto
installNoticeDto
=
installNoticeServiceImpl
.
saveInstallNotice
(
object
,
noticeStatus
);
final
ProjectDto
projectDto
=
projectServiceImpl
.
queryBySeq
(
object
.
getLong
(
"name"
));
installNoticeDto
.
setProjectId
(
object
.
getLong
(
"name"
));
installNoticeDto
.
setNoticeStatus
(
noticeStatus
);
installNoticeDto
.
setNoticeDate
(
new
Date
());
installNoticeDto
.
setApproved
(
false
);
installNoticeDto
.
setOrganizationCode
(
orgServiceImpl
.
getOrgUsr
().
getBizOrgCode
());
installNoticeDto
.
setLicenseNum
(
object
.
getString
(
"licenseNum"
));
installNoticeDto
.
setLicenseCompany
(
object
.
getString
(
"licenseCompany"
));
final
JSONArray
licenseAttch
=
object
.
getJSONArray
(
"licenseAttch"
);
final
JSONArray
contractAttch
=
object
.
getJSONArray
(
"contractAttch"
);
installNoticeDto
.
setLicenseAttch
(
JSON
.
toJSONString
(
licenseAttch
));
installNoticeDto
.
setContractAttch
(
JSON
.
toJSONString
(
contractAttch
));
projectInitiationServiceImpl
.
execute
(
projectDto
.
getInstanceId
(),
installNoticeDto
,
"1"
);
return
ResponseHelper
.
buildResponse
(
installNoticeServiceImpl
.
createWithModel
(
installNoticeDto
));
return
ResponseHelper
.
buildResponse
(
installNoticeServiceImpl
.
createWithModel
(
installNoticeDto
));
}
}
...
@@ -226,15 +210,7 @@ public class InstallNoticeController extends BaseController {
...
@@ -226,15 +210,7 @@ public class InstallNoticeController extends BaseController {
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr安装告知信息"
,
notes
=
"根据sequenceNbr安装告知信息"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr安装告知信息"
,
notes
=
"根据sequenceNbr安装告知信息"
)
public
ResponseModel
<
JSONObject
>
selectOneBySeq
(
@PathVariable
Long
sequenceNbr
)
{
public
ResponseModel
<
JSONObject
>
selectOneBySeq
(
@PathVariable
Long
sequenceNbr
)
{
final
InstallNoticeDto
installNoticeDto
=
installNoticeServiceImpl
.
selectOneById
(
sequenceNbr
);
JSONObject
jsonObject
=
installNoticeServiceImpl
.
selectOneBySeq
(
sequenceNbr
);
final
ProjectDto
projectDto
=
projectServiceImpl
.
queryBySeq
(
installNoticeDto
.
getProjectId
());
JSONObject
jsonObject
=
new
JSONObject
();
jsonObject
.
put
(
"name"
,
projectDto
.
getSequenceNbr
());
jsonObject
.
put
(
"installRegion"
,
projectDto
.
getInstallRegion
());
jsonObject
.
put
(
"licenseNum"
,
installNoticeDto
.
getLicenseNum
());
jsonObject
.
put
(
"licenseCompany"
,
installNoticeDto
.
getLicenseCompany
());
jsonObject
.
put
(
"licenseAttch"
,
JSON
.
parseArray
(
installNoticeDto
.
getLicenseAttch
()));
jsonObject
.
put
(
"contractAttch"
,
JSON
.
parseArray
(
installNoticeDto
.
getContractAttch
()));
return
ResponseHelper
.
buildResponse
(
jsonObject
);
return
ResponseHelper
.
buildResponse
(
jsonObject
);
}
}
...
@@ -259,6 +235,7 @@ public class InstallNoticeController extends BaseController {
...
@@ -259,6 +235,7 @@ public class InstallNoticeController extends BaseController {
installNoticeDto
.
setLicenseCompany
(
object
.
getString
(
"licenseCompany"
));
installNoticeDto
.
setLicenseCompany
(
object
.
getString
(
"licenseCompany"
));
final
JSONArray
licenseAttch
=
object
.
getJSONArray
(
"licenseAttch"
);
final
JSONArray
licenseAttch
=
object
.
getJSONArray
(
"licenseAttch"
);
final
JSONArray
contractAttch
=
object
.
getJSONArray
(
"contractAttch"
);
final
JSONArray
contractAttch
=
object
.
getJSONArray
(
"contractAttch"
);
installNoticeDto
.
setInstallPri
(
object
.
getString
(
"installPri"
));
installNoticeDto
.
setLicenseAttch
(
JSON
.
toJSONString
(
licenseAttch
));
installNoticeDto
.
setLicenseAttch
(
JSON
.
toJSONString
(
licenseAttch
));
installNoticeDto
.
setContractAttch
(
JSON
.
toJSONString
(
contractAttch
));
installNoticeDto
.
setContractAttch
(
JSON
.
toJSONString
(
contractAttch
));
...
@@ -286,6 +263,27 @@ public class InstallNoticeController extends BaseController {
...
@@ -286,6 +263,27 @@ public class InstallNoticeController extends BaseController {
}
}
/**
/**
* 查询当前登陆人所在单位下的可选告知申请的所有项目列表
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询当前登陆人所在单位下的所以项目列表"
,
notes
=
"查询当前登陆人所在单位下的所以项目列表"
)
@GetMapping
(
value
=
"/getProjects"
)
public
ResponseModel
<
List
<
Project
>>
getCompanyProjects
(){
Long
companyId
=
null
;
//获取当前登陆人所在单位id
companyId
=
orgServiceImpl
.
getCompanyId
();
if
(
ValidationUtil
.
isEmpty
(
companyId
)){
return
ResponseHelper
.
buildResponse
(
new
ArrayList
<>());
}
LambdaQueryWrapper
<
Project
>
wrapper
=
new
LambdaQueryWrapper
<
Project
>();
if
(!
ValidationUtil
.
isEmpty
(
companyId
))
{
wrapper
.
eq
(
Project:
:
getInstallationUnitId
,
companyId
).
eq
(
Project:
:
getStatus
,
ProjectInitiationEnum
.
告知申请
.
getName
());
}
return
ResponseHelper
.
buildResponse
(
projectServiceImpl
.
list
(
wrapper
));
}
/**
* 监察部门接受安装告知
* 监察部门接受安装告知
* @param sequenceNbr
* @param sequenceNbr
* @return
* @return
...
...
amos-boot-system-ugp/amos-boot-module-ugp-biz/src/main/java/com/yeejoin/amos/boot/module/ugp/biz/service/impl/InstallNoticeServiceImpl.java
View file @
a866e632
...
@@ -39,6 +39,10 @@ public class InstallNoticeServiceImpl extends BaseService<InstallNoticeDto,Insta
...
@@ -39,6 +39,10 @@ public class InstallNoticeServiceImpl extends BaseService<InstallNoticeDto,Insta
InstallNoticeMapper
installNoticeMapper
;
InstallNoticeMapper
installNoticeMapper
;
@Autowired
@Autowired
ProjectServiceImpl
projectServiceImpl
;
ProjectServiceImpl
projectServiceImpl
;
@Autowired
ProjectInitiationServiceImpl
projectInitiationServiceImpl
;
@Autowired
OrgServiceImpl
orgServiceImpl
;
/**
/**
* 分页查询
* 分页查询
*/
*/
...
@@ -88,19 +92,20 @@ public class InstallNoticeServiceImpl extends BaseService<InstallNoticeDto,Insta
...
@@ -88,19 +92,20 @@ public class InstallNoticeServiceImpl extends BaseService<InstallNoticeDto,Insta
public
InstallNoticeDto
saveInstallNotice
(
JSONObject
object
,
String
noticeStatus
)
{
public
InstallNoticeDto
saveInstallNotice
(
JSONObject
object
,
String
noticeStatus
)
{
InstallNoticeDto
installNoticeDto
=
new
InstallNoticeDto
();
InstallNoticeDto
installNoticeDto
=
new
InstallNoticeDto
();
//
final ProjectDto projectDto = projectServiceImpl.queryBySeq(object.getLong("name"));
final
ProjectDto
projectDto
=
projectServiceImpl
.
queryBySeq
(
object
.
getLong
(
"name"
));
installNoticeDto
.
setProjectId
(
object
.
getLong
(
"name"
));
installNoticeDto
.
setProjectId
(
object
.
getLong
(
"name"
));
installNoticeDto
.
setNoticeStatus
(
noticeStatus
);
installNoticeDto
.
setNoticeStatus
(
noticeStatus
);
installNoticeDto
.
setNoticeDate
(
new
Date
());
installNoticeDto
.
setNoticeDate
(
new
Date
());
installNoticeDto
.
setApproved
(
false
);
installNoticeDto
.
setApproved
(
false
);
// installNoticeDto.setOrganizationCode(orgServiceImpl.getOrgUsr().getBizOrgCode());
installNoticeDto
.
setInstallPri
(
object
.
getString
(
"installPri"
));
installNoticeDto
.
setOrganizationCode
(
orgServiceImpl
.
getOrgUsr
().
getBizOrgCode
());
installNoticeDto
.
setLicenseNum
(
object
.
getString
(
"licenseNum"
));
installNoticeDto
.
setLicenseNum
(
object
.
getString
(
"licenseNum"
));
installNoticeDto
.
setLicenseCompany
(
object
.
getString
(
"licenseCompany"
));
installNoticeDto
.
setLicenseCompany
(
object
.
getString
(
"licenseCompany"
));
final
JSONArray
licenseAttch
=
object
.
getJSONArray
(
"licenseAttch"
);
final
JSONArray
licenseAttch
=
object
.
getJSONArray
(
"licenseAttch"
);
final
JSONArray
contractAttch
=
object
.
getJSONArray
(
"contractAttch"
);
final
JSONArray
contractAttch
=
object
.
getJSONArray
(
"contractAttch"
);
installNoticeDto
.
setLicenseAttch
(
JSON
.
toJSONString
(
licenseAttch
));
installNoticeDto
.
setLicenseAttch
(
JSON
.
toJSONString
(
licenseAttch
));
installNoticeDto
.
setContractAttch
(
JSON
.
toJSONString
(
contractAttch
));
installNoticeDto
.
setContractAttch
(
JSON
.
toJSONString
(
contractAttch
));
//
projectInitiationServiceImpl.execute(projectDto.getInstanceId(),installNoticeDto,"1");
projectInitiationServiceImpl
.
execute
(
projectDto
.
getInstanceId
(),
installNoticeDto
,
"1"
);
return
installNoticeDto
;
return
installNoticeDto
;
}
}
...
@@ -120,6 +125,7 @@ public class InstallNoticeServiceImpl extends BaseService<InstallNoticeDto,Insta
...
@@ -120,6 +125,7 @@ public class InstallNoticeServiceImpl extends BaseService<InstallNoticeDto,Insta
jsonObject
.
put
(
"licenseCompany"
,
installNoticeDto
.
getLicenseCompany
());
jsonObject
.
put
(
"licenseCompany"
,
installNoticeDto
.
getLicenseCompany
());
jsonObject
.
put
(
"licenseAttch"
,
JSON
.
parseArray
(
installNoticeDto
.
getLicenseAttch
()));
jsonObject
.
put
(
"licenseAttch"
,
JSON
.
parseArray
(
installNoticeDto
.
getLicenseAttch
()));
jsonObject
.
put
(
"contractAttch"
,
JSON
.
parseArray
(
installNoticeDto
.
getContractAttch
()));
jsonObject
.
put
(
"contractAttch"
,
JSON
.
parseArray
(
installNoticeDto
.
getContractAttch
()));
jsonObject
.
put
(
"installPri"
,
installNoticeDto
.
getInstallPri
());
return
jsonObject
;
return
jsonObject
;
}
}
}
}
\ No newline at end of file
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