111
lss
2 天以前 23c28e3c0437081a78a48e54dc066c87500fa8bc
HH.WCS.Mobox3 - ´ó³µ¼ä/HH.WCS.Mobox3.JiaTong/api/ApiHelper.cs
@@ -104,7 +104,10 @@
                    case "YBK":
                        n_type = 2;
                        Source = "预备库";
                        state = "等待推送";
                        if (taskData.taskType == 1)
                        {
                            state = "等待推送";
                        }
                        break;
                }
@@ -242,7 +245,7 @@
        /// <returns></returns>
        internal static Result MstStateInquire(MstStateInquire model)
        {
            Result result = new Result() { code = "200", msg = "状态下发成功" };
            Result result = new Result() { code = "0", msg = "状态下发成功" };
            var db = new SqlHelper<object>().GetInstance();
            if (model == null)
            {
@@ -258,8 +261,21 @@
                var task = db.Queryable<WCSTask>().Where(a => a.S_EQ_NO.Trim() == model.taskNum).First();
                if (task != null)
                {
                    task.S_B_STATE ="等待";
                    db.Updateable(task).UpdateColumns(a => new { a.S_B_STATE}).ExecuteCommand();
                    if (task.S_B_STATE != "等待推送")
                    {
                        result.code = "1";
                        result.msg = $"推送失败,任务已经处理";
                        AddErrorInfo("推送失败", result.msg);
                        return result;
                    }
                    task.S_B_STATE = "等待";
                    if (db.Updateable(task).UpdateColumns(a => new { a.S_B_STATE }).ExecuteCommand() < 0)
                    {
                        result.code = "1";
                        result.msg = $"推送失败,修改任务状态失败,请重新下发";
                        AddErrorInfo("推送失败", result.msg);
                        return result;
                    }
                }
                else
                {
@@ -475,7 +491,7 @@
                if (loc != null)
                {
                    UploadLoc upload = new UploadLoc();
                    upload.locationNum = loc.S_CODE;
                    upload.type = loc.S_TYPE;
                    upload.lockState = loc.S_LOCK_STATE;