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
d7a6004d
Commit
d7a6004d
authored
Nov 20, 2025
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(jyjc):检验检测业务管理初始代码
1.初始代码提交
parent
4c1ca550
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
74 additions
and
13 deletions
+74
-13
JyjcBizManageModel.java
...n/amos/boot/module/jyjc/api/model/JyjcBizManageModel.java
+5
-0
JyjcBizManageController.java
...t/module/jyjc/biz/controller/JyjcBizManageController.java
+39
-7
JyjcBizManageServiceImpl.java
...odule/jyjc/biz/service/impl/JyjcBizManageServiceImpl.java
+30
-6
No files found.
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-api/src/main/java/com/yeejoin/amos/boot/module/jyjc/api/model/JyjcBizManageModel.java
View file @
d7a6004d
...
...
@@ -11,4 +11,9 @@ public class JyjcBizManageModel extends JyjcOpeningApplicationModel {
* 区域停(启)用状态
*/
private
String
areaStatus
;
/**
* 公司code
*/
private
String
companyCode
;
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/controller/JyjcBizManageController.java
View file @
d7a6004d
...
...
@@ -16,9 +16,10 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.util.List
;
import
java.util.Map
;
@RestController
@RequestMapping
@RequestMapping
(
value
=
"/jyjcBizManage"
)
@Api
(
tags
=
"检验检测业务管理"
)
@RequiredArgsConstructor
public
class
JyjcBizManageController
extends
BaseController
{
...
...
@@ -27,7 +28,7 @@ public class JyjcBizManageController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"检验检测机构开通业务列表
,分页"
,
notes
=
"检验检测机构开通业务列表,分页
"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"检验检测机构开通业务列表
分页-省市局使用"
,
notes
=
"检验检测机构开通业务分页-省市局使用
"
)
public
ResponseModel
<
IPage
<?>>
getManageList
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestBody
JyjcBizManageModel
model
)
{
...
...
@@ -39,14 +40,14 @@ public class JyjcBizManageController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{appSeq}/area-enable"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业区域启用
"
,
notes
=
"企业区域启
用"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业区域启用
-市局使用"
,
notes
=
"企业区域启用-市局使
用"
)
public
ResponseModel
<
Boolean
>
enableBatch
(
@PathVariable
String
appSeq
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
enable
(
appSeq
,
getSelectedOrgInfo
().
getCompany
()));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{appSeq}/area-disable"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业区域停用
"
,
notes
=
"企业区域停
用"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业区域停用
-市局使用"
,
notes
=
"企业区域停用-市局使
用"
)
public
ResponseModel
<
Boolean
>
disableBatch
(
@PathVariable
String
appSeq
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
disable
(
appSeq
,
getSelectedOrgInfo
().
getCompany
()));
}
...
...
@@ -54,19 +55,50 @@ public class JyjcBizManageController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/{appSeq}/licence-edit"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"资质停起用
"
,
notes
=
"资质停起
用"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"资质停起用
-省局使用"
,
notes
=
"资质停起用-省局使
用"
)
public
ResponseModel
<
Boolean
>
licenceEdit
(
@PathVariable
String
appSeq
,
@RequestBody
List
<
BaseUnitLicence
>
licences
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
licenceEdit
(
appSeq
,
licences
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{appSeq}/basic"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"开通基本信息"
,
notes
=
"开通基本信息"
)
public
ResponseModel
<
JyjcBizManageModel
>
getBasicInfo
(
@PathVariable
String
appSeq
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
getBasicInfo
(
appSeq
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{appSeq}/detail"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"开通详情"
,
notes
=
"开通详情"
)
public
ResponseModel
<
Map
<
String
,
Object
>>
getOne
(
@PathVariable
String
appSeq
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
licenceDetail
(
appSeq
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{appSeq}/licence-detail"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"资质详情
"
,
notes
=
"资质详情
"
)
public
ResponseModel
<
List
<
BaseUnitLicence
>>
licenceDetail
(
@PathVariable
String
appSeq
)
{
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"资质详情
-省局使用"
,
notes
=
"资质详情-省局使用
"
)
public
ResponseModel
<
Map
<
String
,
Object
>>
licenceDetail
(
@PathVariable
String
appSeq
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
licenceDetail
(
appSeq
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{appSeq}/expireDateEdit"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"业务有效期维护-省局使用"
,
notes
=
"业务有效期维护-省局使用"
)
public
ResponseModel
<
Boolean
>
expireDateEdit
(
@PathVariable
String
appSeq
,
@RequestParam
String
newExpiryDate
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
expireDateEdit
(
appSeq
,
newExpiryDate
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{appSeq}/detectionRegionEdit"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"开通区域维护-省局使用"
,
notes
=
"开通区域维护-省局使用"
)
public
ResponseModel
<
Boolean
>
detectionRegionEdit
(
@PathVariable
String
appSeq
,
@RequestParam
String
newDetectionRegion
)
{
return
ResponseHelper
.
buildResponse
(
jyjcBizManageService
.
detectionRegionEdit
(
appSeq
,
newDetectionRegion
));
}
}
amos-boot-system-tzs/amos-boot-module-jyjc/amos-boot-module-jyjc-biz/src/main/java/com/yeejoin/amos/boot/module/jyjc/biz/service/impl/JyjcBizManageServiceImpl.java
View file @
d7a6004d
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jyjc
.
biz
.
service
.
impl
;
import
cn.hutool.core.bean.BeanUtil
;
import
cn.hutool.core.date.DateUtil
;
import
com.alibaba.fastjson.JSONObject
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper
;
...
...
@@ -12,6 +13,7 @@ import com.yeejoin.amos.boot.module.common.api.dto.BaseEnterpriseCertDto;
import
com.yeejoin.amos.boot.module.jyjc.api.common.BizCommonConstant
;
import
com.yeejoin.amos.boot.module.jyjc.api.entity.JyjcInspectionHistory
;
import
com.yeejoin.amos.boot.module.jyjc.api.entity.JyjcOpeningApplication
;
import
com.yeejoin.amos.boot.module.jyjc.api.enums.OpenBizTypeEnumV2
;
import
com.yeejoin.amos.boot.module.jyjc.api.model.JyjcBizManageModel
;
import
com.yeejoin.amos.boot.module.jyjc.api.model.JyjcOpeningApplicationModel
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.BaseUnitLicence
;
...
...
@@ -26,10 +28,7 @@ import org.springframework.stereotype.Service;
import
org.typroject.tyboot.core.rdbms.orm.entity.BaseEntity
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
java.util.ArrayList
;
import
java.util.HashSet
;
import
java.util.List
;
import
java.util.Set
;
import
java.util.*
;
import
java.util.concurrent.TimeUnit
;
import
java.util.stream.Collectors
;
...
...
@@ -61,6 +60,8 @@ public class JyjcBizManageServiceImpl {
List
<
JyjcBizManageModel
>
manageModels
=
res
.
getRecords
().
stream
().
map
(
r
->
{
JyjcBizManageModel
bizManageModel
=
BeanUtil
.
copyProperties
(
r
,
JyjcBizManageModel
.
class
);
setAreaStatusByIdentify
(
company
,
r
,
bizManageModel
);
bizManageModel
.
setCompanyCode
(
company
.
getCompanyCode
());
bizManageModel
.
setOpenBizTypeName
(
Optional
.
of
(
OpenBizTypeEnumV2
.
getOneByCode
(
bizManageModel
.
getOpenBizType
())).
map
(
OpenBizTypeEnumV2:
:
getDescription
).
orElse
(
""
));
return
bizManageModel
;
}).
collect
(
Collectors
.
toList
());
page
.
setRecords
(
manageModels
);
...
...
@@ -168,7 +169,8 @@ public class JyjcBizManageServiceImpl {
return
Boolean
.
TRUE
;
}
public
List
<
BaseUnitLicence
>
licenceDetail
(
String
appSeq
)
{
public
Map
<
String
,
Object
>
licenceDetail
(
String
appSeq
)
{
Map
<
String
,
Object
>
res
=
new
HashMap
<>();
List
<
BaseUnitLicence
>
baseUnitLicences
=
new
ArrayList
<>();
JyjcOpeningApplication
openingApplication
=
openingApplicationService
.
getById
(
appSeq
);
JyjcInspectionHistory
history
=
inspectionHistoryService
.
getBySSeq
(
appSeq
);
...
...
@@ -183,6 +185,28 @@ public class JyjcBizManageServiceImpl {
}
});
}
return
baseUnitLicences
;
res
.
put
(
"licences"
,
baseUnitLicences
);
return
res
;
}
public
Boolean
expireDateEdit
(
String
appSeq
,
String
newExpiryDate
)
{
LambdaUpdateWrapper
<
JyjcOpeningApplication
>
updateWrapper
=
new
LambdaUpdateWrapper
<>();
updateWrapper
.
eq
(
BaseEntity:
:
getSequenceNbr
,
appSeq
);
updateWrapper
.
set
(
JyjcOpeningApplication:
:
getExpiryDate
,
DateUtil
.
parseDate
(
newExpiryDate
));
openingApplicationService
.
update
(
updateWrapper
);
return
Boolean
.
TRUE
;
}
public
Boolean
detectionRegionEdit
(
String
appSeq
,
String
newDetectionRegion
)
{
LambdaUpdateWrapper
<
JyjcOpeningApplication
>
updateWrapper
=
new
LambdaUpdateWrapper
<>();
updateWrapper
.
eq
(
BaseEntity:
:
getSequenceNbr
,
appSeq
);
updateWrapper
.
set
(
JyjcOpeningApplication:
:
getDetectionRegion
,
newDetectionRegion
);
openingApplicationService
.
update
(
updateWrapper
);
return
Boolean
.
TRUE
;
}
public
JyjcBizManageModel
getBasicInfo
(
String
appSeq
)
{
JyjcOpeningApplication
openingApplication
=
openingApplicationService
.
getById
(
appSeq
);
return
BeanUtil
.
copyProperties
(
openingApplication
,
JyjcBizManageModel
.
class
);
}
}
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