Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HikariPool hot reload exception #11

Open
CrossLee opened this issue May 8, 2019 · 4 comments
Open

HikariPool hot reload exception #11

CrossLee opened this issue May 8, 2019 · 4 comments
Assignees

Comments

@CrossLee
Copy link

CrossLee commented May 8, 2019

错误信息:

2019-05-08 11:29:39,999 INFO  a.a.App@[cli-thread-2] - App starting ....
2019-05-08 11:29:40,007 INFO  c.z.h.HikariDataSource@[cli-thread-2] - HikariPool-6 - Shutdown initiated...
2019-05-08 11:29:40,008 WARN  c.z.h.HikariDataSource@[cli-thread-2] - HikariPool-6 - Interrupted during closing
java.lang.InterruptedException: null
	at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2067)
	at java.util.concurrent.ThreadPoolExecutor.awaitTermination(ThreadPoolExecutor.java:1475)
	at com.zaxxer.hikari.pool.HikariPool.shutdown(HikariPool.java:241)
	at com.zaxxer.hikari.HikariDataSource.close(HikariDataSource.java:382)
	at act.db.sql.datasource.HikariDataSourceProvider.release(HikariDataSourceProvider.java:142)
	at act.db.sql.datasource.HikariDataSourceProvider.releaseResources(HikariDataSourceProvider.java:119)
	at act.util.DestroyableBase.destroy(DestroyableBase.java:53)
	at act.db.sql.SqlDbService.releaseResources(SqlDbService.java:219)
	at act.db.beetlsql.BeetlSqlService.releaseResources(BeetlSqlService.java:129)
	at act.util.LogSupportedDestroyableBase.destroy(LogSupportedDestroyableBase.java:52)
	at act.Destroyable$Util.tryDestroyAll(Destroyable.java:95)
	at act.app.DbServiceManager.releaseResources(DbServiceManager.java:160)
	at act.util.LogSupportedDestroyableBase.destroy(LogSupportedDestroyableBase.java:52)
	at act.Destroyable$Util.destroyAll(Destroyable.java:59)
	at act.app.AppServiceRegistry.destroy(AppServiceRegistry.java:84)
	at act.app.App.clearServiceResourceManager(App.java:1503)
	at act.app.App.initServiceResourceManager(App.java:1496)
	at act.app.App.refresh(App.java:686)
	at act.app.App.refresh(App.java:662)
	at act.app.App.checkUpdates(App.java:542)
	at act.app.App.checkUpdatesNonBlock(App.java:516)
	at act.app.CliServer$1.run(CliServer.java:156)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
2019-05-08 11:29:40,009 INFO  a.a.App@[cli-thread-2] - App shutting down ....
2019-05-08 11:29:40,047 INFO  a.a.DbServiceManager@[cli-thread-2] - db service[default] initialized
五月 08, 2019 11:29:40 上午 act.db.sql.util.EbeanAgentLoader loadAgent
信息: dynamically loading javaagent for /Users/cross/.m2/repository/org/avaje/ebean/ebean-agent/8.1.1/ebean-agent-8.1.1.jar
premain loading Transformer with args:debug=1;packages=com.cross.voicetodo
2019-05-08 11:29:40,554 WARN  a.Act@[jobs-thread-1] - JDBC driver not configured, system automatically set to: com.mysql.cj.jdbc.Driver
2019-05-08 11:29:40,560 WARN  a.m.MailerConfig@[cli-thread-2] - smtp host configuration not found, will use mock smtp to send email
2019-05-08 11:29:40,560 INFO  c.z.h.HikariDataSource@[jobs-thread-1] - HikariPool-7 - Starting...
2019-05-08 11:29:40,565 INFO  c.z.h.HikariDataSource@[jobs-thread-1] - HikariPool-7 - Start completed.
BeetlSQL 运行在 product=false,md charset=UTF-8
2019-05-08 11:29:40,938 INFO  a.a.App@[jobs-thread-4] - App[voicetodo] reloaded in 939ms

2019-05-08 11:29:40,946 DEBUG c.c.v.j.UpdateAccessToken@[jobs-thread-6] - 开始更新微信AccessToken...
2019-05-08 11:29:40,949 INFO  a.a.ApiManager@[jobs-thread-4] - start compiling API book
2019-05-08 11:29:40,997 INFO  a.a.ApiManager@[jobs-thread-4] - API book compiled
2019-05-08 11:29:41,382 DEBUG c.c.v.j.UpdateAccessToken@[jobs-thread-6] - 更新微信AccessToken完毕
@greenlaw110 greenlaw110 changed the title HikariPool HotReload错误 HikariPool hot reload exception Jun 16, 2019
@greenlaw110
Copy link
Contributor

@CrossLee I couldn't reproduce this issue. I run https://github.com/act-gallery/todo-beetlsql in dev mode, then update the source code. The project triggered hot reload without problem.

Are you consistently get the error in your project? Can you please report version of act and act-beetlsql?

@CrossLee
Copy link
Author

CrossLee commented Aug 8, 2019

GitHub怎么没有提醒我这里有更新,好像过去蛮久了。。。
之前在1.8.19出现的,后来版本生了主题中的错误不在出现了。
现在act-starter-parent 1.8.25.0在热加载的时候,job里会出现如下情况:

Hot Reload,重启的时候把HikariPool-1 shutdown了,然后起了个HikariPool-2。然后job那边报错,HikariPool-1已经closed了,怎么还是用的pool-1?

image
image

@greenlaw110
Copy link
Contributor

greenlaw110 commented Aug 27, 2019

@CrossLee 能把错误栈给全吗? 另外 JedisPopJob 里面是如何调用到 beetlsql 的 Mapper 的? 相关代码能不能提供一下?

@CrossLee
Copy link
Author

CrossLee commented Aug 27, 2019

代码在这里,错误信息明天重现后发出来。

package cn.com.youkuaijia.job;

import act.Act;
import act.job.OnAppStart;
import cn.com.youkuaijia.constant.Constants;
import cn.com.youkuaijia.controller.socket.WSNotificationTool;
import cn.com.youkuaijia.dao.Bustaffmapper;
import cn.com.youkuaijia.dao.Jiayouordermapper;
import cn.com.youkuaijia.dao.Printermapper;
import cn.com.youkuaijia.dao.Printeryouqiangmapper;
import cn.com.youkuaijia.model.Bustaffentity;
import cn.com.youkuaijia.model.Jiayouorderentity;
import cn.com.youkuaijia.model.Printerentity;
import cn.com.youkuaijia.model.Printeryouqiangentity;
import cn.com.youkuaijia.pojo.PrinterObjectPojo;
import cn.com.youkuaijia.pojo.TTSMessagePojo;
import cn.com.youkuaijia.util.*;
import com.alibaba.fastjson.JSON;
import org.osgl.logging.L;
import org.osgl.logging.Logger;
import org.osgl.util.S;

import javax.inject.Inject;
import java.util.Calendar;
import java.util.List;
import java.util.Map;

import static cn.com.youkuaijia.constant.Constants.BAIDU_TTS_TOKEN;

/**
 * Created by cross on 2018/11/10.
 */
public class JedisPopJob {

    private Logger logger = L.get(JedisPopJob.class);

    @Inject
    private Jiayouordermapper jiayouordermapper;
    @Inject
    private Printermapper printermapper;
    @Inject
    private Printeryouqiangmapper printeryouqiangmapper;
    @Inject
    private Bustaffmapper bustaffmapper;

    @OnAppStart(async = true)
    public void printAndBellPopJob() {

        JedisProcessUtil jedisUtil = Act.getInstance(JedisProcessUtil.class);
        // 检测Redis是否启动
        if (!jedisUtil.check()) {
            logger.error("[printAndBellPopJob] Redis is not running, please start redis!!!");
            return;
        }

        List<String> list;
        String data;
        Map<String, String> dataMap;
        Jiayouorderentity order;

        while (true) {
            try {
                list = jedisUtil.jedisBRPop();
                if (list == null || list.size() == 0) {
                    continue;
                }
                logger.info("[printAndBellPopJob]队列拿出的数据 : [key=%s][value=%s]", list.get(0), list.get(1));
                data = list.get(1);
                dataMap = JSON.parseObject(data, Map.class);
                String orderId = dataMap.get("orderId");
                String stationId = dataMap.get("stationId");
                String youqiangId = dataMap.get("youqiangId");
                String stationName = dataMap.get("stationName");
                String staffName = dataMap.get("staffName");
                String wxfwsEnabled = dataMap.get("wxfwsEnabled");
                String gasType = dataMap.get("gasType");
                String broadcastEnabled = dataMap.get("broadcastEnabled");
                String printerEnabled = dataMap.get("printerEnabled");
                String sunmitPrinterEnabled = dataMap.get("sunmitPrinterEnabled");
                String sunmitBroadcastEnabled = dataMap.get("sunmitBroadcastEnabled");

                // 如果加油站都没有启用,则无需打印小票或者播放语音
                if (S.notEqual("1", broadcastEnabled) && S.notEqual("1", printerEnabled) && S.notEqual("1", sunmitPrinterEnabled) && S.notEqual("1", sunmitBroadcastEnabled)) {
                    logger.warn("[printAndBellPopJob]无需打印小票和播放语音, stationId=%s, youqiangId=%s", stationId, youqiangId);
                    continue;
                }

                order = jiayouordermapper.unique(orderId);
                if (order.getPrinterConfirmed() == 1 && order.getBroadcastConfirmed() == 1) {
                    logger.info("[printAndBellPopJob][orderId=%s], 已经打印过了, 语音播报过了");
                    continue;
                }

                // 处理打印业务
                /*** 情况1:飞鹅打印开关:开,订单状态:没有打印 ***/
                if (S.eq(printerEnabled, "1")) {
                    if(order.getPrinterConfirmed() != 1) {
                        // 首先根据员工查询飞鹅小票机,如果员工有对应的小票机则优先使用员工的小票机
                        if (order.getBuStaffId() > 0) {
                            Bustaffentity buStaff = bustaffmapper.unique(order.getBuStaffId());
                            if (buStaff.getPrinterEnabled() == 1) {
                                String printerSn = buStaff.getPrinterSn();
                                String printerKey = buStaff.getPrinterKey();

                                // 如果key和sn不相同,则使用飞鹅
                                if (S.neq(printerKey, printerSn)) {
                                    PrinterObjectPojo pojo = genPojo(order, stationName, wxfwsEnabled, printerSn, printerKey);
                                    String result = PrinterTool.printJiayouOrder(pojo);
                                    Map<String, String> resultMap = JSON.parseObject(result, Map.class);
                                    String msg = resultMap.get("msg");
                                    if (msg.equals("ok")) {
                                        logger.info("[printAndBellPopJob]使用员工码对应飞鹅小票机打印成功, orderId=%s", orderId);
                                        order.setPrinterConfirmed(1);
                                    } else {
                                        logger.warn("[printAndBellPopJob]使用员工码对应飞鹅小票机打印失败, msg:%s", msg);
                                    }
                                }
                            } else {
                                logger.info("[printAndBellPopJob]此订单为员工码订单,但是员工码打印功能未启用。");
                            }
                        } else {
                            // 使用油枪号对应的飞鹅小票机打印
                            Printeryouqiangentity entity = printeryouqiangmapper.createLambdaQuery().andEq("stationId", stationId).andEq("youqiangId", youqiangId).andEq("enabled", 1).andEq("type", Constants.PrintDevice.FEIE.toString()).single();
                            Printerentity printerEntity;
                            if (entity != null) {
                                printerEntity = printermapper.single(entity.getPrinterId());
                                // 未找到油枪匹配的小票机, 则结束
                                if (printerEntity == null) {
                                    logger.warn("[printAndBellPopJob]没有找到油枪对应的飞鹅小票机,id=%s", entity.getPrinterId());
                                } else {
                                    String printerSn = printerEntity.getPrinterSn();
                                    String printerKey = printerEntity.getPrinterKey();
                                    PrinterObjectPojo pojo = genPojo(order, stationName, wxfwsEnabled, printerSn, printerKey);
                                    String result = PrinterTool.printJiayouOrder(pojo);
                                    Map<String, String> resultMap = JSON.parseObject(result, Map.class);
                                    String msg = resultMap.get("msg");
                                    if (msg.equals("ok")) {
                                        logger.info("[printAndBellPopJob]使用油枪对应的飞鹅小票机打印成功, orderId is %s", orderId);
                                        order.setPrinterConfirmed(1);
                                    } else {
                                        logger.warn("[printAndBellPopJob]使用油枪对应的飞鹅小票机打印失败, msg:%s", msg);
                                    }
                                }
                            } else {
                                logger.warn("[printAndBellPopJob][stationId=%s]未查找到油枪对应的飞鹅打印机", stationId);
                            }
                        }
                    }
                } else {
                    logger.warn("[printAndBellPopJob][stationId=%s]此加油站未启用飞鹅打印功能", stationId);
                }

                /*** 情况2:商米T2打印开关:开,订单状态:没有打印 ***/
                if (S.eq(sunmitPrinterEnabled, "1")) {
                    Printerentity printerEntity = printermapper.createLambdaQuery().andEq("stationId", stationId).andEq("enabled", 1).andEq("type", Constants.PrintDevice.SUNMIT2.toString()).single();
                    if (printerEntity != null) {
                        logger.debug("[printAndBellPopJob]此加油站配置了商米T2打印机,sn=%s", printerEntity.getPrinterSn());

                        PrinterObjectPojo pojo = genPojo(order, stationName, wxfwsEnabled);
                        String content = JSON.toJSONString(pojo);
                        // 查找油枪对应的打印机
                        Printeryouqiangentity printeryouqiangentity = printeryouqiangmapper.createLambdaQuery().andEq("stationId", stationId).andEq("enabled", 1).andEq("type", Constants.PrintDevice.SUNMIT2.toString()).andEq("youqiangId", youqiangId).single();
                        if (printeryouqiangentity != null) {
                            logger.debug("[printAndBellPopJob]通过油枪号查找到商米T2打印机,youqianghaoId=%s", youqiangId);
                            boolean msg = JiGuangTool.pushMerchantPad("PRINT", stationId, content);
                            if (msg) {
                                order.setPrinterConfirmed(1);
                                logger.info("[printAndBellPopJob]通过油枪对应的商米T2打印成功, orderId=%s", orderId);
                            } else {
                                logger.warn("[printAndBellPopJob]通过油枪对应的商米T2打印失败, orderId=%s", orderId);
                            }
                        }

                        // 查找员工码对应打印机
                        if (order.getBuStaffId() > 0) {
                            Bustaffentity bustaffentity = bustaffmapper.createLambdaQuery().andEq("stationId", stationId).andEq("enabled", 1).andEq("printerEnabled", 1).andEq("id", order.getBuStaffId()).single();
                            if (bustaffentity != null && S.eq(bustaffentity.getPrinterSn(), printerEntity.getPrinterSn())) {
                                logger.debug("[printAndBellPopJob]通过员工Id查到商米T2打印机,buStaffId=%s", bustaffentity.getId());
                                boolean msg = JiGuangTool.pushMerchantPad("PRINT", stationId, content);
                                if (msg) {
                                    order.setPrinterConfirmed(1);
                                    logger.info("[printAndBellPopJob]使用员工码对应的商米T2打印成功, orderId=%s", orderId);
                                } else {
                                    logger.warn("[printAndBellPopJob]使用员工码对应的商米T2打印失败, orderId=%s", orderId);
                                }
                            }
                        }

                    } else {
                        logger.debug("[printAndBellPopJob][stationId=%s]此加油站未配置商米T2打印机", stationId);
                    }
                }

                /*** 情况3:如果订单还没有打印,则随便挑一个打印机打印 ***/
                if (order.getPrinterConfirmed() != 1) {
                    Printerentity printerEntity = printermapper.createLambdaQuery().andEq("stationId", stationId).andEq("enabled", 1).single();
                    if (printerEntity != null) {
                        // 随机到飞鹅打印机
                        if (S.eq(Constants.PrintDevice.FEIE.toString(), printerEntity.getType())) {
                            String printerSn = printerEntity.getPrinterSn();
                            String printerKey = printerEntity.getPrinterKey();
                            PrinterObjectPojo pojo = genPojo(order, stationName, wxfwsEnabled, printerSn, printerKey);
                            String result = PrinterTool.printJiayouOrder(pojo);
                            Map<String, String> resultMap = JSON.parseObject(result, Map.class);
                            String msg = resultMap.get("msg");
                            if (msg.equals("ok")) {
                                logger.info("[printAndBellPopJob]随机小票机[飞鹅]打印成功, orderId=%s", orderId);
                                order.setPrinterConfirmed(1);
                            } else {
                                logger.warn("[printAndBellPopJob]随机小票机[飞鹅]打印失败, msg:%s", msg);
                            }
                        }
                        // 随机到商米T2打印机
                        if (S.eq(Constants.PrintDevice.SUNMIT2.toString(), printerEntity.getType())) {
                            PrinterObjectPojo pojo = genPojo(order, stationName, wxfwsEnabled);
                            String content = JSON.toJSONString(pojo);
                            boolean msg = JiGuangTool.pushMerchantPad("PRINT", stationId, content);
                            if (msg) {
                                order.setPrinterConfirmed(1);
                                logger.info("[printAndBellPopJob]随机打印机[商米T2]打印成功, orderId=%s", orderId);
                            } else {
                                logger.warn("[printAndBellPopJob]随机打印机[商米T2]打印失败, orderId=%s", orderId);
                            }
                        }
                    }
                }

                // 处理语音
                boolean flag1 = false;
                boolean flag2 = false;
                /** 情况1:WEB浏览器接受语音播报 **/
                if (S.eq("1", broadcastEnabled)) {
                    if(order.getBroadcastConfirmed() != 1) {
                        TTSMessagePojo ttsMsg = new TTSMessagePojo();
                        ttsMsg.stationId = stationId;
                        String token = BAIDU_TTS_TOKEN;
                        String jine = PriceTool.fenToYuan(order.getTotalPrice()).toString();
                        String text;
                        long buStaffId = order.getBuStaffId();
                        if (buStaffId != 0) {
                            text = S.concat(staffName , ",收款" , jine , "元");
                        } else {
                            text = S.concat(order.getYouqiangId() , "号油枪,已支付" , jine + "元");
                        }
                        ttsMsg.tipAudioSrc = "https://tsn.baidu.com/text2audio?tex=" + text + "&lan=zh&tok=" + token + "&ctp=1&cuid=123123123&vol=9";
                        WSNotificationTool.sendMessage(ttsMsg, stationId);
                        logger.info("[printAndBellPopJob][jiayouOrderId=%s]推送语音到浏览器成功", order.getId());
//                        order.setBroadcastConfirmed(1);
                        flag1 = true;
                    }
                } else {
                    logger.info("[printAndBellPopJob][stationId=%s]未启用WEB语音播报", stationId);
                }

                /** 情况2:商米T2接受语音播报 **/
                if (S.eq("1", sunmitBroadcastEnabled)) {
                    if(order.getBroadcastConfirmed() != 1) {
                        String jine = PriceTool.fenToYuan(order.getTotalPrice()).toString();
                        String voiceContent;
                        if (S.isNotEmpty(staffName)) {
                            voiceContent = S.concat(staffName, ",收款", jine, "元");
                        } else {
                            voiceContent = S.concat(order.getYouqiangId(), "号油枪,已支付", jine, "元");
                        }

                        boolean msg = JiGuangTool.pushMerchantPad("VOICE", stationId, voiceContent);
                        if (msg) {
//                            order.setBroadcastConfirmed(1);
                            flag2 = true;
                            logger.info("[printAndBellPopJob]商米T2语音推送成功, orderId=%s", orderId);
                        } else {
                            logger.warn("[printAndBellPopJob]商米T2语音推送失败, orderId=%s", orderId);
                        }
                    }
                } else {
                    logger.info("[printAndBellPopJob][stationId=%s]未启用商米T2语音播报", stationId);
                }
                if(flag1 || flag2){
                    order.setBroadcastConfirmed(1);
                }
                order.setConfirmed(1);
                jiayouordermapper.updateById(order);
                logger.info("[printAndBellPopJob][jiayouOrderId=%s][printConfirm=%s][broadConfirmed=%s]保存打印和播放语音状态", orderId, order.getPrinterConfirmed(), order.getBroadcastConfirmed());

            } catch (IllegalArgumentException e) {
                logger.error(e, "[printAndBellPopJob]队列BRPOP操作出现异常");
            }
        }
    }

    public static PrinterObjectPojo genPojo(Jiayouorderentity order, String stationName, String wxfwsEnabled, String printerSn, String printerKey) {
        PrinterObjectPojo pojo = new PrinterObjectPojo();
        pojo.title = "慧用车";
        pojo.time = DateTool.formatTime(order.getModified());                    // 交易时间
        pojo.dingdanhao = S.string(order.getId());
        pojo.jiayouzhan = stationName;
        pojo.qianghao = String.valueOf(order.getYouqiangId());
        pojo.jine = PriceTool.fenToYuan(order.getTotalPrice()).toString();                    // 合计金额
        pojo.actualJine = PriceTool.fenToYuan(order.getActualTotalPrice()).toString();              // 实付金额,即actualTotal
        if (S.isNotEmpty(order.getMobile())) {
            pojo.mobile = new StringBuilder(order.getMobile()).replace(3, 7, "****").toString();
        } else {
            pojo.mobile = "";
        }
        pojo.sn = printerSn;
        pojo.key = printerKey;
        pojo.times = String.valueOf(1);
        pojo.redpacketPrice = "0";          // 红包支付金额
//        pojo.daijinquanPrice = "0";         // 代金券支付
        pojo.thirdPartyZhifuMethod = order.getZhiFuMethod();   // 第三方支付方式
        pojo.thirdPartyPrice = PriceTool.fenToYuan(order.getPrice()).toString();        // 第三方支付金额
//        pojo.invoiceTitle = "";            // 发票抬头
        pojo.printTime = DateTool.formatTime(Calendar.getInstance().getTime());                    // 打印时间
        pojo.buStaffId = order.getBuStaffId();                    // 员工ID
        pojo.buStaffName = order.getBuStaffName();
        pojo.marketJine = PriceTool.fenToYuan(order.getMarketTotalPrice()).toString();              // 营收金额
        pojo.zizhuyouhuiJine = PriceTool.fenToYuan(order.getTotalPrice() - order.getMarketTotalPrice()).toString();              // 自主优惠金额
        pojo.wxfwsEnabled = wxfwsEnabled;
        pojo.gasType = order.getGasValue();
        return pojo;
    }

    public static PrinterObjectPojo genPojo(Jiayouorderentity order, String stationName, String wxfwsEnabled) {
        PrinterObjectPojo pojo = new PrinterObjectPojo();
        pojo.title = "慧用车";
        pojo.time = DateTool.formatTime(order.getModified());                    // 交易时间
        pojo.dingdanhao = S.string(order.getId());
        pojo.jiayouzhan = stationName;
        pojo.qianghao = String.valueOf(order.getYouqiangId());
        pojo.jine = PriceTool.fenToYuan(order.getTotalPrice()).toString();                    // 合计金额
        pojo.actualJine = PriceTool.fenToYuan(order.getActualTotalPrice()).toString();              // 实付金额,即actualTotal
        if (S.isNotEmpty(order.getMobile())) {
            pojo.mobile = new StringBuilder(order.getMobile()).replace(3, 7, "****").toString();
        } else {
            pojo.mobile = "";
        }
        pojo.times = String.valueOf(1);
        pojo.thirdPartyZhifuMethod = order.getZhiFuMethod();   // 第三方支付方式
        pojo.thirdPartyPrice = PriceTool.fenToYuan(order.getPrice()).toString();        // 第三方支付金额
        pojo.printTime = DateTool.formatTime(Calendar.getInstance().getTime());                    // 打印时间
        pojo.buStaffId = order.getBuStaffId();                    // 员工ID
        pojo.buStaffName = order.getBuStaffName();
        pojo.marketJine = PriceTool.fenToYuan(order.getMarketTotalPrice()).toString();              // 营收金额
        pojo.zizhuyouhuiJine = PriceTool.fenToYuan(order.getTotalPrice() - order.getMarketTotalPrice()).toString();              // 自主优惠金额
        pojo.wxfwsEnabled = wxfwsEnabled;
        pojo.gasType = order.getGasValue();
        return pojo;
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants