fix
Helius
2022-05-26 ae77dab1e92c795b21b26b2c1d2e0284ae918589
zq-erp/src/main/java/com/matrix/system/hive/service/imp/SysOrderServiceHelper.java
@@ -202,7 +202,7 @@
     */
    private boolean isGiftMoneyPay(SysOrder order) {
        BusParameterSettings giftiIsfree = busParameterSettingsDao.selectCompanyParamByCode(AppConstance.SHOP_MANAGE_GIFTISFREE, order.getCompanyId());
        if (giftiIsfree.getParamValue().equals("是")) {
        if (BooleanEnum.TRUE.getValue() == giftiIsfree.getIntParamValue()) {
            return order.getFlows().stream().allMatch(item -> SysOrderFlow.IS_GIFT_Y.equals(item.getIsGift())
                    && item.getAmount().doubleValue() > 0D);
        } else {
@@ -628,11 +628,19 @@
        for (SysOrderItem item : sysOrder.getItems()) {
            ShoppingGoods shoppingGoods = shoppingGoodsDao.selectById(item.getGoodsId());
            item.setType(shoppingGoods.getGoodType());
            if (item.getZkPrice() == null) {
                item.setZkPrice(shoppingGoods.getSealPice());
            }
            if (item.getZkPrice() == 0) {
                item.setIsFree(Dictionary.FLAG_YES);
            }
            Double itemZkTotal = MoneyUtil.mul(item.getZkPrice(), Double.valueOf(item.getCount()));
            zkTotal = MoneyUtil.add(zkTotal, itemZkTotal);
            if (item.getPrice() == null) {
                item.setPrice(shoppingGoods.getSealPice());
            }
            item.setStatus(Dictionary.ORDER_STATU_DFK);
            item.setRefundCount(0);
        }