ab56a9bcf7
SVN-Revision: r240
55 lines
1.3 KiB
C#
55 lines
1.3 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
|
|
namespace Lskj.SmsSending2
|
|
{
|
|
public sealed class NewEmp
|
|
{
|
|
/// <summary>
|
|
/// 同步数据
|
|
/// </summary>
|
|
/// <param name="
|
|
/// ">没有特殊说明,传入</param>
|
|
public static string PostMethodToObj(string url, string jsonObj)
|
|
{
|
|
try
|
|
{
|
|
return SynchronousOven.HttpUtil.PostUtil.PostUrl<string>(url, jsonObj);
|
|
}
|
|
catch (Exception)
|
|
{
|
|
throw;
|
|
//return JsonConvert.SerializeObject(new ResponseMode{ code = "-1", errorMsg = "非法操作." });
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// 同步数据
|
|
/// </summary>
|
|
public static string GetUrl(string url)
|
|
{
|
|
try
|
|
{
|
|
return SynchronousOven.HttpUtil.GetUtil.GetJson<string>(url);
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
throw;
|
|
//return JsonConvert.SerializeObject(new ResponseMode{ code = "-1", errorMsg = "非法操作." });
|
|
}
|
|
}
|
|
|
|
|
|
|
|
public class ResponseMode
|
|
{
|
|
public int ret;
|
|
public string msg;
|
|
}
|
|
|
|
|
|
}
|
|
}
|