北京安通林JIS系统
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

100 lines
2.4 KiB

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Stone.Common;
using Stone.WinBiz.SystemData;
using Stone.Entity;
using Stone.WinBiz.BasicData;
namespace Stone.WinModule.BasicData
{
public partial class frmEmpDetail : Stone.WinModule.BasicData.frmBaseMainDetail
{
public frmEmpDetail()
{
InitializeComponent();
}
private void frmColorDetail_Load(object sender, EventArgs e)
{
}
public override bool GetData()
{
if (!MyValidator.IsEmpty(this.txtCode, "")) return false;
if (!MyValidator.IsEmpty(this.txtName, "")) return false;
base.GetData();
drData["DepCode"] = MyStrings.GetString(this.txtDepCode.Text.Trim());
drData["Code"] = MyStrings.GetString(this.txtCode.Text.Trim());
drData["Name"] = MyStrings.GetString(this.txtName.Text.Trim());
drData["Memo"] = MyStrings.GetString(this.txtMemo.Text.Trim());
return true;
}
public override bool SetData()
{
if (base.SetData())
{
this.txtDepCode.Text = drData["DepCode"].ToString();
this.txtCode.Text= drData["Code"].ToString();
this.txtName.Text = drData["Name"].ToString();
this.txtMemo.Text = drData["Memo"].ToString();
}
return false;
}
public override void Clear()
{
base.Clear();
this.txtCode.Text = "";
this.txtName.Text = "";
this.txtMemo.Text = "";
this.txtCode.Focus();
}
private void txtDepCode_OnSelectClick(object sender, EventArgs e)
{
try
{
frmCarModel frm = new frmCarModel();
frm.m_Base = new F_CarModel();
frm.init();
if (frm.ShowSelect("") == System.Windows.Forms.DialogResult.OK)
{
this.txtDepCode.Text = frm.SelectValue;
}
frm.Dispose();
}
catch (Exception ex)
{
MyMessageBox.ShowErrorMessage(ex.Message);
}
}
}
}