Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cloud-fb
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
王衍超
cloud-fb
Commits
4389a68c
Commit
4389a68c
authored
May 11, 2021
by
高晓磊
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
统一根据区域公司筛选的方法
parent
0eca20e4
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
8 deletions
+1
-8
ShipInfoDaoImpl.java
...java/com/xyst/dinas/biz/internal/dao/ShipInfoDaoImpl.java
+1
-8
No files found.
backend/xyst.dinas.biz/src/main/java/com/xyst/dinas/biz/internal/dao/ShipInfoDaoImpl.java
View file @
4389a68c
...
@@ -62,7 +62,7 @@ public class ShipInfoDaoImpl extends AbstractBaseDao implements ShipInfoDao, Shi
...
@@ -62,7 +62,7 @@ public class ShipInfoDaoImpl extends AbstractBaseDao implements ShipInfoDao, Shi
KClass
bean
=
Amino
.
getStaticMetadataContext
().
getBean
(
ENTITY
,
KClass
.
class
);
KClass
bean
=
Amino
.
getStaticMetadataContext
().
getBean
(
ENTITY
,
KClass
.
class
);
DetachedCriteria
detachedCriteria
=
DetachedCriteria
.
forEntityName
(
bean
.
getName
());
DetachedCriteria
detachedCriteria
=
DetachedCriteria
.
forEntityName
(
bean
.
getName
());
detachedCriteria
.
add
(
Restrictions
.
eq
(
"del"
,
false
));
detachedCriteria
.
add
(
Restrictions
.
eq
(
"del"
,
false
));
addRegionalCompanyFilter
(
detachedCriteria
);
dinasTypeDao
.
addRegionalCompanyFilter
(
detachedCriteria
);
if
(
StringUtils
.
isNotBlank
(
shipName
)){
if
(
StringUtils
.
isNotBlank
(
shipName
)){
detachedCriteria
.
add
(
Restrictions
.
like
(
"shipName"
,
"%"
+
shipName
+
"%"
));
detachedCriteria
.
add
(
Restrictions
.
like
(
"shipName"
,
"%"
+
shipName
+
"%"
));
...
@@ -78,13 +78,6 @@ public class ShipInfoDaoImpl extends AbstractBaseDao implements ShipInfoDao, Shi
...
@@ -78,13 +78,6 @@ public class ShipInfoDaoImpl extends AbstractBaseDao implements ShipInfoDao, Shi
return
page
;
return
page
;
}
}
private
void
addRegionalCompanyFilter
(
DetachedCriteria
detachedCriteria
)
{
KObject
currentLoginRegionalCompany
=
dinasTypeDao
.
getCurrentLoginRegionalCompany
();
if
(
currentLoginRegionalCompany
!=
null
&&
currentLoginRegionalCompany
.
getString
(
"type"
).
equals
(
OrganizationTypeEnum
.
REGIONAL_COMPANY
.
name
()))
{
detachedCriteria
.
add
(
Restrictions
.
eq
(
"regionalCompany.id"
,
currentLoginRegionalCompany
.
getUuid
(
"id"
)));
}
}
@Override
@Override
public
List
<
KObject
>
getByName
(
String
name
,
UUID
id
)
{
public
List
<
KObject
>
getByName
(
String
name
,
UUID
id
)
{
...
...
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