11
啊鑫
2024-12-23 69e9f4f7ea3467e4030b60200705a750598827b6
11
已修改2个文件
20 ■■■■■ 文件已修改
MES.Service/Dto/webApi/ErpProductionOrderDto.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
MES.Service/service/BasicData/ProductionOrderManager.cs 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
MES.Service/Dto/webApi/ErpProductionOrderDto.cs
@@ -15,6 +15,7 @@
    public string? FPlannerID { get; set; } // 计划员
    public string? FPlanStartDate { get; set; } // 预计开工时间
    public string? FPlanFinishDate { get; set; } // 预计完工时间
    public string? PlanConfirmation{ get; set; }
    public string? FStockInLimitH { get; set; } // 入库上限
    public string? FStockInLimitL { get; set; } // 入库下限
    public string? FMTONO { get; set; } // 计划跟踪号
@@ -33,7 +34,7 @@
    public string? FFORCECLOSERID { get; set; } // 结案人
    public string? FCloseType { get; set; } // 结案类型
    public string? FDescription { get; set; } // 备注
    public string? FPPOMID { get; set; } // ERPID
    public string? FID { get; set; } // ERPID
    public string? FSUBENTRYID { get; set; } // ERP生产订单分录内码
    public string? FPurOrderNo { get; set; } // 采购订单
    public string? FPurOrderEntrySeq { get; set; } // 采购订单行号
@@ -41,7 +42,6 @@
    public string? FBaseNoStockInQty { get; set; } // 未入库数量
    public string? FInStockOwnerId { get; set; } // 入库货主
    public string? PlanConfirmation { get; set; }
    public string? FReqSrc { get; set; }
    public string? SrcSplitSeq { get; set; }
    public string? TypeA { get; set; }
MES.Service/service/BasicData/ProductionOrderManager.cs
@@ -75,10 +75,16 @@
        if (mesRohInDatas.Count > 0)
            db.Deleteable<ProductionOrderSub>()
                .Where(s => s.ErpHeaderId == mesRohIn.ErpId).ExecuteCommand();
                .Where(s => s.ErpProductionEntryCode == mesRohIn.ErpProductionEntryCode).ExecuteCommand();
        var orUpdate = base.Insert(mesRohIn);
        var baOrUpdate = _productionOrderSubManager.InsertRange(mesRohInDatas);
        var orUpdate = db.Insertable(mesRohIn)
            .IgnoreColumns(true).ExecuteCommand() > 0;
        var baOrUpdate = db.Insertable(mesRohInDatas).PageSize(1)
            .IgnoreColumnsNull()
            .ExecuteCommand() > 0;
        if (orUpdate && baOrUpdate) return true;
        throw new NotImplementedException("插入或更新失败");
@@ -142,7 +148,7 @@
            ClosingPerson = erpDto.FFORCECLOSERID,
            ClosingType = erpDto.FCloseType,
            Remarks = erpDto.FDescription,
            ErpId = erpDto.FPPOMID,
            ErpId = erpDto.FID,
            ErpProductionEntryCode = erpDto.FSUBENTRYID,
            Purchaseorderno = erpDto.FPurOrderNo,
            Purchaseorderentryseq = Convert.ToInt32(erpDto.FPurOrderEntrySeq),
@@ -158,7 +164,7 @@
            Typea = erpDto.TypeA,
        };
        var single = base.GetSingle(it => it.ErpId == erpDto.FPPOMID);
        var single = base.GetSingle(it => it.ErpId == erpDto.FID);
        if (single != null) productionOrder.Guid = single.Guid;
        return productionOrder;