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
d5ffacd8
Commit
d5ffacd8
authored
May 27, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2024-05-27
1、更改设备计划重复添加提示 2、维保申请附件删除逻辑调整 3、设备点检详情点检附件多条上传 4、设备保养详情保养附件多条上传
parent
2925a238
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
61 additions
and
41 deletions
+61
-41
ServiceHGSB002A.java
...java/com/baosight/hggp/hg/sb/service/ServiceHGSB002A.java
+4
-6
ServiceHGSB099.java
.../java/com/baosight/hggp/hg/sb/service/ServiceHGSB099.java
+3
-1
HGSBTools.java
src/main/java/com/baosight/hggp/hg/sb/tools/HGSBTools.java
+10
-0
HGSB002A.jsp
src/main/webapp/HG/SB/HGSB002A.jsp
+6
-6
HGSB003.js
src/main/webapp/HG/SB/HGSB003.js
+4
-4
HGSB004.js
src/main/webapp/HG/SB/HGSB004.js
+3
-3
HGSB004A.js
src/main/webapp/HG/SB/HGSB004A.js
+8
-7
HGSB004A.jsp
src/main/webapp/HG/SB/HGSB004A.jsp
+2
-1
HGSB005.js
src/main/webapp/HG/SB/HGSB005.js
+3
-3
HGSB005A.js
src/main/webapp/HG/SB/HGSB005A.js
+8
-7
HGSB005A.jsp
src/main/webapp/HG/SB/HGSB005A.jsp
+2
-1
HGSB006.js
src/main/webapp/HG/SB/HGSB006.js
+1
-1
HGSB099.js
src/main/webapp/HG/SB/HGSB099.js
+6
-1
HGSB099.jsp
src/main/webapp/HG/SB/HGSB099.jsp
+1
-0
No files found.
src/main/java/com/baosight/hggp/hg/sb/service/ServiceHGSB002A.java
View file @
d5ffacd8
...
...
@@ -91,23 +91,21 @@ public class ServiceHGSB002A extends ServiceEPBase {
List
<
Map
>
resultRows
=
inInfo
.
getBlock
(
EiConstant
.
resultBlock
).
getRows
();
Long
parentId
=
Long
.
valueOf
(
inInfo
.
getCellStr
(
EiConstant
.
queryBlock
,
ACConstants
.
ROW_CODE_0
,
HGSB002A
.
FIELD_PARENT_ID
));
HGSB002
hgsb002
=
HGSBTools
.
Hgsb002
.
get
(
parentId
);
List
<
HGSB002A
>
hgsb002AList
=
HGSBTools
.
Hgsb002
.
getDetails
(
parentId
);
// 写入数据
for
(
Map
resultRow
:
resultRows
)
{
HGSB002A
hgsb002a
=
new
HGSB002A
();
hgsb002a
.
fromMap
(
resultRow
);
// 状态==1抛出异常
if
(
hgsb002
.
getPlanStatus
()==
1
)
{
String
str
=
"设备计划已审批完成,保存失败!"
;
throw
new
PlatException
(
str
);
throw
new
PlatException
(
"设备计划已审批完成,保存失败!"
);
}
if
(
hgsb002a
.
getId
()
==
null
||
hgsb002a
.
getId
()
==
0
)
{
List
<
HGSB002A
>
hgsb002AList
=
HGSBTools
.
Hgsb002
.
getDetails
(
parentId
);
for
(
HGSB002A
hgsb002a1:
hgsb002AList
)
{
if
(
hgsb002a1
.
getDeviceCode
().
equals
(
hgsb002a
.
getDeviceCode
()))
{
String
str
=
String
.
format
(
"无法重复添加!"
);
throw
new
PlatException
(
str
);
throw
new
PlatException
(
"无法重复添加!"
);
}
}
if
(
hgsb002a
.
getId
()
==
null
||
hgsb002a
.
getId
()
==
0
)
{
hgsb002a
.
setParentId
(
parentId
);
this
.
add
(
hgsb002a
);
}
else
{
...
...
src/main/java/com/baosight/hggp/hg/sb/service/ServiceHGSB099.java
View file @
d5ffacd8
package
com
.
baosight
.
hggp
.
hg
.
sb
.
service
;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.hg.ds.domain.HGDS002
;
...
...
@@ -49,6 +50,7 @@ public class ServiceHGSB099 extends ServiceEPBase {
return
inInfo
;
}
@OperationLogAnnotation
(
operModul
=
"设备附件详情"
,
operType
=
"删除"
,
operDesc
=
"删除操作"
)
@Override
public
EiInfo
delete
(
EiInfo
inInfo
)
{
try
{
...
...
@@ -69,7 +71,7 @@ public class ServiceHGSB099 extends ServiceEPBase {
}
return
inInfo
;
}
@OperationLogAnnotation
(
operModul
=
"设备附件详情"
,
operType
=
"新增"
,
operDesc
=
"新增操作"
)
@Override
public
EiInfo
insert
(
EiInfo
inInfo
)
{
try
{
...
...
src/main/java/com/baosight/hggp/hg/sb/tools/HGSBTools.java
View file @
d5ffacd8
...
...
@@ -117,6 +117,16 @@ public class HGSBTools {
return
results
;
}
/**
* 查询设备计划详情
*
* @param queryMap
*/
public
static
List
<
HGSB002A
>
getDetails
(
Map
queryMap
)
{
queryMap
.
put
(
HGSB002A
.
FIELD_DELETE_FLAG
,
CommonConstant
.
YesNo
.
NO_0
);
List
<
HGSB002A
>
results
=
DaoBase
.
getInstance
().
query
(
HGSB002A
.
QUERY
,
queryMap
);
return
results
;
}
}
/**
...
...
src/main/webapp/HG/SB/HGSB002A.jsp
View file @
d5ffacd8
...
...
@@ -36,24 +36,24 @@
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true">
<EF:EFColumn ename="id" primaryKey="true" cname="内码" hidden="true"/>
<EF:EFColumn ename="accountCode" cname="账套" hidden="true"/>
<EF:EFComboColumn ename="groupCode" cname="设备区域"
enable="fals
e"
<EF:EFComboColumn ename="groupCode" cname="设备区域"
readonly="tru
e"
columnTemplate="#=textField#" itemTemplate="#=textField#"
textField="textField" valueField="valueField"
maxLength="16"
readonly="false"
width="120" required="true"
maxLength="16" width="120" required="true"
align="center" filter="contains" sort="true">
<EF:EFOptions blockId="group_record_block_id" textField="textField" valueField="valueField"/>
</EF:EFComboColumn>
<EF:EFComboColumn ename="deviceType" cname="设备类型"
<EF:EFComboColumn ename="deviceType" cname="设备类型"
readonly="true"
columnTemplate="#=textField#" itemTemplate="#=textField#"
textField="textField" valueField="valueField"
maxLength="16" width="80" re
adonly="false" re
quired="true"
maxLength="16" width="80" required="true"
align="center" filter="contains" sort="true">
<EF:EFCodeOption codeName="hpjx.hpsb.deviceType" />
</EF:EFComboColumn>
<EF:EFComboColumn ename="deviceCode" cname="设备名称"
<EF:EFComboColumn ename="deviceCode" cname="设备名称"
readonly="true"
columnTemplate="#=textField#" itemTemplate="#=textField#"
textField="textField" valueField="valueField"
maxLength="16"
readonly="false"
width="120" required="true"
maxLength="16" width="120" required="true"
align="center" filter="contains" sort="true">
<EF:EFOptions blockId="deviceCodeBox_block_id" textField="textField" valueField="valueField"/>
</EF:EFComboColumn>
...
...
src/main/webapp/HG/SB/HGSB003.js
View file @
d5ffacd8
...
...
@@ -30,7 +30,7 @@ $(function () {
let
template
=
''
;
if
(
item
.
id
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="uploadFile('
+
item
.
id
+
')" >附件详情</a>'
;
+
'onclick="uploadFile('
+
item
.
id
+
'
,
\'
'
+
item
.
status
+
'
\'
)" >附件详情</a>'
;
}
if
(
item
.
id
)
{
if
(
auditStatus
==
0
)
{
...
...
@@ -274,10 +274,10 @@ function updateStatus(id,deviceStatus) {
*
* @param id
*/
function
uploadFile
(
id
)
{
function
uploadFile
(
id
,
status
)
{
JSColorbox
.
open
({
href
:
"HGSB099?methodName=initLoad&inqu_status-0-matId="
+
id
+
"&inqu_status-0-bizType=SB003
"
,
title
:
"<div style='text-align: center;'>附件
上传
</div>"
,
href
:
"HGSB099?methodName=initLoad&inqu_status-0-matId="
+
id
+
"&inqu_status-0-bizType=SB003
&inqu_status-0-checkStatus="
+
status
,
title
:
"<div style='text-align: center;'>附件
详情
</div>"
,
width
:
"60%"
,
height
:
"50%"
,
//callbackName: uploadFileCallback
...
...
src/main/webapp/HG/SB/HGSB004.js
View file @
d5ffacd8
...
...
@@ -31,7 +31,7 @@ $(function () {
let
template
=
''
;
if
(
item
.
companyCode
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDetail('
+
item
.
id
+
',
\'
'
+
item
.
companyCode
+
'
\'
,
\'
'
+
item
.
companyName
+
'
\'
)" >点检详情</a>'
;
+
'onclick="showDetail('
+
item
.
id
+
',
\'
'
+
item
.
companyCode
+
'
\'
,
\'
'
+
item
.
companyName
+
'
\'
,
\'
'
+
item
.
checkStatus
+
'
\'
)" >点检详情</a>'
;
if
(
auditStatus
==
0
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="updateStatus('
+
item
.
id
+
',1)" >审批完成</a>'
;
...
...
@@ -273,9 +273,9 @@ function updateStatus(id,deviceStatus) {
/**
* 显示详情
*/
function
showDetail
(
id
,
companyCode
,
companyName
)
{
function
showDetail
(
id
,
companyCode
,
companyName
,
checkStatus
)
{
JSColorbox
.
open
({
href
:
"HGSB004A?methodName=initLoad&inqu_status-0-parentId="
+
id
+
"&inqu_status-0-companyCode="
+
companyCode
+
"&inqu_status-0-companyName="
+
companyName
,
href
:
"HGSB004A?methodName=initLoad&inqu_status-0-parentId="
+
id
+
"&inqu_status-0-companyCode="
+
companyCode
+
"&inqu_status-0-companyName="
+
companyName
+
"&inqu_status-0-checkStatus="
+
checkStatus
,
title
:
"<div style='text-align: center;'>设备点检详情</div>"
,
width
:
"80%"
,
height
:
"80%"
,
...
...
src/main/webapp/HG/SB/HGSB004A.js
View file @
d5ffacd8
...
...
@@ -29,7 +29,7 @@ $(function () {
let
template
=
''
;
if
(
item
.
id
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="uploadFile('
+
item
.
id
+
')" >附件
上传
</a>'
;
+
'onclick="uploadFile('
+
item
.
id
+
')" >附件
详情
</a>'
;
}
return
template
;
...
...
@@ -55,7 +55,7 @@ $(function () {
}
return
dataItem
[
"deviceCode"
]
}
},
{
}
/*
, {
field: "docId",
template: function (item) {
let template = '';
...
...
@@ -65,7 +65,7 @@ $(function () {
}
return template;
}
}
}
*/
],
exportGrid
:
{
exportFileName
:
function
(
gridInstance
)
{
...
...
@@ -191,12 +191,13 @@ let save = function (btnNode) {
* @param id
*/
function
uploadFile
(
id
)
{
let
checkStatus
=
$
(
"#inqu_status-0-checkStatus"
).
val
();
JSColorbox
.
open
({
href
:
"HGSB0
03A?methodName=initLoad&inqu_status-0-id="
+
id
,
title
:
"<div style='text-align: center;'>附件
上传
</div>"
,
width
:
"
6
0%"
,
href
:
"HGSB0
99?methodName=initLoad&inqu_status-0-matId="
+
id
+
"&inqu_status-0-bizType=SB004&inqu_status-0-checkStatus="
+
checkStatus
,
title
:
"<div style='text-align: center;'>附件
详情
</div>"
,
width
:
"
7
0%"
,
height
:
"50%"
,
callbackName
:
uploadFileCallback
//
callbackName: uploadFileCallback
});
}
...
...
src/main/webapp/HG/SB/HGSB004A.jsp
View file @
d5ffacd8
...
...
@@ -28,6 +28,7 @@
</EF:EFSelect>
<EF:EFInput blockId="inqu_status" row="0" ename="checkItem" cname="检查项" placeholder="模糊查询" colWidth="3"/>
<EF:EFInput blockId="inqu_status" row="0" ename="parentId" cname="上级ID" colWidth="3" type="hidden"/>
<EF:EFInput blockId="inqu_status" row="0" ename="checkStatus" cname="审核状态" colWidth="3" type="hidden"/>
</div>
</EF:EFRegion>
...
...
@@ -53,7 +54,7 @@
<EF:EFColumn ename="checkItem" cname="检查项" width="100" enable="true" readonly="true" align="center" required="true"/>
<EF:EFColumn ename="checkDescrip" cname="检查描述" editType="textarea" width="160" align="center"/>
<EF:EFColumn ename="checkResult" cname="检查结果" editType="textarea" width="160" align="center"/>
<
EF:EFColumn ename="docId" cname="点检图片" width="100" enable="false" readonly="true" align="center"/
>
<
%--<EF:EFColumn ename="docId" cname="点检图片" width="100" enable="false" readonly="true" align="center"/>--%
>
<EF:EFColumn cname="创建人" ename="createdName" align="center" width="100" readonly="true" required="false"
enable="false"/>
<EF:EFColumn cname="创建时间" ename="createdTime" parseFormats="['yyyyMMddHHmmss']" editType="datetime"
...
...
src/main/webapp/HG/SB/HGSB005.js
View file @
d5ffacd8
...
...
@@ -31,7 +31,7 @@ $(function () {
let
template
=
''
;
if
(
item
.
companyCode
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="showDetail('
+
item
.
id
+
',
\'
'
+
item
.
companyCode
+
'
\'
,
\'
'
+
item
.
companyName
+
'
\'
)" >保养详情</a>'
;
+
'onclick="showDetail('
+
item
.
id
+
',
\'
'
+
item
.
companyCode
+
'
\'
,
\'
'
+
item
.
companyName
+
'
\'
,
\'
'
+
item
.
checkStatus
+
'
\'
)" >保养详情</a>'
;
if
(
auditStatus
==
0
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="updateStatus('
+
item
.
id
+
',1)" >审批完成</a>'
;
...
...
@@ -273,9 +273,9 @@ function updateStatus(id,deviceStatus) {
/**
* 显示详情
*/
function
showDetail
(
id
,
companyCode
,
companyName
)
{
function
showDetail
(
id
,
companyCode
,
companyName
,
checkStatus
)
{
JSColorbox
.
open
({
href
:
"HGSB005A?methodName=initLoad&inqu_status-0-parentId="
+
id
+
"&inqu_status-0-companyCode="
+
companyCode
+
"&inqu_status-0-companyName="
+
companyName
,
href
:
"HGSB005A?methodName=initLoad&inqu_status-0-parentId="
+
id
+
"&inqu_status-0-companyCode="
+
companyCode
+
"&inqu_status-0-companyName="
+
companyName
+
"&inqu_status-0-checkStatus="
+
checkStatus
,
title
:
"<div style='text-align: center;'>设备保养详情</div>"
,
width
:
"80%"
,
height
:
"80%"
,
...
...
src/main/webapp/HG/SB/HGSB005A.js
View file @
d5ffacd8
...
...
@@ -23,7 +23,7 @@ $(function () {
let
template
=
''
;
if
(
item
.
id
)
{
template
+=
'<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
+
'onclick="uploadFile('
+
item
.
id
+
')" >附件
上传
</a>'
;
+
'onclick="uploadFile('
+
item
.
id
+
')" >附件
详情
</a>'
;
}
return
template
;
...
...
@@ -49,7 +49,7 @@ $(function () {
}
return
dataItem
[
"deviceCode"
]
}
},
{
}
/*
, {
field: "docId",
template: function (item) {
let template = '';
...
...
@@ -59,7 +59,7 @@ $(function () {
}
return template;
}
}
}
*/
],
exportGrid
:
{
exportFileName
:
function
(
gridInstance
)
{
...
...
@@ -185,12 +185,13 @@ let save = function (btnNode) {
* @param id
*/
function
uploadFile
(
id
)
{
let
checkStatus
=
$
(
"#inqu_status-0-checkStatus"
).
val
();
JSColorbox
.
open
({
href
:
"HGSB0
03A?methodName=initLoad&inqu_status-0-id="
+
id
,
title
:
"<div style='text-align: center;'>附件
上传
</div>"
,
href
:
"HGSB0
99?methodName=initLoad&inqu_status-0-matId="
+
id
+
"&inqu_status-0-bizType=SB005&inqu_status-0-checkStatus="
+
checkStatus
,
title
:
"<div style='text-align: center;'>附件
详情
</div>"
,
width
:
"60%"
,
height
:
"
5
0%"
,
callbackName
:
uploadFileCallback
height
:
"
6
0%"
,
//
callbackName: uploadFileCallback
});
}
...
...
src/main/webapp/HG/SB/HGSB005A.jsp
View file @
d5ffacd8
...
...
@@ -28,6 +28,7 @@
</EF:EFSelect>
<EF:EFInput blockId="inqu_status" row="0" ename="checkItem" cname="检查项" placeholder="模糊查询" colWidth="3"/>
<EF:EFInput blockId="inqu_status" row="0" ename="parentId" cname="上级ID" colWidth="3" type="hidden"/>
<EF:EFInput blockId="inqu_status" row="0" ename="checkStatus" cname="审核状态" colWidth="3" type="hidden"/>
</div>
</EF:EFRegion>
...
...
@@ -53,7 +54,7 @@
<EF:EFColumn ename="checkItem" cname="检查项" width="100" enable="true" readonly="true" align="center" required="true"/>
<EF:EFColumn ename="checkDescrip" cname="检查描述" editType="textarea" width="160" align="center"/>
<EF:EFColumn ename="checkResult" cname="检查结果" editType="textarea" width="160" align="center"/>
<
EF:EFColumn ename="docId" cname="点检图片" width="100" enable="false" readonly="true" align="center"/
>
<
%--<EF:EFColumn ename="docId" cname="点检图片" width="100" enable="false" readonly="true" align="center"/>--%
>
<EF:EFColumn cname="创建人" ename="createdName" align="center" width="100" readonly="true" required="false"
enable="false"/>
<EF:EFColumn cname="创建时间" ename="createdTime" parseFormats="['yyyyMMddHHmmss']" editType="datetime"
...
...
src/main/webapp/HG/SB/HGSB006.js
View file @
d5ffacd8
...
...
@@ -43,7 +43,7 @@ $(function () {
template
:
function
(
item
)
{
let
earlyStatus
;
if
(
!
isBlank
(
item
.
checkResult
.
trim
())
||
!
isBlank
(
item
.
docId
.
trim
())){
earlyStatus
=
"<span>已完成</span>"
;
;
earlyStatus
=
"<span>已完成</span>"
;
}
else
if
(
item
.
remainderDays
==
0
){
earlyStatus
=
"<span style='color: #67c20b'>点检期</span>"
;
}
else
if
(
item
.
remainderDays
<
0
){
...
...
src/main/webapp/HG/SB/HGSB099.js
View file @
d5ffacd8
...
...
@@ -55,7 +55,7 @@ function uploadFile(id) {
href
:
"HGSB003A?methodName=initLoad&inqu_status-0-bizType="
+
$
(
"#inqu_status-0-bizType"
).
val
()
+
"&inqu_status-0-matId="
+
$
(
"#inqu_status-0-matId"
).
val
(),
title
:
"<div style='text-align: center;'>附件上传</div>"
,
width
:
"60%"
,
height
:
"
5
0%"
,
height
:
"
7
0%"
,
callbackName
:
uploadFileCallback
});
}
...
...
@@ -95,6 +95,11 @@ function deleteFunc() {
message
(
"请先勾选数据!"
);
return
;
}
let
checkStatus
=
$
(
"#inqu_status-0-checkStatus"
).
val
();
if
(
checkStatus
==
1
){
message
(
"审批完成,不能删除!"
);
return
;
}
JSUtils
.
confirm
(
"确定对勾选中的["
+
rows
.
length
+
"]条数据做
\"
删除
\"
操作?"
,
{
ok
:
function
()
{
JSUtils
.
submitGridsData
(
"result"
,
"HGSB099"
,
"delete"
,
true
);
...
...
src/main/webapp/HG/SB/HGSB099.jsp
View file @
d5ffacd8
...
...
@@ -16,6 +16,7 @@
<EF:EFRegion id="inqu" title="查询区域" type="query">
<EF:EFInput cname="主表ID" ename="matId" blockId="inqu_status" row="0" type="hidden"/>
<EF:EFInput cname="业务类型" ename="bizType" blockId="inqu_status" row="0" type="hidden"/>
<EF:EFInput blockId="inqu_status" row="0" ename="checkStatus" cname="审核状态" colWidth="3" type="hidden"/>
<div class="row">
<EF:EFInput cname="文件名称" ename="docName" blockId="inqu_status" row="0" colWidth="3" />
</div>
...
...
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