Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
financial-tools
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
QG
financial-tools
Commits
71cd19b6
Commit
71cd19b6
authored
Jan 12, 2017
by
data-赵 玉龙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化
parent
35c8969d
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
23 additions
and
10 deletions
+23
-10
DifCheckOutAPP.java
src/main/java/cn/gq/financial/app/DifCheckOutAPP.java
+2
-2
RepayFinancialAPP.java
src/main/java/cn/gq/financial/app/RepayFinancialAPP.java
+2
-2
DifCheckOutHandler.java
.../java/cn/gq/financial/app/handler/DifCheckOutHandler.java
+4
-3
UMPayBill.java
src/main/java/cn/gq/financial/model/bill/UMPayBill.java
+10
-1
BillParsers.java
src/main/java/cn/gq/financial/utils/BillParsers.java
+5
-2
No files found.
src/main/java/cn/gq/financial/app/DifCheckOutAPP.java
View file @
71cd19b6
...
...
@@ -31,8 +31,8 @@ public class DifCheckOutAPP {
private
static
ClassPathXmlApplicationContext
context
=
null
;
public
static
void
main
(
String
[]
args
)
throws
Exception
{
List
<
Bill
>
bills
=
CountTotal
.
getBillsFromFile
(
"E:\\financial-system-data\\
yeepay\\baitiao"
,
YeepayBill
.
class
,
"ױ-˻"
,
11
);
getSpringContext
().
getBean
(
DifCheckOutHandler
.
class
).
checkDif
(
bills
);
List
<
Bill
>
bills
=
CountTotal
.
getBillsFromFile
(
"E:\\financial-system-data\\
umpay\\baitiao"
,
YeepayBill
.
class
,
"联动-白条账户"
,
12
);
getSpringContext
().
getBean
(
DifCheckOutHandler
.
class
).
checkDif
(
bills
,
"E:\\financial-system-data\\umpay\\baitiao\\丢失的.txt"
);
closeContext
();
}
...
...
src/main/java/cn/gq/financial/app/RepayFinancialAPP.java
View file @
71cd19b6
...
...
@@ -29,9 +29,9 @@ public class RepayFinancialAPP {
* Tip: 对帐单时 只需修改currentMonth和payType
* currentMonth 当前是几月就输入几 无须减1 后续代码里面已经处理
*/
static
Integer
currentMonth
=
12
;
static
Integer
currentMonth
=
8
;
static
PayType
payType
=
PayType
.
YeePay_
BaiTiao
;
static
PayType
payType
=
PayType
.
YeePay_
Xjd
;
static
AbstractBills
bill
;
...
...
src/main/java/cn/gq/financial/app/handler/DifCheckOutHandler.java
View file @
71cd19b6
...
...
@@ -5,6 +5,7 @@ import cn.gq.financial.db.local.dao.RepayDetailFinancialEntityMapper;
import
cn.gq.financial.db.local.model.RepayDetailFinancialEntity
;
import
cn.gq.financial.db.local.model.RepayDetailFinancialEntityExample
;
import
cn.gq.financial.model.bill.Bill
;
import
cn.gq.financial.model.bill.UMPayBill
;
import
cn.gq.financial.model.bill.WXBill
;
import
cn.gq.financial.model.bill.YeepayBill
;
import
cn.gq.financial.utils.FileUtils
;
...
...
@@ -31,7 +32,7 @@ public class DifCheckOutHandler {
@Autowired
RepayDetailFinancialEntityMapper
repayDetailFinancialEntityMapper
;
public
void
checkDif
(
List
<?
extends
Bill
>
bills
)
throws
Exception
{
public
void
checkDif
(
List
<?
extends
Bill
>
bills
,
String
toFile
)
throws
Exception
{
List
<
String
>
wrong
=
new
ArrayList
<>();
if
(
bills
.
size
()<
item_size
){
wrong
.
addAll
(
checkOut
(
bills
));
...
...
@@ -45,7 +46,7 @@ public class DifCheckOutHandler {
wrong
.
addAll
(
checkOut
(
bills
.
subList
((
i
*
item_size
),
bills
.
size
())));
}
}
FileUtils
.
writeOutStrsToFile
(
wrong
,
"E:\\financial-system-data\\yeepay\\baitiao\\丢失的.txt"
);
FileUtils
.
writeOutStrsToFile
(
wrong
,
toFile
);
}
private
Collection
<?
extends
String
>
checkOut
(
List
<?
extends
Bill
>
bills
)
{
...
...
@@ -68,7 +69,7 @@ public class DifCheckOutHandler {
}
}
else
{
// res.add("订单-->".concat(bill.getOrderId()).concat(" 详细丢失了,交易时间-->").concat(DateFormatUtils.ISO_DATE_FORMAT.format(bill.getTrandingDate())));
res
.
add
(((
Yeep
ayBill
)
bill
).
getSrcStr
());
res
.
add
(((
UMP
ayBill
)
bill
).
getSrcStr
());
}
});
...
...
src/main/java/cn/gq/financial/model/bill/UMPayBill.java
View file @
71cd19b6
...
...
@@ -16,8 +16,17 @@ public class UMPayBill extends Bill {
private
String
phoneNo
;
private
String
transStatus
;
//交易状态,TRANS_SUCCESS,TRANS_FAIL
private
String
srcStr
;
public
String
getPhoneNo
()
{
public
String
getSrcStr
()
{
return
srcStr
;
}
public
void
setSrcStr
(
String
srcStr
)
{
this
.
srcStr
=
srcStr
;
}
public
String
getPhoneNo
()
{
return
phoneNo
;
}
...
...
src/main/java/cn/gq/financial/utils/BillParsers.java
View file @
71cd19b6
...
...
@@ -94,6 +94,7 @@ public class BillParsers {
bill
.
setOrderId
(
split
[
3
].
trim
());
bill
.
setPhoneNo
(
split
[
2
].
trim
());
bill
.
setTransStatus
(
split
[
11
].
trim
());
bill
.
setSrcStr
(
line
);
return
bill
;
}
...
...
@@ -167,10 +168,12 @@ public class BillParsers {
}
if
(
contents
[
1
].
contains
(
"."
)){
yeepayBill
.
setTrandingDate
(
DateUtils
.
parseDate
(
contents
[
1
],
"yyyy-MM-dd HH:mm:ss.SSS"
));
}
else
{
}
else
if
(
contents
[
1
].
length
()>=
18
)
{
//yeepayBill.setTrandingDate(DateUtils.parseDate(contents[1], "yyyy-MM-dd HH:mm:ss.SSS"));
yeepayBill
.
setTrandingDate
(
DateUtils
.
parseDate
(
contents
[
1
],
"yyyy-MM-dd HH:mm:ss"
));
}
}
else
{
yeepayBill
.
setTrandingDate
(
DateUtils
.
parseDate
(
contents
[
1
],
"yyyy-MM-dd HH:mm"
));
}
yeepayBill
.
setAccountType
(
contents
[
2
]);
yeepayBill
.
setBizType
(
contents
[
3
]);
if
(
StringUtils
.
isNotBlank
(
contents
[
4
]))
{
...
...
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