Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
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
haoban3.0
haoban-manage3.0
Commits
36174952
Commit
36174952
authored
Jul 22, 2022
by
墨竹
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
活码操作日志
parent
14f14372
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
10 deletions
+18
-10
HmQrcodeApiServiceImpl.java
...e/service/service/out/impl/hm/HmQrcodeApiServiceImpl.java
+18
-10
No files found.
haoban-manage3-service/src/main/java/com/gic/haoban/manage/service/service/out/impl/hm/HmQrcodeApiServiceImpl.java
View file @
36174952
...
...
@@ -154,11 +154,20 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
}
hmQrcodeQDTO
.
setWxQrcode
(
qywxExternalcontactResultDTO
.
getQr_code
());
hmQrcodeQDTO
.
setWxConfigId
(
qywxExternalcontactResultDTO
.
getConfig_id
());
//操作日志
addLog
(
hmQrcodeQDTO
,
wxEnterpriseId
,
hmId
);
int
saveResult
=
hmQrcodeService
.
insert
(
hmQrcodeQDTO
);
if
(
saveResult
==
1
)
{
// save welcome relation
this
.
updateWelcomeRelation
(
hmQrcodeQDTO
);
}
return
ServiceResponse
.
success
();
}
private
void
addLog
(
HmQrcodeQDTO
hmQrcodeQDTO
,
String
wxEnterpriseId
,
Long
hmId
)
{
Integer
invokingType
=
hmQrcodeQDTO
.
getInvokingType
();
if
(
invokingType
==
0
)
{
GicLogRecordEvaluationContext
.
noWriteLog
();
...
...
@@ -176,8 +185,6 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
logger
.
info
(
"新增活码日志:logText:{}"
,
logContent
);
}
}
return
ServiceResponse
.
success
();
}
@Override
...
...
@@ -242,7 +249,7 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
}
@GicLogRecord
(
value
=
"修改员工活码-${#hmName}
-
${#logContent}"
,
@GicLogRecord
(
value
=
"修改员工活码-${#hmName}
:
${#logContent}"
,
category
=
GicLogRecordCategoryEnum
.
HUOMA
,
optType
=
GicLogRecordOptTypeEnum
.
HUOMA_EDIT
,
optPage
=
"活码管理-修改员工活码"
,
...
...
@@ -285,15 +292,14 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
return
ServiceResponse
.
failure
(
Convert
.
toStr
(
HaoBanErrCodeCommon
.
ERR_0
.
getCode
()),
qywxResponseDTO
.
getErrmsg
());
}
setLoggerContext
(
hmQrcodeQDTO
.
getEnterpriseId
(),
wxEnterpriseId
,
hmQrcodeQDTO
.
getModifierId
(),
hmQrcodeQDTO
.
getModifierName
());
updateSystemLog
(
hmQrcodeQDTO
,
hmId
);
int
updateResult
=
hmQrcodeService
.
update
(
hmQrcodeQDTO
);
if
(
updateResult
==
1
)
{
// 更新欢迎语引用次数
this
.
updateWelcomeRelation
(
hmQrcodeQDTO
);
}
setLoggerContext
(
hmQrcodeQDTO
.
getEnterpriseId
(),
wxEnterpriseId
,
hmQrcodeQDTO
.
getModifierId
(),
hmQrcodeQDTO
.
getModifierName
());
updateSystemLog
(
hmQrcodeQDTO
,
hmId
);
return
ServiceResponse
.
success
();
}
...
...
@@ -375,7 +381,7 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
}
String
logText
=
logContent
.
toString
();
String
hmName
=
"【"
+
hmId
+
"-"
+
hmQrcodeQDTO
.
getName
()
+
"】
:
"
;
String
hmName
=
"【"
+
hmId
+
"-"
+
hmQrcodeQDTO
.
getName
()
+
"】"
;
GicLogRecordEvaluationContext
.
putAttribute
(
"hmName"
,
hmName
);
if
(
invokingType
!=
1
)
{
logText
=
logText
+
"——"
+
ChannelCodeEnum
.
getNameByCode
(
invokingType
);
...
...
@@ -582,13 +588,16 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
return
ServiceResponse
.
failure
(
Convert
.
toStr
(
HaoBanErrCodeCommon
.
ERR_8
.
getCode
()),
qywxResponseDTO
.
getErrmsg
());
}
}
hmQrcodeService
.
deleteById
(
hmId
);
//操作日志
setLoggerContext
(
hmQrcodeBO
.
getEnterpriseId
(),
hmQrcodeBO
.
getWxEnterpriseId
(),
hmQrcodeBO
.
getModifierId
(),
hmQrcodeBO
.
getModifierName
());
String
logContent
=
"【"
+
hmId
+
"-"
+
hmQrcodeBO
.
getName
()
+
"】"
;
if
(
invokingType
!=
1
)
{
logContent
=
logContent
+
"——"
+
ChannelCodeEnum
.
getNameByCode
(
invokingType
);
}
GicLogRecordEvaluationContext
.
putAttribute
(
"logContent"
,
logContent
);
hmQrcodeService
.
deleteById
(
hmId
);
return
ServiceResponse
.
success
();
}
...
...
@@ -621,7 +630,6 @@ public class HmQrcodeApiServiceImpl implements HmQrcodeApiService {
}
else
{
delById
(
hmId
,
invokingType
);
}
}
return
ServiceResponse
.
success
();
}
...
...
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