ソースを参照

修复 修改金额bug

weiximei 6 年 前
コミット
d4d20a9d26

+ 1
- 1
CODE/smart-community/property-api/src/main/java/com/community/huiju/controller/BillInvoiceController.java ファイルの表示

@@ -163,7 +163,7 @@ public class BillInvoiceController extends BaseController {
163 163
         ResponseBean responseBean = new ResponseBean();
164 164
         UserElement userElement = getUserElement(session);
165 165
         Integer payPrice = JSONObject.parseObject(parameter).getInteger("payPrice");
166
-        iBillInvoiceService.updateBillInvoiceIdPayPrice(billId, payPrice , userElement);
166
+        responseBean = iBillInvoiceService.updateBillInvoiceIdPayPrice(billId, payPrice , userElement);
167 167
         return responseBean;
168 168
     }
169 169
 

+ 4
- 0
CODE/smart-community/property-api/src/main/java/com/community/huiju/service/impl/BillInvoiceServiceImpl.java ファイルの表示

@@ -281,6 +281,10 @@ public class BillInvoiceServiceImpl extends ServiceImpl<BillInvoiceMapper, BillI
281 281
     public ResponseBean updateBillInvoiceIdPayPrice(Integer billId, Integer payPrice, UserElement userElement) {
282 282
         ResponseBean responseBean = new ResponseBean();
283 283
         BillInvoice billInvoice = billInvoiceMapper.selectById(billId);
284
+        if ("1".equals(billInvoice.getBillStatus()) || "2".equals(billInvoice.getBillStatus())) {
285
+            responseBean.addError("不能修改已缴费");
286
+            return responseBean;
287
+        }
284 288
         billInvoice.setPayPrice(PayPriceUtils.yuanConversionPoints(payPrice));
285 289
         billInvoice.setUpdateUser(userElement.getId());
286 290
         billInvoice.setUpdateDate(new Date());