刘磊
2026-01-17 f1d726e3de8f15cdfe30d4ca5fbba733d73a1e56
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
using AngleSharp.Common;
using Masuit.Tools;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WIDESEA_Common;
using WIDESEA_Common.MES;
using WIDESEA_Common.MES.Request;
using WIDESEA_Core;
using WIDESEA_Core.Const;
using WIDESEA_Core.Helper;
using WIDESEAWCS_BasicInfoService;
using WIDESEAWCS_Model.Models;
 
namespace WIDESEA_StoragIntegrationServices
{
    /// <summary>
    /// 车身绑定工单(焊装直通涂装)
    /// </summary>
    public partial class MESService
    {
        public WebResponseContent pullLock(object jsondata)
        {
            WebResponseContent content = new WebResponseContent();
            try
            {
                if (string.IsNullOrEmpty(jsondata.ToString())) throw new Exception("请求参数为空");
 
                var result = JsonConvert.DeserializeObject<pullLockInfo>(jsondata.ToString());
 
                foreach (var item in result.data)
                {
                    if (!string.IsNullOrEmpty(item.pvi))
                    {
                        var carInfo = _palletStockInfoRepository.QueryFirst(x => x.PVI == item.pvi && x.pbMaterial == item.pbMaterial);
                        if (carInfo == null)
                        {
                            throw new Exception("未知车身");
                        }
                    }
 
                    var carinfo = _palletStockInfoRepository.QueryData(x => x.pbMaterial == item.pbMaterial).OrderBy(x => x.CreateDate);
 
                }
 
                LogFactory.GetLog("MES拉动锁车").Info(true, $"\r\r--------------------------------------");
                LogFactory.GetLog("MES拉动锁车").Info(true, jsondata.ToJsonString());
 
                return content;
            }
            catch (Exception ex)
            {
                return content.Error(ex.Message);
            }
        }
    }
}