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
e1380145
Commit
e1380145
authored
Jun 11, 2018
by
frank.xa.zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
complete api for data view---VoucherSelectAdvancedCount
parent
c62cf22c
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
244 additions
and
28 deletions
+244
-28
VoucherSelect.java
...rc/main/java/pwc/taxtech/atms/constant/VoucherSelect.java
+42
-0
VoucherLevelEnum.java
...ava/pwc/taxtech/atms/constant/enums/VoucherLevelEnum.java
+25
-0
VoucherTmplDto.java
...main/java/pwc/taxtech/atms/dto/vatdto/VoucherTmplDto.java
+143
-0
DataSourcePoolService.java
.../pwc/taxtech/atms/service/impl/DataSourcePoolService.java
+6
-0
VoucherService.java
...ain/java/pwc/taxtech/atms/vat/service/VoucherService.java
+2
-2
VoucherServiceImpl.java
...pwc/taxtech/atms/vat/service/impl/VoucherServiceImpl.java
+0
-0
applicationContext-datasource.xml
...-api/src/main/resources/applicationContext-datasource.xml
+26
-26
No files found.
atms-api/src/main/java/pwc/taxtech/atms/constant/VoucherSelect.java
0 → 100644
View file @
e1380145
package
pwc
.
taxtech
.
atms
.
constant
;
public
class
VoucherSelect
{
public
static
final
String
S_EqualAnyKey
=
"等于任意一个关键词"
;
public
static
final
String
S_AnyHeaderKey
=
"以任意一个关键词开头"
;
public
static
final
String
S_AllKey
=
"包含全部关键词"
;
public
static
final
String
S_ContainAnyKey
=
"包含任意一个关键词"
;
public
static
final
String
S_AndAll
=
"与"
;
public
static
final
String
S_OrAll
=
"或"
;
public
static
final
String
S_Manual
=
"手工凭证"
;
public
static
final
String
S_Industry
=
"企业凭证"
;
public
static
final
String
S_Equal
=
"等于"
;
public
static
final
String
S_Greater
=
"大于"
;
public
static
final
String
S_GreaterEqual
=
"大于等于"
;
public
static
final
String
S_Include
=
"包含"
;
public
static
final
String
S_JFLJ
=
"借方累计金额"
;
public
static
final
String
S_Less
=
"小于"
;
public
static
final
String
S_LessEqual
=
"小于等于"
;
public
static
final
String
S_NotEqual
=
"不等于"
;
public
static
final
String
S_NotInclude
=
"不包含"
;
public
static
final
String
S_Or
=
"或者"
;
public
static
final
String
S_And
=
"并且"
;
public
static
final
String
S_Condition
=
"条件间的关系"
;
public
static
final
String
S_CorpAcctCoding
=
"科目代码"
;
public
static
final
String
S_CorpAcctName
=
"科目名称"
;
public
static
final
String
S_Period
=
"会计期间"
;
public
static
final
String
S_VoucherType
=
"凭证类型"
;
public
static
final
String
S_VoucherVID
=
"凭证编号"
;
public
static
final
String
S_VoucherSummary
=
"摘要关键字"
;
public
static
final
String
S_CustomerCode
=
"往来核算代码"
;
public
static
final
String
S_CustomerName
=
"往来核算名称"
;
public
static
final
String
S_Date
=
"凭证日期"
;
public
static
final
String
S_Debit
=
"借方金额"
;
public
static
final
String
S_Credit
=
"贷方金额"
;
public
static
final
String
S_Source
=
"凭证来源"
;
public
static
final
String
S_AllJe
=
"显示全部凭证"
;
public
static
final
String
S_DAcctCode
=
"借方科目代码"
;
public
static
final
String
S_CAcctCode
=
"贷方科目代码"
;
public
static
final
String
S_VSummary
=
"摘要包含"
;
public
static
final
String
S_TaxType
=
"税种"
;
public
static
final
String
S_NegativeNum
=
"是否包含借方红字或贷方红字"
;
}
atms-api/src/main/java/pwc/taxtech/atms/constant/enums/VoucherLevelEnum.java
0 → 100644
View file @
e1380145
package
pwc
.
taxtech
.
atms
.
constant
.
enums
;
public
enum
VoucherLevelEnum
{
FirstSort
(
1
,
"运算字符查询"
),
SecondSort
(
2
,
"like字段查询"
),
ThirdSort
(
3
,
"IsNull查询"
);
private
int
code
;
private
String
description
;
VoucherLevelEnum
(
int
code
,
String
description
)
{
this
.
code
=
code
;
this
.
description
=
description
;
}
public
int
getCode
()
{
return
code
;
}
public
String
getDescription
()
{
return
description
;
}
}
atms-api/src/main/java/pwc/taxtech/atms/dto/vatdto/VoucherTmplDto.java
0 → 100644
View file @
e1380145
package
pwc
.
taxtech
.
atms
.
dto
.
vatdto
;
import
pwc.taxtech.atms.constant.enums.VoucherSearchEnum
;
import
java.util.List
;
public
class
VoucherTmplDto
{
private
String
columnName
;
private
String
columnText
;
private
String
lkh
;
private
VoucherSearchEnum
logic
;
private
String
relation
;
private
String
rkh
;
private
int
row
;
private
int
sort
;
private
String
sql
;
private
List
<
String
>
sqlList
;
private
int
tmplCode
;
private
int
tmplId
;
private
String
tmplName
;
private
int
type
;
private
String
value
;
public
String
getColumnName
()
{
return
columnName
;
}
public
void
setColumnName
(
String
columnName
)
{
this
.
columnName
=
columnName
;
}
public
String
getColumnText
()
{
return
columnText
;
}
public
void
setColumnText
(
String
columnText
)
{
this
.
columnText
=
columnText
;
}
public
String
getLkh
()
{
return
lkh
;
}
public
void
setLkh
(
String
lkh
)
{
this
.
lkh
=
lkh
;
}
public
VoucherSearchEnum
getLogic
()
{
return
logic
;
}
public
void
setLogic
(
VoucherSearchEnum
logic
)
{
this
.
logic
=
logic
;
}
public
String
getRelation
()
{
return
relation
;
}
public
void
setRelation
(
String
relation
)
{
this
.
relation
=
relation
;
}
public
String
getRkh
()
{
return
rkh
;
}
public
void
setRkh
(
String
rkh
)
{
this
.
rkh
=
rkh
;
}
public
int
getRow
()
{
return
row
;
}
public
void
setRow
(
int
row
)
{
this
.
row
=
row
;
}
public
int
getSort
()
{
return
sort
;
}
public
void
setSort
(
int
sort
)
{
this
.
sort
=
sort
;
}
public
String
getSql
()
{
return
sql
;
}
public
void
setSql
(
String
sql
)
{
this
.
sql
=
sql
;
}
public
List
<
String
>
getSqlList
()
{
return
sqlList
;
}
public
void
setSqlList
(
List
<
String
>
sqlList
)
{
this
.
sqlList
=
sqlList
;
}
public
int
getTmplCode
()
{
return
tmplCode
;
}
public
void
setTmplCode
(
int
tmplCode
)
{
this
.
tmplCode
=
tmplCode
;
}
public
int
getTmplId
()
{
return
tmplId
;
}
public
void
setTmplId
(
int
tmplId
)
{
this
.
tmplId
=
tmplId
;
}
public
String
getTmplName
()
{
return
tmplName
;
}
public
void
setTmplName
(
String
tmplName
)
{
this
.
tmplName
=
tmplName
;
}
public
int
getType
()
{
return
type
;
}
public
void
setType
(
int
type
)
{
this
.
type
=
type
;
}
public
String
getValue
()
{
return
value
;
}
public
void
setValue
(
String
value
)
{
this
.
value
=
value
;
}
}
atms-api/src/main/java/pwc/taxtech/atms/service/impl/DataSourcePoolService.java
View file @
e1380145
...
...
@@ -13,6 +13,7 @@ import org.springframework.beans.factory.annotation.Qualifier;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.core.io.support.PathMatchingResourcePatternResolver
;
import
org.springframework.jdbc.core.JdbcTemplate
;
import
org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource
;
import
org.springframework.stereotype.Service
;
import
pwc.taxtech.atms.common.datasource.DataSourceConfig
;
...
...
@@ -95,4 +96,9 @@ public class DataSourcePoolService extends AbstractRoutingDataSource {
return
new
SqlSessionTemplate
(
sqlSessionFactory
);
}
@Bean
public
JdbcTemplate
dynamicJdbcTemplate
(
@Qualifier
(
"DynamicDataSource"
)
DataSource
dynamicDataSource
)
{
return
new
JdbcTemplate
(
dynamicDataSource
);
}
}
atms-api/src/main/java/pwc/taxtech/atms/vat/service/VoucherService.java
View file @
e1380145
...
...
@@ -16,7 +16,7 @@ public interface VoucherService {
* @param pagingInfo 分页信息
* @return 分录信息
*/
OperationResultDto
<
Object
>
V
oucherSelectAdvancedByEntry
(
List
<
QueryConditionDto
>
listQueryCondition
,
VoucherSearchEnum
mainRelation
,
boolean
allJe
,
PagingDto
pagingInfo
);
OperationResultDto
<
Object
>
v
oucherSelectAdvancedByEntry
(
List
<
QueryConditionDto
>
listQueryCondition
,
VoucherSearchEnum
mainRelation
,
boolean
allJe
,
PagingDto
pagingInfo
);
/**
* 根据满足查询条件返回总数
...
...
@@ -26,5 +26,5 @@ public interface VoucherService {
* @param allJe 显示全部凭证
* @return 满足条件的总条数
*/
OperationResultDto
<
Object
>
VoucherSelectAdvancedCount
(
List
<
QueryConditionDto
>
listQueryCondition
,
VoucherSearchEnum
mainRelation
,
boolean
isEntryShow
,
boolean
allJe
)
;
OperationResultDto
<
Object
>
voucherSelectAdvancedCount
(
List
<
QueryConditionDto
>
listQueryCondition
,
VoucherSearchEnum
mainRelation
,
boolean
isEntryShow
,
boolean
allJe
)
throws
Exception
;
}
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/VoucherServiceImpl.java
View file @
e1380145
This diff is collapsed.
Click to expand it.
atms-api/src/main/resources/applicationContext-datasource.xml
View file @
e1380145
...
...
@@ -11,39 +11,39 @@
<!-- DruidDataSource数据源配置) -->
<!-- See: https://github.com/alibaba/druid/wiki/%E9%85%8D%E7%BD%AE_DruidDataSource%E5%8F%82%E8%80%83%E9%85%8D%E7%BD%AE -->
<bean
id=
"dataSource"
class=
"com.alibaba.druid.pool.DruidDataSource"
init-method=
"init"
destroy-method=
"close"
>
<!-- 基本属性 url、user、password -->
<property
name=
"url"
value=
"${jdbc_url}"
/>
<property
name=
"username"
value=
"${jdbc_user}"
/>
<property
name=
"password"
value=
"${jdbc_password}"
/>
init-method=
"init"
destroy-method=
"close"
>
<!-- 基本属性 url、user、password -->
<property
name=
"url"
value=
"${jdbc_url}"
/>
<property
name=
"username"
value=
"${jdbc_user}"
/>
<property
name=
"password"
value=
"${jdbc_password}"
/>
<!-- 配置初始化大小、最小、最大 -->
<property
name=
"initialSize"
value=
"${atms.config.druid.initialSize:0}"
/>
<property
name=
"minIdle"
value=
"${atms.config.druid.minIdle:1}"
/>
<property
name=
"maxActive"
value=
"${atms.config.druid.maxActive:20}"
/>
<!-- 配置初始化大小、最小、最大 -->
<property
name=
"initialSize"
value=
"${atms.config.druid.initialSize:0}"
/>
<property
name=
"minIdle"
value=
"${atms.config.druid.minIdle:1}"
/>
<property
name=
"maxActive"
value=
"${atms.config.druid.maxActive:20}"
/>
<!-- 配置获取连接等待超时的时间 -->
<property
name=
"maxWait"
value=
"${atms.config.druid.maxWait:60000}"
/>
<!-- 配置获取连接等待超时的时间 -->
<property
name=
"maxWait"
value=
"${atms.config.druid.maxWait:60000}"
/>
<!-- 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒 -->
<property
name=
"timeBetweenEvictionRunsMillis"
value=
"${atms.config.druid.timeBetweenEvictionRunsMillis:60000}"
/>
<!-- 配置间隔多久才进行一次检测,检测需要关闭的空闲连接,单位是毫秒 -->
<property
name=
"timeBetweenEvictionRunsMillis"
value=
"${atms.config.druid.timeBetweenEvictionRunsMillis:60000}"
/>
<!-- 配置一个连接在池中最小生存的时间,单位是毫秒 -->
<property
name=
"minEvictableIdleTimeMillis"
value=
"${atms.config.druid.minEvictableIdleTimeMillis:300000}"
/>
<!-- 配置一个连接在池中最小生存的时间,单位是毫秒 -->
<property
name=
"minEvictableIdleTimeMillis"
value=
"${atms.config.druid.minEvictableIdleTimeMillis:300000}"
/>
<property
name=
"validationQuery"
value=
"${jdbc_validationQuery:SELECT 'x'"
/>
<property
name=
"testWhileIdle"
value=
"true"
/>
<property
name=
"testOnBorrow"
value=
"false"
/>
<property
name=
"testOnReturn"
value=
"false"
/>
<property
name=
"validationQuery"
value=
"${jdbc_validationQuery:SELECT 'x'"
/>
<property
name=
"testWhileIdle"
value=
"true"
/>
<property
name=
"testOnBorrow"
value=
"false"
/>
<property
name=
"testOnReturn"
value=
"false"
/>
<!-- 打开PSCache,并且指定每个连接上PSCache的大小 -->
<property
name=
"poolPreparedStatements"
value=
"true"
/>
<property
name=
"maxPoolPreparedStatementPerConnectionSize"
value=
"20"
/>
<!-- 打开PSCache,并且指定每个连接上PSCache的大小 -->
<property
name=
"poolPreparedStatements"
value=
"true"
/>
<property
name=
"maxPoolPreparedStatementPerConnectionSize"
value=
"20"
/>
<!-- 配置监控统计拦截的filters -->
<property
name=
"filters"
value=
"stat"
/>
</bean>
<!-- 配置监控统计拦截的filters -->
<property
name=
"filters"
value=
"stat"
/>
</bean>
<bean
id=
"jdbcTemplate"
class=
"org.springframework.jdbc.core.JdbcTemplate"
>
<property
name=
"dataSource"
ref=
"dataSource"
/>
...
...
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