Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hp-smart
Overview
Overview
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
platform
hp-smart
Commits
da554616
Commit
da554616
authored
Apr 23, 2024
by
宋祥
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev-sx' of
http://git.pseer.com/platform/hp-smart
into dev
parents
7d1e9cfd
e7a56aad
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
6 deletions
+20
-6
ServiceHPSC003.java
.../java/com/baosight/hpjx/hp/sc/service/ServiceHPSC003.java
+20
-5
HPSCTools.java
src/main/java/com/baosight/hpjx/hp/sc/tools/HPSCTools.java
+0
-1
No files found.
src/main/java/com/baosight/hpjx/hp/sc/service/ServiceHPSC003.java
View file @
da554616
...
@@ -29,6 +29,7 @@ import com.baosight.iplat4j.core.exception.PlatException;
...
@@ -29,6 +29,7 @@ import com.baosight.iplat4j.core.exception.PlatException;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.core.web.threadlocal.UserSession
;
import
com.baosight.iplat4j.core.web.threadlocal.UserSession
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
import
org.apache.commons.collections.CollectionUtils
;
import
java.text.SimpleDateFormat
;
import
java.text.SimpleDateFormat
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
...
@@ -37,6 +38,7 @@ import java.util.Date;
...
@@ -37,6 +38,7 @@ import java.util.Date;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
/**
/**
*
*
...
@@ -294,20 +296,33 @@ public class ServiceHPSC003 extends ServiceBase {
...
@@ -294,20 +296,33 @@ public class ServiceHPSC003 extends ServiceBase {
*/
*/
public
EiInfo
qrcodePlanDetail
(
EiInfo
inInfo
)
{
public
EiInfo
qrcodePlanDetail
(
EiInfo
inInfo
)
{
try
{
try
{
Map
queryRow
=
EiInfoUtils
.
getFirstRow
(
inInfo
);
String
planInfoNo
=
inInfo
.
getString
(
HPSC003
.
FIELD_PLAN_INFO_NO
);
String
planInfoNo
=
MapUtils
.
getString
(
queryRow
,
HPSC003
.
FIELD_PLAN_INFO_NO
);
AssertUtils
.
isNull
(
planInfoNo
,
"计划号不能为空"
);
AssertUtils
.
isNull
(
planInfoNo
,
"计划号不能为空"
);
// 查询计划主信息
// 查询计划主信息
HPSC003
dbSc003
=
HPSCTools
.
HpSc003
.
getByNo
(
planInfoNo
);
HPSC003
dbSc003
=
HPSCTools
.
HpSc003
.
getByNo
(
planInfoNo
);
EiInfoUtils
.
addBlock
(
inInfo
,
"planMain"
,
dbSc003
,
HPSC003
.
class
);
// 查询计划明细信息
// 查询计划明细信息
List
<
HPSC004
>
dbSc004s
=
HPSCTools
.
HpSc004
.
queryByParent
(
dbSc003
.
getPlanInfoNo
());
List
<
HPSC004
>
dbSc004s
=
HPSCTools
.
HpSc004
.
queryByParent
(
dbSc003
.
getPlanInfoNo
());
EiInfoUtils
.
addBlock
(
inInfo
,
"planDetail"
,
dbSc004s
,
HPSC004
.
class
);
List
<
Map
>
dbSc004Maps
=
dbSc004s
.
stream
().
map
(
HPSC004:
:
toMap
).
collect
(
Collectors
.
toList
()
);
// 订单号
// 订单号
List
<
String
>
prodOrderNos
=
ObjectUtils
.
listEpKey
(
dbSc004s
,
HPSC004
.
FIELD_PROD_ORDER_NO
);
List
<
String
>
prodOrderNos
=
ObjectUtils
.
listEpKey
(
dbSc004s
,
HPSC004
.
FIELD_PROD_ORDER_NO
);
// 查询派工信息
// 查询派工信息
List
<
HPSC005B
>
dbSc005bs
=
HPSCTools
.
HpSc005b
.
listByOrder
(
prodOrderNos
);
List
<
HPSC005B
>
dbSc005bs
=
HPSCTools
.
HpSc005b
.
listByOrder
(
prodOrderNos
);
EiInfoUtils
.
addBlock
(
inInfo
,
"prodOrder"
,
dbSc005bs
,
HPSC005B
.
class
);
// 填充数据
Map
<
String
,
List
<
HPSC005B
>>
dbSc005bMap
=
dbSc005bs
.
stream
()
.
collect
(
Collectors
.
groupingBy
(
HPSC005B:
:
getProdOrderNo
));
for
(
Map
dbSc004Map
:
dbSc004Maps
)
{
String
prodOrderNo
=
MapUtils
.
getString
(
dbSc004Map
,
HPSC004
.
FIELD_PROD_ORDER_NO
);
List
<
HPSC005B
>
dbSc005Items
=
dbSc005bMap
.
get
(
prodOrderNo
);
if
(
CollectionUtils
.
isNotEmpty
(
dbSc005Items
))
{
dbSc004Map
.
put
(
"prodOrders"
,
dbSc005Items
.
stream
().
map
(
HPSC005B:
:
toMap
)
.
collect
(
Collectors
.
toList
()));
}
else
{
dbSc004Map
.
put
(
"prodOrders"
,
new
ArrayList
<>());
}
}
Map
dbSc003Map
=
dbSc003
.
toMap
();
dbSc003Map
.
put
(
"planDetail"
,
dbSc004Maps
);
inInfo
.
set
(
"planInfo"
,
dbSc003Map
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
LogUtils
.
setMsg
(
inInfo
,
e
,
"查询计划详情失败"
);
LogUtils
.
setMsg
(
inInfo
,
e
,
"查询计划详情失败"
);
// 小程序端要求,错误码使用500
// 小程序端要求,错误码使用500
...
...
src/main/java/com/baosight/hpjx/hp/sc/tools/HPSCTools.java
View file @
da554616
...
@@ -425,7 +425,6 @@ public class HPSCTools {
...
@@ -425,7 +425,6 @@ public class HPSCTools {
/**
/**
* 生成二维码
* 生成二维码
*
*
* @param id
* @param planInfoNo
* @param planInfoNo
*/
*/
public
static
void
createQrCode
(
String
planInfoNo
)
throws
Exception
{
public
static
void
createQrCode
(
String
planInfoNo
)
throws
Exception
{
...
...
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