private void CallBack(Object stateObject) { if (ConstantValuePool.BizSettingConfig.telCallConfig.Enabled && ConstantValuePool.IsTelCallWorking) { if (ConstantValuePool.BizSettingConfig.telCallConfig.Model == 0 || ConstantValuePool.BizSettingConfig.telCallConfig.Model == 1) { if (LDT.Check_State(ConstantValuePool.TelCallID) == 255) { string strPhoneNo = LDT.GetNumber_Tel(1).ToString(); if (strPhoneNo.Length > 0) { //创建通话记录 CallRecord callRecord = new CallRecord(); callRecord.CallRecordID = Guid.NewGuid(); callRecord.Telephone = strPhoneNo; callRecord.CallTime = DateTime.Now; callRecord.Status = 0; CustomersService.GetInstance().CreateOrUpdateCallRecord(callRecord); this.lbTelephone.Text = strPhoneNo; this.txtCustomerName.Text = string.Empty; this.txtAddress1.Text = string.Empty; this.txtAddress2.Text = string.Empty; this.txtAddress3.Text = string.Empty; _customerInfo = CustomersService.GetInstance().GetCustomerInfoByPhone(strPhoneNo); if (_customerInfo != null) { txtCustomerName.Text = _customerInfo.CustomerName; txtAddress1.Text = _customerInfo.DeliveryAddress1; txtAddress2.Text = _customerInfo.DeliveryAddress2; txtAddress3.Text = _customerInfo.DeliveryAddress3; if (_customerInfo.ActiveIndex == 1) { ckAddress1.Checked = true; } else if (_customerInfo.ActiveIndex == 2) { ckAddress2.Checked = true; } else if (_customerInfo.ActiveIndex == 3) { ckAddress3.Checked = true; } } } } } if (ConstantValuePool.BizSettingConfig.telCallConfig.Model == 0) { ConstantValuePool.IsTelCallWorking = LDT.Plugin_Tel(ConstantValuePool.TelCallID); } } }
private void button3_Click(object sender, EventArgs e) { LDT about = new LDT(); about.ShowDialog(); }