You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

48 lines
1.4 KiB
C#

2 years ago
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections;
using System.Data;
using Estsh.Web.Dal;
using Estsh.Web.Util;
namespace Estsh.Core.Services
{
public class DeleteKpsnService
{
public DeleteKpsnDal dal = new DeleteKpsnDal(RemotingProxyProvider._remotingProxy);
//cady 2014 07 07
/// <summary>
/// 根据分页条件获取分页菜单数据
/// </summary>
/// <param name="menuName"></param>
/// <param name="pager"></param>
/// <param name="direction"></param>
/// <param name="sort"></param>
/// <returns></returns>
public Hashtable GetDataByKPSN(String CustSN, Pager pager, String direction, String sort)
{
Hashtable result = new Hashtable();
String strWhere = " 1 = 1 ";
if (CustSN != null && !CustSN.Trim().Equals(""))
{
strWhere += " and kpsn like '%" + CustSN.Trim() + "%' or serial_number like '%" + CustSN.Trim() + "%'";
}
String orderBy = "";
if (sort != null && !"".Equals(sort.Trim()))
{
orderBy += sort + " " + direction;
}
else
{
orderBy += " ruid " + direction;
}
result = dal.GetDataByKPSN(pager.pageSize, pager.pageNo, strWhere, orderBy);
return result;
}
}
}