66 lines
1.8 KiB
C#
66 lines
1.8 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Data;
|
|
using System.Windows.Forms;
|
|
namespace AIMS.PublicUI.BLL
|
|
{
|
|
public class Person
|
|
{
|
|
public static void Add(Model.Person PersonObj)
|
|
{
|
|
try
|
|
{
|
|
new DAL.PersonDB().Add(PersonObj);
|
|
MessageBox.Show("增加成功!");
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
MessageBox.Show("增加失败!" + ex.Message);
|
|
}
|
|
}
|
|
|
|
public static void Update(Model.Person PersonObj)
|
|
{
|
|
try
|
|
{
|
|
new DAL.PersonDB().Update(PersonObj);
|
|
MessageBox.Show("修改成功!");
|
|
}
|
|
catch (Exception ex)
|
|
{
|
|
MessageBox.Show("修改失败!" + ex.Message);
|
|
}
|
|
}
|
|
|
|
public static Model.Person GetModel(int Id)
|
|
{
|
|
return new DAL.PersonDB().GetModel(Id); ;
|
|
}
|
|
|
|
public static DataTable GetPersonDataTable()
|
|
{
|
|
return new DAL.PersonDB().GetPersonDataTable();
|
|
}
|
|
public static DataTable GetPersonDataTable(string name,string DeptName)
|
|
{
|
|
return new DAL.PersonDB().GetPersonDataTable(name,DeptName);
|
|
}
|
|
public static bool Login(string No, string PassWord)
|
|
{
|
|
return new DAL.PersonDB().Login(No, PassWord);
|
|
}
|
|
public static Model.Person GetModelByNo(string No)
|
|
{
|
|
return new DAL.PersonDB().GetModelByNo(No);
|
|
}
|
|
|
|
|
|
public static DataTable GetPersonDataTableByDepId(int DepId, string HelpCode, string PersonType)
|
|
{
|
|
return new DAL.PersonDB().GetPersonDataTableByDepId(DepId, HelpCode,PersonType);
|
|
}
|
|
}
|
|
}
|