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
462f5307
Commit
462f5307
authored
Apr 11, 2019
by
chase
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
merge 档案管理
parent
fbc42d8b
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
263 additions
and
141 deletions
+263
-141
FileTypesServiceImpl.java
...a/pwc/taxtech/atms/service/impl/FileTypesServiceImpl.java
+19
-23
TaxDocumentServiceImpl.java
...pwc/taxtech/atms/service/impl/TaxDocumentServiceImpl.java
+71
-108
Gruntfile.js
atms-web/src/main/webapp/Gruntfile.js
+2
-1
bootstrap-confirm.js
...main/webapp/Scripts/bootstrp-confirm/bootstrap-confirm.js
+154
-0
doc-manage.ctrl.js
...app/app/admin/infrastructure/docManage/doc-manage.ctrl.js
+3
-1
app-usr-operate-log.ctrl.js
...framework/app-usr-operate-log/app-usr-operate-log.ctrl.js
+1
-1
tax-document-list.ctrl.js
...ocumentManage/tax-document-list/tax-document-list.ctrl.js
+13
-7
No files found.
atms-api/src/main/java/pwc/taxtech/atms/service/impl/FileTypesServiceImpl.java
View file @
462f5307
...
...
@@ -15,6 +15,7 @@ import pwc.taxtech.atms.entity.OperationLogFileType;
import
javax.annotation.Resource
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.stream.Collectors
;
/**
* 查询
...
...
@@ -99,7 +100,7 @@ public class FileTypesServiceImpl {
criteria
.
andFileTypeEqualTo
(
fileTypes
.
getFileType
());
}
List
<
FileTypes
>
results
=
fileTypesMapper
.
selectByExample
(
example
);
if
(
results
.
size
()
>
0
)
{
if
(
results
.
size
()
>
0
&&
!
results
.
stream
().
map
(
e
->
e
.
getId
()).
collect
(
Collectors
.
toList
()).
contains
(
fileTypes
.
getId
())
)
{
throw
new
RuntimeException
(
"filetype已存在: "
+
fileTypes
.
getFileType
());
}
}
...
...
@@ -129,30 +130,25 @@ public class FileTypesServiceImpl {
@Transactional
public
boolean
editFilesType
(
FileTypes
fileTypes
)
{
try
{
//检测添加类型是否已存在,存在则返回false先(后期改进为多异常)
checkFileType
(
fileTypes
);
//对必填字段进行转换成json对象
requiredFieldFormatToJson
(
fileTypes
);
fileTypes
.
setUpdateTime
(
new
Date
());
int
num
=
fileTypesMapper
.
updateByPrimaryKey
(
fileTypes
);
if
(
num
>
0
)
{
OperationLogFileType
actionEntity
=
buildOperationLogFileType
();
actionEntity
.
setOperationAction
(
"更新"
);
actionEntity
.
setId
(
fileTypes
.
getId
().
toString
());
//设置更新值
actionEntity
.
setUpdateState
(
fileTypes
.
toString
());
boolean
result
=
operationLogFileTypeService
.
addFileTypesList
(
actionEntity
);
if
(
result
)
{
return
true
;
}
else
{
throw
new
RuntimeException
(
"FileTypesServiceImpl editFilesType log error"
);
}
//检测添加类型是否已存在,存在则返回false先(后期改进为多异常)
checkFileType
(
fileTypes
);
//对必填字段进行转换成json对象
requiredFieldFormatToJson
(
fileTypes
);
fileTypes
.
setUpdateTime
(
new
Date
());
int
num
=
fileTypesMapper
.
updateByPrimaryKey
(
fileTypes
);
if
(
num
>
0
)
{
OperationLogFileType
actionEntity
=
buildOperationLogFileType
();
actionEntity
.
setOperationAction
(
"更新"
);
actionEntity
.
setId
(
fileTypes
.
getId
().
toString
());
//设置更新值
actionEntity
.
setUpdateState
(
fileTypes
.
toString
());
boolean
result
=
operationLogFileTypeService
.
addFileTypesList
(
actionEntity
);
if
(
result
)
{
return
true
;
}
else
{
return
false
;
throw
new
RuntimeException
(
"FileTypesServiceImpl editFilesType log error"
)
;
}
}
catch
(
Exception
e
)
{
log
.
error
(
"FileTypesServiceImpl editFilesType error : "
+
e
.
getMessage
());
}
else
{
return
false
;
}
}
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/TaxDocumentServiceImpl.java
View file @
462f5307
...
...
@@ -745,13 +745,6 @@ public class TaxDocumentServiceImpl {
*/
//档案类型分组:公司簡稱_档案类型_文件生效日期
private
final
static
Map
<
String
,
String
>
groupOfCompanyFileTypeFIleTime
=
Maps
.
newHashMap
();
//档案类型分组:公司簡稱_档案类型_到期日
private
final
static
Map
<
String
,
String
>
groupOfCompanyFileTypeEffectiveTime
=
Maps
.
newHashMap
();
//档案类型分组:公司簡稱_档案属性_档案类型(国际档案类型,因为此处英文有重复键,所以多个分组)
private
final
static
Map
<
String
,
String
>
internationalGroupOfCompanyFileAttrFileType1
=
Maps
.
newHashMap
();
private
final
static
Map
<
String
,
String
>
internationalGroupOfCompanyFileAttrFileType2
=
Maps
.
newHashMap
();
private
final
static
Map
<
String
,
String
>
internationalGroupOfCompanyFileAttrFileType3
=
Maps
.
newHashMap
();
private
final
static
Map
<
String
,
String
>
internationalGroupOfCompanyFileAttrFileType4
=
Maps
.
newHashMap
();
/**
* 分组 长度为4
*/
...
...
@@ -759,6 +752,8 @@ public class TaxDocumentServiceImpl {
private
final
static
Map
<
String
,
String
>
groupOfCompanyFileTypeOwnTimeFileTime
=
Maps
.
newHashMap
();
//档案类型分组:公司簡稱_档案类型_所属期间_到期日
private
final
static
Map
<
String
,
String
>
groupOfCompanyFileTypeOwnTimeEffectiveTime
=
Maps
.
newHashMap
();
//档案类型分组:公司簡稱_档案属性_档案类型_文件生效日期
private
final
static
Map
<
String
,
String
>
internationalGroupOfCompanyFileAttrFileTypeFileTime
=
Maps
.
newHashMap
();
//档案类型分组:公司簡稱_档案属性_档案类型_所属期间(国际档案类型)
private
final
static
Map
<
String
,
String
>
internationalGroupOfCompanyFileAttrFileTypeOwnTime
=
Maps
.
newHashMap
();
/**
...
...
@@ -777,12 +772,10 @@ public class TaxDocumentServiceImpl {
//初始化档案类型-档案属性map列表(后续可做成从数据库中拿)
static
{
//添加分组
//公司簡稱_档案类型_文件生效日期
中
//公司簡稱_档案类型_文件生效日期
setGroupOfCompanyFileTypeFIleTime
();
//公司簡稱_档案类型_到期日
setGroupOfCompanyFileTypeEffectiveTime
();
//公司簡稱_档案属性_档案类型
setInternationalGroupOfCompanyFileAttrFileType
();
//公司簡稱_档案属性_档案类型_文件生效日期
setInternationalGroupOfCompanyFileAttrFileTypeFileTime
();
//公司簡稱_档案类型_所属期间_文件生效日期
setGroupOfCompanyFileTypeOwnTimeFileTime
();
//公司簡稱_档案类型_所属期间_到期日
...
...
@@ -815,48 +808,38 @@ public class TaxDocumentServiceImpl {
groupOfCompanyFileTypeFIleTime
.
put
(
"发票核销资料"
,
"06 发票管理类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"开具红字发票资料"
,
"06 发票管理类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"非居民享受税收协定待遇认定"
,
"02 税务认定类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"汇总(合并)纳税企业信息备案资料"
,
"01 税务登记类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"发票票种核定资料"
,
"06 发票管理类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"发票用票量调整资料"
,
"06 发票管理类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"增值税税收优惠资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"车辆购置税税收优惠资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"企业所得税税收优惠资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"税收减免审批资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"税收减免备案资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"纳税申报方式认定"
,
"02 税务认定类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"一般纳税人认定"
,
"02 税务认定类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"征收方式认定"
,
"02 税务认定类"
);
groupOfCompanyFileTypeFIleTime
.
put
(
"税种核定资料"
,
"04 申报征收类"
);
}
/**
* 公司簡稱_档案
类型_到期日
* 公司簡稱_档案
属性_档案类型_文件生效日期
*/
private
static
void
setGroupOfCompanyFileTypeEffectiveTime
()
{
groupOfCompanyFileTypeEffectiveTime
.
put
(
"汇总(合并)纳税企业信息备案资料"
,
"01 税务登记类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"发票票种核定资料"
,
"06 发票管理类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"发票用票量调整资料"
,
"06 发票管理类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"增值税税收优惠资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"车辆购置税税收优惠资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"企业所得税税收优惠资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"税收减免审批资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"税收减免备案资料"
,
"03 税收优惠类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"纳税申报方式认定"
,
"02 税务认定类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"一般纳税人认定"
,
"02 税务认定类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"征收方式认定"
,
"02 税务认定类"
);
groupOfCompanyFileTypeEffectiveTime
.
put
(
"税种核定资料"
,
"04 申报征收类"
);
}
/**
* 公司簡稱_档案属性_档案类型(因为此处英文有重复键,所以多个分组)
*/
private
static
void
setInternationalGroupOfCompanyFileAttrFileType
()
{
//因为此处英文有重复键,所以多个分组区分开
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"Other"
,
"International Tax - Legal Document"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"Application documents"
,
"International tax - Tax Rulings"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"Approval documents"
,
"International tax - Tax Incentives"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"Article of incorporation"
,
"International Tax - Legal Document"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"Business registration"
,
"International Tax - Legal Document"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"CIT"
,
"International Tax - Tax Registration"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"VAT"
,
"International Tax - Tax Registration"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"Letter from Tax Authority"
,
"International Tax - Tax Inspection"
);
internationalGroupOfCompanyFileAttrFileType1
.
put
(
"Reply letter and supporting"
,
"International Tax - Tax Inspection"
);
internationalGroupOfCompanyFileAttrFileType2
.
put
(
"Other"
,
"International Tax - Tax Registration"
);
internationalGroupOfCompanyFileAttrFileType2
.
put
(
"Application documents"
,
"International tax - Tax Incentives"
);
internationalGroupOfCompanyFileAttrFileType2
.
put
(
"Approval documents"
,
"International tax - Tax Rulings"
);
internationalGroupOfCompanyFileAttrFileType3
.
put
(
"Other"
,
"International tax - Tax Incentives"
);
internationalGroupOfCompanyFileAttrFileType4
.
put
(
"Other"
,
"International Tax - Tax Inspection"
);
private
static
void
setInternationalGroupOfCompanyFileAttrFileTypeFileTime
()
{
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Legal Document - Other"
,
"International Tax - Legal Document"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Ruling Application documents"
,
"International tax - Tax Rulings"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Incentive Approval documents"
,
"International tax - Tax Incentives"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Article of incorporation"
,
"International Tax - Legal Document"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Business registration"
,
"International Tax - Legal Document"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"CIT"
,
"International Tax - Tax Registration"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"VAT"
,
"International Tax - Tax Registration"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Letter from Tax Authority"
,
"International Tax - Tax Inspection"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Reply letter and supporting"
,
"International Tax - Tax Inspection"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Tax Registration - Other"
,
"International Tax - Tax Registration"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Incentive Application documents"
,
"International tax - Tax Incentives"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Ruling Approval documents"
,
"International tax - Tax Rulings"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Tax Incentives - Other"
,
"International tax - Tax Incentives"
);
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
put
(
"Tax Inspection - Other"
,
"International Tax - Tax Inspection"
);
}
/**
...
...
@@ -971,107 +954,87 @@ public class TaxDocumentServiceImpl {
*/
private
void
matchFileTypeToInitData
(
ArrayList
<
String
>
errorFileNameList
,
ArrayList
<
String
>
successeFileNameList
,
ArrayList
<
String
>
existedFileNameList
,
Map
<
String
,
String
>
companyNameAndId
,
File
file
,
List
<
String
>
params
,
String
filePath
)
{
//长度为3(先验证是否国际类型并校验匹配,若是国际类型档案类型索引为2(国际类型第三个为档案类型),否则索引为1为档案类型
if
(
params
.
size
()
==
3
&&
(
//国际类型 公司簡稱_档案属性_档案类型
(
internationalGroupOfCompanyFileAttrFileType1
.
keySet
().
contains
(
params
.
get
(
2
))
&&
internationalGroupOfCompanyFileAttrFileType1
.
values
().
contains
(
params
.
get
(
1
)))
||
(
internationalGroupOfCompanyFileAttrFileType2
.
keySet
().
contains
(
params
.
get
(
2
))
&&
internationalGroupOfCompanyFileAttrFileType2
.
values
().
contains
(
params
.
get
(
1
)))
||
(
internationalGroupOfCompanyFileAttrFileType3
.
keySet
().
contains
(
params
.
get
(
2
))
&&
internationalGroupOfCompanyFileAttrFileType3
.
values
().
contains
(
params
.
get
(
1
)))
||
(
internationalGroupOfCompanyFileAttrFileType4
.
keySet
().
contains
(
params
.
get
(
2
))
&&
internationalGroupOfCompanyFileAttrFileType4
.
values
().
contains
(
params
.
get
(
1
)))))
{
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案属性 档案类型
taxDocument
.
setFileAttr
(
params
.
get
(
1
));
taxDocument
.
setFileType
(
params
.
get
(
2
));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
3
//公司簡稱_档案类型_文件生效日期
if
(
params
.
size
()
==
3
//公司簡稱_档案类型_文件生效日期
&&
groupOfCompanyFileTypeFIleTime
.
keySet
().
contains
(
params
.
get
(
1
))
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
2
)))
{
//文件生效日期校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
2
))){
//文件生效日期校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案属性 档案类型 文件生效日期
taxDocument
.
setFileType
(
params
.
get
(
1
));
taxDocument
.
setFileAttr
(
groupOfCompanyFileTypeFIleTime
.
get
(
params
.
get
(
1
)));
taxDocument
.
setFileTime
(
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
2
)));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
3
//公司簡稱_档案类型_到期日
&&
groupOfCompanyFileTypeEffectiveTime
.
keySet
().
contains
(
params
.
get
(
1
))
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
2
)))
{
//到期日校验
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
4
//国际类型 公司簡稱_档案属性_档案类型_文件生效日期
&&
(
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
keySet
().
contains
(
params
.
get
(
2
))
&&
internationalGroupOfCompanyFileAttrFileTypeFileTime
.
values
().
contains
(
params
.
get
(
1
)))
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
))){
//文件生效日期校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案属性 档案类型 到期日
taxDocument
.
setFileType
(
params
.
get
(
1
));
taxDocument
.
setFileAttr
(
groupOfCompanyFileTypeEffectiveTime
.
get
(
params
.
get
(
1
)));
taxDocument
.
setEffectiveTime
(
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
2
)));
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案属性 档案类型
taxDocument
.
setFileAttr
(
params
.
get
(
1
));
taxDocument
.
setFileType
(
params
.
get
(
2
));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
4
//国际类型 公司簡稱_档案属性_档案类型_所属期间
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
4
//国际类型 公司簡稱_档案属性_档案类型_所属期间
&&
(
internationalGroupOfCompanyFileAttrFileTypeOwnTime
.
keySet
().
contains
(
params
.
get
(
2
))
&&
internationalGroupOfCompanyFileAttrFileTypeOwnTime
.
values
().
contains
(
params
.
get
(
1
)))
&&
checkOwnTime
(
params
.
get
(
3
)))
{
//所属期间校验
&&
checkOwnTime
(
params
.
get
(
3
))){
//所属期间校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案属性 档案类型 所属期间
taxDocument
.
setFileAttr
(
params
.
get
(
1
));
taxDocument
.
setFileType
(
params
.
get
(
2
));
taxDocument
.
setOwnTime
(
Integer
.
valueOf
(
params
.
get
(
3
)));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
4
//公司簡稱_档案类型_所属期间_文件生效日期
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
4
//公司簡稱_档案类型_所属期间_文件生效日期
&&
groupOfCompanyFileTypeOwnTimeFileTime
.
keySet
().
contains
(
params
.
get
(
1
))
&&
checkOwnTime
(
params
.
get
(
2
))
//所属期间校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
)))
{
//文件生效日期校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
))){
//文件生效日期校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案类型 档案属性 所属期间 文件生效日期
taxDocument
.
setFileType
(
params
.
get
(
1
));
taxDocument
.
setFileAttr
(
groupOfCompanyFileTypeOwnTimeFileTime
.
get
(
params
.
get
(
1
)));
taxDocument
.
setOwnTime
(
Integer
.
valueOf
(
params
.
get
(
2
)));
taxDocument
.
setFileTime
(
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
)));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
4
//公司簡稱_档案类型_所属期间_到期日
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
4
//公司簡稱_档案类型_所属期间_到期日
&&
groupOfCompanyFileTypeOwnTimeEffectiveTime
.
keySet
().
contains
(
params
.
get
(
1
))
&&
checkOwnTime
(
params
.
get
(
2
))
//所属期间校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
)))
{
//到期日校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
))){
//到期日校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案类型 档案属性 所属期间 到期日
taxDocument
.
setFileType
(
params
.
get
(
1
));
taxDocument
.
setFileAttr
(
groupOfCompanyFileTypeOwnTimeEffectiveTime
.
get
(
params
.
get
(
1
)));
taxDocument
.
setOwnTime
(
Integer
.
valueOf
(
params
.
get
(
2
)));
taxDocument
.
setEffectiveTime
(
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
)));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
5
//国际类型 公司簡稱_档案属性_档案类型_税种_所属期间
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
5
//国际类型 公司簡稱_档案属性_档案类型_税种_所属期间
&&
(
internationalGroupOfCompanyFileAttrFileTypeTaxTypeOwnTime
.
keySet
().
contains
(
params
.
get
(
2
))
&&
internationalGroupOfCompanyFileAttrFileTypeTaxTypeOwnTime
.
values
().
contains
(
params
.
get
(
1
)))
&&
taxsList
.
contains
(
params
.
get
(
3
))
//税种校验
&&
checkOwnTime
(
params
.
get
(
4
)))
{
//所属期间校验
&&
checkOwnTime
(
params
.
get
(
4
))){
//所属期间校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案属性 档案类型 税种 所属期间
taxDocument
.
setFileAttr
(
params
.
get
(
1
));
taxDocument
.
setFileType
(
params
.
get
(
2
));
taxDocument
.
setTaxType
(
params
.
get
(
3
));
taxDocument
.
setOwnTime
(
Integer
.
valueOf
(
params
.
get
(
4
)));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
5
//公司簡稱_档案类型_税种_所属期间_文件生效日期
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
5
//公司簡稱_档案类型_税种_所属期间_文件生效日期
&&
groupOfCompanyFileTypeTaxTypeOwnTimeFileTime
.
keySet
().
contains
(
params
.
get
(
1
))
&&
taxsList
.
contains
(
params
.
get
(
2
))
//税种校验
&&
checkOwnTime
(
params
.
get
(
3
))
//所属期间校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
4
)))
{
//文件生效日期校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
4
))){
//文件生效日期校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案类型 档案属性 税种 所属期间 文件生效日期
taxDocument
.
setFileType
(
params
.
get
(
1
));
taxDocument
.
setFileAttr
(
groupOfCompanyFileTypeTaxTypeOwnTimeFileTime
.
get
(
params
.
get
(
1
)));
...
...
@@ -1079,13 +1042,13 @@ public class TaxDocumentServiceImpl {
taxDocument
.
setOwnTime
(
Integer
.
valueOf
(
params
.
get
(
3
)));
taxDocument
.
setFileTime
(
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
4
)));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
6
//公司簡稱_档案类型_所属期间_文件生效日期_实物存放地点_实物保管人
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
if
(
params
.
size
()
==
6
//公司簡稱_档案类型_所属期间_文件生效日期_实物存放地点_实物保管人
&&
groupOfCompanyFileTypeOwnTimeFileTimeStorageAreaKeeper
.
keySet
().
contains
(
params
.
get
(
1
))
&&
checkOwnTime
(
params
.
get
(
2
))
//所属期间校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
)))
{
//文件生效日期校验
&&
null
!=
DateUtils
.
stringToDate4yyyyMMdd
(
params
.
get
(
3
))){
//文件生效日期校验
//构建基础对象 设置基础值 公司简称 Id 文件名
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
TaxDocument
taxDocument
=
buildBaseTaxDocument
(
companyNameAndId
,
params
,
file
.
getName
());
//设置档案类型 档案属性 所属期间 文件生效日期 实物存放地点 实物保管人
taxDocument
.
setFileType
(
params
.
get
(
1
));
taxDocument
.
setFileAttr
(
groupOfCompanyFileTypeOwnTimeFileTimeStorageAreaKeeper
.
get
(
params
.
get
(
1
)));
...
...
@@ -1094,8 +1057,8 @@ public class TaxDocumentServiceImpl {
taxDocument
.
setStorageArea
(
params
.
get
(
4
));
taxDocument
.
setKeeper
(
params
.
get
(
5
));
//校验是否已存在
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
{
checkExistedAndInsertOrUpdate
(
successeFileNameList
,
existedFileNameList
,
file
,
taxDocument
,
filePath
);
}
else
{
errorFileNameList
.
add
(
filePath
);
}
}
...
...
atms-web/src/main/webapp/Gruntfile.js
View file @
462f5307
...
...
@@ -237,7 +237,8 @@ grunt.initConfig({
"Scripts/viewer/viewer.js"
,
"Scripts/xlsx/shim.min.js"
,
"Scripts/xlsx/xlsx.full.min.js"
,
"Scripts/position-calculator/position-calculator.min.js"
"Scripts/position-calculator/position-calculator.min.js"
,
"Scripts/bootstrp-confirm/bootstrap-confirm.js"
],
dest
:
'<%= pkg.bundleTemp %>/util.js'
},
...
...
atms-web/src/main/webapp/Scripts/bootstrp-confirm/bootstrap-confirm.js
0 → 100644
View file @
462f5307
(
function
(
$
)
{
window
.
Ewin
=
function
()
{
var
html
=
'<div id="[Id]" class="modal fade" role="dialog" aria-labelledby="modalLabel">'
+
'<div class="modal-dialog modal-sm">'
+
'<div class="modal-content">'
+
'<div class="modal-header">'
+
'<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>'
+
'<h4 class="modal-title" id="modalLabel">[Title]</h4>'
+
'</div>'
+
'<div class="modal-body">'
+
'<p>[Message]</p>'
+
'</div>'
+
'<div class="modal-footer">'
+
'<button type="button" class="btn btn-default cancel" data-dismiss="modal">[BtnCancel]</button>'
+
'<button type="button" class="btn btn-primary ok" data-dismiss="modal">[BtnOk]</button>'
+
'</div>'
+
'</div>'
+
'</div>'
+
'</div>'
;
var
dialogdHtml
=
'<div id="[Id]" class="modal fade" role="dialog" aria-labelledby="modalLabel">'
+
'<div class="modal-dialog">'
+
'<div class="modal-content">'
+
'<div class="modal-header">'
+
'<button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span><span class="sr-only">Close</span></button>'
+
'<h4 class="modal-title" id="modalLabel">[Title]</h4>'
+
'</div>'
+
'<div class="modal-body">'
+
'</div>'
+
'</div>'
+
'</div>'
+
'</div>'
;
var
reg
=
new
RegExp
(
"
\\
[([^
\\
[
\\
]]*?)
\\
]"
,
'igm'
);
var
generateId
=
function
()
{
var
date
=
new
Date
();
return
'mdl'
+
date
.
valueOf
();
}
var
init
=
function
(
options
)
{
options
=
$
.
extend
({},
{
title
:
"操作提示"
,
message
:
"提示内容"
,
btnok
:
"确定"
,
btncl
:
"取消"
,
width
:
200
,
auto
:
false
},
options
||
{});
var
modalId
=
generateId
();
var
content
=
html
.
replace
(
reg
,
function
(
node
,
key
)
{
return
{
Id
:
modalId
,
Title
:
options
.
title
,
Message
:
options
.
message
,
BtnOk
:
options
.
btnok
,
BtnCancel
:
options
.
btncl
}[
key
];
});
$
(
'body'
).
append
(
content
);
$
(
'#'
+
modalId
).
modal
({
width
:
options
.
width
,
backdrop
:
'static'
});
$
(
'#'
+
modalId
).
on
(
'hide.bs.modal'
,
function
(
e
)
{
$
(
'body'
).
find
(
'#'
+
modalId
).
remove
();
});
return
modalId
;
}
return
{
alert
:
function
(
options
)
{
if
(
typeof
options
==
'string'
)
{
options
=
{
message
:
options
};
}
var
id
=
init
(
options
);
var
modal
=
$
(
'#'
+
id
);
modal
.
find
(
'.ok'
).
removeClass
(
'btn-success'
).
addClass
(
'btn-primary'
);
modal
.
find
(
'.cancel'
).
hide
();
return
{
id
:
id
,
on
:
function
(
callback
)
{
if
(
callback
&&
callback
instanceof
Function
)
{
modal
.
find
(
'.ok'
).
click
(
function
()
{
callback
(
true
);
});
}
},
hide
:
function
(
callback
)
{
if
(
callback
&&
callback
instanceof
Function
)
{
modal
.
on
(
'hide.bs.modal'
,
function
(
e
)
{
callback
(
e
);
});
}
}
};
},
confirm
:
function
(
options
)
{
var
id
=
init
(
options
);
var
modal
=
$
(
'#'
+
id
);
modal
.
find
(
'.ok'
).
removeClass
(
'btn-primary'
).
addClass
(
'btn-success'
);
modal
.
find
(
'.cancel'
).
show
();
return
{
id
:
id
,
on
:
function
(
callback
)
{
if
(
callback
&&
callback
instanceof
Function
)
{
modal
.
find
(
'.ok'
).
click
(
function
()
{
callback
(
true
);
});
modal
.
find
(
'.cancel'
).
click
(
function
()
{
callback
(
false
);
});
}
},
hide
:
function
(
callback
)
{
if
(
callback
&&
callback
instanceof
Function
)
{
modal
.
on
(
'hide.bs.modal'
,
function
(
e
)
{
callback
(
e
);
});
}
}
};
},
dialog
:
function
(
options
)
{
options
=
$
.
extend
({},
{
title
:
'title'
,
url
:
''
,
width
:
800
,
height
:
550
,
onReady
:
function
()
{
},
onShown
:
function
(
e
)
{
}
},
options
||
{});
var
modalId
=
generateId
();
var
content
=
dialogdHtml
.
replace
(
reg
,
function
(
node
,
key
)
{
return
{
Id
:
modalId
,
Title
:
options
.
title
}[
key
];
});
$
(
'body'
).
append
(
content
);
var
target
=
$
(
'#'
+
modalId
);
target
.
find
(
'.modal-body'
).
load
(
options
.
url
);
if
(
options
.
onReady
())
options
.
onReady
.
call
(
target
);
target
.
modal
();
target
.
on
(
'shown.bs.modal'
,
function
(
e
)
{
if
(
options
.
onReady
(
e
))
options
.
onReady
.
call
(
target
,
e
);
});
target
.
on
(
'hide.bs.modal'
,
function
(
e
)
{
$
(
'body'
).
find
(
target
).
remove
();
});
}
}
}();
})(
jQuery
);
\ No newline at end of file
atms-web/src/main/webapp/app/admin/infrastructure/docManage/doc-manage.ctrl.js
View file @
462f5307
...
...
@@ -23,7 +23,6 @@
};
$scope
.
dataGridUpdate
=
function
(
_data
)
{
$scope
.
localData
=
_data
.
items
;
$scope
.
queryStatusType
(
$scope
.
localData
);
$scope
.
pagingOptions
=
{
totalItems
:
$scope
.
localData
.
length
,
//总数据
...
...
@@ -328,6 +327,9 @@
}
else
{
SweetAlert
.
warning
(
$translate
.
instant
(
'SaveFail'
));
}
if
(
data
.
code
==-
1
){
SweetAlert
.
warning
(
$translate
.
instant
(
data
.
message
));
}
});
$
(
'#editPopDialog'
).
modal
(
'hide'
);
};
...
...
atms-web/src/main/webapp/app/framework/app-usr-operate-log/app-usr-operate-log.ctrl.js
View file @
462f5307
...
...
@@ -19,7 +19,7 @@ frameworkModule.controller('appUsrOperateLogController',
}
});
}
if
(
$scope
.
thisModuleId
.
length
===
0
){
if
(
$
(
"body[ng-controller='AppController']"
).
length
==
1
&&
$
scope
.
thisModuleId
.
length
===
0
){
SweetAlert
.
warning
(
$translate
.
instant
(
"NeedChecked"
));
return
;
}
...
...
atms-web/src/main/webapp/app/taxDocumentManage/tax-document-list/tax-document-list.ctrl.js
View file @
462f5307
...
...
@@ -354,20 +354,26 @@ taxDocumentManageModule.controller('taxDocumentListController',
}
};
$scope
.
changeFieldModel
=
function
()
{
$scope
.
changeFieldModel
=
function
()
{
//新建记录
items
=
$scope
.
editFieldModel
;
var
items
=
$scope
.
editFieldModel
;
if
(
!
PWC
.
isNullOrEmpty
(
items
.
fileTime
)
&&
!
PWC
.
isNullOrEmpty
(
items
.
effectiveTime
)
&&
items
.
fileTime
>
items
.
effectiveTime
)
{
items
.
fileTime
>
items
.
effectiveTime
)
{
SweetAlert
.
warning
(
$translate
.
instant
(
'FileTimeDateRangeError'
));
}
};
$scope
.
changeFieldItem
=
function
()
{
//批量上传
items
=
$scope
.
editFieldItem
;
if
(
!
PWC
.
isNullOrEmpty
(
items
.
fileTime
)
&&
!
PWC
.
isNullOrEmpty
(
items
.
effectiveTime
)
&&
items
.
fileTime
>
items
.
effectiveTime
)
{
SweetAlert
.
warning
(
$translate
.
instant
(
'FileTimeDateRangeError'
));
if
(
$scope
.
multiUploadErrorItems
){
for
(
var
i
=
0
;
i
<
$scope
.
multiUploadErrorItems
.
length
;
i
++
)
{
var
modelItem
=
$scope
.
multiUploadErrorItems
[
i
];
if
(
!
PWC
.
isNullOrEmpty
(
modelItem
.
fileTime
)
&&
!
PWC
.
isNullOrEmpty
(
modelItem
.
effectiveTime
)
&&
modelItem
.
fileTime
>
modelItem
.
effectiveTime
)
{
SweetAlert
.
warning
(
$translate
.
instant
(
"Document"
)
+
(
i
+
1
)
+
","
+
$translate
.
instant
(
'FileTimeDateRangeError'
));
break
;
}
}
}
};
//弹出框
...
...
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