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
c8c6c7d0
Commit
c8c6c7d0
authored
Aug 08, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://git.pseer.com:8800/platform/hg-smart
into dev-ly
parents
de1d5b47
9bbb3cba
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
70 additions
and
125 deletions
+70
-125
ServiceHGSC003B.java
...java/com/baosight/hggp/hg/sc/service/ServiceHGSC003B.java
+2
-41
ServiceHGSC004B.java
...java/com/baosight/hggp/hg/sc/service/ServiceHGSC004B.java
+2
-41
HGSCTools.java
src/main/java/com/baosight/hggp/hg/sc/tools/HGSCTools.java
+22
-22
HGCG002A.js
src/main/webapp/HG/CG/HGCG002A.js
+4
-1
HGPZ005.js
src/main/webapp/HG/PZ/HGPZ005.js
+40
-20
No files found.
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC003B.java
View file @
c8c6c7d0
...
@@ -5,6 +5,7 @@ import com.baosight.hggp.core.dao.DaoUtils;
...
@@ -5,6 +5,7 @@ import com.baosight.hggp.core.dao.DaoUtils;
import
com.baosight.hggp.core.tools.EDTools
;
import
com.baosight.hggp.core.tools.EDTools
;
import
com.baosight.hggp.hg.ds.domain.HGDS002
;
import
com.baosight.hggp.hg.ds.domain.HGDS002
;
import
com.baosight.hggp.hg.sc.domain.HGSC099
;
import
com.baosight.hggp.hg.sc.domain.HGSC099
;
import
com.baosight.hggp.hg.sc.tools.HGSCTools
;
import
com.baosight.hggp.util.FileUtils
;
import
com.baosight.hggp.util.FileUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.hggp.util.contants.ACConstants
;
...
@@ -109,7 +110,7 @@ public class ServiceHGSC003B extends ServiceEPBase {
...
@@ -109,7 +110,7 @@ public class ServiceHGSC003B extends ServiceEPBase {
hgsc099
.
fromMap
(
resultRows
.
get
(
i
));
hgsc099
.
fromMap
(
resultRows
.
get
(
i
));
DaoUtils
.
update
(
HGSC099
.
DELETE
,
hgsc099
);
DaoUtils
.
update
(
HGSC099
.
DELETE
,
hgsc099
);
if
(!
hgsc099
.
getDocId
().
isEmpty
())
{
if
(!
hgsc099
.
getDocId
().
isEmpty
())
{
this
.
delectDoc
(
hgsc099
.
getDocId
());
HGSCTools
.
THGSC099
.
delectDoc
(
hgsc099
.
getDocId
());
}
}
}
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
=
this
.
query
(
inInfo
);
...
@@ -120,44 +121,4 @@ public class ServiceHGSC003B extends ServiceEPBase {
...
@@ -120,44 +121,4 @@ public class ServiceHGSC003B extends ServiceEPBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
* 删除文件
* @param docId 文件ID
*/
public
void
delectDoc
(
String
docId
){
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"docId"
,
docId
);
List
<
HGDS002
>
list
=
this
.
dao
.
query
(
HGDS002
.
QUERY
,
map
);
if
(
list
.
size
()
>
0
)
{
String
realPath
=
list
.
get
(
0
).
getRealPath
();
// 项目环境
String
projectEnv
=
ProjectInfo
.
getProjectEnv
();
if
(
projectEnv
.
equals
(
CommonConstant
.
projectEnv
.
RUN
))
{
EiInfo
queryInfo
=
new
EiInfo
();
queryInfo
.
set
(
HGSC099
.
FIELD_doc_id
,
list
.
get
(
0
).
getDocId
());
//获取文档信息
queryInfo
.
set
(
EiConstant
.
serviceId
,
"S_EU_0102"
);
EiInfo
docInfo
=
XServiceManager
.
call
(
queryInfo
);
//数据库
Map
docInfoMap
=
docInfo
.
getMap
(
"docMap"
);
if
(
docInfoMap
.
size
()
>
0
)
{
EiInfo
eiInfo
=
new
EiInfo
();
eiInfo
.
set
(
"data"
,
docInfoMap
.
get
(
"url"
)+
"-"
+
0
);
eiInfo
.
set
(
EiConstant
.
serviceId
,
"S_EU_0105"
);
//调用接口
EiInfo
outInfo
=
XServiceManager
.
call
(
eiInfo
);
if
(
outInfo
.
getStatus
()
==
EiConstant
.
STATUS_FAILURE
){
LogUtils
.
setDetailMsg
(
outInfo
,
new
Throwable
(),
"查询部件类型失败"
);
outInfo
.
setMsg
(
"失败"
);
}
}
}
else
{
FileUtils
.
deleteFile
(
realPath
);
}
this
.
dao
.
delete
(
HGDS002
.
DELETE
,
map
);
}
}
}
}
src/main/java/com/baosight/hggp/hg/sc/service/ServiceHGSC004B.java
View file @
c8c6c7d0
...
@@ -6,6 +6,7 @@ import com.baosight.hggp.core.dao.DaoUtils;
...
@@ -6,6 +6,7 @@ import com.baosight.hggp.core.dao.DaoUtils;
import
com.baosight.hggp.core.tools.EDTools
;
import
com.baosight.hggp.core.tools.EDTools
;
import
com.baosight.hggp.hg.ds.domain.HGDS002
;
import
com.baosight.hggp.hg.ds.domain.HGDS002
;
import
com.baosight.hggp.hg.sc.domain.HGSC099
;
import
com.baosight.hggp.hg.sc.domain.HGSC099
;
import
com.baosight.hggp.hg.sc.tools.HGSCTools
;
import
com.baosight.hggp.hg.sj.domain.HGSJ003
;
import
com.baosight.hggp.hg.sj.domain.HGSJ003
;
import
com.baosight.hggp.util.FileUtils
;
import
com.baosight.hggp.util.FileUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.LogUtils
;
...
@@ -109,7 +110,7 @@ public class ServiceHGSC004B extends ServiceEPBase {
...
@@ -109,7 +110,7 @@ public class ServiceHGSC004B extends ServiceEPBase {
hgsc099
.
fromMap
(
resultRows
.
get
(
i
));
hgsc099
.
fromMap
(
resultRows
.
get
(
i
));
DaoUtils
.
update
(
HGSC099
.
DELETE
,
hgsc099
);
DaoUtils
.
update
(
HGSC099
.
DELETE
,
hgsc099
);
if
(!
hgsc099
.
getDocId
().
isEmpty
())
{
if
(!
hgsc099
.
getDocId
().
isEmpty
())
{
this
.
delectDoc
(
hgsc099
.
getDocId
());
HGSCTools
.
THGSC099
.
delectDoc
(
hgsc099
.
getDocId
());
}
}
}
}
inInfo
=
this
.
query
(
inInfo
);
inInfo
=
this
.
query
(
inInfo
);
...
@@ -120,44 +121,4 @@ public class ServiceHGSC004B extends ServiceEPBase {
...
@@ -120,44 +121,4 @@ public class ServiceHGSC004B extends ServiceEPBase {
}
}
return
inInfo
;
return
inInfo
;
}
}
/**
* 删除文件
* @param docId 文件ID
*/
public
void
delectDoc
(
String
docId
){
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"docId"
,
docId
);
List
<
HGDS002
>
list
=
this
.
dao
.
query
(
HGDS002
.
QUERY
,
map
);
if
(
list
.
size
()
>
0
)
{
String
realPath
=
list
.
get
(
0
).
getRealPath
();
// 项目环境
String
projectEnv
=
ProjectInfo
.
getProjectEnv
();
if
(
projectEnv
.
equals
(
CommonConstant
.
projectEnv
.
RUN
))
{
EiInfo
queryInfo
=
new
EiInfo
();
queryInfo
.
set
(
HGSC099
.
FIELD_doc_id
,
list
.
get
(
0
).
getDocId
());
//获取文档信息
queryInfo
.
set
(
EiConstant
.
serviceId
,
"S_EU_0102"
);
EiInfo
docInfo
=
XServiceManager
.
call
(
queryInfo
);
//数据库
Map
docInfoMap
=
docInfo
.
getMap
(
"docMap"
);
if
(
docInfoMap
.
size
()
>
0
)
{
EiInfo
eiInfo
=
new
EiInfo
();
eiInfo
.
set
(
"data"
,
docInfoMap
.
get
(
"url"
)+
"-"
+
0
);
eiInfo
.
set
(
EiConstant
.
serviceId
,
"S_EU_0105"
);
//调用接口
EiInfo
outInfo
=
XServiceManager
.
call
(
eiInfo
);
if
(
outInfo
.
getStatus
()
==
EiConstant
.
STATUS_FAILURE
){
LogUtils
.
setDetailMsg
(
outInfo
,
new
Throwable
(),
"查询部件类型失败"
);
outInfo
.
setMsg
(
"失败"
);
}
}
}
else
{
FileUtils
.
deleteFile
(
realPath
);
}
this
.
dao
.
delete
(
HGDS002
.
DELETE
,
map
);
}
}
}
}
src/main/java/com/baosight/hggp/hg/sc/tools/HGSCTools.java
View file @
c8c6c7d0
...
@@ -1322,29 +1322,29 @@ public class HGSCTools {
...
@@ -1322,29 +1322,29 @@ public class HGSCTools {
String
realPath
=
list
.
get
(
0
).
getRealPath
();
String
realPath
=
list
.
get
(
0
).
getRealPath
();
// 项目环境
// 项目环境
String
projectEnv
=
ProjectInfo
.
getProjectEnv
();
String
projectEnv
=
ProjectInfo
.
getProjectEnv
();
if
(
projectEnv
.
equals
(
CommonConstant
.
projectEnv
.
RUN
))
{
//
if (projectEnv.equals(CommonConstant.projectEnv.RUN)) {
EiInfo
queryInfo
=
new
EiInfo
();
//
EiInfo queryInfo = new EiInfo();
queryInfo
.
set
(
HGSC099
.
FIELD_doc_id
,
list
.
get
(
0
).
getDocId
());
//
queryInfo.set(HGSC099.FIELD_doc_id,list.get(0).getDocId());
//获取文档信息
//
//获取文档信息
queryInfo
.
set
(
EiConstant
.
serviceId
,
"S_EU_0102"
);
//
queryInfo.set(EiConstant.serviceId,"S_EU_0102");
EiInfo
docInfo
=
XServiceManager
.
call
(
queryInfo
);
//
EiInfo docInfo = XServiceManager.call(queryInfo);
//数据库
//
//数据库
Map
docInfoMap
=
docInfo
.
getMap
(
"docMap"
);
//
Map docInfoMap = docInfo.getMap("docMap");
if
(
docInfoMap
.
size
()
>
0
)
{
//
if (docInfoMap.size() > 0) {
EiInfo
eiInfo
=
new
EiInfo
();
//
EiInfo eiInfo = new EiInfo();
eiInfo
.
set
(
"data"
,
docInfoMap
.
get
(
"url"
)+
"-"
+
0
);
//
eiInfo.set("data",docInfoMap.get("url")+"-"+0);
eiInfo
.
set
(
EiConstant
.
serviceId
,
"S_EU_0105"
);
//
eiInfo.set(EiConstant.serviceId,"S_EU_0105");
//调用接口
//
//调用接口
EiInfo
outInfo
=
XServiceManager
.
call
(
eiInfo
);
//
EiInfo outInfo = XServiceManager.call(eiInfo);
//
if
(
outInfo
.
getStatus
()
==
EiConstant
.
STATUS_FAILURE
){
//
if(outInfo.getStatus() == EiConstant.STATUS_FAILURE){
LogUtils
.
setDetailMsg
(
outInfo
,
new
Throwable
(),
"查询部件类型失败"
);
//
LogUtils.setDetailMsg(outInfo, new Throwable(), "查询部件类型失败");
outInfo
.
setMsg
(
"失败"
);
//
outInfo.setMsg("失败");
}
//
}
}
//
}
}
else
{
//
}else {
FileUtils
.
deleteFile
(
realPath
);
FileUtils
.
deleteFile
(
realPath
);
}
//
}
DaoBase
.
getInstance
().
delete
(
HGDS002
.
DELETE
,
map
);
DaoBase
.
getInstance
().
delete
(
HGDS002
.
DELETE
,
map
);
}
}
...
...
src/main/webapp/HG/CG/HGCG002A.js
View file @
c8c6c7d0
$
(
function
()
{
$
(
function
()
{
IPLATUI
.
EFGrid
=
{
IPLATUI
.
EFGrid
=
{
"result"
:
{
"result"
:
{
pageable
:
false
,
pageable
:
{
pageSize
:
20
,
pageSizes
:
[
20
,
50
,
70
,
100
],
},
columns
:
[
columns
:
[
],
],
loadComplete
:
function
(
grid
)
{
loadComplete
:
function
(
grid
)
{
...
...
src/main/webapp/HG/PZ/HGPZ005.js
View file @
c8c6c7d0
...
@@ -6,7 +6,7 @@ $(function() {
...
@@ -6,7 +6,7 @@ $(function() {
$
(
"#QUERY"
).
on
(
"click"
,
query
);
$
(
"#QUERY"
).
on
(
"click"
,
query
);
$
(
"#BATCH_FLOW"
).
on
(
"click"
,
function
()
{
$
(
"#BATCH_FLOW"
).
on
(
"click"
,
function
()
{
showFlowDetail
();
batchFlow
();
});
});
IPLATUI
.
EFGrid
.
result
=
{
IPLATUI
.
EFGrid
.
result
=
{
...
@@ -294,25 +294,45 @@ function showFlowDetail(id,inventCode,flowId) {
...
@@ -294,25 +294,45 @@ function showFlowDetail(id,inventCode,flowId) {
});
});
}
}
// function showFlowDetail() {
function
batchFlow
()
{
// let rows = resultGrid.getCheckedRows();
let
rows
=
resultGrid
.
getCheckedRows
();
// let selectIds = [];
let
selectIds
=
[];
// //selectIds.push(rows[i]['id']);
if
(
rows
.
length
<
1
)
{
// if (rows.length < 1) {
message
(
"请选择数据"
)
// message("请选择数据")
return
;
// return;
}
// }
let
inventType
;
// $.each(rows, function(index, item) {
let
flag
=
true
;
// selectIds.push(item.get("id"));
$
.
each
(
rows
,
function
(
index
,
item
)
{
// });
selectIds
.
push
(
item
.
get
(
"id"
));
// JSColorbox.open({
//不存在就直接赋值
// href: "HGPZ005B?methodName=initLoad&inqu_status-0-parentIds=" + selectIds,
if
(
!
inventType
){
// title: "<div style='text-align: center;'>工艺流程</div>",
inventType
=
item
.
get
(
"inventType"
)
// width: "75%",
}
else
{
// height: "80%",
//存在就与当前类型对比
// callbackName: cllback2
if
(
inventType
!=
item
.
get
(
"inventType"
)){
// });
message
(
"只能选择同一个类型存货"
)
// }
flag
=
false
;
return
false
;
}
}
if
(
item
.
get
(
"flowId"
)
>
0
){
message
(
"只能选择未分配的存货"
)
flag
=
false
;
return
false
;
}
});
if
(
flag
){
JSColorbox
.
open
({
href
:
"HGPZ005B?methodName=initLoad&inqu_status-0-parentIds="
+
selectIds
,
title
:
"<div style='text-align: center;'>工艺流程</div>"
,
width
:
"75%"
,
height
:
"80%"
,
callbackName
:
cllback2
});
}
}
/**
/**
* 回调
* 回调
...
...
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