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
3982ed9b
Commit
3982ed9b
authored
Sep 05, 2024
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.需求3005开发,下载汇总表时直接信息管理情况
parent
94a1b9bc
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
50 additions
and
7 deletions
+50
-7
JgUseRegistrationServiceImpl.java
...ule/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
+21
-7
CylinderBasicInformationSummary.ftl
...n/resources/templates/CylinderBasicInformationSummary.ftl
+0
-0
InformationManageTypeEnum.java
.../boot/module/ymt/api/enums/InformationManageTypeEnum.java
+29
-0
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
View file @
3982ed9b
...
@@ -40,10 +40,7 @@ import com.yeejoin.amos.boot.module.jg.biz.service.IIdxBizJgInspectionDetectionI
...
@@ -40,10 +40,7 @@ import com.yeejoin.amos.boot.module.jg.biz.service.IIdxBizJgInspectionDetectionI
import
com.yeejoin.amos.boot.module.jg.biz.utils.CodeUtil
;
import
com.yeejoin.amos.boot.module.jg.biz.utils.CodeUtil
;
import
com.yeejoin.amos.boot.module.ymt.api.common.StringUtil
;
import
com.yeejoin.amos.boot.module.ymt.api.common.StringUtil
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.*
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.*
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.ApplicationFormTypeEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.*
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.EquCodeTypeEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.EquimentEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.FlowStatusEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.*
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.*
;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
...
@@ -2079,14 +2076,29 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -2079,14 +2076,29 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
int
end
=
((
current
-
1
)
*
size
+
size
)
<
total
?
(
current
-
1
)
*
size
+
size
:
(
int
)
total
;
int
end
=
((
current
-
1
)
*
size
+
size
)
<
total
?
(
current
-
1
)
*
size
+
size
:
(
int
)
total
;
// 数据截取
// 数据截取
List
<
Object
>
equData
=
equipmentLists
.
subList
(
start
,
end
);
List
<
Object
>
equData
=
equipmentLists
.
subList
(
start
,
end
);
Map
<
String
,
String
>
recordInformationMap
=
this
.
getInformationManageInfo
(
equData
);
// 设备数据填充
// 设备数据填充
this
.
fillInCylinderEquData
(
exportParamsMap
,
equData
,
size
);
this
.
fillInCylinderEquData
(
exportParamsMap
,
equData
,
size
,
recordInformationMap
);
return
commonService
.
generateSummaryOfCylinderInfo
(
exportParamsMap
,
wordPath
,
filePrefix
);
return
commonService
.
generateSummaryOfCylinderInfo
(
exportParamsMap
,
wordPath
,
filePrefix
);
})).
collect
(
Collectors
.
toList
());
})).
collect
(
Collectors
.
toList
());
CompletableFuture
.
allOf
(
futures
.
toArray
(
new
CompletableFuture
[
page
])).
join
();
CompletableFuture
.
allOf
(
futures
.
toArray
(
new
CompletableFuture
[
page
])).
join
();
return
futures
;
return
futures
;
}
}
private
Map
<
String
,
String
>
getInformationManageInfo
(
List
<
Object
>
equData
)
{
List
<
String
>
records
=
new
ArrayList
<>();
equData
.
forEach
(
e
->{
JSONObject
jsonObject
=
(
JSONObject
)
e
;
String
record
=
jsonObject
.
getString
(
"record"
);
records
.
add
(
record
);
});
LambdaQueryWrapper
<
IdxBizJgOtherInfo
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
select
(
IdxBizJgOtherInfo:
:
getRecord
,
IdxBizJgOtherInfo:
:
getInformationSituation
);
wrapper
.
in
(
IdxBizJgOtherInfo:
:
getRecord
,
records
);
List
<
IdxBizJgOtherInfo
>
jgOtherInfos
=
otherInfoMapper
.
selectList
(
wrapper
);
return
jgOtherInfos
.
stream
().
collect
(
Collectors
.
toMap
(
IdxBizJgOtherInfo:
:
getRecord
,
d
->
InformationManageTypeEnum
.
getName
(
d
.
getInformationSituation
()),(
k1
,
k2
)
->
k2
));
}
/**
/**
* 压力管道数据
* 压力管道数据
*
*
...
@@ -2140,14 +2152,16 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -2140,14 +2152,16 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
/**
/**
* 气瓶设备数据填充
* 气瓶设备数据填充
*/
*/
p
ublic
void
fillInCylinderEquData
(
Map
<
String
,
Object
>
exportParamsMap
,
List
<
Object
>
equData
,
int
size
)
{
p
rivate
void
fillInCylinderEquData
(
Map
<
String
,
Object
>
exportParamsMap
,
List
<
Object
>
equData
,
int
size
,
Map
<
String
,
String
>
recordInformationMap
)
{
String
[]
fieldNames
=
{
"equDefineName"
,
"factoryNum"
,
"chargingMedium"
,
String
[]
fieldNames
=
{
"equDefineName"
,
"factoryNum"
,
"chargingMedium"
,
"produceUnitName"
,
"produceDate"
,
"nominalWorkingPressure"
,
"produceUnitName"
,
"produceDate"
,
"nominalWorkingPressure"
,
"singleBottleVolume"
,
"inspectDate"
,
"nextInspectDate"
,
"useInnerCode"
};
"singleBottleVolume"
,
"inspectDate"
,
"nextInspectDate"
,
"useInnerCode"
,
"informationSituation"
};
// 填充有效数据
// 填充有效数据
for
(
int
curr
=
0
;
curr
<
equData
.
size
();
curr
++)
{
for
(
int
curr
=
0
;
curr
<
equData
.
size
();
curr
++)
{
JSONObject
obj
=
(
JSONObject
)
equData
.
get
(
curr
);
JSONObject
obj
=
(
JSONObject
)
equData
.
get
(
curr
);
// 新增字段信息化管理情况
obj
.
put
(
"informationSituation"
,
recordInformationMap
.
get
(
obj
.
getString
(
"record"
)));
int
serialNum
=
curr
+
1
;
int
serialNum
=
curr
+
1
;
for
(
String
fieldName
:
fieldNames
)
{
for
(
String
fieldName
:
fieldNames
)
{
exportParamsMap
.
put
(
fieldName
+
serialNum
,
ValidationUtil
.
isEmpty
(
obj
.
get
(
fieldName
))
?
""
:
obj
.
get
(
fieldName
));
exportParamsMap
.
put
(
fieldName
+
serialNum
,
ValidationUtil
.
isEmpty
(
obj
.
get
(
fieldName
))
?
""
:
obj
.
get
(
fieldName
));
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/resources/templates/CylinderBasicInformationSummary.ftl
View file @
3982ed9b
This source diff could not be displayed because it is too large. You can
view the blob
instead.
amos-boot-system-tzs/amos-boot-module-ymt/amos-boot-module-ymt-api/src/main/java/com/yeejoin/amos/boot/module/ymt/api/enums/InformationManageTypeEnum.java
0 → 100644
View file @
3982ed9b
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ymt
.
api
.
enums
;
import
lombok.AllArgsConstructor
;
import
lombok.Getter
;
import
java.util.Arrays
;
import
java.util.Optional
;
@AllArgsConstructor
@Getter
public
enum
InformationManageTypeEnum
{
/**
* 信息化管理情况枚举
*/
TYPE_QR_CODE
(
"1"
,
"二维码"
),
TYPE_STAMP
(
"2"
,
"二维码"
),
TYPE_NO
(
"99"
,
"无"
);
private
String
code
;
private
String
name
;
public
static
String
getName
(
String
code
)
{
Optional
<
String
>
op
=
Arrays
.
stream
(
InformationManageTypeEnum
.
values
()).
filter
(
e
->
e
.
getCode
().
equals
(
code
)).
map
(
InformationManageTypeEnum:
:
getName
).
findFirst
();
return
op
.
orElse
(
""
);
}
}
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