Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
K
kwell-mes
Project
Project
Details
Activity
Releases
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
gavelinfo
kwell-mes
Commits
32d39f22
Commit
32d39f22
authored
Mar 14, 2022
by
yff
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改装配BUG
parent
1280849b
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
82 additions
and
34 deletions
+82
-34
GpfkDao.java
gavel/src/main/java/com/gavel/kwell/dao/GpfkDao.java
+2
-0
GpfkDaoImpl.java
...l/src/main/java/com/gavel/kwell/dao/impl/GpfkDaoImpl.java
+34
-0
GphyDaoImpl.java
...l/src/main/java/com/gavel/kwell/dao/impl/GphyDaoImpl.java
+1
-1
GpfkServiceImpl.java
...in/java/com/gavel/kwell/service/impl/GpfkServiceImpl.java
+31
-32
GphyServiceImpl.java
...in/java/com/gavel/kwell/service/impl/GphyServiceImpl.java
+13
-0
SmCodeEnum.java
gavel/src/main/java/com/gavel/kwell/utils/SmCodeEnum.java
+1
-1
No files found.
gavel/src/main/java/com/gavel/kwell/dao/GpfkDao.java
View file @
32d39f22
...
@@ -130,4 +130,6 @@ public interface GpfkDao extends BaseDao {
...
@@ -130,4 +130,6 @@ public interface GpfkDao extends BaseDao {
public
double
getNowGyFksl
(
Wogylx
wogylx
);
public
double
getNowGyFksl
(
Wogylx
wogylx
);
public
List
<
WobomVO
>
queryWobomByFkidAndWlid
(
String
fkid
,
String
wlid
,
String
bzlx
);
}
}
gavel/src/main/java/com/gavel/kwell/dao/impl/GpfkDaoImpl.java
View file @
32d39f22
...
@@ -1308,6 +1308,40 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
...
@@ -1308,6 +1308,40 @@ public class GpfkDaoImpl extends BaseDaoImpl implements GpfkDao {
return
sqlMap
.
queryDouble
();
return
sqlMap
.
queryDouble
();
}
}
@Override
public
List
<
WobomVO
>
queryWobomByFkidAndWlid
(
String
fkid
,
String
wlid
,
String
bzlx
)
{
SqlMap
sqlMap
=
new
SqlMap
();
sqlMap
.
append
(
"select WOBOM_ID, WOBOM_XH, WOBOM_WOID, WOBOM_WLID, WOBOM_FFGX,"
);
sqlMap
.
append
(
" WOBOM_DWYL, WOBOM_XQSL, WOBOM_XQRQ, WOBOM_SHL, WOBOM_SHZ, WOBOM_FFYZ,"
);
sqlMap
.
append
(
" WOBOM_LLSL, WOBOM_CKSL, WOBOM_BZ, WOBOM_WHRID, WOBOM_WHR,"
);
sqlMap
.
append
(
" WOBOM_WHSJ, WOBOM_CJRID, WOBOM_CJR, WOBOM_CJSJ, WOBOM_SYSVERSION,"
);
sqlMap
.
append
(
" WLXX_CODE, WLXX_NAME, WLXX_GG, WOBOM_GJWL, WOBOM_ZT, WOBOM_DJLY,"
);
sqlMap
.
append
(
" WOGYLX_XH, WOGYLX_NAME, WOBOM_WLPH "
);
sqlMap
.
append
(
"from WOBOM"
);
sqlMap
.
append
(
" left join WLXX on WLXX_ID = WOBOM_WLID"
);
sqlMap
.
append
(
" left join WO on WO_ID = WOBOM_WOID"
);
sqlMap
.
append
(
" left join WOSN on WOSN_WOID = WO_ID"
);
sqlMap
.
append
(
" left join WOGYLX on WOGYLX_WOID = WO_ID "
);
sqlMap
.
append
(
" left join BZGX on BZGX_ID = WOGYLX_BZGXID and BZGX_ID = WOBOM_FFGX"
);
sqlMap
.
append
(
" left join GPFK on GPFK_WOSNID = WOSN_CODE and GPFK_FKGX= BZGX_ID and GPFK_WOGYLX =WOGYLX_ID"
);
sqlMap
.
append
(
"where 1=1"
);
if
(
StringUtils
.
isNotEmpty
(
bzlx
)){
sqlMap
.
append
(
" and "
+
SqlUtil
.
getWhereSql
(
"BZGX_ID"
,
bzlx
));
sqlMap
.
setParamValue
(
"BZGX_ID"
,
bzlx
);
}
if
(
StringUtils
.
isNotEmpty
(
wlid
)){
sqlMap
.
append
(
" and "
+
SqlUtil
.
getWhereSql
(
"WLXX_ID"
,
wlid
));
sqlMap
.
setParamValue
(
"WLXX_ID"
,
wlid
);
}
if
(
StringUtils
.
isNotEmpty
(
fkid
)){
sqlMap
.
append
(
" and "
+
SqlUtil
.
getWhereSql
(
"GPFK_ID"
,
fkid
));
sqlMap
.
setParamValue
(
"GPFK_ID"
,
fkid
);
}
sqlMap
.
append
(
"order by WOBOM_XH, WLXX_CODE"
);
System
.
out
.
println
(
sqlMap
.
getSqlText
());
return
sqlMap
.
query
(
WobomVO
.
class
);
}
}
}
gavel/src/main/java/com/gavel/kwell/dao/impl/GphyDaoImpl.java
View file @
32d39f22
...
@@ -165,7 +165,7 @@ public class GphyDaoImpl extends BaseDaoImpl implements GphyDao {
...
@@ -165,7 +165,7 @@ public class GphyDaoImpl extends BaseDaoImpl implements GphyDao {
sqlMap
.
append
(
" group by GPHY_MID) b on b.fkid =a.fkid "
);
sqlMap
.
append
(
" group by GPHY_MID) b on b.fkid =a.fkid "
);
sqlMap
.
append
(
"where 1 = 1 "
);
sqlMap
.
append
(
"where 1 = 1 "
);
if
(
StringUtils
.
isNotEmpty
(
condition
.
getMid
())){
if
(
StringUtils
.
isNotEmpty
(
condition
.
getMid
())){
sqlMap
.
append
(
" and b.fkid =
"
+
condition
.
getMid
()
);
sqlMap
.
append
(
" and b.fkid =
'"
+
condition
.
getMid
()+
"'"
);
}
}
System
.
out
.
println
(
sqlMap
.
getSqlText
());
System
.
out
.
println
(
sqlMap
.
getSqlText
());
return
sqlMap
.
queryInt
();
return
sqlMap
.
queryInt
();
...
...
gavel/src/main/java/com/gavel/kwell/service/impl/GpfkServiceImpl.java
View file @
32d39f22
...
@@ -740,7 +740,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
...
@@ -740,7 +740,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
List
<
SmCodeModel
>
smCodeModels
=
SmCodeEnum
.
toList
();
List
<
SmCodeModel
>
smCodeModels
=
SmCodeEnum
.
toList
();
if
(
smCodeModels
!=
null
&&
smCodeModels
.
size
()>
0
)
{
if
(
smCodeModels
!=
null
&&
smCodeModels
.
size
()>
0
)
{
for
(
SmCodeModel
smCodeModel:
smCodeModels
)
{
for
(
SmCodeModel
smCodeModel:
smCodeModels
)
{
if
(
snid
.
toUpperCase
().
contains
(
smCodeModel
.
getPrefix
()))
{
if
(
snid
.
toUpperCase
().
startsWith
(
smCodeModel
.
getPrefix
()))
{
return
smCodeModel
;
return
smCodeModel
;
}
}
}
}
...
@@ -772,7 +772,6 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
...
@@ -772,7 +772,6 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
gpfkCondition
.
setWosnid
(
wosn
);
gpfkCondition
.
setWosnid
(
wosn
);
gpfkCondition
.
setBzgxid
(
bzlx
);
gpfkCondition
.
setBzgxid
(
bzlx
);
GpfkVO
gpfkVo
=
gpfkDao
.
queryKwellGpfkByWosnAndGxid
(
gpfkCondition
);
GpfkVO
gpfkVo
=
gpfkDao
.
queryKwellGpfkByWosnAndGxid
(
gpfkCondition
);
if
(
gpfkVo
==
null
)
{
WolinkInfoVO
wolinkInfoVO
=
gpfkDao
.
queryKwellWoBySnid
(
wosn
,
bzlx
);
WolinkInfoVO
wolinkInfoVO
=
gpfkDao
.
queryKwellWoBySnid
(
wosn
,
bzlx
);
if
(
wolinkInfoVO
==
null
)
{
if
(
wolinkInfoVO
==
null
)
{
throwReturnMessage
(
"不存在对应订单序号标准类型信息"
);
throwReturnMessage
(
"不存在对应订单序号标准类型信息"
);
...
@@ -782,9 +781,9 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
...
@@ -782,9 +781,9 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
Wogylx
existLastWogylx
=
gpfkDao
.
getLastGx
(
wogylx
);
Wogylx
existLastWogylx
=
gpfkDao
.
getLastGx
(
wogylx
);
if
(
existLastWogylx
!=
null
){
if
(
existLastWogylx
!=
null
){
GpfkCondition
gpfkCondition2
=
new
GpfkCondition
();
GpfkCondition
gpfkCondition2
=
new
GpfkCondition
();
gpfkCondition
.
setWogylx
(
existLastWogylx
.
getId
());
gpfkCondition2
.
setWogylx
(
existLastWogylx
.
getId
());
gpfkCondition
.
setWosnid
(
wosn
);
gpfkCondition2
.
setWosnid
(
wosn
);
gpfkCondition
.
setBzgxid
(
existLastWogylx
.
getBzgxid
());
gpfkCondition2
.
setBzgxid
(
existLastWogylx
.
getBzgxid
());
GpfkVO
gpfk2
=
gpfkDao
.
queryKwellGpfkByWosnAndGxid
(
gpfkCondition2
);
GpfkVO
gpfk2
=
gpfkDao
.
queryKwellGpfkByWosnAndGxid
(
gpfkCondition2
);
if
(
gpfk2
!=
null
)
{
if
(
gpfk2
!=
null
)
{
if
(
existLastWogylx
.
getGylxid
().
equals
(
HzGylxEnum
.
ZP
.
getId
()))
{
if
(
existLastWogylx
.
getGylxid
().
equals
(
HzGylxEnum
.
ZP
.
getId
()))
{
...
@@ -803,7 +802,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
...
@@ -803,7 +802,7 @@ public class GpfkServiceImpl extends BaseEditServiceImpl implements GpfkService
if
(!
wolinkInfoVO
.
getWozt
().
equals
(
"R"
))
{
if
(!
wolinkInfoVO
.
getWozt
().
equals
(
"R"
))
{
throwReturnMessage
(
"订单未下达"
);
throwReturnMessage
(
"订单未下达"
);
}
}
/**判断上一道工序**/
if
(
gpfkVo
==
null
)
{
Gpfk
gpfk
=
new
Gpfk
();
Gpfk
gpfk
=
new
Gpfk
();
gpfk
.
setWosnid
(
wolinkInfoVO
.
getWosnCode
());
gpfk
.
setWosnid
(
wolinkInfoVO
.
getWosnCode
());
gpfk
.
setWogylx
(
wolinkInfoVO
.
getWogylxid
());
gpfk
.
setWogylx
(
wolinkInfoVO
.
getWogylxid
());
...
...
gavel/src/main/java/com/gavel/kwell/service/impl/GphyServiceImpl.java
View file @
32d39f22
...
@@ -23,7 +23,9 @@ import com.gavel.kwell.vo.GphyVO;
...
@@ -23,7 +23,9 @@ import com.gavel.kwell.vo.GphyVO;
import
com.gavel.kwell.vo.GphycxVO
;
import
com.gavel.kwell.vo.GphycxVO
;
import
com.gavel.kwell.vo.WlslItem
;
import
com.gavel.kwell.vo.WlslItem
;
import
com.gavel.persistence.sql.RecordSet
;
import
com.gavel.persistence.sql.RecordSet
;
import
com.gavel.wo.persistent.Wobom
;
import
com.gavel.wo.persistent.Wogylx
;
import
com.gavel.wo.persistent.Wogylx
;
import
com.gavel.wo.vo.WobomVO
;
@Service
(
"gphyService"
)
@Service
(
"gphyService"
)
...
@@ -74,7 +76,18 @@ public class GphyServiceImpl extends BaseEditServiceImpl implements GphyService
...
@@ -74,7 +76,18 @@ public class GphyServiceImpl extends BaseEditServiceImpl implements GphyService
@Override
@Override
public
Gpfk
zpwl
(
GphyCondition
condition
)
{
public
Gpfk
zpwl
(
GphyCondition
condition
)
{
List
<
GphyVO
>
dbGphy
=
gphyDao
.
queryKwellZpGphy
(
condition
).
getRecords
();
if
(
dbGphy
!=
null
&&
dbGphy
.
size
()>
0
)
{
throwReturnMessage
(
"该序列号已经被扫描"
);
}
String
wlid
=
coderuleService
.
matchCodeByRule
(
condition
.
getSnid
());
String
wlid
=
coderuleService
.
matchCodeByRule
(
condition
.
getSnid
());
if
(
StringUtils
.
isEmpty
(
wlid
))
{
throwReturnMessage
(
"不存在该物料"
);
}
List
<
WobomVO
>
woboms
=
gpfkDao
.
queryWobomByFkidAndWlid
(
condition
.
getMid
(),
wlid
,
condition
.
getGxid
());
if
(
woboms
==
null
||
woboms
.
size
()<=
0
)
{
throwReturnMessage
(
"该订单不存在该物料"
);
}
if
(
compareIsZpComplete
(
condition
.
getFkid
(),
wlid
))
{
if
(
compareIsZpComplete
(
condition
.
getFkid
(),
wlid
))
{
Gphy
gphy
=
new
Gphy
();
Gphy
gphy
=
new
Gphy
();
gphy
.
setFkgx
(
condition
.
getGxid
());
gphy
.
setFkgx
(
condition
.
getGxid
());
...
...
gavel/src/main/java/com/gavel/kwell/utils/SmCodeEnum.java
View file @
32d39f22
...
@@ -7,7 +7,7 @@ public enum SmCodeEnum {
...
@@ -7,7 +7,7 @@ public enum SmCodeEnum {
LOGOUT
(
"LOGOUT"
,
"退出"
,
"LOGOUT"
,
10
),
LOGOUT
(
"LOGOUT"
,
"退出"
,
"LOGOUT"
,
10
),
WOSNID
(
"WOSNID"
,
"工单序列号"
,
"2
0
"
,
10
),
WOSNID
(
"WOSNID"
,
"工单序列号"
,
"2"
,
10
),
// WLID("WLID","物料编码","D",10),
// WLID("WLID","物料编码","D",10),
OKBZ
(
"OKBZ"
,
"OK按钮"
,
"OK"
,
10
),
OKBZ
(
"OKBZ"
,
"OK按钮"
,
"OK"
,
10
),
NGBZ
(
"NGBZ"
,
"NG按钮"
,
"NG"
,
10
);
NGBZ
(
"NGBZ"
,
"NG按钮"
,
"NG"
,
10
);
...
...
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