Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
bailuntec-cost
Overview
Overview
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
huluobin
bailuntec-cost
Commits
ebf8776e
Commit
ebf8776e
authored
May 26, 2022
by
jianshuqin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加功能:费用单增加费用大类
parent
93687176
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
35 additions
and
2 deletions
+35
-2
CostTypeImportExcelItem.java
...ther/module/cost/dto/request/CostTypeImportExcelItem.java
+3
-0
CostDomain.java
...main/java/com/blt/other/module/cost/model/CostDomain.java
+2
-0
CostApiServiceImpl.java
...lt/other/module/cost/service/impl/CostApiServiceImpl.java
+2
-0
CostDetailServiceImpl.java
...other/module/cost/service/impl/CostDetailServiceImpl.java
+1
-0
CostTypeImportExcelItemListener.java
...le/cost/service/impl/CostTypeImportExcelItemListener.java
+1
-0
AbstractCostService.java
...er/module/cost/service/impl/cost/AbstractCostService.java
+1
-0
PayCostServiceImpl.java
...her/module/cost/service/impl/cost/PayCostServiceImpl.java
+1
-0
CostPlanNewLend1ServiceImpl.java
...st/service/impl/costplan/CostPlanNewLend1ServiceImpl.java
+4
-0
CostPlanNewLend2ServiceImpl.java
...st/service/impl/costplan/CostPlanNewLend2ServiceImpl.java
+10
-2
CostPlanNewPayServiceImpl.java
...cost/service/impl/costplan/CostPlanNewPayServiceImpl.java
+6
-0
CostPlanNewReceiptServiceImpl.java
.../service/impl/costplan/CostPlanNewReceiptServiceImpl.java
+4
-0
No files found.
cost-service/src/main/java/com/blt/other/module/cost/dto/request/CostTypeImportExcelItem.java
View file @
ebf8776e
...
...
@@ -19,6 +19,9 @@ public class CostTypeImportExcelItem {
@ExcelProperty
(
"费用类别"
)
private
String
typeName
;
@ExcelProperty
(
"费用大类"
)
private
String
categoryName
;
@ExcelProperty
(
"费用类别描述"
)
private
String
typeDesc
;
...
...
cost-service/src/main/java/com/blt/other/module/cost/model/CostDomain.java
View file @
ebf8776e
...
...
@@ -293,6 +293,7 @@ public class CostDomain implements Serializable {
this
.
setTypeId
(
costTypeDomain
.
getId
());
this
.
setTypeNo
(
costTypeDomain
.
getTypeNo
());
this
.
setTypeName
(
costTypeDomain
.
getTypeName
());
this
.
setCategoryName
(
costTypeDomain
.
getCategoryName
());
AccountingSubjectMapper
accountingSubjectMapper
=
SpringContextUtil
.
getBean
(
AccountingSubjectMapper
.
class
);
AccountingSubject
accountingSubject
=
accountingSubjectMapper
.
selectById
(
costTypeDomain
.
getAccountingSubjectId
());
...
...
@@ -357,6 +358,7 @@ public class CostDomain implements Serializable {
// 回调必要的key参数(DetailKey)不能为空;
req
.
setDetailKey
(
detailKey
);
req
.
setTypeName
(
this
.
getTypeName
());
req
.
setCategoryName
(
this
.
getCategoryName
());
req
.
setProject
(
this
.
getProject
());
req
.
setProjectDate
(
this
.
getProjectDate
());
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/CostApiServiceImpl.java
View file @
ebf8776e
...
...
@@ -200,6 +200,7 @@ public class CostApiServiceImpl implements CostApiService {
}
costDomain
.
setTypeNo
(
costTypeDomain
.
getTypeNo
());
costDomain
.
setTypeName
(
costTypeDomain
.
getTypeName
());
costDomain
.
setCategoryName
(
costTypeDomain
.
getCategoryName
());
costDomain
.
setAccountingSubjectId
(
costTypeDomain
.
getAccountingSubjectId
());
costDomain
.
setAccountingSubjectNo
(
costTypeDomain
.
getAccountingSubjectNo
());
costDomain
.
setNsAccountingSubjectId
(
costTypeDomain
.
getNsAccountingSubjectId
());
...
...
@@ -251,6 +252,7 @@ public class CostApiServiceImpl implements CostApiService {
}
costDomain
.
setTypeNo
(
costTypeDomain
.
getTypeNo
());
costDomain
.
setTypeName
(
costTypeDomain
.
getTypeName
());
costDomain
.
setCategoryName
(
costTypeDomain
.
getCategoryName
());
costDomain
.
setAccountingSubjectId
(
costTypeDomain
.
getAccountingSubjectId
());
costDomain
.
setAccountingSubjectNo
(
costTypeDomain
.
getAccountingSubjectNo
());
costDomain
.
setNsAccountingSubjectId
(
costTypeDomain
.
getNsAccountingSubjectId
());
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/CostDetailServiceImpl.java
View file @
ebf8776e
...
...
@@ -99,6 +99,7 @@ public class CostDetailServiceImpl extends ServiceImpl<CostDetailDao, CostDetail
costDetailDomain
.
setTypeId
(
costTypeDomain
.
getId
());
costDetailDomain
.
setTypeNo
(
costTypeDomain
.
getTypeNo
());
costDetailDomain
.
setTypeName
(
costTypeDomain
.
getTypeName
());
costDetailDomain
.
setCategoryName
(
costTypeDomain
.
getCategoryName
());
costDetailDomain
.
setAccountingSubjectNo
(
accountingSubject
.
getSubjectNo
());
costDetailDomain
.
setAccountingSubjectName
(
accountingSubject
.
getName
());
}
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/CostTypeImportExcelItemListener.java
View file @
ebf8776e
...
...
@@ -82,6 +82,7 @@ public class CostTypeImportExcelItemListener extends AnalysisEventListener<CostT
costTypeDomain
=
new
CostTypeDomain
();
costTypeDomain
.
setTypeNo
(
IdWorker
.
getIdStr
());
costTypeDomain
.
setTypeName
(
item
.
getTypeName
());
costTypeDomain
.
setCategoryName
(
item
.
getCategoryName
());
costTypeDomain
.
setDescription
(
item
.
getTypeDesc
());
costTypeDomain
.
setAccountingSubjectId
(
accountingSubject
.
getId
());
costTypeDomain
.
setCostTemplateType
(
costTemplateType
);
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/cost/AbstractCostService.java
View file @
ebf8776e
...
...
@@ -185,6 +185,7 @@ public abstract class AbstractCostService implements CostService {
if
(
accountingSubject
!=
null
)
{
costDomain
.
setTypeNo
(
costDomain
.
getTypeNo
());
costDomain
.
setTypeName
(
costTypeDomain
.
getTypeName
());
costDomain
.
setCategoryName
(
costTypeDomain
.
getCategoryName
());
costDomain
.
setAccountingSubjectNo
(
accountingSubject
.
getSubjectNo
());
costDomain
.
setAccountingSubjectName
(
accountingSubject
.
getName
());
}
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/cost/PayCostServiceImpl.java
View file @
ebf8776e
...
...
@@ -59,6 +59,7 @@ public class PayCostServiceImpl extends AbstractCostService implements CostServi
CostDetailDomain
detailDomain
=
cost
.
getCostDetailDomainList
().
get
(
0
);
req
.
setProject
(
detailDomain
.
getProject
());
req
.
setProjectDate
(
detailDomain
.
getProjectDate
());
req
.
setCategoryName
(
detailDomain
.
getCategoryName
());
}
log
.
info
(
"提交出纳参数:{}"
,
JsonUtilByFsJson
.
beanToJson
(
req
));
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/costplan/CostPlanNewLend1ServiceImpl.java
View file @
ebf8776e
package
com
.
blt
.
other
.
module
.
cost
.
service
.
impl
.
costplan
;
import
com.bailuntec.common.StringUtils
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.blt.other.common.exception.BizRuntimeException
;
import
com.blt.other.common.util.CurUtils
;
...
...
@@ -75,6 +76,9 @@ public class CostPlanNewLend1ServiceImpl extends AbstractCostPlanService impleme
BigDecimal
toRmbRate
=
CurUtils
.
getCur
(
costDomain
.
getDic
(),
"CNY"
);
costDomain
.
setToRmbRate
(
toRmbRate
);
costDomain
.
setAmountRmb
(
costDomain
.
getAmount
().
multiply
(
toRmbRate
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
));
if
(
StringUtils
.
isBlank
(
costDomain
.
getCategoryName
())){
costDomain
.
setCategoryName
((
StringUtils
.
isNotBlank
(
costDomain
.
getProject
())
&&
!
costDomain
.
getProject
().
equals
(
"集团"
)
?
"管理成本"
:
"日常费用"
));
}
int
insert
=
costDao
.
insert
(
costDomain
);
costLogService
.
save
(
costDomain
.
getCostNo
(),
costDomain
.
getCreateUserid
(),
"由费用计划:"
+
costDomain
.
getCostPlanNo
()
+
" 生成借支单"
);
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/costplan/CostPlanNewLend2ServiceImpl.java
View file @
ebf8776e
package
com
.
blt
.
other
.
module
.
cost
.
service
.
impl
.
costplan
;
import
com.bailuntec.common.StringUtils
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.blt.other.common.exception.BizRuntimeException
;
import
com.blt.other.common.util.CurUtils
;
...
...
@@ -102,7 +103,9 @@ public class CostPlanNewLend2ServiceImpl extends AbstractCostPlanService impleme
BigDecimal
toRmbRate
=
CurUtils
.
getCur
(
costDomain
.
getDic
(),
"CNY"
);
costDomain
.
setToRmbRate
(
toRmbRate
);
costDomain
.
setAmountRmb
(
costDomain
.
getAmount
().
multiply
(
toRmbRate
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
));
if
(
StringUtils
.
isBlank
(
costDomain
.
getCategoryName
())){
costDomain
.
setCategoryName
((
StringUtils
.
isNotBlank
(
costDomain
.
getProject
())
&&
!
costDomain
.
getProject
().
equals
(
"集团"
)
?
"管理成本"
:
"日常费用"
));
}
costDao
.
insert
(
costDomain
);
//更新借支单申请归还金额
...
...
@@ -128,6 +131,9 @@ public class CostPlanNewLend2ServiceImpl extends AbstractCostPlanService impleme
BigDecimal
toRmbRate
=
CurUtils
.
getCur
(
costDomain
.
getDic
(),
"CNY"
);
costDomain
.
setToRmbRate
(
toRmbRate
);
costDomain
.
setAmountRmb
(
costDomain
.
getAmount
().
multiply
(
toRmbRate
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
));
if
(
StringUtils
.
isNotBlank
(
costDomain
.
getCategoryName
())){
costDomain
.
setCategoryName
((
StringUtils
.
isNotBlank
(
costDomain
.
getProject
())
&&
!
costDomain
.
getProject
().
equals
(
"集团"
)
?
"管理成本"
:
"日常费用"
));
}
costDao
.
insert
(
costDomain
);
...
...
@@ -225,7 +231,9 @@ public class CostPlanNewLend2ServiceImpl extends AbstractCostPlanService impleme
BigDecimal
toRmbRate1
=
CurUtils
.
getCur
(
costDomain
.
getDic
(),
"CNY"
);
costDomain
.
setToRmbRate
(
toRmbRate1
);
costDomain
.
setAmountRmb
(
costDomain
.
getAmount
().
multiply
(
toRmbRate1
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
));
if
(
StringUtils
.
isBlank
(
costDomain
.
getCategoryName
())){
costDomain
.
setCategoryName
((
StringUtils
.
isNotBlank
(
costDomain
.
getProject
())
&&
!
costDomain
.
getProject
().
equals
(
"集团"
)
?
"管理成本"
:
"日常费用"
));
}
costDao
.
insert
(
costDomain
);
//更新借支单申请归还金额
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/costplan/CostPlanNewPayServiceImpl.java
View file @
ebf8776e
package
com
.
blt
.
other
.
module
.
cost
.
service
.
impl
.
costplan
;
import
com.bailuntec.common.StringUtils
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.blt.other.common.exception.BizRuntimeException
;
import
com.blt.other.common.util.CurUtils
;
...
...
@@ -124,6 +125,11 @@ public class CostPlanNewPayServiceImpl extends AbstractCostPlanService implement
// 生成付款费用详情单
for
(
CostDetailDomain
costDetail
:
costDetailDomains
)
{
costDetail
.
setCostNo
(
costNo
);
if
(
StringUtils
.
isNotBlank
(
costTypeDomain
.
getCategoryName
())){
costDetail
.
setCategoryName
(
costTypeDomain
.
getCategoryName
());
}
else
{
costDetail
.
setCategoryName
((
StringUtils
.
isNotBlank
(
costDetail
.
getProject
())
&&
!
costDetail
.
getProject
().
equals
(
"集团"
)
?
"管理成本"
:
"日常费用"
));
}
// 生成付款费用详情
costDetailDao
.
insert
(
costDetail
);
}
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/costplan/CostPlanNewReceiptServiceImpl.java
View file @
ebf8776e
package
com
.
blt
.
other
.
module
.
cost
.
service
.
impl
.
costplan
;
import
com.bailuntec.common.StringUtils
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.blt.other.common.exception.BizRuntimeException
;
import
com.blt.other.common.util.CurUtils
;
...
...
@@ -75,6 +76,9 @@ public class CostPlanNewReceiptServiceImpl extends AbstractCostPlanService imple
BigDecimal
toRmbRate
=
CurUtils
.
getCur
(
costDomain
.
getDic
(),
"CNY"
);
costDomain
.
setToRmbRate
(
toRmbRate
);
costDomain
.
setAmountRmb
(
costDomain
.
getAmount
().
multiply
(
toRmbRate
).
setScale
(
2
,
BigDecimal
.
ROUND_HALF_UP
));
if
(
StringUtils
.
isBlank
(
costDomain
.
getCategoryName
())){
costDomain
.
setCategoryName
((
StringUtils
.
isNotBlank
(
costDomain
.
getProject
())
&&
!
costDomain
.
getProject
().
equals
(
"集团"
)
?
"管理成本"
:
"日常费用"
));
}
Integer
insert
=
costDao
.
insert
(
costDomain
);
// 记录日志
...
...
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