Compare commits
No commits in common. "d56a896b457bfbafb85aace778992004fa11bc0c" and "d6fb16811fefb5d938476fe588c8a7cab28d3a2a" have entirely different histories.
d56a896b45
...
d6fb16811f
|
|
@ -460,35 +460,20 @@ namespace OpenAuth.App.ServiceApp.DroneSsnydManage
|
|||
}
|
||||
|
||||
public async Task CloseProject(string id)
|
||||
{
|
||||
var project = await Repository.AsQueryable().SingleAsync(a => a.Id == id && a.handle_status_id != 99);
|
||||
if (project == null)
|
||||
{
|
||||
throw new Exception("项目不存在或停止生产");
|
||||
}
|
||||
|
||||
var newProject = new DroneSsnyd()
|
||||
{
|
||||
Id = project.Id,
|
||||
handle_status_id = 99,
|
||||
handle_status_name = "项目终止",
|
||||
};
|
||||
await Repository.AsUpdateable(newProject).IgnoreNullColumns().ExecuteCommandAsync();
|
||||
}
|
||||
|
||||
public DroneSsnyd ProjectDetail(string id)
|
||||
{
|
||||
var project = Repository.GetById(id);
|
||||
if (project == null)
|
||||
{
|
||||
throw new Exception("项目不存在");
|
||||
}
|
||||
project.RcjgList = Repository
|
||||
.ChangeRepository<SugarRepositiry<DroneSsnydRcjg>>().AsQueryable()
|
||||
.Where(c => c.ssnyd_id == id)
|
||||
.ToList();
|
||||
|
||||
return project;
|
||||
}
|
||||
{
|
||||
var project = await Repository.AsQueryable().SingleAsync(a => a.Id == id && a.handle_status_id != 99);
|
||||
if (project == null)
|
||||
{
|
||||
throw new Exception("项目不存在或停止生产");
|
||||
}
|
||||
|
||||
var newProject = new DroneSsnyd()
|
||||
{
|
||||
Id = project.Id,
|
||||
handle_status_id = 99,
|
||||
handle_status_name = "项目终止",
|
||||
};
|
||||
await Repository.AsUpdateable(newProject).IgnoreNullColumns().ExecuteCommandAsync();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -13,8 +13,9 @@ namespace OpenAuth.Repository.Domain
|
|||
{
|
||||
public DroneSsnyd()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// Desc:
|
||||
/// Default:
|
||||
|
|
@ -709,7 +710,5 @@ namespace OpenAuth.Repository.Domain
|
|||
/// </summary>
|
||||
public DateTime? yijiaoshijian { get; set; }
|
||||
|
||||
[SugarColumn(IsIgnore = true)]
|
||||
public List<DroneSsnydRcjg> RcjgList { get; set; }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -218,30 +218,6 @@ namespace OpenAuth.WebApi.Controllers.ServiceControllers
|
|||
|
||||
return response;
|
||||
}
|
||||
|
||||
// 项目移交 项目详情
|
||||
|
||||
/// <summary>
|
||||
/// 项目详情
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
[HttpGet]
|
||||
public Response<DroneSsnyd> ProjectDetail(string id)
|
||||
{
|
||||
var response = new Response<DroneSsnyd>();
|
||||
try
|
||||
{
|
||||
response.Result = droneSsnyApp.ProjectDetail(id);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
response.Code = 500;
|
||||
response.Message = ex.InnerException?.Message ?? ex.Message;
|
||||
}
|
||||
|
||||
return response;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 历史项目导出
|
||||
|
|
|
|||
Loading…
Reference in New Issue