招聘参数配置 新增组别

master
xiaochanghai 5 months ago
parent 0f36714315
commit 9c1873eb32
  1. 10
      Tiobon.Core.Api/Controllers/Ghrh/Ghrh_ConfigGroupController.cs
  2. 6
      Tiobon.Core.Api/Tiobon.Core.xml
  3. 2
      Tiobon.Core.IServices/Ghrh/IGhrh_ConfigGroupServices.cs
  4. 17
      Tiobon.Core.Services/Ghrh/Ghrh_ConfigGroupServices.cs
  5. 6
      Tiobon.Core/Tiobon.Core.xml

@ -11,4 +11,14 @@ public class Ghrh_ConfigGroupController : BaseController<IGhrh_ConfigGroupServic
public Ghrh_ConfigGroupController(IGhrh_ConfigGroupServices service) : base(service)
{
}
/// <summary>
/// 批量更新数据
/// </summary>
/// <param name="entitys"></param>
[HttpPost, Route("BulkUpdateValue")]
public virtual async Task<ServiceResult> BulkUpdateValue([FromBody] List<Ghrh_ConfigGroupDto> entitys)
{
return await _service.BulkUpdateValue(entitys);
}
}

@ -1310,6 +1310,12 @@
招聘参数配置组(Controller)
</summary>
</member>
<member name="M:Tiobon.Core.Api.Controllers.Ghrh_ConfigGroupController.BulkUpdateValue(System.Collections.Generic.List{Tiobon.Core.Model.Models.Ghrh_ConfigGroupDto})">
<summary>
批量更新数据
</summary>
<param name="entitys"></param>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghrh_HumanRequestController">
<summary>
人力需求维护(Controller)

@ -1,4 +1,5 @@
using Tiobon.Core.IServices.BASE;
using Tiobon.Core.Model;
using Tiobon.Core.Model.Models;
namespace Tiobon.Core.IServices;
@ -8,4 +9,5 @@ namespace Tiobon.Core.IServices;
/// </summary>
public interface IGhrh_ConfigGroupServices : IBaseServices<Ghrh_ConfigGroup, Ghrh_ConfigGroupDto, InsertGhrh_ConfigGroupInput, EditGhrh_ConfigGroupInput>
{
Task<ServiceResult> BulkUpdateValue(List<Ghrh_ConfigGroupDto> entitys);
}

@ -26,4 +26,21 @@ public class Ghrh_ConfigGroupServices : BaseServices<Ghrh_ConfigGroup, Ghrh_Conf
});
return result;
}
public async Task<ServiceResult> BulkUpdateValue(List<Ghrh_ConfigGroupDto> entitys)
{
for (int i = 0; i < entitys.Count; i++)
{
for (int j = 0; j < entitys[i].Configs.Count; j++)
{
await Db.Updateable<Ghrh_Config>()
.SetColumns(it => new Ghrh_Config()
{
ConfigValue = entitys[i].Configs[j].ConfigValue
}, true)
.Where(x => x.Id == entitys[i].Configs[j].Id)
.ExecuteCommandAsync();
}
}
return ServiceResult.OprateSuccess();
}
}

@ -1310,6 +1310,12 @@
招聘参数配置组(Controller)
</summary>
</member>
<member name="M:Tiobon.Core.Api.Controllers.Ghrh_ConfigGroupController.BulkUpdateValue(System.Collections.Generic.List{Tiobon.Core.Model.Models.Ghrh_ConfigGroupDto})">
<summary>
批量更新数据
</summary>
<param name="entitys"></param>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghrh_HumanRequestController">
<summary>
人力需求维护(Controller)

Loading…
Cancel
Save