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
c4500a86
Commit
c4500a86
authored
Feb 19, 2019
by
zhkwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CIT固定资产-资产清单补充及优化
parent
f70c2de7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
200 additions
and
13 deletions
+200
-13
AssetListController.java
...java/pwc/taxtech/atms/controller/AssetListController.java
+22
-2
AssetListServiceImpl.java
...a/pwc/taxtech/atms/service/impl/AssetListServiceImpl.java
+4
-3
CitAssetsListMapper.java
...c/main/java/pwc/taxtech/atms/dao/CitAssetsListMapper.java
+3
-0
CitAssetsListExtendsMapper.xml
...c/taxtech/atms/dao/extends/CitAssetsListExtendsMapper.xml
+161
-0
cit.json
atms-web/src/main/webapp/app-resources/i18n/en-us/cit.json
+3
-2
cit.json
atms-web/src/main/webapp/app-resources/i18n/zh-CN/cit.json
+2
-2
cit-import-asset-list.ctrl.js
...mport/cit-import-asset-list/cit-import-asset-list.ctrl.js
+5
-4
No files found.
atms-api/src/main/java/pwc/taxtech/atms/controller/AssetListController.java
View file @
c4500a86
...
@@ -134,20 +134,40 @@ public class AssetListController {
...
@@ -134,20 +134,40 @@ public class AssetListController {
}
}
}
}
/**
* 当保留差异全选或全反选选项变化时进行批量修改
* @param assetType
* @param projectId
* @param isRetain
* @return
*/
@RequestMapping
(
value
=
"batchUpdateIsRetain"
,
method
=
RequestMethod
.
POST
)
@RequestMapping
(
value
=
"batchUpdateIsRetain"
,
method
=
RequestMethod
.
POST
)
public
ApiResultDto
batchUpdateIsRetain
(
Integer
assetType
,
@RequestParam
String
projectId
,
@RequestParam
Integer
isRetain
){
public
ApiResultDto
batchUpdateIsRetain
(
Integer
assetType
,
@RequestParam
String
projectId
,
@RequestParam
Integer
isRetain
){
assetListService
.
batchUpdateIsRetain
(
assetType
,
projectId
,
isRetain
);
assetListService
.
batchUpdateIsRetain
(
assetType
,
projectId
,
isRetain
);
return
null
;
return
null
;
}
}
/**
* 保存资产分类(当对资产类别进行二级分类匹配完成后点击确定按钮所走的方法)
* @param assetGroupResults
* @param saveGroupType
* @param projectId
* @return
*/
@RequestMapping
(
value
=
"saveAssetGroupInfo"
,
method
=
RequestMethod
.
POST
)
@RequestMapping
(
value
=
"saveAssetGroupInfo"
,
method
=
RequestMethod
.
POST
)
public
ApiResultDto
saveAssetGroupInfo
(
@RequestBody
List
<
CitAssetGroupResult
>
assetGroupResults
,
public
ApiResultDto
saveAssetGroupInfo
(
@RequestBody
List
<
CitAssetGroupResult
>
assetGroupResults
,
@RequestParam
Integer
saveGroupType
,
@RequestParam
Integer
saveGroupType
,
@RequestParam
String
projectId
){
@RequestParam
String
projectId
){
assetListService
.
saveAssetGroupInfo
(
assetGroupResults
,
saveGroupType
,
projectId
);
return
null
;
return
assetListService
.
saveAssetGroupInfo
(
assetGroupResults
,
saveGroupType
,
projectId
)
;
}
}
/**
* 当资产清单Grid编辑进行保存所走的方法
* @param citAssetsLists
* @param projectId
* @return
*/
@RequestMapping
(
value
=
"updateAssetResultList"
,
method
=
RequestMethod
.
POST
)
@RequestMapping
(
value
=
"updateAssetResultList"
,
method
=
RequestMethod
.
POST
)
public
ApiResultDto
updateAssetResultList
(
@RequestBody
List
<
CitAssetsList
>
citAssetsLists
,
public
ApiResultDto
updateAssetResultList
(
@RequestBody
List
<
CitAssetsList
>
citAssetsLists
,
@RequestParam
String
projectId
){
@RequestParam
String
projectId
){
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/AssetListServiceImpl.java
View file @
c4500a86
...
@@ -199,9 +199,10 @@ public class AssetListServiceImpl extends BaseService {
...
@@ -199,9 +199,10 @@ public class AssetListServiceImpl extends BaseService {
//在循环存储新的资产之前先删除原有资产
//在循环存储新的资产之前先删除原有资产
deleteByExample
(
projectId
);
deleteByExample
(
projectId
);
//循环存储新的资产
//循环存储新的资产
for
(
CitAssetsList
citAsset
:
citAssetsLists
){
int
insertBatch
=
assetListMapper
.
insertBatch
(
citAssetsLists
);
assetListMapper
.
insertSelective
(
citAsset
);
// for (CitAssetsList citAsset : citAssetsLists){
}
// assetListMapper.insertSelective(citAsset);
// }
//处理资产类别
//处理资产类别
//1、根据projectId查询数据库中已有的资产类别,并和新导入的资产类别进行比较
//1、根据projectId查询数据库中已有的资产类别,并和新导入的资产类别进行比较
// for (CitAssetGroupResult groupResult : citAssetGroupResults) {
// for (CitAssetGroupResult groupResult : citAssetGroupResults) {
...
...
atms-dao/src/main/java/pwc/taxtech/atms/dao/CitAssetsListMapper.java
View file @
c4500a86
...
@@ -105,4 +105,6 @@ public interface CitAssetsListMapper extends MyMapper {
...
@@ -105,4 +105,6 @@ public interface CitAssetsListMapper extends MyMapper {
* @mbg.generated
* @mbg.generated
*/
*/
int
updateByPrimaryKey
(
CitAssetsList
record
);
int
updateByPrimaryKey
(
CitAssetsList
record
);
int
insertBatch
(
List
<
CitAssetsList
>
citAssetsLists
);
}
}
\ No newline at end of file
atms-dao/src/main/resources/pwc/taxtech/atms/dao/extends/CitAssetsListExtendsMapper.xml
0 → 100644
View file @
c4500a86
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"pwc.taxtech.atms.dao.CitAssetsListMapper"
>
<insert
id=
"insertBatch"
parameterType=
"java.util.List"
>
insert into balance_sheet_final
(
<include
refid=
"Base_Column_List"
/>
)
values
<foreach
collection=
"list"
item=
"item"
index=
"index"
separator=
","
>
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<choose>
<when
test=
"item.id != null"
>
#{item.id,jdbcType=BIGINT},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.projectId != null"
>
#{item.projectId,jdbcType=VARCHAR},
</when>
<otherwise>
'',
</otherwise>
</choose>
<choose>
<when
test=
"item.period != null"
>
#{item.period,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.assetNumber != null"
>
#{item.assetNumber,jdbcType=VARCHAR},
</when>
<otherwise>
'',
</otherwise>
</choose>
<choose>
<when
test=
"item.assetGroupName != null"
>
#{item.assetGroupName,jdbcType=VARCHAR},
</when>
<otherwise>
'',
</otherwise>
</choose>
<choose>
<when
test=
"item.assetDetailGroupId != null"
>
#{item.assetDetailGroupId,jdbcType=BIGINT},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.assetDescription != null"
>
#{item.assetDescription,jdbcType=VARCHAR},
</when>
<otherwise>
'',
</otherwise>
</choose>
<choose>
<when
test=
"item.buyDate != null"
>
#{item.buyDate,jdbcType=TIMESTAMP},
</when>
<otherwise>
CURRENT_TIMESTAMP,
</otherwise>
</choose>
<choose>
<when
test=
"item.depreciationDate != null"
>
#{item.depreciationDate,jdbcType=TIMESTAMP},
</when>
<otherwise>
CURRENT_TIMESTAMP,
</otherwise>
</choose>
<choose>
<when
test=
"item.depreciationPeriod != null"
>
#{item.depreciationPeriod,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.acquisitionValue != null"
>
#{item.acquisitionValue,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.adjustmentValue != null"
>
#{item.adjustmentValue,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.disposedDate != null"
>
#{item.disposedDate,jdbcType=TIMESTAMP},
</when>
<otherwise>
CURRENT_TIMESTAMP,
</otherwise>
</choose>
<choose>
<when
test=
"item.residualRate != null"
>
#{item.residualRate,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.yearDepreciationAmount != null"
>
#{item.yearDepreciationAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.yearAdjustmentAmount != null"
>
#{item.yearAdjustmentAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.yearEndValue != null"
>
#{item.yearEndValue,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.status != null"
>
#{item.status,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.accountAcquisitionValue != null"
>
#{item.accountAcquisitionValue,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.accountMonthDepreciationAmount != null"
>
#{item.accountMonthDepreciationAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.accountYearDepreciationAmount != null"
>
#{item.accountYearDepreciationAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.accountTotalDepreciationAmount != null"
>
#{item.accountTotalDepreciationAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxToLastYearDepreciationPeriod != null"
>
#{item.taxToLastYearDepreciationPeriod,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxToCurrentYearDepreciationPeriod != null"
>
#{item.taxToCurrentYearDepreciationPeriod,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxYearDepreciationPeriod != null"
>
#{item.taxYearDepreciationPeriod,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxMonthDepreciationAmount != null"
>
#{item.taxMonthDepreciationAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxToCurrentYearDepreciationAmount != null"
>
#{item.taxToCurrentYearDepreciationAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxCurrentYearDepreciationAmount != null"
>
#{item.taxCurrentYearDepreciationAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.totalDifferenceAmount != null"
>
#{item.totalDifferenceAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.yearDifferenceAmount != null"
>
#{item.yearDifferenceAmount,jdbcType=DECIMAL},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.isRetain != null"
>
#{item.isRetain,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.assetType != null"
>
#{item.assetType,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.createTime != null"
>
#{item.createTime,jdbcType=TIMESTAMP},
</when>
<otherwise>
CURRENT_TIMESTAMP,
</otherwise>
</choose>
<choose>
<when
test=
"item.updateTime != null"
>
#{item.updateTime,jdbcType=TIMESTAMP},
</when>
<otherwise>
CURRENT_TIMESTAMP,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxAccountCompare != null"
>
#{item.taxAccountCompare,jdbcType=INTEGER},
</when>
<otherwise>
0,
</otherwise>
</choose>
<choose>
<when
test=
"item.taxGroupName != null"
>
#{item.taxGroupName,jdbcType=VARCHAR},
</when>
<otherwise>
'',
</otherwise>
</choose>
</trim>
</foreach>
;
SELECT 1 FROM DUAL;
</insert>
</mapper>
\ No newline at end of file
atms-web/src/main/webapp/app-resources/i18n/en-us/cit.json
View file @
c4500a86
...
@@ -76,9 +76,9 @@
...
@@ -76,9 +76,9 @@
"toUpdate"
:
"To be updated"
,
"toUpdate"
:
"To be updated"
,
"~MustBeEndOneApp"
:
"I Must be the End One, please!"
,
"~MustBeEndOneApp"
:
"I Must be the End One, please!"
,
"isRetainDifference"
:
"保留差异"
,
"TaxAccountDifference"
:
"税会差异"
,
"TaxAccountDifference"
:
"税会差异"
,
"TaxDepreciation"
:
"会计折旧"
,
"TaxDepreciation"
:
"会计折旧"
,
"AccountDepreciation"
:
"税务折旧"
,
"AccountDepreciation"
:
"税务折旧"
,
"TaxGreaterAccount"
:
"会计折旧<=税务折旧"
,
"CitJournalAdjustImport"
:
"日记账调整-CIT"
"TaxLessAccount"
:
"会计折旧>税务折旧"
}
}
\ No newline at end of file
atms-web/src/main/webapp/app-resources/i18n/zh-CN/cit.json
View file @
c4500a86
...
@@ -81,11 +81,11 @@
...
@@ -81,11 +81,11 @@
"TaxGroupType"
:
"税法分类"
,
"TaxGroupType"
:
"税法分类"
,
"TaxToLastYearDepreciationPeriod"
:
"截止去年累计折旧期间"
,
"TaxToLastYearDepreciationPeriod"
:
"截止去年累计折旧期间"
,
"TaxToCurrentYearDepreciationPeriod"
:
"截止本年累计折旧期间"
,
"TaxToCurrentYearDepreciationPeriod"
:
"截止本年累计折旧期间"
,
"isRetainDifference"
:
"保留差异"
,
"TaxAccountDifference"
:
"税会差异"
,
"TaxAccountDifference"
:
"税会差异"
,
"TaxDepreciation"
:
"会计折旧"
,
"TaxDepreciation"
:
"会计折旧"
,
"AccountDepreciation"
:
"税务折旧"
,
"AccountDepreciation"
:
"税务折旧"
,
"TaxGreaterAccount"
:
"会计折旧<=税务折旧"
,
"CitJournalAdjustImport"
:
"日记账调整-CIT"
,
"TaxLessAccount"
:
"会计折旧>税务折旧"
,
"BuyDateType"
:
"日期错误"
,
"BuyDateType"
:
"日期错误"
,
"AssetNumberType"
:
"资产编号错误"
,
"AssetNumberType"
:
"资产编号错误"
,
"AssetGroupNameType"
:
"资产类别错误"
,
"AssetGroupNameType"
:
"资产类别错误"
,
...
...
atms-web/src/main/webapp/app/cit/import/cit-import-asset-list/cit-import-asset-list.ctrl.js
View file @
c4500a86
...
@@ -948,6 +948,7 @@
...
@@ -948,6 +948,7 @@
},
},
onCellPrepared
:
function
(
e
)
{
onCellPrepared
:
function
(
e
)
{
if
(
e
.
rowType
===
"header"
)
{
if
(
e
.
rowType
===
"header"
)
{
debugger
;
if
(
e
.
column
.
caption
===
$translate
.
instant
(
'ImportErrorPopUpNoCol'
)
||
if
(
e
.
column
.
caption
===
$translate
.
instant
(
'ImportErrorPopUpNoCol'
)
||
e
.
column
.
caption
===
$translate
.
instant
(
'AssetNumber'
)
||
e
.
column
.
caption
===
$translate
.
instant
(
'AssetNumber'
)
||
e
.
column
.
caption
===
$translate
.
instant
(
'AssetGroupName'
)
||
e
.
column
.
caption
===
$translate
.
instant
(
'AssetGroupName'
)
||
...
@@ -959,14 +960,14 @@
...
@@ -959,14 +960,14 @@
if
(
e
.
column
.
caption
===
$translate
.
instant
(
'IsRetain'
))
if
(
e
.
column
.
caption
===
$translate
.
instant
(
'IsRetain'
))
{
{
e
.
cellElement
.
empty
();
e
.
cellElement
.
empty
();
var
inputElement
=
$
(
'<input type="checkbox" ng-model="SelectAll" ng-click="selectAllAsset()">
保留差异
</input>'
);
var
inputElement
=
$
(
'<input type="checkbox" ng-model="SelectAll" ng-click="selectAllAsset()">
{{
\'
isRetainDifference
\'
| translate}}
</input>'
);
e
.
cellElement
.
addClass
(
'herder-center'
);
e
.
cellElement
.
addClass
(
'herder-center'
);
e
.
cellElement
.
append
(
$compile
(
inputElement
)(
$scope
));
e
.
cellElement
.
append
(
$compile
(
inputElement
)(
$scope
));
}
}
if
(
e
.
column
.
caption
===
$translate
.
instant
(
'IsRetain'
))
if
(
e
.
column
.
caption
===
$translate
.
instant
(
'IsRetain'
))
{
{
e
.
cellElement
.
empty
();
e
.
cellElement
.
empty
();
var
inputElement
=
$
(
'<input type="checkbox" ng-model="SelectAll" ng-click="selectAllAsset()">
保留差异
</input>'
);
var
inputElement
=
$
(
'<input type="checkbox" ng-model="SelectAll" ng-click="selectAllAsset()">
{{
\'
isRetainDifference
\'
| translate}}
</input>'
);
e
.
cellElement
.
addClass
(
'herder-center'
);
e
.
cellElement
.
addClass
(
'herder-center'
);
e
.
cellElement
.
append
(
$compile
(
inputElement
)(
$scope
));
e
.
cellElement
.
append
(
$compile
(
inputElement
)(
$scope
));
}
}
...
@@ -1035,10 +1036,10 @@
...
@@ -1035,10 +1036,10 @@
name
:
$translate
.
instant
(
'AllTheItems'
)
name
:
$translate
.
instant
(
'AllTheItems'
)
},
{
},
{
key
:
"0"
,
key
:
"0"
,
name
:
$translate
.
instant
(
'TaxDepreciation'
)
+
"<"
+
$translate
.
instant
(
'
Tax
Depreciation'
)
name
:
$translate
.
instant
(
'TaxDepreciation'
)
+
"<"
+
$translate
.
instant
(
'
Account
Depreciation'
)
},
{
},
{
key
:
"1"
,
key
:
"1"
,
name
:
$translate
.
instant
(
'TaxDepreciation'
)
+
">="
+
$translate
.
instant
(
'
Tax
Depreciation'
)
name
:
$translate
.
instant
(
'TaxDepreciation'
)
+
">="
+
$translate
.
instant
(
'
Account
Depreciation'
)
}];
}];
//初始化税会差异选项
//初始化税会差异选项
$scope
.
taxAccountDifferenceOptions
=
{
$scope
.
taxAccountDifferenceOptions
=
{
...
...
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