fix(essentials): fixes index off by 1 error and updates call status to check for "OnHold" as status value

This commit is contained in:
Neil Dorin
2022-02-09 16:31:31 -07:00
parent e24965eb54
commit 7dd6b3a9b6
4 changed files with 15 additions and 7 deletions

View File

@@ -240,7 +240,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
new JoinMetadata
{
Description = "Speed Dial",
JoinCapabilities = eJoinCapabilities.ToSIMPL,
JoinCapabilities = eJoinCapabilities.FromSIMPL,
JoinType = eJoinType.Digital
});
@@ -940,7 +940,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
new JoinMetadata
{
Description = "Pulse to remove the selected recent call item specified by the SelectRecentCallItem analog join",
JoinCapabilities = eJoinCapabilities.ToSIMPL,
JoinCapabilities = eJoinCapabilities.FromSIMPL,
JoinType = eJoinType.Digital
});
@@ -954,7 +954,7 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
new JoinMetadata
{
Description = "Pulse to dial the selected recent call item specified by the SelectRecentCallItem analog join",
JoinCapabilities = eJoinCapabilities.ToSIMPL,
JoinCapabilities = eJoinCapabilities.FromSIMPL,
JoinType = eJoinType.Digital
});
@@ -1037,8 +1037,8 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
},
new JoinMetadata
{
Description = "Holds Call at specified index",
JoinCapabilities = eJoinCapabilities.ToFromSIMPL,
Description = "Holds Call at specified index. FB reported on Call Status XSIG",
JoinCapabilities = eJoinCapabilities.FromSIMPL,
JoinType = eJoinType.Digital
});

View File

@@ -909,6 +909,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
if (!string.IsNullOrEmpty(call.Status.Value))
{
tempActiveCall.Status = CodecCallStatus.ConvertToStatusEnum(call.Status.Value);
tempActiveCall.IsOnHold = call.Status.OnHold;
if (newStatus == eCodecCallStatus.Connected)
GetCallHistory();

View File

@@ -317,6 +317,8 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
string _Value;
public bool BoolValue { get; private set; }
public bool OnHold { get; private set; }
public string Value
{
get
@@ -328,6 +330,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
// If the incoming value is "Active" it sets the BoolValue true, otherwise sets it false
_Value = value;
BoolValue = value == "Active";
OnHold = value == "OnHold";
OnValueChanged();
}
}
@@ -2099,6 +2102,7 @@ namespace PepperDash.Essentials.Devices.Common.VideoCodec.Cisco
CallType = new CallType();
Status = new Status2();
Duration = new Duration();
PlacedOnHold = new PlacedOnHold();
}
}

View File

@@ -1054,7 +1054,7 @@ ScreenIndexIsPinnedTo: {8} (a{17})
{
if (u < 1 || u > entryToDial.ContactMethods.Count) return;
trilist.SetSigFalseAction(joinMap.DirectoryDialSelectedContactMethod.JoinNumber, () => Dial(entryToDial.ContactMethods[u].Number));
trilist.SetSigFalseAction(joinMap.DirectoryDialSelectedContactMethod.JoinNumber, () => Dial(entryToDial.ContactMethods[u - 1].Number));
});
// Sets DirectoryDialSelectedLine join action to dial first contact method
@@ -1216,7 +1216,7 @@ ScreenIndexIsPinnedTo: {8} (a{17})
var holdCodec = this as IHasCallHold;
if (holdCodec != null)
{
for (int i = 0; i < joinMap.JoinCallStart.JoinSpan; i++)
for (int i = 0; i < joinMap.HoldCallsStart.JoinSpan; i++)
{
trilist.SetSigFalseAction((uint)(joinMap.HoldCallsStart.JoinNumber + i), () =>
{
@@ -1245,6 +1245,9 @@ ScreenIndexIsPinnedTo: {8} (a{17})
});
}
}
}
private string UpdateCallStatusXSig()