服务端的TigerApi 框架,基于.NET6 2024 版本
Rodney Chen
2024-09-04 0116b5d2ed16a0825da9e7474fc786ee06b2d60c
Tiger.Business.MES/WorkAction/IPQC.cs
@@ -59,7 +59,10 @@
            action.LocaleMsg = new("MES.WorkAction.IPQC.PleaseTest");
            //如果根据输入可以开始执行当前行为则标记为成功,否则失败
            CurStep.Message = Biz.L("等待测试");
            CurStep.Status = StepStatus.Normal;
            action.IsSuccessed = false;
            action.Data.ShortMsg = new("等待测试", ShortMessage.Types.Success);
            return action;
        }
        /// <summary>
@@ -79,12 +82,15 @@
                //行为执行完成
                if (false)
                {
                   action = End();
                   action = End(input);
                }
            }
            //提交数据执行失败
            else
            {
                CurStep.Message = Biz.L("测试失败");
                CurStep.Status = StepStatus.Error;
                action.Data.ShortMsg = new("测试失败", ShortMessage.Types.Failed);
                action.IsSuccessed = false;
                //action.LocaleMsg = new($"执行失败");
                action.LocaleMsg = new("MES.WorkAction.IPQC.Fail");
@@ -101,7 +107,7 @@
        /// 结束执行工序行为
        /// </summary>
        /// <returns></returns>
        public ApiAction<SubmitOutput> End()
        public ApiAction<SubmitOutput> End(SubmitInput input)
        {
            var action = new ApiAction<SubmitOutput>(new SubmitOutput());
@@ -163,7 +169,10 @@
            };
            IsFinished = true;
            action.LocaleMsg = new($"行为结束");
            CurStep.Message = Biz.L("测试完成");
            CurStep.Status = StepStatus.Finished;
            action.Data.ShortMsg = new("测试完成", ShortMessage.Types.Success);
            action.LocaleMsg = new($"测试结束");
            //action.LocaleMsg = new("MES.WorkAction.IPQC.Finish");
            return action;
        }