| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Drawing;
- using System.Data;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- using IVRFlowEditor.IVRControlUtility;
- using HySoft.IVRFlowEditor.Utility;
- using HySoft.IVRFlowEditor.IVRControlUtility;
- namespace IVRFlowEditor.IVRControl
- {
- public partial class CtlIVRHangUp : UserControl
- {
- IVRHangUp _IVRHangUp;
- public CtlIVRHangUp(IVRHangUp obj)
- {
- InitializeComponent();
- this.Load += new EventHandler(CtlIVRHangUp_Load);
- _IVRHangUp = obj;
- }
- void CtlIVRHangUp_Load(object sender, EventArgs e)
- {
- this.cmb_NextNode.DataSource = null;
- this.tb_NodeID.Text = _IVRHangUp.Pos;
- this.tb_NodeName.Text = _IVRHangUp.Name;
- this.rtb_Note.Text = _IVRHangUp.Note;
- this.cmb_NextNode.DataSource = GlobalController.GetComBoBoxofIVR(); ;
- this.cmb_NextNode.DisplayMember = "Note";//2017-5-8将Name改为Note
- this.cmb_NextNode.ValueMember = "ID";
- if (_IVRHangUp.Next != null)
- this.cmb_NextNode.SelectedItem = _IVRHangUp.Next;
- }
- private void btn_enter_Click(object sender, EventArgs e)
- {
- _IVRHangUp.Name = tb_NodeName.Text;
- _IVRHangUp.Note = rtb_Note.Text;
- if (this.cmb_NextNode.SelectedItem != null)
- _IVRHangUp.Next = (this.cmb_NextNode.SelectedItem as IVRControlBase);
- this.FindForm().DialogResult = DialogResult.OK;
- this.FindForm().Close();
- }
- private void btn_cancel_Click(object sender, EventArgs e)
- {
- this.FindForm().DialogResult = DialogResult.No;
- this.FindForm().Close();
- }
- }
- }
|