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
a792a45e
Commit
a792a45e
authored
May 09, 2024
by
宋祥
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.sql名称错误
parent
d2c741ee
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
5 deletions
+7
-5
HGSqlConstant.java
...ain/java/com/baosight/hggp/hg/constant/HGSqlConstant.java
+4
-0
HGXSUser.xml
src/main/java/com/baosight/hggp/hg/xs/sql/HGXSUser.xml
+0
-1
HGXSTools.java
src/main/java/com/baosight/hggp/hg/xs/tools/HGXSTools.java
+3
-4
No files found.
src/main/java/com/baosight/hggp/hg/constant/HGSqlConstant.java
View file @
a792a45e
...
@@ -419,6 +419,10 @@ public class HGSqlConstant {
...
@@ -419,6 +419,10 @@ public class HGSqlConstant {
*/
*/
public
class
HgXsUser
{
public
class
HgXsUser
{
// 查询
public
static
final
String
QUERY
=
"HGXSUser.query"
;
// 查询
public
static
final
String
COUNT
=
"HGXSUser.count"
;
// 根据组织查询
// 根据组织查询
public
static
final
String
QUERY_BY_ORG
=
"HGXSUser.queryByOrg"
;
public
static
final
String
QUERY_BY_ORG
=
"HGXSUser.queryByOrg"
;
}
}
...
...
src/main/java/com/baosight/hggp/hg/xs/sql/HGXSUser.xml
View file @
a792a45e
...
@@ -91,7 +91,6 @@
...
@@ -91,7 +91,6 @@
WHERE 1=1
WHERE 1=1
AND A.ORG_ID = B.ORG_ID
AND A.ORG_ID = B.ORG_ID
AND B.USER_ID = C.USER_ID
AND B.USER_ID = C.USER_ID
AND C.LOGIN_NAME = #loginName#
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
<isNotEmpty
prepend=
" AND "
property=
"accountCode"
>
A.ACCOUNT_CODE = #accountCode#
A.ACCOUNT_CODE = #accountCode#
</isNotEmpty>
</isNotEmpty>
...
...
src/main/java/com/baosight/hggp/hg/xs/tools/HGXSTools.java
View file @
a792a45e
package
com
.
baosight
.
hggp
.
hg
.
xs
.
tools
;
package
com
.
baosight
.
hggp
.
hg
.
xs
.
tools
;
import
com.baosight.hggp.core.constant.CommonConstant
;
import
com.baosight.hggp.core.dao.DaoBase
;
import
com.baosight.hggp.core.dao.DaoBase
;
import
com.baosight.hggp.core.enums.OrgTypeEnum
;
import
com.baosight.hggp.core.enums.OrgTypeEnum
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
import
com.baosight.hggp.core.security.UserSessionUtils
;
...
@@ -48,7 +47,7 @@ public class HGXSTools {
...
@@ -48,7 +47,7 @@ public class HGXSTools {
AssertUtils
.
isEmpty
(
loginName
,
"用户登录名不能为空"
);
AssertUtils
.
isEmpty
(
loginName
,
"用户登录名不能为空"
);
Map
paramMap
=
new
HashMap
();
Map
paramMap
=
new
HashMap
();
paramMap
.
put
(
"loginName"
,
loginName
);
paramMap
.
put
(
"loginName"
,
loginName
);
List
<
User
>
results
=
DaoBase
.
getInstance
().
query
(
"HGXSUser.query"
,
paramMap
);
List
<
User
>
results
=
DaoBase
.
getInstance
().
query
(
HGSqlConstant
.
HgXsUser
.
QUERY
,
paramMap
);
return
CollectionUtils
.
isEmpty
(
results
)
?
null
:
results
.
get
(
0
);
return
CollectionUtils
.
isEmpty
(
results
)
?
null
:
results
.
get
(
0
);
}
}
...
@@ -77,7 +76,7 @@ public class HGXSTools {
...
@@ -77,7 +76,7 @@ public class HGXSTools {
}
}
Map
queryMap
=
new
HashMap
();
Map
queryMap
=
new
HashMap
();
queryMap
.
put
(
"loginNames"
,
loginNames
);
queryMap
.
put
(
"loginNames"
,
loginNames
);
return
DaoBase
.
getInstance
().
query
(
"HGXSUser.query"
,
queryMap
);
return
DaoBase
.
getInstance
().
query
(
HGSqlConstant
.
HgXsUser
.
QUERY
,
queryMap
);
}
}
/**
/**
...
@@ -103,7 +102,7 @@ public class HGXSTools {
...
@@ -103,7 +102,7 @@ public class HGXSTools {
public
static
int
countByAccount
(
String
accountCode
)
{
public
static
int
countByAccount
(
String
accountCode
)
{
Map
paramMap
=
new
HashMap
();
Map
paramMap
=
new
HashMap
();
paramMap
.
put
(
"accountCode"
,
accountCode
);
paramMap
.
put
(
"accountCode"
,
accountCode
);
List
<
Integer
>
results
=
DaoBase
.
getInstance
().
query
(
"HGXSUser.count"
,
paramMap
);
List
<
Integer
>
results
=
DaoBase
.
getInstance
().
query
(
HGSqlConstant
.
HgXsUser
.
COUNT
,
paramMap
);
return
CollectionUtils
.
isEmpty
(
results
)
?
0
:
results
.
get
(
0
);
return
CollectionUtils
.
isEmpty
(
results
)
?
0
:
results
.
get
(
0
);
}
}
...
...
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