using LogLibrary.Log; using Masuit.Tools; using Newtonsoft.Json; using WIDESEA_Common.FangCang; using WIDESEA_Core; using WIDESEA_DTO; using WIDESEA_Model.Models; namespace WIDESEA_StoragIntegrationServices { public partial class ToMESService { /// /// 产品同步接口 /// /// /// public WebResponseContent productSynchronous(object jsondata) { WebResponseContent content = new WebResponseContent(); try { if (string.IsNullOrEmpty(jsondata.ToString())) throw new Exception("上传参数为空"); var result = JsonConvert.DeserializeObject(jsondata.ToString()); //todo 完成物料同步 LogFactory.GetLog("产品同步接口").Info(true, $"\r\r--------------------------------------"); LogFactory.GetLog("产品同步接口").Info(true, jsondata.ToJsonString()); return content; } catch (Exception ex) { LogFactory.GetLog("产品同步接口").Info(true, $"\r\r--------------------------------------"); LogFactory.GetLog("产品同步接口").Info(true, ex.Message); return content.Error($"产品同步接口请求异常:{ex.Message}"); } } } }