Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
T
traffic-front
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangxiaoming
traffic-front
Commits
9ab96cbf
Commit
9ab96cbf
authored
Oct 09, 2018
by
neo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[DEL] delete common service interface
parent
0ad0d662
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
32 additions
and
54 deletions
+32
-54
AreaRegionController.java
...ava/pwc/taxtech/atms/controller/AreaRegionController.java
+14
-11
CommonService.java
...src/main/java/pwc/taxtech/atms/service/CommonService.java
+0
-12
AreaRegionServiceImpl.java
.../pwc/taxtech/atms/service/impl/AreaRegionServiceImpl.java
+10
-16
CommonServiceImpl.java
...java/pwc/taxtech/atms/service/impl/CommonServiceImpl.java
+5
-9
OrganizationServiceImpl.java
...wc/taxtech/atms/service/impl/OrganizationServiceImpl.java
+1
-2
RegionServiceImpl.java
...java/pwc/taxtech/atms/service/impl/RegionServiceImpl.java
+1
-2
UserAccountServiceImpl.java
...pwc/taxtech/atms/service/impl/UserAccountServiceImpl.java
+1
-2
No files found.
atms-api/src/main/java/pwc/taxtech/atms/controller/AreaRegionController.java
View file @
9ab96cbf
package
pwc
.
taxtech
.
atms
.
controller
;
import
java.util.List
;
import
io.swagger.annotations.ApiOperation
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -11,12 +10,12 @@ import org.springframework.web.bind.annotation.RequestMethod;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
org.springframework.web.bind.annotation.RestController
;
import
io.swagger.annotations.ApiOperation
;
import
pwc.taxtech.atms.dto.OperationResultDto
;
import
pwc.taxtech.atms.dto.arearegion.AreaRegionDto
;
import
pwc.taxtech.atms.dto.arearegion.AreaRegionInfo
;
import
pwc.taxtech.atms.service.AreaRegionService
;
import
pwc.taxtech.atms.service.impl.AreaRegionServiceImpl
;
import
java.util.List
;
@RestController
@RequestMapping
(
"/api/v1/areaRegion/"
)
...
...
@@ -25,12 +24,13 @@ public class AreaRegionController {
private
static
Logger
logger
=
LoggerFactory
.
getLogger
(
AreaRegionController
.
class
);
@Autowired
private
AreaRegionService
areaRegionService
;
private
AreaRegionService
Impl
areaRegionService
;
@SuppressWarnings
(
"rawtypes"
)
@ApiOperation
(
value
=
"Adds the specified area."
)
@RequestMapping
(
value
=
"add"
,
method
=
RequestMethod
.
POST
)
public
@ResponseBody
OperationResultDto
add
(
@RequestBody
AreaRegionInfo
areaRegionInfo
)
{
public
@ResponseBody
OperationResultDto
add
(
@RequestBody
AreaRegionInfo
areaRegionInfo
)
{
logger
.
info
(
"/api/v1/areaRegion/add"
);
return
areaRegionService
.
add
(
areaRegionInfo
);
}
...
...
@@ -38,21 +38,24 @@ public class AreaRegionController {
@SuppressWarnings
(
"rawtypes"
)
@ApiOperation
(
value
=
"Update the specified area."
)
@RequestMapping
(
value
=
"update"
,
method
=
RequestMethod
.
POST
)
public
@ResponseBody
OperationResultDto
update
(
@RequestBody
AreaRegionInfo
areaRegionInfo
)
{
public
@ResponseBody
OperationResultDto
update
(
@RequestBody
AreaRegionInfo
areaRegionInfo
)
{
logger
.
info
(
"/api/v1/areaRegion/update"
);
return
areaRegionService
.
update
(
areaRegionInfo
);
}
@ApiOperation
(
value
=
"Get cities"
)
@RequestMapping
(
value
=
"getCities"
,
method
=
RequestMethod
.
GET
)
public
@ResponseBody
List
<
AreaRegionDto
>
getCities
(
@RequestParam
(
name
=
"parentID"
)
String
parentId
)
{
public
@ResponseBody
List
<
AreaRegionDto
>
getCities
(
@RequestParam
(
name
=
"parentID"
)
String
parentId
)
{
logger
.
info
(
"/api/v1/areaRegion/getProvinces"
);
return
areaRegionService
.
getCities
(
parentId
);
}
@ApiOperation
(
value
=
"Get Provinces"
)
@RequestMapping
(
value
=
"getProvinces"
,
method
=
RequestMethod
.
GET
)
public
@ResponseBody
List
<
AreaRegionDto
>
getProvinces
()
{
public
@ResponseBody
List
<
AreaRegionDto
>
getProvinces
()
{
logger
.
info
(
"/api/v1/areaRegion/getCities"
);
return
areaRegionService
.
getProvinces
();
}
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/CommonService.java
deleted
100644 → 0
View file @
0ad0d662
package
pwc
.
taxtech
.
atms
.
service
;
import
java.util.List
;
import
pwc.taxtech.atms.dto.MailMto
;
import
pwc.taxtech.atms.dpo.EnterpriseAccountSetOrgDto
;
public
interface
CommonService
{
void
sendMail
(
MailMto
mailmto
);
boolean
isOrganizationDateTimeOverlap
(
List
<
EnterpriseAccountSetOrgDto
>
list
);
}
atms-api/src/main/java/pwc/taxtech/atms/service/impl/AreaRegionServiceImpl.java
View file @
9ab96cbf
package
pwc
.
taxtech
.
atms
.
service
.
impl
;
import
java.util.ArrayList
;
import
java.util.Comparator
;
import
java.util.List
;
import
java.util.stream.Collectors
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.util.StringUtils
;
import
pwc.taxtech.atms.common.AuthUserHelper
;
import
pwc.taxtech.atms.common.CommonConstants
;
import
pwc.taxtech.atms.common.CommonUtils
;
...
...
@@ -36,8 +30,13 @@ import pwc.taxtech.atms.entity.Region;
import
pwc.taxtech.atms.entity.RegionExample
;
import
pwc.taxtech.atms.service.OperationLogService
;
import
java.util.ArrayList
;
import
java.util.Comparator
;
import
java.util.List
;
import
java.util.stream.Collectors
;
@Service
public
class
AreaRegionServiceImpl
implements
pwc
.
taxtech
.
atms
.
service
.
AreaRegionService
{
public
class
AreaRegionServiceImpl
{
@Autowired
private
AreaRegionMapper
areaRegionMapper
;
...
...
@@ -52,7 +51,6 @@ public class AreaRegionServiceImpl implements pwc.taxtech.atms.service.AreaRegio
@Autowired
private
RegionMapper
regionMapper
;
@Override
public
List
<
AreaRegion
>
findAreaRegionsByArea
(
String
areaId
)
{
return
areaRegionMapper
.
selectAreaRegionByAreaId
(
areaId
);
...
...
@@ -60,12 +58,11 @@ public class AreaRegionServiceImpl implements pwc.taxtech.atms.service.AreaRegio
/*
* (non-Javadoc)
*
*
* @see
* pwc.taxtech.atms.service.AreaRegionService#add(pwc.taxtech.atms.service.dto.
* AreaRegionInfo)
*/
@Override
@Transactional
public
OperationResultDto
add
(
AreaRegionInfo
areaRegionInfo
)
{
...
...
@@ -124,12 +121,11 @@ public class AreaRegionServiceImpl implements pwc.taxtech.atms.service.AreaRegio
/*
* (non-Javadoc)
*
*
* @see
* pwc.taxtech.atms.service.AreaRegionService#update(pwc.taxtech.atms.service.
* dto.AreaRegionInfo)
*/
@Override
@Transactional
public
OperationResultDto
update
(
AreaRegionInfo
areaRegionInfo
)
{
...
...
@@ -237,14 +233,12 @@ public class AreaRegionServiceImpl implements pwc.taxtech.atms.service.AreaRegio
return
new
OperationResultDto
(
true
);
}
@Override
public
List
<
AreaRegionDto
>
getProvinces
(){
public
List
<
AreaRegionDto
>
getProvinces
()
{
List
<
AreaRegionDto
>
provinces
=
getRegions
(
CommonConstants
.
REGION_LEVELTYPE_PROVINCE
);
return
provinces
;
}
@Override
public
List
<
AreaRegionDto
>
getCities
(
String
parentId
)
{
List
<
AreaRegionDto
>
cities
=
getRegions
(
CommonConstants
.
REGION_LEVELTYPE_CITY
);
List
<
AreaRegionDto
>
query
=
cities
.
stream
().
filter
(
s
->
s
.
getRegionParentId
().
equals
(
parentId
))
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/CommonServiceImpl.java
View file @
9ab96cbf
package
pwc
.
taxtech
.
atms
.
service
.
impl
;
import
java.util.ArrayList
;
import
java.util.Date
;
import
java.util.List
;
import
org.nutz.lang.Strings
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
pwc.taxtech.atms.common.CommonConstants
;
import
pwc.taxtech.atms.dao.MailQueueMapper
;
import
pwc.taxtech.atms.dpo.EnterpriseAccountSetOrgDto
;
import
pwc.taxtech.atms.dto.MailMto
;
import
pwc.taxtech.atms.entity.MailQueue
;
import
pwc.taxtech.atms.service.CommonService
;
import
java.util.ArrayList
;
import
java.util.Date
;
import
java.util.List
;
@Service
public
class
CommonServiceImpl
implements
CommonService
{
public
class
CommonServiceImpl
{
private
static
final
Logger
logger
=
LoggerFactory
.
getLogger
(
CommonServiceImpl
.
class
);
@Autowired
private
MailQueueMapper
mailQueueMapper
;
@Override
public
void
sendMail
(
MailMto
mailmto
)
{
logger
.
debug
(
"enter sendMail"
);
mailmto
.
setFrom
(
CommonConstants
.
MailFrom
);
...
...
@@ -71,7 +68,6 @@ public class CommonServiceImpl implements CommonService {
}
@Override
public
boolean
isOrganizationDateTimeOverlap
(
List
<
EnterpriseAccountSetOrgDto
>
list
)
{
for
(
int
i
=
list
.
size
()
-
1
;
i
>=
0
;
i
--)
{
list
.
get
(
i
).
setOverlapList
(
new
ArrayList
<>());
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/OrganizationServiceImpl.java
View file @
9ab96cbf
...
...
@@ -56,7 +56,6 @@ import pwc.taxtech.atms.dto.user.NameDto;
import
pwc.taxtech.atms.entity.*
;
import
pwc.taxtech.atms.entity.OrganizationExample.Criteria
;
import
pwc.taxtech.atms.exception.ApplicationException
;
import
pwc.taxtech.atms.service.CommonService
;
import
pwc.taxtech.atms.service.OperationLogService
;
import
java.text.SimpleDateFormat
;
...
...
@@ -100,7 +99,7 @@ public class OrganizationServiceImpl {
private
DimensionServiceImpl
dimensionService
;
@Autowired
private
CommonService
commonService
;
private
CommonService
Impl
commonService
;
@Autowired
private
RoleServiceImpl
roleService
;
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/RegionServiceImpl.java
View file @
9ab96cbf
...
...
@@ -18,7 +18,6 @@ import pwc.taxtech.atms.entity.AreaRegionExample;
import
pwc.taxtech.atms.entity.Region
;
import
pwc.taxtech.atms.entity.RegionExample
;
import
pwc.taxtech.atms.exception.ApplicationException
;
import
pwc.taxtech.atms.service.AreaRegionService
;
import
pwc.taxtech.atms.service.AreaService
;
import
java.util.ArrayList
;
...
...
@@ -37,7 +36,7 @@ public class RegionServiceImpl extends AbstractService {
private
AreaService
areaService
;
@Autowired
private
AreaRegionService
areaRegionService
;
private
AreaRegionService
Impl
areaRegionService
;
@Autowired
private
RegionMapper
regionMapper
;
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/UserAccountServiceImpl.java
View file @
9ab96cbf
...
...
@@ -28,7 +28,6 @@ import pwc.taxtech.atms.entity.UserHistoricalPasswordExample.Criteria;
import
pwc.taxtech.atms.entity.UserOrganization
;
import
pwc.taxtech.atms.entity.UserRole
;
import
pwc.taxtech.atms.security.AtmsPasswordEncoder
;
import
pwc.taxtech.atms.service.CommonService
;
import
java.util.ArrayList
;
import
java.util.Date
;
...
...
@@ -51,7 +50,7 @@ public class UserAccountServiceImpl extends AbstractService {
@Autowired
private
UserServiceImpl
userService
;
@Autowired
private
CommonService
commonService
;
private
CommonService
Impl
commonService
;
@Autowired
private
AtmsPasswordEncoder
atmsPasswordEncoder
;
...
...
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