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
f5c906d4
Commit
f5c906d4
authored
Jan 18, 2021
by
huluobin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
# fee
parent
7a018b0c
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
40 additions
and
17 deletions
+40
-17
ManageCostDto.java
...c/main/java/com/bailuntec/cost/api/dto/ManageCostDto.java
+0
-5
CostApiController.java
...m/blt/other/module/cost/controller/CostApiController.java
+0
-1
CostDao.java
.../src/main/java/com/blt/other/module/cost/dao/CostDao.java
+4
-0
CostDomain.java
...main/java/com/blt/other/module/cost/model/CostDomain.java
+3
-2
CostApiServiceImpl.java
...lt/other/module/cost/service/impl/CostApiServiceImpl.java
+24
-6
application-dev.yml
cost-service/src/main/resources/application-dev.yml
+1
-1
application-prod.yml
cost-service/src/main/resources/application-prod.yml
+1
-1
application-test.yml
cost-service/src/main/resources/application-test.yml
+1
-1
Cost.xml
cost-service/src/main/resources/mapper/Cost.xml
+6
-0
No files found.
cost-interfaces/src/main/java/com/bailuntec/cost/api/dto/ManageCostDto.java
View file @
f5c906d4
...
...
@@ -10,7 +10,6 @@ import java.util.Date;
@Data
public
class
ManageCostDto
{
@JSONField
(
name
=
"detailname"
)
// 费用单号或采购单号
private
String
no
;
...
...
@@ -29,7 +28,6 @@ public class ManageCostDto {
@JSONField
(
name
=
"cashier_time"
,
format
=
"yyyy-MM-dd HH:mm:ss"
)
// 付款时间
private
Date
payTime
;
// 费用付款单同cost_form=1,费用借还单同cost_form=3,采购单为0
private
Integer
manageCostType
;
// 部门
...
...
@@ -42,15 +40,12 @@ public class ManageCostDto {
private
String
feeSuperType
;
// 费用小类
private
String
feeSubType
;
// 金额
private
BigDecimal
amount
;
// 币种
private
String
currency
;
// 人民币金额
private
BigDecimal
amountRmb
;
//费用单Id
private
Integer
costId
;
//费用单详情Id
...
...
cost-service/src/main/java/com/blt/other/module/cost/controller/CostApiController.java
View file @
f5c906d4
...
...
@@ -70,7 +70,6 @@ public class CostApiController implements CostApi {
@Override
@PostMapping
(
"/manageCostList"
)
public
CostResult
<
List
<
ManageCostDto
>>
manageCostList
(
@RequestBody
ManageCostListReq
req
)
{
//todo
List
<
ManageCostDto
>
manageCostDtoList
=
costApiService
.
manageCostList
(
req
);
return
CostResult
.
success
(
manageCostDtoList
);
...
...
cost-service/src/main/java/com/blt/other/module/cost/dao/CostDao.java
View file @
f5c906d4
package
com
.
blt
.
other
.
module
.
cost
.
dao
;
import
com.bailuntec.cost.api.request.ManageCostListReq
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
...
...
@@ -75,4 +76,7 @@ public interface CostDao extends BaseMapper<CostDomain> {
//分页查询费用单
Page
<
CostDomain
>
queryPage
(
@Param
(
"page"
)
Page
<
Object
>
page
,
@Param
(
"req"
)
CostQueryPageReq
req
);
//管理成本的费用单
List
<
CostDomain
>
manageCostList
(
ManageCostListReq
req
);
}
cost-service/src/main/java/com/blt/other/module/cost/model/CostDomain.java
View file @
f5c906d4
...
...
@@ -263,6 +263,9 @@ public class CostDomain implements Serializable {
private
static
final
String
REGEX_CHINESE
=
"[\u4e00-\u9fa5]"
;
// 中文正则
private
final
static
List
<
String
>
picFilter
=
Lists
.
newArrayList
(
"png"
,
"jpg"
,
"bmp,"
,
"gif"
);
public
PostApplyReq
buildPostApplyReq
()
{
CostCompanyDao
costCompanyDao
=
SpringContextUtil
.
getBean
(
CostCompanyDao
.
class
);
...
...
@@ -390,8 +393,6 @@ public class CostDomain implements Serializable {
return
print
;
}
private
final
static
List
<
String
>
picFilter
=
Lists
.
newArrayList
(
"png"
,
"jpg"
,
"bmp,"
,
"gif"
);
public
CostDto
castToDto
()
{
...
...
cost-service/src/main/java/com/blt/other/module/cost/service/impl/CostApiServiceImpl.java
View file @
f5c906d4
...
...
@@ -24,8 +24,6 @@ import com.blt.other.module.cost.service.impl.costcheck.CostContext;
import
com.blt.other.module.cost.service.impl.costcheck.FinancialCheckState
;
import
com.blt.other.module.cost.utils.CostFileUtil
;
import
com.blt.other.module.cost.utils.CostUtils
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
...
...
@@ -39,7 +37,7 @@ import java.util.stream.Collectors;
@Service
public
class
CostApiServiceImpl
implements
CostApiService
{
private
static
Logger
logger
=
LoggerFactory
.
getLogger
(
CostApiServiceImpl
.
class
);
@Resource
private
CostDao
costDao
;
...
...
@@ -166,8 +164,6 @@ public class CostApiServiceImpl implements CostApiService {
@Resource
CostTypeDao
costTypeDao
;
@Resource
AccountingSubjectMapper
accountingSubjectMapper
;
@Resource
FinancialCheckState
financialCheckState
;
@Override
...
...
@@ -278,6 +274,28 @@ public class CostApiServiceImpl implements CostApiService {
@Override
public
List
<
ManageCostDto
>
manageCostList
(
ManageCostListReq
req
)
{
return
null
;
List
<
CostDomain
>
manageCostList
=
costDao
.
manageCostList
(
req
);
return
manageCostList
.
stream
()
.
map
(
costDomain
->
{
ManageCostDto
manageCostDto
=
new
ManageCostDto
();
manageCostDto
.
setAmount
(
costDomain
.
getAmount
());
manageCostDto
.
setAmountRmb
(
costDomain
.
getAmountRmb
());
manageCostDto
.
setCompanyName
(
costDomain
.
getCompanyName
());
manageCostDto
.
setCompanyValue
(
costDomain
.
getCompanyValue
());
manageCostDto
.
setCostId
(
costDomain
.
getId
());
manageCostDto
.
setCurrency
(
costDomain
.
getDic
());
manageCostDto
.
setManageCostType
(
costDomain
.
getCostForm
());
manageCostDto
.
setNo
(
costDomain
.
getCostNo
());
manageCostDto
.
setReason
(
costDomain
.
getCostReason
());
//银行卡四要素
manageCostDto
.
setReceiveBank
(
costDomain
.
getBankName
());
manageCostDto
.
setReceiveCard
(
costDomain
.
getBankCard
());
manageCostDto
.
setReceiveCardUser
(
costDomain
.
getBankCardUser
());
manageCostDto
.
setReceiveUnit
(
costDomain
.
getBankCompany
());
return
manageCostDto
;
})
.
collect
(
Collectors
.
toList
());
}
}
cost-service/src/main/resources/application-dev.yml
View file @
f5c906d4
...
...
@@ -85,4 +85,4 @@ cost:
server
:
port
:
8082
servlet
:
context-path
:
/purchase/other
context-path
:
/purchase/other
/v3.1
cost-service/src/main/resources/application-prod.yml
View file @
f5c906d4
...
...
@@ -83,4 +83,4 @@ cost:
server
:
port
:
8082
servlet
:
context-path
:
/purchase/other
context-path
:
/purchase/other
/v3.1
cost-service/src/main/resources/application-test.yml
View file @
f5c906d4
...
...
@@ -82,4 +82,4 @@ cost:
server
:
port
:
8082
servlet
:
context-path
:
/purchase/other
context-path
:
/purchase/other
/v3.1
cost-service/src/main/resources/mapper/Cost.xml
View file @
f5c906d4
...
...
@@ -344,5 +344,11 @@
ORDER BY
t1.id DESC
</select>
<select
id=
"manageCostList"
resultType=
"com.blt.other.module.cost.model.CostDomain"
>
select t1.*
from cost t1
left join cost_type ct on t1.type_id = ct.id
where ct.is_manage_cost = 1
</select>
</mapper>
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