添加锁定解锁分割功能
continuous-integration/drone/push Build is passing

This commit is contained in:
he
2026-04-29 10:12:02 +08:00
parent 34f5978aea
commit 962f88f94d
7 changed files with 22224 additions and 1 deletions
@@ -69,6 +69,13 @@ public class SegmentBindingAddOrEdit
public Guid VisitTaskId { get; set; }
}
public class LockOrUnLockSegmentInDto
{
public Guid SegmentId { get; set; }
public bool IsLock { get; set; }
}
public class SegmentBindingQuery:PageInput
{
public Guid? QuestionId { get; set; }
@@ -165,6 +165,21 @@ public class SegmentationService(IRepository<Segmentation> _segmentationReposito
return ResponseOutput.Ok();
}
/// <summary>
/// 锁定解锁分割
/// </summary>
/// <param name="inDto"></param>
/// <returns></returns>
public async Task<IResponseOutput> LockOrUnLockSegment(LockOrUnLockSegmentInDto inDto)
{
await _segmentRepository.UpdatePartialFromQueryAsync(x => x.Id == inDto.SegmentId, t => new Segment
{
IsLock = inDto.IsLock
});
await _segmentRepository.SaveChangesAsync();
return ResponseOutput.Ok();
}
/// <summary>
/// 获取分割绑定