Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hg-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
hg-smart
Commits
fc8ae48e
Commit
fc8ae48e
authored
Sep 23, 2024
by
宋祥
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.报工数量支持小数位填写和计算
parent
a22f748f
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
202 additions
and
147 deletions
+202
-147
ServiceHGKC003.java
.../java/com/baosight/hggp/hg/kc/service/ServiceHGKC003.java
+2
-2
HGKCTools.java
src/main/java/com/baosight/hggp/hg/kc/tools/HGKCTools.java
+9
-6
HGSC005A.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC005A.java
+21
-12
HGSC006A.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC006A.java
+22
-14
HGSC007.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC007.java
+22
-14
HGSC008.java
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC008.java
+26
-20
ServiceHGSC006A.java
...java/com/baosight/hggp/hg/sc/service/ServiceHGSC006A.java
+2
-2
ServiceHGSC006B.java
...java/com/baosight/hggp/hg/sc/service/ServiceHGSC006B.java
+22
-19
ServiceHGSC007A.java
...java/com/baosight/hggp/hg/sc/service/ServiceHGSC007A.java
+7
-5
HGSCTools.java
src/main/java/com/baosight/hggp/hg/sc/tools/HGSCTools.java
+0
-0
HGZL002.java
src/main/java/com/baosight/hggp/hg/zl/domain/HGZL002.java
+21
-12
ServiceHGZL002.java
.../java/com/baosight/hggp/hg/zl/service/ServiceHGZL002.java
+11
-7
HGZLTools.java
src/main/java/com/baosight/hggp/hg/zl/tools/HGZLTools.java
+5
-5
HGSC007.jsp
src/main/webapp/HG/SC/HGSC007.jsp
+1
-1
HGSC007A.js
src/main/webapp/HG/SC/HGSC007A.js
+14
-13
HGSC007A.jsp
src/main/webapp/HG/SC/HGSC007A.jsp
+1
-1
HGSC008.jsp
src/main/webapp/HG/SC/HGSC008.jsp
+4
-4
HGZL002.js
src/main/webapp/HG/ZL/HGZL002.js
+6
-5
HGZL002.jsp
src/main/webapp/HG/ZL/HGZL002.jsp
+6
-5
No files found.
src/main/java/com/baosight/hggp/hg/kc/service/ServiceHGKC003.java
View file @
fc8ae48e
...
@@ -156,7 +156,7 @@ public class ServiceHGKC003 extends ServiceBase {
...
@@ -156,7 +156,7 @@ public class ServiceHGKC003 extends ServiceBase {
this
.
checkSubmitData
(
dbKc003
);
this
.
checkSubmitData
(
dbKc003
);
DaoUtils
.
update
(
HGKC003
.
UPDATE_SUBMIT_STATUS
,
dbKc003
);
DaoUtils
.
update
(
HGKC003
.
UPDATE_SUBMIT_STATUS
,
dbKc003
);
// 修改计划生产任务完工数量
// 修改计划生产任务完工数量
HGSCTools
.
complete
(
dbKc003
.
getQualityId
(),
dbKc003
.
getInvQty
()
.
intValue
()
,
dbKc003
.
getRectificationId
(),
HGSCTools
.
complete
(
dbKc003
.
getQualityId
(),
dbKc003
.
getInvQty
(),
dbKc003
.
getRectificationId
(),
HGConstant
.
StorageType
.
RK
);
HGConstant
.
StorageType
.
RK
);
// 修改库存
// 修改库存
HGKCUtils
.
HgKc010
.
updateInv
(
dbKc003
.
getCompanyCode
(),
dbKc003
.
getWhCode
(),
dbKc003
.
getPrdtCode
(),
HGKCUtils
.
HgKc010
.
updateInv
(
dbKc003
.
getCompanyCode
(),
dbKc003
.
getWhCode
(),
dbKc003
.
getPrdtCode
(),
...
@@ -247,7 +247,7 @@ public class ServiceHGKC003 extends ServiceBase {
...
@@ -247,7 +247,7 @@ public class ServiceHGKC003 extends ServiceBase {
newKc003
.
setIsReturn
(
CommonConstant
.
YesNo
.
YES_1
);
newKc003
.
setIsReturn
(
CommonConstant
.
YesNo
.
YES_1
);
DaoUtils
.
insert
(
HGKC003
.
INSERT
,
newKc003
);
DaoUtils
.
insert
(
HGKC003
.
INSERT
,
newKc003
);
//修改计划生产任务完工数量
//修改计划生产任务完工数量
HGSCTools
.
complete
(
fKc003
.
getQualityId
(),
newKc003
.
getInvQty
()
.
intValue
()
,
fKc003
.
getRectificationId
(),
HGConstant
.
StorageType
.
TH
);
HGSCTools
.
complete
(
fKc003
.
getQualityId
(),
newKc003
.
getInvQty
(),
fKc003
.
getRectificationId
(),
HGConstant
.
StorageType
.
TH
);
// 修改库存
// 修改库存
HGKCUtils
.
HgKc010
.
updateInv
(
newKc003
.
getCompanyCode
(),
newKc003
.
getWhCode
(),
newKc003
.
getPrdtCode
(),
HGKCUtils
.
HgKc010
.
updateInv
(
newKc003
.
getCompanyCode
(),
newKc003
.
getWhCode
(),
newKc003
.
getPrdtCode
(),
newKc003
.
getInvQty
(),
newKc003
.
getInvWeight
());
newKc003
.
getInvQty
(),
newKc003
.
getInvWeight
());
...
...
src/main/java/com/baosight/hggp/hg/kc/tools/HGKCTools.java
View file @
fc8ae48e
...
@@ -290,7 +290,8 @@ public class HGKCTools {
...
@@ -290,7 +290,8 @@ public class HGKCTools {
AssertUtils
.
isEmpty
(
hgzl002
.
getProductCode
(),
"存货编码不能为空!"
);
AssertUtils
.
isEmpty
(
hgzl002
.
getProductCode
(),
"存货编码不能为空!"
);
AssertUtils
.
isEmpty
(
hgzl002
.
getProductName
(),
"存货名称不能为空!"
);
AssertUtils
.
isEmpty
(
hgzl002
.
getProductName
(),
"存货名称不能为空!"
);
AssertUtils
.
isTrue
(
Objects
.
isNull
(
hgzl002
.
getId
())||
hgzl002
.
getId
()<=
0
,
"质检单明细ID不能为空!"
);
AssertUtils
.
isTrue
(
Objects
.
isNull
(
hgzl002
.
getId
())||
hgzl002
.
getId
()<=
0
,
"质检单明细ID不能为空!"
);
AssertUtils
.
isTrue
(
hgzl002
.
getPassQuantity
().
compareTo
(
0
)
==
0
&&
hgzl002
.
getUnpassQuantity
().
compareTo
(
0
)
==
0
,
"合格数量与不合格数量不能都为0!"
);
AssertUtils
.
isTrue
(
hgzl002
.
getPassQuantity
().
compareTo
(
BigDecimal
.
ZERO
)
==
0
&&
hgzl002
.
getUnpassQuantity
().
compareTo
(
BigDecimal
.
ZERO
)
==
0
,
"合格数量与不合格数量不能都为0!"
);
}
}
}
}
/**
/**
...
@@ -310,7 +311,7 @@ public class HGKCTools {
...
@@ -310,7 +311,7 @@ public class HGKCTools {
List
<
HGPZ005A
>
hgpz005AList
=
HGPZTools
.
HgPz005A
.
queryByInventCodes
(
inventCodes
);
List
<
HGPZ005A
>
hgpz005AList
=
HGPZTools
.
HgPz005A
.
queryByInventCodes
(
inventCodes
);
hgkc003List
.
forEach
(
hgkc003
->{
hgkc003List
.
forEach
(
hgkc003
->{
//修改计划生产任务完工数量
//修改计划生产任务完工数量
HGSCTools
.
complete
(
hgkc003
.
getQualityId
(),
hgkc003
.
getInvQty
()
.
intValue
()
,
hgkc003
.
getRectificationId
(),
HGConstant
.
StorageType
.
RK
);
HGSCTools
.
complete
(
hgkc003
.
getQualityId
(),
hgkc003
.
getInvQty
(),
hgkc003
.
getRectificationId
(),
HGConstant
.
StorageType
.
RK
);
//查询当前工序
//查询当前工序
HGPZ005A
hgpz005A
=
hgpz005AList
.
stream
().
filter
(
o
->
o
.
getId
().
equals
(
hgkc003
.
getInventProcessId
())).
findAny
().
orElse
(
null
);
HGPZ005A
hgpz005A
=
hgpz005AList
.
stream
().
filter
(
o
->
o
.
getId
().
equals
(
hgkc003
.
getInventProcessId
())).
findAny
().
orElse
(
null
);
AssertUtils
.
isNull
(
hgpz005A
,
"未获取到当前工序信息!"
);
AssertUtils
.
isNull
(
hgpz005A
,
"未获取到当前工序信息!"
);
...
@@ -345,11 +346,11 @@ public class HGKCTools {
...
@@ -345,11 +346,11 @@ public class HGKCTools {
if
(
Objects
.
nonNull
(
code
)){
if
(
Objects
.
nonNull
(
code
)){
HGZL004
hgzl004
=
hgzl004List
.
stream
().
filter
(
h
->
h
.
getCheckId
().
equals
(
o
.
getId
())).
findAny
().
orElse
(
null
);
HGZL004
hgzl004
=
hgzl004List
.
stream
().
filter
(
h
->
h
.
getCheckId
().
equals
(
o
.
getId
())).
findAny
().
orElse
(
null
);
//整改通知单
//整改通知单
hgkc003
.
setInvQty
(
new
BigDecimal
(
o
.
getUnpassQuantity
()
));
hgkc003
.
setInvQty
(
o
.
getUnpassQuantity
(
));
hgkc003
.
setRectificationId
(
hgzl004
.
getId
());
hgkc003
.
setRectificationId
(
hgzl004
.
getId
());
}
else
{
}
else
{
//工序质检单
//工序质检单
hgkc003
.
setInvQty
(
new
BigDecimal
(
o
.
getPassQuantity
()
));
hgkc003
.
setInvQty
(
o
.
getPassQuantity
(
));
}
}
if
(
hgkc003
.
getInvQty
().
compareTo
(
BigDecimal
.
ZERO
)
==
0
){
if
(
hgkc003
.
getInvQty
().
compareTo
(
BigDecimal
.
ZERO
)
==
0
){
return
;
return
;
...
@@ -416,9 +417,11 @@ public class HGKCTools {
...
@@ -416,9 +417,11 @@ public class HGKCTools {
List
<
HGPZ005A
>
hgpz005AList
=
HGPZTools
.
HgPz005A
.
queryByInventCodes
(
inventCodes
);
List
<
HGPZ005A
>
hgpz005AList
=
HGPZTools
.
HgPz005A
.
queryByInventCodes
(
inventCodes
);
hgkc003List
.
forEach
(
hgkc003
->{
hgkc003List
.
forEach
(
hgkc003
->{
//修改计划生产任务完工数量
//修改计划生产任务完工数量
HGSCTools
.
complete
(
hgkc003
.
getQualityId
(),
hgkc003
.
getInvQty
().
intValue
(),
hgkc003
.
getRectificationId
(),
HGConstant
.
StorageType
.
RK
);
HGSCTools
.
complete
(
hgkc003
.
getQualityId
(),
hgkc003
.
getInvQty
(),
hgkc003
.
getRectificationId
(),
HGConstant
.
StorageType
.
RK
);
//查询当前工序
//查询当前工序
HGPZ005A
hgpz005A
=
hgpz005AList
.
stream
().
filter
(
o
->
o
.
getInventCode
().
equals
(
hgkc003
.
getPrdtCode
())).
findAny
().
orElse
(
null
);
HGPZ005A
hgpz005A
=
hgpz005AList
.
stream
()
.
filter
(
o
->
o
.
getInventCode
().
equals
(
hgkc003
.
getPrdtCode
())).
findAny
().
orElse
(
null
);
//查询比当前工序靠后的工序是否存在,不存在说明是最后工序,修改实时库存
//查询比当前工序靠后的工序是否存在,不存在说明是最后工序,修改实时库存
List
<
HGPZ005A
>
nextHgpz005AList
=
hgpz005AList
.
stream
().
filter
(
o
->
o
.
getProcessOrder
().
compareTo
(
hgpz005A
.
getProcessOrder
())
==
1
).
collect
(
Collectors
.
toList
());
List
<
HGPZ005A
>
nextHgpz005AList
=
hgpz005AList
.
stream
().
filter
(
o
->
o
.
getProcessOrder
().
compareTo
(
hgpz005A
.
getProcessOrder
())
==
1
).
collect
(
Collectors
.
toList
());
if
(
CollectionUtils
.
isEmpty
(
nextHgpz005AList
)){
if
(
CollectionUtils
.
isEmpty
(
nextHgpz005AList
)){
...
...
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC005A.java
View file @
fc8ae48e
...
@@ -128,9 +128,9 @@ public class HGSC005A extends DaoEPBase {
...
@@ -128,9 +128,9 @@ public class HGSC005A extends DaoEPBase {
private
String
finishDate
=
" "
;
/* 完工日期*/
private
String
finishDate
=
" "
;
/* 完工日期*/
private
String
planStartDate
=
" "
;
/* 计划开始日期*/
private
String
planStartDate
=
" "
;
/* 计划开始日期*/
private
String
planEndDate
=
" "
;
/* 计划结束日期*/
private
String
planEndDate
=
" "
;
/* 计划结束日期*/
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
BigDecimal
quantity
=
new
BigDecimal
(
0
);
/* 数量*/
private
Integer
finishQuantity
=
new
Integer
(
0
);
/* 完工数量*/
private
BigDecimal
finishQuantity
=
new
BigDecimal
(
0
);
/* 完工数量*/
private
Integer
unfinishQuantity
=
new
Integer
(
0
);
/* 未完工数量*/
private
BigDecimal
unfinishQuantity
=
new
BigDecimal
(
0
);
/* 未完工数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
finishWeight
=
new
BigDecimal
(
"0"
);
/* 完工重量*/
private
BigDecimal
finishWeight
=
new
BigDecimal
(
"0"
);
/* 完工重量*/
...
@@ -250,14 +250,23 @@ public class HGSC005A extends DaoEPBase {
...
@@ -250,14 +250,23 @@ public class HGSC005A extends DaoEPBase {
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"数量"
);
eiColumn
.
setDescName
(
"数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_finish_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_finish_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"完工数量"
);
eiColumn
.
setDescName
(
"完工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unfinish_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_unfinish_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"未完工数量"
);
eiColumn
.
setDescName
(
"未完工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
...
@@ -683,7 +692,7 @@ public class HGSC005A extends DaoEPBase {
...
@@ -683,7 +692,7 @@ public class HGSC005A extends DaoEPBase {
* get the quantity - 数量.
* get the quantity - 数量.
* @return the quantity
* @return the quantity
*/
*/
public
Integer
getQuantity
()
{
public
BigDecimal
getQuantity
()
{
return
this
.
quantity
;
return
this
.
quantity
;
}
}
...
@@ -692,14 +701,14 @@ public class HGSC005A extends DaoEPBase {
...
@@ -692,14 +701,14 @@ public class HGSC005A extends DaoEPBase {
*
*
* @param quantity - 数量
* @param quantity - 数量
*/
*/
public
void
setQuantity
(
Integer
quantity
)
{
public
void
setQuantity
(
BigDecimal
quantity
)
{
this
.
quantity
=
quantity
;
this
.
quantity
=
quantity
;
}
}
/**
/**
* get the finishQuantity - 完工数量.
* get the finishQuantity - 完工数量.
* @return the finishQuantity
* @return the finishQuantity
*/
*/
public
Integer
getFinishQuantity
()
{
public
BigDecimal
getFinishQuantity
()
{
return
this
.
finishQuantity
;
return
this
.
finishQuantity
;
}
}
...
@@ -708,14 +717,14 @@ public class HGSC005A extends DaoEPBase {
...
@@ -708,14 +717,14 @@ public class HGSC005A extends DaoEPBase {
*
*
* @param finishQuantity - 完工数量
* @param finishQuantity - 完工数量
*/
*/
public
void
setFinishQuantity
(
Integer
finishQuantity
)
{
public
void
setFinishQuantity
(
BigDecimal
finishQuantity
)
{
this
.
finishQuantity
=
finishQuantity
;
this
.
finishQuantity
=
finishQuantity
;
}
}
/**
/**
* get the unfinishQuantity - 未完工数量.
* get the unfinishQuantity - 未完工数量.
* @return the unfinishQuantity
* @return the unfinishQuantity
*/
*/
public
Integer
getUnfinishQuantity
()
{
public
BigDecimal
getUnfinishQuantity
()
{
return
this
.
unfinishQuantity
;
return
this
.
unfinishQuantity
;
}
}
...
@@ -724,7 +733,7 @@ public class HGSC005A extends DaoEPBase {
...
@@ -724,7 +733,7 @@ public class HGSC005A extends DaoEPBase {
*
*
* @param unfinishQuantity - 未完工数量
* @param unfinishQuantity - 未完工数量
*/
*/
public
void
setUnfinishQuantity
(
Integer
unfinishQuantity
)
{
public
void
setUnfinishQuantity
(
BigDecimal
unfinishQuantity
)
{
this
.
unfinishQuantity
=
unfinishQuantity
;
this
.
unfinishQuantity
=
unfinishQuantity
;
}
}
/**
/**
...
@@ -933,9 +942,9 @@ public class HGSC005A extends DaoEPBase {
...
@@ -933,9 +942,9 @@ public class HGSC005A extends DaoEPBase {
setFinishDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_date
)),
finishDate
));
setFinishDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_date
)),
finishDate
));
setPlanStartDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_start_date
)),
planStartDate
));
setPlanStartDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_start_date
)),
planStartDate
));
setPlanEndDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_end_date
)),
planEndDate
));
setPlanEndDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_end_date
)),
planEndDate
));
setQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setFinishQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_quantity
)),
finishQuantity
));
setFinishQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_quantity
)),
finishQuantity
));
setUnfinishQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_quantity
)),
unfinishQuantity
));
setUnfinishQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_quantity
)),
unfinishQuantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setFinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_weight
)),
finishWeight
));
setFinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_weight
)),
finishWeight
));
...
...
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC006A.java
View file @
fc8ae48e
...
@@ -127,9 +127,9 @@ public class HGSC006A extends DaoEPBase {
...
@@ -127,9 +127,9 @@ public class HGSC006A extends DaoEPBase {
private
String
productName
=
" "
;
/* 产品名称*/
private
String
productName
=
" "
;
/* 产品名称*/
private
String
planStartDate
=
" "
;
/* 计划开始日期*/
private
String
planStartDate
=
" "
;
/* 计划开始日期*/
private
String
planEndDate
=
" "
;
/* 计划结束日期*/
private
String
planEndDate
=
" "
;
/* 计划结束日期*/
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
BigDecimal
quantity
=
new
BigDecimal
(
0
);
/* 数量*/
private
Integer
assignQuantity
=
new
Integer
(
0
);
/* 派工数量*/
private
BigDecimal
assignQuantity
=
new
BigDecimal
(
0
);
/* 派工数量*/
private
Integer
unassignQuantity
=
new
Integer
(
0
);
/* 未派工数量*/
private
BigDecimal
unassignQuantity
=
new
BigDecimal
(
0
);
/* 未派工数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
assignWeight
=
new
BigDecimal
(
"0"
);
/* 派工重量*/
private
BigDecimal
assignWeight
=
new
BigDecimal
(
"0"
);
/* 派工重量*/
...
@@ -235,14 +235,23 @@ public class HGSC006A extends DaoEPBase {
...
@@ -235,14 +235,23 @@ public class HGSC006A extends DaoEPBase {
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"数量"
);
eiColumn
.
setDescName
(
"数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_assign_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_assign_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"派工数量"
);
eiColumn
.
setDescName
(
"派工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unassign_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_unassign_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"未派工数量"
);
eiColumn
.
setDescName
(
"未派工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
...
@@ -656,7 +665,7 @@ public class HGSC006A extends DaoEPBase {
...
@@ -656,7 +665,7 @@ public class HGSC006A extends DaoEPBase {
* get the quantity - 数量.
* get the quantity - 数量.
* @return the quantity
* @return the quantity
*/
*/
public
Integer
getQuantity
()
{
public
BigDecimal
getQuantity
()
{
return
this
.
quantity
;
return
this
.
quantity
;
}
}
...
@@ -665,14 +674,14 @@ public class HGSC006A extends DaoEPBase {
...
@@ -665,14 +674,14 @@ public class HGSC006A extends DaoEPBase {
*
*
* @param quantity - 数量
* @param quantity - 数量
*/
*/
public
void
setQuantity
(
Integer
quantity
)
{
public
void
setQuantity
(
BigDecimal
quantity
)
{
this
.
quantity
=
quantity
;
this
.
quantity
=
quantity
;
}
}
/**
/**
* get the assignQuantity - 派工数量.
* get the assignQuantity - 派工数量.
* @return the assignQuantity
* @return the assignQuantity
*/
*/
public
Integer
getAssignQuantity
()
{
public
BigDecimal
getAssignQuantity
()
{
return
this
.
assignQuantity
;
return
this
.
assignQuantity
;
}
}
...
@@ -681,14 +690,14 @@ public class HGSC006A extends DaoEPBase {
...
@@ -681,14 +690,14 @@ public class HGSC006A extends DaoEPBase {
*
*
* @param assignQuantity - 派工数量
* @param assignQuantity - 派工数量
*/
*/
public
void
setAssignQuantity
(
Integer
assignQuantity
)
{
public
void
setAssignQuantity
(
BigDecimal
assignQuantity
)
{
this
.
assignQuantity
=
assignQuantity
;
this
.
assignQuantity
=
assignQuantity
;
}
}
/**
/**
* get the unassignQuantity - 未派工数量.
* get the unassignQuantity - 未派工数量.
* @return the unassignQuantity
* @return the unassignQuantity
*/
*/
public
Integer
getUnassignQuantity
()
{
public
BigDecimal
getUnassignQuantity
()
{
return
this
.
unassignQuantity
;
return
this
.
unassignQuantity
;
}
}
...
@@ -697,7 +706,7 @@ public class HGSC006A extends DaoEPBase {
...
@@ -697,7 +706,7 @@ public class HGSC006A extends DaoEPBase {
*
*
* @param unassignQuantity - 未派工数量
* @param unassignQuantity - 未派工数量
*/
*/
public
void
setUnassignQuantity
(
Integer
unassignQuantity
)
{
public
void
setUnassignQuantity
(
BigDecimal
unassignQuantity
)
{
this
.
unassignQuantity
=
unassignQuantity
;
this
.
unassignQuantity
=
unassignQuantity
;
}
}
/**
/**
...
@@ -921,9 +930,9 @@ public class HGSC006A extends DaoEPBase {
...
@@ -921,9 +930,9 @@ public class HGSC006A extends DaoEPBase {
setProductName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_name
)),
productName
));
setProductName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_product_name
)),
productName
));
setPlanStartDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_start_date
)),
planStartDate
));
setPlanStartDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_start_date
)),
planStartDate
));
setPlanEndDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_end_date
)),
planEndDate
));
setPlanEndDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_plan_end_date
)),
planEndDate
));
setQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setAssignQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_quantity
)),
assignQuantity
));
setAssignQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_quantity
)),
assignQuantity
));
setUnassignQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unassign_quantity
)),
unassignQuantity
));
setUnassignQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unassign_quantity
)),
unassignQuantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setAssignWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_weight
)),
assignWeight
));
setAssignWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_assign_weight
)),
assignWeight
));
...
@@ -984,4 +993,4 @@ public class HGSC006A extends DaoEPBase {
...
@@ -984,4 +993,4 @@ public class HGSC006A extends DaoEPBase {
return
map
;
return
map
;
}
}
}
}
\ No newline at end of file
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC007.java
View file @
fc8ae48e
...
@@ -152,9 +152,9 @@ public class HGSC007 extends DaoEPBase {
...
@@ -152,9 +152,9 @@ public class HGSC007 extends DaoEPBase {
private
String
groupCode
=
" "
;
/* 工作组编号*/
private
String
groupCode
=
" "
;
/* 工作组编号*/
private
String
groupName
=
" "
;
/* 工作组名称*/
private
String
groupName
=
" "
;
/* 工作组名称*/
private
String
completeDate
=
" "
;
/* 完工日期*/
private
String
completeDate
=
" "
;
/* 完工日期*/
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
BigDecimal
quantity
=
new
BigDecimal
(
0
);
/* 数量*/
private
Integer
finishQuantity
=
new
Integer
(
0
);
/* 完工数量*/
private
BigDecimal
finishQuantity
=
new
BigDecimal
(
0
);
/* 完工数量*/
private
Integer
unfinishQuantity
=
new
Integer
(
0
);
/* 未完工数量*/
private
BigDecimal
unfinishQuantity
=
new
BigDecimal
(
0
);
/* 未完工数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
finishWeight
=
new
BigDecimal
(
"0"
);
/* 完工重量*/
private
BigDecimal
finishWeight
=
new
BigDecimal
(
"0"
);
/* 完工重量*/
...
@@ -289,14 +289,23 @@ public class HGSC007 extends DaoEPBase {
...
@@ -289,14 +289,23 @@ public class HGSC007 extends DaoEPBase {
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"数量"
);
eiColumn
.
setDescName
(
"数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_finish_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_finish_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"完工数量"
);
eiColumn
.
setDescName
(
"完工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unfinish_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_unfinish_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"未完工数量"
);
eiColumn
.
setDescName
(
"未完工数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
...
@@ -824,7 +833,7 @@ public class HGSC007 extends DaoEPBase {
...
@@ -824,7 +833,7 @@ public class HGSC007 extends DaoEPBase {
* get the quantity - 数量.
* get the quantity - 数量.
* @return the quantity
* @return the quantity
*/
*/
public
Integer
getQuantity
()
{
public
BigDecimal
getQuantity
()
{
return
this
.
quantity
;
return
this
.
quantity
;
}
}
...
@@ -833,14 +842,14 @@ public class HGSC007 extends DaoEPBase {
...
@@ -833,14 +842,14 @@ public class HGSC007 extends DaoEPBase {
*
*
* @param quantity - 数量
* @param quantity - 数量
*/
*/
public
void
setQuantity
(
Integer
quantity
)
{
public
void
setQuantity
(
BigDecimal
quantity
)
{
this
.
quantity
=
quantity
;
this
.
quantity
=
quantity
;
}
}
/**
/**
* get the finishQuantity - 完工数量.
* get the finishQuantity - 完工数量.
* @return the finishQuantity
* @return the finishQuantity
*/
*/
public
Integer
getFinishQuantity
()
{
public
BigDecimal
getFinishQuantity
()
{
return
this
.
finishQuantity
;
return
this
.
finishQuantity
;
}
}
...
@@ -849,14 +858,14 @@ public class HGSC007 extends DaoEPBase {
...
@@ -849,14 +858,14 @@ public class HGSC007 extends DaoEPBase {
*
*
* @param finishQuantity - 完工数量
* @param finishQuantity - 完工数量
*/
*/
public
void
setFinishQuantity
(
Integer
finishQuantity
)
{
public
void
setFinishQuantity
(
BigDecimal
finishQuantity
)
{
this
.
finishQuantity
=
finishQuantity
;
this
.
finishQuantity
=
finishQuantity
;
}
}
/**
/**
* get the unfinishQuantity - 未完工数量.
* get the unfinishQuantity - 未完工数量.
* @return the unfinishQuantity
* @return the unfinishQuantity
*/
*/
public
Integer
getUnfinishQuantity
()
{
public
BigDecimal
getUnfinishQuantity
()
{
return
this
.
unfinishQuantity
;
return
this
.
unfinishQuantity
;
}
}
...
@@ -865,7 +874,7 @@ public class HGSC007 extends DaoEPBase {
...
@@ -865,7 +874,7 @@ public class HGSC007 extends DaoEPBase {
*
*
* @param unfinishQuantity - 未完工数量
* @param unfinishQuantity - 未完工数量
*/
*/
public
void
setUnfinishQuantity
(
Integer
unfinishQuantity
)
{
public
void
setUnfinishQuantity
(
BigDecimal
unfinishQuantity
)
{
this
.
unfinishQuantity
=
unfinishQuantity
;
this
.
unfinishQuantity
=
unfinishQuantity
;
}
}
/**
/**
...
@@ -1120,9 +1129,9 @@ public class HGSC007 extends DaoEPBase {
...
@@ -1120,9 +1129,9 @@ public class HGSC007 extends DaoEPBase {
setGroupCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_code
)),
groupCode
));
setGroupCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_code
)),
groupCode
));
setGroupName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_name
)),
groupName
));
setGroupName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_name
)),
groupName
));
setCompleteDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_complete_date
)),
completeDate
));
setCompleteDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_complete_date
)),
completeDate
));
setQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setFinishQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_quantity
)),
finishQuantity
));
setFinishQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_quantity
)),
finishQuantity
));
setUnfinishQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_quantity
)),
unfinishQuantity
));
setUnfinishQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unfinish_quantity
)),
unfinishQuantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setFinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_weight
)),
finishWeight
));
setFinishWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_finish_weight
)),
finishWeight
));
...
@@ -1198,4 +1207,4 @@ public class HGSC007 extends DaoEPBase {
...
@@ -1198,4 +1207,4 @@ public class HGSC007 extends DaoEPBase {
return
map
;
return
map
;
}
}
}
}
\ No newline at end of file
src/main/java/com/baosight/hggp/hg/sc/domain/HGSC008.java
View file @
fc8ae48e
...
@@ -23,7 +23,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -23,7 +23,7 @@ public class HGSC008 extends DaoEPBase {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
public
static
final
String
FIELD_id
=
"id"
;
public
static
final
String
FIELD_id
=
"id"
;
public
static
final
String
FIELD_mat_id
=
"matId"
;
/* 物料清单ID*/
public
static
final
String
FIELD_mat_id
=
"matId"
;
/* 物料清单ID*/
public
static
final
String
FIELD_task_id
=
"taskId"
;
/* 生产任务ID*/
public
static
final
String
FIELD_task_id
=
"taskId"
;
/* 生产任务ID*/
public
static
final
String
FIELD_tech_flow_id
=
"techFlowId"
;
/* 工艺流程ID*/
public
static
final
String
FIELD_tech_flow_id
=
"techFlowId"
;
/* 工艺流程ID*/
...
@@ -71,7 +71,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -71,7 +71,7 @@ public class HGSC008 extends DaoEPBase {
public
static
final
String
FIELD_length
=
"length"
;
/* 长*/
public
static
final
String
FIELD_length
=
"length"
;
/* 长*/
public
static
final
String
FIELD_exceed_reason
=
"exceedReason"
;
public
static
final
String
FIELD_exceed_reason
=
"exceedReason"
;
public
static
final
String
COL_id
=
"id"
;
public
static
final
String
COL_id
=
"id"
;
public
static
final
String
COL_mat_id
=
"mat_id"
;
/* 物料清单ID*/
public
static
final
String
COL_mat_id
=
"mat_id"
;
/* 物料清单ID*/
public
static
final
String
COL_task_id
=
"task_id"
;
/* 生产任务ID*/
public
static
final
String
COL_task_id
=
"task_id"
;
/* 生产任务ID*/
public
static
final
String
COL_tech_flow_id
=
"tech_flow_id"
;
/* 工艺流程ID*/
public
static
final
String
COL_tech_flow_id
=
"tech_flow_id"
;
/* 工艺流程ID*/
...
@@ -116,7 +116,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -116,7 +116,7 @@ public class HGSC008 extends DaoEPBase {
public
static
final
String
BATCH_DELETE
=
"HGSC008.batch_delete"
;
public
static
final
String
BATCH_DELETE
=
"HGSC008.batch_delete"
;
private
Long
id
=
new
Long
(
0
);
private
Long
id
=
new
Long
(
0
);
private
Long
matId
=
new
Long
(
0
);
/* 物料清单ID*/
private
Long
matId
=
new
Long
(
0
);
/* 物料清单ID*/
private
Long
taskId
=
new
Long
(
0
);
/* 生产任务ID*/
private
Long
taskId
=
new
Long
(
0
);
/* 生产任务ID*/
private
Long
techFlowId
=
new
Long
(
0
);
/* 工艺流程ID*/
private
Long
techFlowId
=
new
Long
(
0
);
/* 工艺流程ID*/
...
@@ -142,7 +142,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -142,7 +142,7 @@ public class HGSC008 extends DaoEPBase {
private
String
groupCode
=
" "
;
/* 工作组编号*/
private
String
groupCode
=
" "
;
/* 工作组编号*/
private
String
groupName
=
" "
;
/* 工作组名称*/
private
String
groupName
=
" "
;
/* 工作组名称*/
private
String
registerDate
=
" "
;
/* 报工日期*/
private
String
registerDate
=
" "
;
/* 报工日期*/
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
BigDecimal
quantity
=
new
BigDecimal
(
0
);
/* 数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
String
accountCode
=
" "
;
/* 帐套*/
private
String
accountCode
=
" "
;
/* 帐套*/
...
@@ -158,18 +158,18 @@ public class HGSC008 extends DaoEPBase {
...
@@ -158,18 +158,18 @@ public class HGSC008 extends DaoEPBase {
//补充字段
//补充字段
private
Integer
registeredQuantity
=
new
Integer
(
0
);
private
BigDecimal
registeredQuantity
=
new
BigDecimal
(
0
);
private
BigDecimal
registeredWeight
=
new
BigDecimal
(
0
);
private
BigDecimal
registeredWeight
=
new
BigDecimal
(
0
);
private
Integer
unregisterQuantity
=
new
Integer
(
0
);
private
BigDecimal
unregisterQuantity
=
new
BigDecimal
(
0
);
private
BigDecimal
unregisterWeight
=
new
BigDecimal
(
0
);
private
BigDecimal
unregisterWeight
=
new
BigDecimal
(
0
);
private
Integer
taskQuantity
=
new
Integer
(
0
);
private
BigDecimal
taskQuantity
=
new
BigDecimal
(
0
);
private
BigDecimal
taskWeight
=
new
BigDecimal
(
0
);
private
BigDecimal
taskWeight
=
new
BigDecimal
(
0
);
public
Integer
getRegisteredQuantity
()
{
public
BigDecimal
getRegisteredQuantity
()
{
return
registeredQuantity
;
return
registeredQuantity
;
}
}
public
void
setRegisteredQuantity
(
Integer
registeredQuantity
)
{
public
void
setRegisteredQuantity
(
BigDecimal
registeredQuantity
)
{
this
.
registeredQuantity
=
registeredQuantity
;
this
.
registeredQuantity
=
registeredQuantity
;
}
}
...
@@ -181,11 +181,11 @@ public class HGSC008 extends DaoEPBase {
...
@@ -181,11 +181,11 @@ public class HGSC008 extends DaoEPBase {
this
.
registeredWeight
=
registeredWeight
;
this
.
registeredWeight
=
registeredWeight
;
}
}
public
Integer
getUnregisterQuantity
()
{
public
BigDecimal
getUnregisterQuantity
()
{
return
unregisterQuantity
;
return
unregisterQuantity
;
}
}
public
void
setUnregisterQuantity
(
Integer
unregisterQuantity
)
{
public
void
setUnregisterQuantity
(
BigDecimal
unregisterQuantity
)
{
this
.
unregisterQuantity
=
unregisterQuantity
;
this
.
unregisterQuantity
=
unregisterQuantity
;
}
}
...
@@ -197,11 +197,11 @@ public class HGSC008 extends DaoEPBase {
...
@@ -197,11 +197,11 @@ public class HGSC008 extends DaoEPBase {
this
.
unregisterWeight
=
unregisterWeight
;
this
.
unregisterWeight
=
unregisterWeight
;
}
}
public
Integer
getTaskQuantity
()
{
public
BigDecimal
getTaskQuantity
()
{
return
taskQuantity
;
return
taskQuantity
;
}
}
public
void
setTaskQuantity
(
Integer
taskQuantity
)
{
public
void
setTaskQuantity
(
BigDecimal
taskQuantity
)
{
this
.
taskQuantity
=
taskQuantity
;
this
.
taskQuantity
=
taskQuantity
;
}
}
...
@@ -325,6 +325,9 @@ public class HGSC008 extends DaoEPBase {
...
@@ -325,6 +325,9 @@ public class HGSC008 extends DaoEPBase {
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"数量"
);
eiColumn
.
setDescName
(
"数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
...
@@ -393,6 +396,9 @@ public class HGSC008 extends DaoEPBase {
...
@@ -393,6 +396,9 @@ public class HGSC008 extends DaoEPBase {
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_task_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_task_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"任务数量"
);
eiColumn
.
setDescName
(
"任务数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
...
@@ -443,7 +449,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -443,7 +449,7 @@ public class HGSC008 extends DaoEPBase {
/**
/**
* set the id .
* set the id .
*
*
* @param id
* @param id
*/
*/
public
void
setId
(
Long
id
)
{
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
this
.
id
=
id
;
...
@@ -852,7 +858,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -852,7 +858,7 @@ public class HGSC008 extends DaoEPBase {
* get the quantity - 数量.
* get the quantity - 数量.
* @return the quantity
* @return the quantity
*/
*/
public
Integer
getQuantity
()
{
public
BigDecimal
getQuantity
()
{
return
this
.
quantity
;
return
this
.
quantity
;
}
}
...
@@ -861,7 +867,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -861,7 +867,7 @@ public class HGSC008 extends DaoEPBase {
*
*
* @param quantity - 数量
* @param quantity - 数量
*/
*/
public
void
setQuantity
(
Integer
quantity
)
{
public
void
setQuantity
(
BigDecimal
quantity
)
{
this
.
quantity
=
quantity
;
this
.
quantity
=
quantity
;
}
}
/**
/**
...
@@ -1067,7 +1073,7 @@ public class HGSC008 extends DaoEPBase {
...
@@ -1067,7 +1073,7 @@ public class HGSC008 extends DaoEPBase {
setGroupCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_code
)),
groupCode
));
setGroupCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_code
)),
groupCode
));
setGroupName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_name
)),
groupName
));
setGroupName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_name
)),
groupName
));
setRegisterDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_register_date
)),
registerDate
));
setRegisterDate
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_register_date
)),
registerDate
));
setQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setAccountCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_account_code
)),
accountCode
));
setAccountCode
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_account_code
)),
accountCode
));
...
@@ -1078,11 +1084,11 @@ public class HGSC008 extends DaoEPBase {
...
@@ -1078,11 +1084,11 @@ public class HGSC008 extends DaoEPBase {
setUpdatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_updated_name
)),
updatedName
));
setUpdatedName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_updated_name
)),
updatedName
));
setUpdatedTime
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_updated_time
)),
updatedTime
));
setUpdatedTime
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_updated_time
)),
updatedTime
));
setRegisteredQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_registered_quantity
)),
registeredQuantity
));
setRegisteredQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_registered_quantity
)),
registeredQuantity
));
setRegisteredWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_registered_weight
)),
registeredWeight
));
setRegisteredWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_registered_weight
)),
registeredWeight
));
setUnregisterQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unregister_quantity
)),
unregisterQuantity
));
setUnregisterQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unregister_quantity
)),
unregisterQuantity
));
setUnregisterWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unregister_weight
)),
unregisterWeight
));
setUnregisterWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unregister_weight
)),
unregisterWeight
));
setTaskQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_task_quantity
)),
taskQuantity
));
setTaskQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_task_quantity
)),
taskQuantity
));
setTaskWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_task_weight
)),
taskWeight
));
setTaskWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_task_weight
)),
taskWeight
));
setSpec
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_spec
)),
spec
));
setSpec
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_spec
)),
spec
));
setLength
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_length
)),
length
));
setLength
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_length
)),
length
));
...
...
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC006A.java
View file @
fc8ae48e
...
@@ -81,7 +81,7 @@ public class ServiceHGSC006A extends ServiceBase {
...
@@ -81,7 +81,7 @@ public class ServiceHGSC006A extends ServiceBase {
// 校验主订单是否已分派
// 校验主订单是否已分派
//HGSC006A hgsc006A = HGSCTools.THGSC006A.getById(Long.parseLong(orderDetailId));
//HGSC006A hgsc006A = HGSCTools.THGSC006A.getById(Long.parseLong(orderDetailId));
AssignStatusEnum
assignStatusEnum
=
AssignStatusEnum
.
getEnumByCode
(
hgsc006A
.
getAssignStatus
());
AssignStatusEnum
assignStatusEnum
=
AssignStatusEnum
.
getEnumByCode
(
hgsc006A
.
getAssignStatus
());
Integer
assignQuantity
=
new
Integer
(
0
)
;
BigDecimal
assignQuantity
=
BigDecimal
.
ZERO
;
switch
(
assignStatusEnum
){
switch
(
assignStatusEnum
){
case
UNASSIGN:
case
UNASSIGN:
assignQuantity
=
hgsc006A
.
getQuantity
();
assignQuantity
=
hgsc006A
.
getQuantity
();
...
@@ -112,7 +112,7 @@ public class ServiceHGSC006A extends ServiceBase {
...
@@ -112,7 +112,7 @@ public class ServiceHGSC006A extends ServiceBase {
hgsc007
.
setOrderDetailId
(
hgsc006A
.
getId
());
hgsc007
.
setOrderDetailId
(
hgsc006A
.
getId
());
hgsc007
.
setQuantity
(
assignQuantity
);
hgsc007
.
setQuantity
(
assignQuantity
);
hgsc007
.
setUnfinishQuantity
(
assignQuantity
);
hgsc007
.
setUnfinishQuantity
(
assignQuantity
);
hgsc007
.
setTotalWeight
(
hgsc006A
.
getSingleWeight
().
multiply
(
new
BigDecimal
(
assignQuantity
)
));
hgsc007
.
setTotalWeight
(
hgsc006A
.
getSingleWeight
().
multiply
(
assignQuantity
));
hgsc007
.
setUnfinishWeight
(
hgsc007
.
getTotalWeight
());
hgsc007
.
setUnfinishWeight
(
hgsc007
.
getTotalWeight
());
hgsc007
.
setGroupCode
(
groupCode
);
hgsc007
.
setGroupCode
(
groupCode
);
hgsc007
.
setGroupName
(
groupName
);
hgsc007
.
setGroupName
(
groupName
);
...
...
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC006B.java
View file @
fc8ae48e
...
@@ -165,8 +165,8 @@ public class ServiceHGSC006B extends ServiceBase {
...
@@ -165,8 +165,8 @@ public class ServiceHGSC006B extends ServiceBase {
List
<
HGSC007
>
hgsc007s
=
MapUtils
.
toDaoEPBases
(
resultRows
,
HGSC007
.
class
);
List
<
HGSC007
>
hgsc007s
=
MapUtils
.
toDaoEPBases
(
resultRows
,
HGSC007
.
class
);
// 判断数量是否超过订单数量
// 判断数量是否超过订单数量
Integer
totalNum
=
hgsc007s
.
stream
().
mapToInt
(
HGSC007:
:
getQuantity
).
sum
(
);
BigDecimal
totalNum
=
hgsc007s
.
stream
().
map
(
HGSC007:
:
getQuantity
).
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
);
AssertUtils
.
isGt
(
new
BigDecimal
(
totalNum
),
new
BigDecimal
(
hgsc006A
.
getQuantity
()
),
"拆单的分派数量不能大于生产订单数量!"
);
AssertUtils
.
isGt
(
totalNum
,
hgsc006A
.
getQuantity
(
),
"拆单的分派数量不能大于生产订单数量!"
);
// 查询任务信息
// 查询任务信息
List
<
HGSC007
>
hgsc007List
=
HGSCTools
.
THGSC007
.
list
(
taskIds
);
List
<
HGSC007
>
hgsc007List
=
HGSCTools
.
THGSC007
.
list
(
taskIds
);
//查询生产报工
//查询生产报工
...
@@ -219,7 +219,7 @@ public class ServiceHGSC006B extends ServiceBase {
...
@@ -219,7 +219,7 @@ public class ServiceHGSC006B extends ServiceBase {
add007
.
setOrderDetailId
(
hgsc006A
.
getId
());
add007
.
setOrderDetailId
(
hgsc006A
.
getId
());
add007
.
setQuantity
(
hgsc007
.
getQuantity
());
add007
.
setQuantity
(
hgsc007
.
getQuantity
());
add007
.
setUnfinishQuantity
(
hgsc007
.
getQuantity
());
add007
.
setUnfinishQuantity
(
hgsc007
.
getQuantity
());
add007
.
setTotalWeight
(
hgsc006A
.
getSingleWeight
().
multiply
(
new
BigDecimal
(
hgsc007
.
getQuantity
()
)));
add007
.
setTotalWeight
(
hgsc006A
.
getSingleWeight
().
multiply
(
hgsc007
.
getQuantity
(
)));
add007
.
setUnfinishWeight
(
add007
.
getTotalWeight
());
add007
.
setUnfinishWeight
(
add007
.
getTotalWeight
());
add007
.
setGroupCode
(
hgsc007
.
getGroupCode
());
add007
.
setGroupCode
(
hgsc007
.
getGroupCode
());
add007
.
setGroupName
(
hgsc007
.
getGroupName
());
add007
.
setGroupName
(
hgsc007
.
getGroupName
());
...
@@ -271,7 +271,7 @@ public class ServiceHGSC006B extends ServiceBase {
...
@@ -271,7 +271,7 @@ public class ServiceHGSC006B extends ServiceBase {
sc007
.
setFactoryName
(
hgsc007
.
getFactoryName
());
sc007
.
setFactoryName
(
hgsc007
.
getFactoryName
());
sc007
.
setQuantity
(
hgsc007
.
getQuantity
());
sc007
.
setQuantity
(
hgsc007
.
getQuantity
());
sc007
.
setUnfinishQuantity
(
hgsc007
.
getQuantity
());
sc007
.
setUnfinishQuantity
(
hgsc007
.
getQuantity
());
sc007
.
setTotalWeight
(
sc007
.
getSingleWeight
().
multiply
(
new
BigDecimal
(
hgsc007
.
getQuantity
()
)));
sc007
.
setTotalWeight
(
sc007
.
getSingleWeight
().
multiply
(
hgsc007
.
getQuantity
(
)));
sc007
.
setUnfinishWeight
(
sc007
.
getTotalWeight
());
sc007
.
setUnfinishWeight
(
sc007
.
getTotalWeight
());
DaoUtils
.
update
(
HGSC007
.
UPDATE
,
sc007
);
DaoUtils
.
update
(
HGSC007
.
UPDATE
,
sc007
);
...
@@ -296,10 +296,10 @@ public class ServiceHGSC006B extends ServiceBase {
...
@@ -296,10 +296,10 @@ public class ServiceHGSC006B extends ServiceBase {
HGSC007
hgsc007
=
new
HGSC007
();
HGSC007
hgsc007
=
new
HGSC007
();
hgsc007
.
fromMap
(
resultRow
);
hgsc007
.
fromMap
(
resultRow
);
HGSC007
dbsc007
=
HGSCTools
.
THGSC007
.
getById
(
hgsc007
.
getId
());
HGSC007
dbsc007
=
HGSCTools
.
THGSC007
.
getById
(
hgsc007
.
getId
());
AssertUtils
.
isGt
(
new
BigDecimal
(
dbsc007
.
getFinishQuantity
()
),
BigDecimal
.
ZERO
,
AssertUtils
.
isGt
(
dbsc007
.
getFinishQuantity
(
),
BigDecimal
.
ZERO
,
String
.
format
(
"任务[%s]已存在完工数量不能删除"
,
dbsc007
.
getTaskCode
()));
String
.
format
(
"任务[%s]已存在完工数量不能删除"
,
dbsc007
.
getTaskCode
()));
// 更新订单主表数量
// 更新订单主表数量
HGSCTools
.
checkAssignedNum
(
orderDetailId
,
-
hgsc007
.
getQuantity
());
HGSCTools
.
checkAssignedNum
(
orderDetailId
,
hgsc007
.
getQuantity
().
negate
());
// 删除子单
// 删除子单
DaoUtils
.
update
(
HGSC007
.
DELETE
,
hgsc007
);
DaoUtils
.
update
(
HGSC007
.
DELETE
,
hgsc007
);
// 清除已经分配的人员信息
// 清除已经分配的人员信息
...
@@ -335,24 +335,24 @@ public class ServiceHGSC006B extends ServiceBase {
...
@@ -335,24 +335,24 @@ public class ServiceHGSC006B extends ServiceBase {
* @param hgsc006A 生产订单明细
* @param hgsc006A 生产订单明细
* @param totalNum 任务数量
* @param totalNum 任务数量
*/
*/
public
void
checkAssignedNum
(
HGSC006A
hgsc006A
,
Integer
totalNum
)
{
public
void
checkAssignedNum
(
HGSC006A
hgsc006A
,
BigDecimal
totalNum
)
{
// 生产订单
// 生产订单
//HGSC006A hgsc006A = HGSCTools.THGSC006A.getById(orderDetailId);
//HGSC006A hgsc006A = HGSCTools.THGSC006A.getById(orderDetailId);
Integer
jhNum
=
hgsc006A
.
getQuantity
();
BigDecimal
jhNum
=
hgsc006A
.
getQuantity
();
Map
updateMap
=
new
HashMap
<>();
Map
updateMap
=
new
HashMap
<>();
updateMap
.
put
(
HGSC006A
.
FIELD_id
,
hgsc006A
.
getId
());
updateMap
.
put
(
HGSC006A
.
FIELD_id
,
hgsc006A
.
getId
());
updateMap
.
put
(
HGSC006A
.
FIELD_assign_quantity
,
totalNum
);
updateMap
.
put
(
HGSC006A
.
FIELD_assign_quantity
,
totalNum
);
updateMap
.
put
(
HGSC006A
.
FIELD_unassign_quantity
,
jhNum
-
totalNum
);
updateMap
.
put
(
HGSC006A
.
FIELD_unassign_quantity
,
jhNum
.
subtract
(
totalNum
)
);
if
(
Objects
.
nonNull
(
hgsc006A
.
getSingleWeight
())&&
hgsc006A
.
getSingleWeight
().
compareTo
(
BigDecimal
.
ZERO
)>
0
)
{
if
(
Objects
.
nonNull
(
hgsc006A
.
getSingleWeight
())&&
hgsc006A
.
getSingleWeight
().
compareTo
(
BigDecimal
.
ZERO
)>
0
)
{
BigDecimal
assignWeight
=
hgsc006A
.
getSingleWeight
().
multiply
(
new
BigDecimal
(
totalNum
)
);
BigDecimal
assignWeight
=
hgsc006A
.
getSingleWeight
().
multiply
(
totalNum
);
updateMap
.
put
(
HGSC006A
.
FIELD_assign_weight
,
assignWeight
);
updateMap
.
put
(
HGSC006A
.
FIELD_assign_weight
,
assignWeight
);
updateMap
.
put
(
HGSC006A
.
FIELD_unassign_weight
,
hgsc006A
.
getTotalWeight
().
subtract
(
assignWeight
));
updateMap
.
put
(
HGSC006A
.
FIELD_unassign_weight
,
hgsc006A
.
getTotalWeight
().
subtract
(
assignWeight
));
}
}
// 0.未派工,1.部分派工,2.全部派工
// 0.未派工,1.部分派工,2.全部派工
AssignStatusEnum
orderDetailAssignStatus
;
AssignStatusEnum
orderDetailAssignStatus
;
if
(
jhNum
-
totalNum
==
0
)
{
if
(
jhNum
.
subtract
(
totalNum
).
compareTo
(
BigDecimal
.
ZERO
)
==
0
)
{
orderDetailAssignStatus
=
AssignStatusEnum
.
ASSIGNED
;
orderDetailAssignStatus
=
AssignStatusEnum
.
ASSIGNED
;
}
else
if
(
totalNum
>
0
)
{
}
else
if
(
totalNum
.
compareTo
(
BigDecimal
.
ZERO
)
>
0
)
{
orderDetailAssignStatus
=
AssignStatusEnum
.
PARTIAL_ASSIGN
;
orderDetailAssignStatus
=
AssignStatusEnum
.
PARTIAL_ASSIGN
;
}
else
{
}
else
{
orderDetailAssignStatus
=
AssignStatusEnum
.
UNASSIGN
;
orderDetailAssignStatus
=
AssignStatusEnum
.
UNASSIGN
;
...
@@ -364,13 +364,16 @@ public class ServiceHGSC006B extends ServiceBase {
...
@@ -364,13 +364,16 @@ public class ServiceHGSC006B extends ServiceBase {
private
void
handleOrderAssignStatus
(
HGSC006A
hgsc006A
,
AssignStatusEnum
orderDetailAssignStatus
){
private
void
handleOrderAssignStatus
(
HGSC006A
hgsc006A
,
AssignStatusEnum
orderDetailAssignStatus
){
List
<
HGSC006A
>
otherSc006AList
=
HGSCTools
.
THGSC006A
.
otherById
(
hgsc006A
.
getOrderCode
(),
hgsc006A
.
getId
());
List
<
HGSC006A
>
otherSc006AList
=
HGSCTools
.
THGSC006A
.
otherById
(
hgsc006A
.
getOrderCode
(),
hgsc006A
.
getId
());
int
assignQuantity
=
0
;
BigDecimal
assignQuantity
=
BigDecimal
.
ZERO
;
int
unassignQuantity
=
0
;
BigDecimal
unassignQuantity
=
BigDecimal
.
ZERO
;
int
totalQuantity
=
0
;
BigDecimal
totalQuantity
=
BigDecimal
.
ZERO
;
if
(
CollectionUtils
.
isNotEmpty
(
otherSc006AList
)){
if
(
CollectionUtils
.
isNotEmpty
(
otherSc006AList
)){
assignQuantity
=
otherSc006AList
.
stream
().
mapToInt
(
HGSC006A:
:
getAssignQuantity
).
sum
();
assignQuantity
=
otherSc006AList
.
stream
().
map
(
HGSC006A:
:
getAssignQuantity
)
unassignQuantity
=
otherSc006AList
.
stream
().
mapToInt
(
HGSC006A:
:
getUnassignQuantity
).
sum
();
.
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
);
totalQuantity
=
otherSc006AList
.
stream
().
mapToInt
(
HGSC006A:
:
getQuantity
).
sum
();
unassignQuantity
=
otherSc006AList
.
stream
().
map
(
HGSC006A:
:
getUnassignQuantity
)
.
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
);
totalQuantity
=
otherSc006AList
.
stream
().
map
(
HGSC006A:
:
getQuantity
)
.
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
);
}
}
AssignStatusEnum
orderAssignStatus
;
AssignStatusEnum
orderAssignStatus
;
switch
(
orderDetailAssignStatus
){
switch
(
orderDetailAssignStatus
){
...
...
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC007A.java
View file @
fc8ae48e
...
@@ -48,9 +48,11 @@ public class ServiceHGSC007A extends ServiceEPBase {
...
@@ -48,9 +48,11 @@ public class ServiceHGSC007A extends ServiceEPBase {
hgsc008
.
setTaskId
(
hgsc007
.
getId
());
hgsc008
.
setTaskId
(
hgsc007
.
getId
());
hgsc008
.
setTaskQuantity
(
hgsc007
.
getQuantity
());
hgsc008
.
setTaskQuantity
(
hgsc007
.
getQuantity
());
hgsc008
.
setTaskWeight
(
hgsc007
.
getTotalWeight
());
hgsc008
.
setTaskWeight
(
hgsc007
.
getTotalWeight
());
hgsc008
.
setRegisteredQuantity
(
Optional
.
ofNullable
(
old008List
).
orElse
(
new
ArrayList
<>()).
stream
().
mapToInt
(
HGSC008:
:
getQuantity
).
sum
());
hgsc008
.
setRegisteredQuantity
(
Optional
.
ofNullable
(
old008List
).
orElse
(
new
ArrayList
<>()).
stream
()
hgsc008
.
setRegisteredWeight
(
Optional
.
ofNullable
(
old008List
).
orElse
(
new
ArrayList
<>()).
stream
().
map
(
HGSC008:
:
getTotalWeight
).
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
));
.
map
(
HGSC008:
:
getQuantity
).
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
));
hgsc008
.
setUnregisterQuantity
(
hgsc007
.
getQuantity
()
-
hgsc008
.
getRegisteredQuantity
());
hgsc008
.
setRegisteredWeight
(
Optional
.
ofNullable
(
old008List
).
orElse
(
new
ArrayList
<>()).
stream
()
.
map
(
HGSC008:
:
getTotalWeight
).
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
));
hgsc008
.
setUnregisterQuantity
(
hgsc007
.
getQuantity
().
subtract
(
hgsc008
.
getRegisteredQuantity
()));
hgsc008
.
setUnregisterWeight
(
hgsc007
.
getTotalWeight
().
subtract
(
hgsc008
.
getRegisteredWeight
()));
hgsc008
.
setUnregisterWeight
(
hgsc007
.
getTotalWeight
().
subtract
(
hgsc008
.
getRegisteredWeight
()));
hgsc008
.
setRegisterDate
(
DateUtil
.
toDateStr
(
new
Date
(),
DateUtil
.
DATE10_PATTERN
));
hgsc008
.
setRegisterDate
(
DateUtil
.
toDateStr
(
new
Date
(),
DateUtil
.
DATE10_PATTERN
));
hgsc008
.
setQuantity
(
null
);
hgsc008
.
setQuantity
(
null
);
...
@@ -67,8 +69,8 @@ public class ServiceHGSC007A extends ServiceEPBase {
...
@@ -67,8 +69,8 @@ public class ServiceHGSC007A extends ServiceEPBase {
public
EiInfo
save
(
EiInfo
inInfo
)
{
public
EiInfo
save
(
EiInfo
inInfo
)
{
try
{
try
{
Map
resultMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
,
EiConstant
.
resultBlock
);
Map
resultMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
,
EiConstant
.
resultBlock
);
HGSC008
hgsc008
=
HGSCTools
.
THGSC008
.
add
(
inInfo
);
HGSC008
hgsc008
=
HGSCTools
.
THGSC008
.
add
(
inInfo
);
String
docId
=
org
.
apache
.
commons
.
collections
.
MapUtils
.
getString
(
resultMap
,
HGSB004A
.
FIELD_DOC_ID
);
String
docId
=
MapUtils
.
getString
(
resultMap
,
HGSB004A
.
FIELD_DOC_ID
);
if
(
StringUtils
.
isNotEmpty
(
docId
))
{
if
(
StringUtils
.
isNotEmpty
(
docId
))
{
String
[]
docIds
=
docId
.
split
(
","
);
String
[]
docIds
=
docId
.
split
(
","
);
for
(
String
docIdStr
:
docIds
){
for
(
String
docIdStr
:
docIds
){
...
...
src/main/java/com/baosight/hggp/hg/sc/tools/HGSCTools.java
View file @
fc8ae48e
This diff is collapsed.
Click to expand it.
src/main/java/com/baosight/hggp/hg/zl/domain/HGZL002.java
View file @
fc8ae48e
...
@@ -149,9 +149,9 @@ public class HGZL002 extends DaoEPBase {
...
@@ -149,9 +149,9 @@ public class HGZL002 extends DaoEPBase {
private
String
groupName
=
" "
;
/* 工作组名称*/
private
String
groupName
=
" "
;
/* 工作组名称*/
private
String
workBy
=
" "
;
/* 生产人*/
private
String
workBy
=
" "
;
/* 生产人*/
private
String
workName
=
" "
;
/* 生产人名称*/
private
String
workName
=
" "
;
/* 生产人名称*/
private
Integer
quantity
=
new
Integer
(
0
);
/* 数量*/
private
BigDecimal
quantity
=
new
BigDecimal
(
0
);
/* 数量*/
private
Integer
passQuantity
=
new
Integer
(
0
);
/* 合格数量*/
private
BigDecimal
passQuantity
=
new
BigDecimal
(
0
);
/* 合格数量*/
private
Integer
unpassQuantity
=
new
Integer
(
0
);
/* 不合格数量*/
private
BigDecimal
unpassQuantity
=
new
BigDecimal
(
0
);
/* 不合格数量*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
singleWeight
=
new
BigDecimal
(
"0"
);
/* 单重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
BigDecimal
totalWeight
=
new
BigDecimal
(
"0"
);
/* 总重*/
private
String
checkBy
=
" "
;
/* 质检人*/
private
String
checkBy
=
" "
;
/* 质检人*/
...
@@ -286,14 +286,23 @@ public class HGZL002 extends DaoEPBase {
...
@@ -286,14 +286,23 @@ public class HGZL002 extends DaoEPBase {
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"数量"
);
eiColumn
.
setDescName
(
"数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_pass_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_pass_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"合格数量"
);
eiColumn
.
setDescName
(
"合格数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
eiColumn
=
new
EiColumn
(
FIELD_unpass_quantity
);
eiColumn
=
new
EiColumn
(
FIELD_unpass_quantity
);
eiColumn
.
setType
(
"N"
);
eiColumn
.
setScaleLength
(
1
);
eiColumn
.
setFieldLength
(
20
);
eiColumn
.
setDescName
(
"不合格数量"
);
eiColumn
.
setDescName
(
"不合格数量"
);
eiMetadata
.
addMeta
(
eiColumn
);
eiMetadata
.
addMeta
(
eiColumn
);
...
@@ -817,7 +826,7 @@ public class HGZL002 extends DaoEPBase {
...
@@ -817,7 +826,7 @@ public class HGZL002 extends DaoEPBase {
* get the quantity - 数量.
* get the quantity - 数量.
* @return the quantity
* @return the quantity
*/
*/
public
Integer
getQuantity
()
{
public
BigDecimal
getQuantity
()
{
return
this
.
quantity
;
return
this
.
quantity
;
}
}
...
@@ -826,14 +835,14 @@ public class HGZL002 extends DaoEPBase {
...
@@ -826,14 +835,14 @@ public class HGZL002 extends DaoEPBase {
*
*
* @param quantity - 数量
* @param quantity - 数量
*/
*/
public
void
setQuantity
(
Integer
quantity
)
{
public
void
setQuantity
(
BigDecimal
quantity
)
{
this
.
quantity
=
quantity
;
this
.
quantity
=
quantity
;
}
}
/**
/**
* get the passQuantity - 合格数量.
* get the passQuantity - 合格数量.
* @return the passQuantity
* @return the passQuantity
*/
*/
public
Integer
getPassQuantity
()
{
public
BigDecimal
getPassQuantity
()
{
return
this
.
passQuantity
;
return
this
.
passQuantity
;
}
}
...
@@ -842,14 +851,14 @@ public class HGZL002 extends DaoEPBase {
...
@@ -842,14 +851,14 @@ public class HGZL002 extends DaoEPBase {
*
*
* @param passQuantity - 合格数量
* @param passQuantity - 合格数量
*/
*/
public
void
setPassQuantity
(
Integer
passQuantity
)
{
public
void
setPassQuantity
(
BigDecimal
passQuantity
)
{
this
.
passQuantity
=
passQuantity
;
this
.
passQuantity
=
passQuantity
;
}
}
/**
/**
* get the unpassQuantity - 不合格数量.
* get the unpassQuantity - 不合格数量.
* @return the unpassQuantity
* @return the unpassQuantity
*/
*/
public
Integer
getUnpassQuantity
()
{
public
BigDecimal
getUnpassQuantity
()
{
return
this
.
unpassQuantity
;
return
this
.
unpassQuantity
;
}
}
...
@@ -858,7 +867,7 @@ public class HGZL002 extends DaoEPBase {
...
@@ -858,7 +867,7 @@ public class HGZL002 extends DaoEPBase {
*
*
* @param unpassQuantity - 不合格数量
* @param unpassQuantity - 不合格数量
*/
*/
public
void
setUnpassQuantity
(
Integer
unpassQuantity
)
{
public
void
setUnpassQuantity
(
BigDecimal
unpassQuantity
)
{
this
.
unpassQuantity
=
unpassQuantity
;
this
.
unpassQuantity
=
unpassQuantity
;
}
}
/**
/**
...
@@ -1105,9 +1114,9 @@ public class HGZL002 extends DaoEPBase {
...
@@ -1105,9 +1114,9 @@ public class HGZL002 extends DaoEPBase {
setGroupName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_name
)),
groupName
));
setGroupName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_group_name
)),
groupName
));
setWorkBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_work_by
)),
workBy
));
setWorkBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_work_by
)),
workBy
));
setWorkName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_work_name
)),
workName
));
setWorkName
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_work_name
)),
workName
));
setQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_quantity
)),
quantity
));
setPassQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_pass_quantity
)),
passQuantity
));
setPassQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_pass_quantity
)),
passQuantity
));
setUnpassQuantity
(
NumberUtils
.
to
Integer
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unpass_quantity
)),
unpassQuantity
));
setUnpassQuantity
(
NumberUtils
.
to
BigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_unpass_quantity
)),
unpassQuantity
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setSingleWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_single_weight
)),
singleWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setTotalWeight
(
NumberUtils
.
toBigDecimal
(
StringUtils
.
toString
(
map
.
get
(
FIELD_total_weight
)),
totalWeight
));
setCheckBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_check_by
)),
checkBy
));
setCheckBy
(
StringUtils
.
defaultIfEmpty
(
StringUtils
.
toString
(
map
.
get
(
FIELD_check_by
)),
checkBy
));
...
...
src/main/java/com/baosight/hggp/hg/zl/service/ServiceHGZL002.java
View file @
fc8ae48e
...
@@ -16,6 +16,7 @@ import com.baosight.iplat4j.core.ei.EiInfo;
...
@@ -16,6 +16,7 @@ import com.baosight.iplat4j.core.ei.EiInfo;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.collections.CollectionUtils
;
import
java.math.BigDecimal
;
import
java.util.*
;
import
java.util.*
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
...
@@ -112,13 +113,16 @@ public class ServiceHGZL002 extends ServiceBase {
...
@@ -112,13 +113,16 @@ public class ServiceHGZL002 extends ServiceBase {
resultMap
.
put
(
"unpassQuantity"
,
0
);
resultMap
.
put
(
"unpassQuantity"
,
0
);
try
{
try
{
inInfo
=
super
.
query
(
inInfo
,
HGZL002
.
QUERY
,
new
HGZL002
());
inInfo
=
super
.
query
(
inInfo
,
HGZL002
.
QUERY
,
new
HGZL002
());
List
<
HGZL002
>
hgzl002s
=
MapUtils
.
toDaoEPBases
(
inInfo
,
HGZL002
.
class
);
List
<
HGZL002
>
hgzl002s
=
MapUtils
.
toDaoEPBases
(
inInfo
,
HGZL002
.
class
);
int
quantity
=
Optional
.
ofNullable
(
hgzl002s
).
orElse
(
new
ArrayList
<>()).
stream
().
mapToInt
(
HGZL002:
:
getQuantity
).
sum
();
BigDecimal
quantity
=
Optional
.
ofNullable
(
hgzl002s
).
orElse
(
new
ArrayList
<>()).
stream
()
int
passQuantity
=
Optional
.
ofNullable
(
hgzl002s
).
orElse
(
new
ArrayList
<>()).
stream
().
mapToInt
(
HGZL002:
:
getPassQuantity
).
sum
();
.
map
(
HGZL002:
:
getQuantity
).
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
);
int
unpassQuantity
=
Optional
.
ofNullable
(
hgzl002s
).
orElse
(
new
ArrayList
<>()).
stream
().
mapToInt
(
HGZL002:
:
getUnpassQuantity
).
sum
();
BigDecimal
passQuantity
=
Optional
.
ofNullable
(
hgzl002s
).
orElse
(
new
ArrayList
<>()).
stream
()
resultMap
.
put
(
"quantity"
,
quantity
);
.
map
(
HGZL002:
:
getPassQuantity
).
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
);
resultMap
.
put
(
"passQuantity"
,
passQuantity
);
BigDecimal
unpassQuantity
=
Optional
.
ofNullable
(
hgzl002s
).
orElse
(
new
ArrayList
<>()).
stream
()
resultMap
.
put
(
"unpassQuantity"
,
unpassQuantity
);
.
map
(
HGZL002:
:
getUnpassQuantity
).
reduce
(
BigDecimal
.
ZERO
,
BigDecimal:
:
add
);
resultMap
.
put
(
"quantity"
,
quantity
);
resultMap
.
put
(
"passQuantity"
,
passQuantity
);
resultMap
.
put
(
"unpassQuantity"
,
unpassQuantity
);
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"查询失败"
);
}
}
...
...
src/main/java/com/baosight/hggp/hg/zl/tools/HGZLTools.java
View file @
fc8ae48e
...
@@ -16,6 +16,7 @@ import com.baosight.iplat4j.ed.util.SequenceGenerator;
...
@@ -16,6 +16,7 @@ import com.baosight.iplat4j.ed.util.SequenceGenerator;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.BeanUtils
;
import
java.math.BigDecimal
;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -209,10 +210,10 @@ public class HGZLTools {
...
@@ -209,10 +210,10 @@ public class HGZLTools {
queryMap
.
put
(
HGZL004
.
FIELD_id
,
id
);
queryMap
.
put
(
HGZL004
.
FIELD_id
,
id
);
DaoBase
.
getInstance
().
update
(
HGSqlConstant
.
HGZL004
.
LOCK
,
queryMap
);
DaoBase
.
getInstance
().
update
(
HGSqlConstant
.
HGZL004
.
LOCK
,
queryMap
);
}
}
public
static
void
addByHGZL002
(
HGZL002
hgzl002
)
{
public
static
void
addByHGZL002
(
HGZL002
hgzl002
)
{
List
<
HGZL004
>
hgzl004DbList
=
listByCheckId
(
hgzl002
.
getId
(),
CheckTypeEnum
.
PROCESS_CHECK
.
getCode
());
List
<
HGZL004
>
hgzl004DbList
=
listByCheckId
(
hgzl002
.
getId
(),
CheckTypeEnum
.
PROCESS_CHECK
.
getCode
());
if
(
hgzl002
.
getUnpassQuantity
()>
0
&&
CollectionUtils
.
isEmpty
(
hgzl004DbList
))
{
if
(
hgzl002
.
getUnpassQuantity
().
compareTo
(
BigDecimal
.
ZERO
)
==
1
&&
CollectionUtils
.
isEmpty
(
hgzl004DbList
))
{
HGZL004
hgzl004
=
new
HGZL004
();
HGZL004
hgzl004
=
new
HGZL004
();
BeanUtils
.
copyProperties
(
hgzl002
,
hgzl004
);
BeanUtils
.
copyProperties
(
hgzl002
,
hgzl004
);
cleanBaseInfo
(
hgzl004
);
cleanBaseInfo
(
hgzl004
);
...
@@ -306,4 +307,4 @@ public class HGZLTools {
...
@@ -306,4 +307,4 @@ public class HGZLTools {
}
}
}
}
\ No newline at end of file
src/main/webapp/HG/SC/HGSC007.jsp
View file @
fc8ae48e
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
</div>
</div>
</EF:EFRegion>
</EF:EFRegion>
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFRegion
id=
"result"
title=
"明细信息"
fitHeight=
"true"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
>
<EF:EFColumn
ename=
"id"
primaryKey=
"true"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
primaryKey=
"true"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"accountCode"
cname=
"账套"
hidden=
"true"
/>
<EF:EFColumn
ename=
"accountCode"
cname=
"账套"
hidden=
"true"
/>
...
...
src/main/webapp/HG/SC/HGSC007A.js
View file @
fc8ae48e
$
(
function
()
{
$
(
function
()
{
$
(
"#result-0-quantity_textField"
).
on
(
'change'
,
function
()
{
$
(
"#result-0-quantity"
).
on
(
'change'
,
function
()
{
var
quantity
=
$
(
"#result-0-quantity_textField"
).
val
();
var
quantity
=
$
(
"#result-0-quantity"
).
val
();
if
(
!
isPositiveInteger
(
quantity
)){
if
(
!
isPositiveNumber
(
quantity
))
{
message
(
"报工数量必须是大于0的正整数"
)
message
(
"报工数量必须是大于0的数字"
)
}
}
var
singleWeight
=
$
(
"#result-0-singleWeight_textField"
).
val
();
var
singleWeight
=
$
(
"#result-0-singleWeight_textField"
).
val
();
if
(
isPositiveNumber
(
singleWeight
))
{
if
(
isPositiveNumber
(
singleWeight
))
{
$
(
"#result-0-totalWeight_textField"
).
val
((
parseInt
(
singleWeight
*
quantity
*
100
)
/
100
).
toFixed
(
2
));
$
(
"#result-0-totalWeight_textField"
).
val
(
}
(
parseInt
(
singleWeight
*
quantity
*
100
)
/
100
).
toFixed
(
2
));
})
}
})
...
@@ -25,9 +26,9 @@ $(function () {
...
@@ -25,9 +26,9 @@ $(function () {
* 保存*
* 保存*
*/
*/
$
(
"#btn_save"
).
on
(
"click"
,
function
(){
$
(
"#btn_save"
).
on
(
"click"
,
function
(){
var
quantity
=
$
(
"#result-0-quantity
_textField
"
).
val
();
var
quantity
=
$
(
"#result-0-quantity"
).
val
();
if
(
!
isPositive
Integ
er
(
quantity
)){
if
(
!
isPositive
Numb
er
(
quantity
)){
message
(
"报工数量必须是大于0的
正整数
"
);
message
(
"报工数量必须是大于0的
数字
"
);
return
;
return
;
}
}
var
registerDate
=
$
(
"#result-0-registerDate"
).
val
();
var
registerDate
=
$
(
"#result-0-registerDate"
).
val
();
...
...
src/main/webapp/HG/SC/HGSC007A.jsp
View file @
fc8ae48e
...
@@ -32,7 +32,7 @@
...
@@ -32,7 +32,7 @@
<EF:EFInput
ename=
"result-0-groupName"
cname=
"班组"
colWidth=
"4"
required=
"true"
readonly=
"true"
/>
<EF:EFInput
ename=
"result-0-groupName"
cname=
"班组"
colWidth=
"4"
required=
"true"
readonly=
"true"
/>
<EF:EFDatePicker
cname=
"报工日期"
ename=
"result-0-registerDate"
colWidth=
"4"
<EF:EFDatePicker
cname=
"报工日期"
ename=
"result-0-registerDate"
colWidth=
"4"
format=
"yyyy-MM-dd"
required=
"true"
readonly=
"false"
/>
format=
"yyyy-MM-dd"
required=
"true"
readonly=
"false"
/>
<EF:EFInput
ename=
"result-0-quantity"
cname=
"报工数量"
format=
"{0:0
}"
editType=
"text"
colWidth=
"4"
required=
"true"
/>
<EF:EFInput
ename=
"result-0-quantity"
cname=
"报工数量"
format=
"{0:0
.0}"
colWidth=
"4"
required=
"true"
/>
<EF:EFInput
ename=
"result-0-totalWeight"
cname=
"报工重量"
format=
"{0:0.00}"
editType=
"text"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"result-0-totalWeight"
cname=
"报工重量"
format=
"{0:0.00}"
editType=
"text"
colWidth=
"4"
readonly=
"true"
/>
<EF:EFInput
ename=
"result-0-exceedReason"
cname=
"超报原因"
type=
"textarea"
editType=
"text"
colWidth=
"8"
ratio=
"2:10"
/>
<EF:EFInput
ename=
"result-0-exceedReason"
cname=
"超报原因"
type=
"textarea"
editType=
"text"
colWidth=
"8"
ratio=
"2:10"
/>
</div>
</div>
...
...
src/main/webapp/HG/SC/HGSC008.jsp
View file @
fc8ae48e
...
@@ -18,10 +18,10 @@
...
@@ -18,10 +18,10 @@
</div>
</div>
</EF:EFRegion>
</EF:EFRegion>
<EF:EFRegion
id=
"result"
title=
"明细信息
"
>
<EF:EFRegion
id=
"result"
title=
"明细信息"
fitHeight=
"true
"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
>
<EF:EFColumn
ename=
"id"
primaryKey=
"true"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
primaryKey=
"true"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"accountCode"
cname=
"账套"
hidden=
"true"
/>
<EF:EFColumn
ename=
"accountCode"
cname=
"账套"
hidden=
"true"
/>
<EF:EFColumn
ename=
"operator"
cname=
"操作"
locked=
"true"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFColumn
ename=
"operator"
cname=
"操作"
locked=
"true"
enable=
"false"
width=
"120"
align=
"center"
/>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
enable=
"true"
width=
"180"
align=
"center"
readOnly=
"true"
/>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
enable=
"true"
width=
"180"
align=
"center"
readOnly=
"true"
/>
<EF:EFColumn
ename=
"projName"
cname=
"项目名称"
enable=
"true"
width=
"120"
align=
"center"
readOnly=
"true"
/>
<EF:EFColumn
ename=
"projName"
cname=
"项目名称"
enable=
"true"
width=
"120"
align=
"center"
readOnly=
"true"
/>
...
...
src/main/webapp/HG/ZL/HGZL002.js
View file @
fc8ae48e
...
@@ -39,15 +39,16 @@ $(function () {
...
@@ -39,15 +39,16 @@ $(function () {
// 判断父级节点是否发生变化
// 判断父级节点是否发生变化
if
(
e
.
field
==
"unpassQuantity"
)
{
if
(
e
.
field
==
"unpassQuantity"
)
{
// loadChange(grid,e,"passQuantity");
// loadChange(grid,e,"passQuantity");
var
passQuantity
=
e
.
items
[
0
][
'quantity'
]
-
e
.
items
[
0
][
'unpassQuantity'
];
var
passQuantity
=
parseFloat
(
e
.
items
[
0
][
'quantity'
])
resultGrid
.
setCellValue
(
e
.
items
[
0
],
"passQuantity"
,
passQuantity
.
toFixed
(
3
)
);
-
parseFloat
(
e
.
items
[
0
][
'unpassQuantity'
]
);
resultGrid
.
setCellValue
(
e
.
items
[
0
],
"passQuantity"
,
passQuantity
);
}
}
// 判断父级节点是否发生变化
// 判断父级节点是否发生变化
if
(
e
.
field
==
"passQuantity"
)
{
if
(
e
.
field
==
"passQuantity"
)
{
// loadChange(grid,e,"unpassQuantity");
// loadChange(grid,e,"unpassQuantity");
var
unpassQuantity
=
e
.
items
[
0
][
'quantity'
]
-
e
.
items
[
0
][
'passQuantity'
];
var
unpassQuantity
=
parseFloat
(
e
.
items
[
0
][
'quantity'
])
resultGrid
.
setCellValue
(
e
.
items
[
0
],
"unpassQuantity"
,
unpassQuantity
);
-
parseFloat
(
e
.
items
[
0
][
'passQuantity'
]);
resultGrid
.
setCellValue
(
e
.
items
[
0
],
"unpassQuantity"
,
unpassQuantity
);
}
}
});
});
},
},
...
...
src/main/webapp/HG/ZL/HGZL002.jsp
View file @
fc8ae48e
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
</EF:EFRegion>
</EF:EFRegion>
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFRegion
id=
"result"
title=
"明细信息"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
>
<EF:EFGrid
blockId=
"result"
autoDraw=
"override"
isFloat=
"true"
checkMode=
"row"
>
<EF:EFColumn
ename=
"id"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"checkBy"
cname=
"质检员"
hidden=
"true"
/>
<EF:EFColumn
ename=
"checkBy"
cname=
"质检员"
hidden=
"true"
/>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
width=
"130"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"companyName"
cname=
"公司名称"
width=
"130"
enable=
"false"
readonly=
"true"
align=
"center"
/>
...
@@ -37,13 +37,14 @@
...
@@ -37,13 +37,14 @@
<EF:EFColumn
ename=
"productCode"
cname=
"存货编码"
width=
"90"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"productCode"
cname=
"存货编码"
width=
"90"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"productName"
cname=
"存货名称"
width=
"90"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"productName"
cname=
"存货名称"
width=
"90"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"quantity"
cname=
"报工数量"
width=
"90"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"quantity"
cname=
"报工数量"
width=
"90"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"passQuantity"
cname=
"合格数量"
width=
"90"
align=
"center"
required=
"true"
/>
<EF:EFColumn
ename=
"passQuantity"
cname=
"合格数量"
format=
"{0:0.0}"
width=
"90"
align=
"center"
required=
"true"
/>
<EF:EFColumn
ename=
"unpassQuantity"
cname=
"不合格数量"
width=
"100"
align=
"center"
required=
"true"
/>
<EF:EFColumn
ename=
"unpassQuantity"
cname=
"不合格数量"
format=
"{0:0.0}"
width=
"100"
align=
"center"
required=
"true"
/>
<EF:EFColumn
ename=
"checkDate"
cname=
"质检日期"
width=
"120"
enable=
"true"
align=
"center"
editType=
"date"
<EF:EFColumn
ename=
"checkDate"
cname=
"质检日期"
width=
"120"
enable=
"true"
align=
"center"
editType=
"date"
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyy-MM-dd']"
required=
"true"
/>
dateFormat=
"yyyy-MM-dd"
parseFormats=
"['yyyy-MM-dd']"
required=
"true"
/>
<EF:EFColumn
ename=
"checkName"
cname=
"质检员"
width=
"100"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"checkName"
cname=
"质检员"
width=
"100"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFComboColumn
ename=
"checkStatus"
cname=
"质检状态"
width=
"80"
align=
"center"
enable=
"false"
<EF:EFComboColumn
ename=
"checkStatus"
cname=
"质检状态"
width=
"80"
align=
"center"
enable=
"false"
readonly=
"true"
>
readonly=
"true"
>
<EF:EFCodeOption
codeName=
"hggp.checkStatus"
/>
<EF:EFCodeOption
codeName=
"hggp.checkStatus"
/>
</EF:EFComboColumn>
</EF:EFComboColumn>
</EF:EFGrid>
</EF:EFGrid>
...
...
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