服务端的TigerApi 框架,基于.NET6 2024 版本
Ben Lin
2024-12-17 738df70120209daecd85566d0c50dbf56d9e4453
Tiger.Business.MES/Transaction/Position.cs
@@ -993,27 +993,6 @@
            return list;
        }
        #endregion
        #region 提交前通用方法
        /// <summary>
        /// 提交前检查是否岗位、工单和不良代码
        /// </summary>
        /// <param name="code"></param>
        /// <returns></returns>
        public async Task<ApiAction<CheckCodeOutput>> CheckCode(string code) {
            var action = new ApiAction<CheckCodeOutput>($"检查条码{code}成功", new CheckCodeOutput());
            try
            {
                action.Data.Position = DbCache.Cache.Position[code];
                action.Data.WorkOrder = await MainDB.Queryable<BIZ_MES_WO>().Where(q=>q.ORDER_NO == code).FirstAsync();
                action.Data.Defect = DbCache.Cache.Defect[code];
            }
            catch (Exception ex)
            {
                action.CatchExceptionWithLog(ex, $"检查条码{code}异常");
            }
            return action;
        }
        #endregion
        #endregion Functions
        public override bool Close(bool needSaveHistoryLog = false)