mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-02-14 20:24:57 +00:00
fix(essentials): #865 Adds SelectedContactMethodCount join to report the number of methods for the selected contact
This commit is contained in:
@@ -1204,6 +1204,20 @@ namespace PepperDash.Essentials.Core.Bridges.JoinMaps
|
|||||||
JoinType = eJoinType.Analog
|
JoinType = eJoinType.Analog
|
||||||
});
|
});
|
||||||
|
|
||||||
|
[JoinName("SelectedContactMethodCount")]
|
||||||
|
public JoinDataComplete SelectedContactMethodCount = new JoinDataComplete(
|
||||||
|
new JoinData
|
||||||
|
{
|
||||||
|
JoinNumber = 102,
|
||||||
|
JoinSpan = 1
|
||||||
|
},
|
||||||
|
new JoinMetadata
|
||||||
|
{
|
||||||
|
Description = "Reports the number of contact methods for the selected contact",
|
||||||
|
JoinCapabilities = eJoinCapabilities.FromSIMPL,
|
||||||
|
JoinType = eJoinType.Analog
|
||||||
|
});
|
||||||
|
|
||||||
[JoinName("CameraPresetSelect")]
|
[JoinName("CameraPresetSelect")]
|
||||||
public JoinDataComplete CameraPresetSelect = new JoinDataComplete(
|
public JoinDataComplete CameraPresetSelect = new JoinDataComplete(
|
||||||
new JoinData
|
new JoinData
|
||||||
|
|||||||
@@ -972,6 +972,7 @@ ScreenIndexIsPinnedTo: {8} (a{17})
|
|||||||
if (entry is DirectoryFolder)
|
if (entry is DirectoryFolder)
|
||||||
{
|
{
|
||||||
codec.GetDirectoryFolderContents(entry.FolderId);
|
codec.GetDirectoryFolderContents(entry.FolderId);
|
||||||
|
trilist.SetUshort(joinMap.SelectedContactMethodCount.JoinNumber, 0);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -998,10 +999,16 @@ ScreenIndexIsPinnedTo: {8} (a{17})
|
|||||||
// If auto dial is disabled...
|
// If auto dial is disabled...
|
||||||
var entryToDial = entry as DirectoryContact;
|
var entryToDial = entry as DirectoryContact;
|
||||||
|
|
||||||
if (entryToDial == null) return;
|
if (entryToDial == null)
|
||||||
|
{
|
||||||
|
trilist.SetUshort(joinMap.SelectedContactMethodCount.JoinNumber, 0);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
trilist.SetSigFalseAction(joinMap.DirectoryDialSelectedLine.JoinNumber, () => Dial(entryToDial.ContactMethods[0].Number));
|
trilist.SetSigFalseAction(joinMap.DirectoryDialSelectedLine.JoinNumber, () => Dial(entryToDial.ContactMethods[0].Number));
|
||||||
|
|
||||||
|
trilist.SetUshort(joinMap.SelectedContactMethodCount.JoinNumber, (ushort)entryToDial.ContactMethods.Count);
|
||||||
|
|
||||||
var clearBytes = XSigHelpers.ClearOutputs();
|
var clearBytes = XSigHelpers.ClearOutputs();
|
||||||
|
|
||||||
trilist.SetString(joinMap.ContactMethods.JoinNumber,
|
trilist.SetString(joinMap.ContactMethods.JoinNumber,
|
||||||
|
|||||||
Reference in New Issue
Block a user