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
64ec7088
Commit
64ec7088
authored
Mar 13, 2019
by
eddie.woo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
modify
parent
81d221b7
Hide whitespace changes
Inline
Side-by-side
Showing
25 changed files
with
1239 additions
and
15 deletions
+1239
-15
CommonUtils.java
...pi/src/main/java/pwc/taxtech/atms/common/CommonUtils.java
+3
-1
Constant.java
...api/src/main/java/pwc/taxtech/atms/constant/Constant.java
+2
-0
RevenueConfController.java
...va/pwc/taxtech/atms/controller/RevenueConfController.java
+6
-0
RevenueConfMappingController.java
...taxtech/atms/controller/RevenueConfMappingController.java
+51
-0
RevTypeAddDto.java
...n/java/pwc/taxtech/atms/dto/revenuconf/RevTypeAddDto.java
+17
-0
RevenueConfResult.java
...va/pwc/taxtech/atms/dto/revenuconf/RevenueConfResult.java
+4
-0
RevenueTypeResult.java
...va/pwc/taxtech/atms/dto/revenuconf/RevenueTypeResult.java
+10
-0
OrganizationServiceImpl.java
...wc/taxtech/atms/service/impl/OrganizationServiceImpl.java
+10
-0
RevenueConfService.java
...ava/pwc/taxtech/atms/service/impl/RevenueConfService.java
+8
-1
RevenueTypeMappingService.java
.../taxtech/atms/service/impl/RevenueTypeMappingService.java
+138
-0
vatGeneratorConfig.xml
atms-dao/etc/generator-mysql/vatGeneratorConfig.xml
+1
-0
OrganizationMapper.java
...rc/main/java/pwc/taxtech/atms/dao/OrganizationMapper.java
+8
-0
OrgCodeIdDto.java
...-dao/src/main/java/pwc/taxtech/atms/dpo/OrgCodeIdDto.java
+22
-0
RevenueTypeMappingMapper.java
...va/pwc/taxtech/atms/vat/dao/RevenueTypeMappingMapper.java
+3
-0
RevenueTypeMapping.java
.../java/pwc/taxtech/atms/vat/entity/RevenueTypeMapping.java
+36
-0
RevenueTypeMappingExample.java
...wc/taxtech/atms/vat/entity/RevenueTypeMappingExample.java
+60
-0
RevenueTypeMappingMapper.xml
...ces/pwc/taxtech/atms/vat/dao/RevenueTypeMappingMapper.xml
+59
-7
module-part2.js
atms-web/src/main/webapp/Scripts/module-part2.js
+18
-0
vat.json
atms-web/src/main/webapp/app-resources/i18n/zh-CN/vat.json
+6
-0
vat-revenue-conf-mapping.ctrl.js
...vat-revenue-conf-mapping/vat-revenue-conf-mapping.ctrl.js
+288
-0
vat-revenue-conf-mapping.html
...rt/vat-revenue-conf-mapping/vat-revenue-conf-mapping.html
+99
-0
vat-revenue-conf-mapping.js
...port/vat-revenue-conf-mapping/vat-revenue-conf-mapping.js
+20
-0
vat-revenue-conf-mapping.less
...rt/vat-revenue-conf-mapping/vat-revenue-conf-mapping.less
+344
-0
vat-revenue-config.ctrl.js
.../dataImport/vat-revenue-config/vat-revenue-config.ctrl.js
+25
-5
vat-revenue-config.html
...app/dataImport/vat-revenue-config/vat-revenue-config.html
+1
-1
No files found.
atms-api/src/main/java/pwc/taxtech/atms/common/CommonUtils.java
View file @
64ec7088
...
...
@@ -12,7 +12,9 @@ import pwc.taxtech.atms.dpo.EnterpriseAccountSetOrgDto;
public
class
CommonUtils
{
public
static
final
int
BATCH_NUM
=
500
;
public
static
final
int
BATCH_NUM_1000
=
1000
;
public
static
final
int
BATCH_NUM_2000
=
2000
;
public
static
String
getUUID
()
{
return
UUID
.
randomUUID
().
toString
().
toUpperCase
();
}
...
...
atms-api/src/main/java/pwc/taxtech/atms/constant/Constant.java
View file @
64ec7088
...
...
@@ -128,4 +128,5 @@ public final class Constant {
public
static
String
DECIMAL_FORMAT
=
"#,##0.00"
;
public
static
String
ZERO_STR
=
"0"
;
public
static
final
String
DEFAULT_END_DATE
=
"9999-12"
;
}
\ No newline at end of file
atms-api/src/main/java/pwc/taxtech/atms/controller/RevenueConfController.java
View file @
64ec7088
...
...
@@ -43,4 +43,10 @@ public class RevenueConfController extends BaseController {
revenueConfService
.
updateConfig
(
config
);
return
ApiResultDto
.
success
();
}
@PostMapping
(
"del"
)
public
ApiResultDto
delConf
(
@RequestBody
List
<
Long
>
idList
)
{
revenueConfService
.
delConfig
(
idList
);
return
ApiResultDto
.
success
();
}
}
atms-api/src/main/java/pwc/taxtech/atms/controller/RevenueConfMappingController.java
0 → 100644
View file @
64ec7088
package
pwc
.
taxtech
.
atms
.
controller
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.multipart.MultipartFile
;
import
pwc.taxtech.atms.dto.ApiResultDto
;
import
pwc.taxtech.atms.dto.input.CamelPagingResultDto
;
import
pwc.taxtech.atms.dto.revenuconf.RevTypeAddDto
;
import
pwc.taxtech.atms.dto.revenuconf.RevenueConfParam
;
import
pwc.taxtech.atms.dto.revenuconf.RevenueTypeResult
;
import
pwc.taxtech.atms.service.impl.RevenueTypeMappingService
;
import
pwc.taxtech.atms.vat.entity.RevenueTypeMapping
;
import
javax.annotation.Resource
;
import
java.util.List
;
@RestController
@RequestMapping
(
value
=
"api/v1/revenueConfMapping"
)
public
class
RevenueConfMappingController
extends
BaseController
{
@Resource
private
RevenueTypeMappingService
mappingService
;
@PostMapping
(
"queryPage"
)
public
CamelPagingResultDto
<
RevenueTypeResult
>
queryPage
(
@RequestBody
RevenueConfParam
param
)
{
return
new
CamelPagingResultDto
<>(
mappingService
.
queryPage
(
param
));
}
@PostMapping
(
"add"
)
public
ApiResultDto
addConf
(
@RequestBody
RevTypeAddDto
addDto
)
{
mappingService
.
addConfig
(
addDto
);
return
ApiResultDto
.
success
();
}
@PostMapping
(
"update"
)
public
ApiResultDto
updateConf
(
@RequestBody
RevenueTypeMapping
mapping
)
{
mappingService
.
updateConfig
(
mapping
);
return
ApiResultDto
.
success
();
}
@PostMapping
(
"del"
)
public
ApiResultDto
delConf
(
@RequestBody
List
<
Long
>
idList
)
{
mappingService
.
delConfig
(
idList
);
return
ApiResultDto
.
success
();
}
@PostMapping
(
"upload"
)
public
ApiResultDto
upload
(
@RequestParam
MultipartFile
file
,
@RequestParam
Integer
type
)
throws
Exception
{
mappingService
.
upload
(
file
,
type
);
return
ApiResultDto
.
success
();
}
}
atms-api/src/main/java/pwc/taxtech/atms/dto/revenuconf/RevTypeAddDto.java
0 → 100644
View file @
64ec7088
package
pwc
.
taxtech
.
atms
.
dto
.
revenuconf
;
import
pwc.taxtech.atms.vat.entity.RevenueTypeMapping
;
import
java.util.List
;
public
class
RevTypeAddDto
extends
RevenueTypeMapping
{
private
List
<
String
>
orgList
;
public
List
<
String
>
getOrgList
()
{
return
this
.
orgList
;
}
public
void
setOrgList
(
List
<
String
>
orgList
)
{
this
.
orgList
=
orgList
;
}
}
atms-api/src/main/java/pwc/taxtech/atms/dto/revenuconf/RevenueConfResult.java
View file @
64ec7088
...
...
@@ -23,4 +23,8 @@ public class RevenueConfResult extends RevenueConfig {
public
String
getStatusStr
()
{
return
RevenueConfEnum
.
Status
.
MAPPING
.
get
(
this
.
getStatus
());
}
public
String
getIdStr
()
{
return
this
.
getId
().
toString
();
}
}
atms-api/src/main/java/pwc/taxtech/atms/dto/revenuconf/RevenueTypeResult.java
0 → 100644
View file @
64ec7088
package
pwc
.
taxtech
.
atms
.
dto
.
revenuconf
;
import
pwc.taxtech.atms.constant.enums.RevenueConfEnum
;
import
pwc.taxtech.atms.vat.entity.RevenueTypeMapping
;
public
class
RevenueTypeResult
extends
RevenueTypeMapping
{
public
String
getStatusStr
()
{
return
RevenueConfEnum
.
Status
.
MAPPING
.
get
(
this
.
getStatus
());
}
}
atms-api/src/main/java/pwc/taxtech/atms/service/impl/OrganizationServiceImpl.java
View file @
64ec7088
...
...
@@ -3229,4 +3229,14 @@ public class OrganizationServiceImpl extends BaseService{
return
organizationMapper
.
getMyOrgSelectList
(
uid
);
}
}
public
List
<
OrgCodeIdDto
>
getMyOrgCodeList
()
{
String
uid
=
authUserHelper
.
getCurrentUserId
();
User
user
=
userMapper
.
selectByPrimaryKey
(
uid
);
if
(
user
.
getIsSuperAdmin
())
{
return
organizationMapper
.
getAllOrgCodeList
();
}
else
{
return
organizationMapper
.
getMyOrgCodeList
(
uid
);
}
}
}
atms-api/src/main/java/pwc/taxtech/atms/service/impl/RevenueConfService.java
View file @
64ec7088
...
...
@@ -51,8 +51,9 @@ public class RevenueConfService extends BaseService {
RevenueConfigExample
example
=
new
RevenueConfigExample
();
example
.
createCriteria
().
andOrgIdEqualTo
(
param
.
getOrgId
()).
andStartDateLessThanOrEqualTo
(
param
.
getStartDate
()).
andEndDateGreaterThanOrEqualTo
(
param
.
getEndDate
());
return
revenueConfigMapper
.
selectByExample
(
example
).
stream
()
.
map
(
o
->
beanUtil
.
copyProperties
(
o
,
new
RevenueConfResult
())).
collect
(
Collectors
.
toList
());
.
map
(
o
->
beanUtil
.
copyProperties
(
o
,
new
RevenueConfResult
())).
collect
(
Collectors
.
toList
());
}
/**
* 新增配置
*
...
...
@@ -89,6 +90,12 @@ public class RevenueConfService extends BaseService {
revenueConfigMapper
.
updateByPrimaryKeySelective
(
parseEntity
(
config
));
}
public
void
delConfig
(
List
<
Long
>
idList
)
{
if
(!
CollectionUtils
.
isEmpty
(
idList
))
{
idList
.
forEach
(
id
->
revenueConfigMapper
.
deleteByPrimaryKey
(
id
));
}
}
private
RevenueConfig
parseEntity
(
RevenueConfig
config
)
{
if
(
config
.
getAccountType
()
!=
RevenueConfEnum
.
AccountType
.
Account
.
getCode
().
intValue
())
{
config
.
setTbSegment3
(
StringUtils
.
EMPTY
);
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/RevenueTypeMappingService.java
0 → 100644
View file @
64ec7088
package
pwc
.
taxtech
.
atms
.
service
.
impl
;
import
com.github.pagehelper.Page
;
import
com.github.pagehelper.PageHelper
;
import
com.github.pagehelper.PageInfo
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.poi.ss.usermodel.Row
;
import
org.apache.poi.ss.usermodel.Sheet
;
import
org.apache.poi.ss.usermodel.Workbook
;
import
org.apache.poi.ss.usermodel.WorkbookFactory
;
import
org.springframework.stereotype.Service
;
import
org.springframework.web.multipart.MultipartFile
;
import
pwc.taxtech.atms.common.CommonUtils
;
import
pwc.taxtech.atms.dpo.OrgCodeIdDto
;
import
pwc.taxtech.atms.dpo.OrgSelectDto
;
import
pwc.taxtech.atms.dto.revenuconf.RevTypeAddDto
;
import
pwc.taxtech.atms.dto.revenuconf.RevenueConfParam
;
import
pwc.taxtech.atms.dto.revenuconf.RevenueTypeResult
;
import
pwc.taxtech.atms.vat.dao.RevenueTypeMappingMapper
;
import
pwc.taxtech.atms.vat.entity.RevenueTypeMapping
;
import
pwc.taxtech.atms.vat.entity.RevenueTypeMappingExample
;
import
javax.annotation.Resource
;
import
java.io.InputStream
;
import
java.math.BigDecimal
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Optional
;
import
java.util.stream.Collectors
;
import
static
pwc
.
taxtech
.
atms
.
constant
.
Constant
.
DEFAULT_END_DATE
;
@Service
public
class
RevenueTypeMappingService
extends
BaseService
{
@Resource
private
RevenueTypeMappingMapper
typeMappingMapper
;
@Resource
private
OrganizationServiceImpl
organizationService
;
/**
* 分页查询可查看的配置信息
*
* @param param RevenueConfParam
* @return PageInfo
*/
public
PageInfo
<
RevenueTypeResult
>
queryPage
(
RevenueConfParam
param
)
{
List
<
OrgSelectDto
>
orgDtoList
=
organizationService
.
getMyOrgList
();
if
(
CollectionUtils
.
isEmpty
(
orgDtoList
))
{
return
new
PageInfo
<>();
}
Page
page
=
PageHelper
.
startPage
(
param
.
getPageInfo
().
getPageIndex
(),
param
.
getPageInfo
().
getPageSize
());
RevenueTypeMappingExample
example
=
new
RevenueTypeMappingExample
();
example
.
createCriteria
().
andOrgIdIn
(
orgDtoList
.
stream
().
map
(
OrgSelectDto:
:
getId
).
collect
(
Collectors
.
toList
()));
PageInfo
<
RevenueTypeResult
>
pageInfo
=
new
PageInfo
<>(
typeMappingMapper
.
selectByExample
(
example
).
stream
()
.
map
(
o
->
beanUtil
.
copyProperties
(
o
,
new
RevenueTypeResult
())).
collect
(
Collectors
.
toList
()));
pageInfo
.
setTotal
(
page
.
getTotal
());
return
pageInfo
;
}
/**
* 新增配置
*
* @param mapping RevenueTypeMapping
*/
public
void
addConfig
(
RevenueTypeMapping
mapping
)
{
//todo 重复校验
mapping
.
setId
(
idService
.
nextId
());
typeMappingMapper
.
insertSelective
(
mapping
);
}
/**
* 前台批量新增
*
* @param addDto RevTypeAddDto
*/
public
void
addConfig
(
RevTypeAddDto
addDto
)
{
if
(!
CollectionUtils
.
isEmpty
(
addDto
.
getOrgList
()))
{
addDto
.
getOrgList
().
forEach
(
id
->
{
addDto
.
setId
(
idService
.
nextId
());
addDto
.
setOrgId
(
id
);
typeMappingMapper
.
insertSelective
(
addDto
);
});
}
}
/**
* 更新配置
*
* @param mapping RevenueConfig
*/
public
void
updateConfig
(
RevenueTypeMapping
mapping
)
{
//todo 重复校验
typeMappingMapper
.
updateByPrimaryKeySelective
(
mapping
);
}
public
void
delConfig
(
List
<
Long
>
idList
)
{
if
(!
CollectionUtils
.
isEmpty
(
idList
))
{
idList
.
forEach
(
id
->
typeMappingMapper
.
deleteByPrimaryKey
(
id
));
}
}
public
void
upload
(
MultipartFile
file
,
Integer
type
)
throws
Exception
{
InputStream
inputStream
=
file
.
getInputStream
();
Workbook
workbook
=
WorkbookFactory
.
create
(
inputStream
);
Sheet
sheet
=
workbook
.
getSheetAt
(
0
);
List
<
RevenueTypeMapping
>
list
=
new
ArrayList
<>();
List
<
OrgCodeIdDto
>
orgDtoList
=
organizationService
.
getMyOrgCodeList
();
for
(
int
r
=
sheet
.
getFirstRowNum
();
r
<=
sheet
.
getLastRowNum
();
r
++)
{
Row
row
=
sheet
.
getRow
(
r
);
String
orgCode
=
row
.
getCell
(
0
).
getStringCellValue
();
Optional
<
OrgCodeIdDto
>
optional
=
orgDtoList
.
stream
().
filter
(
o
->
StringUtils
.
equals
(
o
.
getCode
(),
orgCode
)).
findFirst
();
if
(!
optional
.
isPresent
())
{
continue
;
}
RevenueTypeMapping
mapping
=
new
RevenueTypeMapping
();
mapping
.
setId
(
idService
.
nextId
());
mapping
.
setOrgId
(
optional
.
get
().
getId
());
mapping
.
setOuName
(
StringUtils
.
defaultString
(
row
.
getCell
(
1
).
getStringCellValue
()));
mapping
.
setContent
(
StringUtils
.
defaultString
(
row
.
getCell
(
2
).
getStringCellValue
()));
mapping
.
setTaxRate
(
new
BigDecimal
(
row
.
getCell
(
3
).
getNumericCellValue
()));
mapping
.
setRevenueTypeName
(
StringUtils
.
defaultString
(
row
.
getCell
(
4
).
getStringCellValue
()));
mapping
.
setStartDate
(
StringUtils
.
defaultString
(
row
.
getCell
(
5
).
getStringCellValue
()));
mapping
.
setEndDate
(
StringUtils
.
defaultString
(
row
.
getCell
(
6
).
getStringCellValue
(),
DEFAULT_END_DATE
));
list
.
add
(
mapping
);
}
if
(
1
==
type
)
{
//todo 覆盖导入 具体覆盖哪些
}
if
(!
CollectionUtils
.
isEmpty
(
list
))
{
List
<
List
<
RevenueTypeMapping
>>
batchList
=
CommonUtils
.
subListWithLen
(
list
,
CommonUtils
.
BATCH_NUM_2000
);
batchList
.
forEach
(
l
->
typeMappingMapper
.
batchInsert
(
l
));
}
}
}
atms-dao/etc/generator-mysql/vatGeneratorConfig.xml
View file @
64ec7088
...
...
@@ -44,6 +44,7 @@
<table
tableName=
"revenue_type_mapping"
domainObjectName=
"RevenueTypeMapping"
>
<property
name=
"useActualColumnNames"
value=
"false"
/>
<property
name=
"ignoreQualifiersAtRuntime"
value=
"true"
/>
<columnOverride
column=
"status"
javaType=
"java.lang.Integer"
jdbcType=
"TINYINT"
/>
</table>
<!-- <table tableName="trial_balance_final" domainObjectName="TrialBalanceFinal">
...
...
atms-dao/src/main/java/pwc/taxtech/atms/dao/OrganizationMapper.java
View file @
64ec7088
...
...
@@ -138,4 +138,11 @@ public interface OrganizationMapper extends MyMapper {
@Select
(
"select id, name from organization;"
)
List
<
OrgSelectDto
>
getAllOrgSelectList
();
@Select
(
"select tb.id,tb.code from user_organization ta left join organization tb on ta.organization_id = tb.id "
+
"where ta.user_id = #{uid}"
)
List
<
OrgCodeIdDto
>
getMyOrgCodeList
(
String
uid
);
@Select
(
"select id, code from organization;"
)
List
<
OrgCodeIdDto
>
getAllOrgCodeList
();
}
\ No newline at end of file
atms-dao/src/main/java/pwc/taxtech/atms/dpo/OrgCodeIdDto.java
0 → 100644
View file @
64ec7088
package
pwc
.
taxtech
.
atms
.
dpo
;
public
class
OrgCodeIdDto
{
private
String
id
;
private
String
code
;
public
String
getId
()
{
return
this
.
id
;
}
public
void
setId
(
String
id
)
{
this
.
id
=
id
;
}
public
String
getCode
()
{
return
this
.
code
;
}
public
void
setCode
(
String
code
)
{
this
.
code
=
code
;
}
}
atms-dao/src/main/java/pwc/taxtech/atms/vat/dao/RevenueTypeMappingMapper.java
View file @
64ec7088
...
...
@@ -105,4 +105,6 @@ public interface RevenueTypeMappingMapper extends MyVatMapper {
* @mbg.generated
*/
int
updateByPrimaryKey
(
RevenueTypeMapping
record
);
int
batchInsert
(
List
<
RevenueTypeMapping
>
list
);
}
\ No newline at end of file
atms-dao/src/main/java/pwc/taxtech/atms/vat/entity/RevenueTypeMapping.java
View file @
64ec7088
...
...
@@ -99,6 +99,17 @@ public class RevenueTypeMapping extends BaseEntity implements Serializable {
*/
private
String
endDate
;
/**
* Database Column Remarks:
* 状态 0:启用 1:停用
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column revenue_type_mapping.status
*
* @mbg.generated
*/
private
Integer
status
;
/**
*
* This field was generated by MyBatis Generator.
...
...
@@ -335,6 +346,30 @@ public class RevenueTypeMapping extends BaseEntity implements Serializable {
this
.
endDate
=
endDate
==
null
?
null
:
endDate
.
trim
();
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column revenue_type_mapping.status
*
* @return the value of revenue_type_mapping.status
*
* @mbg.generated
*/
public
Integer
getStatus
()
{
return
status
;
}
/**
* This method was generated by MyBatis Generator.
* This method sets the value of the database column revenue_type_mapping.status
*
* @param status the value for revenue_type_mapping.status
*
* @mbg.generated
*/
public
void
setStatus
(
Integer
status
)
{
this
.
status
=
status
;
}
/**
* This method was generated by MyBatis Generator.
* This method returns the value of the database column revenue_type_mapping.create_by
...
...
@@ -451,6 +486,7 @@ public class RevenueTypeMapping extends BaseEntity implements Serializable {
sb
.
append
(
", revenueTypeName="
).
append
(
revenueTypeName
);
sb
.
append
(
", startDate="
).
append
(
startDate
);
sb
.
append
(
", endDate="
).
append
(
endDate
);
sb
.
append
(
", status="
).
append
(
status
);
sb
.
append
(
", createBy="
).
append
(
createBy
);
sb
.
append
(
", updateBy="
).
append
(
updateBy
);
sb
.
append
(
", createTime="
).
append
(
createTime
);
...
...
atms-dao/src/main/java/pwc/taxtech/atms/vat/entity/RevenueTypeMappingExample.java
View file @
64ec7088
...
...
@@ -736,6 +736,66 @@ public class RevenueTypeMappingExample {
return
(
Criteria
)
this
;
}
public
Criteria
andStatusIsNull
()
{
addCriterion
(
"`status` is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusIsNotNull
()
{
addCriterion
(
"`status` is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusEqualTo
(
Integer
value
)
{
addCriterion
(
"`status` ="
,
value
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusNotEqualTo
(
Integer
value
)
{
addCriterion
(
"`status` <>"
,
value
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusGreaterThan
(
Integer
value
)
{
addCriterion
(
"`status` >"
,
value
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusGreaterThanOrEqualTo
(
Integer
value
)
{
addCriterion
(
"`status` >="
,
value
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusLessThan
(
Integer
value
)
{
addCriterion
(
"`status` <"
,
value
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusLessThanOrEqualTo
(
Integer
value
)
{
addCriterion
(
"`status` <="
,
value
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusIn
(
List
<
Integer
>
values
)
{
addCriterion
(
"`status` in"
,
values
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusNotIn
(
List
<
Integer
>
values
)
{
addCriterion
(
"`status` not in"
,
values
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusBetween
(
Integer
value1
,
Integer
value2
)
{
addCriterion
(
"`status` between"
,
value1
,
value2
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andStatusNotBetween
(
Integer
value1
,
Integer
value2
)
{
addCriterion
(
"`status` not between"
,
value1
,
value2
,
"status"
);
return
(
Criteria
)
this
;
}
public
Criteria
andCreateByIsNull
()
{
addCriterion
(
"create_by is null"
);
return
(
Criteria
)
this
;
...
...
atms-dao/src/main/resources/pwc/taxtech/atms/vat/dao/RevenueTypeMappingMapper.xml
View file @
64ec7088
...
...
@@ -14,6 +14,7 @@
<result
column=
"revenue_type_name"
jdbcType=
"VARCHAR"
property=
"revenueTypeName"
/>
<result
column=
"start_date"
jdbcType=
"VARCHAR"
property=
"startDate"
/>
<result
column=
"end_date"
jdbcType=
"VARCHAR"
property=
"endDate"
/>
<result
column=
"status"
jdbcType=
"TINYINT"
property=
"status"
/>
<result
column=
"create_by"
jdbcType=
"VARCHAR"
property=
"createBy"
/>
<result
column=
"update_by"
jdbcType=
"VARCHAR"
property=
"updateBy"
/>
<result
column=
"create_time"
jdbcType=
"TIMESTAMP"
property=
"createTime"
/>
...
...
@@ -91,7 +92,7 @@
This element is automatically generated by MyBatis Generator, do not modify.
-->
id, org_id, ou_name, content, tax_rate, revenue_type_name, start_date, end_date,
create_by, update_by, create_time, update_time
`status`,
create_by, update_by, create_time, update_time
</sql>
<select
id=
"selectByExample"
parameterType=
"pwc.taxtech.atms.vat.entity.RevenueTypeMappingExample"
resultMap=
"BaseResultMap"
>
<!--
...
...
@@ -146,14 +147,14 @@
-->
insert into revenue_type_mapping (id, org_id, ou_name,
content, tax_rate, revenue_type_name,
start_date, end_date,
create_by
,
update_by, create_time, update_time
)
start_date, end_date,
`status`
,
create_by, update_by, create_time,
update_time
)
values (#{id,jdbcType=BIGINT}, #{orgId,jdbcType=VARCHAR}, #{ouName,jdbcType=VARCHAR},
#{content,jdbcType=VARCHAR}, #{taxRate,jdbcType=DECIMAL}, #{revenueTypeName,jdbcType=VARCHAR},
#{startDate,jdbcType=VARCHAR}, #{endDate,jdbcType=VARCHAR}, #{
createBy,jdbcType=VARCHAR
},
#{
updateBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}
)
#{startDate,jdbcType=VARCHAR}, #{endDate,jdbcType=VARCHAR}, #{
status,jdbcType=TINYINT
},
#{
createBy,jdbcType=VARCHAR}, #{updateBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{updateTime,jdbcType=TIMESTAMP}
)
</insert>
<insert
id=
"insertSelective"
parameterType=
"pwc.taxtech.atms.vat.entity.RevenueTypeMapping"
>
<!--
...
...
@@ -186,6 +187,9 @@
<if
test=
"endDate != null"
>
end_date,
</if>
<if
test=
"status != null"
>
`status`,
</if>
<if
test=
"createBy != null"
>
create_by,
</if>
...
...
@@ -224,6 +228,9 @@
<if
test=
"endDate != null"
>
#{endDate,jdbcType=VARCHAR},
</if>
<if
test=
"status != null"
>
#{status,jdbcType=TINYINT},
</if>
<if
test=
"createBy != null"
>
#{createBy,jdbcType=VARCHAR},
</if>
...
...
@@ -279,6 +286,9 @@
<if
test=
"record.endDate != null"
>
end_date = #{record.endDate,jdbcType=VARCHAR},
</if>
<if
test=
"record.status != null"
>
`status` = #{record.status,jdbcType=TINYINT},
</if>
<if
test=
"record.createBy != null"
>
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
...
...
@@ -310,6 +320,7 @@
revenue_type_name = #{record.revenueTypeName,jdbcType=VARCHAR},
start_date = #{record.startDate,jdbcType=VARCHAR},
end_date = #{record.endDate,jdbcType=VARCHAR},
`status` = #{record.status,jdbcType=TINYINT},
create_by = #{record.createBy,jdbcType=VARCHAR},
update_by = #{record.updateBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
...
...
@@ -346,6 +357,9 @@
<if
test=
"endDate != null"
>
end_date = #{endDate,jdbcType=VARCHAR},
</if>
<if
test=
"status != null"
>
`status` = #{status,jdbcType=TINYINT},
</if>
<if
test=
"createBy != null"
>
create_by = #{createBy,jdbcType=VARCHAR},
</if>
...
...
@@ -374,6 +388,7 @@
revenue_type_name = #{revenueTypeName,jdbcType=VARCHAR},
start_date = #{startDate,jdbcType=VARCHAR},
end_date = #{endDate,jdbcType=VARCHAR},
`status` = #{status,jdbcType=TINYINT},
create_by = #{createBy,jdbcType=VARCHAR},
update_by = #{updateBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
...
...
@@ -398,4 +413,40 @@
order by ${orderByClause}
</if>
</select>
<insert
id=
"batchInsert"
parameterType=
"pwc.taxtech.atms.vat.entity.RevenueTypeMapping"
>
insert into revenue_type_mapping (id, org_id, ou_name,
content, tax_rate, revenue_type_name,
start_date, end_date, `status`
<if
test=
"createBy != null"
>
,create_by
</if>
<if
test=
"updateBy != null"
>
,update_by
</if>
<if
test=
"createTime != null"
>
,create_time
</if>
<if
test=
"updateTime != null"
>
,update_time
</if>
) values
<foreach
collection=
"list"
item=
"item"
index=
"index"
separator=
","
>
(#{id,jdbcType=BIGINT}, #{orgId,jdbcType=VARCHAR}, #{ouName,jdbcType=VARCHAR},
#{content,jdbcType=VARCHAR}, #{taxRate,jdbcType=DECIMAL}, #{revenueTypeName,jdbcType=VARCHAR},
#{startDate,jdbcType=VARCHAR}, #{endDate,jdbcType=VARCHAR}, #{status,jdbcType=TINYINT}
<if
test=
"createBy != null"
>
,create_by = #{createBy,jdbcType=VARCHAR}
</if>
<if
test=
"updateBy != null"
>
,update_by = #{updateBy,jdbcType=VARCHAR}
</if>
<if
test=
"createTime != null"
>
,create_time = #{createTime,jdbcType=TIMESTAMP}
</if>
<if
test=
"updateTime != null"
>
,update_time = #{updateTime,jdbcType=TIMESTAMP}
</if>
)
</foreach>
</insert>
</mapper>
\ No newline at end of file
atms-web/src/main/webapp/Scripts/module-part2.js
View file @
64ec7088
...
...
@@ -1324,6 +1324,24 @@ var dataImpModule = angular.module('app.dataImp', ['ui.grid', 'ui.router','ui.gr
sticky
:
true
});
$stateProvider
.
state
({
name
:
'dataImportConfigRevenueTypeMapping'
,
url
:
"/dataImportConfig/revenueTypeMapping"
,
dsr
:
true
,
views
:
{
'importContent'
:
{
controller
:
[
'$scope'
,
'$state'
,
'appTranslation'
,
function
(
$scope
,
$state
,
appTranslation
)
{
$scope
.
state
=
$state
;
appTranslation
.
load
([
appTranslation
.
appPart
]);
}],
template
:
'<vat-revenue-conf-mapping></vat-revenue-conf-mapping>'
}
},
resolve
:
scriptDependencyProvider
.
createDependenciesMap
(
scriptDependencyProvider
.
dataImp
),
sticky
:
true
});
$stateProvider
.
state
({
name
:
'recordImportLog'
,
url
:
"/dataImportLog/dataImport"
,
...
...
atms-web/src/main/webapp/app-resources/i18n/zh-CN/vat.json
View file @
64ec7088
...
...
@@ -2106,6 +2106,7 @@
"RevenueNoOrgData"
:
"没有机构权限"
,
"RevenueGetOrgError"
:
"获取机构信息失败"
,
"RevenueAddSuccess"
:
"添加成功"
,
"RevenueDelSuccess"
:
"删除成功"
,
"RevenueUpdateSuccess"
:
"更新成功"
,
"dataValidate"
:
"数据校验"
,
"RevDetail"
:
"收入明细"
,
...
...
@@ -2133,5 +2134,9 @@
"RevDetailType"
:
"收入类型"
,
"RevDetailCategory"
:
"收入类别"
,
"RevDetailTaxOn"
:
"计税方法"
,
"RevCMTitle"
:
"开票记录与收入类型映射配置"
,
"RevCMApplyBU"
:
"申请部门"
,
"RevCMInvoiceCTX"
:
"开票内容"
,
"~MustBeEndOneApp"
:
"我必须是最后一个!"
}
\ No newline at end of file
atms-web/src/main/webapp/app/dataImport/vat-revenue-conf-mapping/vat-revenue-conf-mapping.ctrl.js
0 → 100644
View file @
64ec7088
vatModule
.
controller
(
'VatRevenueConfMappingController'
,
[
'$scope'
,
'$log'
,
'$translate'
,
'$timeout'
,
'SweetAlert'
,
'$q'
,
'$interval'
,
'dxDataGridService'
,
'$http'
,
'apiConfig'
,
'Upload'
,
'apiInterceptor'
,
function
(
$scope
,
$log
,
$translate
,
$timeout
,
SweetAlert
,
$q
,
$interval
,
dxDataGridService
,
$http
,
apiConfig
,
Upload
,
apiInterceptor
)
{
'use strict'
;
//表格配置
$scope
.
revenueGridOptions
=
$
.
extend
(
true
,
{},
dxDataGridService
.
BASIC_GRID_OPTIONS
,
{
columns
:
[
{
dataField
:
'id'
,
caption
:
''
,
visible
:
false
},
{
dataField
:
'orgId'
,
caption
:
$translate
.
instant
(
'RevenueColOrg'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
minWidth
:
'300px'
,
calculateCellValue
:
function
(
data
)
{
return
_
.
find
(
$scope
.
selectOrgList
,
function
(
o
)
{
return
o
.
id
===
data
.
orgId
;
}).
name
;
}},
{
dataField
:
'ouName'
,
caption
:
$translate
.
instant
(
'RevCMApplyBU'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
width
:
'100px'
},
{
dataField
:
'content'
,
caption
:
$translate
.
instant
(
'RevCMInvoiceCTX'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
width
:
'120px'
},
{
dataField
:
'taxRate'
,
caption
:
$translate
.
instant
(
'RevenueColTaxRate'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
width
:
'50px'
,
calculateCellValue
:
function
(
data
)
{
return
(
data
.
taxRate
*
100
)
+
'%'
;
}},
{
dataField
:
'revenueTypeName'
,
caption
:
$translate
.
instant
(
'RevSearchType'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
minWidth
:
'300px'
},
{
dataField
:
'startDate'
,
caption
:
$translate
.
instant
(
'RevenueColEnable'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
width
:
'120px'
},
{
dataField
:
'endDate'
,
caption
:
$translate
.
instant
(
'RevenueColDisable'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
width
:
'120px'
},
{
dataField
:
'statusStr'
,
caption
:
$translate
.
instant
(
'RevenueColStatus'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
width
:
'50px'
},
{
dataField
:
''
,
caption
:
$translate
.
instant
(
'RevenueColEdit'
),
fixed
:
true
,
width
:
'80px'
,
alignment
:
'center'
,
cellTemplate
:
function
(
container
,
options
)
{
try
{
$
(
'<i class="fa fa-pencil-square-o" style="cursor: pointer"></i> '
)
.
on
(
'click'
,
function
()
{
$scope
.
editConfig
(
options
.
data
);
}).
appendTo
(
container
);
$
(
'<i class="fa fa-trash" style="cursor: pointer;margin-left: 5px;"></i>'
)
.
on
(
'click'
,
function
()
{
$scope
.
editConfig
(
options
.
data
);
}).
appendTo
(
container
);
}
catch
(
e
)
{
$log
.
error
(
e
);
}
}},
],
bindingOptions
:
{
dataSource
:
'pageConfDataSource'
,
},
selection
:
{
mode
:
'multiple'
,
showCheckBoxesMode
:
'always'
,
allowSelectAll
:
true
}
});
//刷新页面
$scope
.
refreshConfigGrid
=
function
()
{
$http
.
post
(
'/revenueConfMapping/queryPage'
,{
pageInfo
:
$scope
.
pagingOptions
},
apiConfig
.
createVat
())
.
success
(
function
(
res
)
{
if
(
res
&&
res
.
list
)
{
$scope
.
pageConfDataSource
=
res
.
list
;
$scope
.
pagingOptions
.
totalItems
=
res
.
pageInfo
.
totalCount
;
}
else
{
SweetAlert
.
error
(
$translate
.
instant
(
'SystemError'
));
}
})
};
//添加配置
$scope
.
addConfig
=
function
()
{
$scope
.
isEdit
=
false
;
$scope
.
isOrgReadOnly
=
false
;
$
(
$scope
.
revenueConfAddDiv
).
modal
(
'show'
);
};
//删除配置
$scope
.
delConfig
=
function
()
{
SweetAlert
.
info
(
'del'
);
};
//添加配置
$scope
.
saveConfig
=
function
()
{
if
(
$scope
.
isEdit
)
{
$http
.
post
(
'/revenueConfMapping/update'
,
$scope
.
formParam
,
apiConfig
.
createVat
())
.
success
(
function
(
res
)
{
if
(
res
&&
0
===
res
.
code
)
{
SweetAlert
.
success
(
$translate
.
instant
(
'RevenueAddSuccess'
));
$scope
.
refreshConfigGrid
();
$
(
$scope
.
revenueConfAddDiv
).
modal
(
'hide'
);
}
else
{
SweetAlert
.
error
(
$translate
.
instant
(
'SystemError'
));
}
})
}
else
{
$http
.
post
(
'/revenueConfMapping/add'
,
$scope
.
formParam
,
apiConfig
.
createVat
())
.
success
(
function
(
res
)
{
if
(
res
&&
0
===
res
.
code
)
{
SweetAlert
.
success
(
$translate
.
instant
(
'RevenueAddSuccess'
));
$scope
.
refreshConfigGrid
();
$
(
$scope
.
revenueConfAddDiv
).
modal
(
'hide'
);
}
else
{
SweetAlert
.
error
(
$translate
.
instant
(
'SystemError'
));
}
})
}
};
//关闭配置框
$scope
.
cancelModal
=
function
()
{
$scope
.
formParam
=
{
startDate
:
null
,
endDate
:
null
,
};
$
(
'#configForm'
)[
0
].
reset
();
};
//编辑
$scope
.
editConfig
=
function
(
data
)
{
$scope
.
isEdit
=
true
;
$scope
.
isOrgReadOnly
=
true
;
$scope
.
formParam
=
data
;
$scope
.
formParam
.
orgList
=
[
data
.
orgId
];
$
(
$scope
.
revenueConfAddDiv
).
modal
(
'show'
);
};
//获取机构列表
function
getMyOrgList
()
{
$http
.
get
(
'/org/getMyOrgList'
,
apiConfig
.
createVat
())
.
success
(
function
(
res
)
{
if
(
res
&&
0
===
res
.
code
)
{
$scope
.
selectOrgList
=
res
.
data
;
}
else
{
SweetAlert
.
error
(
$translate
.
instant
(
'RevenueGetOrgError'
));
}
})
}
$scope
.
upload
=
function
()
{
if
(
!
$scope
.
uploadFile
||
!
$scope
.
uploadFile
.
file
.
name
)
{
SweetAlert
.
warning
(
$translate
.
instant
(
'SelectUploadFileRequired'
));
return
;
}
var
deferred
=
$q
.
defer
();
Upload
.
upload
({
url
:
'/revenueConfMapping/upload'
,
data
:
{
type
:
$scope
.
uploadType
,
},
file
:
$scope
.
uploadFile
.
file
,
// resumeChunkSize: resumable ? $scope.chunkSize : null,
headers
:
{
'Access-Control-Allow-Origin'
:
'*'
,
Authorization
:
apiInterceptor
.
tokenType
+
' '
+
apiInterceptor
.
apiToken
(),
__RequestVerificationToken
:
token
,
withCredentials
:
true
},
__RequestVerificationToken
:
token
,
withCredentials
:
true
}).
then
(
function
(
res
)
{
$
(
'#busy-indicator-container'
).
hide
();
deferred
.
resolve
();
if
(
res
&&
0
===
res
.
code
)
{
}
else
{
SweetAlert
.
error
(
$translate
.
instant
(
'SystemError'
));
}
},
function
(
resp
)
{
deferred
.
resolve
();
if
(
resp
.
statusText
===
'HttpRequestValidationException'
)
{
SweetAlert
.
warning
(
$translate
.
instant
(
'HttpRequestValidationException'
));
}
else
{
SweetAlert
.
warning
(
$translate
.
instant
(
'SaveFail'
));
}
console
.
log
(
'Error status: '
+
resp
.
status
);
},
function
(
evt
)
{
deferred
.
resolve
();
var
progressPercentage
=
parseInt
(
100.0
*
evt
.
loaded
/
evt
.
total
);
$log
.
debug
(
'progress: '
+
progressPercentage
+
'% '
+
evt
.
config
.
data
.
file
.
name
);
});
};
(
function
initialize
()
{
//分页的设置
$scope
.
pagingOptions
=
{
pageIndex
:
1
,
//当前页码
totalItems
:
0
,
//总数据
pageSize
:
20
,
//每页多少条数据
};
$scope
.
formParam
=
{
};
$scope
.
isOrgReadOnly
=
false
;
//机构下拉设置
$scope
.
selectOrgOptions
=
{
displayExpr
:
'name'
,
valueExpr
:
'id'
,
width
:
'95%'
,
bindingOptions
:
{
value
:
'formParam.orgList'
,
dataSource
:
'selectOrgList'
,
readOnly
:
'isOrgReadOnly'
},
height
:
'30px'
,
placeholder
:
''
,
showClearButton
:
true
,
searchEnabled
:
true
,
noDataText
:
$translate
.
instant
(
'RevenueNoOrgData'
),
showSelectionControls
:
true
};
//税率下拉框
$scope
.
selectTaxRateOptions
=
{
displayExpr
:
'key'
,
valueExpr
:
'val'
,
bindingOptions
:
{
value
:
'formParam.taxRate'
},
dataSource
:
[
{
'key'
:
'0%'
,
'val'
:
0
},
{
'key'
:
'1.5%'
,
'val'
:
0.015
},
{
'key'
:
'3%'
,
'val'
:
0.03
},
{
'key'
:
'5%'
,
'val'
:
0.05
},
{
'key'
:
'6%'
,
'val'
:
0.06
},
{
'key'
:
'10%'
,
'val'
:
0.1
},
{
'key'
:
'16%'
,
'val'
:
0.16
},
]
};
$scope
.
selectStatusOptions
=
{
displayExpr
:
'key'
,
valueExpr
:
'val'
,
bindingOptions
:
{
value
:
'formParam.status'
},
dataSource
:
[
{
'key'
:
'启用'
,
'val'
:
0
},
{
'key'
:
'停用'
,
'val'
:
1
},
]
};
$scope
.
dateBoxStart
=
{
width
:
'100%'
,
acceptCustomValue
:
false
,
openOnFieldClick
:
true
,
displayFormat
:
'yyyy-MM'
,
maxZoomLevel
:
"year"
,
dateSerializationFormat
:
'yyyy-MM'
,
bindingOptions
:
{
value
:
'formParam.startDate'
}
};
$scope
.
dateBoxEnd
=
{
width
:
'100%'
,
acceptCustomValue
:
false
,
openOnFieldClick
:
true
,
displayFormat
:
'yyyy-MM'
,
maxZoomLevel
:
"year"
,
dateSerializationFormat
:
'yyyy-MM'
,
bindingOptions
:
{
value
:
'formParam.endDate'
}
};
$scope
.
revenueConfAddDiv
=
".vat-revenue-conf-mapping #revenueTypeAddDiv"
;
function
init
()
{
getMyOrgList
();
$scope
.
refreshConfigGrid
();
}
init
()
})();
}
]);
atms-web/src/main/webapp/app/dataImport/vat-revenue-conf-mapping/vat-revenue-conf-mapping.html
0 → 100644
View file @
64ec7088
<div
class=
"vat-revenue-conf-mapping"
>
<!--标题-->
<div
class=
"nav-wrapper"
>
<div
class=
"nav-header"
translate=
"RevCMTitle"
></div>
</div>
<div
id=
"tab_total"
>
<form
class=
"form-inline"
>
<div
class=
"form-group"
>
<button
type=
"button"
class=
"btn btn-secondary"
ng-click=
"addConfig()"
>
{{'RevenueAddBtn' | translate }}
</button>
<button
type=
"button"
class=
"btn btn-third"
ng-click=
"delConfig()"
>
{{'RevenueDelBtn' | translate }}
</button>
<label
class=
"control-label"
>
文件:
</label>
<input
class=
"form-control"
type=
"text"
name=
"fileName"
ng-model=
"uploadFile.file.name"
readonly
placeholder=
""
/>
<button
type=
"button"
type=
"file"
ngf-select
ng-model=
"uploadFile.file"
accept=
".xls,.xlsx"
class=
"btn btn-secondary browse"
>
{{'SelectFile' | translate }}
</button>
<button
type=
"button"
class=
"btn btn-secondary"
translate=
"CoverImportBtn"
ng-click=
"upload()"
></button>
<button
type=
"button"
class=
"btn btn-secondary"
translate=
"AddImportBtn"
ng-click=
"upload()"
></button>
<button
type=
"button"
class=
"btn btn-in-grid inline-div"
ng-click=
"downEntepriseAccountTemplate()"
><i
class=
"fa fa-download"
aria-hidden=
"true"
></i>
下载模板
</button>
</div>
</form>
<div
class=
"dt-init-wrapper"
>
<div
class=
"dx-viewport grid-container"
>
<div
id=
"revenueGridContainer"
dx-data-grid=
"revenueGridOptions"
style=
"margin-top: 0px;"
>
<div
data-options=
"dxTemplate:{ name:'editCellTemplate' }"
>
</div>
</div>
</div>
<div
class=
"page-footer"
>
<ack-pagination
page-options=
"pagingOptions"
refresh-table=
"refreshConfigGrid()"
></ack-pagination>
</div>
</div>
</div>
<div
class=
"modal fade"
id=
"revenueTypeAddDiv"
tabindex=
"-1"
role=
"dialog"
>
<div
class=
"modal-dialog"
style=
"width: 1200px;"
role=
"document"
>
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<h3
class=
"modal-title"
id=
"modal-title"
>
<span
translate=
"RevCMTitle"
></span>
</h3>
</div>
<div
class=
"modal-body"
id=
"modal-body"
>
<form
class=
"form-horizontal"
id=
"configForm"
>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevenueColOrg' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<div
dx-tag-box=
"selectOrgOptions"
></div>
</div>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevCMApplyBU' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<input
class=
"form-control"
name=
"name"
ng-model=
"formParam.ouName"
maxlength=
"255"
>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevCMInvoiceCTX' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<input
class=
"form-control"
name=
"name"
ng-model=
"formParam.content"
maxlength=
"255"
>
</div>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevenueColTaxRate' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<div
dx-select-box=
"selectTaxRateOptions"
></div>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevDetailType' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<input
class=
"form-control"
name=
"name"
ng-model=
"formParam.revenueTypeName"
maxlength=
"255"
>
</div>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevenueColStatus' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<div
dx-select-box=
"selectStatusOptions"
></div>
</div>
</div>
<div
class=
"form-group"
>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevenueColEnable' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<div
dx-date-box=
"dateBoxStart"
></div>
</div>
<label
class=
"col-sm-2 control-label"
><span
style=
"color: red"
>
*
</span>
{{'RevenueColDisable' | translate}}:
</label>
<div
class=
"col-sm-4"
>
<div
dx-date-box=
"dateBoxEnd"
></div>
</div>
</div>
</form>
</div>
<div
class=
"modal-footer"
>
<button
type=
"button"
class=
"btn btn-primary"
ng-click=
"saveConfig()"
>
{{'Confirm' | translate }}
</button>
<button
type=
"button"
class=
"btn btn-third"
data-dismiss=
"modal"
ng-click=
"cancelModal()"
>
{{'Cancel' | translate }}
</button>
</div>
</div>
</div>
</div>
</div>
atms-web/src/main/webapp/app/dataImport/vat-revenue-conf-mapping/vat-revenue-conf-mapping.js
0 → 100644
View file @
64ec7088
citModule
.
directive
(
'vatRevenueConfMapping'
,
[
'$log'
,
'browserService'
,
'$translate'
,
'region'
,
'$timeout'
,
function
(
$log
,
browserService
,
$translate
,
region
,
$timeout
)
{
$log
.
debug
(
'vatPreviewProfitLoss.ctor()...'
);
return
{
restrict
:
'E'
,
templateUrl
:
'/app/dataImport/vat-revenue-conf-mapping/vat-revenue-conf-mapping.html'
+
'?_='
+
Math
.
random
(),
scope
:
{},
controller
:
'VatRevenueConfMappingController'
,
link
:
function
(
$scope
,
element
)
{
$
(
'.main-contents'
)[
0
].
style
.
width
=
"260px"
;
$
(
'.data-import-contents'
)[
0
].
style
.
display
=
"block"
;
$
(
'.main-contents'
)[
0
].
style
.
float
=
"left"
;
$
(
'.main-contents'
)[
0
].
style
.
styleFloat
=
"left"
;
$
(
'.main-contents'
)[
0
].
style
.
cssFloat
=
"left"
;
}
}
}
]);
\ No newline at end of file
atms-web/src/main/webapp/app/dataImport/vat-revenue-conf-mapping/vat-revenue-conf-mapping.less
0 → 100644
View file @
64ec7088
@import "~/app-resources/less/theme.less";
.vat-revenue-conf-mapping {
/*background-color: @color-white;*/
padding-left: 20px;
/*min-height: 800px;*/
height: 96%;
.nav-wrapper {
/*padding-bottom: 5px;
border-bottom: 1px solid #DBD8D3;*/
.nav-header {
height: 54px;
line-height: 54px;
font-family: "Microsoft YaHei Bold", "Microsoft YaHei Regular", "Microsoft YaHei";
font-weight: 700;
font-style: normal;
font-size: 15px;
color: #333;
display: inline-block;
}
.nav-tab {
span {
display: inline-block;
height: 34px;
line-height: 34px;
padding: 0 10px;
background-color: #B90808;
color: #FFF;
font-family: "Microsoft YaHei";
font-weight: 400;
font-style: normal;
font-size: 14px;
cursor: pointer;
}
.active {
background-color: #F91000;
}
}
.alert-warning {
background-color: #FDE2DE;
cursor: pointer;
}
.alert {
color: #CF2D1B;
font-weight: bold;
display: inline-block;
padding: 5px;
margin-left: 60px;
margin-bottom: 0px;
i {
font-size: 20px;
vertical-align: middle;
margin-right: 5px;
}
}
.operation-wrapper {
margin: 15px 25px 10px 10px;
span {
cursor: pointer;
}
}
}
.dropdown-common() {
display: inline-block;
.select-button {
background-color: #F5F5F5;
padding: 6px 0;
width: 100px;
}
.caret {
margin-top: 8px;
}
.dropdown-menu {
min-width: 100px;
li {
text-align: center;
min-height: 0px;
height: 30px;
line-height: 30px;
color: #000;
font-weight: normal;
&:hover {
background-color: #F91000;
color: #FFF;
}
}
}
}
#tab_total {
display: block;
height: calc(~'100% - 40px');
position: relative;
.import-wrapper {
span {
margin-left: 10px;
color: #333;
font-family: "Microsoft YaHei";
font-style: normal;
font-size: 14px;
font-weight: bold;
}
.period-picker {
width: 150px;
border: 1px solid #c7c5c0;
display: inline-block;
line-height: 20px;
margin-top: 7px;
}
.imp-subheader {
display: inline-block;
font-size: 15px;
height: 30px;
line-height: 30px;
vertical-align: middle;
border: none;
select {
appearance: none;
-moz-appearance: none;
-webkit-appearance: none;
background: transparent;
}
}
.dropdown {
.dropdown-common();
}
input {
width: 50px;
outline: none;
border-radius: 3px;
border: 1px solid #3c3a36;
padding: 2px;
text-align: center;
}
> button:last-child {
float: right;
margin-right: 20px;
}
.btn-wrapper {
border-radius: 5px;
background-color: #e0301e;
color: #FFF;
display: inline-block;
float: right;
margin-right: 10px;
.btn-vat-primary {
min-width: 80px;
}
}
}
.dt-init-wrapper {
margin: 30px 0;
max-width: 99%;
height: calc(~'100% - 25px');
position: relative;
.dropdown {
.dropdown-common();
i {
color: #F85550;
}
}
.importPLStatusGridContainer {
height: calc(~'100% - 30px');
overflow: hidden;
position: absolute;
top: 0;
bottom: 136px; /* 130 + 6 */
left: 0;
right: 0;
background-color: #FFF;
}
}
.error-info-wrapper {
position: absolute;
height: 150px;
bottom: 0;
left: 0;
right: 0;
overflow: hidden;
background-color: #FFF;
margin-left: -40px;
}
#content-resizer {
width: 110%;
position: absolute;
height: 4px;
bottom: 150px;
left: 0;
right: 0;
background-color: red;
cursor: n-resize;
margin-left: -40px;
#topIcon {
cursor: pointer;
margin-top: -19px;
width: 38px;
margin-left: 46%;
z-index: 999;
bottom: -381px;
text-align: center;
display: block !important;
}
}
.dt-import-wrapper {
margin: 60px 0;
max-width: 99%;
overflow: auto;
height: calc(~"100% - 35px");
.dropdown {
.dropdown-common();
i {
color: #F85550;
}
}
}
}
.error-list-modal {
.modal-title {
color: #FF0000;
}
.modal-body {
max-height: 300px;
overflow-y: auto;
table {
border: 1px solid #CCC;
thead tr th {
height: 30px;
border: 1px solid #CCC;
}
tbody tr td {
height: 25px;
border: 1px solid #CCC;
}
}
}
.modal-footer {
text-align: center;
}
}
#tab_detail {
display: none;
}
/*覆写ack-pagination.less中:.page-size, .pagination 中的margin演示 */
.page-form-group{
float:right;
.page-size{
margin:0;
}
.pagination {
margin:0;
}
}
}
.tb-model-period-dropdow-popup {
width: 400px;
height: 500px;
position: fixed;
top: 25%;
left: 40%;
.modal-dialog {
width: 100%;
height: 90%;
margin: 20px auto;
.modal-content {
width: 100%;
.modal-body {
height: 90%;
}
}
}
}
#totalWrapper {
margin: 5px 10px 10px -10px;
width: 100%;
padding-left: 10px;
font-family: Microsoft YaHei;
font-size: 13px;
float:right;
.total_span{
color: #B4122A !important;
background-color:#ddd !important;
font-size: 12px !important;
font-weight:bold !important;
border-radius:10px !important;
padding-left: 8px !important;
padding-right: 8px !important;
}
.total-column{
width:15%;
float:left;
padding-left: 15px;
}
}
\ No newline at end of file
atms-web/src/main/webapp/app/dataImport/vat-revenue-config/vat-revenue-config.ctrl.js
View file @
64ec7088
...
...
@@ -6,7 +6,7 @@
//表格配置
$scope
.
revenueGridOptions
=
$
.
extend
(
true
,
{},
dxDataGridService
.
BASIC_GRID_OPTIONS
,
{
columns
:
[
// {dataField: 'serialNo', caption: $translate.instant('RevenueColSerialNo'), fixed: true, allowHeaderFiltering: tru
e},
{
dataField
:
'idStr'
,
caption
:
''
,
visible
:
fals
e
},
{
dataField
:
'name'
,
caption
:
$translate
.
instant
(
'RevenueColName'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
minWidth
:
'300px'
},
{
dataField
:
'orgId'
,
caption
:
$translate
.
instant
(
'RevenueColOrg'
),
fixed
:
true
,
allowHeaderFiltering
:
true
,
minWidth
:
'300px'
,
calculateCellValue
:
function
(
data
)
{
...
...
@@ -35,7 +35,7 @@
}).
appendTo
(
container
);
$
(
'<i class="fa fa-trash" style="cursor: pointer;margin-left: 5px;"></i>'
)
.
on
(
'click'
,
function
()
{
$scope
.
editConfig
(
options
.
data
);
$scope
.
delConfig
([
options
.
data
.
idStr
]
);
}).
appendTo
(
container
);
}
catch
(
e
)
{
...
...
@@ -50,7 +50,11 @@
mode
:
'multiple'
,
showCheckBoxesMode
:
'always'
,
allowSelectAll
:
true
}
},
onSelectionChanged
:
function
(
data
)
{
$scope
.
selectedItems
=
data
.
selectedRowsData
;
$scope
.
selectedRecourdCount
=
data
.
selectedRowsData
.
length
;
},
});
//刷新页面
...
...
@@ -74,8 +78,24 @@
};
//删除配置
$scope
.
delConfig
=
function
()
{
SweetAlert
.
info
(
'del'
);
$scope
.
delConfig
=
function
(
idList
)
{
$http
.
post
(
'/revenueConf/del'
,
idList
,
apiConfig
.
createVat
())
.
success
(
function
(
res
)
{
if
(
res
&&
0
===
res
.
code
)
{
SweetAlert
.
success
(
$translate
.
instant
(
'RevenueDelSuccess'
));
$scope
.
refreshConfigGrid
();
}
else
{
SweetAlert
.
error
(
$translate
.
instant
(
'SystemError'
));
}
})
};
$scope
.
batchDelConfig
=
function
()
{
if
(
!!
$scope
.
selectedRecourdCount
)
{
$scope
.
delConfig
(
_
.
map
(
$scope
.
selectedItems
,
function
(
item
){
return
item
.
idStr
;
}));
}
else
{
SweetAlert
.
warning
(
$translate
.
instant
(
'PleaseSelectAtLeastOneItem'
));
}
};
//添加配置
...
...
atms-web/src/main/webapp/app/dataImport/vat-revenue-config/vat-revenue-config.html
View file @
64ec7088
...
...
@@ -7,7 +7,7 @@
<form
class=
"form-inline"
>
<div
class=
"form-group"
><div
class=
"import-wrapper"
>
<button
type=
"button"
class=
"btn btn-primary"
ng-click=
"addConfig()"
>
{{'RevenueAddBtn' | translate }}
</button>
<button
type=
"button"
class=
"btn btn-third"
ng-click=
"
d
elConfig()"
>
{{'RevenueDelBtn' | translate }}
</button>
<button
type=
"button"
class=
"btn btn-third"
ng-click=
"
batchD
elConfig()"
>
{{'RevenueDelBtn' | translate }}
</button>
</div></div>
</form>
...
...
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