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
10b6f117
Commit
10b6f117
authored
Dec 16, 2021
by
kongfm
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
告知申请单部分接口
parent
cd760c5a
Hide whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
1193 additions
and
3 deletions
+1193
-3
TzsCommonParam.java
...eejoin/amos/boot/module/tzs/api/enums/TzsCommonParam.java
+2
-0
EquipmentInformDto.java
.../amos/boot/module/tzs/flc/api/dto/EquipmentInformDto.java
+133
-0
InformEquipmentDto.java
.../amos/boot/module/tzs/flc/api/dto/InformEquipmentDto.java
+93
-0
EquipmentInform.java
.../amos/boot/module/tzs/flc/api/entity/EquipmentInform.java
+223
-0
InformEquipment.java
.../amos/boot/module/tzs/flc/api/entity/InformEquipment.java
+163
-0
EquipmentInformStatusEnum.java
...t/module/tzs/flc/api/enums/EquipmentInformStatusEnum.java
+32
-0
EquipmentInformMapper.java
...boot/module/tzs/flc/api/mapper/EquipmentInformMapper.java
+14
-0
InformEquipmentMapper.java
...boot/module/tzs/flc/api/mapper/InformEquipmentMapper.java
+14
-0
UnitInfoMapper.java
...n/amos/boot/module/tzs/flc/api/mapper/UnitInfoMapper.java
+5
-0
IEquipmentInformService.java
...t/module/tzs/flc/api/service/IEquipmentInformService.java
+15
-0
IInformEquipmentService.java
...t/module/tzs/flc/api/service/IInformEquipmentService.java
+12
-0
IUnitInfoService.java
...mos/boot/module/tzs/flc/api/service/IUnitInfoService.java
+6
-0
EquipmentInformMapper.xml
...s-api/src/main/resources/mapper/EquipmentInformMapper.xml
+5
-0
InformEquipmentMapper.xml
...s-api/src/main/resources/mapper/InformEquipmentMapper.xml
+5
-0
UnitInfoMapper.xml
...dule-tzs-api/src/main/resources/mapper/UnitInfoMapper.xml
+11
-0
EquipmentInformController.java
...ule/tzs/flc/biz/controller/EquipmentInformController.java
+136
-0
InformEquipmentController.java
...ule/tzs/flc/biz/controller/InformEquipmentController.java
+116
-0
UnitInfoController.java
...oot/module/tzs/flc/biz/controller/UnitInfoController.java
+23
-0
UnitPersonController.java
...t/module/tzs/flc/biz/controller/UnitPersonController.java
+24
-1
EquipmentInformServiceImpl.java
.../tzs/flc/biz/service/impl/EquipmentInformServiceImpl.java
+99
-0
InformEquipmentServiceImpl.java
.../tzs/flc/biz/service/impl/InformEquipmentServiceImpl.java
+34
-0
UnitInfoServiceImpl.java
.../module/tzs/flc/biz/service/impl/UnitInfoServiceImpl.java
+11
-0
application.properties
...boot-system-tzs/src/main/resources/application.properties
+2
-2
tzs-1.0.0.0.xml
...ystem-tzs/src/main/resources/db/changelog/tzs-1.0.0.0.xml
+15
-0
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/api/enums/TzsCommonParam.java
View file @
10b6f117
...
...
@@ -46,5 +46,7 @@ public class TzsCommonParam {
public
static
final
String
LICENCE_INFO
=
"licenceInfo"
;
public
static
final
String
ATTACHMENT
=
"attachment"
;
public
static
final
String
INSPECTION_UNIT_CODE
=
"1044"
;
public
static
final
String
USE_UNIT_CODE
=
"1051"
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/EquipmentInformDto.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
dto
;
import
com.alibaba.excel.annotation.ExcelIgnore
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.yeejoin.amos.boot.module.common.api.dto.AttachmentDto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.Map
;
/**
* 设备告知单
*
* @author system_generator
* @date 2021-12-10
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@ApiModel
(
value
=
"EquipmentInformDto"
,
description
=
"设备告知单"
)
public
class
EquipmentInformDto
extends
BaseDto
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"施工告知编号"
)
private
String
productCode
;
@ApiModelProperty
(
value
=
"施工告知日期"
)
private
Date
productInformDate
;
@ApiModelProperty
(
value
=
"施工单位"
)
private
String
productUnit
;
@ApiModelProperty
(
value
=
"施工单位id"
)
private
Long
productUnitId
;
@ApiModelProperty
(
value
=
"施工类型"
)
private
String
productType
;
@ApiModelProperty
(
value
=
"施工类型code"
)
private
String
productTypeCode
;
@ApiModelProperty
(
value
=
"生产许可证编号"
)
private
String
licenceCode
;
@ApiModelProperty
(
value
=
"生产许可证有效期"
)
private
Date
licenceDate
;
@ApiModelProperty
(
value
=
"区域编码"
)
private
String
regionCode
;
@ApiModelProperty
(
value
=
"省"
)
private
String
province
;
@ApiModelProperty
(
value
=
"市"
)
private
String
city
;
@ApiModelProperty
(
value
=
"县区"
)
private
String
district
;
@ApiModelProperty
(
value
=
"街道"
)
private
String
stree
;
@ApiModelProperty
(
value
=
"小区"
)
private
String
community
;
@ApiModelProperty
(
value
=
"详细地址"
)
private
String
address
;
@ApiModelProperty
(
value
=
"经度"
)
private
String
longitude
;
@ApiModelProperty
(
value
=
"纬度"
)
private
String
latitude
;
@ApiModelProperty
(
value
=
"施工负责人"
)
private
String
principal
;
@ApiModelProperty
(
value
=
"施工负责人id"
)
private
Long
principalId
;
@ApiModelProperty
(
value
=
"施工负责人电话"
)
private
String
principalPhone
;
@ApiModelProperty
(
value
=
"计划施工日期"
)
private
Date
planProductDate
;
@ApiModelProperty
(
value
=
"接收机构"
)
private
String
acceptUnit
;
@ApiModelProperty
(
value
=
"接收机构id"
)
private
Long
acceptUnitId
;
@ApiModelProperty
(
value
=
"检验机构"
)
private
String
inspectonUnit
;
@ApiModelProperty
(
value
=
"检验机构id"
)
private
Long
inspectonUnitId
;
@ApiModelProperty
(
value
=
"使用单位"
)
private
String
useUnit
;
@ApiModelProperty
(
value
=
"使用单位id"
)
private
Long
useUnitId
;
@ApiModelProperty
(
value
=
"产权单位"
)
private
String
propertyUnit
;
@ApiModelProperty
(
value
=
"产权单位id"
)
private
Long
propertyUnitId
;
@ApiModelProperty
(
value
=
"使用场所"
)
private
String
useSite
;
@ApiModelProperty
(
value
=
"使用场所code"
)
private
String
useSiteCode
;
@ApiModelProperty
(
value
=
"告知书编号"
)
private
String
informCode
;
@ApiModelProperty
(
value
=
"告知单状态 0 暂存 1未接收 9已接收"
)
private
String
informStatus
;
@ExcelIgnore
@ApiModelProperty
(
value
=
"附件"
)
@TableField
(
exist
=
false
)
private
Map
<
String
,
List
<
AttachmentDto
>>
attachments
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/dto/InformEquipmentDto.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
dto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
java.util.Date
;
/**
* 告知申请-设备信息表
*
* @author system_generator
* @date 2021-12-10
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@ApiModel
(
value
=
"InformEquipmentDto"
,
description
=
"告知申请-设备信息表"
)
public
class
InformEquipmentDto
extends
BaseDto
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
value
=
"设备id"
)
private
String
equipId
;
@ApiModelProperty
(
value
=
"设备编号"
)
private
String
code
;
@ApiModelProperty
(
value
=
"设备名称"
)
private
String
name
;
@ApiModelProperty
(
value
=
"设备类别id"
)
private
Long
categoryId
;
@ApiModelProperty
(
value
=
"设备类别名称"
)
private
String
categoryName
;
@ApiModelProperty
(
value
=
"设备种类id"
)
private
Long
typeId
;
@ApiModelProperty
(
value
=
"设备种类名称"
)
private
String
typeName
;
@ApiModelProperty
(
value
=
"设备品种id"
)
private
Long
varietyId
;
@ApiModelProperty
(
value
=
"设备品种名称"
)
private
String
varietyName
;
@ApiModelProperty
(
value
=
"设备品牌"
)
private
String
brand
;
@ApiModelProperty
(
value
=
"规格型号"
)
private
String
model
;
@ApiModelProperty
(
value
=
"单位内部编号"
)
private
String
innerCode
;
@ApiModelProperty
(
value
=
"设计单位名称"
)
private
String
designUnitName
;
@ApiModelProperty
(
value
=
"制造单位名称"
)
private
String
manufacturer
;
@ApiModelProperty
(
value
=
"设计使用年限"
)
private
Integer
designLife
;
@ApiModelProperty
(
value
=
"出厂日期"
)
private
Date
factoryDate
;
@ApiModelProperty
(
value
=
"产品编号(出厂编号)"
)
private
String
productCode
;
@ApiModelProperty
(
value
=
"监督检验机构"
)
private
Long
supervisionAgency
;
@ApiModelProperty
(
value
=
"检验报告编号"
)
private
String
inspectionReportCode
;
@ApiModelProperty
(
value
=
"设备状态(未安装,已安装...)"
)
private
String
status
;
@ApiModelProperty
(
value
=
"设备所属单位id"
)
private
Long
equipUnitId
;
@ApiModelProperty
(
value
=
"设备所属单位"
)
private
String
equipUnit
;
@ApiModelProperty
(
value
=
"告知单id"
)
private
Long
informId
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/entity/EquipmentInform.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.yeejoin.amos.boot.biz.common.entity.BaseEntity
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.experimental.Accessors
;
import
java.util.Date
;
/**
* 设备告知单
*
* @author system_generator
* @date 2021-12-10
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@Accessors
(
chain
=
true
)
@TableName
(
"tz_equipment_inform"
)
public
class
EquipmentInform
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 施工告知编号
*/
@TableField
(
"product_code"
)
private
String
productCode
;
/**
* 施工告知日期
*/
@TableField
(
"product_inform_date"
)
private
Date
productInformDate
;
/**
* 施工单位
*/
@TableField
(
"product_unit"
)
private
String
productUnit
;
/**
* 施工单位id
*/
@TableField
(
"product_unit_id"
)
private
Long
productUnitId
;
/**
* 施工类型
*/
@TableField
(
"product_type"
)
private
String
productType
;
/**
* 施工类型code
*/
@TableField
(
"product_type_code"
)
private
String
productTypeCode
;
/**
* 生产许可证编号
*/
@TableField
(
"licence_code"
)
private
String
licenceCode
;
/**
* 生产许可证有效期
*/
@TableField
(
"licence_date"
)
private
Date
licenceDate
;
/**
* 区域编码
*/
@TableField
(
"region_code"
)
private
String
regionCode
;
/**
* 省
*/
@TableField
(
"province"
)
private
String
province
;
/**
* 市
*/
@TableField
(
"city"
)
private
String
city
;
/**
* 县区
*/
@TableField
(
"district"
)
private
String
district
;
/**
* 街道
*/
@TableField
(
"stree"
)
private
String
stree
;
/**
* 小区
*/
@TableField
(
"community"
)
private
String
community
;
/**
* 详细地址
*/
@TableField
(
"address"
)
private
String
address
;
/**
* 经度
*/
@TableField
(
"longitude"
)
private
String
longitude
;
/**
* 纬度
*/
@TableField
(
"latitude"
)
private
String
latitude
;
/**
* 施工负责人
*/
@TableField
(
"principal"
)
private
String
principal
;
/**
* 施工负责人id
*/
@TableField
(
"principal_id"
)
private
Long
principalId
;
/**
* 施工负责人电话
*/
@TableField
(
"principal_phone"
)
private
String
principalPhone
;
/**
* 计划施工日期
*/
@TableField
(
"plan_product_date"
)
private
Date
planProductDate
;
/**
* 接收机构
*/
@TableField
(
"accept_unit"
)
private
String
acceptUnit
;
/**
* 接收机构id
*/
@TableField
(
"accept_unit_id"
)
private
Long
acceptUnitId
;
/**
* 检验机构
*/
@TableField
(
"inspecton_unit"
)
private
String
inspectonUnit
;
/**
* 检验机构id
*/
@TableField
(
"inspecton_unit_id"
)
private
Long
inspectonUnitId
;
/**
* 使用单位
*/
@TableField
(
"use_unit"
)
private
String
useUnit
;
/**
* 使用单位id
*/
@TableField
(
"use_unit_id"
)
private
Long
useUnitId
;
/**
* 产权单位
*/
@TableField
(
"property_unit"
)
private
String
propertyUnit
;
/**
* 产权单位id
*/
@TableField
(
"property_unit_id"
)
private
Long
propertyUnitId
;
/**
* 使用场所
*/
@TableField
(
"use_site"
)
private
String
useSite
;
/**
* 使用场所code
*/
@TableField
(
"use_site_code"
)
private
String
useSiteCode
;
/**
* 告知书编号
*/
@TableField
(
"inform_code"
)
private
String
informCode
;
/**
* 告知单状态 0 暂存 1未接收 9已接收
*/
@TableField
(
"inform_status"
)
private
String
informStatus
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/entity/InformEquipment.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.yeejoin.amos.boot.biz.common.entity.BaseEntity
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.experimental.Accessors
;
import
java.util.Date
;
/**
* 告知申请-设备信息表
*
* @author system_generator
* @date 2021-12-10
*/
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@Accessors
(
chain
=
true
)
@TableName
(
"tcb_inform_equipment"
)
public
class
InformEquipment
extends
BaseEntity
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 设备id
*/
@TableField
(
"equip_id"
)
private
String
equipId
;
/**
* 设备编号
*/
@TableField
(
"code"
)
private
String
code
;
/**
* 设备名称
*/
@TableField
(
"name"
)
private
String
name
;
/**
* 设备类别id
*/
@TableField
(
"category_id"
)
private
Long
categoryId
;
/**
* 设备类别名称
*/
@TableField
(
"category_name"
)
private
String
categoryName
;
/**
* 设备种类id
*/
@TableField
(
"type_id"
)
private
Long
typeId
;
/**
* 设备种类名称
*/
@TableField
(
"type_name"
)
private
String
typeName
;
/**
* 设备品种id
*/
@TableField
(
"variety_id"
)
private
Long
varietyId
;
/**
* 设备品种名称
*/
@TableField
(
"variety_name"
)
private
String
varietyName
;
/**
* 设备品牌
*/
@TableField
(
"brand"
)
private
String
brand
;
/**
* 规格型号
*/
@TableField
(
"model"
)
private
String
model
;
/**
* 单位内部编号
*/
@TableField
(
"inner_code"
)
private
String
innerCode
;
/**
* 设计单位名称
*/
@TableField
(
"design_unit_name"
)
private
String
designUnitName
;
/**
* 制造单位名称
*/
@TableField
(
"manufacturer"
)
private
String
manufacturer
;
/**
* 设计使用年限
*/
@TableField
(
"design_life"
)
private
Integer
designLife
;
/**
* 出厂日期
*/
@TableField
(
"factory_date"
)
private
Date
factoryDate
;
/**
* 产品编号(出厂编号)
*/
@TableField
(
"product_code"
)
private
String
productCode
;
/**
* 监督检验机构
*/
@TableField
(
"supervision_agency"
)
private
Long
supervisionAgency
;
/**
* 检验报告编号
*/
@TableField
(
"inspection_report_code"
)
private
String
inspectionReportCode
;
/**
* 设备状态(未安装,已安装...)
*/
@TableField
(
"status"
)
private
String
status
;
/**
* 设备所属单位id
*/
@TableField
(
"equip_unit_id"
)
private
Long
equipUnitId
;
/**
* 设备所属单位
*/
@TableField
(
"equip_unit"
)
private
String
equipUnit
;
/**
* 告知单id
*/
@TableField
(
"inform_id"
)
private
Long
informId
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/enums/EquipmentInformStatusEnum.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
enums
;
import
lombok.Getter
;
/**
* 设备告知书状态枚举
*/
@Getter
public
enum
EquipmentInformStatusEnum
{
暂存
(
"0"
,
"暂存"
),
未接收
(
"1"
,
"未接收"
),
已接收
(
"2"
,
"已接收"
);
private
String
code
;
private
String
name
;
EquipmentInformStatusEnum
(
String
code
,
String
name
)
{
this
.
name
=
name
;
this
.
code
=
code
;
}
public
static
EquipmentInformStatusEnum
getByCode
(
String
code
)
{
for
(
EquipmentInformStatusEnum
statusEnum
:
EquipmentInformStatusEnum
.
values
())
{
if
(
statusEnum
.
getCode
().
equals
(
code
))
{
return
statusEnum
;
}
}
return
null
;
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/mapper/EquipmentInformMapper.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentInform
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* 设备告知单 Mapper 接口
*
* @author system_generator
* @date 2021-12-10
*/
public
interface
EquipmentInformMapper
extends
BaseMapper
<
EquipmentInform
>
{
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/mapper/InformEquipmentMapper.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.InformEquipment
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* 告知申请-设备信息表 Mapper 接口
*
* @author system_generator
* @date 2021-12-10
*/
public
interface
InformEquipmentMapper
extends
BaseMapper
<
InformEquipment
>
{
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/mapper/UnitInfoMapper.java
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.UnitInfoDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.UnitInfo
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
* 企业信息表 Mapper 接口
...
...
@@ -11,4 +15,5 @@ import com.yeejoin.amos.boot.module.tzs.flc.api.entity.UnitInfo;
*/
public
interface
UnitInfoMapper
extends
BaseMapper
<
UnitInfo
>
{
List
<
UnitInfoDto
>
getUnitByType
(
@Param
(
"typeCode"
)
String
typeCode
);
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/service/IEquipmentInformService.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
service
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentInformDto
;
/**
* 设备告知单接口类
*
* @author system_generator
* @date 2021-12-10
*/
public
interface
IEquipmentInformService
{
EquipmentInformDto
createEquipmentInform
(
EquipmentInformDto
model
);
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/service/IInformEquipmentService.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
api
.
service
;
/**
* 告知申请-设备信息表接口类
*
* @author system_generator
* @date 2021-12-10
*/
public
interface
IInformEquipmentService
{
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/api/service/IUnitInfoService.java
View file @
10b6f117
...
...
@@ -6,6 +6,8 @@ import com.yeejoin.amos.boot.module.tzs.flc.api.dto.UnitInfoDto;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.UnitInfo
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.UnitInfoChange
;
import
java.util.List
;
/**
* 企业信息表接口类
*
...
...
@@ -32,4 +34,8 @@ public interface IUnitInfoService {
UnitInfoDto
getDtoByOrgId
(
Long
sequenceNbr
);
UnitInfoDto
changeUnInfo
(
UnitInfoDto
model
);
List
<
UnitInfoDto
>
getInspectionUnit
();
List
<
UnitInfoDto
>
getUseUnit
();
}
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/resources/mapper/EquipmentInformMapper.xml
0 → 100644
View file @
10b6f117
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.boot.module.tzs.flc.api.mapper.EquipmentInformMapper"
>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/resources/mapper/InformEquipmentMapper.xml
0 → 100644
View file @
10b6f117
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.boot.module.tzs.flc.api.mapper.InformEquipmentMapper"
>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-tzs-api/src/main/resources/mapper/UnitInfoMapper.xml
View file @
10b6f117
...
...
@@ -2,4 +2,15 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.boot.module.tzs.flc.api.mapper.UnitInfoMapper"
>
<select
id=
"getUnitByType"
resultType=
"com.yeejoin.amos.boot.module.tzs.flc.api.dto.UnitInfoDto"
>
select
a.*
from tz_flc_unit_info a
where a.is_delete = 0 AND
(a.unit_status = '1' or a.is_change = 1)
AND a.unit_type_code LIKE CONCAT('%', #{typeCode}, '%')
</select>
</mapper>
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/EquipmentInformController.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
controller
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yeejoin.amos.boot.biz.common.utils.DateUtils
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentInform
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.Api
;
import
org.springframework.web.bind.annotation.RestController
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
java.util.List
;
import
com.yeejoin.amos.boot.module.tzs.flc.biz.service.impl.EquipmentInformServiceImpl
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
javax.servlet.http.HttpServletRequest
;
import
org.springframework.web.bind.annotation.*
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentInformDto
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
/**
* 设备告知单
*
* @author system_generator
* @date 2021-12-10
*/
@RestController
@Api
(
tags
=
"设备告知单Api"
)
@RequestMapping
(
value
=
"/equipment-inform"
)
public
class
EquipmentInformController
extends
BaseController
{
@Autowired
EquipmentInformServiceImpl
equipmentInformServiceImpl
;
/**
* 根据regionCode 获取设备告知单单号
* @param regionCode
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/getInformCode/{regionCode}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据regionCode 获取设备告知单单号"
,
notes
=
"根据regionCode 获取设备告知单单号"
)
public
ResponseModel
<
String
>
getInformCode
(
@PathVariable
String
regionCode
)
{
// 行政编码 + 年月 + 顺序号
String
code
=
regionCode
+
DateUtils
.
getDateNowShortNumber
();
int
number
=
equipmentInformServiceImpl
.
count
(
new
LambdaQueryWrapper
<
EquipmentInform
>().
like
(
EquipmentInform:
:
getProductCode
,
code
));
String
numberStr
=
String
.
format
(
"%04d"
,
number
);
code
+=
numberStr
;
return
ResponseHelper
.
buildResponse
(
code
);
}
/**
* 新增设备告知单
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增设备告知单"
,
notes
=
"新增设备告知单"
)
public
ResponseModel
<
EquipmentInformDto
>
save
(
@RequestBody
EquipmentInformDto
model
)
{
model
=
equipmentInformServiceImpl
.
createEquipmentInform
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr更新
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新设备告知单"
,
notes
=
"根据sequenceNbr更新设备告知单"
)
public
ResponseModel
<
EquipmentInformDto
>
updateBySequenceNbrEquipmentInform
(
@RequestBody
EquipmentInformDto
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
model
.
setSequenceNbr
(
sequenceNbr
);
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
updateWithModel
(
model
));
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除设备告知单"
,
notes
=
"根据sequenceNbr删除设备告知单"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
HttpServletRequest
request
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
){
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
removeById
(
sequenceNbr
));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个设备告知单"
,
notes
=
"根据sequenceNbr查询单个设备告知单"
)
public
ResponseModel
<
EquipmentInformDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"设备告知单分页查询"
,
notes
=
"设备告知单分页查询"
)
public
ResponseModel
<
Page
<
EquipmentInformDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
Page
<
EquipmentInformDto
>
page
=
new
Page
<
EquipmentInformDto
>();
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
queryForEquipmentInformPage
(
page
));
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"设备告知单列表全部数据查询"
,
notes
=
"设备告知单列表全部数据查询"
)
@GetMapping
(
value
=
"/list"
)
public
ResponseModel
<
List
<
EquipmentInformDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
equipmentInformServiceImpl
.
queryForEquipmentInformList
());
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/InformEquipmentController.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
controller
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.Api
;
import
org.springframework.web.bind.annotation.RestController
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
java.util.List
;
import
com.yeejoin.amos.boot.module.tzs.flc.biz.service.impl.InformEquipmentServiceImpl
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
javax.servlet.http.HttpServletRequest
;
import
org.springframework.web.bind.annotation.*
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.InformEquipmentDto
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
/**
* 告知申请-设备信息表
*
* @author system_generator
* @date 2021-12-10
*/
@RestController
@Api
(
tags
=
"告知申请-设备信息表Api"
)
@RequestMapping
(
value
=
"/inform-equipment"
)
public
class
InformEquipmentController
extends
BaseController
{
@Autowired
InformEquipmentServiceImpl
informEquipmentServiceImpl
;
/**
* 新增告知申请-设备信息表
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增告知申请-设备信息表"
,
notes
=
"新增告知申请-设备信息表"
)
public
ResponseModel
<
InformEquipmentDto
>
save
(
@RequestBody
InformEquipmentDto
model
)
{
model
=
informEquipmentServiceImpl
.
createWithModel
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr更新
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新告知申请-设备信息表"
,
notes
=
"根据sequenceNbr更新告知申请-设备信息表"
)
public
ResponseModel
<
InformEquipmentDto
>
updateBySequenceNbrInformEquipment
(
@RequestBody
InformEquipmentDto
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
model
.
setSequenceNbr
(
sequenceNbr
);
return
ResponseHelper
.
buildResponse
(
informEquipmentServiceImpl
.
updateWithModel
(
model
));
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除告知申请-设备信息表"
,
notes
=
"根据sequenceNbr删除告知申请-设备信息表"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
HttpServletRequest
request
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
){
return
ResponseHelper
.
buildResponse
(
informEquipmentServiceImpl
.
removeById
(
sequenceNbr
));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个告知申请-设备信息表"
,
notes
=
"根据sequenceNbr查询单个告知申请-设备信息表"
)
public
ResponseModel
<
InformEquipmentDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
informEquipmentServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"告知申请-设备信息表分页查询"
,
notes
=
"告知申请-设备信息表分页查询"
)
public
ResponseModel
<
Page
<
InformEquipmentDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
Page
<
InformEquipmentDto
>
page
=
new
Page
<
InformEquipmentDto
>();
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
informEquipmentServiceImpl
.
queryForInformEquipmentPage
(
page
));
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"告知申请-设备信息表列表全部数据查询"
,
notes
=
"告知申请-设备信息表列表全部数据查询"
)
@GetMapping
(
value
=
"/list"
)
public
ResponseModel
<
List
<
InformEquipmentDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
informEquipmentServiceImpl
.
queryForInformEquipmentList
());
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/UnitInfoController.java
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
controller
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
...
...
@@ -447,6 +448,28 @@ public class UnitInfoController extends BaseController {
}
/**
* 获取检验机构列表
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/getInspectionUnit"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"获取检验机构列表"
,
notes
=
"获取检验机构列表"
)
public
ResponseModel
<
List
<
UnitInfoDto
>>
getInspectionUnit
()
{
List
<
UnitInfoDto
>
result
=
unitInfoServiceImpl
.
getInspectionUnit
();
return
ResponseHelper
.
buildResponse
(
result
);
}
/**
* 获取使用单位列表
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/getUseUnit"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"获取使用单位列表"
,
notes
=
"获取使用单位列表"
)
public
ResponseModel
<
List
<
UnitInfoDto
>>
getUseUnit
()
{
List
<
UnitInfoDto
>
result
=
unitInfoServiceImpl
.
getUseUnit
();
return
ResponseHelper
.
buildResponse
(
result
);
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/controller/UnitPersonController.java
View file @
10b6f117
...
...
@@ -45,6 +45,7 @@ import javax.servlet.http.HttpServletRequest;
import
java.util.ArrayList
;
import
java.util.Arrays
;
import
java.util.Collection
;
import
java.util.HashMap
;
import
java.util.HashSet
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -189,7 +190,7 @@ public class UnitPersonController extends BaseController {
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/listMyUnitPerson"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"
根据当前登录人获取人员信息 带分页搜索"
,
notes
=
"
根据当前登录人获取人员信息 带分页搜索"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"
企业端-根据当前登录人获取人员信息 带分页搜索"
,
notes
=
"企业端-
根据当前登录人获取人员信息 带分页搜索"
)
public
ResponseModel
<
Object
>
listMyUnitPerson
(
@RequestParam
(
required
=
false
)
Map
<
String
,
Object
>
requestBody
)
{
List
<
Long
>
unitIds
=
getMyUnitList
();
List
<
Long
>
parentIds
=
new
ArrayList
<>();
...
...
@@ -205,6 +206,28 @@ public class UnitPersonController extends BaseController {
return
ResponseHelper
.
buildResponse
(
iUnitPersonService
.
pagePerson
(
parentIds
,
requestBody
.
get
(
"pageNum"
).
toString
(),
requestBody
.
get
(
"pageSize"
).
toString
(),
requestBody
));
}
/**
* 企业端-根据当前登录人获取人员信息不分页
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/listMyUnitPersonAll"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"企业端-根据当前登录人获取人员信息不分页"
,
notes
=
"企业端-据当前登录人获取人员信息不分页"
)
public
ResponseModel
<
Object
>
listMyUnitPerson
()
{
List
<
Long
>
unitIds
=
getMyUnitList
();
List
<
Long
>
parentIds
=
new
ArrayList
<>();
unitIds
.
stream
().
forEach
(
id
->
{
OrgUsr
unit
=
iOrgUsrService
.
getOne
(
new
LambdaQueryWrapper
<
OrgUsr
>().
eq
(
OrgUsr:
:
getIsDelete
,
false
).
eq
(
OrgUsr:
:
getAmosOrgId
,
id
));
if
(
unit
!=
null
)
{
parentIds
.
add
(
unit
.
getSequenceNbr
());
}
});
if
(
parentIds
.
size
()
==
0
)
{
parentIds
.
add
(-
1
l
);
}
return
ResponseHelper
.
buildResponse
(
iUnitPersonService
.
pagePerson
(
parentIds
,
"1"
,
Integer
.
MAX_VALUE
+
""
,
new
HashMap
<
String
,
Object
>()));
}
/**
* 获取本单位拥有的角色信息
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/EquipmentInformServiceImpl.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
service
.
impl
;
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.biz.service.impl.OrgUsrServiceImpl
;
import
com.yeejoin.amos.boot.module.common.biz.service.impl.SourceFileServiceImpl
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentIndexDto
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.EquipmentInform
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.enums.EquipmentInformStatusEnum
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.enums.EquipmentStatusEnum
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.mapper.EquipmentInformMapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IEquipmentInformService
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.EquipmentInformDto
;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.springframework.stereotype.Service
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
java.util.Date
;
import
java.util.List
;
/**
* 设备告知单服务实现类
*
* @author system_generator
* @date 2021-12-10
*/
@Service
public
class
EquipmentInformServiceImpl
extends
BaseService
<
EquipmentInformDto
,
EquipmentInform
,
EquipmentInformMapper
>
implements
IEquipmentInformService
{
@Autowired
SourceFileServiceImpl
sourceFileService
;
@Autowired
OrgUsrServiceImpl
iOrgUsrService
;
/**
* 分页查询
*/
public
Page
<
EquipmentInformDto
>
queryForEquipmentInformPage
(
Page
<
EquipmentInformDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
}
/**
* 列表查询 示例
*/
public
List
<
EquipmentInformDto
>
queryForEquipmentInformList
()
{
return
this
.
queryForList
(
""
,
false
);
}
@Override
public
EquipmentInformDto
createEquipmentInform
(
EquipmentInformDto
model
)
{
// 获取用户所在单位 保存施工单位所属信息
OrgUsr
myUnit
=
null
;
AgencyUserModel
user
=
Privilege
.
agencyUserClient
.
getme
().
getResult
();
List
<
CompanyModel
>
companys
=
user
.
getCompanys
();
for
(
CompanyModel
c
:
companys
)
{
myUnit
=
iOrgUsrService
.
getOne
(
new
LambdaQueryWrapper
<
OrgUsr
>().
eq
(
OrgUsr:
:
getIsDelete
,
false
).
eq
(
OrgUsr:
:
getAmosOrgId
,
c
.
getSequenceNbr
()));
}
if
(
myUnit
==
null
)
{
throw
new
BadRequest
(
"该用户非施工单位人员无法创建告知单"
);
}
// 判断是暂存还是提交
if
(
EquipmentInformStatusEnum
.
未接收
.
getCode
().
equals
(
model
.
getInformStatus
()))
{
// 提交判断日期
if
(
model
.
getPlanProductDate
()
==
null
)
{
throw
new
BadRequest
(
"未填写计划施工日期"
);
}
if
((
model
.
getPlanProductDate
().
getTime
()
-
System
.
currentTimeMillis
()
)
<
3
*
24
*
60
*
60
*
1000
)
{
throw
new
BadRequest
(
"计划施工日期比现在时间至少提前3天"
);
}
}
model
.
setProductInformDate
(
new
Date
());
model
.
setProductUnitId
(
myUnit
.
getSequenceNbr
());
model
.
setProductUnit
(
myUnit
.
getBizOrgName
());
model
=
this
.
createWithModel
(
model
);
saveSourceFile
(
model
);
return
model
;
}
// 保存附件信息
public
void
saveSourceFile
(
EquipmentInformDto
model
)
{
if
(
model
.
getAttachments
()
!=
null
)
{
sourceFileService
.
saveAttachments
(
model
.
getSequenceNbr
(),
model
.
getAttachments
());
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/InformEquipmentServiceImpl.java
0 → 100644
View file @
10b6f117
package
com
.
yeejoin
.
amos
.
boot
.
module
.
tzs
.
flc
.
biz
.
service
.
impl
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.entity.InformEquipment
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.mapper.InformEquipmentMapper
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.service.IInformEquipmentService
;
import
com.yeejoin.amos.boot.module.tzs.flc.api.dto.InformEquipmentDto
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.springframework.stereotype.Service
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
java.util.List
;
/**
* 告知申请-设备信息表服务实现类
*
* @author system_generator
* @date 2021-12-10
*/
@Service
public
class
InformEquipmentServiceImpl
extends
BaseService
<
InformEquipmentDto
,
InformEquipment
,
InformEquipmentMapper
>
implements
IInformEquipmentService
{
/**
* 分页查询
*/
public
Page
<
InformEquipmentDto
>
queryForInformEquipmentPage
(
Page
<
InformEquipmentDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
}
/**
* 列表查询 示例
*/
public
List
<
InformEquipmentDto
>
queryForInformEquipmentList
()
{
return
this
.
queryForList
(
""
,
false
);
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-tzs-biz/src/main/java/com/yeejoin/amos/boot/module/tzs/flc/biz/service/impl/UnitInfoServiceImpl.java
View file @
10b6f117
...
...
@@ -546,4 +546,14 @@ public class UnitInfoServiceImpl extends BaseService<UnitInfoDto, UnitInfo, Unit
return
unitChangeInfoToDto
(
targetInfo
);
}
@Override
public
List
<
UnitInfoDto
>
getInspectionUnit
()
{
return
baseMapper
.
getUnitByType
(
TzsCommonParam
.
INSPECTION_UNIT_CODE
);
}
@Override
public
List
<
UnitInfoDto
>
getUseUnit
()
{
return
baseMapper
.
getUnitByType
(
TzsCommonParam
.
USE_UNIT_CODE
);
}
}
\ No newline at end of file
amos-boot-system-tzs/src/main/resources/application.properties
View file @
10b6f117
spring.application.name
=
TZS
spring.application.name
=
TZS
-kfm
server.servlet.context-path
=
/tzs
server.port
=
11000
spring.profiles.active
=
dev
spring.profiles.active
=
jd
spring.jackson.time-zone
=
GMT+8
spring.jackson.date-format
=
yyyy-MM-dd HH:mm:ss
...
...
amos-boot-system-tzs/src/main/resources/db/changelog/tzs-1.0.0.0.xml
View file @
10b6f117
...
...
@@ -479,6 +479,21 @@
</changeSet>
<changeSet
author=
"kongfm"
id=
"2021-12-16-01"
>
<preConditions
onFail=
"MARK_RAN"
>
<sqlCheck
expectedResult=
"0"
>
select count(*) from cb_data_dictionary where sequence_nbr = 1107
</sqlCheck>
</preConditions>
<comment>
add data_dictionary inform
</comment>
<sql>
INSERT INTO `cb_data_dictionary` (`sequence_nbr`, `code`, `name`, `type`, `type_desc`, `parent`, `rec_user_name`, `rec_user_id`, `rec_date`, `is_delete`, `sort_num`) VALUES (1107, '1107', '安装', 'BUILD_TYPE', NULL, NULL, NULL, NULL, NULL, b'0', 1);
INSERT INTO `cb_data_dictionary` (`sequence_nbr`, `code`, `name`, `type`, `type_desc`, `parent`, `rec_user_name`, `rec_user_id`, `rec_date`, `is_delete`, `sort_num`) VALUES (1108, '1108', '改造', 'BUILD_TYPE', NULL, NULL, NULL, NULL, NULL, b'0', 1);
INSERT INTO `cb_data_dictionary` (`sequence_nbr`, `code`, `name`, `type`, `type_desc`, `parent`, `rec_user_name`, `rec_user_id`, `rec_date`, `is_delete`, `sort_num`) VALUES (1109, '1109', '维修', 'BUILD_TYPE', NULL, NULL, NULL, NULL, NULL, b'0', 1);
INSERT INTO `cb_data_dictionary` (`sequence_nbr`, `code`, `name`, `type`, `type_desc`, `parent`, `rec_user_name`, `rec_user_id`, `rec_date`, `is_delete`, `sort_num`) VALUES (1110, '1110', '移装', 'BUILD_TYPE', NULL, NULL, NULL, NULL, NULL, b'0', 1);
</sql>
</changeSet>
</databaseChangeLog>
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