|
|
|
@ -13,17 +13,17 @@ namespace Mesnac.Action.ChemicalWeighing.InterfaceDocking
|
|
|
|
|
{
|
|
|
|
|
public class HttpResponse
|
|
|
|
|
{
|
|
|
|
|
public string PostResponse(TankIsDischargedSyncEntity taskIsDisChargedSyncEntity)
|
|
|
|
|
public string PostResponse(TankIsDischargedSyncEntity taskIsDisChargedSyncEntity)
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
return Post("http://192.168.202.23:5001/api/ReceivingAndFeedingMaterials/TankIsDischargedSync", taskIsDisChargedSyncEntity.JsonTo());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public string PostUsed(int deCode, string used)
|
|
|
|
|
public string PostUsed(int deCode, string used)
|
|
|
|
|
{
|
|
|
|
|
string stry = new LGusedEntity(deCode, used).JsonTo();
|
|
|
|
|
string stry = new LGusedEntity(deCode, used).JsonTo();
|
|
|
|
|
return Post("http://192.168.202.34:8080/mes/wcsInterface/saveLGusedLog", stry);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -41,7 +41,7 @@ namespace Mesnac.Action.ChemicalWeighing.InterfaceDocking
|
|
|
|
|
string stry = new GetLGInfoEntity().JsonTo();
|
|
|
|
|
var str = Post("http://192.168.202.34:30000/prod-api/open/openInterface/getLGInfo", stry);
|
|
|
|
|
var job = JObject.Parse(str);
|
|
|
|
|
if (job["code"].ToString()== "200")
|
|
|
|
|
if (job["code"].ToString() == "200")
|
|
|
|
|
{
|
|
|
|
|
JArray arr = job["data"] as JArray;
|
|
|
|
|
foreach (JObject item in arr)
|
|
|
|
@ -62,15 +62,15 @@ namespace Mesnac.Action.ChemicalWeighing.InterfaceDocking
|
|
|
|
|
return dic;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private string Post(string url,string postData)
|
|
|
|
|
|
|
|
|
|
private string Post(string url, string postData)
|
|
|
|
|
{
|
|
|
|
|
HttpItem item = new HttpItem()
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
URL = url, //URL 必需项
|
|
|
|
|
Method = "post",//URL 可选项 默认为Get
|
|
|
|
|
ContentType = "application/json",//返回类型 可选项有默认值
|
|
|
|
|