|
@@ -319,6 +319,8 @@ namespace CallCenter.NewRock
|
|
|
cancellationToken);
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+ //TODO 修改参数传递
|
|
|
/// <summary>
|
|
|
/// 更新分机组
|
|
|
/// </summary>
|
|
@@ -327,7 +329,7 @@ namespace CallCenter.NewRock
|
|
|
/// <param name="cancellationToken"></param>
|
|
|
/// <param name="isAdd"></param>
|
|
|
/// <returns></returns>
|
|
|
- public async Task ModifyGroupExtAsync(string groupId, List<string> ext,string voicefile="",bool isAdd=true,CancellationToken cancellationToken = default)
|
|
|
+ public async Task ModifyGroupExtAsync(string groupId,string ext,string voicefile="",bool isAdd=true,CancellationToken cancellationToken = default)
|
|
|
{
|
|
|
if (!int.TryParse(groupId, out int mId))
|
|
|
throw new UserFriendlyException("请输入数字");
|
|
@@ -352,17 +354,11 @@ namespace CallCenter.NewRock
|
|
|
|
|
|
if (isAdd)
|
|
|
{
|
|
|
- for (int i = 0; i < ext.Count; i++)
|
|
|
- {
|
|
|
- exts.Add(new QueryExtGroupExt(){ Id = ext[i] });
|
|
|
- }
|
|
|
+ exts.Add(new QueryExtGroupExt(){ Id = ext });
|
|
|
}
|
|
|
else
|
|
|
{
|
|
|
- for (int i = 0; i < ext.Count; i++)
|
|
|
- {
|
|
|
- exts.Remove(exts.First(x=>x.Id == ext.First()));
|
|
|
- }
|
|
|
+ exts.Remove(exts.First(x=>x.Id == ext));
|
|
|
}
|
|
|
|
|
|
groupModel.Ext = exts.Select(x=>x.Id).ToList();
|