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
a9f82509
Commit
a9f82509
authored
Aug 28, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2024-08-28 合同管理甲方和乙方修复筛选功能
parent
0cdfd3ca
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
93 additions
and
12 deletions
+93
-12
ServiceHGCW002A.java
...java/com/baosight/hggp/hg/cw/service/ServiceHGCW002A.java
+72
-6
HGPZTools.java
src/main/java/com/baosight/hggp/hg/pz/tools/HGPZTools.java
+15
-0
HGCW002A.js
src/main/webapp/HG/CW/HGCW002A.js
+4
-2
HGCW002A.jsp
src/main/webapp/HG/CW/HGCW002A.jsp
+2
-4
No files found.
src/main/java/com/baosight/hggp/hg/cw/service/ServiceHGCW002A.java
View file @
a9f82509
...
...
@@ -16,10 +16,7 @@ import com.baosight.hggp.hg.sj.domain.HGSJ003;
import
com.baosight.hggp.hg.xs.domain.Company
;
import
com.baosight.hggp.hg.xs.domain.Org
;
import
com.baosight.hggp.hg.xs.tools.HGXSTools
;
import
com.baosight.hggp.util.AssertUtils
;
import
com.baosight.hggp.util.CommonMethod
;
import
com.baosight.hggp.util.ExcelUtils
;
import
com.baosight.hggp.util.LogUtils
;
import
com.baosight.hggp.util.*
;
import
com.baosight.hggp.util.contants.ACConstants
;
import
com.baosight.iplat4j.core.ei.EiBlock
;
import
com.baosight.iplat4j.core.ei.EiConstant
;
...
...
@@ -27,6 +24,7 @@ import com.baosight.iplat4j.core.ei.EiInfo;
import
com.baosight.iplat4j.core.exception.PlatException
;
import
com.baosight.iplat4j.core.service.impl.ServiceBase
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.poi.ss.formula.functions.T
;
import
java.math.BigDecimal
;
import
java.util.*
;
...
...
@@ -66,12 +64,46 @@ public class ServiceHGCW002A extends ServiceBase {
*/
public
EiInfo
partyAQuery
(
EiInfo
inInfo
)
{
try
{
List
<
Map
>
params
=
inInfo
.
getBlock
(
EiConstant
.
queryBlock
).
getRows
();
List
<
UserVO
>
userVOList
=
new
ArrayList
<>();
String
contractCategory
=
inInfo
.
getString
(
"contractCategory"
);
String
partyA
=
inInfo
.
getString
(
"partyA"
);
if
(
contractCategory
.
equals
(
"1"
))
{
List
<
HGPZ002
>
hgpz002List
=
HGPZTools
.
HgPz002
.
list
(
1
);
List
<
HGPZ002
>
hgpz002List
=
MapUtils
.
toDaoEPBases
(
super
.
query
(
inInfo
,
HGPZ002
.
QUERY
,
new
HGPZ002
()).
getBlock
(
EiConstant
.
resultBlock
).
getRows
(),
HGPZ002
.
class
);
if
(
CollectionUtils
.
isNotEmpty
(
hgpz002List
))
{
if
(
params
.
size
()>
0
){
Map
<
String
,
String
>
params1
=
params
.
get
(
0
);
Map
<
String
,
String
>
params2
=
params
.
size
()>
1
?
params
.
get
(
1
):
null
;
String
username
=
params1
.
get
(
"username"
);
String
usercode
=
params1
.
get
(
"usercode"
);
String
username1
=
params2
==
null
?
null
:
params2
.
get
(
"username"
);
String
usercode1
=
params2
==
null
?
null
:
params2
.
get
(
"usercode"
);
if
(
StringUtils
.
isNotNull
(
username
)){
switch
(
username1
){
case
"eq"
:
hgpz002List
=
hgpz002List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getCustName
().
equals
(
username
)).
collect
(
Collectors
.
toList
());
break
;
case
"neq"
:
hgpz002List
=
hgpz002List
.
stream
().
filter
(
hgpz002
->
!
hgpz002
.
getCustName
().
equals
(
username
)).
collect
(
Collectors
.
toList
());
break
;
default
:
hgpz002List
=
hgpz002List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getCustName
().
contains
(
username
)).
collect
(
Collectors
.
toList
());
}
}
if
(
StringUtils
.
isNotNull
(
usercode
)){
switch
(
usercode1
){
case
"eq"
:
hgpz002List
=
hgpz002List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getCustCode
().
equals
(
usercode
)).
collect
(
Collectors
.
toList
());
break
;
case
"neq"
:
hgpz002List
=
hgpz002List
.
stream
().
filter
(
hgpz002
->
!
hgpz002
.
getCustCode
().
equals
(
usercode
)).
collect
(
Collectors
.
toList
());
break
;
default
:
hgpz002List
=
hgpz002List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getCustCode
().
contains
(
usercode
)).
collect
(
Collectors
.
toList
());
}
}
}
hgpz002List
.
forEach
(
hgpz002
->
{
UserVO
userVO
=
new
UserVO
();
userVO
.
setUsercode
(
hgpz002
.
getCustCode
());
...
...
@@ -103,6 +135,7 @@ public class ServiceHGCW002A extends ServiceBase {
*/
public
EiInfo
partyBQuery
(
EiInfo
inInfo
)
{
try
{
List
<
Map
>
params
=
inInfo
.
getBlock
(
EiConstant
.
queryBlock
).
getRows
();
List
<
UserVO
>
userVOList
=
new
ArrayList
<>();
String
contractCategory
=
inInfo
.
getString
(
"contractCategory"
);
String
partyB
=
inInfo
.
getString
(
"partyB"
);
...
...
@@ -116,8 +149,41 @@ public class ServiceHGCW002A extends ServiceBase {
}
}
else
if
(
contractCategory
.
equals
(
"2"
))
{
List
<
HGPZ003
>
hgpz003List
=
HGCWTools
.
HgCw002
.
list
(
1
);
List
<
HGPZ003
>
hgpz003List
=
MapUtils
.
toDaoEPBases
(
super
.
query
(
inInfo
,
HGPZ003
.
QUERY
,
new
HGPZ003
()).
getBlock
(
EiConstant
.
resultBlock
).
getRows
(),
HGPZ003
.
class
);
if
(
CollectionUtils
.
isNotEmpty
(
hgpz003List
))
{
if
(
params
.
size
()>
0
){
Map
<
String
,
String
>
params1
=
params
.
get
(
0
);
Map
<
String
,
String
>
params2
=
params
.
size
()>
1
?
params
.
get
(
1
):
null
;
String
username
=
params1
.
get
(
"username"
);
String
usercode
=
params1
.
get
(
"usercode"
);
String
username1
=
params2
==
null
?
null
:
params2
.
get
(
"username"
);
String
usercode1
=
params2
==
null
?
null
:
params2
.
get
(
"usercode"
);
if
(
StringUtils
.
isNotNull
(
username
)){
switch
(
username1
){
case
"eq"
:
hgpz003List
=
hgpz003List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getSupName
().
equals
(
username
)).
collect
(
Collectors
.
toList
());
break
;
case
"neq"
:
hgpz003List
=
hgpz003List
.
stream
().
filter
(
hgpz002
->
!
hgpz002
.
getSupName
().
equals
(
username
)).
collect
(
Collectors
.
toList
());
break
;
default
:
hgpz003List
=
hgpz003List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getSupName
().
contains
(
username
)).
collect
(
Collectors
.
toList
());
}
}
if
(
StringUtils
.
isNotNull
(
usercode
)){
switch
(
usercode1
){
case
"eq"
:
hgpz003List
=
hgpz003List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getSupCode
().
equals
(
usercode
)).
collect
(
Collectors
.
toList
());
break
;
case
"neq"
:
hgpz003List
=
hgpz003List
.
stream
().
filter
(
hgpz002
->
!
hgpz002
.
getSupCode
().
equals
(
usercode
)).
collect
(
Collectors
.
toList
());
break
;
default
:
hgpz003List
=
hgpz003List
.
stream
().
filter
(
hgpz002
->
hgpz002
.
getSupCode
().
contains
(
usercode
)).
collect
(
Collectors
.
toList
());
}
}
}
hgpz003List
.
forEach
(
hgpz003
->
{
UserVO
userVO
=
new
UserVO
();
userVO
.
setUsercode
(
hgpz003
.
getSupCode
());
...
...
src/main/java/com/baosight/hggp/hg/pz/tools/HGPZTools.java
View file @
a9f82509
...
...
@@ -57,6 +57,21 @@ public class HGPZTools {
queryMap
.
put
(
"status"
,
status
);
return
DaoBase
.
getInstance
().
query
(
HGPZ002
.
QUERY
,
queryMap
);
}
public
static
List
<
HGPZ002
>
list
(
List
<
Map
>
params
,
Integer
status
)
{
if
(
status
==
null
)
{
return
null
;
}
Map
queryMap
=
new
HashMap
<>();
queryMap
.
put
(
"status"
,
status
);
if
(
CollectionUtils
.
isNotEmpty
(
params
)){
queryMap
.
put
(
"code"
,
params
.
get
(
0
));
queryMap
.
put
(
"name"
,
params
.
get
(
1
));
}
//queryMap.put("param0", param.get(0));
return
DaoBase
.
getInstance
().
query
(
HGPZ002
.
QUERY
,
queryMap
);
}
}
public
static
class
HgPz003
{
...
...
src/main/webapp/HG/CW/HGCW002A.js
View file @
a9f82509
...
...
@@ -285,6 +285,7 @@ $(function() {
var
info
=
new
EiInfo
();
info
.
set
(
"contractCategory"
,
contractCategory
);
info
.
set
(
"partyA"
,
$
(
"#result-0-partyA"
).
val
())
info
.
set
(
"inqu_status-0-status"
,
1
);
return
info
;
},
/**
...
...
@@ -324,8 +325,9 @@ $(function() {
e
.
preventDefault
();
}
var
info
=
new
EiInfo
();
info
.
set
(
"contractCategory"
,
contractCategory
)
info
.
set
(
"partyB"
,
$
(
"#result-0-partyB"
).
val
())
info
.
set
(
"contractCategory"
,
contractCategory
);
info
.
set
(
"partyB"
,
$
(
"#result-0-partyB"
).
val
());
info
.
set
(
"inqu_status-0-status"
,
1
);
return
info
;
},
/**
...
...
src/main/webapp/HG/CW/HGCW002A.jsp
View file @
a9f82509
...
...
@@ -35,8 +35,7 @@
</div>
<div
class=
"row"
>
<EF:EFPopupInput
ename=
"popupInputPartyA"
cname=
"甲方名称"
colWidth=
"4"
serviceName=
"HGCW002A"
methodName=
"partyAQuery"
resultId=
"partyAResult"
serviceName=
"HGCW002A"
methodName=
"partyAQuery"
resultId=
"partyAResult"
required=
"true"
save=
"false"
popupType=
"ServiceGrid"
valueField=
"username"
textField=
"username"
columnEnames=
"username,usercode"
...
...
@@ -46,8 +45,7 @@
</EF:EFPopupInput>
<EF:EFInput
ename=
"result-0-partyA"
cname=
"甲方名称"
type=
"hidden"
/>
<EF:EFPopupInput
ename=
"popupInputPartyB"
cname=
"乙方名称"
colWidth=
"4"
serviceName=
"HGCW002A"
methodName=
"partyBQuery"
resultId=
"partyAResult"
serviceName=
"HGCW002A"
methodName=
"partyBQuery"
resultId=
"partyAResult"
save=
"false"
popupType=
"ServiceGrid"
valueField=
"username"
textField=
"username"
columnEnames=
"username,usercode"
...
...
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