From 1767cb98e9f7cbaabedd5f9433c5ed0f492de4d1 Mon Sep 17 00:00:00 2001 From: yixian Date: Mon, 20 Jul 2020 15:50:24 +1000 Subject: [PATCH] =?UTF-8?q?addressInfo=20in=20bttps=20file=20=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E5=AE=B9=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../payment/manage/analysis/beans/ato/AddressInfo.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/beans/ato/AddressInfo.java b/src/main/java/au/com/royalpay/payment/manage/analysis/beans/ato/AddressInfo.java index 02ac63210..0c79f941e 100644 --- a/src/main/java/au/com/royalpay/payment/manage/analysis/beans/ato/AddressInfo.java +++ b/src/main/java/au/com/royalpay/payment/manage/analysis/beans/ato/AddressInfo.java @@ -13,6 +13,7 @@ public class AddressInfo { public AddressInfo(String address, String suburb, String state, String postCode, String country) { this.address = address; this.suburb = suburb; + postCode = postCode.replaceAll("\\D", ""); if (!postCode.matches("^\\d{4}$")) { postCode = "9999"; country = "OTH"; @@ -24,7 +25,9 @@ public class AddressInfo { postCode = "9999"; } this.postCode = postCode; - this.state = state; + if (state != null) { + this.state = state.toUpperCase(); + } this.country = country; }