| | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.stylefeng.guns.core.base.tips.SuccessTip; |
| | | import com.stylefeng.guns.core.shiro.ShiroKit; |
| | | import com.stylefeng.guns.core.util.DateUtil; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TDriverCommissionResp; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TDriverResp; |
| | |
| | | wrapper.between("createTime",startTime,endTime); |
| | | } |
| | | wrapper.orderBy(true,"approvalStatus"); |
| | | // 判断是否为代理商或者分公司 |
| | | if(Objects.requireNonNull(ShiroKit.getUser()).getRoleType() == 2){ |
| | | // 分公司 |
| | | wrapper.eq("branchOfficeId",ShiroKit.getUser().getObjectId()); |
| | | } |
| | | if(Objects.requireNonNull(ShiroKit.getUser()).getRoleType() == 3){ |
| | | // 代理商 |
| | | wrapper.eq("agentId",ShiroKit.getUser().getObjectId()); |
| | | } |
| | | return wrapper; |
| | | } |
| | | |
| | |
| | | wrapper.like("name",name); |
| | | } |
| | | wrapper.orderBy(true,"approvalStatus"); |
| | | // 判断是否为代理商或者分公司 |
| | | if(Objects.requireNonNull(ShiroKit.getUser()).getRoleType() == 2){ |
| | | // 分公司 |
| | | wrapper.eq("branchOfficeId",ShiroKit.getUser().getObjectId()); |
| | | } |
| | | if(Objects.requireNonNull(ShiroKit.getUser()).getRoleType() == 3){ |
| | | // 代理商 |
| | | wrapper.eq("agentId",ShiroKit.getUser().getObjectId()); |
| | | } |
| | | return wrapper; |
| | | } |
| | | |