Commit f4b0b0ad authored by 李洪明's avatar 李洪明

添加上传进出厂记录

parent 8d90919c
......@@ -17,6 +17,7 @@ import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.Date;
import java.util.List;
import java.util.Objects;
@Service
@Slf4j
......@@ -29,6 +30,7 @@ public class TransportDateService {
private LoginService loginService;
@Autowired
private TransportDateUploadFailMapper transportDateUploadFailMapper;
private final static String COMPANY_CODE = "1302847854";
private final static String CARGO_URL = "https://dctapi.soszyzg.com/dct/addCargo";
......@@ -100,7 +102,9 @@ public class TransportDateService {
materialInfo.setUnit("T");
materialInfo.setCargoquantity(transportDate.getTransportVolume().toString());
// 进出厂流水号
materialInfo.setEntryexitflownumber("");
String timeStr = Objects.requireNonNull(DateUtils.format(DateUtils.toDate(transportDate.getInoutTime()), DateUtils.DATE_FORMAT_MIN)).substring(0, DateUtils.DATE_FORMAT_MIN.length());
String rsn = COMPANY_CODE + timeStr + transportDate.getInOut();
materialInfo.setEntryexitflownumber(rsn);
return materialInfo;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment