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
22b7b901
Commit
22b7b901
authored
Jun 04, 2024
by
wuwenlong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
沟通记录dev
parent
18b3df0f
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
150 additions
and
7 deletions
+150
-7
HGZL004.java
src/main/java/com/baosight/hggp/hg/zl/domain/HGZL004.java
+4
-0
HGZL004A.java
src/main/java/com/baosight/hggp/hg/zl/domain/HGZL004A.java
+2
-0
ServiceHGZL004A.java
...java/com/baosight/hggp/hg/zl/service/ServiceHGZL004A.java
+25
-0
HGZL004.xml
src/main/java/com/baosight/hggp/hg/zl/sql/HGZL004.xml
+13
-0
HGZL004A.xml
src/main/java/com/baosight/hggp/hg/zl/sql/HGZL004A.xml
+8
-3
HGZLTools.java
src/main/java/com/baosight/hggp/hg/zl/tools/HGZLTools.java
+30
-0
HGSC002.jsp
src/main/webapp/HG/SC/HGSC002.jsp
+1
-1
HGZL004.js
src/main/webapp/HG/ZL/HGZL004.js
+45
-1
HGZL004A.js
src/main/webapp/HG/ZL/HGZL004A.js
+20
-0
HGZL004A.jsp
src/main/webapp/HG/ZL/HGZL004A.jsp
+2
-2
No files found.
src/main/java/com/baosight/hggp/hg/zl/domain/HGZL004.java
View file @
22b7b901
...
@@ -93,6 +93,10 @@ public class HGZL004 extends DaoEPBase {
...
@@ -93,6 +93,10 @@ public class HGZL004 extends DaoEPBase {
public
static
final
String
UPDATE
=
"HGZL004.update"
;
public
static
final
String
UPDATE
=
"HGZL004.update"
;
public
static
final
String
DELETE
=
"HGZL004.delete"
;
public
static
final
String
DELETE
=
"HGZL004.delete"
;
public
static
final
String
BATCH_COMPLETE
=
"HGZL004.batch_complete"
;
public
static
final
String
BATCH_COMPLETE
=
"HGZL004.batch_complete"
;
public
static
final
String
DELETE_BY_CHECK_IDS
=
"HGZL004.delete_by_check_ids"
;
public
static
final
String
DELETE_BY_IDS
=
"HGZL004.delete_by_ids"
;
private
Long
id
=
new
Long
(
0
);
private
Long
id
=
new
Long
(
0
);
private
Long
checkId
=
new
Long
(
0
);
/* 质检单ID*/
private
Long
checkId
=
new
Long
(
0
);
/* 质检单ID*/
...
...
src/main/java/com/baosight/hggp/hg/zl/domain/HGZL004A.java
View file @
22b7b901
...
@@ -56,6 +56,8 @@ public class HGZL004A extends DaoEPBase {
...
@@ -56,6 +56,8 @@ public class HGZL004A extends DaoEPBase {
public
static
final
String
INSERT
=
"HGZL004A.insert"
;
public
static
final
String
INSERT
=
"HGZL004A.insert"
;
public
static
final
String
UPDATE
=
"HGZL004A.update"
;
public
static
final
String
UPDATE
=
"HGZL004A.update"
;
public
static
final
String
DELETE
=
"HGZL004A.delete"
;
public
static
final
String
DELETE
=
"HGZL004A.delete"
;
public
static
final
String
DELETE_BY_INFORM_IDS
=
"HGZL004A.delete_by_inform_ids"
;
private
Long
id
=
new
Long
(
0
);
private
Long
id
=
new
Long
(
0
);
private
Long
informId
=
new
Long
(
0
);
/* 整改通知单ID*/
private
Long
informId
=
new
Long
(
0
);
/* 整改通知单ID*/
...
...
src/main/java/com/baosight/hggp/hg/zl/service/ServiceHGZL004A.java
View file @
22b7b901
package
com
.
baosight
.
hggp
.
hg
.
zl
.
service
;
package
com
.
baosight
.
hggp
.
hg
.
zl
.
service
;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.aspect.annotation.OperationLogAnnotation
;
import
com.baosight.hggp.core.dao.DaoUtils
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.hg.xs.domain.User
;
import
com.baosight.hggp.hg.xs.domain.User
;
import
com.baosight.hggp.hg.zl.domain.HGZL004A
;
import
com.baosight.hggp.hg.zl.domain.HGZL004A
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.EiInfoUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.ei.EiInfo
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
java.util.Map
;
import
java.util.Objects
;
/**
/**
* @author wwl
* @author wwl
...
@@ -51,6 +56,26 @@ public class ServiceHGZL004A extends ServiceBase {
...
@@ -51,6 +56,26 @@ public class ServiceHGZL004A extends ServiceBase {
return
inInfo
;
return
inInfo
;
}
}
@OperationLogAnnotation
(
operModul
=
"整改通知单-沟通记录"
,
operType
=
"保存"
,
operDesc
=
"保存"
)
public
EiInfo
save
(
EiInfo
inInfo
)
{
try
{
Long
informId
=
Long
.
valueOf
(
EiInfoUtils
.
getFirstRow
(
inInfo
).
get
(
HGZL004A
.
FIELD_inform_id
).
toString
());
Map
resultMap
=
EiInfoUtils
.
getFirstRow
(
inInfo
,
EiConstant
.
resultBlock
);
HGZL004A
hgzl004a
=
new
HGZL004A
();
hgzl004a
.
fromMap
(
resultMap
);
hgzl004a
.
setInformId
(
informId
);
if
(
Objects
.
nonNull
(
hgzl004a
.
getId
())&&
hgzl004a
.
getId
()!=
0
){
DaoUtils
.
update
(
HGZL004A
.
UPDATE
,
hgzl004a
);
}
else
{
DaoUtils
.
insert
(
HGZL004A
.
INSERT
,
hgzl004a
);
}
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setMsg
(
"保存成功!"
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
inInfo
,
e
,
"保存失败"
);
}
return
inInfo
;
}
}
}
src/main/java/com/baosight/hggp/hg/zl/sql/HGZL004.xml
View file @
22b7b901
...
@@ -136,6 +136,9 @@
...
@@ -136,6 +136,9 @@
<isNotEmpty
prepend=
" AND "
property=
"updatedTime"
>
<isNotEmpty
prepend=
" AND "
property=
"updatedTime"
>
updated_time = #updatedTime#
updated_time = #updatedTime#
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"checkIds"
>
check_id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"checkIds"
>
#checkIds[]#
</iterate>
</isNotEmpty>
</sql>
</sql>
<select
id=
"query"
parameterClass=
"java.util.HashMap"
<select
id=
"query"
parameterClass=
"java.util.HashMap"
...
@@ -393,4 +396,14 @@
...
@@ -393,4 +396,14 @@
id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"ids"
>
#ids[]#
</iterate>
id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"ids"
>
#ids[]#
</iterate>
</update>
</update>
<delete
id=
"delete_by_check_ids"
>
DELETE FROM ${hggpSchema}.HGZL004 WHERE
check_type = #checkType#
AND check_id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"checkIds"
>
#checkIds[]#
</iterate>
</delete>
<delete
id=
"delete_by_ids"
>
DELETE FROM ${hggpSchema}.HGZL004 WHERE
id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"ids"
>
#ids[]#
</iterate>
</delete>
</sqlMap>
</sqlMap>
src/main/java/com/baosight/hggp/hg/zl/sql/HGZL004A.xml
View file @
22b7b901
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
inform_id = #informId#
inform_id = #informId#
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"content"
>
<isNotEmpty
prepend=
" AND "
property=
"content"
>
content
= #content#
content
like ('%$content$%')
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
company_code = #companyCode#
company_code = #companyCode#
...
@@ -50,10 +50,10 @@
...
@@ -50,10 +50,10 @@
created_by = #createdBy#
created_by = #createdBy#
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"createdName"
>
<isNotEmpty
prepend=
" AND "
property=
"createdName"
>
created_name
= #createdName#
created_name
like ('%$createdName$%')
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"createdTime"
>
<isNotEmpty
prepend=
" AND "
property=
"createdTime"
>
created_time
= #createdTime#
date_format(created_time,'%Y-%m-%d')
= #createdTime#
</isNotEmpty>
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"updatedBy"
>
<isNotEmpty
prepend=
" AND "
property=
"updatedBy"
>
updated_by = #updatedBy#
updated_by = #updatedBy#
...
@@ -190,4 +190,9 @@
...
@@ -190,4 +190,9 @@
id = #id#
id = #id#
</update>
</update>
<delete
id=
"delete_by_inform_ids"
>
DELETE FROM ${hggpSchema}.HGZL004A WHERE
inform_id IN
<iterate
close=
")"
open=
"("
conjunction=
","
property=
"informIds"
>
#informIds[]#
</iterate>
</delete>
</sqlMap>
</sqlMap>
src/main/java/com/baosight/hggp/hg/zl/tools/HGZLTools.java
View file @
22b7b901
...
@@ -13,6 +13,7 @@ import com.baosight.hggp.hg.sc.tools.HGSCTools;
...
@@ -13,6 +13,7 @@ import com.baosight.hggp.hg.sc.tools.HGSCTools;
import
com.baosight.hggp.hg.zl.domain.HGZL001
;
import
com.baosight.hggp.hg.zl.domain.HGZL001
;
import
com.baosight.hggp.hg.zl.domain.HGZL002
;
import
com.baosight.hggp.hg.zl.domain.HGZL002
;
import
com.baosight.hggp.hg.zl.domain.HGZL004
;
import
com.baosight.hggp.hg.zl.domain.HGZL004
;
import
com.baosight.hggp.hg.zl.domain.HGZL004A
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.iplat4j.core.data.DaoEPBase
;
import
com.baosight.iplat4j.core.data.DaoEPBase
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
import
com.baosight.iplat4j.ed.util.SequenceGenerator
;
...
@@ -127,6 +128,8 @@ public class HGZLTools {
...
@@ -127,6 +128,8 @@ public class HGZLTools {
}
}
public
static
void
deleteByWorkIds
(
List
<
Long
>
workIds
)
{
public
static
void
deleteByWorkIds
(
List
<
Long
>
workIds
)
{
List
<
HGZL002
>
hgzl002s
=
list
(
workIds
);
THGZL004
.
deleteByCheckIds
(
hgzl002s
.
stream
().
map
(
HGZL002:
:
getId
).
collect
(
Collectors
.
toList
()),
CheckTypeEnum
.
PROCESS_CHECK
);
DaoUtils
.
update
(
HGZL002
.
DELETE_BY_WORKS
,
new
HashMap
<
String
,
Object
>()
{{
DaoUtils
.
update
(
HGZL002
.
DELETE_BY_WORKS
,
new
HashMap
<
String
,
Object
>()
{{
put
(
"workIds"
,
workIds
);
put
(
"workIds"
,
workIds
);
}});
}});
...
@@ -173,6 +176,17 @@ public class HGZLTools {
...
@@ -173,6 +176,17 @@ public class HGZLTools {
// }
// }
}
}
public
static
void
deleteByCheckIds
(
List
<
Long
>
checkIds
,
CheckTypeEnum
checkType
){
List
<
HGZL004
>
hgzl004List
=
listByCheckIds
(
checkIds
,
checkType
.
getCode
());
List
<
Long
>
ids
=
hgzl004List
.
stream
().
map
(
HGZL004:
:
getId
).
collect
(
Collectors
.
toList
());
DaoUtils
.
update
(
HGZL004
.
DELETE_BY_IDS
,
new
HashMap
<
String
,
Object
>(){{
put
(
"ids"
,
ids
);}});
// THGZL004A.deleteByInformIds(ids);
ids
.
forEach
(
id
->
{
HGSCTools
.
THGSC099
.
deleteByMatId
(
id
,
HGConstant
.
FileBizType
.
CHECK_DEFECT
);
HGSCTools
.
THGSC099
.
deleteByMatId
(
id
,
HGConstant
.
FileBizType
.
CHECK_HANDLE
);
});
}
private
static
void
cleanBaseInfo
(
HGZL004
hgzl004
)
{
private
static
void
cleanBaseInfo
(
HGZL004
hgzl004
)
{
hgzl004
.
setCreatedBy
(
null
);
hgzl004
.
setCreatedBy
(
null
);
hgzl004
.
setCreatedName
(
null
);
hgzl004
.
setCreatedName
(
null
);
...
@@ -185,6 +199,13 @@ public class HGZLTools {
...
@@ -185,6 +199,13 @@ public class HGZLTools {
hgzl004
.
setId
(
null
);
hgzl004
.
setId
(
null
);
}
}
public
static
List
<
HGZL004
>
listByCheckIds
(
List
<
Long
>
checkIds
,
Integer
checkType
)
{
Map
queryMap
=
new
HashMap
();
queryMap
.
put
(
"checkIds"
,
checkIds
);
queryMap
.
put
(
HGZL004
.
FIELD_check_type
,
checkType
);
return
DaoBase
.
getInstance
().
query
(
HGZL004
.
QUERY
,
queryMap
);
}
public
static
List
<
HGZL004
>
listByCheckId
(
Long
checkId
,
Integer
checkType
)
{
public
static
List
<
HGZL004
>
listByCheckId
(
Long
checkId
,
Integer
checkType
)
{
Map
queryMap
=
new
HashMap
();
Map
queryMap
=
new
HashMap
();
queryMap
.
put
(
HGZL004
.
FIELD_check_id
,
checkId
);
queryMap
.
put
(
HGZL004
.
FIELD_check_id
,
checkId
);
...
@@ -205,4 +226,12 @@ public class HGZLTools {
...
@@ -205,4 +226,12 @@ public class HGZLTools {
}
}
public
static
class
THGZL004A
{
public
static
void
deleteByInformIds
(
List
<
Long
>
informIds
){
AssertUtils
.
isEmpty
(
informIds
,
"通知单ID不能为空"
);
DaoUtils
.
update
(
HGZL004A
.
DELETE_BY_INFORM_IDS
,
new
HashMap
<
String
,
Object
>(){{
put
(
"informIds"
,
informIds
);}});
}
}
}
}
\ No newline at end of file
src/main/webapp/HG/SC/HGSC002.jsp
View file @
22b7b901
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
</div>
</div>
</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=
"single"
>
<EF:EFColumn
ename=
"id"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"主键"
hidden=
"true"
/>
<EF:EFColumn
ename=
"createdBy"
cname=
"创建人"
hidden=
"true"
/>
<EF:EFColumn
ename=
"createdBy"
cname=
"创建人"
hidden=
"true"
/>
<EF:EFColumn
ename=
"updatedBy"
cname=
"修改人"
hidden=
"true"
/>
<EF:EFColumn
ename=
"updatedBy"
cname=
"修改人"
hidden=
"true"
/>
...
...
src/main/webapp/HG/ZL/HGZL004.js
View file @
22b7b901
...
@@ -32,7 +32,8 @@ $(function () {
...
@@ -32,7 +32,8 @@ $(function () {
onSuccess
:
function
(
e
)
{
onSuccess
:
function
(
e
)
{
},
},
loadComplete
:
function
(
grid
)
{
loadComplete
:
function
(
grid
)
{
//复检完工
$
(
"#BNT_COMPLETE"
).
on
(
"click"
,
complete
);
},
},
onSave
:
function
(
e
){
onSave
:
function
(
e
){
// 阻止默认请求,使用自定义保存
// 阻止默认请求,使用自定义保存
...
@@ -99,3 +100,45 @@ function communication(id) {
...
@@ -99,3 +100,45 @@ function communication(id) {
height
:
"80%"
,
height
:
"80%"
,
});
});
}
}
function
complete
()
{
let
rows
=
resultGrid
.
getCheckedRows
()
if
(
rows
.
length
<
1
)
{
message2
(
"复检合格"
,
"没有选中的行"
);
return
;
}
let
flag
=
true
;
$
.
each
(
rows
,
function
(
index
,
item
)
{
if
(
item
.
handleStatus
===
'0'
){
message2
(
"复检合格"
,
"【非处理中的数据】未填写处理意见或整改措施,无法进行复检操作!"
);
flag
=
false
;
return
;
}
});
if
(
flag
)
{
IPLAT
.
confirm
({
title
:
'复检合格'
,
message
:
'确认复检此数据么?'
,
okFn
:
function
()
{
var
post
=
new
EiInfo
();
post
.
addBlock
(
resultGrid
.
getCheckedBlockData
());
post
.
set
(
"recursion"
,
true
);
EiCommunicator
.
send
(
"HGZL004"
,
"complete"
,
post
,
{
onSuccess
:
function
(
ei
)
{
if
(
ei
.
getStatus
()
>=
0
)
{
NotificationUtil
(
ei
);
resultGrid
.
dataSource
.
query
();
}
else
{
NotificationUtil
(
ei
,
"error"
);
}
},
onFail
:
function
(
ei
)
{
// 发生异常
NotificationUtil
(
"操作失败,原因["
+
ei
+
"]"
,
"error"
);
}
});
}
});
}
}
\ No newline at end of file
src/main/webapp/HG/ZL/HGZL004A.js
View file @
22b7b901
...
@@ -11,6 +11,14 @@ $(function () {
...
@@ -11,6 +11,14 @@ $(function () {
onSuccess
:
function
(
e
)
{
onSuccess
:
function
(
e
)
{
},
},
loadComplete
:
function
(
grid
)
{
loadComplete
:
function
(
grid
)
{
},
onSave
:
function
(
e
){
// 阻止默认请求,使用自定义保存
e
.
preventDefault
();
let
btnNode
=
$
(
this
);
//禁用按钮
btnNode
.
attr
(
"disabled"
,
true
);
save
(
btnNode
);
}
}
}
}
}
}
...
@@ -26,3 +34,15 @@ let query = function () {
...
@@ -26,3 +34,15 @@ let query = function () {
resultGrid
.
dataSource
.
page
(
1
);
resultGrid
.
dataSource
.
page
(
1
);
}
}
let
save
=
function
()
{
let
rows
=
resultGrid
.
getCheckedRows
();
if
(
rows
.
length
<
1
)
{
message
(
"请选择数据"
)
return
;
}
JSUtils
.
confirm
(
"确定对勾选中的["
+
rows
.
length
+
"]条数据做保存操作吗? "
,
{
ok
:
function
()
{
JSUtils
.
submitGridsData
(
"result"
,
"HGZL004A"
,
"save"
,
true
);
}
});
}
src/main/webapp/HG/ZL/HGZL004A.jsp
View file @
22b7b901
...
@@ -18,9 +18,9 @@
...
@@ -18,9 +18,9 @@
</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=
"single"
>
<EF:EFColumn
ename=
"id"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"id"
cname=
"内码"
hidden=
"true"
/>
<EF:EFColumn
ename=
"content"
cname=
"内容"
width=
"150"
enable=
"fals
e"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"content"
cname=
"内容"
width=
"150"
required=
"tru
e"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"chreatedName"
cname=
"创建人"
width=
"130"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"chreatedName"
cname=
"创建人"
width=
"130"
enable=
"false"
readonly=
"true"
align=
"center"
/>
<EF:EFColumn
ename=
"createdTime"
cname=
"创建时间"
editType=
"date"
<EF:EFColumn
ename=
"createdTime"
cname=
"创建时间"
editType=
"date"
dateFormat=
"yyyy-MM-dd HH:mm:ss"
parseFormats=
"['yyyyMMddHHmmss']"
enable=
"true"
width=
"130"
align=
"center"
readOnly=
"true"
/>
dateFormat=
"yyyy-MM-dd HH:mm:ss"
parseFormats=
"['yyyyMMddHHmmss']"
enable=
"true"
width=
"130"
align=
"center"
readOnly=
"true"
/>
...
...
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