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.
 
 
 
 
 

34 lines
1.0 KiB

using NFine.Code;
using NFine.Data.Extensions;
using NFine.Domain.Entity.SystemManage;
using NFine.Repository;
using System;
using System.Collections.Generic;
using System.Data;
using System.Data.Common;
using System.Linq;
using System.Text;
namespace NFine.Application
{
public class UserWorkPointApp : RepositoryFactory<UserEntity>
{
public DataTable GetWorkPoint(string queryJson)
{
DataTable dt = new DataTable();
var queryParam = queryJson.ToJObject();
List<DbParameter> parameter = new List<DbParameter>();
string sql = @"SELECT WorkPointCode,WorkPointName FROM dbo.Sys_WorkPoint where 1=1 ";
if (!string.IsNullOrWhiteSpace(queryJson))
{
if (!string.IsNullOrWhiteSpace(queryParam["WorkPointCode"].ToString()))
{
sql += " and WorkPointCode = '%" + queryParam["WorkPointCode"].ToString() + "%' ";
}
}
return Repository().FindTableBySql(sql.ToString());
}
}
}