From b267af1b816f646fa02c6f4983ebb3f9825cc192 Mon Sep 17 00:00:00 2001 From: pang.jiabao <pang_jiabao@163.com> Date: 星期六, 13 四月 2024 15:00:44 +0800 Subject: [PATCH] 单据管理:1.销售账号,在系统里面单据管理这里A销售员做的单子,在它的账号只显示自己的客户信息,不同的账号,看不到别人的信息,管理员是可以全部看的 2.增加客户名称,操作员搜索 --- src/main/java/com/zy/asrs/service/impl/PlaServiceImpl.java | 16 ++++++++++++---- 1 files changed, 12 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/zy/asrs/service/impl/PlaServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/PlaServiceImpl.java index c87188c..6cbd4cd 100644 --- a/src/main/java/com/zy/asrs/service/impl/PlaServiceImpl.java +++ b/src/main/java/com/zy/asrs/service/impl/PlaServiceImpl.java @@ -5,6 +5,7 @@ import com.baomidou.mybatisplus.plugins.Page; import com.baomidou.mybatisplus.service.impl.ServiceImpl; import com.core.common.Cools; +import com.core.common.DateUtils; import com.core.exception.CoolException; import com.zy.asrs.entity.OrderDetl; import com.zy.asrs.entity.Pla; @@ -154,11 +155,18 @@ public Page<Pla> getStockStatisAll(Page<Pla> page) { List<Pla> plaList; - if(Cools.isEmpty(page.getCondition().get("brand"))){ - plaList=baseMapper.getStockStatisAll(); - }else { - plaList = baseMapper.getStockStatisAllByBrand(page.getCondition().get("brand").toString()); + Date stime = null; + Date etime = null; + Object create_time = page.getCondition().get("create_time"); + Object brand = page.getCondition().get("brand"); + Object status = page.getCondition().get("status"); + String createTime = create_time == null ? null : create_time.toString(); + if(!Cools.isEmpty(createTime)){ + String[] dates = createTime.split(" - "); + stime = DateUtils.convert(dates[0]); + etime = DateUtils.convert(dates[1]); } + plaList=baseMapper.getStockStatisAll(brand == null ? null:brand.toString(), status == null ? null:status.toString(), stime,etime); double weightSum = plaList.stream().mapToDouble(Pla::getWeight).sum(); -- Gitblit v1.9.1