Commit 0427d8c7 authored by data-赵 玉龙's avatar data-赵 玉龙

新增现金白条账户

parent ad169629
......@@ -30,9 +30,9 @@ public class OfflineRapay {
* Tip: 对帐单时 只需修改currentMonth和payType
* currentMonth 当前是几月就输入几 无须减1 后续代码里面已经处理
*/
static Integer currentMonth = 11;
static Integer currentMonth = 7;
static PayType payType = PayType.YeePay_Xjd;
static PayType payType = PayType.WeiChat_BaiTiao_Cash;
static AbstractBills bill;
......
......@@ -29,9 +29,9 @@ public class RepayFinancialAPP {
* Tip: 对帐单时 只需修改currentMonth和payType
* currentMonth 当前是几月就输入几 无须减1 后续代码里面已经处理
*/
static Integer currentMonth = 2;
static Integer currentMonth = 7;
static PayType payType = PayType.YeePay_Xjd;
static PayType payType = PayType.WeiChat_BaiTiao_Cash;
static AbstractBills bill;
......@@ -54,17 +54,17 @@ public class RepayFinancialAPP {
clazz = UMPayBill.class;
break;
}
// // 拉取帐单前先清理目录
// if (!"易宝".equals(payType.getChannelName())) {
// if (Paths.get(path).toFile().exists()) {
// try {
// FileUtils.cleanDirectory(Paths.get(path).toFile());
// } catch (IOException e) {
// e.printStackTrace();
// }
// }
// bill.pullBills(payType);
// }
// 拉取帐单前先清理目录
if (!"易宝".equals(payType.getChannelName())) {
if (Paths.get(path).toFile().exists()) {
try {
FileUtils.cleanDirectory(Paths.get(path).toFile());
} catch (IOException e) {
e.printStackTrace();
}
}
bill.pullBills(payType);
}
}
public static void main(String[] args) throws Exception {
......
......@@ -47,8 +47,8 @@ public class RepayHandler {
public void repayBillDetailHandler(final String srcPaht,final Class<? extends Bill> clazz, String payAccount, Integer month) throws Exception {
List<Bill> bills = getBillsFromFile(srcPaht,clazz,payAccount,month);
if(!CollectionUtils.isEmpty(bills)){
asyncHandlerRepayData(clazz, bills);
count.await(); //等待所有线程结束
// asyncHandlerRepayData(clazz, bills);
// count.await(); //等待所有线程结束
}else{
throw new RuntimeException("没有读入任何账单");
......
......@@ -25,6 +25,12 @@ public enum PayType {
return Joiner.on(File.separator).join("weichat", "baitiao");
}
},
WeiChat_BaiTiao_Cash("微信", "微信-白条现金支付账户") {
@Override
public String path() {
return Joiner.on(File.separator).join("weichat", "baitiao_cash");
}
},
UMPay_Xjd("联动", "联动-现金贷账户") {
@Override
public String path() {
......
......@@ -42,9 +42,20 @@ public class WeichatBills extends AbstractBills {
weiChatBaitiaoInfo.put("nonce_str", "53E9BC685BF2CE47D4C064D3737F890B");
weiChatBaitiaoInfo.put("key", "53E9BC685BF2CE47D4C064D3737F890B");
Map<String, String> weiChatBaitiaoCashInfo = Maps.newLinkedHashMap();
weiChatBaitiaoCashInfo.put("appid", "wx7bf214ccdcbd2e16");
weiChatBaitiaoCashInfo.put("bill_date", billDate);
weiChatBaitiaoCashInfo.put("bill_type", "ALL");
weiChatBaitiaoCashInfo.put("mch_id", "1480390602");
weiChatBaitiaoCashInfo.put("nonce_str", "53E9BC685BF2CE47D4C064D3737F890B");
weiChatBaitiaoCashInfo.put("key", "UYu4Rpk08TdaFQLuKYsgF9eiCQ7U2TI1");
EnumMap<PayType, Map<String, String>> weiChatInfo = Maps.newEnumMap(PayType.class);
weiChatInfo.put(PayType.WeiChat_Xjd, weiChatXjdInfo);
weiChatInfo.put(PayType.WeiChat_BaiTiao, weiChatBaitiaoInfo);
weiChatInfo.put(PayType.WeiChat_BaiTiao_Cash, weiChatBaitiaoCashInfo);
return weiChatInfo;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment