Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hp-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
hp-smart
Commits
e4a25de8
Commit
e4a25de8
authored
Oct 17, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
http://git.pseer.com:8800/platform/hp-smart
into dev-ly
parents
e5f8b3f6
0ef907ae
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
39 additions
and
2 deletions
+39
-2
UserSessionUtils.java
...ava/com/baosight/hpjx/core/security/UserSessionUtils.java
+2
-2
ServiceHPDM099.java
.../java/com/baosight/hpjx/hp/dm/service/ServiceHPDM099.java
+2
-0
ServiceHPXSUser.java
...java/com/baosight/hpjx/hp/xs/service/ServiceHPXSUser.java
+35
-0
No files found.
src/main/java/com/baosight/hpjx/core/security/UserSessionUtils.java
View file @
e4a25de8
...
@@ -32,9 +32,9 @@ public class UserSessionUtils extends UserSession {
...
@@ -32,9 +32,9 @@ public class UserSessionUtils extends UserSession {
*/
*/
public
static
User
getUser
()
{
public
static
User
getUser
()
{
EiInfo
eiInfo
=
new
EiInfo
();
EiInfo
eiInfo
=
new
EiInfo
();
eiInfo
.
set
(
"
userId"
,
UserSession
.
getUserId
());
eiInfo
.
set
(
"
loginName"
,
UserSession
.
getLoginName
());
eiInfo
.
set
(
EiConstant
.
serviceName
,
"HPXSUser"
);
eiInfo
.
set
(
EiConstant
.
serviceName
,
"HPXSUser"
);
eiInfo
.
set
(
EiConstant
.
methodName
,
"getUser"
);
eiInfo
.
set
(
EiConstant
.
methodName
,
"getUser
ByLogin
"
);
EiInfo
outInfo
=
XLocalManager
.
call
(
eiInfo
);
EiInfo
outInfo
=
XLocalManager
.
call
(
eiInfo
);
// -1表示报错
// -1表示报错
if
(
outInfo
.
getStatus
()
==
-
1
)
{
if
(
outInfo
.
getStatus
()
==
-
1
)
{
...
...
src/main/java/com/baosight/hpjx/hp/dm/service/ServiceHPDM099.java
View file @
e4a25de8
...
@@ -6,6 +6,7 @@ import com.baosight.hpjx.core.dao.DaoUtils;
...
@@ -6,6 +6,7 @@ import com.baosight.hpjx.core.dao.DaoUtils;
import
com.baosight.hpjx.core.utils.Iplat4jUtils
;
import
com.baosight.hpjx.core.utils.Iplat4jUtils
;
import
com.baosight.hpjx.hp.dm.domain.HPDM099
;
import
com.baosight.hpjx.hp.dm.domain.HPDM099
;
import
com.baosight.hpjx.hp.xs.domain.HPXS007A
;
import
com.baosight.hpjx.hp.xs.domain.HPXS007A
;
import
com.baosight.hpjx.util.AssertUtils
;
import
com.baosight.hpjx.util.LogUtils
;
import
com.baosight.hpjx.util.LogUtils
;
import
com.baosight.hpjx.util.MapUtils
;
import
com.baosight.hpjx.util.MapUtils
;
import
com.baosight.iplat4j.core.ProjectInfo
;
import
com.baosight.iplat4j.core.ProjectInfo
;
...
@@ -65,6 +66,7 @@ public class ServiceHPDM099 extends ServiceEPBase {
...
@@ -65,6 +66,7 @@ public class ServiceHPDM099 extends ServiceEPBase {
public
EiInfo
upload
(
EiInfo
inInfo
)
{
public
EiInfo
upload
(
EiInfo
inInfo
)
{
try
{
try
{
HPDM099
fDm099
=
MapUtils
.
toDaoEPBase
(
inInfo
,
HPDM099
.
class
);
HPDM099
fDm099
=
MapUtils
.
toDaoEPBase
(
inInfo
,
HPDM099
.
class
);
AssertUtils
.
isEmpty
(
fDm099
.
getDocId
(),
"文件ID不能为空"
);
fDm099
.
setDeleteFlag
(
CommonConstant
.
YesNo
.
NO_0
);
fDm099
.
setDeleteFlag
(
CommonConstant
.
YesNo
.
NO_0
);
DaoUtils
.
insert
(
HPDM099
.
INSERT
,
fDm099
);
DaoUtils
.
insert
(
HPDM099
.
INSERT
,
fDm099
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
inInfo
.
setStatus
(
EiConstant
.
STATUS_DEFAULT
);
...
...
src/main/java/com/baosight/hpjx/hp/xs/service/ServiceHPXSUser.java
View file @
e4a25de8
...
@@ -58,6 +58,41 @@ public class ServiceHPXSUser extends ServiceBase {
...
@@ -58,6 +58,41 @@ public class ServiceHPXSUser extends ServiceBase {
return
outInfo
;
return
outInfo
;
}
}
/**
* 获取用户信息
*
* @param eiInfo
* @return
*/
public
EiInfo
getUserByLogin
(
EiInfo
eiInfo
)
{
EiInfo
outInfo
=
new
EiInfo
();
int
status
=
0
;
String
msg
=
""
;
try
{
String
loginName
=
eiInfo
.
getString
(
"loginName"
);
if
(
StringUtils
.
isNotEmpty
(
loginName
))
{
Map
map
=
new
HashMap
();
map
.
put
(
"loginName"
,
loginName
);
List
<
User
>
users
=
dao
.
query
(
"HGXSUser.query"
,
map
);
if
(
users
!=
null
&&
users
.
size
()
>
0
)
{
status
=
1
;
msg
=
"用户存在!"
;
outInfo
.
set
(
"result"
,
users
.
get
(
0
));
}
else
{
msg
=
"用户信息不存在!"
;
}
}
else
{
msg
=
"传入用户名不能为空!"
;
}
outInfo
.
setStatus
(
status
);
outInfo
.
setMsg
(
msg
);
}
catch
(
Exception
e
)
{
LogUtils
.
setDetailMsg
(
outInfo
,
e
,
"平台调用用户信息异常"
);
}
return
outInfo
;
}
/**
/**
* 查询用户下拉框
* 查询用户下拉框
*
*
...
...
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