wms105加个生产日期

master
mengjiao 3 weeks ago
parent 6fe5b2dcb1
commit 8c91b60297

@ -29,6 +29,8 @@ import org.springframework.stereotype.Service;
import javax.validation.Validator;
import java.math.BigDecimal;
import java.text.SimpleDateFormat;
import java.time.LocalDate;
import java.time.format.DateTimeFormatter;
import java.util.*;
@Component
@ -659,6 +661,10 @@ public class SapItemSyncImpl implements SapItemSyncService {
@Override
public R sap105temporarilyCollected(List<Map> mapList) {
try {
LocalDate today = LocalDate.now(); // 获取当前日期
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyyMMdd"); // 定义日期格式
String todayDate = today.format(formatter); // 格式化当前日期为字符串
Map map= mapList.get(0);
JCoRepository repository = dest.getRepository();
JCoFunction func = repository.getFunction("ZMES_GET_MSEG");
@ -781,7 +787,7 @@ public class SapItemSyncImpl implements SapItemSyncService {
L_ITEM.setValue("LGORT", "0001");//库存地点
L_ITEM.setValue("QUANTITY",menge);//数量
L_ITEM.setValue("BATCH", map.get("incomeBatchNo"));//批号
L_ITEM.setValue("HSDAT","");//生产日期
L_ITEM.setValue("HSDAT",todayDate);//生产日期
System.out.println(L_ITEM);
func2.execute(dest);//执行调用函数
RETCODE = func2.getExportParameterList().getString("RETCODE");

Loading…
Cancel
Save