コード例 #1
0
        public void DeletePersonalizedGreeting(CallButlerAuthInfo authInfo, Guid personalizedGreetingID)
        {
            if (Authenticate(authInfo))
            {
                dataProvider.DeletePersonalizedGreeting(authInfo.CustomerID, personalizedGreetingID);

                // Delete any greeting associated with this
                DeleteGreeting(authInfo, personalizedGreetingID);
            }
        }
コード例 #2
0
 public string GetLogErrorEmail(CallButlerAuthInfo authInfo)
 {
     if (Authenticate(authInfo))
         return Properties.Settings.Default.LogErrorEmailAddress;
     else
         return null;
 }
コード例 #3
0
 public bool GetMultilingual(CallButlerAuthInfo authInfo)
 {
     return Authenticate(authInfo) ? Properties.Settings.Default.Multilingual : false;
 }
コード例 #4
0
 public string GetLanguages(CallButlerAuthInfo authInfo)
 {
     return Authenticate(authInfo) ? Properties.Settings.Default.Languages : null;
 }
コード例 #5
0
 public CallButlerDataset.LocalizedGreetingsDataTable GetLocalizedGreetingInDefaultLanguage(CallButlerAuthInfo authInfo, Guid greetingID)
 {
     return Authenticate(authInfo) ? GetLocalizedGreeting(authInfo, greetingID, GetDefaultLanguage(authInfo)) : null;
 }
コード例 #6
0
 public CallButlerDataset.LocalizedGreetingsDataTable GetExtensionVoicemailGreeting(CallButlerAuthInfo authInfo, Guid extensionID)
 {
     return Authenticate(authInfo) ? GetLocalizedGreeting(authInfo, extensionID, GetDefaultLanguage(authInfo)) : null;
 }
コード例 #7
0
        public string[] GetHoldMusic(CallButlerAuthInfo authInfo)
        {
            string[] fileList = new string[0];

            if (Authenticate(authInfo))
            {
                string holdMusicLocation = WOSI.Utilities.FileUtils.GetApplicationRelativePath(Properties.Settings.Default.HoldMusicRootDirectory);

                if (Directory.Exists(holdMusicLocation))
                {
                    fileList = Directory.GetFiles(holdMusicLocation);
                }
            }

            return fileList;
        }
コード例 #8
0
 public int GetAnswerTimeout(CallButlerAuthInfo authInfo)
 {
     if (Authenticate(authInfo))
         return Properties.Settings.Default.AnswerTimeout;
     else
         return 0;
 }
コード例 #9
0
 public string GetApplicationPermissions(CallButlerAuthInfo authInfo)
 {
     return Authenticate(authInfo) ? Properties.Resources.Permissions : null;
 }
コード例 #10
0
        public bool DoesEmployeeHaveNewVoicemails(CallButlerAuthInfo authInfo, Guid extensionId)
        {
            if (Authenticate(authInfo))
            {
                CallButlerDataset.VoicemailsDataTable voicemailTable = dataProvider.GetVoicemails(extensionId);

                if (voicemailTable.Select("IsNew = True").Length > 0)
                {
                    return true;
                }
                else
                {
                    return false;
                }
            }
            else
            {
                return false;
            }
        }
コード例 #11
0
        public object ExchangePluginData(CallButlerAuthInfo authInfo, Guid pluginID, string method, object data)
        {
            if (Authenticate(authInfo))
            {
                foreach (CallButler.Service.Plugin.CallButlerServicePlugin plugin in pluginManager.Plugins)
                {
                    if (plugin.PluginID == pluginID)
                        return plugin.ExchangePluginData(method, data);
                }
            }

            return null;
        }
コード例 #12
0
 public void DeleteVoicemail(CallButlerAuthInfo authInfo, Guid extensionID, Guid voicemailID)
 {
     if (Authenticate(authInfo))
     {
         vmService.DeleteVoicemail(extensionID, voicemailID);
     }
 }
コード例 #13
0
 public void DeleteScriptSchedule(CallButlerAuthInfo authInfo, Guid scriptScheduleID)
 {
     if (Authenticate(authInfo))
     {
         dataProvider.DeleteScriptSchedule(authInfo.CustomerID, scriptScheduleID);
     }
 }
コード例 #14
0
        public void DeleteProvider(CallButlerAuthInfo authInfo, Guid providerID)
        {
            if (Authenticate(authInfo))
            {
                // Unregister our provider
                telecomProvider.Unregister(providerID);

                dataProvider.DeleteProvider(authInfo.CustomerID, providerID);
            }
        }
コード例 #15
0
        public CallButlerDataset.ExtensionsDataTable GetExtensionNumber(CallButlerAuthInfo authInfo, int extensionNumber)
        {
            if (Authenticate(authInfo))
            {
                WOSI.CallButler.Data.CallButlerDataset.ExtensionsDataTable extensionTable = new CallButlerDataset.ExtensionsDataTable();
                WOSI.CallButler.Data.CallButlerDataset.ExtensionsRow extension = dataProvider.GetExtensionNumber(authInfo.CustomerID, extensionNumber);

                if (extension != null)
                    extensionTable.ImportRow(extension);

                return extensionTable;
            }
            else
            {
                return null;
            }
        }
コード例 #16
0
        //public bool FirstTimeRun
        //{
        //    get
        //    {
        //        return Properties.Settings.Default.FirstTimeRun;
        //    }
        //    set
        //    {
        //        Properties.Settings.Default.FirstTimeRun = value;
        //        Properties.Settings.Default.Save();
        //    }
        //}
        public AudioCodecInformation[] GetAudioCodecs(CallButlerAuthInfo authInfo)
        {
            if (Authenticate(authInfo))
            {
                List<AudioCodecInformation> codecs = new List<AudioCodecInformation>();

                foreach (CallButler.Telecom.AudioCodecInformation acInfo in telecomProvider.GetAudioCodecs())
                {
                    WOSI.CallButler.ManagementInterface.AudioCodecInformation newAcInfo = new AudioCodecInformation();

                    newAcInfo.Enabled = acInfo.Enabled;
                    newAcInfo.Name = acInfo.Name;

                    codecs.Add(newAcInfo);
                }

                return codecs.ToArray();
            }
            else
                return null;
        }
コード例 #17
0
        public CallButlerDataset.ExtensionsDataTable GetExtensions(CallButlerAuthInfo authInfo)
        {
            if (Authenticate(authInfo))
            {
                int maxExtensions = 100; // Licensing.Management.AppPermissions.StatGetPermissionScalar("Extensions");

                if (maxExtensions != 0)
                    return (CallButlerDataset.ExtensionsDataTable)TrimRows(dataProvider.GetExtensions(authInfo.CustomerID), maxExtensions);
                else
                    return dataProvider.GetExtensions(authInfo.CustomerID);
            }
            else
                return null;
        }
コード例 #18
0
 public string GetBusyRedirectServer(CallButlerAuthInfo authInfo)
 {
     if (Authenticate(authInfo))
         return Properties.Settings.Default.BusyRedirectServer;
     else
         return null;
 }
コード例 #19
0
        public bool GetFirstTimeRun(CallButlerAuthInfo authInfo)
        {
            if (Authenticate(authInfo))
            {
                return Properties.Settings.Default.FirstTimeRun;
            }

            return true;
        }
コード例 #20
0
 public WOSI.CallButler.Data.CallButlerDataset.CallHistoryDataTable GetCallHistory(CallButlerAuthInfo authInfo)
 {
     return Authenticate(authInfo) ? dataProvider.GetCallHistory(authInfo.CustomerID) : null;
 }
コード例 #21
0
 public string GetHostedTestAddress(CallButlerAuthInfo authInfo)
 {
     return String.Empty;
 }
コード例 #22
0
        //public string DefaultTTSVoice
        //{
        //    get
        //    {
        //        return Properties.Settings.Default.DefaultTTSVoice;
        //    }
        //    set
        //    {
        //        Properties.Settings.Default.DefaultTTSVoice = value;
        //        Properties.Settings.Default.Save();
        //    }
        //}
        public string GetDefaultVoice(CallButlerAuthInfo authInfo)
        {
            string defaultVoice = "";
            if (Authenticate(authInfo))
            {
                defaultVoice = Properties.Settings.Default.DefaultTTSVoice;
            }

            return defaultVoice;
        }
コード例 #23
0
        public CallButlerDataset.LocalizedGreetingsDataTable GetLocalizedGreeting(CallButlerAuthInfo authInfo, Guid greetingID, Guid localizedGreetingID)
        {
            if (Authenticate(authInfo))
            {
                CallButlerDataset.LocalizedGreetingsDataTable lgTable = new CallButlerDataset.LocalizedGreetingsDataTable();
                CallButlerDataset.LocalizedGreetingsRow localizedGreeting = dataProvider.GetLocalizedGreeting(authInfo.CustomerID, greetingID, localizedGreetingID);

                if (localizedGreeting != null)
                    lgTable.ImportRow(localizedGreeting);

                return lgTable;
            }
            else
            {
                return null;
            }
        }
コード例 #24
0
 public CallButlerDataset.DepartmentsDataTable GetDepartments(CallButlerAuthInfo authInfo)
 {
     return Authenticate(authInfo) ? dataProvider.GetDepartments(authInfo.CustomerID) : null;
 }
コード例 #25
0
        public byte[] GetLocalizedGreetingSound(CallButlerAuthInfo authInfo, Guid greetingID, Guid localizedGreetingID)
        {
            if (Authenticate(authInfo))
            {
                // First, find our greeting
                WOSI.CallButler.Data.CallButlerDataset.LocalizedGreetingsRow localizedGreeting = dataProvider.GetLocalizedGreeting(authInfo.CustomerID, greetingID, localizedGreetingID);

                if (localizedGreeting != null)
                {
                    string greetingFilename = WOSI.Utilities.FileUtils.GetApplicationRelativePath(Properties.Settings.Default.GreetingSoundRootDirectory) + "\\" + localizedGreeting.LanguageID + "\\" + localizedGreeting.GreetingID.ToString() + ".snd";

                    if (File.Exists(greetingFilename))
                        return WOSI.Utilities.FileUtils.GetFileBytes(greetingFilename);
                }
                return null;
            }
            else
            {
                return null;
            }
        }
コード例 #26
0
        public CallButlerDataset.ExtensionsDataTable GetEmployeeExtension(CallButlerAuthInfo authInfo, int extension, string password)
        {
            if (Authenticate(authInfo))
            {
                WOSI.CallButler.Data.CallButlerDataset.ExtensionsDataTable extensionsTable = GetExtensionNumber(authInfo, extension);

                if (extensionsTable.Count > 0)
                {
                    // If the passwords don't match, send an empty data table
                    if (extensionsTable[0].Password != password)
                    {
                        return new CallButlerDataset.ExtensionsDataTable();
                    }
                }

                return extensionsTable;
            }
            else
            {
                return null;
            }
        }
コード例 #27
0
 public string GetManagementPassword(CallButlerAuthInfo authInfo)
 {
     return Properties.Settings.Default.ManagementPassword;
 }
コード例 #28
0
 public CallButlerDataset.ExtensionContactNumbersDataTable GetExtensionContactNumbers(CallButlerAuthInfo authInfo, Guid extensionID)
 {
     return Authenticate(authInfo) ? dataProvider.GetExtensionContactNumbers(extensionID) : null;
 }
コード例 #29
0
 public CallButlerDataset.VoicemailsDataTable GetNewEmployeeVoicemails(CallButlerAuthInfo authInfo, Guid extensionId)
 {
     if (Authenticate(authInfo))
     {
         CallButlerDataset.VoicemailsDataTable vmTable = GetVoicemails(authInfo, extensionId);
         CallButlerDataset.VoicemailsDataTable newVmTable = new CallButlerDataset.VoicemailsDataTable();
         DataRow[] rows = vmTable.Select("IsNew=true");
         return MergeVoicemailDataRows(rows);
     }
     else
     {
         return null;
     }
 }
コード例 #30
0
        public void DeleteHoldMusic(CallButlerAuthInfo authInfo, string fileName)
        {
            if (Authenticate(authInfo))
            {
                string fileLocation = WOSI.Utilities.FileUtils.GetApplicationRelativePath(Properties.Settings.Default.HoldMusicRootDirectory);
                fileLocation = Path.Combine(fileLocation, fileName);

                if (File.Exists(fileLocation))
                {
                    File.SetAttributes(fileLocation, FileAttributes.Normal);
                    File.Delete(fileLocation);
                }
            }
        }