xhxu 5 лет назад
Родитель
Сommit
4a22379aa8
1 измененных файлов: 11 добавлений и 2 удалений
  1. +11
    -2
      mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java

+ 11
- 2
mallinkService/src/main/java/com/iformall/service/impl/WxRentContractServiceImpl.java Просмотреть файл

@@ -1229,9 +1229,10 @@ public class WxRentContractServiceImpl implements WxRentContractService {
a = new BigDecimal(rentPrice1).divide(new BigDecimal(100));
}
String otherRentPriceInfo1 = wxRentContract.getOtherRentPriceInfo();
logger.info("why----error---"+otherRentPriceInfo1);
if(StringUtils.isNotBlank(otherRentPriceInfo1)){
// JSONObject jsonObject = new JSONObject(otherRentPriceInfo1);
if(otherRentPriceInfo1.startsWith("\"")){
otherRentPriceInfo1 = otherRentPriceInfo1.substring(1,otherRentPriceInfo1.length()-1);
}
JSONObject jsonObject = JSONObject.parseObject(otherRentPriceInfo1);
String siteMoney1 = jsonObject.getString("siteMoney");
if(StringUtils.isNotBlank(siteMoney1)){
@@ -2710,4 +2711,12 @@ public class WxRentContractServiceImpl implements WxRentContractService {
return exists;
}


public static void main(String[] args) {
String s = "{\"siteMoney\":\"2\",\"facilityMoney\":\"3\",\"administratorMoney\":\"4\"}";
JSONObject jsonObject = JSONObject.parseObject(s);
String siteMoney = jsonObject.getString("siteMoney");
System.out.println(siteMoney);
}

}

Загрузка…
Отмена
Сохранить