Ejemplo n.º 1
0
        //天切片
        #endregion

        /// <summary>
        /// 实际的统计
        /// </summary>
        public void DoAction(DataBaseConfig ADataBaseConfig, ServiceConfigInfo AServiceConfigInfo, GlobalSetting AGolbalSetting)
        {
            this.IDataBaseConfig    = ADataBaseConfig;
            this.IServiceConfigInfo = AServiceConfigInfo;
            this.IGlobalSetting     = AGolbalSetting;

            //得到全部的座席
            List <ObjectInfo> lstAgentInfo = new List <ObjectInfo>();

            DALAgentInfo.GetAllAgentInfo(IDataBaseConfig, ref lstAgentInfo, IGlobalSetting);
            foreach (ObjectInfo agent in lstAgentInfo)
            {
                DoTimeSplitStatistics(agent);
                Thread.Sleep(10);
            }

            //得到全部的分机
            lstAgentInfo.Clear();
            DALExtensionInfo.GetAllExtensionInfo(IDataBaseConfig, ref lstAgentInfo, IGlobalSetting);
            foreach (ObjectInfo extension in lstAgentInfo)
            {
                DoTimeSplitStatistics(extension);
                Thread.Sleep(10);
            }
        }
Ejemplo n.º 2
0
        //天切片
        #endregion

        public void DoAction(DataBaseConfig ADataBaseConfig, ServiceConfigInfo AServiceConfigInfo, GlobalSetting AGolbalSetting)
        {
            try
            {
                //得到全局参数
                this.IDataBaseConfig    = ADataBaseConfig;
                this.IServiceConfigInfo = AServiceConfigInfo;
                this.IGlobalSetting     = AGolbalSetting;

                //得到全部的座席
                List <ObjectInfo> lstAgentInfo = new List <ObjectInfo>();
                DALAgentInfo.GetAllAgentInfo(IDataBaseConfig, ref lstAgentInfo, IGlobalSetting);
                foreach (ObjectInfo agent in lstAgentInfo)
                {
                    DoTimeSplitStatistics(agent);
                    Thread.Sleep(10);
                }

                //得到全部的分机
                lstAgentInfo.Clear();
                DALExtensionInfo.GetAllExtensionInfo(IDataBaseConfig, ref lstAgentInfo, IGlobalSetting);
                foreach (ObjectInfo extension in lstAgentInfo)
                {
                    DoTimeSplitStatistics(extension);
                    Thread.Sleep(10);
                }

                //得到全部的用户
                lstAgentInfo.Clear();
                DALUserInfo.GetAllUserInfo(IDataBaseConfig, IGlobalSetting, ref lstAgentInfo);
                foreach (ObjectInfo user in lstAgentInfo)
                {
                    DoTimeSplitStatistics(user);
                    Thread.Sleep(10);
                }
            }
            catch (Exception ex)
            {
                FileLog.WriteError("QMStatistics().DoAction", ex.Message);
            }
        }