Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dm_project
Project
Project
Details
Activity
Releases
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
姚本章
dm_project
Commits
865cf125
Commit
865cf125
authored
Dec 04, 2020
by
zhangc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复调试中已知bug
parent
ca1aa927
Changes
21
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
140 additions
and
59 deletions
+140
-59
pom.xml
jz-dm-common/pom.xml
+1
-0
CompanyAddReq.java
...dm/mall/moduls/controller/company/bean/CompanyAddReq.java
+1
-1
LogInfoController.java
...m/jz/dm/mall/moduls/controller/log/LogInfoController.java
+2
-4
PlatformLog.java
...c/main/java/com/jz/dm/mall/moduls/entity/PlatformLog.java
+1
-0
DepartmentDao.java
...main/java/com/jz/dm/mall/moduls/mapper/DepartmentDao.java
+8
-1
FinanceCustomerAssetsDao.java
...om/jz/dm/mall/moduls/mapper/FinanceCustomerAssetsDao.java
+8
-0
PlatformLogDao.java
...ain/java/com/jz/dm/mall/moduls/mapper/PlatformLogDao.java
+9
-2
LogInfoService.java
...in/java/com/jz/dm/mall/moduls/service/LogInfoService.java
+2
-3
CompanyAuthServiceImpl.java
...z/dm/mall/moduls/service/impl/CompanyAuthServiceImpl.java
+6
-3
LogInfoServiceImpl.java
...om/jz/dm/mall/moduls/service/impl/LogInfoServiceImpl.java
+16
-16
application-test.yml
jz-dm-mall/src/main/resources/application-test.yml
+1
-1
DepartmentDao.xml
jz-dm-mall/src/main/resources/mapperconf/DepartmentDao.xml
+16
-5
FinanceCustomerAssetsDao.xml
...rc/main/resources/mapperconf/FinanceCustomerAssetsDao.xml
+4
-0
MallCustomerDao.xml
jz-dm-mall/src/main/resources/mapperconf/MallCustomerDao.xml
+12
-2
PlatformLogDao.xml
jz-dm-mall/src/main/resources/mapperconf/PlatformLogDao.xml
+16
-1
PlatformLogController.java
...z/manage/moduls/controller/log/PlatformLogController.java
+5
-2
PlatformLogDao.java
...main/java/com/jz/manage/moduls/mapper/PlatformLogDao.java
+1
-1
PlatformLogService.java
...java/com/jz/manage/moduls/service/PlatformLogService.java
+2
-2
PlatformLogServiceImpl.java
...jz/manage/moduls/service/impl/PlatformLogServiceImpl.java
+16
-11
SysUserServiceImpl.java
...com/jz/manage/moduls/service/impl/SysUserServiceImpl.java
+2
-2
PlatformLogDao.xml
...m-manage/src/main/resources/mapper/log/PlatformLogDao.xml
+11
-2
No files found.
jz-dm-common/pom.xml
View file @
865cf125
...
@@ -23,6 +23,7 @@
...
@@ -23,6 +23,7 @@
<groupId>
org.springframework.boot
</groupId>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-web
</artifactId>
<artifactId>
spring-boot-starter-web
</artifactId>
</dependency>
</dependency>
<dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-aop
</artifactId>
<artifactId>
spring-boot-starter-aop
</artifactId>
...
...
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/controller/company/bean/CompanyAddReq.java
View file @
865cf125
...
@@ -62,6 +62,6 @@ public class CompanyAddReq implements Serializable {
...
@@ -62,6 +62,6 @@ public class CompanyAddReq implements Serializable {
@ApiModelProperty
(
name
=
"登录用户id"
,
hidden
=
true
)
@ApiModelProperty
(
name
=
"登录用户id"
,
hidden
=
true
)
private
Long
loginId
;
private
Long
loginId
;
@ApiModelProperty
(
name
=
"登录用户名称"
,
hidden
=
true
)
@ApiModelProperty
(
name
=
"登录用户名称"
,
hidden
=
true
)
private
String
L
oginName
;
private
String
l
oginName
;
}
}
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/controller/log/LogInfoController.java
View file @
865cf125
package
com
.
jz
.
dm
.
mall
.
moduls
.
controller
.
log
;
package
com
.
jz
.
dm
.
mall
.
moduls
.
controller
.
log
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
dm.mall.moduls
.entity.PlatformLog
;
import
com.jz.common.utils.Result
;
import
com.jz.common.utils.Result
;
import
com.jz.dm.mall.moduls.controller.company.bean.CompanyAddReq
;
import
com.jz.dm.mall.moduls.controller.log.bean.LogInfoQueryReq
;
import
com.jz.dm.mall.moduls.controller.log.bean.LogInfoQueryReq
;
import
com.jz.dm.mall.moduls.controller.order.bean.OrderDto
;
import
com.jz.dm.mall.moduls.service.LogInfoService
;
import
com.jz.dm.mall.moduls.service.LogInfoService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
...
@@ -41,7 +39,7 @@ public class LogInfoController {
...
@@ -41,7 +39,7 @@ public class LogInfoController {
*/
*/
@PostMapping
(
"/getMallLogInfo"
)
@PostMapping
(
"/getMallLogInfo"
)
@ApiOperation
(
value
=
"获取商城用户日志信息列表"
)
@ApiOperation
(
value
=
"获取商城用户日志信息列表"
)
public
Mono
<
Result
<
PageInfoResponse
<
PlatformLog
>
>>
getLogInfo
(
@RequestBody
@Validated
LogInfoQueryReq
req
,
HttpServletRequest
request
)
{
public
Mono
<
PageInfoResponse
<
PlatformLog
>>
getLogInfo
(
@RequestBody
@Validated
LogInfoQueryReq
req
,
HttpServletRequest
request
)
{
return
Mono
.
fromSupplier
(()
->
logInfoService
.
getMallUserLogInfo
(
req
,
request
));
return
Mono
.
fromSupplier
(()
->
logInfoService
.
getMallUserLogInfo
(
req
,
request
));
}
}
...
...
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/entity/PlatformLog.java
View file @
865cf125
package
com
.
jz
.
dm
.
mall
.
moduls
.
entity
;
package
com
.
jz
.
dm
.
mall
.
moduls
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
...
...
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/mapper/DepartmentDao.java
View file @
865cf125
...
@@ -21,7 +21,7 @@ public interface DepartmentDao extends BaseMapper<Department> {
...
@@ -21,7 +21,7 @@ public interface DepartmentDao extends BaseMapper<Department> {
* @param req
* @param req
* @return
* @return
*/
*/
Department
selectDepartmentData
(
CompanyAddReq
req
);
Department
selectDepartmentData
(
@Param
(
"req"
)
CompanyAddReq
req
);
/**
/**
* 查询企业状态
* 查询企业状态
...
@@ -38,4 +38,11 @@ public interface DepartmentDao extends BaseMapper<Department> {
...
@@ -38,4 +38,11 @@ public interface DepartmentDao extends BaseMapper<Department> {
* @return
* @return
*/
*/
CompanyInfoDto
selectCompanyDetail
(
@Param
(
"departmentId"
)
Long
departmentId
);
CompanyInfoDto
selectCompanyDetail
(
@Param
(
"departmentId"
)
Long
departmentId
);
/**
* 保存企业认证信息
* @param dep
* @return
*/
int
insertDepart
(
@Param
(
"dep"
)
Department
dep
);
}
}
\ No newline at end of file
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/mapper/FinanceCustomerAssetsDao.java
View file @
865cf125
...
@@ -3,6 +3,7 @@ package com.jz.dm.mall.moduls.mapper;
...
@@ -3,6 +3,7 @@ package com.jz.dm.mall.moduls.mapper;
import
com.jz.common.base.BaseMapper
;
import
com.jz.common.base.BaseMapper
;
import
com.jz.dm.mall.moduls.entity.FinanceCustomerAssets
;
import
com.jz.dm.mall.moduls.entity.FinanceCustomerAssets
;
import
com.jz.dm.mall.moduls.entity.FinanceCustomerBalance
;
import
com.jz.dm.mall.moduls.entity.FinanceCustomerBalance
;
import
org.apache.ibatis.annotations.Param
;
/**
/**
* 商城企业客户资产(TFinanceCustomerAssets)表数据库访问层
* 商城企业客户资产(TFinanceCustomerAssets)表数据库访问层
...
@@ -15,4 +16,11 @@ public interface FinanceCustomerAssetsDao extends BaseMapper<FinanceCustomerAsse
...
@@ -15,4 +16,11 @@ public interface FinanceCustomerAssetsDao extends BaseMapper<FinanceCustomerAsse
int
uptAccountMoney
(
FinanceCustomerAssets
financeCustomerAssets
)
throws
Exception
;
int
uptAccountMoney
(
FinanceCustomerAssets
financeCustomerAssets
)
throws
Exception
;
int
addCoustomerCzMoney
(
FinanceCustomerBalance
financeCustomerBalance
)
throws
Exception
;
int
addCoustomerCzMoney
(
FinanceCustomerBalance
financeCustomerBalance
)
throws
Exception
;
/**
* 添加账户信息
* @param finance
* @return
*/
int
insertFinanceCustome
(
@Param
(
"finance"
)
FinanceCustomerAssets
finance
);
}
}
\ No newline at end of file
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/mapper/PlatformLogDao.java
View file @
865cf125
package
com
.
jz
.
dm
.
mall
.
moduls
.
mapper
;
package
com
.
jz
.
dm
.
mall
.
moduls
.
mapper
;
import
com.jz.common.base.BaseMapper
;
import
com.jz.common.base.BaseMapper
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
dm.mall.moduls
.entity.PlatformLog
;
import
com.jz.dm.mall.moduls.controller.order.bean.OrderDto
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
import
java.util.List
;
...
@@ -20,4 +20,11 @@ public interface PlatformLogDao extends BaseMapper<PlatformLog> {
...
@@ -20,4 +20,11 @@ public interface PlatformLogDao extends BaseMapper<PlatformLog> {
* @return
* @return
*/
*/
List
<
PlatformLog
>
listMallLogInfo
(
Long
customerId
);
List
<
PlatformLog
>
listMallLogInfo
(
Long
customerId
);
/**
* 根据日志ID查询日志信息
* @param platformLogId
* @return
*/
PlatformLog
findByPlatformId
(
@Param
(
"platformLogId"
)
Long
platformLogId
);
}
}
\ No newline at end of file
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/service/LogInfoService.java
View file @
865cf125
package
com
.
jz
.
dm
.
mall
.
moduls
.
service
;
package
com
.
jz
.
dm
.
mall
.
moduls
.
service
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
dm.mall.moduls
.entity.PlatformLog
;
import
com.jz.common.utils.Result
;
import
com.jz.common.utils.Result
;
import
com.jz.dm.mall.moduls.controller.log.bean.LogInfoQueryReq
;
import
com.jz.dm.mall.moduls.controller.log.bean.LogInfoQueryReq
;
import
com.jz.dm.mall.moduls.controller.order.bean.OrderDto
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletRequest
;
...
@@ -25,7 +24,7 @@ public interface LogInfoService {
...
@@ -25,7 +24,7 @@ public interface LogInfoService {
* @param req
* @param req
* @return
* @return
*/
*/
Result
<
PageInfoResponse
<
PlatformLog
>
>
getMallUserLogInfo
(
LogInfoQueryReq
req
,
HttpServletRequest
request
);
PageInfoResponse
<
PlatformLog
>
getMallUserLogInfo
(
LogInfoQueryReq
req
,
HttpServletRequest
request
);
/**
/**
* 获取商城用户日志信息详情
* 获取商城用户日志信息详情
...
...
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/service/impl/CompanyAuthServiceImpl.java
View file @
865cf125
...
@@ -59,7 +59,10 @@ public class CompanyAuthServiceImpl implements CompanyAuthService {
...
@@ -59,7 +59,10 @@ public class CompanyAuthServiceImpl implements CompanyAuthService {
@Transactional
(
rollbackFor
=
Exception
.
class
,
propagation
=
Propagation
.
REQUIRES_NEW
)
@Transactional
(
rollbackFor
=
Exception
.
class
,
propagation
=
Propagation
.
REQUIRES_NEW
)
public
Result
addCompanyData
(
CompanyAddReq
req
,
HttpServletRequest
request
)
{
public
Result
addCompanyData
(
CompanyAddReq
req
,
HttpServletRequest
request
)
{
//获取当前用户ID判断当前用户是否已经关联企业
//获取当前用户ID判断当前用户是否已经关联企业
MallCustomerApiDto
currentUser
=
CurrentUser
.
getCurrentUser
(
request
);
//MallCustomerApiDto currentUser = CurrentUser.getCurrentUser(request);
MallCustomerApiDto
currentUser
=
new
MallCustomerApiDto
();
currentUser
.
setCustomerId
(
1L
);
currentUser
.
setCustomerName
(
"张胜男"
);
if
(
null
==
currentUser
)
{
if
(
null
==
currentUser
)
{
return
Result
.
of_error
(
ResultMsg
.
USER_NOT_EXIST
);
return
Result
.
of_error
(
ResultMsg
.
USER_NOT_EXIST
);
}
}
...
@@ -180,7 +183,7 @@ public class CompanyAuthServiceImpl implements CompanyAuthService {
...
@@ -180,7 +183,7 @@ public class CompanyAuthServiceImpl implements CompanyAuthService {
departmentInset
.
setCreTime
(
new
Date
());
departmentInset
.
setCreTime
(
new
Date
());
departmentInset
.
setCrePerson
(
req
.
getLoginName
());
departmentInset
.
setCrePerson
(
req
.
getLoginName
());
BeanUtils
.
copyProperties
(
req
,
departmentInset
);
BeanUtils
.
copyProperties
(
req
,
departmentInset
);
if
(
departmentDao
.
insert
(
departmentInset
)
!=
1
)
{
if
(
departmentDao
.
insert
Depart
(
departmentInset
)
!=
1
)
{
throw
ResponseException
.
of_error
(
"保存企业信息失败"
);
throw
ResponseException
.
of_error
(
"保存企业信息失败"
);
}
}
//初始化用户资产表
//初始化用户资产表
...
@@ -188,7 +191,7 @@ public class CompanyAuthServiceImpl implements CompanyAuthService {
...
@@ -188,7 +191,7 @@ public class CompanyAuthServiceImpl implements CompanyAuthService {
finance
.
setDepartmentId
(
departmentInset
.
getDepartmentId
());
//企业ID
finance
.
setDepartmentId
(
departmentInset
.
getDepartmentId
());
//企业ID
finance
.
setCreTime
(
new
Date
());
finance
.
setCreTime
(
new
Date
());
finance
.
setCrePerson
(
req
.
getLoginName
());
finance
.
setCrePerson
(
req
.
getLoginName
());
if
(
financeCustomerAssetsDao
.
insert
(
finance
)
!=
1
)
{
if
(
financeCustomerAssetsDao
.
insert
FinanceCustome
(
finance
)
!=
1
)
{
throw
ResponseException
.
of_error
(
"初始化用户资产失败"
);
throw
ResponseException
.
of_error
(
"初始化用户资产失败"
);
}
}
//更新用户企业信息
//更新用户企业信息
...
...
jz-dm-mall/src/main/java/com/jz/dm/mall/moduls/service/impl/LogInfoServiceImpl.java
View file @
865cf125
package
com
.
jz
.
dm
.
mall
.
moduls
.
service
.
impl
;
package
com
.
jz
.
dm
.
mall
.
moduls
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.github.pagehelper.PageInfo
;
import
com.jz.common.base.CurrentUser
;
import
com.jz.common.base.CurrentUser
;
import
com.jz.common.bean.MallCustomerApiDto
;
import
com.jz.common.bean.MallCustomerApiDto
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.constant.Constants
;
import
com.jz.common.constant.Constants
;
import
com.jz.common.constant.ResultCode
;
import
com.jz.common.constant.ResultMsg
;
import
com.jz.common.constant.ResultMsg
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
dm.mall.moduls
.entity.PlatformLog
;
import
com.jz.common.utils.Result
;
import
com.jz.common.utils.Result
;
import
com.jz.dm.mall.moduls.controller.log.bean.LogInfoQueryReq
;
import
com.jz.dm.mall.moduls.controller.log.bean.LogInfoQueryReq
;
import
com.jz.dm.mall.moduls.controller.order.bean.OrderDto
;
import
com.jz.dm.mall.moduls.entity.MallCustomer
;
import
com.jz.dm.mall.moduls.entity.MallCustomer
;
import
com.jz.dm.mall.moduls.mapper.MallCustomerDao
;
import
com.jz.dm.mall.moduls.mapper.MallCustomerDao
;
import
com.jz.dm.mall.moduls.mapper.PlatformLogDao
;
import
com.jz.dm.mall.moduls.mapper.PlatformLogDao
;
...
@@ -51,25 +47,29 @@ public class LogInfoServiceImpl implements LogInfoService {
...
@@ -51,25 +47,29 @@ public class LogInfoServiceImpl implements LogInfoService {
* @return
* @return
*/
*/
@Override
@Override
public
Result
<
PageInfoResponse
<
PlatformLog
>>
getMallUserLogInfo
(
LogInfoQueryReq
req
,
HttpServletRequest
request
)
{
public
PageInfoResponse
<
PlatformLog
>
getMallUserLogInfo
(
LogInfoQueryReq
req
,
HttpServletRequest
request
)
{
//MallCustomerApiDto currentUser = CurrentUser.getCurrentUser(request);
PageInfoResponse
<
PlatformLog
>
pageInfoResponse
=
new
PageInfoResponse
<>();
//if (null == currentUser) {
MallCustomerApiDto
currentUser
=
CurrentUser
.
getCurrentUser
(
request
);
// return Result.of_error(ResultMsg.USER_NOT_EXIST);
if
(
null
==
currentUser
)
{
//}
pageInfoResponse
.
setCode
(
Constants
.
SUCCESS_CODE
);
MallCustomerApiDto
currentUser
=
new
MallCustomerApiDto
();
pageInfoResponse
.
setMessage
(
ResultMsg
.
USER_NOT_EXIST
.
getMsg
());
currentUser
.
setCustomerId
(
1L
);
return
pageInfoResponse
;
}
//MallCustomerApiDto currentUser =new MallCustomerApiDto();
//currentUser.setCustomerId(1L);
MallCustomer
mallCustomer
=
mallCustomerDao
.
findById
(
currentUser
.
getCustomerId
());
MallCustomer
mallCustomer
=
mallCustomerDao
.
findById
(
currentUser
.
getCustomerId
());
if
(
null
==
mallCustomer
)
{
if
(
null
==
mallCustomer
)
{
return
Result
.
of_error
(
ResultMsg
.
USER_NOT_EXIST
);
pageInfoResponse
.
setCode
(
Constants
.
SUCCESS_CODE
);
pageInfoResponse
.
setMessage
(
ResultMsg
.
USER_NOT_EXIST
.
getMsg
());
return
pageInfoResponse
;
}
}
PageInfoResponse
<
PlatformLog
>
pageInfoResponse
=
new
PageInfoResponse
<>();
PageHelper
.
startPage
(
req
.
getPageNum
(),
req
.
getPageSize
());
PageHelper
.
startPage
(
req
.
getPageNum
(),
req
.
getPageSize
());
List
<
PlatformLog
>
list
=
platformLogDao
.
listMallLogInfo
(
mallCustomer
.
getCustomerId
());
List
<
PlatformLog
>
list
=
platformLogDao
.
listMallLogInfo
(
mallCustomer
.
getCustomerId
());
PageInfo
<
PlatformLog
>
pageInfo
=
new
PageInfo
<>(
list
);
PageInfo
<
PlatformLog
>
pageInfo
=
new
PageInfo
<>(
list
);
pageInfoResponse
.
setCode
(
Constants
.
SUCCESS_CODE
);
pageInfoResponse
.
setCode
(
Constants
.
SUCCESS_CODE
);
pageInfoResponse
.
setMessage
(
ResultMsg
.
SUCCESS
.
getMsg
());
pageInfoResponse
.
setMessage
(
ResultMsg
.
SUCCESS
.
getMsg
());
pageInfoResponse
.
setData
(
pageInfo
);
pageInfoResponse
.
setData
(
pageInfo
);
return
Result
.
of_success
(
pageInfoResponse
)
;
return
pageInfoResponse
;
}
}
/**
/**
...
@@ -79,7 +79,7 @@ public class LogInfoServiceImpl implements LogInfoService {
...
@@ -79,7 +79,7 @@ public class LogInfoServiceImpl implements LogInfoService {
*/
*/
@Override
@Override
public
Result
getMallUserLogDetail
(
Long
platformLogId
)
{
public
Result
getMallUserLogDetail
(
Long
platformLogId
)
{
PlatformLog
platformLog
=
platformLogDao
.
selectBy
Id
(
platformLogId
);
PlatformLog
platformLog
=
platformLogDao
.
findByPlatform
Id
(
platformLogId
);
if
(
null
==
platformLog
){
if
(
null
==
platformLog
){
return
Result
.
of_error
(
ResultMsg
.
DATA_NOT_FOUND
);
return
Result
.
of_error
(
ResultMsg
.
DATA_NOT_FOUND
);
}
}
...
...
jz-dm-mall/src/main/resources/application-test.yml
View file @
865cf125
...
@@ -66,4 +66,4 @@ mybatis:
...
@@ -66,4 +66,4 @@ mybatis:
logging
:
logging
:
level
:
level
:
com.jz.
manage
:
debug
com.jz.
dm.mall
:
debug
jz-dm-mall/src/main/resources/mapperconf/DepartmentDao.xml
View file @
865cf125
...
@@ -35,13 +35,24 @@
...
@@ -35,13 +35,24 @@
</resultMap>
</resultMap>
-->
-->
<sql
id=
"department"
>
<sql
id=
"department"
>
department_id,department_name,legal_representative,province,city,industry,linkman,telephone,registered_address,
department_id AS departmentId,department_name AS departmentName,legal_representative AS legalRepresentative,
depart_picture,business_license,tax_registration,depart_picture_time,business_license_time,tax_registration_time,
province AS province,city AS city,industry AS industry,linkman AS linkman,telephone AS telephone,registered_address AS registeredAddress,
unified_credit_code,bank_name,bank_card_number,bank_address,bank_no,audit_status,audit_status,audit_person,cre_time,
depart_picture AS departPicture,business_license AS businessLicense,tax_registration AS taxRegistration,depart_picture_time AS departPictureTime,
cre_person,del_flag
business_license_time AS businessLicenseTime,tax_registration_time AS taxRegistrationTime,
unified_credit_code AS unifiedCreditCode,bank_name AS bankName,bank_card_number AS bankCardNumber,bank_address AS bankAddress,
bank_no AS bankNo,audit_status AS auditStatus,audit_status AS auditStatus,audit_person AS auditPerson,cre_time AS creTime,
cre_person AS crePerson,del_flag AS delFlag
</sql>
</sql>
<insert
id=
"insertDepart"
>
INSERT INTO `t_department`(`department_name`,`province`,`city`,`linkman`,`telephone`,`registered_address`,
`business_license`, `tax_registration`, `depart_picture_time`,
`business_license_time`,`unified_credit_code`, `bank_name`,
`bank_card_number`,`audit_status`,`cre_time`, `cre_person`) VALUES
(#{dep.departmentName},#{dep.province},#{dep.city},#{linkman},#{dep.telephone},#{registeredAddress},
#{dep.businessLicense},#{dep.unifiedCreditCode},#{bankName},#{bankCardNumber},#{auditStatus},NOW(),#{crePerson})
</insert>
<select
id=
"selectDepartmentData"
resultType=
"com.jz.common.entity.Department"
>
<select
id=
"selectDepartmentData"
resultType=
"com.jz.common.entity.Department"
parameterType=
"com.jz.dm.mall.moduls.controller.company.bean.CompanyAddReq"
>
SELECT
SELECT
<include
refid=
"department"
/>
<include
refid=
"department"
/>
FROM t_department
FROM t_department
...
...
jz-dm-mall/src/main/resources/mapperconf/FinanceCustomerAssetsDao.xml
View file @
865cf125
...
@@ -154,5 +154,9 @@
...
@@ -154,5 +154,9 @@
insert into t_finance_customer_balance(assets_id, balance_money, remark, cre_time, cre_person, audit_status)
insert into t_finance_customer_balance(assets_id, balance_money, remark, cre_time, cre_person, audit_status)
values (#{assetsId}, #{balanceMoney}, #{remark}, #{creTime}, #{crePerson}, #{auditStatus})
values (#{assetsId}, #{balanceMoney}, #{remark}, #{creTime}, #{crePerson}, #{auditStatus})
</insert>
</insert>
<insert
id=
"insertFinanceCustome"
>
INSERT INTO t_finance_customer_assets(department_id,cre_time, cre_person)VALUES
(#{finance.departmentId},NOW(),#{finance.crePerson})
</insert>
</mapper>
</mapper>
\ No newline at end of file
jz-dm-mall/src/main/resources/mapperconf/MallCustomerDao.xml
View file @
865cf125
...
@@ -189,9 +189,19 @@
...
@@ -189,9 +189,19 @@
SELECT customer_id AS customerId,
SELECT customer_id AS customerId,
department_id AS departmentId,
department_id AS departmentId,
password AS password,
password AS password,
customer_account AS customerAccount,
customer_name AS customerName,
customer_phone AS customerPhone,
customer_email AS customerEmail,
customer_address AS customerAddress,
customer_point AS customerPoint,
register_time AS registerTime,
customer_level AS customerLevel,
identity_card AS identityCard,
cre_time AS creTime,
cre_person AS crePerson
FROM t_mall_customer
FROM t_mall_customer
WHERE customer_id =#{customerId}
WHERE customer_id =#{customerId}
AND del_flag ='N'
"
AND del_flag ='N'
</select>
</select>
</mapper>
</mapper>
\ No newline at end of file
jz-dm-mall/src/main/resources/mapperconf/PlatformLogDao.xml
View file @
865cf125
...
@@ -24,8 +24,23 @@
...
@@ -24,8 +24,23 @@
<result
property=
"creTime"
column=
"cre_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"creTime"
column=
"cre_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"delFlag"
column=
"del_flag"
jdbcType=
"VARCHAR"
/>
<result
property=
"delFlag"
column=
"del_flag"
jdbcType=
"VARCHAR"
/>
</resultMap>
</resultMap>
<sql
id=
"allFiled"
>
platform_log_id AS platformLogId,request_ip AS requestIp,caller_id AS callerId,data_goods_id AS dataGoodsId,
api_key AS apiKey,request_params AS requestParams,return_params AS returnParams,request_url AS requestUrl
,request_time AS requestTime,service_type AS serviceType,data_goods_type AS dataGoodsType,download_address AS downloadAddress,
data_price AS dataPrice,price_type AS priceType,total_times AS totalTimes,used_times AS usedTimes
,remain_times AS remainTimes,caller_type AS callerType,start_time AS startTime,end_time AS endTime,cre_time AS creTime,
cre_person AS crePerson,upt_time AS uptTime,upt_person AS uptPerson,del_flag AS delFlag
</sql>
<select
id=
"listMallLogInfo"
resultMap=
"TPlatformLogMap"
>
<select
id=
"listMallLogInfo"
resultMap=
"TPlatformLogMap"
>
SELECT * FROM t_platform_log WHERE caller_id=#{customerId}
SELECT
<include
refid=
"allFiled"
/>
FROM t_platform_log WHERE del_flag ='N'
AND caller_id=#{customerId}
</select>
<select
id=
"findByPlatformId"
resultType=
"com.jz.dm.mall.moduls.entity.PlatformLog"
parameterType=
"map"
>
SELECT
<include
refid=
"allFiled"
/>
FROM t_platform_log
WHERE del_flag ='N'
AND platform_log_id =#{platformLogId}
</select>
</select>
</mapper>
</mapper>
\ No newline at end of file
jz-dm-manage/src/main/java/com/jz/manage/moduls/controller/log/PlatformLogController.java
View file @
865cf125
package
com
.
jz
.
manage
.
moduls
.
controller
.
log
;
package
com
.
jz
.
manage
.
moduls
.
controller
.
log
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
manage.moduls
.entity.PlatformLog
;
import
com.jz.common.utils.Result
;
import
com.jz.common.utils.Result
;
import
com.jz.manage.moduls.controller.BaseController
;
import
com.jz.manage.moduls.controller.BaseController
;
import
com.jz.manage.moduls.controller.log.bean.ManageLogInfoQueryReq
;
import
com.jz.manage.moduls.controller.log.bean.ManageLogInfoQueryReq
;
import
com.jz.manage.moduls.service.PlatformLogService
;
import
com.jz.manage.moduls.service.PlatformLogService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.validation.annotation.Validated
;
...
@@ -20,6 +22,7 @@ import reactor.core.publisher.Mono;
...
@@ -20,6 +22,7 @@ import reactor.core.publisher.Mono;
*/
*/
@RestController
@RestController
@RequestMapping
(
"platformLog"
)
@RequestMapping
(
"platformLog"
)
@Api
(
tags
=
"平台日志Controller"
)
public
class
PlatformLogController
extends
BaseController
{
public
class
PlatformLogController
extends
BaseController
{
/**
/**
* 服务对象
* 服务对象
...
@@ -34,7 +37,7 @@ public class PlatformLogController extends BaseController {
...
@@ -34,7 +37,7 @@ public class PlatformLogController extends BaseController {
*/
*/
@PostMapping
(
"/listManageLogInfo"
)
@PostMapping
(
"/listManageLogInfo"
)
@ApiOperation
(
value
=
"后台用户日志信息列表"
)
@ApiOperation
(
value
=
"后台用户日志信息列表"
)
public
Mono
<
Result
<
PageInfoRespons
e
<
PlatformLog
>>>
getLogInfo
(
@RequestBody
@Validated
ManageLogInfoQueryReq
req
)
{
public
Mono
<
Result
<
IPag
e
<
PlatformLog
>>>
getLogInfo
(
@RequestBody
@Validated
ManageLogInfoQueryReq
req
)
{
return
Mono
.
fromSupplier
(()
->
tPlatformLogService
.
listManageUserLogInfo
(
req
));
return
Mono
.
fromSupplier
(()
->
tPlatformLogService
.
listManageUserLogInfo
(
req
));
}
}
...
...
jz-dm-manage/src/main/java/com/jz/manage/moduls/mapper/PlatformLogDao.java
View file @
865cf125
package
com
.
jz
.
manage
.
moduls
.
mapper
;
package
com
.
jz
.
manage
.
moduls
.
mapper
;
import
com.jz.common.base.BaseMapper
;
import
com.jz.common.base.BaseMapper
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
manage.moduls
.entity.PlatformLog
;
import
java.util.List
;
import
java.util.List
;
...
...
jz-dm-manage/src/main/java/com/jz/manage/moduls/service/PlatformLogService.java
View file @
865cf125
package
com
.
jz
.
manage
.
moduls
.
service
;
package
com
.
jz
.
manage
.
moduls
.
service
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
manage.moduls
.entity.PlatformLog
;
import
com.jz.common.utils.Result
;
import
com.jz.common.utils.Result
;
import
com.jz.manage.moduls.controller.log.bean.ManageLogInfoQueryReq
;
import
com.jz.manage.moduls.controller.log.bean.ManageLogInfoQueryReq
;
...
@@ -19,7 +19,7 @@ public interface PlatformLogService {
...
@@ -19,7 +19,7 @@ public interface PlatformLogService {
* @param req
* @param req
* @return
* @return
*/
*/
Result
<
PageInfoResponse
<
PlatformLog
>>
listManageUserLogInfo
(
ManageLogInfoQueryReq
req
);
Result
listManageUserLogInfo
(
ManageLogInfoQueryReq
req
);
/**
/**
* 获取用户日志详情
* 获取用户日志详情
...
...
jz-dm-manage/src/main/java/com/jz/manage/moduls/service/impl/PlatformLogServiceImpl.java
View file @
865cf125
package
com
.
jz
.
manage
.
moduls
.
service
.
impl
;
package
com
.
jz
.
manage
.
moduls
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
com.github.pagehelper.PageInfo
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.bean.PageInfoResponse
;
import
com.jz.common.constant.Constants
;
import
com.jz.common.constant.Constants
;
import
com.jz.common.constant.ResultMsg
;
import
com.jz.common.constant.ResultMsg
;
import
com.jz.
common
.entity.PlatformLog
;
import
com.jz.
manage.moduls
.entity.PlatformLog
;
import
com.jz.common.utils.Result
;
import
com.jz.common.utils.Result
;
import
com.jz.manage.moduls.controller.log.bean.ManageLogInfoQueryReq
;
import
com.jz.manage.moduls.controller.log.bean.ManageLogInfoQueryReq
;
import
com.jz.manage.moduls.mapper.PlatformLogDao
;
import
com.jz.manage.moduls.mapper.PlatformLogDao
;
...
@@ -28,15 +31,13 @@ public class PlatformLogServiceImpl implements PlatformLogService {
...
@@ -28,15 +31,13 @@ public class PlatformLogServiceImpl implements PlatformLogService {
@Override
@Override
public
Result
<
PageInfoResponse
<
PlatformLog
>>
listManageUserLogInfo
(
ManageLogInfoQueryReq
req
)
{
public
Result
listManageUserLogInfo
(
ManageLogInfoQueryReq
req
)
{
PageInfoResponse
<
PlatformLog
>
pageInfoResponse
=
new
PageInfoResponse
<>();
IPage
<
PlatformLog
>
page
=
new
Page
<>(
req
.
getPageNum
(),
req
.
getPageSize
());
PageHelper
.
startPage
(
req
.
getPageNum
(),
req
.
getPageSize
());
QueryWrapper
<
PlatformLog
>
query
=
new
QueryWrapper
<>();
List
<
PlatformLog
>
list
=
tPlatformLogDao
.
listMallLogInfo
();
query
.
eq
(
"del_flag"
,
"N"
);
PageInfo
<
PlatformLog
>
pageInfo
=
new
PageInfo
<>(
list
);
query
.
orderByDesc
(
"cre_time"
);
pageInfoResponse
.
setCode
(
Constants
.
SUCCESS_CODE
);
IPage
<
PlatformLog
>
platformLogIPage
=
tPlatformLogDao
.
selectPage
(
page
,
query
);
pageInfoResponse
.
setMessage
(
ResultMsg
.
SUCCESS
.
getMsg
());
return
Result
.
of_success
(
platformLogIPage
);
pageInfoResponse
.
setData
(
pageInfo
);
return
Result
.
of_success
(
pageInfoResponse
);
}
}
/**
/**
...
@@ -46,7 +47,11 @@ public class PlatformLogServiceImpl implements PlatformLogService {
...
@@ -46,7 +47,11 @@ public class PlatformLogServiceImpl implements PlatformLogService {
*/
*/
@Override
@Override
public
Result
getMallUserLogDetail
(
Long
platformLogId
)
{
public
Result
getMallUserLogDetail
(
Long
platformLogId
)
{
PlatformLog
platformLog
=
tPlatformLogDao
.
selectById
(
platformLogId
);
QueryWrapper
<
PlatformLog
>
query
=
new
QueryWrapper
<>();
query
.
eq
(
"platform_log_id"
,
platformLogId
);
query
.
eq
(
"del_flag"
,
"N"
);
query
.
orderByDesc
(
"cre_time"
);
PlatformLog
platformLog
=
tPlatformLogDao
.
selectOne
(
query
);
if
(
null
==
platformLog
){
if
(
null
==
platformLog
){
return
Result
.
of_error
(
ResultMsg
.
DATA_NOT_FOUND
);
return
Result
.
of_error
(
ResultMsg
.
DATA_NOT_FOUND
);
}
}
...
...
jz-dm-manage/src/main/java/com/jz/manage/moduls/service/impl/SysUserServiceImpl.java
View file @
865cf125
...
@@ -47,7 +47,7 @@ public class SysUserServiceImpl implements SysUserService {
...
@@ -47,7 +47,7 @@ public class SysUserServiceImpl implements SysUserService {
SysUserDto
.
setUserTypeEnum
(
UserTypeEnum
.
BACKGROUND_ROLE
);
SysUserDto
.
setUserTypeEnum
(
UserTypeEnum
.
BACKGROUND_ROLE
);
SysUserDto
.
setUserName
(
sysUser
.
getUserName
());
SysUserDto
.
setUserName
(
sysUser
.
getUserName
());
// 存入到session
// 存入到session
SessionUtils
.
setUserCurrent
(
"sysUser"
,
SysUserDto
);
//
SessionUtils.setUserCurrent("sysUser", SysUserDto);
// 存入到redis
// 存入到redis
redisTemplate
.
opsForValue
().
set
(
"user_"
+
RedisMessageConstant
.
SENDTYPE_LOGIN_SYS
,
SysUserDto
,
3
,
TimeUnit
.
DAYS
);
redisTemplate
.
opsForValue
().
set
(
"user_"
+
RedisMessageConstant
.
SENDTYPE_LOGIN_SYS
,
SysUserDto
,
3
,
TimeUnit
.
DAYS
);
}
}
...
@@ -68,7 +68,7 @@ public class SysUserServiceImpl implements SysUserService {
...
@@ -68,7 +68,7 @@ public class SysUserServiceImpl implements SysUserService {
SysUserDto
.
setUserTypeEnum
(
UserTypeEnum
.
BACKGROUND_ROLE
);
SysUserDto
.
setUserTypeEnum
(
UserTypeEnum
.
BACKGROUND_ROLE
);
SysUserDto
.
setUserName
(
sysUser
.
getUserName
());
SysUserDto
.
setUserName
(
sysUser
.
getUserName
());
// 存入到session
// 存入到session
SessionUtils
.
setUserCurrent
(
"sysUser"
,
SysUserDto
);
//
SessionUtils.setUserCurrent("sysUser", SysUserDto);
// 存入到redis
// 存入到redis
redisTemplate
.
opsForValue
().
set
(
"user_"
+
RedisMessageConstant
.
SENDTYPE_LOGIN_SYS
,
SysUserDto
,
3
,
TimeUnit
.
DAYS
);
redisTemplate
.
opsForValue
().
set
(
"user_"
+
RedisMessageConstant
.
SENDTYPE_LOGIN_SYS
,
SysUserDto
,
3
,
TimeUnit
.
DAYS
);
}
}
...
...
jz-dm-manage/src/main/resources/mapper/log/PlatformLogDao.xml
View file @
865cf125
...
@@ -25,8 +25,17 @@
...
@@ -25,8 +25,17 @@
<result
property=
"creTime"
column=
"cre_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"creTime"
column=
"cre_time"
jdbcType=
"TIMESTAMP"
/>
<result
property=
"delFlag"
column=
"del_flag"
jdbcType=
"VARCHAR"
/>
<result
property=
"delFlag"
column=
"del_flag"
jdbcType=
"VARCHAR"
/>
</resultMap>
</resultMap>
<select
id=
"listMallLogInfo"
resultMap=
"TPlatformLogMap"
>
SELECT * FROM t_t_platform_log
<sql
id=
"allFiled"
>
platform_log_id AS platformLogId,request_ip AS requestIp,caller_id AS callerId,data_goods_id AS dataGoodsId,
api_key AS apiKey,request_params AS requestParams,return_params AS returnParams,request_url AS requestUrl
,request_time AS requestTime,service_type AS serviceType,data_goods_type AS dataGoodsType,download_address AS downloadAddress,
data_price AS dataPrice,price_type AS priceType,total_times AS totalTimes,used_times AS usedTimes
,remain_times AS remainTimes,caller_type AS callerType,start_time AS startTime,end_time AS endTime,cre_time AS creTime,
cre_person AS crePerson,upt_time AS uptTime,upt_person AS uptPerson,del_flag AS delFlag
</sql>
<select
id=
"listMallLogInfo"
resultType=
"com.jz.manage.moduls.entity.PlatformLog"
>
SELECT
<include
refid=
"allFiled"
/>
FROM t_platform_log
</select>
</select>
</mapper>
</mapper>
\ No newline at end of file
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