internal abstract Bitmap GetShowImageByState(DispatchPlatform.TalkControl.EnumUserLineStatus status = TalkControl.EnumUserLineStatus.None);
Ejemplo n.º 2
0
        /// <summary>根据用户状态信息得到个数</summary>
        /// <returns></returns>
        public int GetMemberCountByLineState(bool isBoxOnline,DispatchPlatform.TalkControl.EnumUserLineStatus state)
        {
            int count = 0;
            if (isBoxOnline==false)
            {
                return 0;
            }
             List<SingleUserControl> lstC = _lstGroup[0].lstControl.FindAll(delegate(SingleUserControl s)
            {
                return s.UserLineStatus == state;
            });
         
          
            if (lstC != null)
            {
                count = lstC.Count;
            }

            lstC = _lstGroup[1].lstControl.FindAll(delegate(SingleUserControl s)
            {
                return s.UserLineStatus == state;
            });

            if (lstC != null)
            {
                count =count+ lstC.Count;
            }
            return count;
        }
Ejemplo n.º 3
0
 /// <summary>更新单个成员状态</summary>
 public void UpdateMemberState(long number, DispatchPlatform.TalkControl.EnumUserLineStatus state)
 {
     foreach (NormalGroupModel item in _lstGroup)
     {
         SingleUserControl s = item.lstControl.Find(delegate(SingleUserControl p) { return p.Number == number; });
         if (s != null)
         {
            // s.MeetingMemberState = state;
             s.UserLineStatus = state;
             if (state == TalkControl.EnumUserLineStatus.Record)
             {
                 s.UserRecordStatus = TalkControl.EnumRecordStatus.ON;
             }
             else
             {
                 s.UserRecordStatus = TalkControl.EnumRecordStatus.OFF;
             }
             Pub.UpdateSingleUserContorlFont(s);
           //  break;
         }
     }
 }
 public FormCallKeyborad(DispatchPlatform.TalkControl tc)
 {
     _tc = tc;
     InitializeComponent();
     lblNumber.Text = "";
 }
Ejemplo n.º 5
0
        void waitControl1_OnSelect(object obj, DispatchPlatform.Control.WaitControl.SelectEventArgs e)
        {
            BaseCommand bc = null;
            switch (e.Type)
            {
                case CommControl.PublicEnums.EnumWaitType.Normal:
                    bc = new SelectAnswerCommand();
                    break;
                case CommControl.PublicEnums.EnumWaitType.Lemc:
                    bc = new SelectLemcAnswerCommand();
                    break;
                default:
                    break;
            }
            AutoSelectIdelDispatch();

            if (_isBoxOnline)
            {
                if (Pub.CurrentDispatchControl.UserLineStatus == TalkControl.EnumUserLineStatus.Idle
                    || Pub.CurrentDispatchControl.UserLineStatus == TalkControl.EnumUserLineStatus.HookOn
                    || Pub.CurrentDispatchControl.UserLineStatus == TalkControl.EnumUserLineStatus.Holding
                    )
                {
                    bc.MemberControl = new SingleUserControl()
                    {
                        Number = e.Number
                    };
                    bc.talkControl = Pub._talkControl;
                    bc.OnMsg += new BaseCommand.MsgDelegate(bc_OnMsg);

                    bc.Begin();
                }
            }
        }
Ejemplo n.º 6
0
        /// <summary>增加会议分组</summary>
        public void AddMeetingGroup(MeetingGroupModel.EnumMeetingState meetingState, DispatchPlatform.MeetingGroupModel.EnumMeetingType meetingType, int groupID, int meetingID, string meetingGroupName, List<DB_Talk.Model.m_Member> lstMembers, long dispatchNumber, bool tabVisible)
        {
            foreach (SuperTabItem item in _mainForm.superTabControlMeeting.Tabs)
            {
                MeetingGroupModel model = (MeetingGroupModel)item.Tag;
                if (model.GroupName == meetingGroupName || lstMembers.Count==0)
                {
                    return;
                }
            }


            SuperTabItem tabItem = new SuperTabItem();
            
            tabItem.GlobalItem = false;
            tabItem.SelectedTabFont = new System.Drawing.Font("宋体", 18F, System.Drawing.FontStyle.Bold);
            superTabLinearGradientColorTable1.Colors = new System.Drawing.Color[] {
        System.Drawing.Color.FromArgb(((int)(((byte)(36)))), ((int)(((byte)(41)))), ((int)(((byte)(48))))),
        System.Drawing.Color.FromArgb(((int)(((byte)(95)))), ((int)(((byte)(113)))), ((int)(((byte)(130)))))};
            superTabItemStateColorTable1.Background = superTabLinearGradientColorTable1;
            superTabColorStates1.Selected = superTabItemStateColorTable1;
            superTabItemColorTable1.Bottom = superTabColorStates1;
            tabItem.TabColor = superTabItemColorTable1;
            
            tabItem.Text = meetingGroupName;


            Pub.SetSupperTabColor(tabItem);

            tabItem.Click += new EventHandler(_mainForm.MeetingTabItem_Click);

            MeetingGroupModel mModel = new MeetingGroupModel();
            
            mModel.MeetingState = meetingState;
            mModel.MeetingID = meetingID;
            mModel.GroupID = groupID;
            mModel.GroupName = meetingGroupName;
            mModel.MeetingType = meetingType;
            mModel.DispatchNumber = dispatchNumber;
            tabItem.Tag = mModel;

            _lstGroup.Add(mModel);

           
            _mainForm.superTabControlMeeting.Tabs.Add(tabItem);

            _mainForm.superTabControlMeeting.SelectedTab = tabItem;
            SuperTabControlPanel sp = new SuperTabControlPanel();

            tabItem.Visible = tabVisible;

            _mainForm.superTabControlMeeting.Controls.Add(sp);
            tabItem.AttachedControl = sp;

            //_lstGroup.Add(mModel);
            PageControl pControl = new PageControl();
            mModel.pageControl = pControl;
            pControl.Dock = DockStyle.Fill;
            sp.Controls.Add(pControl);
            
            foreach (DB_Talk.Model.m_Member item in lstMembers)
            {
                if (item.i_Number != Pub.manageModel.LeftDispatchNumber.Value && item.i_Number != Pub.manageModel.RightDispatchNumber.Value)
                {
                    SingleUserControl sc = new SingleUserControl();

                    sc.Number = item.i_Number.Value;
                    sc.MemberName = item.vc_Name;
                    sc.ID = item.ID;
                    if (item.DepartmentID!=null)
                    {
                        sc.DepartmentID = item.DepartmentID.Value;    
                    }

                    if (item.i_TellType != null)
                    {
                        sc.TellType = (CommControl.PublicEnums.EnumTelType)item.i_TellType.Value;
                        if (item.i_TellType.Value==0)
                        {
                            sc.TellType = PublicEnums.EnumTelType.WiFi手机;
                        }
                    }
                    else
                    {
                        sc.TellType = PublicEnums.EnumTelType.WiFi手机;
                    }

                    if (meetingType == MeetingGroupModel.EnumMeetingType.Temp)
                    {
                        sc.PeerNumber = meetingGroupName;
                        sc.UserLineStatus = Pub._memberManage.GetMemberState(item.i_Number.Value);
                    }

                    mModel.lstControl.Add(sc);
                    sc.Click += new EventHandler(_mainForm.single_Click);
                }
            }
            if (meetingType == MeetingGroupModel.EnumMeetingType.Temp)
            {
                mModel.DispatchNumber = dispatchNumber;
                tabItem.RaiseClick();
            }
            pControl.Init(mModel.lstControl);
        }