南骏 池
7 天以前 9af04222e7449442f1d1cc1a80b6e07a90f4c9bf
MES.Service/service/BasicData/ProductionOrderManager.cs
@@ -35,7 +35,11 @@
                //         ? 1
                //         : 0;
                case "3":
                    return UpdateData(db, mesRohIn, mesRohInDatas) ? 1 : 0;
                    //return UpdateData(db, mesRohIn, mesRohInDatas) ? 1 : 0;//改为不删除
                    return SaveOrUpdateData(db, mesRohIn, mesRohInDatas,
                        erpProductionOrderDto.Type)
                        ? 1
                        : 0;
                case "2":
                case "4":
                    return SaveOrUpdateData(db, mesRohIn, mesRohInDatas,
@@ -70,6 +74,11 @@
    private bool SaveOrUpdateData(SqlSugarScope db, ProductionOrder mesRohIn,
        List<ProductionOrderSub> mesRohInDatas, string type)
    {
        if(type == "3")
        {
            mesRohIn.Typea = "3";  // 新增字段赋值
        }
        if (StringUtil.CheckGuid(mesRohIn.Guid))
            db.Deleteable<ProductionOrder>()
                .Where(s => s.Guid == mesRohIn.Guid)