xxe 2 yıl önce
ebeveyn
işleme
fa1f5b912e
2 değiştirilmiş dosya ile 13 ekleme ve 37 silme
  1. +3
    -27
      HKCardManager/UserPages/PersonnelEntryPage.Designer.cs
  2. +10
    -10
      HKCardManager/UserPages/PersonnelEntryPage.cs

+ 3
- 27
HKCardManager/UserPages/PersonnelEntryPage.Designer.cs Dosyayı Görüntüle

@@ -30,8 +30,6 @@
{
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
this.button2 = new System.Windows.Forms.Button();
this.textBox2 = new System.Windows.Forms.TextBox();
this.label4 = new System.Windows.Forms.Label();
this.comboBox2 = new System.Windows.Forms.ComboBox();
this.label3 = new System.Windows.Forms.Label();
this.textBox1 = new System.Windows.Forms.TextBox();
@@ -73,7 +71,7 @@
//
// button2
//
this.button2.Location = new System.Drawing.Point(757, 13);
this.button2.Location = new System.Drawing.Point(468, 14);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(90, 32);
this.button2.TabIndex = 20;
@@ -81,24 +79,6 @@
this.button2.UseVisualStyleBackColor = true;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// textBox2
//
this.textBox2.Font = new System.Drawing.Font("Microsoft YaHei UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.textBox2.Location = new System.Drawing.Point(323, 13);
this.textBox2.Name = "textBox2";
this.textBox2.Size = new System.Drawing.Size(136, 28);
this.textBox2.TabIndex = 18;
//
// label4
//
this.label4.AutoSize = true;
this.label4.Font = new System.Drawing.Font("Microsoft YaHei UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.label4.Location = new System.Drawing.Point(228, 17);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(106, 21);
this.label4.TabIndex = 17;
this.label4.Text = "输入手机号:";
//
// comboBox2
//
this.comboBox2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
@@ -107,7 +87,7 @@
this.comboBox2.Items.AddRange(new object[] {
"男",
"女"});
this.comboBox2.Location = new System.Drawing.Point(579, 13);
this.comboBox2.Location = new System.Drawing.Point(320, 14);
this.comboBox2.Name = "comboBox2";
this.comboBox2.Size = new System.Drawing.Size(97, 29);
this.comboBox2.TabIndex = 16;
@@ -116,7 +96,7 @@
//
this.label3.AutoSize = true;
this.label3.Font = new System.Drawing.Font("Microsoft YaHei UI", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point);
this.label3.Location = new System.Drawing.Point(499, 17);
this.label3.Location = new System.Drawing.Point(240, 18);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(90, 21);
this.label3.TabIndex = 15;
@@ -153,11 +133,9 @@
//
// splitContainer1.Panel2
//
this.splitContainer1.Panel2.Controls.Add(this.textBox2);
this.splitContainer1.Panel2.Controls.Add(this.comboBox2);
this.splitContainer1.Panel2.Controls.Add(this.button2);
this.splitContainer1.Panel2.Controls.Add(this.textBox1);
this.splitContainer1.Panel2.Controls.Add(this.label4);
this.splitContainer1.Panel2.Controls.Add(this.label3);
this.splitContainer1.Panel2.Controls.Add(this.label1);
this.splitContainer1.Size = new System.Drawing.Size(947, 561);
@@ -427,8 +405,6 @@
#endregion

private Button button2;
private TextBox textBox2;
private Label label4;
private ComboBox comboBox2;
private Label label3;
private TextBox textBox1;


+ 10
- 10
HKCardManager/UserPages/PersonnelEntryPage.cs Dosyayı Görüntüle

@@ -103,18 +103,18 @@ namespace HKCardManager.UserPages
MessageLogNotify.GetInstance.ShowWarning("请输入姓名");
return;
}
if (!string.IsNullOrEmpty(textBox2.Text.Trim()))
{
if (!textBox2.Text.Trim().IsMobile())
{
MessageLogNotify.GetInstance.ShowWarning("手机号格式不正确");
return;
}
}
//if (!string.IsNullOrEmpty(textBox2.Text.Trim()))
//{
// if (!textBox2.Text.Trim().IsMobile())
// {
// MessageLogNotify.GetInstance.ShowWarning("手机号格式不正确");
// return;
// }
//}
UserDto userDto = new UserDto()
{
Name = textBox1.Text.Trim(),
Phone = textBox2.Text.Trim(),
//Phone = textBox2.Text.Trim(),
OrgId = orgTables.FirstOrDefault(p => p.Name == comboBox2.Text)?.SId
};
string OrgName = comboBox2.Text;
@@ -127,7 +127,7 @@ namespace HKCardManager.UserPages
this.Invoke(() =>
{
textBox1.Text = string.Empty;
textBox2.Text = string.Empty;
//textBox2.Text = string.Empty;
});
MessageLogNotify.GetInstance.Show($"用户 【{userDto.Name}】 添加成功");
}


Yükleniyor…
İptal
Kaydet