春风项目四线(合箱线、总装线)
yyt
2024-01-24 01cb633562174ae7390d12b85690a45997f34be7
jcdm-main/src/main/java/com/jcdm/main/bs/orderScheduling/service/impl/BsOrderSchedulingServiceImpl.java
@@ -1,15 +1,14 @@
package com.jcdm.main.bs.orderScheduling.service.impl;
import java.util.List;
import cn.hutool.core.util.StrUtil;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.jcdm.common.utils.DateUtils;
import com.jcdm.main.bs.orderScheduling.Query.PrepareOnlineQuery;
import com.jcdm.main.bs.orderScheduling.domain.BsOrderScheduling;
import com.jcdm.main.bs.orderScheduling.mapper.BsOrderSchedulingMapper;
import com.jcdm.main.bs.orderScheduling.service.IBsOrderSchedulingService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.jcdm.main.bs.orderScheduling.mapper.BsOrderSchedulingMapper;
import com.jcdm.main.bs.orderScheduling.domain.BsOrderScheduling;
import com.jcdm.main.bs.orderScheduling.service.IBsOrderSchedulingService;
import java.util.List;
/**
 * 订单排产Service业务层处理
@@ -18,7 +17,7 @@
 * @date 2024-01-13
 */
@Service
public class BsOrderSchedulingServiceImpl implements IBsOrderSchedulingService
public class BsOrderSchedulingServiceImpl implements IBsOrderSchedulingService
{
    @Autowired
    private BsOrderSchedulingMapper bsOrderSchedulingMapper;
@@ -44,19 +43,23 @@
    @Override
    public List<BsOrderScheduling> selectBsOrderSchedulingList(BsOrderScheduling bsOrderScheduling)
    {
//        if(bsOrderScheduling.getOperateTime()!=null){
//            ObjectMapper objectMapper = new ObjectMapper();
//            try {
//                String[] dateArray = objectMapper.readValue(bsOrderScheduling.getOperateTime(), String[].class);
//            }catch (Exception e){
//
//            }
//
//        }
        if(bsOrderScheduling.getDateConditions()!=null){
            String[] conditions = bsOrderScheduling.getDateConditions();
            bsOrderScheduling.setStartTime(conditions[0]);
            bsOrderScheduling.setEndTime(conditions[1]);
        }
        return bsOrderSchedulingMapper.selectBsOrderSchedulingList(bsOrderScheduling);
    }
    /**
     * 查询合箱上线列表
     * @param prepareOnlineQuery
     * @return list
     */
    public List<BsOrderScheduling> getPrepareOnlineList(PrepareOnlineQuery prepareOnlineQuery){
        return bsOrderSchedulingMapper.getPrepareOnlineList(prepareOnlineQuery);
    }
    /**
     * 新增订单排产
     *