|
|
|
@ -2,6 +2,7 @@ package com.foreverwin.mesnac.dispatch.controller;
|
|
|
|
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil;
|
|
|
|
|
import com.foreverwin.mesnac.common.dto.SfcDispatchDto;
|
|
|
|
|
import com.foreverwin.mesnac.common.util.StringUtil;
|
|
|
|
|
import com.foreverwin.mesnac.dispatch.model.ShopOrderRelease;
|
|
|
|
|
import com.foreverwin.modular.core.util.R;
|
|
|
|
|
import com.foreverwin.modular.core.util.FrontPage;
|
|
|
|
@ -16,7 +17,9 @@ import org.springframework.web.bind.annotation.*;
|
|
|
|
|
import org.springframework.web.multipart.MultipartFile;
|
|
|
|
|
|
|
|
|
|
import javax.websocket.server.PathParam;
|
|
|
|
|
import java.util.HashMap;
|
|
|
|
|
import java.util.List;
|
|
|
|
|
import java.util.Map;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
*
|
|
|
|
@ -320,4 +323,32 @@ public class SfcDispatchController {
|
|
|
|
|
return R.failed(message.toString());
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@PostMapping("/gantt-list")
|
|
|
|
|
public R ganttList(@RequestBody ShopOrderRelease shopOrderRelease) {
|
|
|
|
|
Map<String, Object> result = new HashMap<>();
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
String site = CommonMethods.getSite();
|
|
|
|
|
if (StringUtil.notBlank(shopOrderRelease.getStartFromDate_S())) {
|
|
|
|
|
shopOrderRelease.setStartFromDate(DateUtil.parseDate(shopOrderRelease.getStartFromDate_S()));
|
|
|
|
|
}
|
|
|
|
|
if (StringUtil.notBlank(shopOrderRelease.getStartToDate_S())) {
|
|
|
|
|
shopOrderRelease.setStartToDate(DateUtil.parseDate(shopOrderRelease.getStartToDate_S()));
|
|
|
|
|
}
|
|
|
|
|
shopOrderRelease.setSite(site);
|
|
|
|
|
|
|
|
|
|
//查询派工数据
|
|
|
|
|
List<ShopOrderRelease> scheduleList = sfcDispatchService.findSfcDispatchList(shopOrderRelease);
|
|
|
|
|
result.put("schedules", scheduleList);
|
|
|
|
|
|
|
|
|
|
//查询工作中心工作时间
|
|
|
|
|
result.put("workCenterWorkTimes", "");
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
return R.failed(e.getMessage());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return R.ok();
|
|
|
|
|
}
|
|
|
|
|
}
|