服务端的TigerApi 框架,基于.NET6 2024 版本
Tiger.Business.MES/BIZ/BIZ_MES_WO.cs
@@ -140,7 +140,7 @@
                    result.LocaleMsg = new($"工单[{input.Wo.ORDER_NO}]已经存在工单批次[{_batch.BATCH_NO}]在线体[{input.WoBatch.ACT_LINE}]中状态为[{_batch.STATUS.GetEnumDesc<BIZ_MES_WO.STATUSs>()}],不能下发!");
                    return result;
                }
                WoContext.RemoveBatch(input.WoBatch.BATCH_NO);
                //WoContext.RemoveBatch(input.WoBatch.BATCH_NO);
                input.Wo.ACT_LINE = input.WoBatch.ACT_LINE;
                input.Wo.RELEASE_TIME = DateTime.Now;
                input.Wo.RELEASE_USER = input.WoBatch.UPDATE_USER;
@@ -207,7 +207,7 @@
                var db = Biz.Db;
                var dbTran = db.UseTran(() =>
                {
                    db.Updateable(_wo, input.UserId).UpdateColumns(x => new { x.STATUS, x.ROUTE_STATUS }).ExecuteCommand();
                    db.Updateable(_wo, input.UserId).UpdateColumns(x => new { x.STATUS, x.ROUTE_STATUS, x.UPDATE_USER, x.UPDATE_TIME }).ExecuteCommand();
                });
                if (!dbTran.IsSuccess)
                {
@@ -241,7 +241,7 @@
                    _woBatch.STATUS = input.Status < 0 ? _woBatch.STATUS : input.Status;
                    if (input.Status == BIZ_MES_WO_BATCH.STATUSs.Paused.GetValue())
                    {
                        WoContext.RemoveBatch(input.WoBatch);
                        //WoContext.RemoveBatch(input.WoBatch);
                    }
                    //如果是下发
                    if (input.Status == BIZ_MES_WO_BATCH.STATUSs.Release.GetValue())
@@ -270,11 +270,11 @@
                    //如果是下发
                    if (input.Status == BIZ_MES_WO_BATCH.STATUSs.Release.GetValue())
                    {
                        db.Updateable(_woBatch, input.UserId).UpdateColumns(x => new { x.STATUS, x.RELEASE_USER, x.RELEASE_TIME, x.ACT_LINE }).ExecuteCommand();
                        db.Updateable(_woBatch, input.UserId).UpdateColumns(x => new { x.STATUS, x.RELEASE_USER, x.RELEASE_TIME, x.ACT_LINE, x.UPDATE_USER, x.UPDATE_TIME }).ExecuteCommand();
                    }
                    else
                    {
                        db.Updateable(_woBatch, input.UserId).UpdateColumns(x => new { x.STATUS }).ExecuteCommand();
                        db.Updateable(_woBatch, input.UserId).UpdateColumns(x => new { x.STATUS, x.UPDATE_USER, x.UPDATE_TIME }).ExecuteCommand();
                    }
                });
                if (!dbTran.IsSuccess)