20210706
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Net.Http;
|
||||
using System.Web.Http;
|
||||
using BLL;
|
||||
using WebAPI.Filter;
|
||||
|
||||
namespace WebAPI.Controllers
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public class getController : ApiController
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取凭证
|
||||
/// </summary>
|
||||
/// <param name="projectId"></param>
|
||||
/// <param name="appId"></param>
|
||||
/// <param name="appSecret"></param>
|
||||
/// <returns></returns>
|
||||
[HttpGet]
|
||||
public object token(string projectId, string appId, string appSecret)
|
||||
{
|
||||
return new
|
||||
{
|
||||
code = 0,
|
||||
data = new { token = Const.sysglyId },
|
||||
tokenExpires = Funs.ConvertDateTimeToInt32(DateTime.Now.AddMonths(1)),
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -93,7 +93,39 @@ namespace WebAPI.Controllers
|
||||
}
|
||||
else
|
||||
{
|
||||
responeData.message ="数据为空!";
|
||||
responeData.message = "数据为空!";
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
responeData.code = -1;
|
||||
responeData.message = ex.Message;
|
||||
}
|
||||
|
||||
return responeData;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 潮州华瀛项目出入人员信息
|
||||
/// <summary>
|
||||
/// 保存人员信息
|
||||
/// </summary>
|
||||
/// <param name="person">人员信息</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public Model.ResponeData person([FromBody] Model.attendanceItem person)
|
||||
{
|
||||
var responeData = new Model.ResponeData();
|
||||
try
|
||||
{
|
||||
responeData.code = 0;
|
||||
if (person != null )
|
||||
{
|
||||
responeData.message="success";
|
||||
}
|
||||
else
|
||||
{
|
||||
responeData.message = "数据为空!";
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
Reference in New Issue
Block a user